:root {
  --bg: #f8fafc;
  --bg-alt: #ffffff;
  --card: #ffffff;
  --ink: #0f172a;
  --muted: #4b5563;
  --accent: #0f62fe;
  --accent-2: #0ea05a;
  --danger: #ef4444;
  --border: #e5e7eb;
  --accent-soft: #e8f0ff;
  --radius: 18px;
  --shadow: 0 12px 32px rgba(0, 0, 0, 0.08);
  --font-display: 'Inter', system-ui, -apple-system, sans-serif;
  --font-body: 'Inter', system-ui, -apple-system, sans-serif;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html, body {
  max-width: 100vw;
  overflow-x: hidden;
}

body {
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--ink);
  line-height: 1.7;
  font-size: 1.44rem;
  min-height: 100vh;
  padding: 0;
}

main {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 5vw;
}

a {
  color: var(--ink);
  text-decoration: none;
}

a:hover {
  color: var(--accent);
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.4rem 5vw;
  background: #ffffff;
  border-bottom: 1px solid var(--border);
  box-shadow: var(--shadow);
  width: 100%;
}

.topbar::after {
  display: none;
}

.logo {
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: 0.5px;
}

.logo.brand {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.logo-mark {
  height: 68px;
  width: auto;
  background: rgba(255, 255, 255, 0.06);
  border-radius: 10px;
  padding: 4px;
}

.brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1.1;
}

.brand-name {
  font-weight: 700;
  font-size: 2.7rem;
  white-space: nowrap;
}



.nav {
  display: flex;
  align-items: center;
  gap: 0.9rem;
  font-size: 1.2em;
  color: var(--ink);
}

.nav-login {
  padding: 0.5rem 1rem;
  border-radius: 999px;
  font-weight: 700;
  background: transparent;
  color: var(--accent);
  border: 1px solid var(--accent);
  box-shadow: none;
}

.nav-login:hover {
  transform: translateY(-1px);
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
  box-shadow: 0 10px 24px rgba(15, 98, 254, 0.18);
}

.logout-btn {
  /* Use the same visual style as nav-login */
}

.nav > a,
.nav-item > a {
  padding: 0.3rem 0.1rem;
  border-radius: 6px;
  color: var(--ink);
  font-weight: 600;
  white-space: nowrap;
  transition: background 150ms ease, color 150ms ease, transform 150ms ease, box-shadow 150ms ease;
}

.nav > a:hover,
.nav-item > a:hover {
  background: #f2f5f9;
  color: var(--accent);
  transform: translateY(-1px);
  box-shadow: inset 0 -2px 0 var(--accent);
}

.nav-item {
  position: relative;
  display: flex;
  align-items: center;
}

.nav-dropdown {
  position: absolute;
  top: 100%;
  left: 0;
  display: none;
  flex-direction: column;
  min-width: 180px;
  padding: 0.6rem 0;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 12px;
  box-shadow: var(--shadow);
  z-index: 15;
}

.nav-dropdown a {
  padding: 0.65rem 1rem;
  color: var(--ink);
  white-space: nowrap;
}

.nav-dropdown a:hover {
  background: #f2f5f9;
  color: var(--accent);
}

.nav-item.has-menu:hover .nav-dropdown,
.nav-item.has-menu:focus-within .nav-dropdown,
.nav-dropdown:hover {
  display: flex;
}

.hero {
  display: grid;
  grid-template-columns: 3fr auto 1fr;
  gap: 2.4rem;
  align-items: flex-start;
  padding: 3.5rem 0 2.5rem;
  position: relative;
}

.mini-logo {
  display: flex;
  justify-content: center;
  align-items: center;
  pointer-events: none;
}

.mini-logo img {
  width: 80px;
  height: 80px;
  object-fit: contain;
  opacity: 0.25;
  filter: drop-shadow(0 8px 16px rgba(23, 33, 30, 0.12));
}

.mini-logo--hero {
  align-self: center;
  justify-self: center;
}

.mini-logo--after {
  padding: 0.5rem 0 2.5rem;
}

.image-showcase {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.2rem;
  margin: 1.5rem 0 2.4rem;
}

.image-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.image-card img {
  display: block;
  width: 100%;
  height: 100%;
  max-height: 320px;
  object-fit: cover;
}


body.home {
  background: var(--bg);
}

.home main {
  max-width: 1240px;
}

.home .hero {
  background: #ffffff;
  border: 1px solid var(--border);
  border-radius: 24px;
  padding: 3rem;
  box-shadow: 0 22px 40px rgba(23, 33, 30, 0.12);
  position: relative;
  overflow: hidden;
}

.home .hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at top right, rgba(31, 111, 84, 0.14), transparent 55%);
  pointer-events: none;
}

.home .hero__card {
  background: linear-gradient(160deg, #ffffff 0%, #f6fbf8 100%);
  border: 1px solid #e6efe8;
}

.home .card__badge {
  background: #f1efe8;
  color: #5b5247;
}

.home .offer {
  border: 1px solid #ece7dc;
  background: #ffffff;
  box-shadow: 0 16px 28px rgba(23, 33, 30, 0.08);
}

.home .offer-icon {
  background: #f1efe8;
  color: var(--accent);
}

.home .image-showcase {
  margin-top: 2rem;
}

.home .image-card {
  border-radius: 22px;
  box-shadow: 0 24px 42px rgba(23, 33, 30, 0.14);
}

.home .image-card img {
  max-height: 360px;
}

.hero__copy h1 {
  font-family: var(--font-display);
  font-size: clamp(2.1rem, 3.6vw, 3rem);
  line-height: 1.05;
  margin: 0.4rem 0 0.8rem;
  color: var(--ink);
}

.hero .lede {
  font-size: 1.15rem;
  color: var(--muted);
}

.hero__copy > .lede {
  font-size: 1.72rem;
  line-height: 1.5;
}

.hero__copy .list {
  font-size: 1.5rem;
}

.hero__card {
  font-size: 1.15rem;
  max-width: 280px;
  width: 100%;
  justify-self: end;
}

.hero__card h3 {
  font-size: 1.5rem;
}

.lede {
  color: var(--muted);
  max-width: 680px;
}

.eyebrow {
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent);
  font-weight: 600;
  font-size: 1.35rem;
}

.actions {
  display: flex;
  gap: 0.9rem;
  margin: 1.5rem 0;
  flex-wrap: wrap;
}

.cta {
  background: var(--accent);
  color: #fff;
  border: 1px solid var(--accent);
  padding: 0.9rem 1.4rem;
  border-radius: 999px;
  font-weight: 700;
  cursor: pointer;
  transition: transform 150ms ease, box-shadow 150ms ease, background 150ms ease;
  box-shadow: 0 10px 24px rgba(15, 98, 254, 0.18);
}

.cta:hover {
  transform: translateY(-1px);
  background: #0c53d4;
  color: #fff;
  border-color: #0c53d4;
}

.cta:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.cta.ghost {
  background: transparent;
  color: var(--ink);
  border: 1px solid var(--border);
  box-shadow: none;
}

.cta.ghost:hover {
  background: var(--accent-soft);
  border-color: var(--accent);
  color: var(--ink);
}

/* Homepage “Try a free quiz” CTA */
.cta.ghost[href="sample-quiz.html"] {
  background: var(--accent);
  color: #fff;
  border: 1px solid var(--accent);
  box-shadow: 0 10px 24px rgba(15, 98, 254, 0.18);
}

.cta.ghost[href="sample-quiz.html"]:hover {
  background: #0c53d4;
  color: #fff;
  border-color: #0c53d4;
}

/* Nav login button overrides ghost defaults */
.nav .nav-login {
  background: transparent;
  color: var(--accent);
  border: 1px solid var(--accent);
  box-shadow: none;
}

.nav .nav-login:hover {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
  box-shadow: 0 10px 24px rgba(15, 98, 254, 0.18);
}

.cta.full {
  width: 100%;
  justify-content: center;
  display: inline-flex;
  align-items: center;
  text-align: center;
}

.hero__meta {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 1rem;
  margin-top: 1.8rem;
}

.hero__offers {
  margin-top: 1.1rem;
  padding: 1.2rem 1.1rem;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.hero__offers .eyebrow {
  margin-bottom: 0.65rem;
}

.offers-wide {
  margin-top: 1.6rem;
  padding: 1.8rem 1.6rem;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.offers-wide .eyebrow {
  margin-bottom: 0.7rem;
  color: var(--accent);
}

.offers-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1.1rem;
}

.offer {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.7rem 1rem;
  padding: 1.2rem;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 14px;
  box-shadow: var(--shadow);
}

.offer:nth-child(odd) {
  background: var(--card);
  border-color: var(--border);
}

.offer:nth-child(even) {
  background: var(--card);
  border-color: var(--border);
}

.offer-icon {
  width: 52px;
  height: 52px;
  border-radius: 12px;
  background: var(--accent-soft);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  color: var(--accent);
  box-shadow: none;
}

.offer-body h4 {
  margin: 0;
  font-size: 1.15rem;
  font-weight: 700;
}

.offer-body p {
  margin: 0;
  color: var(--muted);
  font-size: 1.05rem;
  line-height: 1.55;
}

.meta-label {
  display: block;
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--accent);
}

.meta-caption {
  color: var(--muted);
  font-size: 0.95rem;
}

.hero__card {
  background: var(--card);
  border: 1px solid var(--border);
  padding: 2.2rem;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  align-self: flex-start;
  color: var(--ink);
}

.card__badge {
  display: inline-block;
  padding: 0.3rem 0.8rem;
  background: var(--accent-soft);
  color: var(--accent);
  border-radius: 999px;
  font-weight: 600;
  font-size: 0.95rem;
}

.hero__card h3 {
  font-family: var(--font-display);
  margin: 1rem 0 0.6rem;
}

.hero__card ul {
  list-style: none;
  color: var(--muted);
  margin: 0 0 1.2rem;
  line-height: 1.6;
}

.section {
  padding: 4rem 0;
}

.section__header h2 {
  font-family: var(--font-display);
  font-size: clamp(2rem, 3.2vw, 2.8rem);
  margin: 0.6rem 0 0.8rem;
}

.info-box {
  margin-top: 1rem;
  padding: 1.25rem 1.2rem;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 16px;
  box-shadow: var(--shadow);
  color: var(--ink);
}

.info-box h2 {
  margin-top: 0;
  margin-bottom: 0.75rem;
}

.login-section {
  padding: 3.5rem 0;
}

.auth-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 3.6rem 2rem 2.4rem;
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.08);
  display: grid;
  gap: 1rem;
  align-items: start;
  color: var(--ink);
  width: 100%;
  max-width: 1120px;
  margin: 0 auto;
}

.auth-views {
  display: grid;
  gap: 0.75rem;
  margin-top: 1.4rem;
}

.auth-form {
  display: grid;
  gap: 0.8rem;
  width: 100%;
  max-width: 780px;
  margin: 0 auto;
  padding: 0.9rem 0.2rem 1.1rem;
}

.auth-form .cta.full {
  margin-top: 0.4rem;
  border-radius: 12px;
  padding: 0.85rem 1rem;
  box-shadow: 0 10px 24px rgba(15, 98, 254, 0.16);
}

.auth-form .text-link {
  display: inline;
  margin-top: 0.2rem;
  padding: 0;
  border-radius: 0;
  color: var(--accent);
  justify-self: start;
  align-self: center;
  width: auto;
}

button.text-link {
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 0;
  width: auto;
  display: inline;
  margin: 0;
  line-height: 1.4;
}

.forgot-password-trigger {
  display: inline;
}

.auth-note {
  color: var(--muted);
  font-size: 1.05rem;
}

.title-small {
  font-size: clamp(1.9rem, 3vw, 2.5rem);
}

.section__header .narrow {
  max-width: 720px;
}

.grid.features {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.2rem;
  margin-top: 2rem;
}

.feature {
  background: var(--card);
  border: 1px solid var(--border);
  padding: 2rem;
  border-radius: 20px;
  min-height: 210px;
  box-shadow: var(--shadow);
  color: var(--ink);
}

.feature:nth-child(odd) {
  background: var(--card);
  border-color: var(--border);
}

.feature:nth-child(even) {
  background: var(--card);
  border-color: var(--border);
}

/* After-login action cards */
.after-login-actions .features {
  gap: 1.4rem;
}

.after-card {
  min-height: 360px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  background: var(--card);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  padding: 1.75rem;
  color: var(--ink);
}

.after-card:nth-child(2) {
  background: radial-gradient(circle at 20% 20%, rgba(16, 185, 129, 0.16), transparent 42%),
    linear-gradient(185deg, rgba(14, 45, 46, 0.95), rgba(6, 22, 24, 0.96));
  border-color: rgba(46, 204, 113, 0.55);
}

.after-card:nth-child(3) {
  background: radial-gradient(circle at 18% 18%, rgba(59, 130, 246, 0.2), transparent 40%),
    linear-gradient(185deg, rgba(15, 30, 60, 0.95), rgba(9, 16, 28, 0.96));
  border-color: rgba(59, 130, 246, 0.55);
}

.after-card:nth-child(4) {
  background: radial-gradient(circle at 18% 18%, rgba(16, 185, 129, 0.18), transparent 40%),
    linear-gradient(185deg, rgba(10, 41, 38, 0.95), rgba(7, 20, 22, 0.96));
  border-color: rgba(46, 204, 113, 0.55);
}

.pill-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.9rem 1.7rem;
  border-radius: 999px;
  font-weight: 800;
  letter-spacing: 0.01em;
  text-align: center;
  border: 2px solid var(--border);
  color: var(--ink);
  background: #ffffff;
  transition: transform 150ms ease, box-shadow 150ms ease, border-color 150ms ease, background 150ms ease;
}

.pill-btn.outline:hover {
  transform: translateY(-1px);
  border-color: rgba(255, 255, 255, 0.4);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.45);
}

.pill-btn.solid {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
  box-shadow: 0 10px 24px rgba(15, 98, 254, 0.18);
}

.pill-btn.solid:hover {
  background: #0c53d4;
  transform: translateY(-1px);
  box-shadow: 0 14px 30px rgba(12, 83, 212, 0.22);
}

.feature .cta {
  margin-top: 1rem;
  display: inline-flex;
  align-items: center;
}

.feature__icon {
  font-size: 1.3rem;
  margin-bottom: 0.7rem;
}

.split {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 1.5rem;
  align-items: center;
}

.list {
  color: var(--muted);
  margin-top: 1rem;
  padding-left: 1.1rem;
  line-height: 1.7;
}

.list.tight li {
  margin-bottom: 0.35rem;
}

.panel {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.4rem;
  box-shadow: var(--shadow);
  color: var(--ink);
}

.panel.alt {
  background: var(--card);
}

.panel__stat {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.9rem 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.panel__stat:last-child {
  border-bottom: none;
}

.stat {
  font-size: 1.6rem;
  font-weight: 700;
}

.stat-label {
  color: var(--muted);
}

.pricing__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1rem;
  margin-top: 2rem;
}

.price-card {
  position: relative;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
}

.price-card__badge {
  position: absolute;
  top: -12px;
  right: 12px;
  background: var(--accent-soft);
  color: var(--accent);
  padding: 0.35rem 0.7rem;
  border-radius: 999px;
  font-weight: 700;
  font-size: 0.8rem;
}

.price {
  font-size: 2.2rem;
  font-weight: 700;
}

.columns {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 1.5rem;
  align-items: start;
}

.steps {
  list-style-position: inside;
  color: var(--muted);
  line-height: 1.8;
}

.quote {
  background: var(--card);
  border: 1px solid var(--border);
  padding: 1.3rem;
  border-radius: var(--radius);
  color: var(--muted);
}

.faq__list {
  display: grid;
  gap: 0.8rem;
  margin-top: 1.2rem;
}

.faq__item {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1rem 1.1rem;
}

.faq__item header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
}

.faq__item p {
  color: var(--muted);
  margin-top: 0.4rem;
  display: none;
}

.faq__item.open p {
  display: block;
}

.toggle {
  background: #f2f5f9;
  border: 1px solid var(--border);
  color: var(--ink);
  border-radius: 50%;
  width: 32px;
  height: 32px;
  font-size: 1.2rem;
  cursor: pointer;
}

.footer {
  width: 100%;
  margin: 3rem 0 0;
  padding: 0.9rem 5vw;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-top: 1px solid var(--border);
  background: #ffffff;
  box-shadow: 0 -8px 24px rgba(0, 0, 0, 0.04);
  color: var(--muted);
  backdrop-filter: none;
}

.footer::before {
  display: none;
}

.footer__actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.text-link {
  color: var(--accent);
}

.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 320ms ease, transform 320ms ease;
}

.in-view {
  opacity: 1;
  transform: none;
}

.newsletter {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 2rem;
  box-shadow: var(--shadow);
}

.newsletter__form {
  margin-top: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
}

.newsletter__fields {
  display: grid;
  grid-template-columns: 1.2fr auto;
  gap: 0.6rem;
}

.newsletter input[type="email"] {
  width: 100%;
  background: #ffffff;
  border: 1px solid var(--border);
  color: var(--ink);
  border-radius: 999px;
  padding: 0.9rem 1rem;
  font-size: 1rem;
}

.newsletter input[type="email"]:focus {
  outline: 2px solid var(--accent);
  border-color: var(--accent);
}

.newsletter__note {
  color: var(--muted);
  font-size: 0.95rem;
}

.newsletter__status {
  min-height: 1.2rem;
  color: var(--accent);
  font-weight: 600;
}

.newsletter__status.error {
  color: var(--danger);
}

.quiz__card {
  position: relative;
  overflow: hidden;
  background: linear-gradient(150deg, rgba(26, 43, 68, 0.95), rgba(16, 27, 44, 0.98)) padding-box,
    radial-gradient(circle at 15% 20%, rgba(59, 130, 246, 0.22), transparent 32%) padding-box,
    radial-gradient(circle at 88% 18%, rgba(16, 185, 129, 0.18), transparent 30%) padding-box;
  border: 1px solid rgba(112, 189, 81, 0.6);
  border-radius: 22px;
  padding: 2.1rem;
  box-shadow: 0 28px 70px rgba(0, 0, 0, 0.55), inset 0 1px 0 rgba(255, 255, 255, 0.06);
  backdrop-filter: blur(8px);
  display: flex;
  flex-direction: column;
  gap: 1.15rem;
}

.quiz__card::before {
  content: '';
  position: absolute;
  top: -18%;
  right: -2%;
  width: 260px;
  height: 260px;
  background: radial-gradient(circle, rgba(245, 158, 11, 0.28), rgba(245, 158, 11, 0));
  filter: blur(26px);
  opacity: 0.32;
  pointer-events: none;
}

.quiz__card::after {
  content: '';
  position: absolute;
  bottom: -18%;
  left: -14%;
  width: 280px;
  height: 280px;
  background: radial-gradient(circle, rgba(59, 130, 246, 0.22), rgba(59, 130, 246, 0));
  filter: blur(28px);
  opacity: 0.28;
  pointer-events: none;
}

.quiz__card.is-submitted .quiz__meta,
.quiz__card.is-submitted .quiz__bullet,
.quiz__card.is-submitted .quiz__answers,
.quiz__card.is-submitted .quiz__actions,
.quiz__card.is-submitted .quiz__nav,
.quiz__card.is-submitted .quiz__solution {
  display: none;
}

.quiz__meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-weight: 700;
  color: #e5e7eb;
  padding: 0.6rem 0.9rem;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 14px;
  gap: 1rem;
}

.quiz__number {
  color: var(--ink);
}

.quiz__timer {
  font-family: var(--font-display);
  letter-spacing: 0.08em;
  padding: 0.55rem 0.95rem;
  border-radius: 12px;
  background: linear-gradient(135deg, #f59e0b, #fbbf24);
  border: 1px solid rgba(245, 158, 11, 0.7);
  color: #0b1222;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.35), 0 8px 18px rgba(0, 0, 0, 0.18);
}

.quiz__bullet {
  color: #e5e7eb;
  font-size: 1.08rem;
  line-height: 1.75;
  padding: 1rem 1.1rem;
  background: linear-gradient(135deg, rgba(17, 24, 39, 0.94), rgba(11, 18, 34, 0.96));
  border: 1px solid rgba(112, 189, 81, 0.55);
  border-radius: 14px;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.quiz__bullet .katex-display {
  text-align: center;
  padding: 0.35rem 0;
}

.quiz__answers {
  display: grid;
  gap: 0.9rem;
  padding: 1.05rem 1.1rem;
  background: linear-gradient(140deg, rgba(44, 63, 97, 0.85), rgba(25, 41, 66, 0.88)),
    linear-gradient(150deg, rgba(37, 99, 235, 0.22), rgba(16, 185, 129, 0.2));
  border: 1px solid rgba(112, 189, 81, 0.5);
  border-radius: 16px;
  box-shadow: 0 20px 48px rgba(0, 0, 0, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.quiz__choice {
  width: 100%;
  text-align: left;
  display: flex;
  gap: 0.55rem;
  align-items: flex-start;
  background: rgba(15, 23, 42, 0.85);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: var(--ink);
  border-radius: 14px;
  padding: 1rem 1.05rem;
  cursor: pointer;
  transition: border-color 150ms ease, background 150ms ease, transform 150ms ease, box-shadow 150ms ease;
  line-height: 1.6;
}

.quiz__choice:hover {
  transform: translateY(-1px);
  border-color: rgba(255, 255, 255, 0.35);
  box-shadow: 0 10px 26px rgba(0, 0, 0, 0.35);
}

.quiz__choice.selected {
  border-color: rgba(59, 130, 246, 0.85);
  background: linear-gradient(135deg, rgba(59, 130, 246, 0.2), rgba(59, 130, 246, 0.12));
  box-shadow: 0 12px 28px rgba(59, 130, 246, 0.22);
}

.quiz__choice.correct {
  border-color: var(--accent-2);
  background: rgba(61, 214, 161, 0.14);
  box-shadow: inset 0 0 0 1px rgba(61, 214, 161, 0.5);
}

.quiz__choice.incorrect {
  border-color: var(--danger);
  background: rgba(239, 68, 68, 0.14);
}

.quiz__solution {
  background: linear-gradient(135deg, rgba(61, 214, 161, 0.15), rgba(61, 214, 161, 0.06));
  border: 1px solid rgba(61, 214, 161, 0.3);
  border-radius: 16px;
  padding: 1rem;
  margin-top: 0.8rem;
  color: var(--ink);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.15);
  line-height: 1.65;
}

.quiz__answer {
  color: var(--accent-2);
}

.quiz__note {
  color: var(--muted);
  font-size: 0.95rem;
}

.quiz__steps p {
  margin-bottom: 0.2rem;
}

.quiz__actions {
  display: flex;
  align-items: center;
  gap: 0.8rem;
}

.quiz__submit {
  padding: 1rem 1.5rem;
  font-size: 1.02rem;
  box-shadow: 0 14px 30px rgba(245, 158, 11, 0.25);
  border: 1px solid rgba(245, 158, 11, 0.4);
}

.quiz__controls {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-top: 0.6rem;
  flex-wrap: wrap;
}

.quiz__controls .quiz__status {
  color: var(--muted);
}

.quiz__nav {
  display: flex;
  align-items: center;
  gap: 0.8rem;
}

.quiz__nav .text-link {
  padding: 0.65rem 1.25rem;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 999px;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.04));
  color: #e5e7eb;
  font-weight: 700;
  letter-spacing: 0.01em;
  transition: transform 150ms ease, border-color 150ms ease, background 150ms ease, box-shadow 150ms ease;
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.22);
}

.quiz__nav .text-link:hover {
  transform: translateY(-1px);
  border-color: rgba(255, 255, 255, 0.3);
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.12), rgba(255, 255, 255, 0.08));
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.26);
}

.quiz__progress {
  color: var(--muted);
  font-weight: 600;
}

.quiz__summary {
  margin-top: 0.8rem;
  font-weight: 700;
  color: var(--accent-2);
  padding: 0.75rem 0.95rem;
  border-radius: 14px;
  background: rgba(61, 214, 161, 0.1);
  border: 1px solid rgba(61, 214, 161, 0.32);
}

.quiz__review {
  margin-top: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.review__item {
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 14px;
  padding: 0.9rem 1rem;
  background: rgba(255, 255, 255, 0.04);
}

.review__item.ok {
  border-color: rgba(61, 214, 161, 0.4);
  background: rgba(61, 214, 161, 0.08);
}

.review__item.fail {
  border-color: rgba(239, 68, 68, 0.4);
  background: rgba(239, 68, 68, 0.06);
}

.review__heading {
  font-weight: 700;
  margin-bottom: 0.35rem;
}

.review__stem {
  color: var(--ink);
  margin-bottom: 0.35rem;
}

.review__answers {
  color: var(--muted);
  margin-bottom: 0.25rem;
}

.review__solution {
  color: var(--muted);
  font-size: 0.95rem;
}

.review__options {
  list-style: none;
  padding: 0;
  margin: 0.35rem 0 0.4rem;
  display: grid;
  gap: 0.25rem;
}

.review__options li {
  color: var(--ink);
  padding: 0.35rem 0.45rem;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.05);
  background: rgba(255, 255, 255, 0.03);
}

.review__options li.correct {
  border-color: rgba(61, 214, 161, 0.5);
  background: rgba(61, 214, 161, 0.12);
}

.review__options li.chosen {
  border-color: rgba(245, 158, 11, 0.5);
  box-shadow: inset 0 0 0 1px rgba(245, 158, 11, 0.45);
}

.review__options li.correct.chosen {
  border-color: rgba(61, 214, 161, 0.8);
  box-shadow: inset 0 0 0 1px rgba(61, 214, 161, 0.7);
}

.quiz__status {
  min-height: 1.4rem;
  color: var(--accent-2);
  font-weight: 600;
}

.quiz__status.error {
  color: var(--danger);
}

.checkout {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 2.4rem 2.6rem 2.2rem;
  box-shadow: var(--shadow);
}

.checkout__form {
  margin-top: 1.2rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  padding: 1rem 0.6rem 1.25rem;
}

.form__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1rem;
}

.form__field.plan-field {
  grid-column: span 2;
}

@media (max-width: 640px) {
  .form__field.plan-field {
    grid-column: span 1;
  }
}

.form__field {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  color: var(--muted);
  font-size: 0.95rem;
  padding: 0.1rem 0.05rem;
}

.form__field input,
.form__field select {
  background: #f9fbff;
  border: 1px solid #d5d9e0;
  color: var(--ink);
  border-radius: 12px;
  padding: 0.85rem 0.9rem;
  font-size: 1rem;
  box-shadow: inset 0 1px 2px rgba(15, 23, 42, 0.05);
}

.form__field input:focus,
.form__field select:focus {
  outline: 2px solid var(--accent);
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
}

.form__field input:hover,
.form__field select:hover {
  border-color: #c7ccd5;
}

.password-input-wrapper {
  position: relative;
  width: 100%;
  display: block;
}

.password-input-wrapper input {
  width: 100%;
  padding-right: 2.8rem;
  box-sizing: border-box;
}

.password-toggle {
  position: absolute;
  right: 0.6rem;
  top: 50%;
  transform: translateY(-50%);
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 0.4rem;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #64748b;
  transition: color 0.2s ease;
  border-radius: 6px;
}

.password-toggle:hover {
  color: var(--accent);
  background: var(--accent-soft);
}

.password-toggle:focus {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.password-toggle svg {
  display: block;
}

.checkout__actions {
  display: flex;
  align-items: center;
  gap: 0.9rem;
}

.checkout__status {
  min-height: 1.4rem;
  color: var(--accent-2);
  font-weight: 600;
}

.checkout__status.error {
  color: var(--danger);
}

.otp-panel {
  margin-top: 1.2rem;
  padding: 1.2rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--card);
  box-shadow: var(--shadow);
}

.otp__status {
  min-height: 1.4rem;
  color: var(--accent);
  font-weight: 600;
}

.otp__status.error {
  color: var(--danger);
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

@media (max-width: 900px) {
  body {
    padding: 0 1.5rem 3rem;
  }

  .hero, .split, .columns {
    grid-template-columns: 1fr;
  }

  .hero__card {
    max-width: none;
    justify-self: stretch;
  }

  .nav {
    display: flex !important;
    flex-direction: column !important;
    width: 100% !important;
    background: rgba(15, 23, 42, 0.98);
    position: static;
    gap: 0.5rem;
    padding: 1rem 0 0.5rem 0;
    align-items: flex-start;
    font-size: 1.1rem;
  }

  .topbar {
    flex-direction: column !important;
    align-items: flex-start !important;
  }
}

@media (max-width: 768px) {
  main {
    padding: 0 2vw;
  }
  .hero {
    grid-template-columns: 1fr;
    gap: 1.5rem;
    padding: 2rem 0 1.5rem;
  }
  .hero__card {
    margin-top: 1.5rem;
    padding: 1.2rem;
  }
  .offers-grid {
    grid-template-columns: 1fr;
  }
  .topbar {
    flex-direction: column;
    align-items: flex-start;
    padding: 0.5rem 2vw;
  }
  .brand-name {
    font-size: 1.5rem;
  }
  .nav {
    flex-wrap: wrap;
    gap: 0.5rem;
    font-size: 1rem;
  }
  body {
    padding: 0 !important;
    max-width: 100vw;
    overflow-x: hidden;
  }
  main {
    max-width: 100vw;
    overflow-x: hidden;
  }
  .footer {
    width: 100%;
    box-sizing: border-box;
  }
  .footer {
    flex-direction: column;
    align-items: flex-start;
    text-align: left;
    padding: 2rem 1rem 1rem 1rem;
    gap: 1.5rem;
  }
  .footer__actions {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    align-items: flex-start;
    margin-top: 1rem;
  }
  .footer .logo.brand {
    margin-bottom: 1rem;
  }
}

/* Hamburger menu styles */
.nav-toggle {
  display: none;
  background: #ffffff;
  border: 1px solid var(--border);
  font-size: 2rem;
  color: var(--accent);
  cursor: pointer;
  margin-left: auto;
  z-index: 1001;
  border-radius: 14px;
  box-shadow: var(--shadow);
  line-height: 1;
  transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease, color 0.18s ease;
}

@media (max-width: 900px) {
  .topbar {
    position: relative;
    flex-direction: row !important;
    align-items: center !important;
    justify-content: space-between !important;
  }
  .nav-toggle {
    display: block;
    position: fixed;
    right: 1.2rem;
    top: 1.1rem;
    z-index: 2001;
    background: #ffffff;
    border: 1px solid var(--border);
    border-radius: 14px;
    font-size: 2.4rem;
    padding: 0.24em 0.86em 0.16em 0.86em;
    min-width: 52px;
    min-height: 52px;
    box-shadow: 0 10px 26px rgba(0,0,0,0.14);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease, color 0.18s ease;
  }
  .nav-toggle:hover {
    background: var(--accent-soft);
    color: var(--accent);
    box-shadow: 0 14px 32px rgba(15, 98, 254, 0.22);
  }
  .nav-toggle:active {
    transform: translateY(1px);
  }
  .nav {
    display: none;
    flex-direction: column;
    width: 82vw;
    max-width: 340px;
    background: rgba(255, 255, 255, 0.97);
    border: 1px solid var(--border);
    position: fixed;
    right: 1.2rem;
    top: 72px;
    z-index: 2000;
    gap: 0.35rem;
    padding: 1.1rem 1rem 1.1rem 1rem;
    align-items: flex-start;
    font-size: 1.05rem;
    box-shadow: 0 12px 32px rgba(0,0,0,0.16);
    border-radius: 14px;
    transition: opacity 0.2s, visibility 0.2s;
    opacity: 0;
    pointer-events: none;
    visibility: hidden;
  }
  .nav.open {
    display: flex;
    opacity: 1;
    pointer-events: auto;
    visibility: visible;
  }
  .nav a {
    display: block;
    width: 100%;
    color: var(--ink);
    padding: 0.85rem 0.9rem;
    border-radius: 10px;
    box-shadow: none;
    transform: none;
  }
  .nav a:hover {
    background: var(--accent-soft);
    color: var(--accent);
    box-shadow: none;
    transform: none;
  }
  .nav .nav-login {
    background: var(--accent);
    color: #fff;
    border-color: var(--accent);
    text-align: center;
    box-shadow: 0 10px 24px rgba(15, 98, 254, 0.18);
  }
  .nav .nav-login:hover {
    background: #0c53d4;
    color: #fff;
  }
}

  /* Dashboard/account hamburger dropdown (desktop + mobile) */
  .nav-menu {
    position: absolute;
    top: 68px;
    right: 16px;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
    min-width: 200px;
    display: none;
    flex-direction: column;
    list-style: none;
    padding: 8px 0;
    z-index: 3000;
  }

  .nav-menu.open {
    display: flex;
  }

  .nav-menu a {
    padding: 12px 16px;
    color: #4a5568;
    font-weight: 600;
    transition: background 0.2s, color 0.2s;
  }

  .nav-menu a:hover {
    background: #f4f7f6;
    color: #2563eb;
  }

  .nav-menu .logout-btn {
    color: #ef4444;
  }
