:root {
  --ink: #1a1a2e;
  --muted: #5c5c5c;
  --paper: #f8f9fa;
  --white: #fff;
  --blue: #1565c0;
  --blue-dark: #0d47a1;
  --blue-light: #e3f2fd;
  --green: #2e7d32;
  --green-dark: #1b5e20;
  --green-light: #edf7ee;
  --purple: #5e35b1;
  --purple-dark: #4527a0;
  --purple-light: #f3e5f5;
  --amber: #fbbc04;
  --line: #e0e0e0;
  --radius: 24px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: "DM Sans", sans-serif;
  -webkit-font-smoothing: antialiased;
}
button, input { font: inherit; }
button { color: inherit; }
a { color: inherit; text-decoration: none; }

.site-header {
  height: 76px;
  padding: 0 clamp(24px, 6vw, 96px);
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: rgba(255, 255, 255, .92);
  border-bottom: 1px solid rgba(20, 39, 32, .07);
  position: sticky;
  top: 0;
  z-index: 10;
  backdrop-filter: blur(12px);
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font: 800 24px/1 "Manrope", sans-serif;
  letter-spacing: -.8px;
}
.brand-mark {
  width: 29px;
  height: 29px;
  display: grid;
  place-items: center;
  background: var(--green-dark);
  border-radius: 9px;
}
.brand-mark img { display: block; width: 72%; height: auto; }
nav { display: flex; gap: 34px; font-size: 14px; font-weight: 600; }
nav a:hover { opacity: .6; }
.header-actions { display: flex; align-items: center; gap: 12px; }
.language-control {
  min-height: 44px;
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: white;
}
.language-control select { border: 0; background: transparent; color: var(--ink); font-weight: 700; outline: 0; cursor: pointer; }
.button {
  border: 0;
  border-radius: 999px;
  padding: 15px 24px;
  font-weight: 700;
  cursor: pointer;
  transition: transform .2s, background .2s, opacity .2s;
}
.button:hover:not(:disabled) { transform: translateY(-2px); }
.button:disabled { cursor: not-allowed; opacity: .55; }
.button-small { padding: 11px 18px; font-size: 13px; }
.button-light, .button-primary { background: var(--blue); color: white; }
.button-primary { padding: 17px 25px; }
.button-primary:hover { background: var(--blue-dark); }
.button-dark { background: var(--ink); color: white; display: flex; justify-content: space-between; width: 100%; }
.button-iq, .button-math, .button-chc { color: white; display: flex; justify-content: space-between; width: 100%; }
.button-iq { background: var(--blue-dark); }
.button-math { background: var(--green-dark); }
.button-chc { background: var(--purple-dark); }
.button-outline { border: 1px solid var(--line); background: transparent; width: 100%; }

.hero {
  min-height: 620px;
  padding: 110px 24px 90px;
  text-align: center;
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  align-items: center;
  color: white;
  background: linear-gradient(180deg, #0a1f5c 0%, #1a4fa8 58%, #f0f5ff 100%);
}
.eyebrow, .kicker {
  text-transform: uppercase;
  letter-spacing: 1.8px;
  font-size: 11px;
  font-weight: 700;
}
.eyebrow { display: flex; align-items: center; gap: 9px; }
.eyebrow > span:first-child { width: 7px; height: 7px; border-radius: 50%; background: var(--amber); }
h1, h2, h3 { font-family: "Manrope", sans-serif; margin: 0; }
h1 { font-size: clamp(52px, 6.2vw, 90px); line-height: .98; letter-spacing: -5px; margin: 28px 0; }
h1 em { color: #bbdefb; font-style: normal; }
.hero-copy { max-width: 580px; font-size: 19px; line-height: 1.6; color: rgba(255,255,255,.82); margin: 0; }
.hero-actions { display: flex; align-items: center; gap: 26px; margin-top: 34px; }
.text-link { font-weight: 700; border-bottom: 1px solid white; padding-bottom: 4px; }
.hero-note { margin-top: 30px; display: flex; align-items: center; gap: 10px; color: rgba(255,255,255,.8); font-size: 13px; }
.hero-note i { width: 3px; height: 3px; background: #a8b0ab; border-radius: 50%; }
.hero-orbit { position: absolute; border: 1px solid rgba(255,255,255,.12); border-radius: 50%; pointer-events: none; }
.orbit-one { width: 680px; height: 680px; top: 28px; }
.orbit-two { width: 950px; height: 450px; top: 160px; }
.hero-symbol { position: absolute; font-size: 42px; color: rgba(255,255,255,.25); }
.symbol-one { left: 12%; top: 30%; transform: rotate(-12deg); }
.symbol-two { right: 14%; top: 25%; }
.symbol-three { right: 10%; bottom: 18%; transform: rotate(17deg); }
.hero > *:not(.hero-orbit):not(.hero-symbol) { position: relative; z-index: 1; }

.section { padding: 100px clamp(24px, 7vw, 110px); }
.tests-section { background: white; }
.section-heading { display: flex; justify-content: space-between; align-items: end; margin-bottom: 44px; gap: 30px; }
.section-heading h2, .how-section h2, .trust-section h2 { font-size: clamp(34px, 4vw, 56px); letter-spacing: -2.5px; line-height: 1.05; }
.section-heading > p { color: var(--muted); max-width: 380px; line-height: 1.6; }
.kicker { color: var(--blue); margin: 0 0 14px; }
.test-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.test-card { padding: 30px; border: 1px solid var(--line); border-radius: var(--radius); display: flex; flex-direction: column; min-height: 420px; }
.test-card.iq-card { background: var(--blue-light); border-color: #bbdefb; }
.test-card.math-card { background: var(--green-light); border-color: #c8e6c9; }
.test-card.chc-card { background: var(--purple-light); border-color: #e1bee7; }
.card-topline { display: flex; justify-content: space-between; align-items: center; margin-bottom: 45px; }
.card-icon { background: rgba(255,255,255,.75); width: 50px; height: 50px; border-radius: 15px; display: grid; place-items: center; font-size: 27px; }
.tag { background: white; border-radius: 999px; padding: 7px 11px; font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: .7px; }
.tag.muted { background: #f0f1ed; color: var(--muted); }
.test-card h3 { font-size: 25px; }
.test-card > p { color: var(--muted); line-height: 1.55; }
.test-card ul { display: flex; gap: 18px; padding: 0; margin: 14px 0 28px; list-style: none; font-size: 12px; font-weight: 600; }
.test-card li + li::before { content: "·"; margin-right: 18px; color: #99a39f; }
.test-card .button { margin-top: auto; }

.how-section { padding: 100px clamp(24px, 7vw, 110px); }
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px; margin-top: 55px; background: var(--line); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.steps > div { background: var(--paper); padding: 38px; min-height: 240px; }
.steps span { color: var(--blue); font-weight: 700; font-size: 12px; }
.steps h3 { font-size: 21px; margin: 48px 0 10px; }
.steps p { color: var(--muted); line-height: 1.6; margin: 0; }
.trust-section { background: var(--blue-dark); color: white; padding: 90px clamp(24px, 8vw, 130px); display: grid; grid-template-columns: 1fr 1fr; gap: 80px; }
.kicker.light { color: #bbdefb; }
.trust-copy { color: #c8d1cd; font-size: 18px; line-height: 1.65; }
.trust-points { display: grid; gap: 12px; margin-top: 30px; font-size: 14px; color: white; }
.trust-points span::first-letter { color: var(--amber); }
.app-promo {
  background: linear-gradient(135deg, var(--green-dark) 0%, #143d1c 100%);
  color: white;
  padding: 70px clamp(24px, 8vw, 130px);
  display: flex;
  align-items: center;
  gap: 40px;
  flex-wrap: wrap;
}
.app-promo-icon { font-size: 56px; flex: 0 0 auto; }
.app-promo > div:nth-child(2) { flex: 1; min-width: 240px; }
.app-promo h2 { font-size: clamp(28px, 3.4vw, 40px); letter-spacing: -1.6px; margin: 6px 0 10px; }
.app-promo p { color: rgba(255, 255, 255, .82); line-height: 1.6; max-width: 520px; margin: 0; }
.google-play-badge { flex: 0 0 auto; display: inline-block; }
.google-play-badge img { display: block; height: 62px; width: auto; }
footer { padding: 46px clamp(24px, 7vw, 110px); display: flex; justify-content: space-between; align-items: center; font-size: 12px; color: var(--muted); }
footer .brand { color: var(--ink); }

dialog { border: 0; padding: 0; }
dialog::backdrop { background: rgba(10, 31, 92, .72); backdrop-filter: blur(7px); }
.app-dialog { width: min(900px, calc(100% - 24px)); max-height: calc(100% - 24px); border-radius: 28px; background: var(--paper); overflow: hidden; }
.account-dialog { width: min(480px, calc(100% - 24px)); border-radius: 24px; background: white; padding: 38px; }
.dialog-close { position: absolute; top: 16px; right: 18px; width: 34px; height: 34px; border: 0; border-radius: 50%; font-size: 22px; cursor: pointer; }
.test-shell { height: min(720px, calc(100vh - 24px)); display: flex; flex-direction: column; overflow: hidden; }
.test-header { display: flex; align-items: center; gap: 14px; padding: 14px 20px; border-bottom: 1px solid var(--line); }
.test-header .brand { font-size: 20px; margin-right: auto; }
/* Static so it cannot sit on top of the timer like the dialog-level close button. */
.test-header .dialog-close { position: static; flex: 0 0 auto; background: #eef0ec; }
.test-timer { font-variant-numeric: tabular-nums; background: var(--blue-light); color: var(--blue-dark); padding: 7px 13px; border-radius: 999px; font-size: 14px; }
.test-body { flex: 1; min-height: 0; overflow-y: auto; display: flex; flex-direction: column; }
.test-footer { display: flex; justify-content: flex-end; gap: 12px; padding: 14px 20px; border-top: 1px solid var(--line); background: rgba(255, 255, 255, .92); }
.test-progress { height: 4px; background: #e5e8e2; }
.test-progress span { display: block; height: 100%; background: var(--blue); transition: width .3s; }
.question-panel { width: min(680px, 100%); margin: auto; padding: 22px 24px 18px; }
.question-meta { display: flex; justify-content: space-between; color: var(--muted); font-size: 13px; }
.question-panel h2 { font-size: clamp(20px, 2.6vw, 28px); letter-spacing: -.8px; margin: 12px 0 14px; line-height: 1.3; }
.question-image { display: block; max-width: 100%; max-height: min(240px, 30vh); margin: 0 auto 16px; object-fit: contain; background: white; border-radius: 16px; padding: 10px; }
.options { display: grid; gap: 10px; }
.options-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
/* Short answers pack into columns so a full option set fits without scrolling. */
.options-compact { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.options-tight { grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); }
.option { text-align: left; padding: 13px 16px; border: 1px solid var(--line); background: white; border-radius: 12px; cursor: pointer; display: flex; gap: 12px; align-items: center; }
.option.option-image { flex-direction: column; align-items: stretch; }
.option.option-image img { width: 100%; max-height: 120px; object-fit: contain; }
.option:hover, .option.selected { border-color: var(--blue); background: var(--blue-light); }
.option b { width: 28px; height: 28px; display: grid; place-items: center; border: 1px solid var(--line); border-radius: 50%; font-size: 12px; flex: 0 0 auto; }
.picker-panel { width: min(860px, 100%); margin: auto; padding: 36px 28px; }
.picker-panel h2 { font-size: clamp(28px, 4vw, 42px); letter-spacing: -1.6px; margin: 8px 0 12px; }
.picker-panel > p { color: var(--muted); line-height: 1.6; }
.picker-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; margin-top: 28px; }
.picker-card { background: white; border: 1px solid var(--line); border-radius: 20px; padding: 22px; text-align: left; }
.picker-card h3 { font-size: 22px; margin: 6px 0 8px; }
.picker-card p { color: var(--muted); margin: 0 0 16px; }
.paper-list { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.paper-locked { display: flex; justify-content: space-between; align-items: center; border-color: var(--amber); background: #fffbea; }
.payments-test-notice { background: #fffbea; border: 1px solid var(--amber); border-radius: 12px; padding: 10px 14px; font-size: 13px; font-weight: 600; margin: 4px 0 0; }
.intro-panel, .result-panel { text-align: center; width: min(620px, 100%); margin: auto; padding: 40px 28px; }
.intro-panel .brain, .result-score { width: 120px; height: 120px; display: grid; place-items: center; margin: 0 auto 28px; border-radius: 50%; background: var(--blue); color: white; font: 800 44px "Manrope"; }
.intro-panel h2, .result-panel h2 { font-size: 40px; letter-spacing: -2px; }
.intro-panel p, .result-panel p { color: var(--muted); line-height: 1.65; }
.intro-facts { display: flex; justify-content: center; gap: 28px; margin: 30px 0; font-size: 13px; font-weight: 700; }
.score-bars { display: grid; gap: 13px; text-align: left; margin: 30px 0; }
.score-bar { display: grid; grid-template-columns: 150px 1fr 40px; align-items: center; gap: 12px; font-size: 12px; font-weight: 600; }
.bar-track { height: 8px; border-radius: 99px; background: #e4e8df; overflow: hidden; }
.bar-track span { display: block; height: 100%; border-radius: 99px; background: var(--blue); }
.dialog-brand { margin-bottom: 22px; }
.account-dialog h2 { font-size: 32px; letter-spacing: -1.4px; }
.tabs { display: flex; gap: 8px; margin: 24px 0; }
.tab { border: 0; padding: 9px 14px; border-radius: 999px; cursor: pointer; background: #f0f2ee; }
.tab.active { background: var(--blue); color: white; }
.form { display: grid; gap: 13px; }
.form label { font-size: 12px; font-weight: 700; }
.form input { width: 100%; border: 1px solid var(--line); border-radius: 12px; padding: 14px; margin-top: 6px; }
.form .button { margin-top: 8px; }
.form-note { font-size: 12px; color: var(--muted); line-height: 1.5; }
.form-error { font-size: 13px; color: #d92d20; line-height: 1.5; }
.profile-results { margin-top: 24px; display: grid; gap: 10px; }
.result-row { background: var(--paper); padding: 15px; border-radius: 12px; display: flex; justify-content: space-between; }
#toast { position: fixed; bottom: 24px; left: 50%; transform: translate(-50%, 120px); background: var(--ink); color: white; padding: 12px 18px; border-radius: 999px; z-index: 50; transition: transform .25s; font-size: 13px; }
#toast.show { transform: translate(-50%, 0); }

.results-main { max-width: 820px; margin: 0 auto; padding: 56px clamp(20px, 6vw, 24px) 100px; display: grid; gap: 22px; }
.results-main h1 { font-size: clamp(30px, 4vw, 44px); letter-spacing: -1.6px; margin: 0; }
.account-subtitle { color: var(--muted); font-size: 15px; margin: 0; }
.account-subtitle b { color: var(--ink); }
.account-card { background: white; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.account-tabs { display: flex; gap: 4px; padding: 14px; border-bottom: 1px solid var(--line); flex-wrap: wrap; }
.account-tab { border: 0; background: transparent; padding: 10px 16px; border-radius: 999px; font-weight: 700; font-size: 14px; cursor: pointer; display: inline-flex; align-items: center; gap: 6px; }
.account-tab:hover { background: var(--paper); }
.account-tab.active { background: var(--blue); color: white; }
.account-tab.active:hover { background: var(--blue); }
.account-tab-body { padding: 30px clamp(20px, 4vw, 36px); }
.account-tab-body h3 { font-size: 24px; letter-spacing: -1px; margin: 0 0 8px; }
.account-tab-body > p.form-note { margin-bottom: 22px; }
.form-subheading { font-size: 15px; margin: 10px 0 2px; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 13px; }
.dob-selects { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: 6px; }
.dob-selects select { width: 100%; border: 1px solid var(--line); border-radius: 12px; padding: 12px; }
#password-form { margin-top: 14px; }
.account-actions { margin: 22px 0 0; }
.danger-zone { margin-top: 34px; padding-top: 24px; border-top: 1px solid var(--line); }
.danger-zone h4 { font-size: 14px; text-transform: uppercase; letter-spacing: .6px; color: #d92d20; margin: 0 0 8px; }
.delete-form { grid-template-columns: 1fr auto; grid-auto-flow: column; align-items: start; }
.delete-form input { margin: 0; }
.delete-button { background: #d92d20; color: white; }
.result-hero { background: var(--blue-light); border: 1px solid #bbdefb; border-radius: var(--radius); text-align: center; padding: 40px 28px; margin-bottom: 24px; }
.result-hero .kicker { color: var(--blue-dark); }
.result-hero h2 { font-size: 32px; letter-spacing: -1.4px; margin: 6px 0; }
.result-hero p { color: var(--muted); line-height: 1.6; }
.report-list { display: grid; gap: 14px; }
.report-card { border: 1px solid var(--line); border-radius: 16px; overflow: hidden; }
.report-card-head { padding: 14px 18px; border-bottom: 1px solid var(--line); background: var(--paper); }
.report-card-head h4 { margin: 0; font-size: 15px; }
.report-card-row { display: flex; justify-content: space-between; align-items: center; padding: 14px 18px; font-size: 13px; color: var(--muted); }
.report-card-detail { padding: 4px 18px 18px; }
.results-signin-note { text-align: center; margin: -6px 0 4px; }
.auth-card { padding: 30px clamp(20px, 4vw, 36px); }

.stat-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 14px; }
.stat-grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; }
.stat-tile { background: white; border: 1px solid var(--line); border-radius: 16px; padding: 18px; display: grid; gap: 6px; }
.stat-label { font-size: 12px; color: var(--muted); font-weight: 700; text-transform: uppercase; letter-spacing: .4px; }
.stat-value { font-size: 26px; font-family: "Manrope", sans-serif; letter-spacing: -1px; }
.bar-rows { display: grid; gap: 10px; }
.bar-row { display: grid; grid-template-columns: 120px 1fr 40px; align-items: center; gap: 12px; font-size: 13px; }
.bar-row-label { color: var(--muted); text-transform: capitalize; }
.bar-row-track { height: 10px; border-radius: 99px; background: #eef0ec; overflow: hidden; }
.bar-row-track span { display: block; height: 100%; border-radius: 99px; background: var(--blue); }
.daily-chart { display: flex; align-items: flex-end; gap: 6px; height: 140px; padding-top: 10px; }
.daily-bar { flex: 1; height: 100%; display: flex; flex-direction: column; justify-content: flex-end; align-items: center; gap: 6px; }
.daily-bar-fill { display: block; width: 100%; max-width: 22px; border-radius: 6px 6px 0 0; background: var(--blue); min-height: 2px; }
.daily-bar label { font-size: 10px; color: var(--muted); }
.analytics-table { width: 100%; border-collapse: collapse; font-size: 12px; }
.analytics-table th { text-align: left; color: var(--muted); font-weight: 700; padding: 8px 10px; border-bottom: 1px solid var(--line); white-space: nowrap; }
.analytics-table td { padding: 8px 10px; border-bottom: 1px solid var(--line); white-space: nowrap; max-width: 240px; overflow: hidden; text-overflow: ellipsis; }
.table-scroll { overflow-x: auto; }
.event-pill { background: var(--blue-light); color: var(--blue-dark); border-radius: 999px; padding: 3px 9px; font-weight: 700; font-size: 11px; }
.admin-link { color: var(--blue); font-size: 13px; }
.kangaroo-main { max-width: 900px; margin: 0 auto; padding: 56px clamp(20px, 6vw, 24px) 100px; display: grid; gap: 28px; }
.kangaroo-hero { text-align: center; }
.kangaroo-hero h1 { font-size: clamp(32px, 4.5vw, 52px); letter-spacing: -2px; margin: 6px 0 10px; }
.kangaroo-subtitle { color: var(--muted); font-weight: 700; margin: 0 0 14px; }
.kangaroo-hero p:not(.kangaroo-subtitle) { color: var(--muted); line-height: 1.6; max-width: 640px; margin: 10px auto; }
.kangaroo-skills { text-align: left; max-width: 640px; margin: 14px auto; padding: 0; list-style: none; display: grid; gap: 10px; }
.kangaroo-skills li { color: var(--muted); line-height: 1.6; padding-left: 22px; position: relative; }
.kangaroo-skills li::before { content: "✓"; position: absolute; left: 0; color: var(--green-dark); font-weight: 700; }
.kangaroo-tiers { padding: 0; list-style: none; display: grid; gap: 10px; margin: 12px 0; }
.kangaroo-tiers li { color: var(--muted); line-height: 1.6; }
.scoring-edition-note { background: #fffbea; border: 1px solid var(--amber); border-radius: 12px; padding: 12px 14px; font-size: 14px; }
.kangaroo-scoring .account-tab-body h3 { margin-bottom: 10px; }
.kangaroo-scoring .account-tab-body p { color: var(--muted); line-height: 1.6; margin: 8px 0; }
.kangaroo-levels h2 { font-size: 26px; letter-spacing: -1px; margin: 0 0 16px; }
.level-card { cursor: pointer; text-align: left; }
.level-card button { margin-top: 14px; width: 100%; pointer-events: none; }
.paper-list-solo { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; margin-top: 22px; }
.bot-note { margin: -4px 0 4px; }
.bot-pill { border-radius: 999px; padding: 3px 9px; font-weight: 700; font-size: 11px; white-space: nowrap; }
.bot-pill-verified { background: var(--blue-light); color: var(--blue-dark); }
.bot-pill-likely { background: #fdecea; color: #d92d20; }
.bot-pill-human { background: var(--green-light); color: var(--green-dark); }
.bot-pill-unknown { background: #f0f1ed; color: var(--muted); }

@media (max-width: 800px) {
  .stat-grid { grid-template-columns: 1fr 1fr; }
  .stat-grid-2 { grid-template-columns: 1fr; }
  .results-header { flex-direction: column; }
  .results-main { padding: 40px 18px 80px; }
  nav { display: none; }
  .site-header { padding: 0 18px; }
  .language-control { padding: 0 8px; }
  .hero { padding-top: 75px; min-height: 570px; }
  h1 { letter-spacing: -3px; }
  .hero-symbol { display: none; }
  .section-heading, footer { align-items: flex-start; flex-direction: column; }
  .app-promo { flex-direction: column; text-align: center; padding: 50px 24px; }
  .app-promo p { max-width: none; }
  .test-grid, .steps, .trust-section, .picker-grid, .options-compact { grid-template-columns: 1fr; }
  .test-shell { height: calc(100vh - 24px); }
  .test-header, .test-footer { padding: 12px 14px; }
  .test-footer .button { flex: 1; }
  .question-panel { padding: 18px 16px 14px; }
  .trust-section { gap: 38px; }
  .steps > div { min-height: 190px; }
  .steps h3 { margin-top: 28px; }
  .test-card { min-height: 380px; }
  footer { gap: 18px; }
  .score-bar { grid-template-columns: 110px 1fr 34px; }
}
