/* ===== CSS VARIABLES ===== */
:root {
  --green: rgb(34, 139, 34);
  --green-light: rgb(220, 245, 220);
  --green-border: rgb(34, 139, 34);
  --saffron: rgb(210, 105, 30);
  --saffron-light: rgb(255, 237, 210);
  --saffron-border: rgb(210, 105, 30);
  --blue: rgb(25, 90, 160);
  --blue-light: rgb(210, 228, 250);
  --blue-border: rgb(25, 90, 160);
  --bg: rgb(245, 248, 252);
  --card-bg: rgb(255, 255, 255);
  --text: rgb(30, 30, 40);
  --text-muted: rgb(90, 90, 110);
  --shadow: 0 2px 12px rgba(0,0,0,0.10);
  --shadow-hover: 0 6px 24px rgba(0,0,0,0.16);
  --radius: 10px;
  --font-main: 'Georgia', 'Times New Roman', serif;
  --font-ui: 'Trebuchet MS', 'Segoe UI', sans-serif;
}

/* ===== RESET & BASE ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-main);
  font-size: 16px;
  line-height: 1.75;
  font-weight: bold;
}

/* ===== DISCLAIMER BANNER ===== */
.disclaimer-banner {
  background: rgb(255, 243, 205);
  border-bottom: 3px solid rgb(210, 170, 30);
  color: rgb(110, 80, 0);
  text-align: center;
  padding: 10px 20px;
  font-size: 14px;
  font-family: var(--font-ui);
  font-weight: bold;
  letter-spacing: 0.3px;
}

/* ===== SITE HEADER ===== */
.site-header {
  background: linear-gradient(135deg, rgb(20, 65, 130) 0%, rgb(25, 90, 160) 50%, rgb(34, 139, 34) 100%);
  color: white;
  padding: 40px 20px 36px;
  text-align: center;
}

.header-inner {
  max-width: 900px;
  margin: 0 auto;
}

.header-badge {
  display: inline-block;
  background: rgba(255,255,255,0.20);
  border: 2px solid rgba(255,255,255,0.45);
  color: white;
  font-family: var(--font-ui);
  font-size: 12px;
  letter-spacing: 2px;
  text-transform: uppercase;
  padding: 4px 14px;
  border-radius: 20px;
  margin-bottom: 14px;
}

.site-header h1 {
  font-size: 2.4rem;
  font-weight: bold;
  text-shadow: 0 2px 8px rgba(0,0,0,0.3);
  margin-bottom: 8px;
}

.subtitle {
  font-size: 1rem;
  color: rgba(255,255,255,0.88);
  font-family: var(--font-ui);
  margin-bottom: 20px;
}

.print-btn {
  background: rgb(210, 105, 30);
  color: white;
  border: none;
  padding: 10px 26px;
  border-radius: 6px;
  font-size: 15px;
  font-family: var(--font-ui);
  font-weight: bold;
  cursor: pointer;
  box-shadow: 0 2px 8px rgba(0,0,0,0.25);
  transition: background 0.2s, transform 0.15s;
}
.print-btn:hover {
  background: rgb(180, 80, 10);
  transform: translateY(-2px);
}

/* ===== LAYOUT ===== */
.layout {
  display: flex;
  max-width: 1200px;
  margin: 0 auto;
  padding: 30px 16px;
  gap: 24px;
  align-items: flex-start;
}

/* ===== SIDEBAR ===== */
.sidebar {
  width: 240px;
  flex-shrink: 0;
  position: sticky;
  top: 20px;
}

.toc-card {
  background: var(--card-bg);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 20px;
  border-top: 4px solid var(--blue);
}

.toc-card h3 {
  font-family: var(--font-ui);
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--blue);
  margin-bottom: 14px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--blue-light);
}

.toc-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.toc-link {
  display: block;
  font-family: var(--font-ui);
  font-size: 13px;
  color: var(--text);
  text-decoration: none;
  padding: 6px 10px;
  border-radius: 5px;
  transition: background 0.2s, color 0.2s;
  font-weight: bold;
}
.toc-link:hover {
  background: var(--blue-light);
  color: var(--blue);
}

/* ===== MAIN CONTENT ===== */
.main-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 24px;
  min-width: 0;
}

/* ===== CARDS ===== */
.card {
  background: var(--card-bg);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
  transition: box-shadow 0.25s;
}
.card:hover {
  box-shadow: var(--shadow-hover);
}

.card-header {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px 24px;
}
.card-header.green  { background: linear-gradient(90deg, var(--green-light), rgb(200,240,200)); border-left: 5px solid var(--green); }
.card-header.saffron{ background: linear-gradient(90deg, var(--saffron-light), rgb(255,225,190)); border-left: 5px solid var(--saffron); }
.card-header.blue   { background: linear-gradient(90deg, var(--blue-light), rgb(190,215,250)); border-left: 5px solid var(--blue); }

.card-header .card-icon { font-size: 1.5rem; }

.card-header h2 {
  font-size: 1.2rem;
  font-family: var(--font-ui);
  font-weight: bold;
  color: var(--text);
}

.card-body {
  padding: 22px 28px;
}
.card-body p {
  margin-bottom: 12px;
}

/* ===== SUB HEADINGS ===== */
.sub-heading {
  font-size: 1rem;
  font-family: var(--font-ui);
  color: var(--blue);
  margin: 16px 0 8px;
  padding-left: 10px;
  border-left: 3px solid var(--blue);
}

/* ===== LISTS ===== */
.study-list {
  padding-left: 20px;
  margin-bottom: 12px;
}
.study-list li {
  margin-bottom: 7px;
  font-size: 15px;
  line-height: 1.7;
}
.study-list li::marker {
  color: var(--green);
}

/* ===== HIGHLIGHT BOXES ===== */
.highlight-box {
  padding: 14px 18px;
  border-radius: 7px;
  margin: 16px 0;
  font-size: 14.5px;
  line-height: 1.7;
  border-left: 4px solid;
}
.green-box   { background: var(--green-light);   border-color: var(--green);   color: rgb(20,80,20); }
.saffron-box { background: var(--saffron-light); border-color: var(--saffron); color: rgb(100,50,0); }
.blue-box    { background: var(--blue-light);    border-color: var(--blue);    color: rgb(15,50,110); }

/* ===== MINI TABLES ===== */
.mini-table, .table-wrap {
  overflow-x: auto;
  margin: 16px 0;
}
.mini-table table,
.summary-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
  font-family: var(--font-ui);
}
.mini-table table th,
.summary-table th {
  background: rgb(25, 90, 160);
  color: white;
  padding: 10px 14px;
  text-align: left;
  font-weight: bold;
}
.mini-table table td,
.summary-table td {
  padding: 9px 14px;
  border-bottom: 1px solid rgb(210,220,235);
  vertical-align: top;
}
.summary-table tr.alt td {
  background: rgb(240, 245, 252);
}
.mini-table table tr:hover td,
.summary-table tr:hover td {
  background: var(--blue-light);
}

/* ===== CONCEPT GRID ===== */
.concept-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 16px;
  margin-top: 10px;
}
.concept-card {
  background: rgb(248, 250, 255);
  border: 2px solid var(--blue-light);
  border-radius: 8px;
  padding: 14px 16px;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.concept-card:hover {
  border-color: var(--blue);
  box-shadow: 0 4px 12px rgba(25,90,160,0.15);
}
.concept-title {
  font-family: var(--font-ui);
  font-size: 14px;
  color: var(--blue);
  font-weight: bold;
  margin-bottom: 6px;
  padding-bottom: 5px;
  border-bottom: 1px solid var(--blue-light);
}
.concept-body {
  font-size: 13.5px;
  color: var(--text);
  line-height: 1.65;
}

/* ===== ROADMAP STAGES ===== */
.roadmap-stages {
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-bottom: 20px;
}
.stage {
  padding: 16px 20px;
  border-radius: 8px;
  border-left: 5px solid;
}
.stage-1 { background: rgb(220,245,220); border-color: var(--green); }
.stage-2 { background: var(--saffron-light); border-color: var(--saffron); }
.stage-3 { background: var(--blue-light); border-color: var(--blue); }
.stage-4 { background: rgb(252,240,255); border-color: rgb(140,60,180); }
.stage-5 { background: rgb(255,250,220); border-color: rgb(200,160,0); }

.stage-label {
  font-family: var(--font-ui);
  font-size: 14px;
  font-weight: bold;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 8px;
  color: var(--text);
}

/* ===== FOOTER ===== */
.site-footer {
  background: rgb(30, 40, 60);
  color: rgba(255,255,255,0.75);
  text-align: center;
  padding: 18px;
  font-family: var(--font-ui);
  font-size: 13px;
}

/* ===== SCROLL BEHAVIOR ===== */
html { scroll-behavior: smooth; }

/* ===== ACTIVE TOC LINK ===== */
.toc-link.active {
  background: var(--blue-light);
  color: var(--blue);
}

/* ===== RESPONSIVE ===== */
@media (max-width: 850px) {
  .layout { flex-direction: column; }
  .sidebar { width: 100%; position: static; }
  .toc-list { flex-direction: row; flex-wrap: wrap; }
  .toc-link { font-size: 12px; padding: 5px 8px; }
  .site-header h1 { font-size: 1.7rem; }
  .concept-grid { grid-template-columns: 1fr; }
}

/* ===== PRINT STYLES ===== */
@media print {
  .disclaimer-banner,
  .site-header,
  .sidebar,
  .site-footer,
  .print-btn { display: none !important; }
  body { background: white; color: black; font-size: 13px; }
  .layout { display: block; padding: 0; }
  .main-content { display: block; }
  .card { box-shadow: none; border: 1px solid #ccc; margin-bottom: 16px; page-break-inside: avoid; }
  .highlight-box { border: 1px solid #999; }
  a { color: black; text-decoration: none; }
}