/* ExamEdge Prep — design system v2 (deep navy + amber accent) */
:root {
  --navy-900: #0a1730;
  --navy-800: #102449;
  --navy-700: #1a3463;
  --navy-600: #25497f;
  --navy-100: #e6ecf6;
  --amber-500: #f5a524;
  --amber-600: #d98a08;
  --amber-100: #fff4d6;
  --ink: #0e1726;
  --ink-soft: #4b5773;
  --line: #dfe4ec;
  --line-strong: #c2cad8;
  --bg: #f6f5f1;
  --bg-card: #ffffff;
  --green-600: #0f7a5a;
  --red-600: #c2410c;
  --shadow-sm: 0 1px 2px rgba(10, 23, 48, 0.04), 0 1px 1px rgba(10,23,48,0.04);
  --shadow-md: 0 4px 12px rgba(10, 23, 48, 0.06), 0 2px 4px rgba(10,23,48,0.04);
  --shadow-lg: 0 16px 40px rgba(10,23,48,0.10), 0 4px 12px rgba(10,23,48,0.05);
  --radius-sm: 6px;
  --radius-md: 12px;
  --radius-lg: 18px;
  --max-w: 1180px;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
  font-size: 16px;
  line-height: 1.6;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img { max-width: 100%; display: block; }
a { color: var(--navy-700); text-decoration: none; }
a:hover { color: var(--amber-600); text-decoration: underline; }

.container { max-width: var(--max-w); margin: 0 auto; padding: 0 24px; }
.muted { color: var(--ink-soft); }

/* === TYPOGRAPHY === */
h1, h2, h3, h4 {
  font-family: 'Fraunces', 'Source Serif Pro', Georgia, serif;
  color: var(--navy-900);
  letter-spacing: -0.01em;
  line-height: 1.18;
  margin: 0 0 0.5em;
  font-weight: 600;
}
h1 { font-size: clamp(2rem, 4vw + 1rem, 3.4rem); font-weight: 700; }
h2 { font-size: clamp(1.5rem, 1.6vw + 1rem, 2.1rem); }
h3 { font-size: 1.25rem; }
h4 { font-size: 1.05rem; }
p  { margin: 0 0 1em; }
p + h2, ul + h2, ol + h2, table + h2 { margin-top: 1.6em; }

/* === HEADER === */
.site-header {
  background: var(--bg-card);
  border-bottom: 1px solid var(--line);
  position: sticky; top: 0; z-index: 50;
  backdrop-filter: saturate(1.6) blur(8px);
  background: rgba(255,255,255,0.92);
}
.nav { display: flex; align-items: center; gap: 32px; padding: 16px 0; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 700; color: var(--navy-900); font-size: 1.15rem; text-decoration: none; }
.brand:hover { color: var(--navy-800); text-decoration: none; }
.brand-mark {
  width: 40px; height: 40px;
  background: var(--navy-900);
  color: var(--amber-500);
  border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  font-family: 'Fraunces', serif; font-weight: 700; font-size: 1.05rem;
  box-shadow: var(--shadow-sm);
}
.brand small { display: block; font-size: 0.7rem; font-weight: 500; color: var(--ink-soft); text-transform: uppercase; letter-spacing: 0.08em; }
.nav nav { margin-left: auto; display: flex; gap: 24px; align-items: center; }
.nav nav a {
  color: var(--ink); font-weight: 500; font-size: 0.95rem;
  padding: 8px 0; border-bottom: 2px solid transparent;
}
.nav nav a:hover { color: var(--navy-900); border-bottom-color: var(--amber-500); text-decoration: none; }

/* === BUTTONS === */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 12px 22px; border-radius: 999px;
  font-weight: 600; font-size: 0.95rem;
  border: none; cursor: pointer; text-decoration: none;
  transition: transform 0.08s ease, box-shadow 0.15s ease, background 0.15s ease;
}
.btn-primary {
  background: var(--amber-500); color: var(--navy-900);
  box-shadow: 0 1px 1px rgba(0,0,0,0.08), inset 0 -2px 0 rgba(0,0,0,0.06);
}
.btn-primary:hover { background: var(--amber-600); color: #fff; text-decoration: none; transform: translateY(-1px); box-shadow: var(--shadow-md); }
.btn-dark { background: var(--navy-900); color: #fff; }
.btn-dark:hover { background: var(--navy-800); color: #fff; text-decoration: none; }
.btn-outline {
  background: transparent; color: var(--navy-900);
  border: 1.5px solid var(--navy-900);
}
.btn-outline:hover { background: var(--navy-900); color: #fff; text-decoration: none; }
.btn-sm { padding: 8px 16px; font-size: 0.85rem; }

/* === HERO === */
.hero {
  background: linear-gradient(180deg, var(--navy-900) 0%, var(--navy-800) 100%);
  color: #fff;
  padding: 64px 0 96px;
  position: relative; overflow: hidden;
}
.hero::before {
  content: ''; position: absolute; inset: 0;
  background-image:
    radial-gradient(circle at 20% 0%, rgba(245, 165, 36, 0.18), transparent 40%),
    radial-gradient(circle at 90% 100%, rgba(245, 165, 36, 0.08), transparent 50%);
  pointer-events: none;
}
.hero-grid { display: grid; grid-template-columns: 1.1fr 1fr; gap: 48px; align-items: center; position: relative; z-index: 1; }
.hero h1 { color: #fff; font-size: clamp(2.2rem, 3vw + 1.5rem, 3.8rem); margin-bottom: 18px; }
.hero p.lede { color: rgba(255,255,255,0.88); font-size: 1.15rem; margin-bottom: 28px; max-width: 560px; }
.hero-pill {
  display: inline-flex; align-items: center; gap: 8px;
  background: rgba(245,165,36,0.16); color: var(--amber-500);
  padding: 6px 14px; border-radius: 999px;
  font-size: 0.82rem; font-weight: 600; letter-spacing: 0.04em;
  margin-bottom: 20px; border: 1px solid rgba(245,165,36,0.3);
}
.hero-cta { display: flex; gap: 14px; flex-wrap: wrap; margin-bottom: 28px; }
.hero-stats { display: flex; gap: 40px; padding-top: 28px; border-top: 1px solid rgba(255,255,255,0.12); }
.hero-stats div span { display: block; font-family: 'Fraunces', serif; font-size: 2rem; font-weight: 700; color: var(--amber-500); }
.hero-stats div small { color: rgba(255,255,255,0.7); font-size: 0.78rem; text-transform: uppercase; letter-spacing: 0.1em; }
.hero-card {
  background: rgba(255,255,255,0.05); border: 1px solid rgba(255,255,255,0.12);
  border-radius: var(--radius-lg); padding: 28px;
  backdrop-filter: blur(8px);
}
.hero-card h3 { color: #fff; margin-bottom: 14px; }
.hero-card ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.hero-card li { display: flex; align-items: center; gap: 10px; color: rgba(255,255,255,0.92); font-size: 0.94rem; }
.hero-card li::before { content: '✓'; color: var(--amber-500); font-weight: 700; }

/* === SECTIONS === */
section { padding: 64px 0; }
.section-eyebrow {
  display: block; color: var(--amber-600); font-size: 0.78rem;
  text-transform: uppercase; letter-spacing: 0.15em; font-weight: 700;
  margin-bottom: 8px;
}
.section-heading { display: flex; justify-content: space-between; align-items: end; gap: 24px; margin-bottom: 32px; flex-wrap: wrap; }
.section-heading > div { max-width: 700px; }
.section-heading p { color: var(--ink-soft); margin: 6px 0 0; }

/* === CARDS === */
.grid { display: grid; gap: 22px; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
.grid-5 { grid-template-columns: repeat(5, 1fr); }
.grid-sidebar { grid-template-columns: 1fr 320px; gap: 48px; align-items: start; }

.card {
  background: var(--bg-card);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  padding: 24px;
  transition: transform 0.12s ease, box-shadow 0.15s ease, border-color 0.15s ease;
}
.card:hover { transform: translateY(-2px); box-shadow: var(--shadow-md); border-color: var(--line-strong); }

.cat-card { padding: 28px; height: 100%; display: flex; flex-direction: column; }
.cat-card .icon {
  width: 44px; height: 44px;
  background: var(--navy-100); color: var(--navy-800);
  border-radius: 12px; display: flex; align-items: center; justify-content: center;
  font-size: 1.4rem; margin-bottom: 16px;
}
.cat-card h3 { font-size: 1.15rem; margin: 0 0 8px; }
.cat-card .tag { font-size: 0.78rem; color: var(--amber-600); text-transform: uppercase; letter-spacing: 0.08em; font-weight: 700; }
.cat-card p { font-size: 0.92rem; color: var(--ink-soft); margin: 10px 0 18px; flex: 1; }
.cat-card .meta { font-size: 0.85rem; color: var(--navy-700); font-weight: 500; }
.cat-card a.cover-link { position: absolute; inset: 0; }
.cat-card { position: relative; }

.exam-card { display: flex; gap: 16px; align-items: start; }
.exam-card .num {
  flex-shrink: 0; width: 44px; height: 44px;
  background: var(--amber-100); color: var(--amber-600);
  border-radius: 10px; display: flex; align-items: center; justify-content: center;
  font-family: 'Fraunces', serif; font-weight: 700; font-size: 1.1rem;
}
.exam-card h4 { margin: 0 0 4px; font-size: 1.02rem; }
.exam-card p { font-size: 0.88rem; margin: 0; color: var(--ink-soft); }
.exam-card a { font-weight: 600; }

/* state grid */
.state-grid { columns: 4; column-gap: 24px; }
.state-grid li { break-inside: avoid; margin: 0 0 8px; list-style: none; font-size: 0.94rem; }
@media (max-width: 800px) { .state-grid { columns: 2; } }

/* === SIDEBAR === */
.sidebar { display: grid; gap: 24px; position: sticky; top: 90px; }
.sidebar .widget {
  background: var(--bg-card);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  padding: 22px;
}
.sidebar .widget h4 {
  font-family: 'Inter', sans-serif; font-weight: 700;
  font-size: 0.78rem; letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--ink-soft); margin: 0 0 14px;
}
.sidebar .widget ul { list-style: none; padding: 0; margin: 0; }
.sidebar .widget li { margin: 0 0 10px; padding-bottom: 10px; border-bottom: 1px dashed var(--line); }
.sidebar .widget li:last-child { border-bottom: none; padding-bottom: 0; margin-bottom: 0; }
.sidebar .widget a { color: var(--navy-800); font-weight: 500; font-size: 0.93rem; line-height: 1.4; }
.sidebar .widget a:hover { color: var(--amber-600); }
.sidebar .widget small { display: block; color: var(--ink-soft); font-size: 0.78rem; margin-top: 2px; }
.sidebar .editorial { background: var(--navy-900); color: #fff; }
.sidebar .editorial h4 { color: var(--amber-500); }
.sidebar .editorial a { color: rgba(255,255,255,0.94); }
.sidebar .editorial a:hover { color: var(--amber-500); }
.sidebar .editorial li { border-bottom-color: rgba(255,255,255,0.12); }

/* === ARTICLE / TOPIC PAGE === */
.topic-hero {
  background: linear-gradient(135deg, var(--navy-900), var(--navy-700));
  color: #fff; padding: 56px 0 64px;
}
.topic-hero h1 { color: #fff; }
.topic-hero .breadcrumb { color: rgba(255,255,255,0.7); font-size: 0.85rem; margin-bottom: 14px; }
.topic-hero .breadcrumb a { color: rgba(255,255,255,0.85); }
.topic-hero .breadcrumb a:hover { color: var(--amber-500); }
.topic-hero p { color: rgba(255,255,255,0.85); font-size: 1.05rem; max-width: 760px; }
.exam-meta { display: flex; gap: 28px; flex-wrap: wrap; padding: 16px 0 0; margin-top: 16px; border-top: 1px solid rgba(255,255,255,0.15); }
.exam-meta div { font-size: 0.86rem; color: rgba(255,255,255,0.75); }
.exam-meta strong { color: #fff; display: block; font-size: 0.95rem; font-weight: 600; }

.prose { font-size: 1.02rem; line-height: 1.8; color: var(--ink); }
.prose p { margin: 0 0 1.2em; }
.prose h2 { margin-top: 1.8em; padding-top: 0.4em; }
.prose h3 { margin-top: 1.6em; }
.prose ul, .prose ol { padding-left: 1.4em; margin: 0 0 1.2em; }
.prose li { margin-bottom: 0.4em; }
.prose blockquote {
  border-left: 4px solid var(--amber-500); margin: 1.4em 0; padding: 0.4em 1em;
  color: var(--ink-soft); background: var(--amber-100); border-radius: 0 8px 8px 0;
}
.callout {
  background: var(--navy-100); border-left: 4px solid var(--navy-700);
  padding: 18px 22px; border-radius: 8px; margin: 22px 0;
}
.callout strong { color: var(--navy-900); }

/* === QUESTION FORM === */
.question {
  background: var(--bg-card); border: 1px solid var(--line);
  border-radius: var(--radius-md); padding: 24px; margin: 0 0 18px;
}
.question .q-num { font-family: 'Fraunces', serif; color: var(--amber-600); font-size: 0.9rem; font-weight: 700; }
.question .q-prompt { font-size: 1.03rem; font-weight: 600; color: var(--navy-900); margin: 6px 0 16px; line-height: 1.5; }
.choices { display: grid; gap: 8px; }
.choices label {
  display: flex; gap: 12px; align-items: start;
  padding: 12px 16px; border: 1px solid var(--line); border-radius: 8px;
  cursor: pointer; transition: background 0.12s ease, border-color 0.12s ease;
  background: #fdfdfb;
}
.choices label:hover { border-color: var(--navy-600); background: #fff; }
.choices input[type=radio] { margin-top: 4px; accent-color: var(--navy-700); }
.choices .letter { font-weight: 700; color: var(--navy-700); margin-right: 4px; }

/* result */
.q-result { padding: 22px; border-radius: var(--radius-md); margin: 0 0 18px; border: 1px solid var(--line); background: var(--bg-card); }
.q-result.correct { border-color: var(--green-600); background: #f0fdf4; }
.q-result.wrong { border-color: var(--red-600); background: #fff7ed; }
.q-result .badge {
  display: inline-block; padding: 3px 10px; border-radius: 999px;
  font-size: 0.75rem; font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase;
}
.badge-ok { background: var(--green-600); color: #fff; }
.badge-bad { background: var(--red-600); color: #fff; }
.q-result .why { margin-top: 10px; padding-top: 12px; border-top: 1px dashed var(--line); color: var(--ink-soft); font-size: 0.94rem; }
.q-result .why strong { color: var(--navy-900); }

.score-block {
  background: linear-gradient(135deg, var(--navy-900), var(--navy-700));
  color: #fff; padding: 40px; border-radius: var(--radius-lg); margin: 0 0 32px;
  display: flex; gap: 32px; align-items: center; flex-wrap: wrap;
}
.score-num { font-family: 'Fraunces', serif; font-size: 4rem; font-weight: 700; color: var(--amber-500); line-height: 1; }
.score-block h2 { color: #fff; margin: 0 0 6px; }
.score-block p { color: rgba(255,255,255,0.88); margin: 0; }

/* === FOOTER === */
.site-footer {
  background: var(--navy-900); color: rgba(255,255,255,0.78);
  padding: 56px 0 28px; margin-top: 80px; font-size: 0.9rem;
}
.site-footer h5 {
  font-size: 0.78rem; text-transform: uppercase; letter-spacing: 0.12em;
  color: var(--amber-500); margin: 0 0 14px; font-weight: 700;
  font-family: 'Inter', sans-serif;
}
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 48px; }
.site-footer ul { list-style: none; padding: 0; margin: 0; }
.site-footer li { margin: 0 0 8px; }
.site-footer a { color: rgba(255,255,255,0.85); }
.site-footer a:hover { color: var(--amber-500); }
.site-footer .brand { color: #fff; font-size: 1.2rem; }
.site-footer .brand small { color: rgba(255,255,255,0.55); }
.site-footer p { color: rgba(255,255,255,0.7); margin: 0 0 14px; max-width: 320px; line-height: 1.6; }
.footer-bottom { margin-top: 36px; padding-top: 22px; border-top: 1px solid rgba(255,255,255,0.12); display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; font-size: 0.82rem; color: rgba(255,255,255,0.55); }

/* === TABLES === */
.table-wrap { overflow-x: auto; margin: 16px 0; border: 1px solid var(--line); border-radius: var(--radius-md); }
table { width: 100%; border-collapse: collapse; }
th, td { text-align: left; padding: 10px 14px; border-bottom: 1px solid var(--line); font-size: 0.94rem; }
th { background: #fafaf6; color: var(--navy-900); font-weight: 600; }

/* === RESPONSIVE === */
@media (max-width: 900px) {
  .hero-grid, .grid-sidebar { grid-template-columns: 1fr; }
  .grid-3, .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .grid-5 { grid-template-columns: repeat(3, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .nav nav { gap: 14px; }
  .nav nav a { font-size: 0.88rem; }
  section { padding: 48px 0; }
  .sidebar { position: static; }
}
@media (max-width: 560px) {
  .grid-2, .grid-3, .grid-4, .grid-5 { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .hero-stats { gap: 20px; flex-wrap: wrap; }
  .nav { flex-wrap: wrap; gap: 12px; padding: 12px 0; }
  .nav nav { width: 100%; margin-left: 0; gap: 4px 14px; flex-wrap: wrap; justify-content: flex-start; padding-top: 4px; border-top: 1px solid var(--line); }
  .nav nav a { font-size: 0.82rem; padding: 6px 0; }
  .container { padding: 0 18px; }
  .hero { padding: 40px 0 56px; }
  .hero-card { padding: 22px; }
  .topic-hero { padding: 36px 0 44px; }
  .score-block { padding: 26px; gap: 18px; }
  .score-num { font-size: 3rem; }
  .footer-bottom { flex-direction: column; }
}
