/* ==========================================================================
   L.B. English Co. — Design Tokens
   Signature: "Mission Control vs. Exam Paper" — a glowing glass HUD for
   marketing/product chrome, contrasted with warm, paper-toned serif
   reading passages inside the exam engine.
   ========================================================================== */

:root {
  /* Brand */
  --brand-terracotta: #b33101;
  --brand-terracotta-hover: #d43b02;
  --brand-terracotta-glow: rgba(179, 49, 1, 0.4);
  --brand-teal: #026366;
  --brand-teal-bright: #22d3d8;
  --brand-teal-glow: rgba(2, 99, 102, 0.45);
  --brand-slate: #4a5459;

  /* Surfaces */
  --bg-deep: #070d10;
  --bg-surface: rgba(13, 22, 26, 0.78);
  --bg-surface-solid: #0d161a;
  --bg-surface-2: rgba(20, 32, 37, 0.7);
  --border-glass: rgba(255, 255, 255, 0.08);
  --border-glass-strong: rgba(255, 255, 255, 0.16);

  /* Text */
  --text-main: #f0f4f6;
  --text-muted: #9ca3af;
  --text-faint: #6b7680;

  /* Highlighter (exam tool — brighter than brand tones so marks read on paper) */
  --hl-yellow: #f5c542;
  --hl-teal: #22d3d8;
  --hl-terracotta: #ff6b35;

  /* Error states. Distinct from terracotta so a failed form never reads as
     brand accent — students must be able to tell "this is the CTA" from
     "this went wrong". */
  --danger: #ff7a70;
  --danger-soft: rgba(255, 122, 112, 0.12);
  --danger-border: rgba(255, 122, 112, 0.38);

  /* Paper (exam passage signature) */
  --paper: #efe7d8;
  --paper-ink: #211c14;
  --paper-muted: #6b5f4a;
  --paper-rule: rgba(33, 28, 20, 0.14);

  /* Type */
  --font-ui: 'Plus Jakarta Sans', system-ui, sans-serif;
  --font-passage: 'Lora', Georgia, serif;
  --font-mono: 'JetBrains Mono', ui-monospace, monospace;

  /* Radius */
  --r-sm: 8px;
  --r-md: 14px;
  --r-lg: 20px;
  --r-pill: 9999px;

  --shadow-card: 0 8px 32px 0 rgba(0, 0, 0, 0.5);
  --ease: cubic-bezier(0.4, 0, 0.2, 1);

  /* Theme-aware fills / scrims (dark defaults — see light override below) */
  --fill-xs: rgba(255, 255, 255, 0.04);
  --fill-sm: rgba(255, 255, 255, 0.05);
  --fill-md: rgba(255, 255, 255, 0.06);
  --fill-lg: rgba(255, 255, 255, 0.08);
  --scrim-sm: rgba(0, 0, 0, 0.15);
  --scrim-md: rgba(0, 0, 0, 0.2);
  --scrim-drawer: rgba(0, 0, 0, 0.55);
  --scrim-modal: rgba(0, 0, 0, 0.6);
  --ring-soft: rgba(255, 255, 255, 0.25);
  --shadow-nav: rgba(0, 0, 0, 0.35);
  --nav-bg: rgba(7, 13, 16, 0.72);
  --paper-shadow: 0 12px 30px rgba(0, 0, 0, 0.35);
}

/* ==========================================================================
   Light theme — the default. Cool glass chrome (not warm) so the parchment
   "paper" tone stays unique to the exam passage panel in both themes.
   ========================================================================== */
:root[data-theme="light"] {
  --bg-deep: #f5f7f8;
  --bg-surface: rgba(255, 255, 255, 0.68);
  --bg-surface-solid: #ffffff;
  --bg-surface-2: rgba(255, 255, 255, 0.9);
  --border-glass: rgba(15, 23, 26, 0.08);
  --border-glass-strong: rgba(15, 23, 26, 0.15);

  --text-main: #101820;
  --text-muted: #5a6570;
  --text-faint: #8d97a1;

  /* Accent text/icon colors need real contrast on a light surface, so the
     "bright" teal and "hover" terracotta shift to their inkier, still-vivid
     register instead of the neon dark-mode tones. */
  --brand-teal-bright: #026366;
  --brand-terracotta-hover: #9c2a01;
  --brand-teal-glow: rgba(2, 99, 102, 0.12);
  --brand-terracotta-glow: rgba(179, 49, 1, 0.12);

  --danger: #b3261e;
  --danger-soft: rgba(179, 38, 30, 0.07);
  --danger-border: rgba(179, 38, 30, 0.28);

  --shadow-card: 0 10px 28px rgba(30, 22, 10, 0.09), 0 2px 8px rgba(30, 22, 10, 0.05);
  --paper-shadow: 0 10px 24px rgba(30, 22, 10, 0.16);

  --fill-xs: rgba(15, 23, 26, 0.035);
  --fill-sm: rgba(15, 23, 26, 0.045);
  --fill-md: rgba(15, 23, 26, 0.055);
  --fill-lg: rgba(15, 23, 26, 0.08);
  --scrim-sm: rgba(15, 23, 26, 0.035);
  --scrim-md: rgba(15, 23, 26, 0.045);
  --scrim-drawer: rgba(20, 16, 10, 0.32);
  --scrim-modal: rgba(20, 16, 10, 0.38);
  --ring-soft: rgba(15, 23, 26, 0.16);
  --shadow-nav: rgba(15, 23, 26, 0.1);
  --nav-bg: rgba(246, 248, 249, 0.78);
}

/* ==========================================================================
   Reset & base
   ========================================================================== */

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; transition-duration: 0.001ms !important; }
}

body {
  margin: 0;
  background-color: var(--bg-deep);
  color: var(--text-main);
  font-family: var(--font-ui);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  background-image:
    radial-gradient(ellipse 900px 700px at 8% -5%, var(--brand-teal-glow) 0%, transparent 55%),
    radial-gradient(ellipse 900px 700px at 100% 60%, var(--brand-terracotta-glow) 0%, transparent 55%),
    radial-gradient(ellipse 700px 500px at 20% 100%, rgba(2, 99, 102, 0.2) 0%, transparent 60%);
  background-attachment: fixed;
  overflow-x: hidden;
}

img { max-width: 100%; display: block; }
h1, h2, h3, h4 { margin: 0; font-weight: 700; letter-spacing: -0.01em; }
p { margin: 0; }
ul { margin: 0; padding: 0; list-style: none; }
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; }
:focus-visible { outline: 2px solid var(--brand-teal-bright); outline-offset: 2px; border-radius: 4px; }

.skip-link {
  position: absolute; left: -999px; top: 0; z-index: 999;
  background: var(--brand-terracotta); color: #fff; padding: 12px 20px; border-radius: 0 0 8px 0;
}
.skip-link:focus { left: 0; }

.section-inner { max-width: 1280px; margin: 0 auto; padding: 0 20px; }
@media (min-width: 900px) { .section-inner { padding: 0 64px; } }

.section { padding: 88px 0; position: relative; }
.section-alt { background: linear-gradient(180deg, rgba(2, 99, 102, 0.05), transparent 30%, transparent 70%, rgba(179, 49, 1, 0.04)); }

.eyebrow {
  font-family: var(--font-mono); text-transform: uppercase; letter-spacing: 0.14em;
  font-size: 12px; font-weight: 600; color: var(--brand-teal-bright); margin-bottom: 12px;
  display: flex; align-items: center; gap: 8px;
}
.eyebrow-live { color: var(--brand-terracotta-hover); }
.section-title { font-size: clamp(1.9rem, 3vw, 2.6rem); margin-bottom: 12px; }
.section-sub { color: var(--text-muted); max-width: 640px; font-size: 1.05rem; margin-bottom: 40px; }
.subheading { font-size: 1.3rem; margin: 40px 0 20px; }

/* ==========================================================================
   Glass card & buttons
   ========================================================================== */

.glass-card {
  background: var(--bg-surface);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--border-glass);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-card);
}

.btn-terracotta {
  background: var(--brand-terracotta);
  color: #fff; border: none; padding: 14px 24px; border-radius: var(--r-sm);
  font-weight: 700; font-size: 0.95rem; display: inline-flex; align-items: center; gap: 8px;
  transition: all 0.2s var(--ease); white-space: nowrap;
}
.btn-terracotta:hover { background: var(--brand-terracotta-hover); box-shadow: 0 0 25px var(--brand-terracotta-glow); transform: translateY(-2px); }
.btn-terracotta:disabled { opacity: 0.4; cursor: not-allowed; transform: none; box-shadow: none; }
.btn-lg { padding: 16px 30px; font-size: 1rem; }
.btn-sm { padding: 9px 16px; font-size: 0.85rem; }

.btn-ghost {
  background: transparent; color: var(--text-main); border: 1px solid var(--border-glass-strong);
  padding: 14px 24px; border-radius: var(--r-sm); font-weight: 600; font-size: 0.95rem;
  display: inline-flex; align-items: center; gap: 8px; transition: all 0.2s var(--ease);
}
.btn-ghost:hover { border-color: var(--brand-teal-bright); color: var(--brand-teal-bright); }

.icon-btn {
  background: var(--fill-md); border: 1px solid var(--border-glass); color: var(--text-main);
  width: 38px; height: 38px; border-radius: var(--r-sm); display: inline-flex; align-items: center; justify-content: center;
  transition: all 0.2s var(--ease);
}
.icon-btn:hover { border-color: var(--brand-teal-bright); color: var(--brand-teal-bright); }

.link-quiet { color: var(--text-muted); font-weight: 600; font-size: 0.95rem; transition: color 0.2s; }
.link-quiet:hover { color: var(--text-main); }

.material-symbols-outlined { font-variation-settings: 'FILL' 0, 'wght' 500, 'GRAD' 0, 'opsz' 24; font-size: 20px; line-height: 1; }

.pulse-dot {
  width: 8px; height: 8px; border-radius: 50%; background: var(--brand-teal-bright);
  box-shadow: 0 0 0 0 rgba(34, 211, 216, 0.6); animation: pulse 2s infinite;
}
.eyebrow-live .pulse-dot, .status-badge .pulse-dot { background: var(--brand-terracotta-hover); box-shadow: 0 0 0 0 rgba(212, 59, 2, 0.6); }
.pulse-dot--sm { width: 7px; height: 7px; }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 currentColor; } 70% { box-shadow: 0 0 0 8px transparent; } 100% { box-shadow: 0 0 0 0 transparent; } }

.grad-text {
  background: linear-gradient(100deg, var(--brand-teal-bright), var(--brand-terracotta-hover));
  -webkit-background-clip: text; background-clip: text; color: transparent;
}

.avatar {
  --av: var(--brand-teal);
  width: 40px; height: 40px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center;
  background: var(--av); color: #fff; font-weight: 700; font-size: 0.8rem; border: 2px solid var(--bg-deep);
}
.avatar-lg { width: 52px; height: 52px; font-size: 1rem; }
.avatar-stack { display: flex; }
.avatar-stack .avatar { margin-left: -12px; }
.avatar-stack .avatar:first-child { margin-left: 0; }

.chip {
  background: var(--fill-xs); border: 1px solid var(--border-glass-strong); color: var(--text-muted);
  padding: 9px 16px; border-radius: var(--r-pill); font-size: 0.85rem; font-weight: 600; transition: all 0.2s var(--ease);
}
.chip:hover { border-color: var(--brand-teal-bright); color: var(--text-main); }
.chip.is-active { background: rgba(179,49,1,0.15); border-color: var(--brand-terracotta); color: var(--text-main); box-shadow: 0 0 16px var(--brand-terracotta-glow); }
.chip-row, .filter-row { display: flex; flex-wrap: wrap; gap: 10px; margin: 16px 0 24px; }

.swatch {
  --sw: #fff; width: 26px; height: 26px; border-radius: 50%; background: var(--sw);
  border: 2px solid var(--ring-soft); transition: all 0.15s var(--ease);
}
.swatch.is-active, .swatch:hover { border-color: var(--text-main); transform: scale(1.12); }

.rating { color: var(--hl-yellow); font-size: 0.85rem; }
.rating b { color: var(--text-main); }

/* ==========================================================================
   Navigation
   ========================================================================== */

.nav {
  position: sticky; top: 0; z-index: 100;
  background: var(--nav-bg); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border-glass); transition: box-shadow 0.3s;
}
.nav.is-scrolled { box-shadow: 0 8px 24px var(--shadow-nav); }
.nav-inner { max-width: 1280px; margin: 0 auto; padding: 0 20px; height: 76px; display: flex; align-items: center; justify-content: space-between; gap: 20px; }
@media (min-width: 900px) { .nav-inner { padding: 0 64px; } }

.brand { display: flex; align-items: center; gap: 10px; }
.brand-mark {
  width: 48px; height: auto; flex: none;
  filter: drop-shadow(0 0 10px var(--brand-teal-glow));
}
.brand-name { font-weight: 800; font-size: 1.05rem; letter-spacing: -0.01em; }

/* Logo ink — shared between the compact nav mark and the full footer lockup */
.logo-ink { fill: var(--brand-teal-bright); }
.logo-tagline { fill: var(--text-faint); }
.logo-pen-fill { fill: var(--brand-terracotta-hover); }
.logo-pen-hole { fill: var(--bg-surface-solid); }
.logo-pen-stroke { fill: none; stroke: var(--brand-terracotta-hover); stroke-width: 6; stroke-linecap: round; }

.logo-full { width: 100%; max-width: 220px; height: auto; filter: drop-shadow(0 0 14px var(--brand-teal-glow)); }

.nav-links { display: none; align-items: center; gap: 28px; }
.nav-links a { font-size: 0.9rem; font-weight: 600; color: var(--text-muted); transition: color 0.2s; }
.nav-links a:hover { color: var(--text-main); }
@media (min-width: 1080px) { .nav-links { display: flex; } }

.nav-actions { display: flex; align-items: center; gap: 16px; }
.nav-login { display: none; }
.nav-cta { display: none; }
@media (min-width: 1080px) { .nav-login, .nav-cta { display: inline-flex; } }

.nav-toggle { background: none; border: 1px solid var(--border-glass-strong); color: var(--text-main); width: 42px; height: 42px; border-radius: var(--r-sm); display: inline-flex; align-items: center; justify-content: center; }
@media (min-width: 1080px) { .nav-toggle { display: none; } }

.theme-toggle {
  position: relative; width: 42px; height: 42px; border-radius: var(--r-pill);
  background: var(--fill-md); border: 1px solid var(--border-glass-strong); color: var(--text-main);
  display: inline-flex; align-items: center; justify-content: center; flex: none; transition: border-color 0.2s;
}
.theme-toggle:hover { border-color: var(--brand-teal-bright); }
.theme-toggle .material-symbols-outlined { position: absolute; transition: opacity 0.25s var(--ease), transform 0.25s var(--ease); }
:root[data-theme="light"] .theme-toggle .theme-icon-dark { opacity: 0; transform: scale(0.5) rotate(-60deg); pointer-events: none; }
:root[data-theme="dark"] .theme-toggle .theme-icon-light { opacity: 0; transform: scale(0.5) rotate(60deg); pointer-events: none; }

.theme-toggle--mobile {
  width: 100%; height: auto; border-radius: var(--r-sm); padding: 12px; margin-top: 4px;
  display: flex; align-items: center; justify-content: center; gap: 8px; font-weight: 600; font-size: 0.9rem;
}
.theme-toggle--mobile .material-symbols-outlined { position: static; }
.theme-toggle--mobile::after { content: 'Switch to dark theme'; }
:root[data-theme="dark"] .theme-toggle--mobile::after { content: 'Switch to light theme'; }
.theme-toggle--mobile .theme-icon-light, .theme-toggle--mobile .theme-icon-dark { display: none; }

.nav-mobile { display: none; flex-direction: column; gap: 4px; padding: 12px 20px 20px; border-top: 1px solid var(--border-glass); }
.nav-mobile.is-open { display: flex; }
.nav-mobile a { padding: 12px 8px; border-radius: var(--r-sm); font-weight: 600; color: var(--text-muted); }
.nav-mobile a:hover { background: var(--fill-sm); color: var(--text-main); }
.nav-mobile .btn-terracotta { justify-content: center; margin-top: 8px; }

/* ==========================================================================
   Hero
   ========================================================================== */

.hero { padding: 64px 0 100px; }
.hero-inner { max-width: 1280px; margin: 0 auto; padding: 0 20px; display: grid; gap: 48px; align-items: center; }
@media (min-width: 900px) { .hero-inner { padding: 0 64px; grid-template-columns: 1fr 1fr; gap: 32px; } }

.hero-pill {
  display: inline-flex; align-items: center; gap: 8px; background: rgba(2,99,102,0.16);
  border: 1px solid var(--brand-teal); padding: 8px 16px; border-radius: var(--r-pill);
  font-size: 0.85rem; font-weight: 600; margin-bottom: 22px;
}
.hero-title { font-size: clamp(2.6rem, 5.5vw, 4.2rem); line-height: 1.05; font-weight: 800; letter-spacing: -0.02em; margin-bottom: 22px; }
.hero-sub { color: var(--text-muted); font-size: 1.1rem; max-width: 520px; margin-bottom: 32px; }
.hero-actions { display: flex; flex-direction: column; gap: 20px; }
@media (min-width: 560px) { .hero-actions { flex-direction: row; align-items: center; } }
.trust-row { display: flex; align-items: center; gap: 12px; }

/* CTA aura — a glow revealed behind the button on hover/focus, not just on it */
.cta-wrap { position: relative; display: inline-flex; isolation: isolate; }
.cta-wrap .cta-aura {
  position: absolute; inset: -22px; z-index: -1; border-radius: var(--r-pill);
  background: conic-gradient(from 90deg, var(--brand-teal-bright), var(--brand-terracotta-hover), var(--hl-yellow), var(--brand-teal-bright));
  filter: blur(22px); opacity: 0; transform: scale(0.55);
  transition: opacity 0.4s var(--ease), transform 0.4s var(--ease);
}
.cta-wrap:hover .cta-aura, .cta-wrap:focus-within .cta-aura { opacity: 0.55; transform: scale(1); }
.trust-text { color: var(--text-muted); font-size: 0.88rem; font-weight: 600; }

.hero-stage { position: relative; }
.frame { overflow: hidden; transform: rotate(1.2deg); transition: transform 0.5s var(--ease); }
.frame:hover { transform: rotate(0deg); }
.frame-bar { display: flex; align-items: center; justify-content: space-between; padding: 12px 16px; border-bottom: 1px solid var(--border-glass); }
.frame-title { font-size: 0.78rem; color: var(--text-muted); font-weight: 600; }
.frame-dots { display: flex; gap: 6px; }
.frame-dots i { width: 8px; height: 8px; border-radius: 50%; background: var(--border-glass-strong); display: block; }

.frame-video-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 2px; background: var(--border-glass); }
.video-tile {
  position: relative; aspect-ratio: 4/3; background: radial-gradient(circle at 30% 20%, rgba(2,99,102,0.35), #0a1316 70%);
  display: flex; align-items: flex-end; padding: 14px; border: 2px solid transparent; transition: border-color 0.4s;
}
.video-tile.is-active { border-color: var(--brand-teal-bright); box-shadow: inset 0 0 30px rgba(34,211,216,0.15); }
.video-avatar {
  --av: var(--brand-teal); position: absolute; top: 50%; left: 50%; transform: translate(-50%, -60%);
  width: 64px; height: 64px; border-radius: 50%; background: var(--av); color: #fff; font-weight: 800;
  display: flex; align-items: center; justify-content: center; font-size: 1.1rem;
}
.video-label { display: flex; flex-direction: column; font-size: 0.78rem; }
.video-label strong { font-size: 0.85rem; }
.video-label span { color: var(--text-muted); }
.live-badge { position: absolute; top: 10px; right: 10px; font-size: 0.65rem; font-weight: 700; color: var(--brand-terracotta-hover); background: rgba(179,49,1,0.2); padding: 3px 8px; border-radius: var(--r-pill); }

.frame-toolbar { display: flex; align-items: center; justify-content: center; gap: 10px; padding: 14px; }
.tool-btn {
  background: var(--fill-md); border: 1px solid var(--border-glass); color: var(--text-muted);
  width: 42px; height: 42px; border-radius: var(--r-sm); display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  transition: all 0.2s var(--ease); font-size: 0.8rem; font-weight: 600;
}
.tool-btn.is-on { background: rgba(34,211,216,0.14); border-color: var(--brand-teal-bright); color: var(--brand-teal-bright); }
.tool-btn:hover { border-color: var(--brand-teal-bright); color: var(--text-main); }
.tool-leave { background: rgba(179,49,1,0.18); border-color: var(--brand-terracotta); color: var(--brand-terracotta-hover); width: auto; padding: 0 16px; }
.tool-wide { width: auto; padding: 0 16px; }
.tool-leave:hover { background: var(--brand-terracotta); color: #fff; }

.stat-badge {
  position: absolute; left: -24px; bottom: -24px; display: flex; align-items: center; gap: 12px;
  padding: 16px; animation: bob 4s ease-in-out infinite;
}
@media (max-width: 640px) { .stat-badge { left: 8px; bottom: -20px; } }
@keyframes bob { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }
.stat-icon { width: 44px; height: 44px; border-radius: 50%; background: rgba(34,211,216,0.15); color: var(--brand-teal-bright); display: flex; align-items: center; justify-content: center; }
.stat-label { font-size: 0.68rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--text-muted); font-weight: 700; }
.stat-value { font-size: 1.1rem; font-weight: 800; }

/* ==========================================================================
   About strip
   ========================================================================== */

.about-strip { padding: 56px 0; border-top: 1px solid var(--border-glass); border-bottom: 1px solid var(--border-glass); }
.about-inner { display: grid; gap: 32px; }
@media (min-width: 900px) { .about-inner { grid-template-columns: 1fr 1.2fr; align-items: center; } }
.about-lede { font-size: 1.15rem; color: var(--text-muted); max-width: 480px; }
.about-stats { display: grid; grid-template-columns: repeat(2, 1fr); gap: 24px; }
@media (min-width: 560px) { .about-stats { grid-template-columns: repeat(4, 1fr); } }
.about-stat { text-align: center; }
.about-num { display: block; font-size: 2rem; font-weight: 800; color: var(--brand-teal-bright); }
.about-label { font-size: 0.78rem; color: var(--text-muted); font-weight: 600; }

/* ==========================================================================
   Booking Engine
   ========================================================================== */

.tutor-grid { display: grid; gap: 20px; margin-bottom: 32px; }
@media (min-width: 760px) { .tutor-grid { grid-template-columns: repeat(3, 1fr); } }
.tutor-grid--pair { max-width: 860px; }
@media (min-width: 640px) { .tutor-grid--pair { grid-template-columns: repeat(2, 1fr); } }
.tutor-card { padding: 22px; transition: transform 0.2s var(--ease), border-color 0.2s; }
.tutor-card:hover, .tutor-card:focus-within { transform: translateY(-4px); border-color: var(--brand-teal); }
.tutor-top { display: flex; gap: 14px; align-items: center; margin-bottom: 14px; }
.tutor-top h3 { font-size: 1.05rem; }
.tutor-flag { font-size: 0.78rem; color: var(--text-muted); }
.tutor-bio { color: var(--text-muted); font-size: 0.88rem; margin-bottom: 14px; min-height: 60px; }
.tutor-tags { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 16px; }
.tutor-tags .tag { background: rgba(2,99,102,0.12); color: var(--brand-teal-bright); border: 1px solid rgba(2,99,102,0.3); padding: 4px 10px; border-radius: var(--r-pill); font-size: 0.72rem; font-weight: 700; }
.tutor-meta { display: flex; justify-content: space-between; align-items: center; margin-bottom: 16px; }
.tutor-rate { font-weight: 800; }
.tutor-rate small { color: var(--text-muted); font-weight: 500; }
.tutor-actions { display: flex; gap: 10px; }
.tutor-actions .btn-sm { flex: 1; justify-content: center; }

.intro-panel { display: flex; align-items: center; gap: 16px; padding: 16px 20px; margin-bottom: 24px; }
.intro-panel[hidden] { display: none; }
.intro-video { width: 64px; height: 64px; border-radius: var(--r-sm); background: rgba(34,211,216,0.12); color: var(--brand-teal-bright); display: flex; align-items: center; justify-content: center; flex: none; }
.intro-name { font-weight: 700; margin-bottom: 4px; }
.intro-text { color: var(--text-muted); font-size: 0.85rem; }
.intro-panel #introClose { margin-left: auto; }

.booking-flow { padding: 28px; }
.flow-steps { display: flex; gap: 24px; margin-bottom: 24px; border-bottom: 1px solid var(--border-glass); padding-bottom: 16px; }
.flow-step { font-size: 0.82rem; font-weight: 700; color: var(--text-faint); }
.flow-step.is-active { color: var(--brand-teal-bright); }
.flow-pane { display: none; }
.flow-pane.is-active { display: block; }
.flow-label { color: var(--text-muted); font-weight: 600; font-size: 0.9rem; margin-bottom: 10px; }
.flow-btn-row { display: flex; gap: 12px; margin-top: 20px; }

.calendar-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 14px; }
.tz-select { display: flex; align-items: center; gap: 8px; font-size: 0.85rem; color: var(--text-muted); font-weight: 600; }
.tz-select select { background: var(--bg-surface-2); color: var(--text-main); border: 1px solid var(--border-glass-strong); border-radius: var(--r-sm); padding: 8px 10px; }

.calendar-days { display: grid; grid-template-columns: repeat(7, 1fr); gap: 8px; margin-bottom: 20px; }
.cal-day { background: var(--fill-xs); border: 1px solid var(--border-glass-strong); border-radius: var(--r-sm); padding: 10px 4px; text-align: center; }
.cal-day span { display: block; }
.cal-day .cal-dow { font-size: 0.65rem; color: var(--text-faint); text-transform: uppercase; }
.cal-day .cal-num { font-weight: 700; font-size: 1rem; }
.cal-day.is-active { border-color: var(--brand-terracotta); background: rgba(179,49,1,0.15); box-shadow: 0 0 16px var(--brand-terracotta-glow); }

.slot-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(90px, 1fr)); gap: 10px; margin-bottom: 8px; }
.slot-btn { background: var(--fill-xs); border: 1px solid var(--border-glass-strong); border-radius: var(--r-sm); padding: 10px; color: var(--text-muted); font-weight: 600; font-size: 0.85rem; }
.slot-btn.is-active { border-color: var(--brand-teal-bright); color: var(--brand-teal-bright); background: rgba(34,211,216,0.12); }

/* A taken slot stays legible rather than dimmed to near-invisible: the student
   should be able to read which times have gone, and the tooltip says why. */
.slot-btn.is-taken { color: var(--text-faint); background: transparent; border-style: dashed; text-decoration: line-through; cursor: not-allowed; }
.slot-btn:disabled { cursor: not-allowed; }

/* Marks a slot that falls on a different calendar day in the student's zone. */
.slot-shift { font-size: 0.6rem; font-weight: 700; margin-left: 3px; color: var(--brand-terracotta-hover); vertical-align: super; }

.slot-notice { grid-column: 1 / -1; margin: 0; padding: 14px 2px; color: var(--text-muted); font-size: 0.88rem; }

/* A fully-booked day is signalled on the calendar strip before it is opened. */
.cal-day.is-full { opacity: 0.45; }
.cal-day.is-full .cal-num { text-decoration: line-through; }

.summary-list { display: flex; flex-direction: column; gap: 10px; margin-bottom: 24px; }
.summary-list li { display: flex; justify-content: space-between; padding: 12px 16px; background: var(--fill-xs); border-radius: var(--r-sm); font-size: 0.9rem; }
.summary-list li span:first-child { color: var(--text-muted); }
.summary-list li span:last-child { font-weight: 700; }

.flow-pane[data-pane="success"] { text-align: center; padding: 20px 0; }
.success-icon { font-size: 52px; color: var(--brand-teal-bright); margin-bottom: 12px; }
.room-note { color: var(--text-muted); font-size: 0.85rem; margin: 12px 0 24px; }
.room-note code { background: var(--fill-md); padding: 3px 8px; border-radius: 4px; font-family: var(--font-mono); }
.flow-pane[data-pane="success"] .flow-btn-row { justify-content: center; }

/* ==========================================================================
   Classroom
   ========================================================================== */

.classroom-frame { position: relative; }
.classroom-shell { display: grid; gap: 0; overflow: hidden; }
@media (min-width: 900px) { .classroom-shell { grid-template-columns: 1fr 340px; } }
.classroom-shell[inert] { filter: blur(3px) saturate(0.7) brightness(0.85); user-select: none; }

.classroom-lock {
  position: absolute; inset: 0; z-index: 5; display: flex; align-items: center; justify-content: center;
  padding: 24px; background: var(--scrim-modal); border-radius: var(--r-lg);
}
.classroom-lock-card {
  max-width: 380px; padding: 32px; text-align: center; display: flex; flex-direction: column;
  align-items: center; gap: 12px;
}
.classroom-lock-icon {
  width: 60px; height: 60px; border-radius: 50%; font-size: 30px;
  background: rgba(179,49,1,0.15); color: var(--brand-terracotta-hover);
  display: flex; align-items: center; justify-content: center; margin-bottom: 6px;
}
.classroom-lock-card h3 { font-size: 1.15rem; }
.classroom-lock-card p { color: var(--text-muted); font-size: 0.9rem; margin-bottom: 6px; }
.classroom-lock-card .btn-terracotta { width: 100%; justify-content: center; }
.classroom-lock-card .link-quiet { font-size: 0.85rem; }
.classroom-main { padding: 20px; }
.stage { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-bottom: 16px; }
.stage-tile { aspect-ratio: 16/10; border-radius: var(--r-md); }
.hand-badge { position: absolute; top: 10px; left: 10px; background: var(--brand-terracotta); color: #fff; width: 30px; height: 30px; border-radius: 50%; display: flex; align-items: center; justify-content: center; }
.hand-badge[hidden] { display: none; }
.classroom-toolbar { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.session-timer { font-family: var(--font-mono); font-weight: 600; background: var(--fill-sm); padding: 10px 14px; border-radius: var(--r-sm); color: var(--text-muted); margin-left: auto; }

.classroom-side { border-top: 1px solid var(--border-glass); background: var(--scrim-sm); display: flex; flex-direction: column; }
@media (min-width: 900px) { .classroom-side { border-top: none; border-left: 1px solid var(--border-glass); } }
.side-panel { display: none; flex-direction: column; flex: 1; padding: 16px; min-height: 420px; }
.side-panel.is-active { display: flex; }
.board-tools { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; }
.board-tools .btn-sm { margin-left: auto; }
#whiteboard { width: 100%; height: 100%; background: #0a1316; border-radius: var(--r-sm); border: 1px solid var(--border-glass); cursor: crosshair; touch-action: none; }

.chat-log { flex: 1; overflow-y: auto; display: flex; flex-direction: column; gap: 12px; margin-bottom: 12px; max-height: 360px; }
.chat-msg strong { font-size: 0.78rem; color: var(--brand-teal-bright); display: block; margin-bottom: 2px; }
.chat-msg p { font-size: 0.88rem; }
.chat-doc { display: flex; align-items: center; gap: 8px; background: var(--fill-sm); padding: 8px 12px; border-radius: var(--r-sm); font-size: 0.82rem; color: var(--text-muted); width: fit-content; }
.chat-form { display: flex; gap: 8px; }
.chat-form input { flex: 1; background: var(--fill-sm); border: 1px solid var(--border-glass-strong); border-radius: var(--r-sm); padding: 10px 12px; color: var(--text-main); font-size: 0.88rem; }
.chat-form input::placeholder { color: var(--text-faint); }

/* ==========================================================================
   Storefront
   ========================================================================== */

.product-grid { display: grid; gap: 20px; margin-bottom: 64px; }
@media (min-width: 640px) { .product-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1000px) { .product-grid { grid-template-columns: repeat(3, 1fr); } }
.product-card { padding: 22px; display: flex; flex-direction: column; gap: 10px; transition: transform 0.2s var(--ease), border-color 0.2s; }
.product-card:hover { transform: translateY(-4px); border-color: var(--brand-teal); }
.product-card.is-hidden { display: none; }
.product-tag { align-self: flex-start; font-size: 0.68rem; text-transform: uppercase; letter-spacing: 0.08em; font-weight: 700; color: var(--brand-terracotta-hover); background: rgba(179,49,1,0.15); padding: 4px 10px; border-radius: var(--r-pill); }
.product-card h3 { font-size: 1.05rem; }
.product-card p { color: var(--text-muted); font-size: 0.88rem; flex: 1; }
.product-card p.product-instructor { color: var(--text-faint); font-size: 0.78rem; font-weight: 600; flex: none; margin-top: -6px; }
.product-foot { display: flex; justify-content: space-between; align-items: center; }
.price { font-weight: 800; font-size: 1.05rem; }

.pricing-block { text-align: center; padding-top: 20px; }
.pricing-block .section-title, .pricing-block .eyebrow { text-align: center; }
.pricing-sub { margin: 0 auto 8px; text-align: center; }
.plan-grid { display: grid; gap: 20px; margin-top: 32px; text-align: left; }
@media (min-width: 860px) { .plan-grid { grid-template-columns: repeat(3, 1fr); } }
.plan-card { padding: 28px; position: relative; display: flex; flex-direction: column; }
.plan-featured { border-color: var(--brand-terracotta); box-shadow: 0 0 30px var(--brand-terracotta-glow); }
.plan-badge { position: absolute; top: -12px; right: 24px; background: var(--brand-terracotta); color: #fff; font-size: 0.7rem; font-weight: 700; padding: 5px 12px; border-radius: var(--r-pill); }
.plan-card h3 { font-size: 1.2rem; margin-bottom: 8px; }
.plan-tagline { color: var(--text-muted); font-size: 0.85rem; margin-bottom: 20px; }
.plan-prices { display: flex; flex-direction: column; gap: 10px; margin-bottom: 22px; padding-bottom: 22px; border-bottom: 1px solid var(--border-glass); }
.plan-price-row { display: flex; justify-content: space-between; align-items: baseline; }
.plan-tutor { font-weight: 700; font-size: 0.92rem; }
.plan-tutor small { color: var(--text-faint); font-weight: 500; font-size: 0.72rem; margin-left: 4px; }
.plan-range { font-weight: 800; font-size: 1.05rem; white-space: nowrap; }
.plan-range small { font-size: 0.75rem; color: var(--text-muted); font-weight: 500; }
.plan-list { display: flex; flex-direction: column; gap: 12px; margin-bottom: 24px; }
.plan-list li { color: var(--text-muted); font-size: 0.9rem; padding-left: 24px; position: relative; }
.plan-list li::before { content: "✓"; position: absolute; left: 0; color: var(--brand-teal-bright); font-weight: 700; }
.plan-card .btn-lg, .plan-card .btn-ghost.btn-lg { width: 100%; justify-content: center; margin-top: auto; }

/* Cart */
.cart-fab {
  position: fixed; bottom: 28px; right: 28px; z-index: 90; width: 58px; height: 58px; border-radius: 50%;
  background: var(--brand-terracotta); color: #fff; border: none; display: flex; align-items: center; justify-content: center;
  box-shadow: 0 8px 24px var(--brand-terracotta-glow); transition: transform 0.2s var(--ease), opacity 0.25s var(--ease);
}
.cart-fab:hover { transform: scale(1.08); }
.cart-fab.is-clear { opacity: 0; pointer-events: none; transform: scale(0.85); }
.cart-count { position: absolute; top: -4px; right: -4px; background: var(--brand-teal-bright); color: #04191b; font-size: 0.7rem; font-weight: 800; width: 22px; height: 22px; border-radius: 50%; display: flex; align-items: center; justify-content: center; }

.drawer-overlay { position: fixed; inset: 0; background: var(--scrim-drawer); z-index: 110; opacity: 0; pointer-events: none; transition: opacity 0.3s; }
.drawer-overlay.is-open { opacity: 1; pointer-events: auto; }
.cart-drawer {
  position: fixed; top: 0; right: 0; height: 100%; width: min(400px, 100%); z-index: 111; border-radius: 0;
  transform: translateX(100%); transition: transform 0.35s var(--ease); display: flex; flex-direction: column; padding: 24px;
}
.cart-drawer.is-open { transform: translateX(0); }
.drawer-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 20px; }
.cart-items { flex: 1; overflow-y: auto; display: flex; flex-direction: column; gap: 14px; }
.cart-item { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding-bottom: 14px; border-bottom: 1px solid var(--border-glass); }
.cart-item-name { font-weight: 600; font-size: 0.9rem; }
.cart-item-price { color: var(--text-muted); font-size: 0.82rem; }
.qty-stepper { display: flex; align-items: center; gap: 8px; }
.qty-stepper button { width: 26px; height: 26px; border-radius: 6px; background: var(--fill-md); border: 1px solid var(--border-glass-strong); color: var(--text-main); }
.cart-empty { color: var(--text-muted); text-align: center; padding: 40px 0; }
.drawer-foot { border-top: 1px solid var(--border-glass); padding-top: 16px; margin-top: 16px; }
.cart-subtotal { display: flex; justify-content: space-between; margin-bottom: 16px; font-size: 1rem; }
.drawer-foot .btn-lg { width: 100%; justify-content: center; }

/* ==========================================================================
   Mock Exam Engine
   ========================================================================== */

.exam-shell { overflow: hidden; }
.exam-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 16px; padding: 14px 20px; border-bottom: 1px solid var(--border-glass); background: var(--scrim-md); }
.exam-module { font-size: 0.85rem; font-weight: 700; color: var(--text-muted); margin-right: auto; }
.highlighter-tools { display: flex; align-items: center; gap: 8px; }
.hl-icon { color: var(--text-faint); }
.exam-timer { font-family: var(--font-mono); font-weight: 700; font-size: 1.05rem; background: var(--fill-md); padding: 8px 16px; border-radius: var(--r-sm); }
.exam-timer.is-warning { color: var(--brand-terracotta-hover); background: rgba(179,49,1,0.18); animation: timerPulse 1s infinite; }
@keyframes timerPulse { 0%, 100% { box-shadow: 0 0 0 0 rgba(179,49,1,0.5); } 50% { box-shadow: 0 0 0 6px rgba(179,49,1,0); } }

.exam-split { display: grid; }
@media (min-width: 900px) { .exam-split { grid-template-columns: 1fr 1fr; } }

.passage-pane { background: var(--scrim-sm); padding: 24px; max-height: 620px; overflow-y: auto; }
.passage-paper {
  background: var(--paper); color: var(--paper-ink); font-family: var(--font-passage);
  border-radius: var(--r-md); padding: 28px; box-shadow: inset 0 0 0 1px var(--paper-rule), var(--paper-shadow);
}
.passage-kicker { font-family: var(--font-ui); font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.1em; font-weight: 700; color: var(--paper-muted); margin-bottom: 8px; }
.passage-paper h4 { font-family: var(--font-passage); font-size: 1.3rem; margin-bottom: 14px; color: var(--paper-ink); }
.passage-paper p { margin-bottom: 16px; line-height: 1.75; font-size: 1rem; }
.passage-table { width: 100%; border-collapse: collapse; margin: 8px 0 18px; font-family: var(--font-ui); font-size: 0.85rem; }
.passage-table th, .passage-table td { border: 1px solid var(--paper-rule); padding: 8px 10px; text-align: left; }
.passage-table th { background: rgba(33,28,20,0.06); font-weight: 700; }
.passage-notes { font-family: var(--font-ui); font-size: 0.85rem; }
.passage-notes li { position: relative; padding-left: 18px; margin-bottom: 6px; color: var(--paper-muted); }
.passage-notes li::before { content: "—"; position: absolute; left: 0; }
.passage-paper mark { padding: 0 1px; border-radius: 2px; color: var(--paper-ink); }
.passage-paper mark.hl-yellow { background: var(--hl-yellow); }
.passage-paper mark.hl-teal { background: var(--hl-teal); }
.passage-paper mark.hl-terracotta { background: var(--hl-terracotta); }

.question-pane { padding: 24px; display: flex; flex-direction: column; }
.question-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 18px; font-size: 0.85rem; color: var(--text-muted); font-weight: 700; }
.question-body { flex: 1; }
.q-stem { font-size: 1.02rem; font-weight: 600; margin-bottom: 18px; }
.q-options { display: flex; flex-direction: column; gap: 10px; }
.q-option { display: flex; align-items: center; gap: 10px; }
.option-item {
  flex: 1; display: flex; align-items: center; gap: 10px; background: var(--fill-xs);
  border: 1px solid var(--border-glass-strong); border-radius: var(--r-sm); padding: 12px 14px; font-size: 0.92rem;
  transition: all 0.15s var(--ease); text-align: left;
}
.option-item .opt-letter { width: 24px; height: 24px; border-radius: 50%; background: var(--fill-lg); display: inline-flex; align-items: center; justify-content: center; font-size: 0.75rem; font-weight: 700; flex: none; }
.option-item.selected { border-color: var(--brand-terracotta); background: rgba(179,49,1,0.15); box-shadow: 0 0 20px var(--brand-terracotta-glow); }
.option-item.selected .opt-letter { background: var(--brand-terracotta); color: #fff; }
.option-item.struck { opacity: 0.4; text-decoration: line-through; }
.strike-btn { width: 30px; height: 30px; border-radius: var(--r-sm); background: var(--fill-sm); border: 1px solid var(--border-glass-strong); color: var(--text-faint); font-size: 0.7rem; font-weight: 700; flex: none; }
.strike-btn.is-struck { color: var(--brand-terracotta-hover); border-color: var(--brand-terracotta); }

.question-foot { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 12px; margin-top: 24px; padding-top: 16px; border-top: 1px solid var(--border-glass); }
#flagBtn.is-flagged { color: var(--brand-terracotta-hover); border-color: var(--brand-terracotta); }

/* Modals */
.modal-overlay { position: fixed; inset: 0; background: var(--scrim-modal); z-index: 120; display: none; align-items: center; justify-content: center; padding: 20px; }
.modal-overlay.is-open { display: flex; }
.modal { max-width: 440px; padding: 28px; }
.modal h3 { margin-bottom: 14px; }
.modal p { color: var(--text-muted); margin-bottom: 20px; line-height: 1.6; }
/* Auth dialog */
.auth-modal { max-width: 420px; position: relative; text-align: left; }
.auth-modal h3 { margin-bottom: 6px; }
.auth-close { position: absolute; top: 14px; right: 14px; width: 34px; height: 34px; display: grid; place-items: center; border-radius: var(--r-sm); background: transparent; border: none; color: var(--text-muted); transition: background 0.2s var(--ease), color 0.2s var(--ease); }
.auth-close:hover { background: var(--fill-sm); color: var(--text-main); }
.auth-close .material-symbols-outlined { font-size: 20px; }

.auth-reason { font-size: 0.9rem; color: var(--brand-teal-bright); margin-bottom: 16px; }
.auth-modal p.auth-reason[hidden],
.auth-error[hidden] { display: none; }

.auth-error { background: var(--danger-soft); border: 1px solid var(--danger-border); color: var(--danger); border-radius: var(--r-sm); padding: 10px 12px; font-size: 0.88rem; font-weight: 600; margin-bottom: 16px; line-height: 1.45; }

.field { display: block; margin-bottom: 14px; }
.field[hidden] { display: none; }
.field > span { display: block; font-size: 0.8rem; font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase; color: var(--text-muted); margin-bottom: 6px; }
.field input { width: 100%; background: var(--bg-surface-2); color: var(--text-main); border: 1px solid var(--border-glass-strong); border-radius: var(--r-sm); padding: 12px 14px; font-family: var(--font-ui); font-size: 0.98rem; transition: border-color 0.2s var(--ease), box-shadow 0.2s var(--ease); }
.field input::placeholder { color: var(--text-faint); }
.field input:focus { outline: none; border-color: var(--brand-teal-bright); box-shadow: 0 0 0 3px var(--brand-teal-glow); }

.auth-submit { width: 100%; margin-top: 6px; }
.auth-submit[data-busy="true"] { opacity: 0.6; cursor: progress; }

.auth-switch { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 6px; margin: 18px 0 0; font-size: 0.9rem; color: var(--text-muted); }
.auth-switch button { background: none; border: none; padding: 0; cursor: pointer; color: var(--brand-teal-bright); font-weight: 700; font-size: 0.9rem; }
.auth-switch button:hover { text-decoration: underline; }

/* Nav account control */
.auth-slot { display: inline-flex; align-items: center; gap: 10px; }
.auth-who { font-size: 0.9rem; font-weight: 700; color: var(--text-main); }
.auth-signout { background: none; border: none; padding: 0; cursor: pointer; font-family: inherit; }
.nav-mobile .auth-slot { display: flex; }
.nav-mobile .auth-slot button { background: none; border: none; padding: 0; text-align: left; font-family: inherit; cursor: pointer; }

.matrix-modal { max-width: 380px; }
.matrix-grid { display: grid; grid-template-columns: repeat(5, 1fr); gap: 10px; margin: 16px 0; }
.matrix-cell { aspect-ratio: 1; border-radius: 6px; background: var(--fill-sm); border: 1px solid var(--border-glass-strong); color: var(--text-muted); font-weight: 700; font-size: 0.85rem; position: relative; }
.matrix-cell.is-answered { background: rgba(34,211,216,0.16); border-color: var(--brand-teal-bright); color: var(--brand-teal-bright); }
.matrix-cell.is-current { outline: 2px solid var(--brand-terracotta-hover); outline-offset: 2px; }
.matrix-cell.is-flagged::after { content: ""; position: absolute; top: 3px; right: 3px; width: 6px; height: 6px; border-radius: 50%; background: var(--brand-terracotta-hover); }
.matrix-legend { display: flex; flex-wrap: wrap; gap: 12px; font-size: 0.75rem; color: var(--text-muted); margin-bottom: 20px; }
.matrix-legend span { display: flex; align-items: center; gap: 6px; }
.dot { width: 9px; height: 9px; border-radius: 50%; display: inline-block; }
.dot-answered { background: var(--brand-teal-bright); }
.dot-flagged { background: var(--brand-terracotta-hover); }
.dot-current { border: 2px solid var(--brand-terracotta-hover); }
.dot-empty { border: 1px solid var(--border-glass-strong); }

/* ==========================================================================
   Dashboard
   ========================================================================== */

.score-grid { display: grid; gap: 20px; margin-bottom: 28px; }
@media (min-width: 760px) { .score-grid { grid-template-columns: repeat(3, 1fr); } }
.score-card { padding: 26px; text-align: center; }
.score-label { color: var(--text-muted); font-size: 0.82rem; font-weight: 700; margin-bottom: 18px; }
.gauge {
  --pct: 50; width: 130px; height: 130px; border-radius: 50%; margin: 0 auto 12px; display: flex; align-items: center; justify-content: center;
  background: conic-gradient(var(--brand-teal-bright) calc(var(--pct) * 1%), var(--fill-lg) 0);
  position: relative;
}
.gauge::before { content: ""; position: absolute; inset: 10px; border-radius: 50%; background: var(--bg-surface-solid); }
.gauge span { position: relative; font-size: 1.5rem; font-weight: 800; }
.gauge-alt { background: conic-gradient(var(--brand-terracotta-hover) calc(var(--pct) * 1%), var(--fill-lg) 0); }
.score-range { color: var(--text-faint); font-size: 0.8rem; }
.band-track { display: flex; gap: 4px; margin-bottom: 12px; justify-content: center; }
.band-seg { width: 18px; height: 44px; border-radius: 4px; background: var(--fill-lg); }
.band-seg.is-filled { background: var(--brand-teal-bright); }

.advice-card { padding: 24px; margin-bottom: 40px; }
.advice-card h3 { display: flex; align-items: center; gap: 10px; margin-bottom: 14px; font-size: 1.05rem; color: var(--hl-yellow); }
.advice-card ul { display: flex; flex-direction: column; gap: 10px; }
.advice-card li { color: var(--text-muted); font-size: 0.92rem; padding-left: 18px; position: relative; }
.advice-card li::before { content: "→"; position: absolute; left: 0; color: var(--brand-teal-bright); }

.domain-list { display: flex; flex-direction: column; gap: 16px; margin-bottom: 48px; }
.domain-row { display: grid; grid-template-columns: 180px 1fr 46px; align-items: center; gap: 14px; }
.domain-row span { font-size: 0.88rem; font-weight: 600; color: var(--text-muted); }
.domain-row b { text-align: right; font-size: 0.88rem; }
.track { height: 8px; border-radius: var(--r-pill); background: var(--fill-lg); overflow: hidden; }
.fill { height: 100%; width: 0%; background: linear-gradient(90deg, var(--brand-teal), var(--brand-teal-bright)); border-radius: var(--r-pill); transition: width 1.1s var(--ease); }

.hub-grid { display: grid; gap: 20px; }
@media (min-width: 700px) { .hub-grid { grid-template-columns: repeat(2, 1fr); } }
.hub-card { padding: 22px; }
.hub-card h4 { display: flex; align-items: center; gap: 8px; font-size: 0.95rem; margin-bottom: 14px; color: var(--text-main); }
.hub-card ul { display: flex; flex-direction: column; gap: 10px; }
.hub-card li { font-size: 0.85rem; color: var(--text-muted); background: var(--fill-xs); padding: 10px 12px; border-radius: var(--r-sm); }
.hub-empty { font-style: italic; color: var(--text-faint); background: transparent !important; padding: 0 !important; }
.forum-teaser { color: var(--text-muted); font-size: 0.88rem; margin-bottom: 14px; }

/* ==========================================================================
   Testimonials
   ========================================================================== */

.testi-grid { display: grid; gap: 20px; }
@media (min-width: 780px) { .testi-grid { grid-template-columns: repeat(3, 1fr); } }
.testi-card { padding: 26px; margin: 0; }
.testi-card p { font-size: 0.95rem; color: var(--text-main); margin-bottom: 16px; font-style: italic; }
.testi-card footer { color: var(--brand-teal-bright); font-size: 0.85rem; font-weight: 600; }
.testi-card footer strong { color: var(--text-main); }

/* ==========================================================================
   Footer
   ========================================================================== */

.footer { border-top: 1px solid var(--border-glass); padding: 64px 0 32px; margin-top: 40px; }
.footer-grid { display: grid; gap: 32px; margin-bottom: 40px; }
@media (min-width: 700px) { .footer-grid { grid-template-columns: 2fr 1fr 1fr; } }
.footer-brand p { color: var(--text-muted); font-size: 0.88rem; margin-top: 12px; max-width: 280px; }
.footer-col h4 { font-size: 0.78rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--text-faint); margin-bottom: 16px; }
.footer-col ul { display: flex; flex-direction: column; gap: 10px; }
.footer-col a { color: var(--text-muted); font-size: 0.9rem; transition: color 0.2s; }
.footer-col a:hover { color: var(--brand-teal-bright); }
.footer-bottom { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; padding-top: 24px; border-top: 1px solid var(--border-glass); }
.footer-social { display: flex; gap: 12px; }
.footer-social a { width: 36px; height: 36px; border-radius: 50%; border: 1px solid var(--border-glass-strong); display: flex; align-items: center; justify-content: center; color: var(--text-muted); }
.footer-social a:hover { color: var(--brand-teal-bright); border-color: var(--brand-teal-bright); }
.footer-bottom p { color: var(--text-faint); font-size: 0.82rem; }
.status-badge { display: flex; align-items: center; gap: 8px; font-size: 0.8rem; font-weight: 600; color: var(--text-muted); }

/* ==========================================================================
   Toast
   ========================================================================== */

.toast {
  position: fixed; bottom: 28px; left: 50%; transform: translateX(-50%) translateY(20px); z-index: 200;
  background: var(--bg-surface-solid); border: 1px solid var(--border-glass-strong); color: var(--text-main);
  padding: 12px 22px; border-radius: var(--r-pill); font-size: 0.88rem; font-weight: 600; box-shadow: var(--shadow-card);
  opacity: 0; pointer-events: none; transition: all 0.3s var(--ease);
}
.toast.is-visible { opacity: 1; transform: translateX(-50%) translateY(0); }

/* ================= Currency switch ================= */
/* Hidden until more than one currency is priced, so it appears on its own
   the moment lira prices are entered. */
.currency-switch { display: inline-flex; gap: 2px; padding: 3px; border-radius: var(--r-pill); background: var(--fill-sm); border: 1px solid var(--border-glass); }
.currency-switch[hidden] { display: none; }
.currency-btn { padding: 5px 11px; border: none; background: transparent; border-radius: var(--r-pill); color: var(--text-muted); font-family: inherit; font-size: 0.78rem; font-weight: 700; letter-spacing: 0.03em; cursor: pointer; transition: background 0.2s var(--ease), color 0.2s var(--ease); }
.currency-btn:hover { color: var(--text-main); }
.currency-btn.is-active { background: var(--brand-teal); color: #fff; }

/* A product with no price in the active currency cannot be bought. */
.product-card.is-unpriced .price { color: var(--text-faint); font-style: italic; }
.product-card.is-unpriced [data-add-cart] { opacity: 0.45; pointer-events: none; }

/* ================= Transfer instructions ================= */
.transfer-modal { max-width: 460px; position: relative; text-align: left; }
.transfer-icon { display: block; font-size: 34px; color: var(--brand-teal-bright); margin-bottom: 10px; }
.transfer-modal h3 { margin-bottom: 8px; }
.transfer-lede { color: var(--text-muted); font-size: 0.93rem; line-height: 1.6; margin-bottom: 18px; }

.transfer-details { display: grid; grid-template-columns: auto 1fr; gap: 0; margin: 0 0 16px; border: 1px solid var(--border-glass-strong); border-radius: var(--r-md); overflow: hidden; }
.transfer-details dt { padding: 11px 14px; font-size: 0.78rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.04em; color: var(--text-muted); background: var(--fill-xs); display: flex; align-items: center; }
.transfer-details dd { margin: 0; padding: 11px 14px; font-size: 0.95rem; font-weight: 600; color: var(--text-main); display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.transfer-details dt + dd { border-left: 1px solid var(--border-glass); }
.transfer-details dt:not(:first-of-type),
.transfer-details dd:not(:first-of-type) { border-top: 1px solid var(--border-glass); }
/* IBANs and references are long strings read character by character. */
.transfer-details dd span { font-family: var(--font-mono); font-size: 0.9rem; word-break: break-all; }

.copy-btn { flex-shrink: 0; padding: 4px 10px; border-radius: var(--r-sm); border: 1px solid var(--border-glass-strong); background: var(--fill-sm); color: var(--text-muted); font-family: inherit; font-size: 0.72rem; font-weight: 700; cursor: pointer; transition: color 0.2s var(--ease), border-color 0.2s var(--ease); }
.copy-btn:hover { color: var(--brand-teal-bright); border-color: var(--brand-teal-bright); }

.transfer-warn { display: flex; gap: 9px; align-items: flex-start; padding: 11px 13px; border-radius: var(--r-sm); background: var(--danger-soft); border: 1px solid var(--danger-border); color: var(--text-main); font-size: 0.86rem; line-height: 1.5; margin-bottom: 18px; }
.transfer-warn .material-symbols-outlined { font-size: 19px; color: var(--danger); flex-shrink: 0; }

.transfer-modal .btn-terracotta { width: 100%; }
.transfer-foot { text-align: center; font-size: 0.8rem; color: var(--text-faint); margin: 12px 0 0; }

@media (max-width: 520px) {
  .transfer-details { grid-template-columns: 1fr; }
  .transfer-details dt + dd { border-left: none; }
  .transfer-details dd { border-top: none; }
  .transfer-details dt:not(:first-of-type) { border-top: 1px solid var(--border-glass); }
}

/* ================= Admin (payments) ================= */
.admin-body { min-height: 100vh; }
.admin-head { border-bottom: 1px solid var(--border-glass); background: var(--nav-bg); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); position: sticky; top: 0; z-index: 40; }
.admin-head-inner { max-width: 980px; margin: 0 auto; padding: 14px 20px; display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.admin-head-actions { display: inline-flex; align-items: center; gap: 12px; }

.admin-main { max-width: 980px; margin: 0 auto; padding: 40px 20px 80px; }
.admin-gate { max-width: 400px; margin: 40px auto; padding: 30px; }
.admin-gate h1 { font-size: 1.4rem; margin-bottom: 8px; }
.admin-lede { color: var(--text-muted); font-size: 0.92rem; line-height: 1.6; margin-bottom: 22px; }

.admin-toolbar { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; justify-content: space-between; margin-bottom: 14px; }
.admin-tabs { display: flex; flex-wrap: wrap; gap: 8px; }
.admin-hint { color: var(--text-muted); font-size: 0.88rem; line-height: 1.6; margin-bottom: 22px; max-width: 62ch; }
.admin-empty { color: var(--text-muted); padding: 34px 4px; text-align: center; }

.admin-list { display: grid; gap: 14px; }
.admin-order { padding: 18px 20px; }
.admin-order-head { display: flex; align-items: baseline; justify-content: space-between; gap: 14px; margin-bottom: 8px; }
/* The reference is read off a bank statement and typed back — monospace so
   similar glyphs stay distinguishable. */
.admin-ref { font-family: var(--font-mono); font-size: 1rem; font-weight: 600; color: var(--brand-teal-bright); letter-spacing: 0.04em; }
.admin-amount { font-size: 1.2rem; }
.admin-student { font-size: 0.92rem; font-weight: 600; }
.admin-when { font-size: 0.8rem; color: var(--text-faint); margin-top: 2px; }

.admin-items { margin: 12px 0 0; padding-top: 12px; border-top: 1px solid var(--border-glass); display: grid; gap: 5px; }
.admin-items li { font-size: 0.9rem; color: var(--text-muted); }

.admin-actions { display: flex; gap: 10px; margin-top: 16px; }

@media (max-width: 520px) {
  .admin-order-head { flex-direction: column; gap: 4px; }
  .admin-actions { flex-direction: column; }
  .admin-actions button { width: 100%; justify-content: center; }
}

/* ================= Touch targets =================
   Pointer-coarse rather than a width breakpoint: the constraint is fingertip
   size, not screen size, so this also covers touch laptops and tablets.
   44px is the long-standing minimum below which mis-taps climb sharply. */
@media (pointer: coarse) {
  .chip,
  .slot-btn,
  .cal-day,
  .currency-btn,
  .copy-btn,
  .qty-stepper button {
    min-height: 44px;
  }
  .chip,
  .currency-btn { display: inline-flex; align-items: center; }
  .slot-btn { display: flex; align-items: center; justify-content: center; }
  .qty-stepper button { min-width: 44px; }
  /* Icon-only controls need width as well as height to be hittable. */
  .icon-btn,
  .auth-close,
  .tool-btn { min-width: 44px; min-height: 44px; }
}

/* Available to screen readers, removed from the visual layout. */
.visually-hidden { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }

/* ================= Hourly rate table ================= */
.rate-block { margin-top: 56px; padding-top: 44px; border-top: 1px solid var(--border-glass); }
.rate-title { font-size: 1.45rem; margin-bottom: 8px; }
.rate-sub { color: var(--text-muted); max-width: 60ch; margin-bottom: 26px; line-height: 1.65; }

/* Wide content scrolls inside its own box rather than pushing the page sideways. */
.rate-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; border-radius: var(--r-md); }
.rate-table { width: 100%; min-width: 480px; border-collapse: collapse; background: var(--bg-surface); border: 1px solid var(--border-glass); border-radius: var(--r-md); overflow: hidden; }

.rate-table thead th { text-align: left; padding: 14px 18px; font-size: 0.9rem; font-weight: 700; background: var(--fill-sm); border-bottom: 1px solid var(--border-glass-strong); white-space: nowrap; }
.rate-table thead th small { display: block; font-size: 0.7rem; font-weight: 500; color: var(--text-faint); letter-spacing: 0.03em; margin-top: 2px; }

.rate-table tbody th { text-align: left; padding: 16px 18px; font-size: 0.95rem; font-weight: 700; border-bottom: 1px solid var(--border-glass); }
.rate-table tbody th small { display: block; font-size: 0.75rem; font-weight: 500; color: var(--text-faint); margin-top: 3px; }
.rate-table tbody tr:last-child th,
.rate-table tbody tr:last-child td { border-bottom: none; }

.rate-table td { padding: 16px 18px; border-bottom: 1px solid var(--border-glass); border-left: 1px solid var(--border-glass); }
.rate-table td strong { display: block; font-size: 1.15rem; font-family: var(--font-mono); font-weight: 600; color: var(--brand-teal-bright); letter-spacing: -0.01em; }
.rate-table td small { display: block; font-size: 0.72rem; color: var(--text-faint); margin-top: 3px; }

/* The 1:1 row is the headline offer — give it the terracotta accent. */
.rate-table tbody tr:first-child td strong { color: var(--brand-terracotta-hover); font-size: 1.3rem; }

.rate-note { display: flex; gap: 10px; align-items: flex-start; margin-top: 20px; padding: 13px 15px; border-radius: var(--r-sm); background: var(--fill-xs); border: 1px solid var(--border-glass); color: var(--text-muted); font-size: 0.88rem; line-height: 1.55; max-width: 70ch; }
.rate-note .material-symbols-outlined { font-size: 20px; color: var(--brand-teal-bright); flex-shrink: 0; }

/* ================= Session balance ================= */
.session-status { margin: 18px 0; }
.session-status[hidden] { display: none; }

.session-have { display: flex; gap: 9px; align-items: center; padding: 12px 14px; border-radius: var(--r-sm); background: rgba(34, 211, 216, 0.1); border: 1px solid var(--brand-teal-bright); color: var(--text-main); font-size: 0.9rem; font-weight: 600; }
.session-have .material-symbols-outlined { font-size: 20px; color: var(--brand-teal-bright); }

.session-none { padding: 12px 14px; border-radius: var(--r-sm); background: var(--danger-soft); border: 1px solid var(--danger-border); color: var(--text-main); font-size: 0.9rem; font-weight: 600; margin-bottom: 12px; }

.session-packs { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: 10px; }
.session-pack { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 14px 10px; border-radius: var(--r-sm); background: var(--fill-xs); border: 1px solid var(--border-glass-strong); color: var(--text-main); font-family: inherit; cursor: pointer; transition: border-color 0.2s var(--ease), background 0.2s var(--ease), transform 0.2s var(--ease); }
.session-pack:hover { border-color: var(--brand-terracotta); background: var(--fill-sm); transform: translateY(-2px); }
.session-pack strong { font-size: 0.95rem; }
.session-pack span { font-family: var(--font-mono); font-size: 0.92rem; color: var(--brand-teal-bright); }

.session-save { display: block; font-size: 0.7rem; font-style: normal; font-weight: 700; color: var(--brand-terracotta-hover); letter-spacing: 0.02em; }
.admin-quoted { flex-basis: 100%; font-size: 0.78rem; color: var(--text-faint); }
.admin-order-head { flex-wrap: wrap; }
