/* ============================================================
   MOA & AOA – Companies Act 2013 | LL.B. Study Resource
   Professional Educational Stylesheet
   Color Theme: Light-green, Red, Blue, Saffron, Pink & Green
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Merriweather:wght@400;700;900&family=Source+Sans+3:wght@400;600;700&display=swap');

/* ---- CSS VARIABLES ---- */
:root {
  --blue:       rgb(30, 100, 200);
  --blue-light: rgb(210, 230, 255);
  --blue-bg:    rgb(235, 245, 255);
  --blue-border:rgb(100, 160, 230);

  --saffron:       rgb(220, 130, 0);
  --saffron-light: rgb(255, 235, 180);
  --saffron-bg:    rgb(255, 248, 225);
  --saffron-border:rgb(210, 160, 50);

  --green:       rgb(30, 140, 60);
  --green-light: rgb(200, 245, 210);
  --green-bg:    rgb(235, 255, 240);
  --green-border:rgb(100, 200, 130);

  --pink:        rgb(220, 50, 120);
  --pink-light:  rgb(255, 210, 230);
  --pink-bg:     rgb(255, 240, 248);
  --pink-border: rgb(220, 140, 180);

  --red:         rgb(200, 20, 40);
  --red-light:   rgb(255, 210, 215);
  --red-bg:      rgb(255, 240, 242);
  --red-border:  rgb(220, 100, 110);

  --lgreen:      rgb(90, 190, 100);
  --lgreen-light:rgb(210, 255, 215);

  --text-dark:   rgb(25, 30, 40);
  --text-mid:    rgb(60, 70, 90);
  --font-head:   'Merriweather', Georgia, serif;
  --font-body:   'Source Sans 3', 'Segoe UI', Arial, sans-serif;
}

/* ---- RESET & BASE ---- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

body {
  font-family: var(--font-body);
  font-size: 15px;
  color: var(--text-dark);
  background: rgb(245, 248, 255);
  line-height: 1.7;
}

/* ---- DISCLAIMER BANNER ---- */
.disclaimer-banner {
  background: rgb(255, 243, 200);
  color: rgb(120, 70, 0);
  border-bottom: 3px solid rgb(220, 160, 50);
  text-align: center;
  padding: 10px 20px;
  font-size: 13px;
  font-family: var(--font-body);
  font-weight: 600;
  letter-spacing: 0.2px;
}

/* ---- PRINT BUTTON ---- */
.print-btn {
  position: fixed;
  top: 60px;
  right: 20px;
  z-index: 999;
  background: var(--blue);
  color: white;
  border: none;
  padding: 10px 18px;
  border-radius: 8px;
  cursor: pointer;
  font-size: 14px;
  font-weight: 700;
  font-family: var(--font-body);
  box-shadow: 0 3px 10px rgba(30,100,200,0.35);
  transition: background 0.2s, transform 0.1s;
}
.print-btn:hover { background: rgb(20,70,160); transform: translateY(-1px); }

/* ---- HEADER ---- */
.main-header {
  background: linear-gradient(135deg, rgb(20,60,180), rgb(60,130,240));
  color: white;
  padding: 30px 20px 28px;
  text-align: center;
  box-shadow: 0 4px 20px rgba(30,100,200,0.4);
}
.header-inner { max-width: 900px; margin: auto; }
.badge {
  display: inline-block;
  background: rgb(255,220,80);
  color: rgb(80,40,0);
  padding: 4px 16px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  margin-bottom: 12px;
}
.main-header h1 {
  font-family: var(--font-head);
  font-size: 28px;
  font-weight: 900;
  letter-spacing: -0.5px;
  margin-bottom: 8px;
}
.header-sub { font-size: 14px; opacity: 0.88; font-weight: 600; }

/* ---- JUMP NAV ---- */
.jump-nav {
  background: rgb(30, 60, 130);
  padding: 14px 20px;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}
.jump-nav-title {
  color: rgb(255,220,100);
  font-weight: 700;
  font-size: 13px;
  white-space: nowrap;
}
.jump-buttons { display: flex; flex-wrap: wrap; gap: 8px; }
.jump-buttons button {
  background: rgba(255,255,255,0.12);
  color: white;
  border: 1px solid rgba(255,255,255,0.3);
  padding: 5px 14px;
  border-radius: 20px;
  cursor: pointer;
  font-size: 12px;
  font-weight: 700;
  font-family: var(--font-body);
  transition: background 0.2s;
}
.jump-buttons button:hover { background: rgba(255,255,255,0.25); }

/* ---- TAB BAR ---- */
.tab-bar {
  display: flex;
  flex-wrap: wrap;
  background: rgb(240, 243, 252);
  border-bottom: 3px solid var(--blue);
  padding: 0 10px;
  gap: 3px;
}
.tab-btn {
  background: none;
  border: none;
  padding: 12px 18px;
  cursor: pointer;
  font-size: 13px;
  font-weight: 700;
  font-family: var(--font-body);
  color: var(--text-mid);
  border-bottom: 3px solid transparent;
  margin-bottom: -3px;
  transition: color 0.2s, border-color 0.2s;
  white-space: nowrap;
}
.tab-btn:hover { color: var(--blue); }
.tab-btn.active {
  color: var(--blue);
  border-bottom-color: var(--blue);
  background: white;
}

/* ---- TAB CONTENT ---- */
.tab-content { display: none; }
.tab-content.active { display: block; }

/* ---- CONTENT WRAPPER ---- */
.content-wrapper {
  max-width: 960px;
  margin: 30px auto;
  padding: 0 20px;
}

/* ---- SECTION CARDS ---- */
.section-card {
  border-radius: 12px;
  padding: 28px 32px;
  margin-bottom: 28px;
  border-left: 6px solid;
  box-shadow: 0 2px 12px rgba(0,0,0,0.07);
}
.section-card h2 {
  font-family: var(--font-head);
  font-size: 19px;
  font-weight: 900;
  margin-bottom: 16px;
  padding-bottom: 10px;
  border-bottom: 2px solid;
}
.section-card h3 {
  font-family: var(--font-head);
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 14px;
  color: var(--text-dark);
}

/* Card color variants */
.card-blue   { background: var(--blue-bg);    border-left-color: var(--blue);    }
.card-blue   h2 { color: var(--blue);    border-bottom-color: var(--blue-border); }

.card-saffron{ background: var(--saffron-bg); border-left-color: var(--saffron);  }
.card-saffron h2 { color: var(--saffron); border-bottom-color: var(--saffron-border); }

.card-green  { background: var(--green-bg);   border-left-color: var(--green);   }
.card-green  h2 { color: var(--green);   border-bottom-color: var(--green-border); }

.card-pink   { background: var(--pink-bg);    border-left-color: var(--pink);    }
.card-pink   h2 { color: var(--pink);    border-bottom-color: var(--pink-border); }

.card-red    { background: var(--red-bg);     border-left-color: var(--red);     }
.card-red    h2 { color: var(--red);     border-bottom-color: var(--red-border); }

/* ---- KEY TIP BOX ---- */
.key-tip {
  background: rgb(255, 252, 220);
  border: 1px solid rgb(220, 190, 50);
  border-radius: 8px;
  padding: 10px 16px;
  margin-top: 14px;
  font-size: 14px;
  font-weight: 600;
  color: rgb(90, 55, 0);
}

/* ---- EXAMPLE BOX ---- */
.example-box {
  background: rgb(240, 248, 255);
  border: 1px solid var(--blue-border);
  border-radius: 8px;
  padding: 10px 16px;
  margin-top: 10px;
  font-size: 13.5px;
  color: rgb(20, 60, 130);
  font-weight: 600;
}

/* ---- STUDY LIST ---- */
.study-list {
  padding-left: 22px;
  margin-top: 8px;
}
.study-list li {
  margin-bottom: 8px;
  font-weight: 600;
  font-size: 14.5px;
  color: var(--text-dark);
  line-height: 1.65;
}
.study-list li ul {
  padding-left: 20px;
  margin-top: 5px;
}
.study-list li ul li {
  font-weight: 500;
  font-size: 13.5px;
  margin-bottom: 4px;
  color: var(--text-mid);
}

/* ---- TABLE ---- */
.table-wrap { overflow-x: auto; margin-top: 14px; }
.study-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13.5px;
  min-width: 480px;
}
.study-table thead tr {
  background: rgb(30, 60, 160);
  color: white;
}
.study-table th {
  padding: 11px 14px;
  text-align: left;
  font-weight: 700;
  font-size: 13px;
  letter-spacing: 0.3px;
}
.study-table td {
  padding: 10px 14px;
  font-weight: 600;
  border-bottom: 1px solid rgb(210, 218, 235);
  vertical-align: top;
  color: var(--text-dark);
}
.study-table tbody tr:nth-child(even) { background: rgb(245, 248, 255); }
.study-table tbody tr:hover { background: rgb(230, 240, 255); }

/* ---- CLAUSE CARDS ---- */
.clause-card {
  display: flex;
  gap: 16px;
  background: white;
  border: 1px solid var(--blue-border);
  border-radius: 10px;
  padding: 18px;
  margin-bottom: 14px;
  box-shadow: 0 2px 8px rgba(30,100,200,0.06);
}
.clause-num {
  background: var(--blue);
  color: white;
  font-weight: 900;
  font-size: 12px;
  padding: 4px 10px;
  border-radius: 6px;
  height: fit-content;
  white-space: nowrap;
  font-family: var(--font-body);
}
.clause-body { flex: 1; }
.clause-body strong { font-size: 14.5px; color: var(--blue); display: block; margin-bottom: 8px; }
.clause-body ul { padding-left: 20px; }
.clause-body ul li { font-size: 13.5px; font-weight: 600; margin-bottom: 5px; color: var(--text-dark); }

/* ---- FLOWCHART ---- */
.flowchart-container {
  background: white;
  border: 2px solid var(--blue-border);
  border-radius: 12px;
  padding: 20px;
  margin-top: 16px;
  overflow-x: auto;
}
.flow-svg { width: 100%; max-width: 760px; display: block; margin: auto; }

/* ---- MIND MAP ---- */
.mindmap-container {
  background: rgb(245, 250, 255);
  border: 2px solid var(--green-border);
  border-radius: 12px;
  padding: 20px;
  overflow-x: auto;
}
.mind-svg { width: 100%; max-width: 900px; display: block; margin: auto; }

/* ---- ROADMAP ---- */
.roadmap-container { margin-top: 10px; }
.roadmap-stage {
  border-radius: 12px;
  padding: 24px 28px;
  margin-bottom: 20px;
  border-left: 8px solid;
}
.stage-1 { background: var(--blue-bg);    border-left-color: var(--blue);    }
.stage-2 { background: var(--green-bg);   border-left-color: var(--green);   }
.stage-3 { background: var(--saffron-bg); border-left-color: var(--saffron); }
.stage-4 { background: var(--pink-bg);    border-left-color: var(--pink);    }
.stage-5 { background: var(--red-bg);     border-left-color: var(--red);     }

.stage-header {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 14px;
}
.stage-icon {
  width: 42px; height: 42px;
  border-radius: 50%;
  background: var(--blue);
  color: white;
  display: flex; align-items: center; justify-content: center;
  font-weight: 900;
  font-size: 18px;
  flex-shrink: 0;
}
.stage-1 .stage-icon { background: var(--blue); }
.stage-2 .stage-icon { background: var(--green); }
.stage-3 .stage-icon { background: var(--saffron); }
.stage-4 .stage-icon { background: var(--pink); }
.stage-5 .stage-icon { background: var(--red); }

.stage-title {
  font-family: var(--font-head);
  font-size: 16px;
  font-weight: 900;
  color: var(--text-dark);
}
.stage-time {
  font-family: var(--font-body);
  font-size: 12px;
  font-weight: 600;
  color: rgb(100,100,120);
  background: rgba(0,0,0,0.07);
  padding: 3px 10px;
  border-radius: 20px;
  margin-left: 10px;
}
.stage-goal {
  margin-top: 14px;
  padding: 10px 16px;
  background: rgba(0,0,0,0.05);
  border-radius: 8px;
  font-size: 14px;
  font-weight: 700;
  color: var(--text-dark);
}

/* ---- FOOTER ---- */
.main-footer {
  background: rgb(25, 40, 90);
  color: rgba(255,255,255,0.75);
  text-align: center;
  padding: 24px 20px;
  font-size: 12.5px;
  line-height: 2;
  margin-top: 40px;
}

/* ============================================================
   PRINT STYLES
   ============================================================ */
@media print {
  .disclaimer-banner { position: static !important; }
  .print-btn, .jump-nav, .tab-bar { display: none !important; }
  .tab-content { display: block !important; }
  .section-card { page-break-inside: avoid; }
  body { font-size: 12px; }
  .main-header { background: #1e3c96 !important; -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  .study-table thead tr { background: #1e3ca0 !important; -webkit-print-color-adjust: exact; print-color-adjust: exact; }
}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 640px) {
  .main-header h1 { font-size: 20px; }
  .section-card { padding: 18px 16px; }
  .clause-card { flex-direction: column; }
  .tab-btn { padding: 8px 12px; font-size: 11px; }
  .print-btn { top: auto; bottom: 20px; right: 16px; }
  .stage-title { font-size: 14px; }
}