/* =========================================================
   StudyCitizenship.ca — stylesheet
   Canadian-themed, IRCC-inspired, modern & responsive.
   ========================================================= */

:root {
  --navy: #0b3d6b;         /* primary brand — Canadian navy */
  --navy-dark: #082c4d;
  --navy-soft: #e9f0f7;
  --red: #D52B1E;          /* maple-leaf red — accent + error states */
  --red-dark: #A91B12;
  --red-soft: #fbeceb;
  --ink: #1b1b1b;
  --slate: #4a4f54;
  --muted: #6b7280;
  --line: #e4e7eb;
  --bg: #ffffff;
  --bg-alt: #f6f7f9;
  --bg-dark: #2b2f33;
  --green: #1a7f4b;
  --green-soft: #e6f4ec;
  --amber: #b7791f;
  --radius: 14px;
  --radius-sm: 9px;
  --shadow-sm: 0 1px 2px rgba(16,24,40,.06), 0 1px 3px rgba(16,24,40,.10);
  --shadow: 0 8px 24px rgba(16,24,40,.10);
  --shadow-lg: 0 20px 50px rgba(16,24,40,.16);
  --maxw: 1140px;
  --font: 'Lato', system-ui, -apple-system, 'Segoe UI', Roboto, Arial, sans-serif;
  --serif: 'Noto Serif', Georgia, 'Times New Roman', serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.65;
  font-size: 17px;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--navy); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3 { font-family: var(--serif); line-height: 1.2; color: var(--ink); font-weight: 700; }
h1 { font-size: clamp(2rem, 4.5vw, 3.1rem); margin: 0 0 .5em; }
h2 { font-size: clamp(1.5rem, 3vw, 2.1rem); margin: 0 0 .5em; }
h3 { font-size: 1.2rem; margin: 0 0 .4em; }
p { margin: 0 0 1rem; }

.container { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 20px; }
.narrow { max-width: 760px; }
.center { text-align: center; }
.muted { color: var(--muted); }
.skip-link {
  position: absolute; left: -999px; top: 0; background: var(--ink); color: #fff;
  padding: 10px 16px; z-index: 1000; border-radius: 0 0 8px 0;
}
.skip-link:focus { left: 0; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
  font-weight: 700; font-family: var(--font); font-size: 1rem;
  padding: .72rem 1.4rem; border-radius: 999px; border: 2px solid transparent;
  cursor: pointer; transition: transform .08s ease, background .15s ease, box-shadow .15s ease;
  text-decoration: none; line-height: 1.1; white-space: nowrap;
}
.btn:hover { text-decoration: none; transform: translateY(-1px); }
.btn:active { transform: translateY(0); }
.btn-primary { background: var(--navy); color: #fff; box-shadow: var(--shadow-sm); }
.btn-primary:hover { background: var(--navy-dark); color: #fff; }
.btn-outline { background: #fff; color: var(--navy); border-color: var(--navy); }
.btn-outline:hover { background: var(--navy-soft); color: var(--navy-dark); }
.btn-ghost { background: transparent; color: var(--ink); border-color: var(--line); }
.btn-ghost:hover { background: var(--bg-alt); color: var(--ink); }
.btn-light { background: #fff; color: var(--navy); }
.btn-light:hover { background: #f3f4f6; color: var(--navy-dark); }
.btn-lg { padding: .95rem 1.9rem; font-size: 1.08rem; }
.btn-sm { padding: .45rem .95rem; font-size: .9rem; }
.btn-block { display: flex; width: 100%; }

/* ---------- Header / nav ---------- */
.site-header { position: sticky; top: 0; z-index: 100; background: #fff; box-shadow: var(--shadow-sm); }
.topbar { background: var(--ink); color: #d9dce0; font-size: .8rem; }
.topbar-inner { display: flex; justify-content: space-between; align-items: center; min-height: 34px; gap: 1rem; }
.topbar-note { opacity: .85; }
.topbar-user { font-weight: 700; color: #fff; }
.navbar { display: flex; align-items: center; justify-content: space-between; gap: 1rem; min-height: 72px; }
.brand { display: inline-flex; align-items: center; gap: .6rem; text-decoration: none; }
.brand-logo, .brand img { width: 40px; height: 40px; }
.brand-text { display: flex; flex-direction: column; line-height: 1; }
.brand-text strong { font-family: var(--serif); font-size: 1.18rem; color: var(--ink); }
.brand-text small { font-size: .72rem; letter-spacing: .14em; text-transform: uppercase; color: var(--navy); font-weight: 700; }
.brand:hover { text-decoration: none; }

.nav-menu { display: flex; align-items: center; gap: .35rem; list-style: none; margin: 0; padding: 0; }
.nav-menu a:not(.btn) {
  color: var(--slate); font-weight: 700; padding: .55rem .8rem; border-radius: 8px; display: inline-block;
}
.nav-menu a:not(.btn):hover { color: var(--navy); background: var(--navy-soft); text-decoration: none; }
.nav-menu a.active { color: var(--navy); }
.nav-cta { margin-left: .4rem; }
.nav-toggle { display: none; flex-direction: column; gap: 5px; background: none; border: 0; cursor: pointer; padding: 8px; }
.nav-toggle span { width: 26px; height: 3px; background: var(--ink); border-radius: 3px; transition: .25s; }

/* ---------- Alerts ---------- */
.alert { padding: .9rem 1.1rem; border-radius: var(--radius-sm); margin: 1rem 0; border: 1px solid transparent; }
.alert-success { background: var(--green-soft); border-color: #b7e0c6; color: #145c37; }
.alert-error { background: var(--red-soft); border-color: #f3c0bc; color: var(--red-dark); }
.alert p { margin: .35rem 0 0; }

/* ---------- Hero ---------- */
.hero { background:
    radial-gradient(1200px 500px at 110% -10%, rgba(11,61,107,.10), transparent 60%),
    linear-gradient(180deg, #fff 0%, var(--bg-alt) 100%);
  padding: clamp(2.5rem, 6vw, 5rem) 0; border-bottom: 1px solid var(--line); }
.hero-inner { display: grid; grid-template-columns: 1.1fr .9fr; gap: 3rem; align-items: center; }
.eyebrow { display: inline-block; font-weight: 700; letter-spacing: .04em; color: var(--navy);
  background: var(--navy-soft); padding: .35rem .8rem; border-radius: 999px; font-size: .85rem; margin-bottom: 1rem; }
.hero-copy .lead, .lead { font-size: 1.2rem; color: var(--slate); }
.hero-actions { display: flex; flex-wrap: wrap; gap: .8rem; margin: 1.6rem 0 1.2rem; }
.hero-actions.center { justify-content: center; }
.hero-trust { list-style: none; display: flex; flex-wrap: wrap; gap: 1.2rem; padding: 0; margin: 0; color: var(--slate); font-weight: 700; font-size: .95rem; }

.hero-card { display: flex; justify-content: center; }
.exam-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow-lg);
  padding: 1.4rem; width: 100%; max-width: 380px; transform: rotate(1.2deg); }
.exam-card-head { display: flex; align-items: center; gap: .5rem; font-weight: 700; color: var(--navy); font-size: .85rem; text-transform: uppercase; letter-spacing: .08em; }
.exam-card-head .dot { width: 10px; height: 10px; border-radius: 50%; background: var(--navy); }
.exam-q { font-family: var(--serif); font-size: 1.15rem; margin: .8rem 0 1rem; }
.exam-opts { list-style: none; padding: 0; margin: 0; display: grid; gap: .5rem; }
.exam-opts li { border: 1.5px solid var(--line); border-radius: 9px; padding: .6rem .8rem; font-size: .95rem; }
.exam-opts li.correct { border-color: var(--green); background: var(--green-soft); color: #145c37; font-weight: 700; }
.exam-card-foot { display: flex; justify-content: space-between; margin-top: 1rem; color: var(--muted); font-size: .82rem; }

/* ---------- Sections ---------- */
.section { padding: clamp(2.5rem, 5vw, 4.5rem) 0; }
.section--alt { background: var(--bg-alt); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.section-head { text-align: center; max-width: 680px; margin: 0 auto 2.5rem; }
.section-head p { color: var(--slate); font-size: 1.1rem; }

.feature-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.4rem; }
.feature { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 1.6rem; box-shadow: var(--shadow-sm); transition: transform .15s, box-shadow .15s; }
.feature:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.feature-icon { font-size: 2rem; }
.feature h3 { margin-top: .6rem; }
.feature p { color: var(--slate); margin: 0; font-size: .97rem; }

/* ---------- Steps ---------- */
.step-list { list-style: none; counter-reset: step; padding: 0; margin: 0 0 2rem; display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.5rem; }
.step-list li { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 1.6rem; position: relative; }
.step-num { display: inline-flex; align-items: center; justify-content: center; width: 42px; height: 42px; border-radius: 50%; background: var(--navy); color: #fff; font-weight: 900; font-size: 1.2rem; margin-bottom: .7rem; }
.step-list p { color: var(--slate); margin: 0; }

/* ---------- FAQ ---------- */
.faq { max-width: 780px; margin: 0 auto; }
.faq-item { background: #fff; border: 1px solid var(--line); border-radius: var(--radius-sm); margin-bottom: .8rem; padding: 0 1.2rem; }
.faq-item summary { cursor: pointer; font-weight: 700; padding: 1rem 0; list-style: none; position: relative; padding-right: 2rem; }
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after { content: '+'; position: absolute; right: 0; top: 50%; transform: translateY(-50%); font-size: 1.4rem; color: var(--navy); }
.faq-item[open] summary::after { content: '−'; }
.faq-item p { color: var(--slate); padding-bottom: 1rem; margin: 0; }

/* ---------- CTA band ---------- */
.cta-band { background: linear-gradient(135deg, var(--navy), var(--navy-dark)); color: #fff; padding: clamp(2.5rem, 5vw, 4rem) 0; }
.cta-inner { text-align: center; }
.cta-band h2 { color: #fff; }
.cta-band p { color: rgba(255,255,255,.9); font-size: 1.15rem; }

/* ---------- Page head ---------- */
.page-head { background: var(--bg-alt); border-bottom: 1px solid var(--line); padding: clamp(2rem, 4vw, 3rem) 0; }
.page-head .lead { max-width: 720px; }

/* ---------- Auth ---------- */
.auth-section { padding: clamp(2rem, 5vw, 4rem) 0; background: var(--bg-alt); min-height: 70vh; display: flex; align-items: center; }
.auth-wrap { display: flex; justify-content: center; }
.auth-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 2.2rem; width: 100%; max-width: 460px; }
.auth-alt { text-align: center; margin: 1.2rem 0 0; color: var(--slate); }

/* ---------- Forms ---------- */
.form .field { margin-bottom: 1.1rem; }
.field label { display: block; font-weight: 700; margin-bottom: .35rem; font-size: .95rem; }
.field input, .field textarea, .field select {
  width: 100%; padding: .75rem .9rem; border: 1.6px solid var(--line); border-radius: var(--radius-sm);
  font: inherit; color: var(--ink); background: #fff; transition: border-color .15s, box-shadow .15s;
}
.field input:focus, .field textarea:focus {
  outline: none; border-color: var(--navy); box-shadow: 0 0 0 3px var(--navy-soft);
}
.field-error { color: var(--red-dark); font-size: .85rem; margin-top: .3rem; display: block; }

/* ---------- Course / chapters ---------- */
.chapter-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.5rem; }
.chapter-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 1.5rem; display: flex; flex-direction: column; box-shadow: var(--shadow-sm); transition: transform .15s, box-shadow .15s; }
.chapter-card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.chapter-card.is-locked { background: #fcfcfd; }
.chapter-top { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: .6rem; }
.chapter-icon { font-size: 2rem; }
.chapter-title { font-size: 1.18rem; }
.chapter-summary { color: var(--slate); flex: 1; font-size: .97rem; }
.chapter-meta { display: flex; gap: 1rem; color: var(--muted); font-size: .85rem; margin: .6rem 0 1rem; }
.badge { font-size: .72rem; font-weight: 700; padding: .25rem .6rem; border-radius: 999px; text-transform: uppercase; letter-spacing: .04em; }
.badge-free { background: var(--green-soft); color: #145c37; }
.badge-lock { background: #fff3df; color: var(--amber); }
.badge-open { background: var(--navy-soft); color: var(--navy-dark); }

/* ---------- Lesson ---------- */
.lesson { padding: 2.5rem 0; }
.lesson-layout { display: grid; grid-template-columns: 260px 1fr; gap: 2.5rem; align-items: start; }
.lesson-toc { position: sticky; top: 96px; background: var(--bg-alt); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.3rem; }
.back-link { font-weight: 700; font-size: .9rem; display: inline-block; margin-bottom: 1rem; }
.toc-title { font-family: var(--font); font-size: .8rem; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); }
.toc-list { padding-left: 1.1rem; margin: .5rem 0 1.2rem; }
.toc-list li { margin-bottom: .4rem; }
.toc-list a { color: var(--slate); font-size: .95rem; }
.lesson-body { max-width: 760px; }
.lesson-section { padding: 1.2rem 0; border-top: 1px solid var(--line); }
.lesson-section:first-of-type { border-top: 0; }
.lesson-body h2 { margin-top: .4rem; }
.lesson-body ul, .lesson-body ol { padding-left: 1.3rem; }
.lesson-body li { margin-bottom: .4rem; }
.lesson-nav { display: flex; justify-content: space-between; gap: 1rem; margin-top: 2rem; padding-top: 1.5rem; border-top: 1px solid var(--line); }
.lesson-nav a { font-weight: 700; max-width: 48%; }

/* ---------- Pricing ---------- */
.price-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 380px)); gap: 1.8rem; justify-content: center; margin-bottom: 2rem; }
.price-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 2rem; box-shadow: var(--shadow-sm); position: relative; }
.price-card--featured { border: 2px solid var(--navy); box-shadow: var(--shadow); }
.price-badge { position: absolute; top: -14px; left: 50%; transform: translateX(-50%); background: var(--navy); color: #fff; font-size: .78rem; font-weight: 700; padding: .3rem .9rem; border-radius: 999px; text-transform: uppercase; letter-spacing: .05em; }
.price { font-family: var(--serif); margin: .4rem 0 1rem; }
.price span { font-size: 2.8rem; font-weight: 700; }
.price small { color: var(--muted); font-family: var(--font); font-size: 1rem; }
.price-features { list-style: none; padding: 0; margin: 0 0 1.5rem; }
.price-features li { padding: .45rem 0; border-bottom: 1px solid var(--line); font-size: .97rem; }
.price-features li.muted { color: var(--muted); }
.price-fine { font-size: .82rem; color: var(--muted); text-align: center; margin: .8rem 0 0; }

/* ---------- Dashboard ---------- */
.upgrade-banner { background: linear-gradient(135deg, var(--navy), var(--navy-dark)); color: #fff; border-radius: var(--radius); padding: 1.6rem 1.8rem; display: flex; align-items: center; justify-content: space-between; gap: 1.5rem; flex-wrap: wrap; margin-bottom: 2rem; }
.upgrade-banner h2 { color: #fff; margin: 0; }
.upgrade-banner p { margin: .3rem 0 0; color: rgba(255,255,255,.9); }
.stat-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.2rem; margin-bottom: 2rem; }
.stat { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 1.3rem; text-align: center; box-shadow: var(--shadow-sm); }
.stat-num { display: block; font-family: var(--serif); font-size: 2rem; font-weight: 700; color: var(--navy); }
.stat-label { color: var(--muted); font-size: .85rem; }
.dash-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1.8rem; }
.dash-col { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 1.6rem; }
.dash-list { list-style: none; padding: 0; margin: 0 0 1rem; }
.dash-list li { display: flex; justify-content: space-between; align-items: center; gap: 1rem; padding: .7rem 0; border-bottom: 1px solid var(--line); }
.dash-table { width: 100%; border-collapse: collapse; margin-bottom: 1rem; }
.dash-table th, .dash-table td { text-align: left; padding: .6rem .4rem; border-bottom: 1px solid var(--line); font-size: .92rem; }
.dash-table th { color: var(--muted); font-size: .8rem; text-transform: uppercase; letter-spacing: .04em; }
.dash-account { margin-top: 1.5rem; }
.pill { font-size: .75rem; font-weight: 700; padding: .2rem .6rem; border-radius: 999px; }
.pill-pass { background: var(--green-soft); color: #145c37; }
.pill-fail { background: var(--red-soft); color: var(--red-dark); }

/* ---------- Test ---------- */
.test-layout { display: grid; grid-template-columns: 1fr 280px; gap: 2rem; align-items: start; }
.qcard { border: 1px solid var(--line); border-radius: var(--radius); padding: 1.4rem 1.5rem; margin: 0 0 1.3rem; background: #fff; box-shadow: var(--shadow-sm); }
.qcard legend { font-family: var(--serif); font-size: 1.12rem; font-weight: 700; padding: 0; margin-bottom: .9rem; display: flex; gap: .6rem; align-items: baseline; }
.qnum { background: var(--navy-soft); color: var(--navy-dark); font-family: var(--font); font-size: .8rem; font-weight: 700; padding: .15rem .55rem; border-radius: 6px; }
.opt { display: flex; align-items: center; gap: .7rem; border: 1.6px solid var(--line); border-radius: var(--radius-sm); padding: .7rem .9rem; margin-bottom: .6rem; cursor: pointer; transition: border-color .12s, background .12s; }
.opt:hover { border-color: var(--navy); background: var(--navy-soft); }
.opt input { accent-color: var(--navy); width: 18px; height: 18px; }
.opt:has(input:checked) { border-color: var(--navy); background: var(--navy-soft); font-weight: 700; }
.test-aside { position: sticky; top: 96px; display: grid; gap: 1rem; }
.timer-box, .progress-box { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 1.1rem; text-align: center; box-shadow: var(--shadow-sm); }
.timer-label, .progress-label { display: block; font-size: .8rem; color: var(--muted); text-transform: uppercase; letter-spacing: .05em; }
.timer { font-family: var(--serif); font-size: 2rem; font-weight: 700; color: var(--ink); }
.timer.warning { color: var(--navy); }
.progress-bar { height: 10px; background: var(--bg-alt); border-radius: 999px; overflow: hidden; margin-top: .6rem; }
.progress-fill { height: 100%; width: 0; background: var(--green); transition: width .3s; }

/* ---------- Results ---------- */
.result-score { text-align: center; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 2rem; box-shadow: var(--shadow-sm); margin-bottom: 2rem; }
.result-ring { --pct: 0; width: 150px; height: 150px; border-radius: 50%; margin: 0 auto 1rem; display: grid; place-items: center;
  background: conic-gradient(var(--green) calc(var(--pct) * 1%), var(--bg-alt) 0); }
.result-score.is-fail .result-ring { background: conic-gradient(var(--red) calc(var(--pct) * 1%), var(--bg-alt) 0); }
.result-ring span { width: 116px; height: 116px; background: #fff; border-radius: 50%; display: grid; place-items: center; font-family: var(--serif); font-size: 1.8rem; font-weight: 700; }
.result-actions { display: flex; flex-wrap: wrap; gap: .7rem; justify-content: center; margin-top: 1rem; }
.review-title { margin: 1.5rem 0 1rem; }
.review-list { list-style: none; padding: 0; counter-reset: r; }
.review-item { background: #fff; border: 1px solid var(--line); border-left: 5px solid var(--green); border-radius: var(--radius); padding: 1.3rem; margin-bottom: 1rem; }
.review-item.no { border-left-color: var(--red); }
.review-q { font-family: var(--serif); font-weight: 700; font-size: 1.08rem; }
.review-opts { list-style: none; padding: 0; margin: .7rem 0; }
.review-opts li { padding: .5rem .8rem; border-radius: 8px; margin-bottom: .35rem; border: 1px solid var(--line); }
.opt-correct { background: var(--green-soft); border-color: #b7e0c6 !important; color: #145c37; font-weight: 700; }
.opt-wrong { background: var(--red-soft); border-color: #f3c0bc !important; color: var(--red-dark); }
.tag { font-size: .72rem; font-weight: 700; }
.tag-bad { color: var(--red-dark); }
.review-exp { font-size: .92rem; color: var(--slate); background: var(--bg-alt); padding: .7rem .9rem; border-radius: 8px; margin: .5rem 0 0; }

/* ---------- Account ---------- */
.account-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 1.6rem; margin-bottom: 1.4rem; box-shadow: var(--shadow-sm); }
.kv { display: grid; grid-template-columns: 160px 1fr; gap: .5rem 1rem; margin: 0; }
.kv dt { color: var(--muted); font-weight: 700; }
.kv dd { margin: 0; }

/* ---------- Misc ---------- */
.success-mark, .big-emoji { font-size: 3.5rem; }
.prose h2 { margin-top: 1.8rem; }
.prose li { margin-bottom: .4rem; }

/* ---------- Footer ---------- */
.site-footer { background: var(--bg-dark); color: #c9cdd2; margin-top: 0; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1.3fr; gap: 2rem; padding: 3rem 20px; }
.footer-col h3 { color: #fff; font-family: var(--font); font-size: .85rem; text-transform: uppercase; letter-spacing: .08em; margin-bottom: .9rem; }
.footer-col ul { list-style: none; padding: 0; margin: 0; }
.footer-col li { margin-bottom: .5rem; }
.footer-col a { color: #c9cdd2; font-size: .95rem; }
.footer-col a:hover { color: #fff; }
.footer-brand p { color: #9aa0a6; font-size: .92rem; margin-top: .8rem; }
.brand--footer .brand-text strong { color: #fff; }
.brand--footer .brand-text small { color: #ff8c82; }
.footer-disclaimer { background: #1f2226; border-top: 1px solid #34383d; }
.footer-disclaimer .container { padding-top: 1.4rem; padding-bottom: 1.4rem; }
.footer-disclaimer p { font-size: .82rem; color: #9aa0a6; margin: 0 0 .5rem; }
.footer-disclaimer a { color: #c9cdd2; text-decoration: underline; }
.copyright { color: #7a8086 !important; }

/* ---------- Responsive ---------- */
@media (max-width: 960px) {
  .hero-inner { grid-template-columns: 1fr; }
  .hero-card { order: -1; }
  .feature-grid { grid-template-columns: repeat(2, 1fr); }
  .chapter-grid { grid-template-columns: repeat(2, 1fr); }
  .step-list { grid-template-columns: 1fr; }
  .lesson-layout { grid-template-columns: 1fr; }
  .lesson-toc { position: static; }
  .test-layout { grid-template-columns: 1fr; }
  .test-aside { position: static; grid-template-columns: 1fr 1fr; display: grid; }
  .dash-grid { grid-template-columns: 1fr; }
  .stat-grid { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 720px) {
  body { font-size: 16px; }
  .nav-toggle { display: flex; }
  .nav-menu {
    position: fixed; inset: 0 0 0 auto; width: min(80vw, 320px); background: #fff;
    flex-direction: column; align-items: stretch; gap: .2rem; padding: 5rem 1.3rem 2rem;
    box-shadow: var(--shadow-lg); transform: translateX(100%); transition: transform .25s ease; z-index: 90;
  }
  .nav-menu.open { transform: translateX(0); }
  .nav-menu li { width: 100%; }
  .nav-menu a:not(.btn) { display: block; }
  .nav-cta { margin: .4rem 0 0; }
  .nav-toggle.open span:nth-child(1) { transform: translateY(8px) rotate(45deg); }
  .nav-toggle.open span:nth-child(2) { opacity: 0; }
  .nav-toggle.open span:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }
  .topbar-note { font-size: .72rem; }
  .price-grid { grid-template-columns: 1fr; }
  .feature-grid, .chapter-grid, .stat-grid, .footer-grid { grid-template-columns: 1fr; }
  .kv { grid-template-columns: 1fr; }
  .kv dt { margin-top: .5rem; }
}

@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; scroll-behavior: auto !important; }
}


/* ---------- Language switcher ---------- */
.nav-lang{display:flex;align-items:center}
.lang-switch{position:relative}
.lang-switch summary{list-style:none;cursor:pointer;padding:.5rem .7rem;border:1.5px solid var(--line);border-radius:8px;font-weight:700;font-size:.9rem;color:var(--slate);display:flex;align-items:center;gap:.35rem;white-space:nowrap}
.lang-switch summary::-webkit-details-marker{display:none}
.lang-switch[open] summary{border-color:var(--navy)}
.lang-menu{position:absolute;top:calc(100% + 6px);right:0;background:#fff;border:1px solid var(--line);border-radius:10px;box-shadow:var(--shadow);list-style:none;padding:.4rem;margin:0;min-width:200px;z-index:60}
.lang-menu li{margin:0}
.lang-menu a{display:flex;justify-content:space-between;gap:.6rem;padding:.5rem .7rem;border-radius:7px;color:var(--ink);font-weight:700;font-size:.92rem}
.lang-menu a:hover{background:var(--bg-alt);text-decoration:none}
.lang-menu a.active{background:var(--navy-soft);color:var(--navy)}
.lang-menu a small{color:var(--muted);font-weight:400}
/* ---------- RTL ---------- */
body.rtl{direction:rtl}
body.rtl .lang-menu{right:auto;left:0}
body.rtl .hero-actions,body.rtl .hero-trust,body.rtl .result-actions{justify-content:flex-start}
body.rtl .review-item{border-left:none;border-right:5px solid var(--green)}
body.rtl .review-item.no{border-right-color:var(--red)}
body.rtl .faq-item summary{padding-right:0;padding-left:2rem}
body.rtl .faq-item summary::after{right:auto;left:0}
@media(max-width:720px){ body.rtl .nav-menu{inset:0 auto 0 0;transform:translateX(-100%)} body.rtl .nav-menu.open{transform:translateX(0)} }
/* ---------- One-time price ---------- */
.price-old{ text-decoration: line-through; color: var(--muted); font-size:1.7rem; font-weight:700; margin-inline-end:.4rem; font-family: var(--serif); }
.price-note{ font-size:.9rem; color: var(--slate); background: var(--navy-soft); border-radius:8px; padding:.55rem .8rem; margin:.2rem 0 1.1rem; }
