/* ==========================================================================
   Waheed Shah tutoring – styles.css
   Mobile first (360px), then 768px, then 1280px. No frameworks, no build step.
   ========================================================================== */

/* ---------- 1. Design tokens ---------- */
:root {
  /* Colour (all text/background pairs below pass WCAG AA 4.5:1) */
  --navy: #0B2545;        /* headings, header            – 15.0:1 on white */
  --teal: #1F7A8C;        /* buttons, links              –  5.0:1 on white, 4.7:1 on page */
  --teal-dark: #17606F;   /* hover state                 –  7.0:1 on white */
  --page: #F7F9FC;        /* page background */
  --white: #FFFFFF;       /* cards */
  --border: #E2E8F0;
  --text: #1B2733;        /* body text                   – 14.6:1 on white */
  --muted: #5B6B7B;       /* secondary text              –  5.5:1 on white, 5.1:1 on page */
  --on-teal: #FFFFFF;     /* text on teal buttons        –  5.0:1 */

  /* Typography: system stack, no external fonts */
  --font: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --fs-body: 1.0625rem;                              /* 17px */
  --fs-small: 0.9375rem;                             /* 15px */
  --fs-h1: clamp(2rem, 1.5rem + 2.5vw, 3.25rem);
  --fs-h2: clamp(1.625rem, 1.3rem + 1.4vw, 2.25rem);
  --fs-h3: clamp(1.1875rem, 1.1rem + 0.4vw, 1.375rem);
  --lh-body: 1.65;
  --lh-heading: 1.2;

  /* Spacing: 8px scale */
  --s-1: 0.5rem;   /*  8 */
  --s-2: 1rem;     /* 16 */
  --s-3: 1.5rem;   /* 24 */
  --s-4: 2rem;     /* 32 */
  --s-5: 2.5rem;   /* 40 */
  --s-6: 3rem;     /* 48 */
  --s-8: 4rem;     /* 64 */
  --s-9: 4.5rem;   /* 72 */
  --section-pad: var(--s-6);                         /* 48px mobile */

  /* Shape and depth */
  --radius: 14px;
  --radius-pill: 999px;
  --shadow-sm: 0 1px 2px rgba(11, 37, 69, 0.06);
  --shadow: 0 2px 4px rgba(11, 37, 69, 0.04), 0 8px 24px rgba(11, 37, 69, 0.08);
  --shadow-hover: 0 4px 8px rgba(11, 37, 69, 0.06), 0 14px 32px rgba(11, 37, 69, 0.12);

  /* Layout */
  --container: 1100px;
  --gutter: var(--s-2);
  --header-h: 64px;
  --tap: 44px;                                       /* minimum tap target */
  --ease: cubic-bezier(0.2, 0.6, 0.2, 1);
}

@media (min-width: 768px) {
  :root { --gutter: var(--s-4); }
}
@media (min-width: 1280px) {
  :root { --section-pad: var(--s-9); }               /* 72px desktop */
}
@media (min-width: 768px) and (max-width: 1279px) {
  :root { --section-pad: var(--s-8); }
}

/* ---------- 2. Modern reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }
html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + var(--s-2));
}
body {
  min-height: 100vh;
  font-family: var(--font);
  font-size: var(--fs-body);
  line-height: var(--lh-body);
  color: var(--text);
  background: var(--page);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img, picture, svg, video { display: block; max-width: 100%; height: auto; }
input, button, textarea, select { font: inherit; color: inherit; }
button { cursor: pointer; }
p, li, h1, h2, h3 { overflow-wrap: break-word; }
ul[class], ol[class] { list-style: none; padding: 0; }
table { border-collapse: collapse; width: 100%; }

/* ---------- 3. Base typography ---------- */
h1, h2, h3 {
  font-weight: 650;
  line-height: var(--lh-heading);
  color: var(--navy);
  letter-spacing: -0.01em;
}
h1 { font-size: var(--fs-h1); letter-spacing: -0.02em; }
h2 { font-size: var(--fs-h2); }
h3 { font-size: var(--fs-h3); }
p + p { margin-top: var(--s-2); }
small, .small { font-size: var(--fs-small); }
strong { font-weight: 650; }

a {
  color: var(--teal);
  text-underline-offset: 0.2em;
  text-decoration-thickness: 1px;
}
a:hover { color: var(--teal-dark); text-decoration-thickness: 2px; }

/* Visible focus ring everywhere */
:focus-visible {
  outline: 3px solid var(--teal);
  outline-offset: 3px;
  border-radius: 4px;
}

/* ---------- 4. Layout ---------- */
.container {
  width: 100%;
  max-width: calc(var(--container) + 2 * var(--gutter));
  margin-inline: auto;
  padding-inline: var(--gutter);
}
.section { padding-block: var(--section-pad); }
.section--white { background: var(--white); border-block: 1px solid var(--border); }
.section--navy { background: var(--navy); color: var(--white); }
.section--navy h2, .section--navy h3 { color: var(--white); }
.section__intro { color: var(--muted); max-width: 60ch; margin-top: var(--s-1); }
.section__head { margin-bottom: var(--s-4); }

.grid { display: grid; gap: var(--s-3); }
@media (min-width: 768px) {
  .grid--2 { grid-template-columns: repeat(2, 1fr); }
  .grid--3 { grid-template-columns: repeat(3, 1fr); }
}
@media (min-width: 1280px) {
  .grid--4 { grid-template-columns: repeat(4, 1fr); }
}
@media (min-width: 768px) and (max-width: 1279px) {
  .grid--4 { grid-template-columns: repeat(2, 1fr); }
}

.stack > * + * { margin-top: var(--s-2); }
.cluster { display: flex; flex-wrap: wrap; gap: var(--s-1) var(--s-2); align-items: center; }

/* ---------- 5. Buttons (pill, 44px+ tap target) ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--s-1);
  min-height: var(--tap);
  padding: 0.75rem 1.5rem;
  border: 2px solid var(--teal);
  border-radius: var(--radius-pill);
  background: var(--teal);
  color: var(--on-teal);
  font-weight: 600;
  line-height: 1.2;
  text-align: center;
  text-decoration: none;
  transition: background-color 0.2s var(--ease), border-color 0.2s var(--ease),
              color 0.2s var(--ease), transform 0.2s var(--ease);
}
.btn:hover { background: var(--teal-dark); border-color: var(--teal-dark); color: var(--on-teal); }
.btn:active { transform: translateY(1px); }
.btn--secondary { background: transparent; color: var(--teal); }
.btn--secondary:hover { background: var(--teal); border-color: var(--teal); color: var(--on-teal); }
.btn--small { padding: 0.5rem 1.125rem; font-size: var(--fs-small); }
.btn--block { width: 100%; }
@media (max-width: 479px) {
  .btn-row .btn { width: 100%; }
}
.btn-row { display: flex; flex-wrap: wrap; gap: var(--s-1) var(--s-2); }

/* ---------- 6. Cards ---------- */
.card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: var(--s-3);
}
.card--hover { transition: box-shadow 0.25s var(--ease), transform 0.25s var(--ease); }
.card--hover:hover { box-shadow: var(--shadow-hover); transform: translateY(-2px); }
.card__icon { width: 40px; height: 40px; margin-bottom: var(--s-2); color: var(--teal); }
.card h3 { margin-bottom: var(--s-1); }
.card p { color: var(--muted); }

/* Small pill label, e.g. "First lesson free" */
.badge {
  display: inline-block;
  padding: 0.25rem 0.75rem;
  border-radius: var(--radius-pill);
  background: #E6F2F4;           /* teal tint; navy text 12:1 */
  color: var(--navy);
  font-size: var(--fs-small);
  font-weight: 600;
}

/* ---------- 7. Simple table (group prices) ---------- */
.table { background: var(--white); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; }
.table th, .table td { padding: var(--s-2); text-align: left; border-bottom: 1px solid var(--border); }
.table tr:last-child td { border-bottom: 0; }
.table thead th { background: var(--page); color: var(--navy); font-weight: 650; font-size: var(--fs-small); }

/* ---------- 8. Utilities ---------- */
.muted { color: var(--muted); }
.text-center { text-align: center; }
.mt-1 { margin-top: var(--s-1); } .mt-2 { margin-top: var(--s-2); }
.mt-3 { margin-top: var(--s-3); } .mt-4 { margin-top: var(--s-4); }
.mb-0 { margin-bottom: 0; }
.hidden, [hidden] { display: none !important; }

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

/* Skip link: visible only on keyboard focus */
.skip-link {
  position: absolute;
  top: var(--s-1);
  left: var(--s-1);
  z-index: 1000;
  padding: 0.75rem 1.25rem;
  background: var(--navy);
  color: var(--white);
  border-radius: var(--radius-pill);
  transform: translateY(-200%);
}
.skip-link:focus { transform: translateY(0); color: var(--white); }

/* Scroll reveal: only hidden when JS has added .js to <html>, so the page works without JS */
.js .reveal { opacity: 0; transform: translateY(12px); transition: opacity 0.6s var(--ease), transform 0.6s var(--ease); }
.js .reveal.is-visible { opacity: 1; transform: none; }

/* ---------- 9. Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  .js .reveal { opacity: 1; transform: none; }
}

/* ==========================================================================
   Page components (Phase 3)
   ========================================================================== */

.container--narrow { max-width: calc(780px + 2 * var(--gutter)); }

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--navy);
  color: var(--white);
  box-shadow: var(--shadow-sm);
}
.site-header__inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-1) var(--s-2);
  padding-block: var(--s-1);
}
.wordmark {
  display: inline-flex;
  align-items: center;
  min-height: var(--tap);
  color: var(--white);
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  text-decoration: none;
}
.wordmark:hover { color: var(--white); }
.site-header :focus-visible { outline-color: var(--white); }
.site-header .btn { background: var(--white); border-color: var(--white); color: var(--navy); }
.site-header .btn:hover { background: #E6F2F4; border-color: #E6F2F4; color: var(--navy); }

/* Mobile: nav sits on its own scrollable row (Phase 4 adds a menu button) */
.site-nav { order: 3; width: 100%; overflow-x: auto; }
.site-nav__list { display: flex; gap: var(--s-1); list-style: none; padding: 0; white-space: nowrap; }
.site-nav a {
  display: inline-flex;
  align-items: center;
  min-height: var(--tap);
  padding-inline: var(--s-1);
  color: var(--white);
  text-decoration: none;
  font-weight: 500;
}
.site-nav a:hover { text-decoration: underline; color: var(--white); }
@media (min-width: 900px) {
  .site-nav { order: 0; width: auto; overflow: visible; margin-left: auto; }
  .site-nav__list { gap: var(--s-2); }
}

/* ---------- Hero ---------- */
.hero { padding-block: var(--s-6) var(--s-6); background: var(--white); border-bottom: 1px solid var(--border); }
@media (min-width: 768px) { .hero { padding-block: var(--s-8); } }
.hero__inner { max-width: calc(820px + 2 * var(--gutter)); margin-inline: 0; }
@media (min-width: 1180px) { .hero__inner { margin-inline: auto; max-width: calc(var(--container) + 2 * var(--gutter)); } .hero h1, .hero__sub { max-width: 820px; } }
.hero__sub { font-size: 1.25rem; color: var(--muted); margin-block: var(--s-2) var(--s-4); }
.trust-strip {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-1) var(--s-3);
  margin-top: var(--s-4);
  padding: 0;
  list-style: none;
  color: var(--muted);
  font-size: var(--fs-small);
  font-weight: 500;
}
.trust-strip li::before { content: ""; display: inline-block; width: 8px; height: 8px; margin-right: 8px; border-radius: 50%; background: var(--teal); }

/* ---------- About ---------- */
.about { display: grid; gap: var(--s-4); align-items: center; }
.about__photo {
  width: 100%;
  max-width: 320px;
  aspect-ratio: 1;
  object-fit: cover;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}
@media (min-width: 768px) { .about { grid-template-columns: 320px 1fr; gap: var(--s-6); } }

/* ---------- Steps ---------- */
.steps { display: grid; gap: var(--s-3); padding: 0; list-style: none; counter-reset: step; }
.steps__item {
  position: relative;
  padding: var(--s-3) var(--s-3) var(--s-3) calc(var(--s-3) + 56px);
  background: var(--page);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  counter-increment: step;
}
.steps__item::before {
  content: counter(step);
  position: absolute;
  left: var(--s-3);
  top: var(--s-3);
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--navy);
  color: var(--white);
  font-weight: 700;
}
.steps__item p { color: var(--muted); }
@media (min-width: 1100px) { .steps { grid-template-columns: repeat(4, 1fr); } }

/* ---------- Prices ---------- */
.prices { display: grid; gap: var(--s-4); align-items: start; }
@media (min-width: 768px) { .prices { grid-template-columns: 1fr 1.2fr; gap: var(--s-6); } }
.price-card__amount { margin-block: var(--s-2) var(--s-1); font-size: 3rem; font-weight: 700; line-height: 1; color: var(--navy); }
.price-card__amount span { font-size: 1.125rem; font-weight: 500; color: var(--muted); }
.price-card p { color: var(--text); }

/* ---------- Checklist (safeguarding) ---------- */
.checklist { display: grid; gap: var(--s-2); padding: 0; list-style: none; max-width: 70ch; }
.checklist li { position: relative; padding-left: 36px; }
.checklist li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.25em;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--teal) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 12.5l4 4 8-9'/%3E%3C/svg%3E") center / 14px no-repeat;
}

/* ---------- Video facade container ---------- */
.video { aspect-ratio: 16 / 9; max-width: 800px; background: var(--navy); border-radius: var(--radius); overflow: hidden; }

/* ---------- FAQ ---------- */
.faq { display: grid; gap: var(--s-1); }
.faq details { background: var(--white); border: 1px solid var(--border); border-radius: var(--radius); }
.faq summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-2);
  min-height: var(--tap);
  padding: var(--s-2) var(--s-3);
  font-weight: 600;
  color: var(--navy);
  cursor: pointer;
  list-style: none;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; flex: none; font-size: 1.5rem; line-height: 1; color: var(--teal); }
.faq details[open] summary::after { content: "\2212"; }
.faq details p { padding: 0 var(--s-3) var(--s-3); color: var(--text); }

/* ---------- Contact ---------- */
.contact { display: grid; gap: var(--s-4); }
@media (min-width: 900px) { .contact { grid-template-columns: 1fr 1fr; gap: var(--s-8); align-items: start; } }
.section--navy a:not(.btn) { color: var(--white); }
.section--navy :focus-visible { outline-color: var(--white); }
.btn--light { background: var(--white); border-color: var(--white); color: var(--navy); }
.btn--light:hover { background: #E6F2F4; border-color: #E6F2F4; color: var(--navy); }
.btn--outline-light { background: transparent; border-color: var(--white); color: var(--white); }
.btn--outline-light:hover { background: var(--white); border-color: var(--white); color: var(--navy); }

.contact__form { color: var(--text); }
.contact__form :focus-visible { outline-color: var(--teal); }
.contact__form h3 { color: var(--navy); }
.field { margin-top: var(--s-2); }
.field label { display: block; margin-bottom: 4px; font-size: var(--fs-small); font-weight: 600; color: var(--navy); }
.field input, .field select, .field textarea {
  width: 100%;
  min-height: var(--tap);
  padding: 0.625rem 0.875rem;
  background: var(--white);
  border: 1px solid #8795A5;      /* 3:1+ against white for form controls */
  border-radius: 10px;
}
.contact__form button { margin-top: var(--s-3); }

/* ---------- Footer ---------- */
.site-footer { padding-block: var(--s-4); background: var(--page); border-top: 1px solid var(--border); color: var(--muted); font-size: var(--fs-small); }
.site-footer__inner { display: flex; flex-wrap: wrap; justify-content: space-between; gap: var(--s-1) var(--s-3); }
.site-footer ul { list-style: none; padding: 0; }
.site-footer a { display: inline-flex; align-items: center; min-height: var(--tap); }

/* ---------- Simple document pages (privacy, 404) ---------- */
.doc { padding-block: var(--s-6); }
.doc h1 { margin-bottom: var(--s-3); }
.doc h2 { margin-top: var(--s-4); margin-bottom: var(--s-1); font-size: var(--fs-h3); }
.doc ul { padding-left: 1.25rem; }

/* ==========================================================================
   Interactions (Phase 4)
   ========================================================================== */

/* Header shrinks on scroll */
.site-header__inner { transition: padding 0.25s var(--ease); }
.site-header.is-scrolled { box-shadow: var(--shadow); }
.site-header.is-scrolled .site-header__inner { padding-block: 0; }
.site-header.is-scrolled .wordmark { font-size: 1.125rem; }

/* Mobile menu button: only shown when JS is running, below 900px */
.nav-toggle { display: none; }
.js .nav-toggle {
  display: inline-grid;
  place-items: center;
  width: var(--tap);
  height: var(--tap);
  margin-left: auto;
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.5);
  border-radius: 10px;
  color: var(--white);
}
.nav-toggle__bars, .nav-toggle__bars::before, .nav-toggle__bars::after {
  display: block;
  width: 20px;
  height: 2px;
  background: currentColor;
  border-radius: 2px;
  transition: transform 0.2s var(--ease), background-color 0.2s;
}
.nav-toggle__bars { position: relative; }
.nav-toggle__bars::before, .nav-toggle__bars::after { content: ""; position: absolute; left: 0; }
.nav-toggle__bars::before { top: -6px; }
.nav-toggle__bars::after { top: 6px; }
.menu-open .nav-toggle__bars { background: transparent; }
.menu-open .nav-toggle__bars::before { transform: translateY(6px) rotate(45deg); }
.menu-open .nav-toggle__bars::after { transform: translateY(-6px) rotate(-45deg); }

@media (max-width: 899px) {
  .js .site-nav { display: none; overflow: visible; }
  .js .menu-open .site-nav { display: block; }
  .js .site-nav__list { flex-direction: column; gap: 0; padding-bottom: var(--s-1); }
  .js .site-nav a { width: 100%; padding-inline: 0; border-top: 1px solid rgba(255, 255, 255, 0.15); }
  .site-header__cta { font-size: 0.875rem; padding-inline: 0.875rem; }
}
@media (min-width: 900px) {
  .js .nav-toggle { display: none; }
}
@media (max-width: 359px) { .site-header__cta { display: none; } }

/* Video facade */
.video { position: relative; }
.video iframe, .video__play { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.video__play {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: var(--s-1);
  background: var(--navy);
  color: var(--white);
  font-weight: 600;
}
.video__play:hover svg { transform: scale(1.06); }
.video__play svg { transition: transform 0.2s var(--ease); }
.video__play:focus-visible { outline-color: var(--white); outline-offset: -6px; }

/* Four-across steps: number sits above the text so columns stay readable */
@media (min-width: 1100px) {
  .steps__item { padding: calc(var(--s-3) + 56px) var(--s-3) var(--s-3); }
}

/* Header: keep wordmark, CTA and menu button on one row at 360px */
.site-header__inner { gap: var(--s-1); }
.site-header__cta { order: 1; margin-left: auto; padding-inline: 0.75rem; }
.js .nav-toggle { order: 2; margin-left: 0; }
@media (min-width: 900px) { .site-header__cta { margin-left: var(--s-2); padding-inline: 1.125rem; } }
@media (max-width: 479px) {
  .wordmark { font-size: 1.0625rem; }
  .site-header__cta { font-size: 0.8125rem; padding: 0.5rem 0.625rem; }
}

/* ==========================================================================
   Visual refresh (Phase 7): distinctive hero, graphics and motion.
   Pure CSS + inline SVG. All motion is switched off by prefers-reduced-motion.
   ========================================================================== */
:root {
  --amber: #F4B942;          /* accent, used on dark navy only (11:1) */
  --sky: #5CC8D9;            /* light teal for dark backgrounds */
  --navy-2: #123A63;
  --on-dark: #D3DFEC;        /* body text on navy, 10:1 */
}

/* Scroll progress bar */
.progress { position: fixed; inset: 0 0 auto 0; height: 3px; z-index: 200; pointer-events: none; }
.progress span { display: block; height: 100%; transform: scaleX(0); transform-origin: 0 50%; background: linear-gradient(90deg, var(--sky), var(--amber)); }

/* Header: frosted navy */
.site-header { background: rgba(11, 37, 69, 0.92); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  overflow: hidden;
  padding-block: var(--s-6) calc(var(--s-9) + 24px);
  background: linear-gradient(160deg, var(--navy) 0%, var(--navy-2) 100%);
  color: var(--white);
  border-bottom: 0;
  isolation: isolate;
}
.hero::after {   /* pointer-following light */
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background: radial-gradient(420px circle at var(--mx, 70%) var(--my, 20%), rgba(92, 200, 217, 0.18), transparent 70%);
}
.hero__bg { position: absolute; inset: 0; z-index: -2; overflow: hidden; }
.blob { position: absolute; border-radius: 50%; filter: blur(70px); opacity: 0.55; animation: drift 18s ease-in-out infinite alternate; }
.blob--1 { width: 420px; height: 420px; background: #1F7A8C; top: -140px; right: -80px; }
.blob--2 { width: 340px; height: 340px; background: #2A4D8F; bottom: -120px; left: -100px; animation-delay: -6s; }
.grid-lines {
  position: absolute; inset: 0; opacity: 0.5;
  background-image: linear-gradient(rgba(255,255,255,.05) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.05) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: radial-gradient(ellipse at 70% 30%, #000 20%, transparent 70%);
  -webkit-mask-image: radial-gradient(ellipse at 70% 30%, #000 20%, transparent 70%);
}
@keyframes drift { to { transform: translate(40px, 30px) scale(1.12); } }

.hero__inner { display: grid; gap: var(--s-6); align-items: center; max-width: none; margin-inline: auto; width: 100%; }
.hero__inner { max-width: calc(var(--container) + 2 * var(--gutter)); }
@media (min-width: 960px) { .hero__inner { grid-template-columns: 1.15fr 0.85fr; } }
.hero h1 { color: var(--white); max-width: 18ch; text-wrap: balance; }
@media (min-width: 960px) { .hero h1 { max-width: none; } }
.grad {
  background: linear-gradient(90deg, var(--sky), var(--amber), var(--sky));
  background-size: 200% 100%;
  -webkit-background-clip: text; background-clip: text;
  color: transparent; -webkit-text-fill-color: transparent;
  animation: shine 8s linear infinite;
}
@keyframes shine { to { background-position: 200% 0; } }
.hero__sub { color: var(--on-dark); max-width: 36ch; }
.hero__eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  margin-bottom: var(--s-2); padding: 0.375rem 0.875rem;
  border: 1px solid rgba(255,255,255,.25); border-radius: var(--radius-pill);
  background: rgba(255,255,255,.08);
  font-size: var(--fs-small); font-weight: 600; color: var(--white);
}
.pulse { width: 9px; height: 9px; border-radius: 50%; background: var(--amber); box-shadow: 0 0 0 0 rgba(244,185,66,.7); animation: pulse 2s infinite; }
@keyframes pulse { 70% { box-shadow: 0 0 0 10px rgba(244,185,66,0); } 100% { box-shadow: 0 0 0 0 rgba(244,185,66,0); } }
.btn--lg { min-height: 52px; padding-inline: 1.75rem; font-size: 1.0625rem; }
.hero .btn--light { box-shadow: 0 8px 24px rgba(0,0,0,.25); }
.hero .btn--light:hover { transform: translateY(-2px); }
.hero .trust-strip { color: var(--on-dark); }
.hero .trust-strip li::before { background: var(--amber); }
.hero :focus-visible { outline-color: var(--white); }

/* Entrance on load */
.hero__copy > * { animation: rise 0.8s var(--ease) both; }
.hero__copy > *:nth-child(2) { animation-delay: .08s; } .hero__copy > *:nth-child(3) { animation-delay: .16s; }
.hero__copy > *:nth-child(4) { animation-delay: .24s; } .hero__copy > *:nth-child(5) { animation-delay: .32s; }
@keyframes rise { from { opacity: 0; transform: translateY(24px); } }

/* Hero artwork */
.hero__art { position: relative; min-height: 340px; animation: rise 1s .3s var(--ease) both; }
.art-card {
  position: absolute; border-radius: 16px; overflow: hidden;
  background: rgba(8, 26, 50, 0.78);
  border: 1px solid rgba(255,255,255,.16);
  box-shadow: 0 24px 60px rgba(0,0,0,.35);
  backdrop-filter: blur(6px);
}
.art-card--graph { top: 0; right: 0; width: 82%; animation: bob 7s ease-in-out infinite; }
.art-card--code { bottom: -8px; left: 0; width: 74%; animation: bob 8s -3s ease-in-out infinite; }
@keyframes bob { 50% { transform: translateY(-10px); } }
.art-card__bar { display: flex; align-items: center; gap: 6px; padding: 10px 14px; background: rgba(255,255,255,.07); font-size: 0.8125rem; color: var(--on-dark); font-family: ui-monospace, SFMono-Regular, Menlo, monospace; }
.art-card__bar i { width: 10px; height: 10px; border-radius: 50%; background: #ff6b6b; }
.art-card__bar i:nth-child(2) { background: var(--amber); } .art-card__bar i:nth-child(3) { background: #4cd08b; }
.art-card__bar span { margin-left: auto; }
.graph { width: 100%; height: auto; padding: 8px; }
.graph__root { opacity: 0; animation: pop .5s 2s var(--ease) forwards; }
.graph__wipe { transform-box: fill-box; transform-origin: 0 50%; transform: scaleX(0); animation: wipe 2.4s 0.8s var(--ease) forwards; }
@keyframes wipe { to { transform: scaleX(1); } }
.graph__dot { opacity: 0; transform-origin: 150px 140px; animation: pop .6s 2.6s var(--ease) forwards, pulse 2s 3.2s infinite; }
@keyframes pop { from { opacity: 0; transform: scale(0); } to { opacity: 1; transform: scale(1); } }
.art-card pre { margin: 0; padding: 14px 16px 16px; font: 0.9375rem/1.7 ui-monospace, SFMono-Regular, Menlo, monospace; color: #E6EEF7; white-space: pre; overflow: hidden; }
.k { color: #F59EC0; } .f { color: var(--sky); } .n { color: var(--amber); }
.caret { display: inline-block; width: 8px; height: 1.1em; margin-left: 3px; vertical-align: text-bottom; background: var(--amber); animation: blink 1s steps(1) infinite; }
@keyframes blink { 50% { opacity: 0; } }
.float { position: absolute; font-weight: 700; color: rgba(255,255,255,.28); font-family: ui-serif, Georgia, serif; animation: floaty 9s ease-in-out infinite; user-select: none; }
.float--1 { top: -18px; left: 4%; font-size: 3rem; }
.float--2 { top: 46%; right: -6px; font-size: 2.5rem; animation-delay: -2s; color: rgba(244,185,66,.5); }
.float--3 { bottom: 38%; left: -4px; font-size: 1.75rem; animation-delay: -4s; font-family: ui-monospace, monospace; }
.float--4 { bottom: -16px; right: 12%; font-size: 2rem; animation-delay: -6s; }
.float--5 { top: 40%; left: 30%; font-size: 1.25rem; animation-delay: -1s; font-family: ui-monospace, monospace; color: rgba(92,200,217,.5); }
@keyframes floaty { 50% { transform: translateY(-16px) rotate(6deg); } }
@media (max-width: 959px) { .hero__art { min-height: 300px; max-width: 460px; width: 100%; } }
@media (max-width: 479px) { .hero__art { min-height: 270px; } .art-card pre { font-size: 0.8125rem; } }

/* ---------- At a glance band (overlaps hero) ---------- */
.glance { position: relative; z-index: 2; margin-top: -48px; padding-bottom: var(--s-6); }
.glance__list {
  display: grid; grid-template-columns: repeat(2, 1fr); gap: 1px; padding: 0; list-style: none;
  background: var(--border); border: 1px solid var(--border); border-radius: var(--radius);
  box-shadow: var(--shadow-hover); overflow: hidden;
}
@media (min-width: 768px) { .glance__list { grid-template-columns: repeat(4, 1fr); } }
.glance__list li { display: flex; flex-direction: column; gap: 4px; padding: var(--s-3) var(--s-2); background: var(--white); text-align: center; }
.glance__list strong { font-size: clamp(1.75rem, 1.3rem + 2vw, 2.5rem); line-height: 1; color: var(--navy); font-variant-numeric: tabular-nums; }
.glance__list li:nth-child(odd) strong, .glance__list li:nth-child(even) strong { background: linear-gradient(90deg, var(--navy), var(--teal)); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; color: transparent; }
.glance__list li > span { color: var(--muted); font-size: var(--fs-small); }

/* ---------- Section headings: accent bar ---------- */
.section__head h2::after { content: ""; display: block; width: 56px; height: 4px; margin-top: 12px; border-radius: 4px; background: linear-gradient(90deg, var(--teal), var(--amber)); }
.section--navy .section__head h2::after, .section--navy h2::after { background: linear-gradient(90deg, var(--sky), var(--amber)); }

/* ---------- Subject cards ---------- */
.card--subject { position: relative; overflow: hidden; padding-top: calc(var(--s-3) + 6px); }
.card--subject::before { content: ""; position: absolute; inset: 0 0 auto 0; height: 6px; background: linear-gradient(90deg, var(--teal), var(--sky)); }
.card--cs::before { background: linear-gradient(90deg, var(--navy), var(--navy-2) 40%, var(--teal)); }
.card--subject::after { position: absolute; right: -4px; bottom: -22px; font-size: 6rem; font-weight: 800; line-height: 1; color: var(--teal); opacity: 0.07; font-family: ui-serif, Georgia, serif; pointer-events: none; transition: transform .4s var(--ease), opacity .4s; }
.card--subject:nth-child(1)::after { content: "÷"; } .card--subject:nth-child(2)::after { content: "∫"; }
.card--subject:nth-child(3)::after { content: "{ }"; font-family: ui-monospace, monospace; font-size: 4.5rem; }
.card--subject:nth-child(4)::after { content: "</>"; font-family: ui-monospace, monospace; font-size: 4rem; }
.card--subject:hover::after { transform: translateY(-8px) rotate(-6deg); opacity: 0.14; }
.card__icon { width: 56px; height: 56px; padding: 12px; color: var(--white); border-radius: 16px; background: linear-gradient(135deg, var(--teal), var(--navy)); box-shadow: 0 8px 18px rgba(31,122,140,.3); transition: transform .3s var(--ease); }
.card--subject:hover .card__icon { transform: rotate(-8deg) scale(1.08); }
.js .card--hover.is-visible:hover, .card--hover:hover { transform: translateY(-6px); }
.card p { position: relative; z-index: 1; }

/* ---------- About ---------- */
.about__frame { position: relative; width: 100%; max-width: 340px; }
.about__frame::before { content: ""; position: absolute; inset: 18px -18px -18px 18px; border-radius: var(--radius); background: linear-gradient(135deg, var(--teal), var(--navy)); opacity: .9; z-index: 0; }
.about__frame::after { content: ""; position: absolute; width: 96px; height: 96px; left: -26px; top: -26px; z-index: 0; background-image: radial-gradient(var(--teal) 2px, transparent 2px); background-size: 16px 16px; opacity: .5; }
.about__photo { position: relative; z-index: 1; max-width: none; transition: transform .5s var(--ease); }
.about__frame:hover .about__photo { transform: translate(-4px, -4px); }
.about__chip { position: absolute; z-index: 2; left: 16px; bottom: -14px; padding: .4rem .9rem; border-radius: var(--radius-pill); background: var(--white); color: var(--navy); font-size: var(--fs-small); font-weight: 650; box-shadow: var(--shadow); animation: bob 6s ease-in-out infinite; }
@media (min-width: 768px) { .about { grid-template-columns: 340px 1fr; } }

/* ---------- Steps ---------- */
.steps__item { transition: transform .3s var(--ease), box-shadow .3s var(--ease), border-color .3s; }
.steps__item:hover { transform: translateY(-4px); box-shadow: var(--shadow); border-color: var(--teal); }
.steps__item::before { background: linear-gradient(135deg, var(--teal), var(--navy)); box-shadow: 0 6px 14px rgba(11,37,69,.25); }

/* ---------- Prices ---------- */
.price-card { position: relative; overflow: hidden; background: linear-gradient(150deg, var(--navy), var(--navy-2)); border: 0; color: var(--white); }
.price-card::after { content: "£"; position: absolute; right: 10px; bottom: -40px; font-size: 9rem; font-weight: 800; color: rgba(255,255,255,.06); line-height: 1; }
.price-card .badge { background: var(--amber); color: var(--navy); }
.price-card__amount { color: var(--white); }
.price-card__amount span, .price-card p { color: var(--on-dark); }

/* ---------- Safeguarding & FAQ polish ---------- */
.checklist li { padding: var(--s-2) var(--s-2) var(--s-2) 56px; background: var(--page); border: 1px solid var(--border); border-radius: 12px; }
.checklist li::before { left: 18px; top: calc(var(--s-2) + 0.2em); }
.faq details { transition: border-color .2s, box-shadow .2s; }
.faq details[open] { border-color: var(--teal); box-shadow: var(--shadow); }
.faq summary:hover { color: var(--teal); }
.faq details[open] p { animation: rise .35s var(--ease); }

/* ---------- Contact ---------- */
.section--navy { position: relative; overflow: hidden; background: linear-gradient(160deg, var(--navy), var(--navy-2)); }
.section--navy::before { content: ""; position: absolute; width: 380px; height: 380px; right: -120px; top: -120px; border-radius: 50%; background: var(--teal); filter: blur(90px); opacity: .45; animation: drift 16s ease-in-out infinite alternate; }
.section--navy > .container { position: relative; }
.section--navy p { color: var(--on-dark); }
.section--navy .contact__form p { color: var(--muted); }

/* Reduced motion: also stop looping/decorative motion */
@media (prefers-reduced-motion: reduce) {
  .blob, .grad, .art-card, .float, .about__chip, .section--navy::before { animation: none !important; }
  .graph__wipe { transform: none; animation: none; }
  .graph__dot, .graph__root { opacity: 1; animation: none; }
  .hero__copy > *, .hero__art { animation: none; }
  .hero::after { display: none; }
}

/* QA fix: the offset frame behind the About photo pushed the page 2px wider than a 360px screen */
.about__frame::before { inset: 14px -12px -14px 12px; }
@media (min-width: 768px) { .about__frame::before { inset: 18px -18px -18px 18px; } }
