/* Community Matters Apprenticeships — design system */
:root {
  --red: #c00021;
  --red-dark: #96001a;
  --red-tint: #fdeef0;
  --navy: #14213d;
  --ink: #1f2933;
  --muted: #5b6673;
  --line: #e3e7ec;
  --teal: #0f7c8c;
  --teal-dark: #0a5f6c;
  --teal-tint: #e7f4f6;
  --sand: #f6f3ee;
  --sand-dark: #ebe6dd;
  --white: #ffffff;
  --amber: #f2a900;
  --font: "Manrope", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --radius: 14px;
  --radius-sm: 8px;
  --shadow: 0 10px 30px rgba(20, 33, 61, 0.08);
  --max: 1180px;
  --gutter: clamp(16px, 4vw, 40px);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body { margin: 0; font-family: var(--font); color: var(--ink); background: var(--white); line-height: 1.6; font-size: 17px; }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--teal-dark); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--red); }
h1, h2, h3, h4 { font-weight: 800; line-height: 1.15; color: var(--navy); margin: 0 0 .5em; letter-spacing: -0.01em; }
h1 { font-size: clamp(2rem, 4.5vw, 3.25rem); letter-spacing: -0.02em; }
h2 { font-size: clamp(1.6rem, 3vw, 2.25rem); }
h3 { font-size: 1.25rem; }
h4 { font-size: 1.05rem; }
p { margin: 0 0 1em; }
ul, ol { padding-left: 1.3em; }
li { margin-bottom: .35em; }
.lead { font-size: 1.2rem; color: var(--muted); max-width: 60ch; }
.eyebrow { display: inline-block; font-size: .8rem; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; color: var(--red); margin-bottom: .75rem; }
.muted { color: var(--muted); }
.small { font-size: .9rem; }
.container { width: min(var(--max), 100% - 2 * var(--gutter)); margin-inline: auto; }
.narrow { max-width: 760px; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--navy); color: #fff; padding: .5rem 1rem; z-index: 999; }
.skip:focus { left: 8px; }
:focus-visible { outline: 3px solid var(--amber); outline-offset: 2px; }

/* Buttons */
.btn { white-space: nowrap; display: inline-flex; align-items: center; gap: .5rem; padding: .85rem 1.4rem; border-radius: 999px; font-weight: 700; text-decoration: none; border: 2px solid transparent; cursor: pointer; font-size: 1rem; line-height: 1.2; transition: transform .15s ease, background .15s ease, color .15s ease; }
.btn:hover { transform: translateY(-1px); }
.btn-primary { background: var(--red); color: #fff; }
.btn-primary:hover { background: var(--red-dark); color: #fff; }
.btn-secondary { background: var(--navy); color: #fff; }
.btn-secondary:hover { background: #0d1730; color: #fff; }
.btn-outline { background: transparent; color: var(--navy); border-color: var(--navy); }
.btn-outline:hover { background: var(--navy); color: #fff; }
.btn-light { background: #fff; color: var(--navy); }
.btn-light:hover { background: var(--sand); color: var(--navy); }
.btn-ghost { background: transparent; color: #fff; border-color: rgba(255,255,255,.6); }
.btn-ghost:hover { background: rgba(255,255,255,.12); color: #fff; }
.btn-sm { padding: .55rem 1rem; font-size: .9rem; }
.btn-group { display: flex; flex-wrap: wrap; gap: .75rem; }

/* Audience bar + header */
.audience-bar { background: var(--navy); color: #fff; font-size: .9rem; }
.audience-bar .container { display: flex; justify-content: space-between; align-items: center; min-height: 40px; gap: 1rem; }
.audience-bar nav { display: flex; gap: .25rem; }
.audience-bar a { color: #fff; text-decoration: none; padding: .45rem .9rem; border-radius: 999px; font-weight: 600; opacity: .85; }
.audience-bar a:hover { opacity: 1; }
.audience-bar a[aria-current="true"] { background: var(--red); opacity: 1; }
.audience-bar .links a { padding: .45rem .5rem; }
@media (max-width: 640px) { .audience-bar .links { display: none; } }

.site-header { position: sticky; top: 0; z-index: 50; background: rgba(255,255,255,.96); backdrop-filter: blur(8px); border-bottom: 1px solid var(--line); }
.site-header .container { display: flex; align-items: center; justify-content: space-between; gap: 1rem; min-height: 76px; }
.brand { display: flex; align-items: center; gap: .75rem; text-decoration: none; color: var(--navy); font-weight: 800; flex-shrink: 0; }
.brand img { width: 52px; height: 52px; }
.brand span { line-height: 1.1; font-size: .95rem; white-space: nowrap; }
@media (max-width: 1440px) and (min-width: 1181px) { .brand span { display: none; } }
.brand small { display: block; font-weight: 600; color: var(--muted); font-size: .75rem; letter-spacing: .04em; text-transform: uppercase; }
.main-nav { display: flex; align-items: center; gap: .1rem; }
.main-nav > a, .main-nav > .has-menu > a { color: var(--navy); text-decoration: none; font-weight: 700; padding: .6rem .42rem; border-radius: var(--radius-sm); font-size: .9rem; white-space: nowrap; }
.main-nav > a:hover, .main-nav > .has-menu > a:hover, .main-nav > a[aria-current="page"] { background: var(--sand); color: var(--red); }
.has-menu { position: relative; }
.has-menu > a { display: block; }
.has-menu > a::after { content: ""; display: inline-block; width: .45em; height: .45em; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: rotate(45deg); margin-left: .45em; position: relative; top: -.15em; }
.has-menu .menu { position: absolute; top: 100%; left: 0; min-width: 320px; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: .5rem; display: none; z-index: 60; }
.has-menu:hover .menu, .has-menu:focus-within .menu { display: block; }
.has-menu .menu a { display: block; padding: .6rem .8rem; text-decoration: none; color: var(--navy); border-radius: var(--radius-sm); }
.has-menu .menu a small { display: block; color: var(--muted); font-weight: 500; }
.has-menu .menu a:hover { background: var(--sand); }
.has-menu .menu .all { border-top: 1px solid var(--line); margin-top: .35rem; padding-top: .6rem; font-weight: 700; color: var(--red); }
.header-cta { display: flex; align-items: center; gap: .5rem; flex-shrink: 0; }
.nav-toggle { display: none; background: none; border: 2px solid var(--navy); border-radius: var(--radius-sm); padding: .45rem .7rem; font-weight: 700; color: var(--navy); font-family: inherit; cursor: pointer; }
@media (max-width: 1180px) {
  .main-nav { display: none; }
  .nav-toggle { display: inline-flex; align-items: center; gap: .4rem; }
  .header-cta .btn { display: none; }
  body.nav-open .main-nav { display: flex; flex-direction: column; align-items: stretch; position: absolute; top: 100%; left: 0; right: 0; background: #fff; border-bottom: 1px solid var(--line); padding: .75rem var(--gutter) 1.25rem; box-shadow: var(--shadow); }
  body.nav-open .main-nav > a, body.nav-open .has-menu > a { padding: .8rem .6rem; font-size: 1.05rem; }
  body.nav-open .has-menu .menu { position: static; display: block; border: 0; box-shadow: none; padding: 0 0 .5rem .75rem; min-width: 0; }
  body.nav-open .has-menu > a::after { display: none; }
  body.nav-open .main-nav .mobile-cta { display: flex; margin-top: .75rem; }
}
.main-nav .mobile-cta { display: none; }

/* Hero */
.hero { position: relative; background: var(--navy); color: #fff; overflow: hidden; }
.hero::before { content: ""; position: absolute; inset: 0; background: var(--hero-image) center/cover no-repeat; opacity: .55; }
.hero::after { content: ""; position: absolute; inset: 0; background: linear-gradient(100deg, rgba(20,33,61,.97) 0%, rgba(20,33,61,.88) 42%, rgba(20,33,61,.3) 100%); }
.hero .container { position: relative; z-index: 1; padding: clamp(3rem, 8vw, 6.5rem) 0; display: grid; gap: 2rem; grid-template-columns: minmax(0, 1.25fr) minmax(0, .75fr); align-items: center; }
.hero h1 { color: #fff; margin-bottom: 1rem; max-width: 18ch; }
.hero .lead { color: rgba(255,255,255,.88); font-size: 1.2rem; max-width: 52ch; }
.hero .eyebrow { color: #ffb3bf; }
.hero .btn-group { margin-top: 1.5rem; }
.hero-side { display: grid; gap: 1rem; }
.hero.compact .container { grid-template-columns: 1fr; padding: clamp(2.5rem, 6vw, 4.5rem) 0; }
.hero.compact h1 { max-width: 22ch; }
@media (max-width: 900px) { .hero .container { grid-template-columns: 1fr; } }

/* Ofsted badge */
.ofsted { display: inline-flex; align-items: center; gap: .9rem; background: #fff; color: var(--navy); border-radius: var(--radius); padding: .8rem 1.1rem; text-decoration: none; box-shadow: var(--shadow); max-width: 100%; }
.ofsted .mark { flex: none; width: 46px; height: 46px; border-radius: 50%; background: var(--navy); color: #fff; display: grid; place-items: center; font-weight: 800; font-size: .7rem; letter-spacing: .02em; }
.ofsted b { display: block; font-size: 1rem; line-height: 1.2; }
.ofsted span { font-size: .85rem; color: var(--muted); }
.ofsted:hover { color: var(--navy); transform: translateY(-1px); }
.ofsted-quote { background: rgba(255,255,255,.1); border-left: 4px solid var(--red); padding: 1rem 1.2rem; border-radius: 0 var(--radius) var(--radius) 0; font-size: 1.05rem; }
.ofsted-quote cite { display: block; font-style: normal; font-size: .85rem; color: rgba(255,255,255,.75); margin-top: .5rem; }

/* Sections */
.section { padding: clamp(3rem, 7vw, 5.5rem) 0; }
.section-tight { padding: clamp(2rem, 4vw, 3rem) 0; }
.bg-sand { background: var(--sand); }
.bg-teal { background: var(--teal-tint); }
.bg-navy { background: var(--navy); color: #fff; }
.bg-navy h2, .bg-navy h3 { color: #fff; }
.bg-navy .eyebrow { color: #ffb3bf; }
#information-session { scroll-margin-top: 76px; }
.bg-red { background: var(--red); color: #fff; }
.bg-red h2, .bg-red h3 { color: #fff; }
.section-head { max-width: 720px; margin-bottom: 2.5rem; }
.section-head.center { margin-inline: auto; text-align: center; }
.section-head p { color: var(--muted); font-size: 1.1rem; }
.bg-navy .section-head p, .bg-red .section-head p { color: rgba(255,255,255,.85); }

/* Grid + cards */
.grid { display: grid; gap: 1.5rem; }
.grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
@media (max-width: 960px) { .grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } .grid-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 640px) { .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; } }
.card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 1.6rem; box-shadow: 0 1px 2px rgba(20,33,61,.04); }
.card h3 { margin-top: 0; }
.card p:last-child { margin-bottom: 0; }
.card .icon { width: 44px; height: 44px; border-radius: 12px; background: var(--red-tint); color: var(--red); display: grid; place-items: center; margin-bottom: 1rem; }
.card .icon svg { width: 24px; height: 24px; }
.card-teal .icon { background: var(--teal-tint); color: var(--teal-dark); }
.stat { font-size: .92rem; color: var(--teal-dark); border-top: 1px dashed var(--line); padding-top: .75rem; margin-top: .9rem; }

/* Programme cards */
.prog-card { display: flex; flex-direction: column; background: #fff; border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line); text-decoration: none; color: var(--ink); transition: transform .15s ease, box-shadow .15s ease; }
.prog-card:hover { transform: translateY(-3px); box-shadow: var(--shadow); color: var(--ink); }
.prog-card img { aspect-ratio: 4 / 3; object-fit: cover; width: 100%; }
.prog-card .body { padding: 1.25rem 1.4rem 1.5rem; display: flex; flex-direction: column; gap: .5rem; flex: 1; }
.prog-card h3 { margin: 0; font-size: 1.15rem; }
.prog-card p { margin: 0; color: var(--muted); font-size: .95rem; flex: 1; }
.prog-card .more { color: var(--red); font-weight: 700; }
.pill { display: inline-block; font-size: .75rem; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; padding: .3rem .6rem; border-radius: 999px; background: var(--red-tint); color: var(--red); }
.pill-teal { background: var(--teal-tint); color: var(--teal-dark); }
.pill-navy { background: var(--navy); color: #fff; }
.pill-row { display: flex; gap: .4rem; flex-wrap: wrap; }

/* Logo strips */
.logo-strip { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 1.25rem 2.5rem; }
.logo-strip img { height: 52px; width: auto; max-width: 150px; object-fit: contain; filter: grayscale(1); opacity: .75; transition: filter .2s, opacity .2s; }
.logo-strip img:hover { filter: none; opacity: 1; }
.logo-strip.colour img { filter: none; opacity: 1; }
.logo-strip.tall img { height: 64px; }
@media (max-width: 640px) { .logo-strip { gap: 1rem 1.5rem; } .logo-strip img { height: 40px; max-width: 110px; } }

/* Trust strip on home */
.trust { border-bottom: 1px solid var(--line); background: #fff; }
.trust .container { display: flex; align-items: center; gap: 1.5rem 2.5rem; flex-wrap: wrap; justify-content: center; padding: 1.25rem 0; }
.trust .label { font-size: .8rem; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }

/* Split */
.split { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(2rem, 5vw, 4rem); align-items: center; }
.split img { border-radius: var(--radius); aspect-ratio: 4 / 3; object-fit: cover; width: 100%; }
.split.reverse > :first-child { order: 2; }
@media (max-width: 860px) { .split { grid-template-columns: 1fr; } .split.reverse > :first-child { order: 0; } }

/* Steps */
.steps { counter-reset: step; display: grid; gap: 1.25rem; grid-template-columns: repeat(4, minmax(0,1fr)); }
.step { counter-increment: step; background: #fff; border-radius: var(--radius); padding: 1.5rem; border: 1px solid var(--line); }
.step::before { content: counter(step); display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; background: var(--red); color: #fff; font-weight: 800; margin-bottom: 1rem; }
.step h3 { font-size: 1.05rem; }
.step p { margin: 0; color: var(--muted); font-size: .95rem; }
@media (max-width: 960px) { .steps { grid-template-columns: repeat(2, minmax(0,1fr)); } }
@media (max-width: 560px) { .steps { grid-template-columns: 1fr; } }

/* Quotes */
.quote-card { background: #fff; border-radius: var(--radius); padding: 1.75rem; border: 1px solid var(--line); display: flex; flex-direction: column; gap: 1rem; }
.quote-card blockquote { margin: 0; font-size: 1.05rem; color: var(--navy); }
.quote-card blockquote::before { content: "\201C"; color: var(--red); font-size: 2.5rem; line-height: 0; vertical-align: -0.4em; margin-right: .1em; font-weight: 800; }
.quote-card footer { font-size: .9rem; color: var(--muted); margin-top: auto; }
.quote-card footer b { color: var(--navy); display: block; }

/* Stats */
.stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1.25rem; }
.stat-tile { background: rgba(255,255,255,.08); border-radius: var(--radius); padding: 1.5rem; border: 1px solid rgba(255,255,255,.12); }
.stat-tile .num { font-size: 2.2rem; font-weight: 800; line-height: 1; color: #fff; letter-spacing: -0.02em; }
.stat-tile .lbl { color: rgba(255,255,255,.8); margin-top: .4rem; font-size: .95rem; }
.bg-sand .stat-tile, .bg-white .stat-tile { background: #fff; border-color: var(--line); }
.bg-sand .stat-tile .num { color: var(--red); }
.bg-sand .stat-tile .lbl { color: var(--muted); }
@media (max-width: 900px) { .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* Facts row (programme) */
.facts { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1rem; }
.fact { background: rgba(255,255,255,.1); border: 1px solid rgba(255,255,255,.15); border-radius: var(--radius); padding: 1rem 1.2rem; }
.fact small { display: block; text-transform: uppercase; letter-spacing: .08em; font-size: .72rem; color: rgba(255,255,255,.7); font-weight: 700; }
.fact b { display: block; font-size: 1.05rem; margin-top: .25rem; }
@media (max-width: 900px) { .facts { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* Tabs (audience switch on programme pages) */
.switch { display: inline-flex; background: rgba(255,255,255,.12); border-radius: 999px; padding: 4px; gap: 4px; }
.switch a { color: #fff; text-decoration: none; padding: .5rem 1.1rem; border-radius: 999px; font-weight: 700; font-size: .95rem; }
.switch a[aria-current="true"] { background: #fff; color: var(--navy); }

/* Checklist */
.check { list-style: none; padding: 0; }
.check li { position: relative; padding-left: 1.9rem; margin-bottom: .6rem; }
.check li::before { content: ""; position: absolute; left: 0; top: .35em; width: 1.1em; height: 1.1em; border-radius: 50%; background: var(--teal-tint); }
.check li::after { content: ""; position: absolute; left: .32em; top: .52em; width: .4em; height: .7em; border-right: 2.5px solid var(--teal-dark); border-bottom: 2.5px solid var(--teal-dark); transform: rotate(45deg); }

/* Accordion */
details.acc { border-top: 1px solid var(--line); }
details.acc:last-of-type { border-bottom: 1px solid var(--line); }
details.acc summary { cursor: pointer; list-style: none; padding: 1.1rem 2.5rem 1.1rem 0; font-weight: 700; color: var(--navy); position: relative; font-size: 1.05rem; }
details.acc summary::-webkit-details-marker { display: none; }
details.acc summary::after { content: "+"; position: absolute; right: .25rem; top: 50%; transform: translateY(-50%); font-size: 1.6rem; color: var(--red); font-weight: 400; }
details.acc[open] summary::after { content: "\2212"; }
details.acc .acc-body { padding: 0 0 1.25rem; color: var(--ink); max-width: 70ch; }

/* Table */
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; }
table { width: 100%; border-collapse: collapse; font-size: .95rem; }
th, td { text-align: left; padding: .9rem 1rem; border-bottom: 1px solid var(--line); vertical-align: top; }
th { background: var(--sand); font-size: .8rem; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); }
tr:last-child td { border-bottom: 0; }
td b { color: var(--navy); }

/* Prose */
.prose { max-width: 72ch; }
.prose h2 { margin-top: 2.2rem; font-size: 1.6rem; }
.prose h3 { margin-top: 1.8rem; }
.prose img { border-radius: var(--radius); }
.prose blockquote { margin: 1.5rem 0; padding: 1rem 1.5rem; border-left: 4px solid var(--red); background: var(--sand); border-radius: 0 var(--radius) var(--radius) 0; font-size: 1.1rem; color: var(--navy); }
.prose blockquote p:last-child { margin: 0; }
.prose table { font-size: .92rem; }
.prose .table-wrap { margin: 1.5rem 0; }

/* Article list */
.post-card { display: flex; flex-direction: column; gap: .5rem; padding: 1.5rem; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); text-decoration: none; color: var(--ink); transition: transform .15s ease, box-shadow .15s ease; }
.post-card:hover { transform: translateY(-3px); box-shadow: var(--shadow); color: var(--ink); }
.post-card time { font-size: .85rem; color: var(--muted); font-weight: 600; }
.post-card h3 { margin: 0; font-size: 1.15rem; }
.post-card p { margin: 0; color: var(--muted); font-size: .95rem; }
.post-card .more { color: var(--red); font-weight: 700; margin-top: auto; }

/* Case study cards */
.cs-card { display: grid; grid-template-columns: 1fr; background: #fff; border-radius: var(--radius); border: 1px solid var(--line); overflow: hidden; text-decoration: none; color: var(--ink); }
.cs-card:hover { box-shadow: var(--shadow); color: var(--ink); }
.cs-card .body { padding: 1.5rem; }
.cs-card .logos { display: flex; gap: 1rem; align-items: center; margin-bottom: 1rem; }
.cs-card .logos img { height: 34px; width: auto; max-width: 140px; object-fit: contain; }
.cs-card .kpis { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 1rem; margin-top: 1.25rem; }
.cs-card .kpis div b { display: block; font-size: 1.5rem; color: var(--red); line-height: 1; }
.cs-card .kpis div span { font-size: .8rem; color: var(--muted); }

/* Video */
.video { position: relative; aspect-ratio: 16 / 9; border-radius: var(--radius); overflow: hidden; background: var(--navy); }
.video iframe, .video img { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; object-fit: cover; }
.video button { position: absolute; inset: 0; width: 100%; height: 100%; background: linear-gradient(to top, rgba(20,33,61,.8), rgba(20,33,61,.1)); border: 0; cursor: pointer; color: #fff; font-family: inherit; display: flex; flex-direction: column; justify-content: flex-end; align-items: flex-start; padding: 1.25rem; text-align: left; gap: .5rem; }
.video button .play { width: 56px; height: 56px; border-radius: 50%; background: var(--red); display: grid; place-items: center; }
.video button .play::after { content: ""; border-left: 18px solid #fff; border-top: 11px solid transparent; border-bottom: 11px solid transparent; margin-left: 4px; }
.video button b { font-size: 1.05rem; }
.video button span { font-size: .85rem; opacity: .85; }

/* Team */
.person { text-align: center; }
.person img { aspect-ratio: 3 / 4; object-fit: cover; border-radius: var(--radius); margin-bottom: .75rem; }
.person b { display: block; color: var(--navy); }
.person span { color: var(--muted); font-size: .9rem; }

/* CTA band */
.cta-band { background: var(--red); color: #fff; }
.cta-band .container { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1.5rem; padding: clamp(2.5rem, 5vw, 4rem) 0; }
.cta-band h2 { color: #fff; margin: 0 0 .35rem; }
.cta-band p { margin: 0; color: rgba(255,255,255,.9); max-width: 55ch; }

/* Forms */
.form { display: grid; gap: 1rem; }
.form .row { display: grid; gap: 1rem; grid-template-columns: repeat(2, minmax(0,1fr)); }
@media (max-width: 640px) { .form .row { grid-template-columns: 1fr; } }
label { font-weight: 700; color: var(--navy); font-size: .95rem; display: block; margin-bottom: .35rem; }
label .opt { font-weight: 500; color: var(--muted); }
input[type=text], input[type=email], input[type=tel], select, textarea { width: 100%; font: inherit; padding: .8rem .9rem; border: 1.5px solid #cfd6de; border-radius: var(--radius-sm); background: #fff; color: var(--ink); }
input:focus, select:focus, textarea:focus { border-color: var(--teal); outline: none; box-shadow: 0 0 0 3px var(--teal-tint); }
textarea { min-height: 140px; resize: vertical; }
.checks { display: grid; gap: .5rem; }
.checks label { display: flex; gap: .6rem; align-items: flex-start; font-weight: 500; }
.checks input { margin-top: .3em; }
.hp { position: absolute; left: -9999px; }

/* Contact aside */
.contact-aside { background: var(--sand); border-radius: var(--radius); padding: 1.75rem; }
.contact-aside h3 { margin-top: 0; }
.contact-aside dl { margin: 0; }
.contact-aside dt { font-size: .8rem; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); font-weight: 700; margin-top: 1rem; }
.contact-aside dd { margin: .2rem 0 0; }

/* Footer */
.site-footer { background: var(--navy); color: rgba(255,255,255,.85); padding: 3.5rem 0 2rem; font-size: .95rem; }
.site-footer a { color: #fff; text-decoration: none; }
.site-footer a:hover { color: #ffb3bf; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 2rem; }
.site-footer h4 { color: #fff; font-size: .85rem; letter-spacing: .1em; text-transform: uppercase; margin-bottom: 1rem; }
.site-footer ul { list-style: none; padding: 0; margin: 0; }
.site-footer li { margin-bottom: .5rem; }
.footer-brand { display: flex; align-items: center; gap: .75rem; margin-bottom: 1rem; }
.footer-brand img { width: 48px; height: 48px; border-radius: 50%; }
.footer-brand b { color: #fff; font-size: 1.05rem; }
.footer-badges { display: flex; gap: 1rem; align-items: center; margin-top: 1.25rem; flex-wrap: wrap; }
.footer-badges img { height: 64px; width: auto; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.15); margin-top: 2.5rem; padding-top: 1.5rem; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 1rem; font-size: .85rem; color: rgba(255,255,255,.65); }
.footer-bottom nav { display: flex; gap: 1.25rem; flex-wrap: wrap; }
@media (max-width: 900px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .footer-grid { grid-template-columns: 1fr; } }

/* Utilities */
.mt-1 { margin-top: 1rem; } .mt-2 { margin-top: 2rem; } .mt-3 { margin-top: 3rem; }
.mb-0 { margin-bottom: 0; } .mb-1 { margin-bottom: 1rem; } .mb-2 { margin-bottom: 2rem; }
.center { text-align: center; }
.flex { display: flex; gap: 1rem; flex-wrap: wrap; align-items: center; }
.between { justify-content: space-between; }
.notice { background: var(--teal-tint); border-left: 4px solid var(--teal); padding: 1rem 1.25rem; border-radius: 0 var(--radius) var(--radius) 0; }
.notice p:last-child { margin: 0; }
.breadcrumb { font-size: .85rem; color: var(--muted); margin-bottom: 1rem; }
.breadcrumb a { color: inherit; }
.hero .breadcrumb { color: rgba(255,255,255,.7); }
.aside-box { background: var(--sand); border-radius: var(--radius); padding: 1.5rem; }
.aside-box h3 { font-size: 1.05rem; margin-top: 0; }
.sticky { position: sticky; top: 96px; }
.two-col { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 3rem; align-items: start; }
@media (max-width: 900px) { .two-col { grid-template-columns: 1fr; } .sticky { position: static; } }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { transition: none !important; scroll-behavior: auto !important; } }

.grid-auto { display: grid; gap: 1.5rem; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }
.grid-auto > .card { min-width: 0; }

/* Long email addresses: break after the @ rather than overflowing their box */
.contact-aside dd, .contact-aside a, .site-footer a, .site-footer p { overflow-wrap: anywhere; }
.btn { max-width: 100%; }
/* Responsive column variants (replacing inline grid styles that blocked the mobile layout) */
.steps-3 { grid-template-columns: repeat(3, minmax(0,1fr)); }
.grid-5 { grid-template-columns: repeat(5, minmax(0,1fr)); }
.facts-2 { grid-template-columns: repeat(2, minmax(0,1fr)); }
@media (max-width: 960px) { .steps-3 { grid-template-columns: 1fr; } .grid-5 { grid-template-columns: repeat(3, minmax(0,1fr)); } }
@media (max-width: 640px) { .grid-5 { grid-template-columns: repeat(2, minmax(0,1fr)); } }
@media (max-width: 400px) { .facts-2 { grid-template-columns: 1fr; } }
@media (max-width: 900px) { .two-col { grid-template-columns: minmax(0, 1fr); } }

/* ---------- Learner login and learner portal ---------- */
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
input[type=password], input[type=search] { width: 100%; font: inherit; padding: .8rem .9rem; border: 1.5px solid #cfd6de; border-radius: var(--radius-sm); background: #fff; color: var(--ink); }
.login-wrap { background: var(--sand); padding: clamp(2.5rem, 7vw, 5rem) 0; }
.login-card { max-width: 480px; margin: 0 auto; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: clamp(1.5rem, 4vw, 2.5rem); box-shadow: var(--shadow); }
.login-card h1 { font-size: clamp(1.8rem, 4vw, 2.4rem); margin: .2rem 0 .5rem; }
.login-card .btn { width: 100%; justify-content: center; }
.login-note { border-top: 1px solid var(--line); margin-top: 1.5rem; padding-top: 1.25rem; }
.login-note h2 { font-size: 1.05rem; margin: 0 0 .35rem; }
.login-note p { color: var(--muted); font-size: .95rem; }
.login-msg { background: var(--teal-tint); color: var(--teal-dark); border-radius: var(--radius-sm); padding: .75rem 1rem; font-weight: 600; font-size: .95rem; }

.portal-hero { background: var(--navy); color: #fff; }
.portal-hero .container { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 360px); gap: 2rem; align-items: center; padding: clamp(2.25rem, 5vw, 3.5rem) 0; }
.portal-hero h1 { color: #fff; margin: .2rem 0 .6rem; }
.portal-hero .lead { color: rgba(255,255,255,.88); }
.portal-hero .eyebrow { color: #ffb3bf; }
.portal-hero .signed-in { color: rgba(255,255,255,.75); margin: 1rem 0 0; }
.portal-hero .signed-in a { color: #fff; }
.aptem-card { background: #fff; color: var(--ink); border-radius: var(--radius); padding: 1.5rem; }
.aptem-card h2 { font-size: 1.25rem; margin: 0 0 .35rem; }
.aptem-card p { color: var(--muted); font-size: .95rem; margin: 0 0 1rem; }
@media (max-width: 800px) { .portal-hero .container { grid-template-columns: minmax(0, 1fr); } }

.portal-bar { display: flex; flex-wrap: wrap; gap: 1rem; align-items: center; justify-content: space-between; margin-bottom: .5rem; }
.ptabs { display: flex; flex-wrap: wrap; gap: .5rem; }
.ptab { font: inherit; font-weight: 700; font-size: .95rem; padding: .6rem 1rem; border-radius: 999px; border: 1.5px solid var(--line); background: #fff; color: var(--navy); cursor: pointer; }
.ptab[aria-selected="true"] { background: var(--navy); border-color: var(--navy); color: #fff; }
.psearch { flex: 1 1 260px; max-width: 360px; margin: 0; }
.portal-h { font-size: 1.35rem; margin: 2.25rem 0 1rem; }
.rec-grid { display: grid; gap: 1.25rem; grid-template-columns: repeat(3, minmax(0, 1fr)); }
.rec .small { display: inline-block; margin-top: .45rem; }
@media (max-width: 960px) { .rec-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) { .rec-grid { grid-template-columns: minmax(0, 1fr); } }
.portal-cat summary .count { display: inline-block; margin-left: .5rem; font-size: .8rem; font-weight: 700; color: var(--muted); background: var(--sand); border-radius: 999px; padding: .1rem .55rem; vertical-align: middle; }
.portal-cat .acc-body { max-width: none; }
.file-sub { font-size: .8rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); margin: 1.1rem 0 .35rem .5rem; }
.file-group:first-child .file-sub { margin-top: .25rem; }
.file-list { list-style: none; margin: 0; padding: 0; display: grid; gap: .15rem; }
.file-list li { display: flex; gap: .75rem; align-items: center; padding: .45rem .5rem; border-radius: var(--radius-sm); }
.file-list li:hover { background: var(--sand); }
.file-list a { color: var(--navy); font-weight: 600; text-decoration: none; overflow-wrap: anywhere; }
.file-list a:hover { color: var(--red); text-decoration: underline; }
.ftype { flex: 0 0 auto; font-size: .7rem; font-weight: 800; letter-spacing: .04em; border-radius: 6px; padding: .2rem .4rem; background: var(--red-tint); color: var(--red); min-width: 2.6rem; text-align: center; }
.ftype-docx { background: #e8f0fe; color: #1a56c4; }
.ftype-xlsx { background: #e6f4ea; color: #137333; }
.ftype-png { background: var(--teal-tint); color: var(--teal-dark); }
.search-empty { color: var(--muted); font-weight: 600; }
.portal-help { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 2rem; }
.portal-help h2 { font-size: 1.2rem; margin: 0 0 .4rem; }
.portal-help p { margin: 0; color: var(--ink); }
.portal-help a { overflow-wrap: anywhere; }
@media (max-width: 700px) { .portal-help { grid-template-columns: minmax(0, 1fr); } }
[hidden] { display: none !important; }
.your-prog { margin: 0; font-size: 1rem; color: var(--muted); }
.your-prog b { color: var(--navy); }

/* Manage learners (staff) */
.manage-grid { display: grid; grid-template-columns: minmax(0, 340px) minmax(0, 1fr); gap: 2rem; align-items: start; }
@media (max-width: 960px) { .manage-grid { grid-template-columns: minmax(0, 1fr); } }
.add-card h2, .list-head h2 { font-size: 1.3rem; margin: 0 0 1rem; }
.add-card .btn { width: 100%; justify-content: center; }
.lbl-strong { display: block; font-weight: 700; color: var(--navy); font-size: .95rem; margin-bottom: .5rem; }
.form-error { background: var(--red-tint); color: var(--red-dark); border-radius: var(--radius-sm); padding: .6rem .8rem; font-weight: 600; font-size: .92rem; margin: 0; }
.list-head { display: flex; flex-wrap: wrap; gap: .75rem 1rem; align-items: center; justify-content: space-between; margin-bottom: 1rem; }
.list-head h2 { margin: 0; }
.list-head .count { font-size: .85rem; font-weight: 700; color: var(--muted); background: var(--sand); border-radius: 999px; padding: .15rem .6rem; vertical-align: middle; }
.list-tools { display: flex; flex-wrap: wrap; gap: .5rem; }
.list-tools select, .list-tools input { width: auto; min-width: 180px; padding: .55rem .7rem; }
.ln-table td { vertical-align: middle; }
.ln-table .ln-name { font-weight: 700; color: var(--navy); }
.ln-table .ln-email { font-size: .88rem; color: var(--muted); overflow-wrap: anywhere; }
.ln-table select { padding: .45rem .55rem; font-size: .9rem; min-width: 0; }
.status { display: inline-block; font-size: .78rem; font-weight: 700; border-radius: 999px; padding: .15rem .6rem; white-space: nowrap; }
.status-invited { background: #fff4d6; color: #8a5a00; }
.status-active { background: #e6f4ea; color: #137333; }
.row-actions { display: flex; gap: .4rem; justify-content: flex-end; flex-wrap: wrap; }
.link-btn { font: inherit; font-size: .88rem; font-weight: 700; background: none; border: 0; padding: .3rem .4rem; cursor: pointer; color: var(--teal-dark); border-radius: 6px; }
.link-btn:hover { background: var(--sand); }
.link-btn.danger { color: var(--red); }
.ln-empty td { text-align: center; color: var(--muted); padding: 2rem 1rem; }
.login-err { background: var(--red-tint); color: var(--red-dark); }
@media (max-width: 560px) { .list-tools { width: 100%; } .list-tools select, .list-tools input { flex: 1 1 100%; min-width: 0; width: 100%; } }
.list-tools select { max-width: 100%; }
.ln-table .ln-email { overflow-wrap: normal; }
.ln-table td:first-child { min-width: 13rem; }
.table-wrap { position: relative; }
.stat-tile .stat-logo { display: inline-flex; background: #fff; border-radius: 6px; padding: 2px 6px; line-height: 0; }
.stat-tile .stat-logo img { display: block; height: 31px; width: auto; }

:root{color-scheme:light}
html{scroll-padding-top:env(safe-area-inset-top,0px)}
body{background:#fff;padding-top:env(safe-area-inset-top,0px);padding-bottom:env(safe-area-inset-bottom,0px)}
.steps-list{padding-left:1.2rem;margin:.5rem 0 .75rem}.steps-list li{margin-bottom:.45rem}
.pill-row .pill-break{flex-basis:100%;height:0;margin:0}
/* Mobile menu: programmes list folds away, and the open menu scrolls on small screens */
body.nav-open .main-nav{max-height:calc(100vh - 120px);max-height:var(--nav-max,calc(100dvh - 120px));overflow-y:auto;overscroll-behavior:contain;-webkit-overflow-scrolling:touch}
body.nav-open .has-menu .menu{display:none}
body.nav-open .has-menu.sub-open .menu{display:block}
body.nav-open .has-menu > a{display:flex;justify-content:space-between;align-items:center}
body.nav-open .has-menu > a::after{display:inline-block;margin-right:.35rem;transition:transform .15s}
body.nav-open .has-menu.sub-open > a::after{transform:rotate(225deg);top:.1em}
.toast{position:fixed;left:50%;bottom:calc(16px + env(safe-area-inset-bottom,0px));transform:translateX(-50%);background:#14213d;color:#fff;padding:.75rem 1.1rem;border-radius:10px;font:600 .9rem var(--font);box-shadow:0 10px 30px rgba(0,0,0,.25);z-index:999;max-width:calc(100% - 32px)}

/* Ofsted QR code and sliding "Trusted by" banner */
.ofsted-wrap{display:flex;gap:.75rem;align-items:stretch;flex-wrap:wrap}
.ofsted-qr{display:inline-flex;align-items:center;gap:.6rem;background:#fff;color:var(--navy);border-radius:var(--radius);padding:.5rem .7rem;box-shadow:var(--shadow);text-decoration:none;font-size:.75rem;line-height:1.25;max-width:100%}
.ofsted-qr svg{width:64px;height:64px;flex:none;display:block}
.ofsted-qr span{max-width:6.5rem;color:var(--muted);font-weight:600}
.ofsted-qr:hover{color:var(--navy);transform:translateY(-1px)}
.bg-navy .ofsted-wrap{align-items:center}
.ofsted-quote{margin:0}
.hero-side .ofsted-quote{width:100%}
.hero-side .ofsted-wrap{width:100%}
.trust .container{flex-direction:column;gap:.6rem;align-items:stretch}
.trust .label{text-align:center}
.logo-marquee{overflow:hidden;width:100%;-webkit-mask-image:linear-gradient(90deg,transparent,#000 8%,#000 92%,transparent);mask-image:linear-gradient(90deg,transparent,#000 8%,#000 92%,transparent)}
.logo-marquee .track{display:flex;align-items:center;width:max-content;animation:logo-scroll 55s linear infinite;padding:.25rem 0}
.logo-marquee:hover .track,.logo-marquee:focus-within .track{animation-play-state:paused}
.logo-marquee img{height:44px;width:auto;max-width:130px;object-fit:contain;margin-right:3rem;filter:grayscale(1);opacity:.75;transition:filter .2s,opacity .2s}
.logo-marquee img:hover{filter:none;opacity:1}
@keyframes logo-scroll{to{transform:translateX(-50%)}}
@media (prefers-reduced-motion:reduce){.logo-marquee{mask-image:none;-webkit-mask-image:none}.logo-marquee .track{animation:none;width:auto;flex-wrap:wrap;justify-content:center;gap:1rem 0}.logo-marquee img.dup{display:none}}

/* Learner area: live-site additions */
.login-card form + form, .login-card .login-msg + form { margin-top: 0; }
.login-card .pw-hint { font-size: .88rem; color: var(--muted); margin: -.35rem 0 0; }
.login-card .link-btn { padding-left: 0; }
.portal-loading { color: var(--muted); font-weight: 600; padding: 1.5rem 0; }
.ln-table tr.busy { opacity: .5; pointer-events: none; }

/* Manage learners: import a list */
.bulk-card { margin-bottom: 2rem; border-color: var(--teal); box-shadow: var(--shadow); scroll-margin-top: 6.5rem; }
.bulk-head { display: flex; align-items: baseline; justify-content: space-between; gap: 1rem; margin-bottom: .5rem; }
.bulk-head h2 { font-size: 1.3rem; margin: 0; }
.bulk-head h2:focus { outline: none; }
.bulk-card textarea { min-height: 11rem; font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: .9rem; line-height: 1.5; white-space: pre; overflow: auto; tab-size: 4; }
.bulk-card input[type=file] { width: 100%; font: inherit; font-size: .92rem; padding: .55rem .6rem; border: 1.5px dashed #cfd6de; border-radius: var(--radius-sm); background: var(--sand); }
.bulk-card .row { align-items: end; }
.bulk-help { border: 1px solid var(--line); border-radius: var(--radius-sm); padding: .7rem .9rem; font-size: .93rem; }
.bulk-help summary { font-weight: 700; color: var(--navy); cursor: pointer; }
.bulk-help ul { margin: .6rem 0 0; padding-left: 1.2rem; }
.bulk-help li + li { margin-top: .35rem; }
.bulk-summary { font-weight: 600; color: var(--navy); margin: .25rem 0 1rem; }
.bulk-summary b.bad { color: var(--red-dark); }
.bulk-wrap { max-height: min(34rem, 70vh); overflow: auto; }
.bulk-table thead th { position: sticky; top: 0; z-index: 1; box-shadow: 0 1px 0 var(--line); }
.bulk-table td:first-child { min-width: 0; width: 3.5rem; color: var(--muted); font-variant-numeric: tabular-nums; }
.bulk-table td:nth-child(2) { min-width: 13rem; }
.bulk-table td:nth-child(4) { min-width: 12rem; }
.bulk-table .ln-email { overflow-wrap: anywhere; }
.bulk-table tr.b-out td:not(:last-child) { opacity: .45; }
.bulk-table tr.b-out .ln-name, .bulk-table tr.b-out .ln-email { text-decoration: line-through; }
.bulk-table tr.b-skip td:not(:last-child) { opacity: .7; }
.bulk-note { display: block; font-size: .85rem; color: var(--muted); margin-top: .25rem; max-width: 34ch; }
.bulk-note.bad { color: var(--red-dark); font-weight: 600; }
.bulk-note.warn { color: #8a5a00; font-weight: 600; }
.status-ready { background: var(--teal-tint); color: var(--teal-dark); }
.status-problem, .status-failed { background: var(--red-tint); color: var(--red-dark); }
.status-skip, .status-out, .status-waiting { background: var(--sand); color: var(--muted); }
.status-sending { background: #fff4d6; color: #8a5a00; }
.status-sent { background: #e6f4ea; color: #137333; }
.status-noemail { background: #fff4d6; color: #8a5a00; }
.bulk-actions { margin-top: 1.25rem; }
.bulk-card .btn:disabled { opacity: .6; cursor: default; transform: none; }
.bulk-link { margin: 1rem 0 0; color: var(--muted); }
.bulk-link .link-btn { padding-left: .15rem; font-size: inherit; text-decoration: underline; text-underline-offset: 3px; }
@media (max-width: 560px) { .bulk-actions .btn { flex: 1 1 100%; justify-content: center; } }
/* On a phone each row of the checked list becomes a small block, so the result is visible without scrolling sideways. */
@media (max-width: 700px) {
  .bulk-table thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  .bulk-table, .bulk-table tbody, .bulk-table tr, .bulk-table td { display: block; }
  .bulk-table tr { position: relative; padding: .8rem .9rem .8rem 2.9rem; border-bottom: 1px solid var(--line); }
  .bulk-table tr:last-child { border-bottom: 0; }
  .bulk-table td, .bulk-table td:first-child, .bulk-table td:nth-child(2), .bulk-table td:nth-child(4) { min-width: 0; width: auto; padding: .15rem 0; border: 0; }
  .bulk-table td:first-child { position: absolute; left: .9rem; top: .95rem; }
  .bulk-table td:nth-child(3) { font-size: .9rem; color: var(--muted); }
  .bulk-table td:nth-child(4) { padding-top: .4rem; }
  .bulk-table td:last-child:not(:has(button)) { display: none; }
  .bulk-table .row-actions { justify-content: flex-start; margin-left: -.4rem; }
  .bulk-note { max-width: none; }
}
.err-page { padding: clamp(3rem, 8vw, 6rem) 0; text-align: center; }

/* Cookie choice banner and footer control */
.cookie-banner { position: fixed; left: 0; right: 0; bottom: 0; z-index: 900; background: var(--navy); color: #fff; border-top: 1px solid rgba(255,255,255,.25); box-shadow: 0 -10px 30px rgba(20, 33, 61, .2); padding: 1rem 0 calc(1rem + env(safe-area-inset-bottom, 0px)); }
.cookie-banner[hidden] { display: none; }
.cookie-banner:focus { outline: none; }
.cookie-banner .container { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .9rem 2rem; }
.cookie-banner p { margin: 0; flex: 1 1 340px; max-width: 64ch; font-size: .95rem; line-height: 1.5; }
.cookie-banner a { color: #fff; }
.cookie-banner a:hover { color: #ffb3bf; }
.cookie-banner [data-cookie-state] { font-weight: 700; }
.cookie-actions { display: flex; flex-wrap: wrap; gap: .6rem; }
.cookie-actions .btn { flex: 1 1 0; justify-content: center; }
.footer-bottom nav button { font: inherit; color: #fff; background: none; border: 0; padding: 0; cursor: pointer; }
.footer-bottom nav button:hover { color: #ffb3bf; }
.footer-bottom nav button[hidden] { display: none; }
.cookie-table code { font-size: .88em; overflow-wrap: anywhere; }
@media print { .cookie-banner, .toast { display: none !important; } }
