/* Markwell Tuition (sample website by Agile Release).
   Look: crisp white pages, sunflower highlighter and jade "teacher's ticks", ring-binder divider tabs for
   sections and subjects, and a school ruler for choosing a year. Type: Young Serif for headings, Lexend for
   everything else. */

@font-face {
  font-family: "Lexend";
  src: url("fonts/lexend-latin.woff2") format("woff2");
  font-weight: 300 800;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Young Serif";
  src: url("fonts/young-serif-latin.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

:root {
  --white: #ffffff;
  --paper: #fbfaf6;
  --mist: #eff7f3;
  --mist-2: #e2f0e9;
  --sun-wash: #fff9e3;
  --ink: #1a1d23;
  --ink-2: #252930;
  --ink-3: #343943;
  --text: #22262d;
  --muted: #555b64;
  --muted-light: #b9c0cb;
  --line: #e5e2d8;
  --line-strong: #c8c4b7;

  --jade: #0b7a57;
  --jade-dark: #075e43;
  --jade-deep: #06422f;
  --jade-soft: #dcf1e7;

  --sun: #ffd43b;
  --sun-light: #ffe58a;
  --sun-soft: #fff3c4;
  --sun-ink: #6e4f00;

  --maths: #1f56d6;
  --maths-ink: #1a47b3;
  --maths-soft: #e3ecff;
  --english: #c4306a;
  --english-ink: #a8214f;
  --english-soft: #ffe4ec;
  --science: #0f7d96;
  --science-ink: #0b6378;
  --science-soft: #dbf2f7;
  --eleven: #e0a000;
  --eleven-ink: #7a5300;
  --eleven-soft: #fff1c2;

  --radius: 14px;
  --radius-sm: 10px;
  --shadow: 0 1px 2px rgba(26, 29, 35, 0.06), 0 8px 24px rgba(26, 29, 35, 0.07);
  --shadow-lg: 0 2px 4px rgba(26, 29, 35, 0.05), 0 22px 50px rgba(26, 29, 35, 0.12);
  --header-h: 72px;
  --font: "Lexend", system-ui, -apple-system, "Segoe UI", sans-serif;
  --serif: "Young Serif", Georgia, "Times New Roman", serif;
}

/* ---------- Base ---------- */

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-padding-top: calc(var(--header-h) + 16px);
}

@media (prefers-reduced-motion: no-preference) {
  html {
    scroll-behavior: smooth;
  }
}

body {
  margin: 0;
  background: var(--white);
  color: var(--text);
  font-family: var(--font);
  font-size: 1rem;
  font-weight: 400;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img,
svg {
  display: block;
  max-width: 100%;
}

h1,
h2,
h3,
h4 {
  margin: 0;
  color: var(--ink);
  line-height: 1.15;
}

p {
  margin: 0 0 1rem;
}

a {
  color: var(--jade-dark);
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

a:hover {
  color: var(--jade-deep);
  text-decoration-thickness: 2px;
}

button,
input,
select,
textarea {
  font: inherit;
  color: inherit;
}

:focus-visible {
  outline: 3px solid var(--maths-ink);
  outline-offset: 2px;
  border-radius: 4px;
}

::selection {
  background: var(--sun-light);
  color: var(--ink);
}

.sprite {
  display: none;
}

.icon {
  width: 1.25em;
  height: 1.25em;
  flex: none;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.9;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.icon-sm {
  width: 1em;
  height: 1em;
}

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

.wrap {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

.skip-link {
  position: absolute;
  left: 12px;
  top: -60px;
  z-index: 100;
  padding: 10px 16px;
  background: var(--ink);
  color: var(--white);
  border-radius: 8px;
  font-weight: 600;
  text-decoration: none;
}

.skip-link:focus {
  top: 12px;
  color: var(--white);
}

/* ---------- Type ---------- */

.display {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(2.7rem, 6.2vw, 4.75rem);
  line-height: 1.02;
  letter-spacing: -0.015em;
}

.h1 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(2.3rem, 5vw, 3.6rem);
  line-height: 1.05;
  letter-spacing: -0.01em;
}

.h2 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(1.95rem, 3.6vw, 2.8rem);
  line-height: 1.08;
  letter-spacing: -0.01em;
}

.h3 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(1.4rem, 2.4vw, 1.75rem);
  line-height: 1.15;
}

.lead {
  font-size: clamp(1.05rem, 1.6vw, 1.2rem);
  line-height: 1.6;
  color: var(--text);
  max-width: 36em;
}

/* The highlighter: a sunflower swipe behind a word or two. */
.hl {
  position: relative;
  z-index: 0;
  white-space: nowrap;
}

.hl::after {
  content: "";
  position: absolute;
  z-index: -1;
  left: -0.08em;
  right: -0.14em;
  bottom: 0.02em;
  height: 0.52em;
  background: var(--sun);
  border-radius: 0.12em 0.45em 0.2em 0.5em;
  transform: skewX(-10deg) rotate(-1deg);
  transform-origin: left center;
}

html.js .hl-animate::after {
  transform: skewX(-10deg) rotate(-1deg) scaleX(0);
}

html.js .hl-animate.is-drawn::after {
  transform: skewX(-10deg) rotate(-1deg) scaleX(1);
  transition: transform 0.75s cubic-bezier(0.25, 0.8, 0.25, 1) 0.15s;
}

/* Divider-tab kicker: a tab that sits on the rule above a heading. */
.kicker {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin: 0;
  padding: 7px 16px 6px;
  border-radius: 10px 10px 0 0;
  background: var(--sun);
  color: var(--ink);
  font-size: 0.78rem;
  font-weight: 650;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  line-height: 1.2;
}

.kicker + .h2,
.kicker + .h1,
.kicker + .h3 {
  border-top: 3px solid var(--sun);
  padding-top: 18px;
}

.kicker-jade {
  background: var(--jade);
  color: var(--white);
}

.kicker-jade + .h2,
.kicker-jade + .h3 {
  border-top-color: var(--jade);
}

.kicker-sun {
  background: var(--sun);
}

.tag {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 9px;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 650;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  line-height: 1.5;
  vertical-align: 0.15em;
}

.tag-example {
  background: var(--english-soft);
  color: var(--english-ink);
  border: 1px dashed var(--english);
}

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 50px;
  padding: 12px 22px;
  border: 2px solid transparent;
  border-radius: 12px;
  font-weight: 600;
  font-size: 1rem;
  line-height: 1.2;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 0.15s, color 0.15s, border-color 0.15s, transform 0.15s, box-shadow 0.15s;
}

.btn:hover {
  text-decoration: none;
}

.btn:active {
  transform: translateY(1px);
}

.btn-sm {
  min-height: 42px;
  padding: 8px 16px;
  font-size: 0.92rem;
}

.btn-block {
  display: flex;
  width: 100%;
}

.btn-primary {
  background: var(--jade);
  color: var(--white);
  box-shadow: 0 3px 0 var(--jade-deep);
}

.btn-primary:hover {
  background: var(--jade-dark);
  color: var(--white);
}

.btn-primary:active {
  box-shadow: 0 2px 0 var(--jade-deep);
}

.btn-sun {
  background: var(--sun);
  color: var(--ink);
  box-shadow: 0 3px 0 #c99a00;
}

.btn-sun:hover {
  background: var(--sun-light);
  color: var(--ink);
}

.btn-dark {
  background: var(--ink);
  color: var(--white);
}

.btn-dark:hover {
  background: var(--ink-3);
  color: var(--white);
}

.btn-outline {
  border-color: var(--ink);
  color: var(--ink);
  background: var(--white);
}

.btn-outline:hover {
  background: var(--ink);
  color: var(--white);
}

.btn-outline-dark {
  border-color: var(--ink);
  color: var(--ink);
  background: transparent;
}

.btn-outline-dark:hover {
  background: var(--ink);
  color: var(--sun);
}

.btn-ghost-light {
  border-color: rgba(255, 255, 255, 0.35);
  color: var(--white);
  background: transparent;
}

.btn-ghost-light:hover {
  border-color: var(--white);
  background: rgba(255, 255, 255, 0.08);
  color: var(--white);
}

.btn[disabled],
.btn[aria-disabled="true"] {
  opacity: 0.55;
  cursor: not-allowed;
}

/* ---------- Sample bar, header and menu ---------- */

.sample-bar {
  background: var(--ink);
  color: #e9ebef;
  font-size: 0.85rem;
  line-height: 1.45;
}

.sample-bar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px 20px;
  padding-top: 8px;
  padding-bottom: 8px;
}

.sample-bar p {
  margin: 0;
}

.sample-bar strong {
  color: var(--sun);
  font-weight: 600;
}

.sample-bar a {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  flex: none;
  color: var(--white);
  font-weight: 600;
}

.sample-bar a:hover {
  color: var(--sun);
}

.sample-bar :focus-visible {
  outline-color: var(--sun);
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.96);
  border-bottom: 1px solid transparent;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.site-header.is-stuck {
  border-bottom-color: var(--line);
  box-shadow: 0 6px 20px rgba(26, 29, 35, 0.06);
}

.header-inner {
  display: flex;
  align-items: center;
  gap: 24px;
  min-height: var(--header-h);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--ink);
  text-decoration: none;
  flex: none;
}

.brand:hover {
  color: var(--ink);
}

.brand-mark {
  width: 38px;
  height: 38px;
}

.bm-box {
  fill: var(--sun);
}

.bm-tick {
  fill: none;
  stroke: var(--jade-dark);
  stroke-width: 4.2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.brand-name {
  font-family: var(--serif);
  font-size: 1.5rem;
  line-height: 1;
  letter-spacing: -0.01em;
}

.brand-name span {
  font-family: var(--font);
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-left: 2px;
  color: var(--muted);
}

.brand-light {
  color: var(--white);
}

.brand-light:hover {
  color: var(--white);
}

.brand-light .brand-name span {
  color: var(--muted-light);
}

.brand-light .bm-tick {
  stroke: #5fd3a6;
}

.nav {
  margin-left: auto;
}

.nav ul {
  display: flex;
  gap: 4px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.nav a {
  display: block;
  padding: 8px 12px;
  border-radius: 8px;
  color: var(--ink);
  font-weight: 500;
  font-size: 0.95rem;
  text-decoration: none;
}

.nav a:hover {
  background: var(--sun-soft);
  color: var(--ink);
}

.nav a[aria-current="page"] {
  background: var(--sun);
}

.header-cta {
  flex: none;
}

.menu-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  width: 46px;
  height: 46px;
  margin-left: auto;
  border: 2px solid var(--ink);
  border-radius: 10px;
  background: var(--white);
  cursor: pointer;
}

.menu-toggle .icon {
  width: 22px;
  height: 22px;
}

@media (max-width: 1080px) {
  .nav a {
    padding: 8px 9px;
    font-size: 0.9rem;
  }
}

@media (max-width: 960px) {
  .menu-toggle:not([hidden]) {
    display: inline-flex;
  }

  .header-inner {
    gap: 12px;
  }

  .nav {
    position: absolute;
    left: 0;
    right: 0;
    top: 100%;
    margin: 0;
    background: var(--white);
    border-bottom: 1px solid var(--line);
    box-shadow: 0 18px 30px rgba(26, 29, 35, 0.1);
    display: none;
  }

  html:not(.js) .nav {
    position: static;
    display: block;
    box-shadow: none;
    border: 0;
  }

  .nav.is-open {
    display: block;
  }

  .nav ul {
    flex-direction: column;
    padding: 10px 16px 18px;
  }

  .nav a {
    padding: 13px 12px;
    font-size: 1.05rem;
    border-bottom: 1px solid var(--line);
    border-radius: 0;
  }

  .nav li:last-child a {
    border-bottom: 0;
  }

  .header-cta {
    margin-left: auto;
  }

  .header-cta + .menu-toggle {
    margin-left: 0;
  }
}

@media (max-width: 520px) {
  .wrap {
    padding: 0 18px;
  }

  .header-cta {
    padding: 8px 12px;
    font-size: 0.85rem;
  }

  .brand-mark {
    width: 32px;
    height: 32px;
  }

  .brand-name {
    font-size: 1.3rem;
  }

  .brand-name span {
    display: none;
  }

  .sample-bar-inner {
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (max-width: 359px) {
  .header-cta {
    display: none;
  }
}

/* ---------- Sections ---------- */

.section {
  padding: clamp(64px, 9vw, 112px) 0;
}

.section-mist {
  background: var(--mist);
}

.section-sun-wash {
  background: var(--sun-wash);
}

.section-head {
  max-width: 760px;
  margin-bottom: clamp(32px, 5vw, 52px);
}

.section-head > p:last-child {
  margin: 16px 0 0;
  color: var(--muted);
  font-size: 1.08rem;
}

.section-head-split {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr);
  gap: 20px 56px;
  align-items: end;
  max-width: none;
}

.section-head-split > p:last-child {
  margin: 0 0 4px;
  max-width: 34em;
}

@media (max-width: 860px) {
  .section-head-split {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* Reveal on scroll (only when JavaScript runs and motion is welcome). */
@media (prefers-reduced-motion: no-preference) {
  html.js [data-reveal] {
    opacity: 0;
    transform: translateY(18px);
    transition: opacity 0.6s ease, transform 0.6s ease;
  }

  html.js [data-reveal].is-visible {
    opacity: 1;
    transform: none;
  }
}

.ticks {
  margin: 0 0 1rem;
  padding: 0;
  list-style: none;
}

.ticks li {
  position: relative;
  padding-left: 32px;
  margin-bottom: 10px;
}

.ticks li::before {
  content: "";
  position: absolute;
  left: 2px;
  top: 0.3em;
  width: 20px;
  height: 14px;
  border-left: 3px solid var(--jade);
  border-bottom: 3px solid var(--jade);
  border-radius: 0 0 0 3px;
  transform: rotate(-48deg) skewX(-6deg) scale(0.72, 0.62);
  transform-origin: 30% 60%;
}

/* ---------- Hero ---------- */

.hero {
  position: relative;
  overflow: hidden;
  padding: clamp(40px, 7vw, 88px) 0 clamp(56px, 8vw, 104px);
  background: var(--white);
}

.hero::before {
  content: "";
  position: absolute;
  right: -180px;
  top: -220px;
  width: 720px;
  height: 720px;
  border-radius: 50%;
  background: var(--sun-wash);
  z-index: 0;
}

.hero-inner {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(0, 0.92fr);
  gap: 56px;
  align-items: center;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 22px;
  padding: 6px 14px 6px 10px;
  border-radius: 999px;
  background: var(--mist);
  color: var(--jade-deep);
  font-weight: 600;
  font-size: 0.9rem;
}

.hero .display {
  margin-bottom: 24px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin: 30px 0 30px;
}

.hero-ticks {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 26px;
  margin: 0;
  padding: 0;
  list-style: none;
  font-weight: 600;
  color: var(--ink);
}

.hero-ticks li {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.hero-ticks .icon {
  color: var(--jade);
  stroke-width: 2.6;
  width: 22px;
  height: 22px;
}

/* The class finder: a binder page with subject tabs along its top edge. */
.finder {
  position: relative;
  filter: drop-shadow(0 22px 40px rgba(26, 29, 35, 0.12)) drop-shadow(0 2px 3px rgba(26, 29, 35, 0.06));
}

.finder-tabs {
  display: flex;
  gap: 4px;
  padding: 0 14px;
}

.ftab {
  position: relative;
  padding: 9px 14px 8px;
  border: 0;
  border-radius: 10px 10px 0 0;
  background: var(--line);
  color: var(--ink);
  font-weight: 600;
  font-size: 0.86rem;
  line-height: 1.2;
  cursor: pointer;
  transform: translateY(3px);
  transition: transform 0.15s, background-color 0.15s;
}

.ftab:hover {
  transform: translateY(0);
}

.ftab-maths {
  background: var(--maths-soft);
  color: var(--maths-ink);
}

.ftab-english {
  background: var(--english-soft);
  color: var(--english-ink);
}

.ftab-science {
  background: var(--science-soft);
  color: var(--science-ink);
}

.ftab-elevenplus {
  background: var(--eleven-soft);
  color: var(--eleven-ink);
}

.ftab[aria-pressed="true"] {
  background: var(--white);
  color: var(--ink);
  transform: none;
  box-shadow: inset 0 3px 0 var(--sun);
}

.ftab-maths[aria-pressed="true"] {
  box-shadow: inset 0 3px 0 var(--maths);
}

.ftab-english[aria-pressed="true"] {
  box-shadow: inset 0 3px 0 var(--english);
}

.ftab-science[aria-pressed="true"] {
  box-shadow: inset 0 3px 0 var(--science);
}

.ftab-elevenplus[aria-pressed="true"] {
  box-shadow: inset 0 3px 0 var(--eleven);
}

.finder-page {
  position: relative;
  padding: 24px 24px 18px 52px;
  background: var(--white);
  border-radius: 4px var(--radius) var(--radius) var(--radius);
}

/* Punched holes down the left margin. */
.finder-page::before {
  content: "";
  position: absolute;
  left: 18px;
  top: 34px;
  bottom: 34px;
  width: 14px;
  background:
    radial-gradient(circle at 50% 7px, var(--paper) 0 6px, var(--line) 6.5px 7px, transparent 7.5px) 0 0 / 14px 33.33% repeat-y;
}

.finder-page::after {
  content: "";
  position: absolute;
  left: 40px;
  top: 0;
  bottom: 0;
  width: 2px;
  background: var(--english-soft);
}

.finder-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.finder-title {
  font-family: var(--serif);
  font-weight: 400;
  font-size: 1.45rem;
}

.finder-year select {
  min-height: 42px;
  padding: 6px 34px 6px 12px;
  border: 2px solid var(--ink);
  border-radius: 10px;
  background: var(--white);
  font-weight: 600;
  font-size: 0.92rem;
}

.finder-list {
  margin: 0;
  padding: 0;
  list-style: none;
  min-height: 292px;
}

.finder-fallback,
.finder-empty {
  padding: 18px 0;
  color: var(--muted);
}

.finder-day {
  margin: 12px 0 4px;
  font-size: 0.76rem;
  font-weight: 650;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}

.finder-day:first-child {
  margin-top: 0;
}

.finder-item a {
  display: grid;
  grid-template-columns: 70px minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  padding: 10px 10px 10px 0;
  border-bottom: 1px dashed var(--line);
  color: var(--ink);
  text-decoration: none;
}

.finder-item a:hover {
  background: linear-gradient(90deg, transparent, var(--sun-wash) 20%);
}

.finder-time {
  font-weight: 650;
  font-size: 0.98rem;
}

.finder-name {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 600;
  line-height: 1.3;
}

.finder-meta {
  display: block;
  color: var(--muted);
  font-size: 0.84rem;
  line-height: 1.4;
}

.finder-places {
  font-size: 0.8rem;
  font-weight: 650;
  color: var(--jade-dark);
  white-space: nowrap;
}

.finder-places.is-few {
  color: var(--english-ink);
}

.finder-foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 6px 16px;
  margin: 14px 0 0;
  font-size: 0.86rem;
  color: var(--muted);
}

.finder-foot a {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-weight: 600;
}

/* A small coloured square that marks a subject. */
.sw {
  display: inline-block;
  flex: none;
  width: 10px;
  height: 10px;
  border-radius: 3px;
  background: var(--jade);
}

.sw-maths {
  background: var(--maths);
}

.sw-english {
  background: var(--english);
}

.sw-science {
  background: var(--science);
}

.sw-elevenplus {
  background: var(--eleven);
}

@media (max-width: 960px) {
  .hero-inner {
    grid-template-columns: minmax(0, 1fr);
    gap: 44px;
  }

  .hero::before {
    width: 520px;
    height: 520px;
    right: -260px;
    top: -200px;
  }
}

@media (max-width: 520px) {
  .finder-tabs {
    padding: 0 6px;
    gap: 3px;
  }

  .ftab {
    padding: 9px 9px 8px;
    font-size: 0.8rem;
  }

  .finder-page {
    padding: 20px 16px 16px 16px;
  }

  .finder-page::before,
  .finder-page::after {
    display: none;
  }

  .finder-head {
    flex-wrap: wrap;
  }

  .finder-item a {
    grid-template-columns: 62px minmax(0, 1fr);
  }

  .finder-places {
    grid-column: 2;
  }

  .finder-list {
    min-height: 0;
  }

  .hero-actions .btn {
    flex: 1 1 100%;
  }
}

/* ---------- Subjects: the year ruler ---------- */

.ruler-wrap {
  margin-bottom: 28px;
}

.ruler {
  position: relative;
  padding: 0 0 6px;
}

.ruler-years {
  display: grid;
  grid-template-columns: 1.1fr repeat(14, 1fr);
  border-radius: 12px;
  background:
    repeating-linear-gradient(90deg, rgba(26, 29, 35, 0.55) 0 1.5px, transparent 1.5px calc(100% / 60)) left top / 100% 9px no-repeat,
    repeating-linear-gradient(90deg, rgba(26, 29, 35, 0.35) 0 1px, transparent 1px calc(100% / 120)) left top / 100% 5px no-repeat,
    var(--sun);
  box-shadow: inset 0 -4px 0 rgba(150, 110, 0, 0.18), 0 2px 0 rgba(26, 29, 35, 0.08);
  overflow: hidden;
}

.ruler-years button {
  position: relative;
  min-height: 64px;
  padding: 16px 0 6px;
  border: 0;
  background: transparent;
  color: var(--ink);
  font-family: var(--serif);
  font-size: 1.35rem;
  line-height: 1;
  cursor: pointer;
}

.ruler-years button + button::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  width: 2px;
  height: 18px;
  background: var(--ink);
  opacity: 0.75;
}

.ruler-years button:hover {
  background: rgba(255, 255, 255, 0.4);
}

.ruler-years button[aria-pressed="true"] {
  background: var(--ink);
  color: var(--sun);
}

.ruler-years button:focus-visible {
  outline: 3px solid var(--maths-ink);
  outline-offset: -3px;
  border-radius: 6px;
}

.ruler-years .ruler-all {
  font-family: var(--font);
  font-size: 0.85rem;
  font-weight: 650;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.ruler-years small {
  display: block;
  margin-top: 6px;
  font-family: var(--font);
  font-size: 0.62rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  opacity: 0.7;
}

.ruler-years .is-before {
  color: rgba(26, 29, 35, 0.62);
}

.ruler-years .is-before[aria-pressed="true"] {
  color: var(--sun);
}

.ruler-stages {
  display: grid;
  grid-template-columns: 1.1fr repeat(14, 1fr);
  margin-top: 8px;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--muted);
}

.rs {
  position: relative;
  padding: 10px 4px 0;
  text-align: center;
  line-height: 1.25;
}

.rs::before {
  content: "";
  position: absolute;
  left: 6px;
  right: 6px;
  top: 0;
  height: 7px;
  border: 2px solid var(--line-strong);
  border-top: 0;
  border-radius: 0 0 6px 6px;
}

.rs i {
  display: none;
  font-style: normal;
}

.rs b {
  font-weight: 600;
}

.rs-eyfs { grid-column: 2 / 3; }
.rs-ks1 { grid-column: 3 / 5; }
.rs-ks2 { grid-column: 5 / 9; }
.rs-ks3 { grid-column: 9 / 12; }
.rs-ks4 { grid-column: 12 / 14; }
.rs-ks5 { grid-column: 14 / 16; }

.rs.is-active {
  color: var(--ink);
}

.rs.is-active::before {
  border-color: var(--ink);
}

@media (max-width: 860px) {
  .rs b {
    display: none;
  }

  .rs i {
    display: inline;
  }

  .ruler-years small {
    display: none;
  }

  .ruler-years button {
    min-height: 54px;
    font-size: 1.1rem;
  }
}

/* On a phone the ruler slides sideways inside its own strip, so every year stays a good size to tap. */
@media (max-width: 640px) {
  .ruler {
    margin: 0 -18px;
    padding: 0 18px 12px;
    overflow-x: auto;
    scrollbar-width: thin;
  }

  .ruler-years,
  .ruler-stages {
    min-width: 600px;
  }

  .ruler-years button {
    min-height: 52px;
    font-size: 1.05rem;
  }

  .ruler-stages {
    font-size: 0.72rem;
  }

  .ruler-hint {
    display: block;
  }
}

.ruler-hint {
  display: none;
  margin: 6px 0 0;
  font-size: 0.82rem;
  color: var(--muted);
}

.birth-helper {
  margin-top: 18px;
}

.birth-helper summary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--jade-dark);
  font-weight: 600;
  cursor: pointer;
  list-style: none;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.birth-helper summary::-webkit-details-marker {
  display: none;
}

.birth-helper summary::before {
  content: "+";
  display: inline-grid;
  place-items: center;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--jade);
  color: var(--white);
  font-size: 1rem;
  line-height: 1;
  text-decoration: none;
}

.birth-helper[open] summary::before {
  content: "−";
}

.birth-body {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 14px 18px;
  margin-top: 14px;
  padding: 18px 20px;
  background: var(--white);
  border: 1px solid var(--mist-2);
  border-radius: var(--radius);
}

.birth-result {
  flex: 1 1 280px;
  margin: 0;
  color: var(--muted);
}

.birth-result strong {
  color: var(--ink);
}

.birth-result button {
  margin-left: 6px;
  padding: 0;
  border: 0;
  background: none;
  color: var(--jade-dark);
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 3px;
  cursor: pointer;
}

/* ---------- Subjects: the year panel and subject cards ---------- */

.year-panel {
  margin-bottom: 28px;
}

.year-summary {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 6px 18px;
  margin: 0 0 20px;
  padding: 0;
}

.year-summary h3 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: 1.6rem;
}

.year-summary p {
  margin: 0;
  color: var(--muted);
}

.year-summary .stage-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 12px;
  border-radius: 999px;
  background: var(--ink);
  color: var(--white);
  font-size: 0.82rem;
  font-weight: 600;
}

.subject-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 30px 20px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.subject-card {
  position: relative;
  display: flex;
  flex-direction: column;
  margin-top: 28px;
  padding: 24px 22px 20px;
  background: var(--white);
  border-radius: 0 var(--radius) var(--radius) var(--radius);
  box-shadow: var(--shadow);
  border-top: 4px solid var(--jade);
}

.subject-tab {
  position: absolute;
  left: 0;
  bottom: 100%;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 6px 14px 5px;
  border-radius: 10px 10px 0 0;
  background: var(--jade);
  color: var(--white);
  font-size: 0.82rem;
  font-weight: 650;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.subject-tab .icon {
  width: 16px;
  height: 16px;
}

.subject-card.s-maths { border-top-color: var(--maths); }
.subject-card.s-maths .subject-tab { background: var(--maths); }
.subject-card.s-english { border-top-color: var(--english); }
.subject-card.s-english .subject-tab { background: var(--english-ink); }
.subject-card.s-science { border-top-color: var(--science); }
.subject-card.s-science .subject-tab { background: var(--science-ink); }
.subject-card.s-elevenplus { border-top-color: var(--eleven); }
.subject-card.s-elevenplus .subject-tab { background: var(--eleven); color: var(--ink); }

.subject-card h4 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: 1.3rem;
  margin-bottom: 12px;
}

.subject-card .ticks {
  font-size: 0.94rem;
}

.subject-card .ticks li {
  margin-bottom: 8px;
}

.subject-levels {
  margin: 0 0 14px;
  padding: 0;
  list-style: none;
}

.subject-levels li {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 9px 0;
  border-bottom: 1px dashed var(--line);
  font-size: 0.94rem;
}

.subject-levels li:last-child {
  border-bottom: 0;
}

.subject-levels span:last-child {
  color: var(--muted);
  white-space: nowrap;
  font-size: 0.86rem;
}

.subject-extra {
  margin: 0 0 12px;
  padding: 10px 12px;
  border-radius: 8px;
  background: var(--paper);
  font-size: 0.86rem;
  line-height: 1.5;
}

.subject-extra strong {
  display: block;
  font-size: 0.74rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 650;
}

.subject-foot {
  margin-top: auto;
  padding-top: 12px;
  border-top: 1px solid var(--line);
  font-size: 0.9rem;
}

.subject-foot p {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  margin: 0 0 6px;
}

.subject-foot .icon {
  margin-top: 2px;
  color: var(--jade);
}

.subject-foot a {
  font-weight: 600;
}

.year-note {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 16px;
  align-items: start;
  padding: 24px;
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  max-width: 760px;
}

.year-note .icon {
  width: 28px;
  height: 28px;
  color: var(--jade);
}

.year-note p:last-child {
  margin-bottom: 0;
}

.board-note {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 12px;
  align-items: start;
  margin: 0 0 28px;
  padding: 16px 18px;
  border: 1px solid var(--mist-2);
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.6);
  font-size: 0.95rem;
}

.board-note .icon {
  margin-top: 2px;
  color: var(--jade);
}

.board-note p {
  margin: 0;
}

/* The 11+ note: a sheet with a sunflower tab. */
.eleven {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.6fr);
  gap: 24px 48px;
  padding: 0 32px 30px;
  background: var(--white);
  border-radius: 0 var(--radius) var(--radius) var(--radius);
  box-shadow: var(--shadow);
  border-top: 4px solid var(--eleven);
}

.eleven-head {
  padding-top: 0;
}

.eleven-head .kicker {
  margin-top: -1px;
  border-radius: 0 0 10px 10px;
  background: var(--eleven);
}

.eleven-head .kicker + .h3 {
  border-top: 0;
  padding-top: 18px;
}

.eleven-body {
  padding-top: 30px;
}

.eleven-body p:last-child {
  margin-bottom: 0;
  font-weight: 600;
  color: var(--ink);
}

@media (max-width: 760px) {
  .eleven {
    grid-template-columns: minmax(0, 1fr);
    padding: 0 20px 24px;
  }

  .eleven-body {
    padding-top: 0;
  }
}

/* ---------- Progress ---------- */

.track {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
  margin: 0 0 clamp(48px, 7vw, 80px);
  padding: 0;
  list-style: none;
  counter-reset: none;
}

.track-step {
  position: relative;
  padding: 26px 22px 22px;
  border: 2px solid var(--ink);
  border-radius: var(--radius);
  background: var(--white);
}

.track-step::after {
  content: "";
  position: absolute;
  right: -20px;
  top: 40px;
  width: 22px;
  height: 2px;
  background: var(--ink);
}

.track-step:last-child::after {
  display: none;
}

.track-num {
  position: absolute;
  top: -15px;
  left: 18px;
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: var(--sun);
  border: 2px solid var(--ink);
  font-weight: 700;
  font-size: 0.9rem;
}

.track-icon {
  width: 34px;
  height: 34px;
  margin-bottom: 14px;
  fill: none;
  stroke: var(--jade);
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.track-step h3 {
  font-size: 1.1rem;
  font-weight: 650;
  margin-bottom: 8px;
}

.track-step p {
  margin: 0;
  font-size: 0.93rem;
  color: var(--text);
}

.track-step [data-report-date],
.track-step [data-meeting-date] {
  display: block;
  margin-top: 10px;
  font-weight: 600;
  color: var(--jade-dark);
}

.track-step [data-report-date]:empty,
.track-step [data-meeting-date]:empty {
  display: none;
}

@media (max-width: 1000px) {
  .track {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 30px 18px;
  }

  .track-step::after {
    display: none;
  }
}

@media (max-width: 560px) {
  .track {
    grid-template-columns: minmax(0, 1fr);
  }
}

.example {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: 40px;
  align-items: start;
  padding: clamp(24px, 4vw, 44px);
  border: 2px dashed var(--english);
  border-radius: 22px;
  background: repeating-linear-gradient(-45deg, var(--paper) 0 14px, var(--white) 14px 28px);
}

@media (min-width: 1001px) {
  .example-intro {
    position: sticky;
    top: calc(var(--header-h) + 24px);
  }
}

.example-flag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 14px;
  padding: 4px 12px;
  border-radius: 999px;
  background: var(--english-ink);
  color: var(--white);
  font-size: 0.78rem;
  font-weight: 650;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.example-intro .h3 {
  margin-bottom: 14px;
}

.results-honest {
  margin-top: 26px;
  padding: 20px 22px;
  background: var(--white);
  border-radius: var(--radius);
  border-left: 5px solid var(--sun);
}

.results-honest h4 {
  font-size: 1rem;
  font-weight: 650;
  margin-bottom: 8px;
}

.results-honest p {
  font-size: 0.94rem;
}

.template {
  font-family: var(--serif);
  font-size: 1.12rem;
  line-height: 1.6;
  color: var(--ink);
}

.blank {
  display: inline-block;
  min-width: 4.2em;
  padding: 0 6px;
  border-bottom: 2px solid var(--ink);
  font-family: var(--font);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
  text-align: center;
  line-height: 1.4;
}

.template-note {
  margin: 0;
  color: var(--muted);
  font-size: 0.86rem !important;
}

/* The example report sheet. */
.report {
  position: relative;
  margin: 0;
  padding: 28px 28px 24px;
  background: var(--white);
  border-radius: 6px;
  box-shadow: var(--shadow-lg);
  overflow: hidden;
}

.report-stamp {
  position: absolute;
  right: -46px;
  top: 26px;
  width: 200px;
  margin: 0;
  padding: 6px 0;
  transform: rotate(35deg);
  background: var(--english-ink);
  color: var(--white);
  text-align: center;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.22em;
  text-transform: uppercase;
}

.report-head {
  padding-bottom: 16px;
  margin-bottom: 16px;
  border-bottom: 2px solid var(--ink);
}

.report-kind {
  margin: 0 0 4px;
  font-size: 0.75rem;
  font-weight: 650;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
}

.report-title {
  padding-right: 48px;
  font-family: var(--serif);
  font-weight: 400;
  font-size: 1.45rem;
}

.report-sub {
  margin: 4px 0 0;
  color: var(--muted);
}

.report-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 18px;
  margin: 0 0 12px;
  padding: 0;
  list-style: none;
  font-size: 0.82rem;
  color: var(--text);
}

.report-legend li {
  display: inline-flex;
  align-items: center;
  gap: 7px;
}

.report-legend svg {
  width: 12px;
  height: 12px;
}

.report-rows {
  margin-bottom: 14px;
}

.rrow {
  display: grid;
  grid-template-columns: minmax(0, 9rem) minmax(0, 1fr) 7.4rem;
  gap: 14px;
  align-items: center;
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
}

.rrow-name {
  font-weight: 600;
  font-size: 0.92rem;
  line-height: 1.3;
}

.rrow-scores {
  display: block;
  font-weight: 400;
  font-size: 0.78rem;
  color: var(--muted);
}

.rrow-chart {
  width: 100%;
  height: 30px;
  overflow: visible;
}

.rc-zone {
  fill: #f1efe8;
}

.rc-zone-mid {
  fill: var(--sun-soft);
}

.rc-zone-top {
  fill: var(--jade-soft);
}

.rc-axis {
  stroke: var(--line-strong);
  stroke-width: 1;
}

.rc-link {
  stroke: var(--jade);
  stroke-width: 2;
  stroke-linecap: round;
}

.rc-dot {
  stroke: var(--white);
  stroke-width: 2;
}

.rc-dot-0 { fill: #9fd8bf; }
.rc-dot-1 { fill: #3fa67e; }
.rc-dot-2 { fill: var(--jade-deep); }

.rrow-status {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.82rem;
  font-weight: 600;
  line-height: 1.25;
}

.rrow-status .icon {
  width: 16px;
  height: 16px;
}

.st-secure { color: var(--jade-dark); }
.st-getting { color: var(--eleven-ink); }
.st-not { color: var(--english-ink); }

.report-scale {
  display: grid;
  grid-template-columns: minmax(0, 9rem) minmax(0, 1fr) 7.4rem;
  gap: 14px;
  margin-top: 4px;
  font-size: 0.72rem;
  color: var(--muted);
}

.report-bands {
  display: grid;
  grid-template-columns: 10fr 5fr 5fr;
}

.report-bands > span {
  margin-left: -3px;
}

.report-bands > span:last-child {
  display: flex;
  justify-content: space-between;
}

.report-bands > span:last-child span:last-child {
  margin-right: -6px;
}

.report-key {
  margin: 10px 0 0;
  font-size: 0.8rem;
  color: var(--muted);
}

.report-facts {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin: 18px 0 16px;
}

.report-facts div {
  padding: 10px 12px;
  border-radius: 8px;
  background: var(--paper);
}

.report-facts dt {
  font-size: 0.72rem;
  font-weight: 650;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--muted);
}

.report-facts dd {
  margin: 2px 0 0;
  font-weight: 600;
  font-size: 0.92rem;
}

.report-comment {
  padding: 14px 16px;
  border-left: 4px solid var(--jade);
  background: var(--mist);
  border-radius: 0 8px 8px 0;
  font-size: 0.92rem;
}

.report-comment p {
  margin: 0;
}

.report-table {
  margin-top: 10px;
  font-size: 0.86rem;
}

.report-table summary {
  cursor: pointer;
  color: var(--jade-dark);
  font-weight: 600;
}

.report-table table {
  width: 100%;
  margin-top: 8px;
  border-collapse: collapse;
}

.report-table th,
.report-table td {
  padding: 6px 8px;
  border-bottom: 1px solid var(--line);
  text-align: left;
}

.report-table td {
  font-variant-numeric: tabular-nums;
}

@media (max-width: 1000px) {
  .example {
    grid-template-columns: minmax(0, 1fr);
  }
}

@media (max-width: 520px) {
  .report {
    padding: 22px 16px 18px;
  }

  .rrow,
  .report-scale {
    grid-template-columns: minmax(0, 1fr) 6.6rem;
    gap: 4px 10px;
  }

  .rrow-name {
    grid-column: 1 / -1;
  }

  .report-scale > span:first-child {
    display: none;
  }

  .report-stamp {
    width: 170px;
    font-size: 0.68rem;
  }

  .report-facts {
    grid-template-columns: minmax(0, 1fr);
  }

  .report-stamp {
    right: -56px;
    top: 16px;
  }

  .example {
    padding: 18px 12px 12px;
    border-radius: 16px;
  }

  .results-honest {
    padding: 16px;
  }
}

/* ---------- Tutors ---------- */

.tutor-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
  margin: 0 0 24px;
  padding: 0;
  list-style: none;
}

.tutor {
  display: flex;
  flex-direction: column;
  padding: 24px;
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.tutor-top {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 16px;
}

.monogram {
  display: grid;
  place-items: center;
  flex: none;
  width: 64px;
  height: 64px;
  border-radius: 16px 16px 16px 4px;
  font-family: var(--serif);
  font-size: 2rem;
  line-height: 1;
  color: var(--white);
  background: var(--jade);
}

.m-maths { background: var(--maths); }
.m-english { background: var(--english-ink); }
.m-science { background: var(--science-ink); }
.m-elevenplus { background: var(--eleven); color: var(--ink); }

.tutor h3 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: 1.35rem;
}

.tutor-role {
  margin: 2px 0 0;
  font-size: 0.86rem;
  color: var(--muted);
}

.tutor-teaches {
  margin: 0 0 8px;
  font-weight: 600;
  color: var(--ink);
}

.tutor-bg {
  font-size: 0.93rem;
  color: var(--text);
}

.tutor-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: auto;
  padding-top: 14px;
  border-top: 1px dashed var(--line);
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: 8px;
  background: var(--mist);
  color: var(--jade-deep);
  font-size: 0.8rem;
  font-weight: 600;
}

.badge .icon {
  width: 16px;
  height: 16px;
}

.badge-example {
  background: var(--english-soft);
  color: var(--english-ink);
  border: 1px dashed var(--english);
}

.example-note {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  max-width: 900px;
  margin: 0;
  font-size: 0.92rem;
  color: var(--muted);
}

.example-note .tag {
  flex: none;
  margin-top: 2px;
}

.tutor-fallback {
  color: var(--muted);
}

@media (max-width: 960px) {
  .tutor-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 600px) {
  .tutor-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* ---------- Call to action band ---------- */

.cta-band {
  position: relative;
  overflow: hidden;
  padding: clamp(48px, 7vw, 76px) 0;
  background: var(--sun);
}

.cta-band::before {
  content: "";
  position: absolute;
  left: -60px;
  top: -80px;
  width: 260px;
  height: 260px;
  border-radius: 50%;
  border: 2px solid rgba(26, 29, 35, 0.12);
}

.cta-inner {
  position: relative;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 24px 40px;
}

.cta-inner .h2 {
  margin-bottom: 10px;
}

.cta-inner p {
  max-width: 34em;
  margin: 0;
  color: var(--ink);
  font-size: 1.08rem;
}

.cta-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.cta-band :focus-visible {
  outline-color: var(--ink);
}

/* ---------- Visit and contact ---------- */

.visit {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(0, 0.75fr);
  gap: 48px;
  align-items: start;
}

.visit-info .h2 {
  margin-bottom: 26px;
}

.visit-line {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 16px;
}

.visit-line .icon {
  margin-top: 3px;
  color: var(--jade);
}

.map-link a {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-weight: 600;
}

.hours-wrap {
  margin-top: 28px;
  padding: 24px;
  border-radius: var(--radius);
  background: var(--paper);
  border: 1px solid var(--line);
}

.open-status {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 18px;
  font-weight: 600;
  color: var(--ink);
}

.open-status .dot {
  width: 12px;
  height: 12px;
  flex: none;
  border-radius: 50%;
  background: var(--muted-light);
}

.open-status.is-open .dot {
  background: var(--jade);
  box-shadow: 0 0 0 4px var(--jade-soft);
}

.open-status.is-holiday .dot {
  background: var(--eleven);
  box-shadow: 0 0 0 4px var(--eleven-soft);
}

.hours-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px;
}

.hours-title {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 10px;
  font-size: 1rem;
  font-weight: 650;
}

.hours-title .icon {
  color: var(--jade);
}

.hours {
  margin: 0;
  font-size: 0.93rem;
}

.hours div {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 7px 0;
  border-bottom: 1px dashed var(--line-strong);
}

.hours div:last-child {
  border-bottom: 0;
}

.hours dt {
  color: var(--muted);
}

.hours dd {
  margin: 0;
  font-weight: 600;
  text-align: right;
}

.hours dd {
  white-space: nowrap;
}

.hours div.is-today {
  margin: 0 -10px;
  padding: 7px 10px;
  border-radius: 8px;
  border-bottom-color: transparent;
  background: var(--sun-soft);
}

.hours .is-today dt {
  color: var(--ink);
  font-weight: 600;
}

.hours-note {
  margin: 16px 0 0;
  font-size: 0.86rem;
  color: var(--muted);
}

.contact-card {
  position: sticky;
  top: calc(var(--header-h) + 24px);
  padding: 32px 28px;
  border-radius: 20px;
  background: var(--ink);
  color: #dfe2e8;
}

.contact-title {
  font-family: var(--serif);
  font-weight: 400;
  font-size: 1.8rem;
  color: var(--white);
  margin-bottom: 12px;
}

.contact-actions {
  display: grid;
  gap: 12px;
  margin: 22px 0 18px;
}

.contact-foot {
  margin: 0;
  font-size: 0.88rem;
  color: var(--muted-light);
}

.contact-card :focus-visible {
  outline-color: var(--sun);
}

@media (max-width: 960px) {
  .visit {
    grid-template-columns: minmax(0, 1fr);
  }

  .contact-card {
    position: static;
  }
}

@media (max-width: 560px) {
  .hours-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .hours-wrap {
    padding: 20px 16px;
  }
}

/* ---------- Footer ---------- */

.site-footer {
  background: var(--ink);
  color: #c9cdd5;
  padding: 56px 0 40px;
  font-size: 0.93rem;
}

.footer-inner {
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr);
  gap: 28px 48px;
}

.footer-brand p {
  margin: 14px 0 0;
  max-width: 30em;
}

.footer-address {
  display: flex;
  align-items: center;
  gap: 8px;
}

.footer-nav {
  display: grid;
  grid-template-columns: repeat(2, max-content);
  gap: 10px 40px;
  align-content: start;
  justify-content: end;
}

.footer-nav a,
.footer-credit a {
  color: var(--white);
}

.footer-nav a:hover,
.footer-credit a:hover {
  color: var(--sun);
}

.footer-credit {
  grid-column: 1 / -1;
  margin: 12px 0 0;
  padding-top: 22px;
  border-top: 1px solid var(--ink-3);
  font-size: 0.85rem;
  color: #aeb4be;
}

.site-footer :focus-visible {
  outline-color: var(--sun);
}

@media (max-width: 760px) {
  .footer-inner {
    grid-template-columns: minmax(0, 1fr);
  }

  .footer-nav {
    justify-content: start;
  }
}

/* ---------- Inner page header ---------- */

.page-head {
  position: relative;
  overflow: hidden;
  padding: clamp(40px, 6vw, 72px) 0 clamp(36px, 5vw, 56px);
  background: var(--sun-wash);
  border-bottom: 1px solid #f4e6b0;
}

.page-head::after {
  content: "";
  position: absolute;
  right: -120px;
  top: -140px;
  width: 420px;
  height: 420px;
  border-radius: 50%;
  background: rgba(255, 212, 59, 0.28);
}

.page-head .wrap {
  position: relative;
  z-index: 1;
}

.page-head-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
  gap: 32px 56px;
  align-items: end;
}

.page-head .h1 {
  margin-bottom: 18px;
}

.page-head .lead {
  margin: 0;
}

@media (max-width: 900px) {
  .page-head-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* The current term, worked out from today's date. */
.term-card {
  padding: 22px 24px;
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.term-card-top {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px 16px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}

.term-card h2 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: 1.35rem;
}

.term-week {
  font-size: 0.86rem;
  font-weight: 650;
  color: var(--jade-dark);
}

.term-bar {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(0, 1fr);
  gap: 3px;
  margin-bottom: 14px;
}

.term-bar i {
  display: block;
  height: 10px;
  border-radius: 3px;
  background: var(--line);
}

.term-bar i.is-done {
  background: var(--jade);
}

.term-bar i.is-now {
  background: var(--sun);
  box-shadow: inset 0 0 0 2px var(--ink);
}

.term-bar i.is-half {
  background: repeating-linear-gradient(-45deg, var(--line) 0 3px, var(--white) 3px 6px);
}

.term-facts {
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: 0.9rem;
}

.term-facts li {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 6px 0;
  border-bottom: 1px dashed var(--line);
}

.term-facts li:last-child {
  border-bottom: 0;
}

.term-facts span:first-child {
  color: var(--muted);
}

.term-facts span:last-child {
  font-weight: 600;
  text-align: right;
}

/* ---------- Timetable ---------- */

.filters-bar {
  position: sticky;
  top: var(--header-h);
  z-index: 20;
  background: rgba(255, 255, 255, 0.97);
  border-bottom: 1px solid var(--line);
}

.filters {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 24px;
  padding-top: 14px;
  padding-bottom: 14px;
}

.filter-year {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 600;
}

.filter-year select,
.field select,
.field input,
.field textarea {
  min-height: 46px;
  padding: 10px 12px;
  border: 2px solid var(--line-strong);
  border-radius: 10px;
  background: var(--white);
  font-size: 1rem;
}

.filter-year select {
  border-color: var(--ink);
  min-width: 170px;
  font-weight: 600;
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0;
  padding: 0;
  border: 0;
}

.chip {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 42px;
  padding: 8px 15px;
  border: 2px solid var(--line-strong);
  border-radius: 999px;
  background: var(--white);
  color: var(--ink);
  font-weight: 600;
  font-size: 0.92rem;
  cursor: pointer;
}

.chip:hover {
  border-color: var(--ink);
}

.chip[aria-pressed="true"] {
  border-color: var(--ink);
  background: var(--ink);
  color: var(--white);
}

.filter-count {
  margin: 0 0 0 auto;
  font-size: 0.9rem;
  color: var(--muted);
}

.filter-count strong {
  color: var(--ink);
}

@media (max-width: 760px) {
  .filters-bar {
    position: static;
  }

  .filters {
    gap: 12px;
  }

  .filter-year {
    width: 100%;
    justify-content: space-between;
  }

  .filter-year select {
    flex: 1;
  }

  .filter-count {
    margin: 0;
    width: 100%;
  }

  .chip {
    padding: 7px 12px;
  }
}

.tt {
  padding: 36px 0 clamp(56px, 8vw, 96px);
}

.tt-day {
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr);
  gap: 24px;
  padding: 26px 0;
  border-bottom: 1px solid var(--line);
}

.tt-day:first-child {
  padding-top: 0;
}

.tt-day-head {
  position: relative;
}

.tt-day-name {
  position: sticky;
  top: calc(var(--header-h) + 90px);
  font-family: var(--serif);
  font-weight: 400;
  font-size: 1.55rem;
}

.tt-day-name small {
  display: block;
  margin-top: 6px;
  font-family: var(--font);
  font-size: 0.82rem;
  color: var(--muted);
}

.tt-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(290px, 1fr));
  gap: 16px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.tt-class {
  position: relative;
  display: flex;
  flex-direction: column;
  padding: 18px 18px 16px 22px;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: 0 1px 2px rgba(26, 29, 35, 0.04);
}

.tt-class::before {
  content: "";
  position: absolute;
  left: -1px;
  top: 16px;
  bottom: 16px;
  width: 5px;
  border-radius: 0 4px 4px 0;
  background: var(--jade);
}

.tt-class.s-maths::before { background: var(--maths); }
.tt-class.s-english::before { background: var(--english); }
.tt-class.s-science::before { background: var(--science); }
.tt-class.s-elevenplus::before { background: var(--eleven); }

.tt-top {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 6px;
}

.tt-time {
  font-weight: 700;
  font-size: 1.02rem;
  color: var(--ink);
}

.tt-subj {
  font-size: 0.74rem;
  font-weight: 650;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 2px 8px;
  border-radius: 6px;
}

.tt-class.s-maths .tt-subj { background: var(--maths-soft); color: var(--maths-ink); }
.tt-class.s-english .tt-subj { background: var(--english-soft); color: var(--english-ink); }
.tt-class.s-science .tt-subj { background: var(--science-soft); color: var(--science-ink); }
.tt-class.s-elevenplus .tt-subj { background: var(--eleven-soft); color: var(--eleven-ink); }

.tt-title {
  font-family: var(--serif);
  font-weight: 400;
  font-size: 1.22rem;
  margin-bottom: 8px;
}

.tt-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 14px;
  margin: 0 0 12px;
  padding: 0;
  list-style: none;
  font-size: 0.86rem;
  color: var(--muted);
}

.tt-meta li {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.tt-meta .icon {
  width: 16px;
  height: 16px;
}

.tt-meta .is-years {
  color: var(--ink);
  font-weight: 600;
}

.tt-places {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
  font-size: 0.86rem;
  font-weight: 600;
}

.seats {
  display: flex;
  gap: 3px;
}

.seats i {
  width: 14px;
  height: 14px;
  border-radius: 4px;
  background: var(--white);
  border: 2px solid var(--jade);
}

.seats i.is-taken {
  background: var(--line-strong);
  border-color: var(--line-strong);
}

.tt-places.is-few {
  color: var(--english-ink);
}

.tt-places.is-full {
  color: var(--muted);
}

.tt-places.is-full .seats i {
  background: var(--line-strong);
  border-color: var(--line-strong);
}

.tt-price {
  margin: 0 0 14px;
  font-size: 0.86rem;
  color: var(--muted);
}

.tt-price strong {
  color: var(--ink);
  font-size: 1rem;
}

.tt-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: auto;
  padding-top: 12px;
  border-top: 1px dashed var(--line);
}

.tt-next {
  font-size: 0.82rem;
  color: var(--muted);
  line-height: 1.3;
}

.tt-next strong {
  display: block;
  color: var(--ink);
  font-size: 0.88rem;
}

.tt-foot .btn {
  min-height: 40px;
  padding: 7px 14px;
  font-size: 0.88rem;
  flex: none;
}

.tt-empty {
  padding: 28px;
  border: 2px dashed var(--line-strong);
  border-radius: var(--radius);
  text-align: center;
  color: var(--muted);
}

.tt-empty p {
  max-width: 34em;
  margin: 0 auto 14px;
}

.tt-empty p:last-child {
  margin-bottom: 0;
}

@media (max-width: 760px) {
  .tt-day {
    grid-template-columns: minmax(0, 1fr);
    gap: 14px;
  }

  .tt-day-name {
    position: static;
    display: flex;
    align-items: baseline;
    gap: 10px;
  }

  .tt-day-name small {
    margin: 0;
  }

  .tt-list {
    grid-template-columns: minmax(0, 1fr);
  }
}

.one-box {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 28px 48px;
  align-items: center;
  padding: clamp(24px, 4vw, 40px);
  border-radius: 22px;
  background: var(--mist);
}

.one-box .h3 {
  margin-bottom: 12px;
}

.price-list {
  margin: 0;
  padding: 0;
  list-style: none;
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.price-list li {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  padding: 13px 18px;
  border-bottom: 1px dashed var(--line);
}

.price-list li:last-child {
  border-bottom: 0;
}

.price-list strong {
  white-space: nowrap;
}

@media (max-width: 860px) {
  .one-box {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* ---------- Trial booking ---------- */

.trial {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 0.8fr);
  gap: 40px;
  align-items: start;
  padding-top: 40px;
  padding-bottom: clamp(56px, 8vw, 96px);
}

.trial-form {
  min-width: 0;
}

.step {
  position: relative;
  margin: 0 0 22px;
  padding: 26px 26px 24px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--white);
  min-width: 0;
}

.step[hidden] {
  display: none;
}

.step > legend {
  display: flex;
  align-items: center;
  gap: 12px;
  float: left;
  width: 100%;
  margin: 0 0 18px;
  padding: 0;
  font-family: var(--serif);
  font-size: 1.4rem;
  color: var(--ink);
}

.step > legend + * {
  clear: both;
}

.step-num {
  display: grid;
  place-items: center;
  flex: none;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--sun);
  border: 2px solid var(--ink);
  font-family: var(--font);
  font-size: 0.95rem;
  font-weight: 700;
}

.step.is-done .step-num {
  background: var(--jade);
  border-color: var(--jade);
  color: var(--white);
}

.field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin: 0 0 16px;
  padding: 0;
  border: 0;
  min-width: 0;
}

.field-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0 16px;
}

.field-label {
  font-weight: 600;
  color: var(--ink);
  font-size: 0.95rem;
  padding: 0;
}

.field-optional {
  font-weight: 400;
  color: var(--muted);
  font-size: 0.86rem;
}

.field-hint {
  margin: 0;
  font-size: 0.86rem;
  color: var(--muted);
}

.field input:focus,
.field select:focus,
.field textarea:focus,
.filter-year select:focus,
.finder-year select:focus {
  border-color: var(--ink);
}

.field input[aria-invalid="true"],
.field select[aria-invalid="true"] {
  border-color: var(--english-ink);
  background: #fff8fa;
}

.field textarea {
  resize: vertical;
  min-height: 92px;
}

.field-error {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--english-ink);
}

.field-error[hidden] {
  display: none;
}

.field-inline {
  margin: 0;
}

.field-inline select {
  min-width: 140px;
}

@media (max-width: 560px) {
  .field-row {
    grid-template-columns: minmax(0, 1fr);
  }

  .step {
    padding: 22px 16px 20px;
  }
}

/* Big choice cards (radio buttons). */
.choices {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  gap: 10px;
}

.choices-2 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.choice {
  position: relative;
  display: block;
  min-width: 0;
}

.choice input {
  position: absolute;
  opacity: 0;
  width: 1px;
  height: 1px;
}

.choice-body {
  display: flex;
  flex-direction: column;
  gap: 2px;
  height: 100%;
  padding: 14px 16px 14px 46px;
  border: 2px solid var(--line-strong);
  border-radius: 12px;
  background: var(--white);
  cursor: pointer;
  transition: border-color 0.15s, background-color 0.15s;
  position: relative;
}

.choice-body::before {
  content: "";
  position: absolute;
  left: 15px;
  top: 16px;
  width: 20px;
  height: 20px;
  border: 2px solid var(--line-strong);
  border-radius: 50%;
  background: var(--white);
}

.choice-body strong {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--ink);
  font-weight: 600;
  line-height: 1.3;
}

.choice-body span {
  font-size: 0.86rem;
  color: var(--muted);
  line-height: 1.4;
}

.choice:hover .choice-body {
  border-color: var(--ink);
}

.choice input:checked + .choice-body {
  border-color: var(--jade);
  background: var(--mist);
}

.choice input:checked + .choice-body::before {
  border-color: var(--jade);
  background: radial-gradient(circle, var(--jade) 0 5px, var(--white) 5.5px);
}

.choice input:focus-visible + .choice-body {
  outline: 3px solid var(--maths-ink);
  outline-offset: 2px;
}

.choice input:disabled + .choice-body {
  cursor: not-allowed;
  background: var(--paper);
  border-style: dashed;
}

.choice input:disabled + .choice-body strong {
  color: var(--muted);
}

.choice-check .choice-body::before {
  border-radius: 5px;
}

.choice-check input:checked + .choice-body::before {
  background: var(--jade);
  border-color: var(--jade);
}

.choice-check input:checked + .choice-body::after {
  content: "";
  position: absolute;
  left: 21px;
  top: 20px;
  width: 8px;
  height: 12px;
  border: solid var(--white);
  border-width: 0 3px 3px 0;
  transform: rotate(45deg);
}

.choice-compact .choice-body {
  padding: 10px 12px 10px 42px;
}

.choice-compact .choice-body::before {
  top: 12px;
  left: 13px;
}

.choice-compact.choice-check input:checked + .choice-body::after {
  left: 19px;
  top: 16px;
}

/* A class to pick, with its next dates. */
.slot-list {
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.slot-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 2px 12px;
}

.dates {
  margin-top: 16px;
}

.date-choices {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.date-choices .choice-body {
  padding: 10px 14px 10px 40px;
}

.date-choices .choice-body::before {
  left: 12px;
  top: 13px;
}

.step-note {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 10px;
  margin: 14px 0 0;
  padding: 12px 14px;
  border-radius: 10px;
  background: var(--sun-wash);
  font-size: 0.9rem;
}

.step-note .icon {
  margin-top: 2px;
  color: var(--eleven-ink);
}

.step-note p {
  margin: 0;
}

.step-note[hidden] {
  display: none;
}

.form-errors {
  margin: 0 0 22px;
  padding: 18px 20px;
  border: 2px solid var(--english-ink);
  border-radius: var(--radius);
  background: #fff8fa;
}

.form-errors h2 {
  font-size: 1.05rem;
  font-weight: 650;
  margin-bottom: 8px;
  color: var(--english-ink);
}

.form-errors ul {
  margin: 0;
  padding-left: 20px;
}

.form-errors a {
  color: var(--english-ink);
  font-weight: 600;
}

.form-errors[hidden] {
  display: none;
}

.submit-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px 20px;
}

.form-note {
  margin: 0;
  font-size: 0.86rem;
  color: var(--muted);
}

.trial-aside {
  position: sticky;
  top: calc(var(--header-h) + 24px);
  display: grid;
  gap: 18px;
}

.summary-card {
  padding: 24px;
  border-radius: var(--radius);
  background: var(--ink);
  color: #dfe2e8;
}

.summary-card h2 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: 1.4rem;
  color: var(--white);
  margin-bottom: 14px;
}

.summary-list {
  margin: 0;
}

.summary-list div {
  display: grid;
  grid-template-columns: 6.5em minmax(0, 1fr);
  gap: 10px;
  padding: 8px 0;
  border-bottom: 1px solid var(--ink-3);
  font-size: 0.9rem;
}

.summary-list div:last-child {
  border-bottom: 0;
}

.summary-list dt {
  color: var(--muted-light);
}

.summary-list dd {
  margin: 0;
  color: var(--white);
  font-weight: 600;
}

.summary-list dd.is-empty {
  color: #8e95a1;
  font-weight: 400;
}

.next-card {
  padding: 22px 24px;
  border-radius: var(--radius);
  background: var(--mist);
}

.next-card h2 {
  font-size: 1.05rem;
  font-weight: 650;
  margin-bottom: 10px;
}

.next-card ol {
  margin: 0;
  padding-left: 20px;
  font-size: 0.92rem;
}

.next-card li {
  margin-bottom: 6px;
}

@media (max-width: 960px) {
  .trial {
    grid-template-columns: minmax(0, 1fr);
  }

  .trial-aside {
    position: static;
  }

  .summary-card {
    display: none;
  }
}

@media (max-width: 560px) {
  .choices-2 {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* ---------- Dialog and the WhatsApp message ---------- */

.dialog {
  width: min(560px, calc(100% - 24px));
  max-height: calc(100% - 24px);
  padding: 0;
  border: 0;
  border-radius: 20px;
  background: var(--white);
  color: var(--text);
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.35);
}

.dialog::backdrop {
  background: rgba(26, 29, 35, 0.6);
}

.dialog-body {
  padding: 26px 26px 24px;
}

.dialog-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
}

.dialog-title {
  font-family: var(--serif);
  font-weight: 400;
  font-size: 1.6rem;
}

.dialog-title:focus {
  outline: none;
}

.dialog-close {
  display: grid;
  place-items: center;
  flex: none;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 10px;
  background: var(--paper);
  cursor: pointer;
}

.dialog-close:hover {
  background: var(--line);
}

.dialog-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 18px;
}

.chat {
  padding: 16px;
  border-radius: 14px;
  background: #ece5dd;
}

.chat-to {
  display: flex;
  align-items: center;
  gap: 6px;
  margin: 0 0 10px;
  font-size: 0.82rem;
  font-weight: 600;
  color: #3b4a42;
}

.bubble {
  position: relative;
  margin: 0;
  padding: 12px 14px;
  border-radius: 12px 12px 4px 12px;
  background: #dcf8c6;
  color: #111b21;
  font-size: 0.92rem;
  line-height: 1.5;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.sample-note {
  margin-top: 16px;
  padding: 14px 16px;
  border-radius: 12px;
  background: var(--sun-wash);
  border: 1px solid #f1df9c;
  font-size: 0.92rem;
}

.sample-note p {
  margin: 0 0 6px;
}

.sample-note p:last-child {
  margin: 0;
}

.copy-status {
  min-height: 1.4em;
  margin: 8px 0 0;
  font-size: 0.86rem;
  font-weight: 600;
  color: var(--jade-dark);
}

/* ---------- Fees and information page ---------- */

.page-nav {
  position: sticky;
  top: var(--header-h);
  z-index: 20;
  background: rgba(255, 255, 255, 0.97);
  border-bottom: 1px solid var(--line);
}

.page-nav ul {
  display: flex;
  gap: 6px;
  margin: 0;
  padding: 12px 0;
  list-style: none;
  overflow-x: auto;
  scrollbar-width: thin;
}

.page-nav a {
  display: block;
  padding: 7px 14px;
  border-radius: 999px;
  background: var(--paper);
  border: 1px solid var(--line);
  color: var(--ink);
  font-weight: 600;
  font-size: 0.88rem;
  text-decoration: none;
  white-space: nowrap;
}

.page-nav a:hover {
  background: var(--sun-soft);
  border-color: var(--sun);
}

.fee-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px;
}

.fee-card {
  position: relative;
  margin-top: 26px;
  padding: 26px 24px 22px;
  background: var(--white);
  border-radius: 0 var(--radius) var(--radius) var(--radius);
  box-shadow: var(--shadow);
  border-top: 4px solid var(--jade);
}

.fee-card .subject-tab {
  background: var(--jade);
}

.fee-card-sun {
  border-top-color: var(--sun);
}

.fee-card-sun .subject-tab {
  background: var(--sun);
  color: var(--ink);
}

.fee-card h3 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: 1.4rem;
  margin-bottom: 6px;
}

.fee-card > p {
  color: var(--muted);
  font-size: 0.94rem;
}

.fee-card > p.subject-tab {
  color: var(--white);
  font-size: 0.82rem;
}

.fee-card-sun > p.subject-tab {
  color: var(--ink);
}

.fee-table {
  width: 100%;
  margin: 12px 0 14px;
  border-collapse: collapse;
  font-size: 0.94rem;
}

.fee-table th,
.fee-table td {
  padding: 10px 6px;
  border-bottom: 1px dashed var(--line);
  text-align: left;
  vertical-align: top;
}

.fee-table thead th {
  font-size: 0.74rem;
  font-weight: 650;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
  border-bottom: 2px solid var(--ink);
}

.fee-table td:last-child,
.fee-table th:last-child {
  text-align: right;
}

.fee-table td {
  white-space: nowrap;
}

.fee-table thead th:last-child {
  max-width: 11em;
}

.fee-table tbody th {
  font-weight: 600;
}

.fee-table .fee-sub {
  display: block;
  font-weight: 400;
  font-size: 0.82rem;
  color: var(--muted);
}

.fee-points {
  font-size: 0.92rem;
}

@media (max-width: 860px) {
  .fee-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* The fee calculator. */
.calc {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(0, 0.75fr);
  gap: 28px;
  align-items: start;
}

.calc-panel {
  padding: 26px;
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.calc-term {
  margin-bottom: 18px;
}

.calc-rows {
  display: grid;
  gap: 12px;
  margin: 0 0 14px;
  padding: 0;
  list-style: none;
}

.calc-row {
  display: grid;
  grid-template-columns: 9em minmax(0, 1fr) auto;
  gap: 10px;
  align-items: end;
  padding: 14px;
  border-radius: 12px;
  background: var(--paper);
  border: 1px solid var(--line);
}

.calc-row .field {
  margin: 0;
}

.calc-row .field select {
  width: 100%;
  min-width: 0;
}

.icon-btn {
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border: 2px solid var(--line-strong);
  border-radius: 10px;
  background: var(--white);
  color: var(--ink);
  cursor: pointer;
}

.icon-btn:hover {
  border-color: var(--english-ink);
  color: var(--english-ink);
}

.add-row {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 4px;
  border: 0;
  background: none;
  color: var(--jade-dark);
  font-weight: 600;
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.add-row[disabled] {
  color: var(--muted);
  cursor: not-allowed;
  text-decoration: none;
}

.calc-result {
  position: sticky;
  top: calc(var(--header-h) + 80px);
  padding: 24px;
  border-radius: var(--radius);
  background: var(--ink);
  color: #dfe2e8;
}

.calc-result h3 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: 1.35rem;
  color: var(--white);
  margin-bottom: 4px;
}

.calc-result .calc-term-label {
  margin: 0 0 14px;
  font-size: 0.88rem;
  color: var(--muted-light);
}

.calc-lines {
  margin: 0 0 14px;
  padding: 0;
  list-style: none;
  font-size: 0.88rem;
}

.calc-lines li {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 7px 0;
  border-bottom: 1px solid var(--ink-3);
}

.calc-lines li span:last-child {
  white-space: nowrap;
  font-weight: 600;
  color: var(--white);
}

.calc-lines .is-discount span:last-child {
  color: #8ee0bf;
}

.calc-lines .is-empty {
  color: #9aa1ad;
  border-bottom: 0;
}

.calc-total {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 12px;
  margin: 0 0 4px;
  padding-top: 6px;
  color: var(--white);
}

.calc-total strong {
  font-family: var(--serif);
  font-weight: 400;
  font-size: 2rem;
  color: var(--sun);
}

.calc-instal {
  margin: 0 0 16px;
  font-size: 0.86rem;
  color: var(--muted-light);
}

.calc-result :focus-visible {
  outline-color: var(--sun);
}

@media (max-width: 960px) {
  .calc {
    grid-template-columns: minmax(0, 1fr);
  }

  .calc-result {
    position: static;
  }
}

@media (max-width: 600px) {
  .calc-panel {
    padding: 18px 14px;
  }

  .calc-row {
    grid-template-columns: minmax(0, 1fr) auto;
  }

  .calc-row .field-class {
    grid-column: 1 / -1;
    order: 2;
  }
}

/* Term dates table. */
.terms-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
  margin-bottom: 24px;
}

.term-tile {
  padding: 22px;
  border-radius: var(--radius);
  background: var(--white);
  border: 1px solid var(--line);
}

.term-tile.is-current {
  border: 2px solid var(--ink);
  box-shadow: 6px 6px 0 var(--sun);
}

.term-tile h3 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: 1.3rem;
  margin-bottom: 4px;
}

.term-tile .term-tag {
  display: inline-block;
  margin-bottom: 10px;
  padding: 2px 10px;
  border-radius: 999px;
  background: var(--paper);
  font-size: 0.76rem;
  font-weight: 650;
  color: var(--muted);
}

.term-tile.is-current .term-tag {
  background: var(--sun);
  color: var(--ink);
}

.term-tile dl {
  margin: 0;
  font-size: 0.9rem;
}

.term-tile dl div {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  padding: 6px 0;
  border-bottom: 1px dashed var(--line);
}

.term-tile dl div:last-child {
  border-bottom: 0;
}

.term-tile dt {
  color: var(--muted);
}

.term-tile dd {
  margin: 0;
  font-weight: 600;
  text-align: right;
}

@media (max-width: 860px) {
  .terms-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}

.policy-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}

.policy {
  padding: 24px;
  border-radius: var(--radius);
  background: var(--white);
  border: 1px solid var(--line);
}

.policy-icon {
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  margin-bottom: 14px;
  border-radius: 12px;
  background: var(--sun);
  color: var(--ink);
}

.policy-icon .icon {
  width: 24px;
  height: 24px;
}

.policy h3 {
  font-size: 1.12rem;
  font-weight: 650;
  margin-bottom: 10px;
}

.policy p,
.policy li {
  font-size: 0.93rem;
}

.policy .ticks li {
  margin-bottom: 8px;
}

.policy p:last-child,
.policy .ticks:last-child {
  margin-bottom: 0;
}

@media (max-width: 960px) {
  .policy-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* Online lessons. */
.online {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 40px;
  align-items: start;
}

.checklist {
  padding: 24px;
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: var(--shadow);
}

.checklist-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}

.checklist-head h3 {
  font-size: 1.12rem;
  font-weight: 650;
}

.checklist-count {
  padding: 3px 12px;
  border-radius: 999px;
  background: var(--paper);
  font-size: 0.85rem;
  font-weight: 650;
}

.checklist-count.is-ready {
  background: var(--jade);
  color: var(--white);
}

.checklist ul {
  display: grid;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.checklist-done {
  margin: 14px 0 0;
  font-weight: 600;
  color: var(--jade-dark);
}

.online-steps {
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: os;
}

.online-steps li {
  position: relative;
  padding: 0 0 18px 48px;
  counter-increment: os;
}

.online-steps li::before {
  content: counter(os);
  position: absolute;
  left: 0;
  top: -2px;
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 2px solid var(--ink);
  background: var(--white);
  font-weight: 700;
  font-size: 0.9rem;
}

.online-steps li::after {
  content: "";
  position: absolute;
  left: 16px;
  top: 32px;
  bottom: 2px;
  width: 2px;
  background: var(--line-strong);
}

.online-steps li:last-child::after {
  display: none;
}

.online-steps h3 {
  font-size: 1.02rem;
  font-weight: 650;
  margin-bottom: 4px;
}

.online-steps p {
  margin: 0;
  font-size: 0.93rem;
  color: var(--text);
}

@media (max-width: 860px) {
  .online {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* Safeguarding. */
.safe {
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(0, 0.7fr);
  gap: 40px;
  align-items: start;
}

.dsl-card {
  padding: 26px 24px;
  border-radius: var(--radius);
  background: var(--white);
  border: 2px solid var(--ink);
  box-shadow: 8px 8px 0 var(--jade-soft);
}

.dsl-card h3 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: 1.3rem;
  margin-bottom: 14px;
}

.dsl-person {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 0;
  border-bottom: 1px dashed var(--line);
}

.dsl-person .monogram {
  width: 48px;
  height: 48px;
  font-size: 1.5rem;
  border-radius: 12px 12px 12px 3px;
}

.dsl-person p {
  margin: 0;
  line-height: 1.35;
}

.dsl-person strong {
  display: block;
  color: var(--ink);
}

.dsl-person p span {
  font-size: 0.86rem;
  color: var(--muted);
}

.dsl-contact {
  margin: 14px 0 0;
  font-size: 0.92rem;
}

.dsl-urgent {
  margin: 14px 0 0;
  padding: 12px 14px;
  border-radius: 10px;
  background: var(--english-soft);
  color: var(--ink);
  font-size: 0.9rem;
}

@media (max-width: 860px) {
  .safe {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* FAQ. */
.faq-layout {
  display: grid;
  grid-template-columns: minmax(0, 0.7fr) minmax(0, 1.3fr);
  gap: 24px 56px;
  align-items: start;
}

.faq details {
  border-bottom: 1px solid var(--line);
}

.faq details:first-child {
  border-top: 1px solid var(--line);
}

.faq summary {
  position: relative;
  padding: 18px 44px 18px 0;
  font-weight: 600;
  color: var(--ink);
  cursor: pointer;
  list-style: none;
}

.faq summary::-webkit-details-marker {
  display: none;
}

.faq summary::after {
  content: "";
  position: absolute;
  right: 8px;
  top: 50%;
  width: 22px;
  height: 22px;
  margin-top: -11px;
  border-radius: 6px;
  background:
    linear-gradient(var(--ink), var(--ink)) center / 10px 2px no-repeat,
    linear-gradient(var(--ink), var(--ink)) center / 2px 10px no-repeat,
    var(--sun);
}

.faq details[open] summary::after {
  background:
    linear-gradient(var(--ink), var(--ink)) center / 10px 2px no-repeat,
    var(--sun);
}

.faq details p {
  margin: 0 0 18px;
  max-width: 44em;
}

@media (max-width: 860px) {
  .faq-layout {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* ---------- Privacy ---------- */

.prose {
  max-width: 760px;
}

.prose h2 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: 1.6rem;
  margin: 36px 0 12px;
}

.prose h2:first-child {
  margin-top: 0;
}

.prose-note {
  margin-top: 36px;
  padding: 16px 18px;
  border-radius: 12px;
  background: var(--sun-wash);
  border: 1px solid #f1df9c;
}

/* ---------- Reduced motion ---------- */

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }

  html.js .hl-animate::after {
    transform: skewX(-10deg) rotate(-1deg);
  }
}

@media (forced-colors: active) {
  .hl::after {
    background: Highlight;
  }

  .seats i.is-taken {
    background: GrayText;
  }
}

/* ---------- Additions ---------- */

.eleven-first {
  margin-top: 22px;
  padding: 18px 18px 16px;
  border-radius: 12px;
  background: var(--eleven-soft);
  font-size: 0.93rem;
}

.eleven-first p {
  margin: 0 0 8px;
  font-weight: 600;
  color: var(--ink);
}

.eleven-first p:last-child {
  margin: 10px 0 0;
  font-weight: 400;
}

.eleven-first ol {
  margin: 0;
  padding-left: 22px;
}

.eleven-first li {
  margin-bottom: 4px;
}

.one-box-plain {
  background: var(--paper);
  border: 1px solid var(--line);
}

.one-box-plain .ticks {
  margin: 0;
}

.section-tight {
  padding-top: clamp(40px, 6vw, 72px);
}

.section-mist .one-box {
  padding: 0;
  background: none;
}

/* Trial form details. */
.type-panel {
  margin-top: 22px;
  padding-top: 20px;
  border-top: 1px dashed var(--line-strong);
}

.type-panel[hidden] {
  display: none;
}

.panel-label {
  margin: 0 0 10px;
  padding: 0;
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--ink);
}

.type-panel .field {
  margin-bottom: 18px;
}

.slot-list .choice-body strong {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--muted);
}

.slot-list .choice-body .slot-title {
  font-family: var(--serif);
  font-size: 1.12rem;
  color: var(--ink);
  line-height: 1.3;
}

.slot-list .choice input:checked + .choice-body strong {
  color: var(--jade-dark);
}

.choices-days {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.board-field {
  margin: 18px 0 0;
  max-width: 340px;
}

.board-field[hidden] {
  display: none;
}

.alt-contact {
  margin: 18px 0 0;
  font-size: 0.92rem;
  color: var(--muted);
}

[data-submit-row][hidden] {
  display: none;
}

@media (max-width: 420px) {
  .choices-days {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.date-choices {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
}

/* Fees page details. */
.policy-grid-2 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

@media (max-width: 860px) {
  .policy-grid-2 {
    grid-template-columns: minmax(0, 1fr);
  }
}

.rebook p {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin: 0;
  padding: 16px 20px;
  border-radius: var(--radius-sm);
  background: var(--sun-wash);
  border: 1px solid #f1df9c;
}

.rebook .icon {
  margin-top: 3px;
  color: var(--eleven-ink);
}

.checklist .choices {
  grid-template-columns: minmax(0, 1fr);
  margin: 0;
  padding: 0;
  list-style: none;
}

.checklist-done[hidden] {
  display: none;
}

.dsl-note {
  margin: 14px 0 0;
  font-size: 0.84rem;
  color: var(--muted);
}

.dsl-card h3 .tag {
  margin-left: 6px;
}

.calc-error {
  margin: 12px 0 0;
  color: #ffb3c8;
}

.safe-points .ticks li {
  margin-bottom: 14px;
}

.calc-term .choices {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

@media (max-width: 520px) {
  .calc-term .choices {
    grid-template-columns: minmax(0, 1fr);
  }
}
