/* ==========================================================================
   Refined theme. Loads after site.css.

   One ground (white), one ink (a warm near-black), one accent (the magenta of
   the logo's "Sure"), and two fields: warm sand for light bands and the ink
   itself for dark bands. Flat colour only, with no gradients. Surfaces are told
   apart by a step in tone, not by outlines or shadows. Corners are square
   throughout; only round things (dots, toggles, avatars) stay round.
   ========================================================================== */
:root {
  --ground: #FFFFFF;
  --ink: #1E1A1D;          /* text and dark bands */
  --ink-2: #2B2529;        /* a step lighter, for blocks on dark bands */
  --sand: #F3EDE4;         /* light bands */
  --sand-2: #EAE2D6;       /* a step darker, for blocks on sand */
  --tone: #F7F4EF;         /* blocks on white */
  --note: #5A5257;         /* secondary notes only */
  --accent: #B3145D;       /* the logo's magenta: actions and key figures */
  --accent-deep: #8E0F49;
  --on-dark: #F5F1EC;
  --gold: #F2B640;         /* the logo's hand: one highlight on dark bands */

  /* Older names point at the new roles */
  --pink: var(--accent); --pink-deep: var(--accent-deep);
  --plum: var(--ink); --teal: var(--ink); --blue: var(--ink);
  --amber: var(--gold); --mist: var(--sand); --on-plum: var(--on-dark);
}
::selection { background: #F5D4E2; color: var(--ink); }
body { color: var(--ink); }

/* ---- Bands ------------------------------------------------------------- */
.section--mist, .field-mist, .section--warm,
.can.field-amber, .move.field-pink, .calc.field-teal, .paywork.field-indigo,
.section.field-teal, .section.field-amber { background: var(--sand) !important; color: var(--ink) !important; }
.acalc-section, .calc--white { background: var(--ground); }

.hero, .banner, .banner[class*="field-"], .arthead,
.section.field-plum, .section.field-purple, .section.field-indigo:not(.paywork), .section.field-ocean,
.section.field-pink:not(.move), .field-mauve, .field-green, .field-blue, .foot {
  background: var(--ink) !important; background-image: none !important; color: var(--on-dark) !important;
}
.banner h1, .banner .banner__lead, .banner .crumb, .arthead h1, .hero h1 { color: #fff !important; }
.hero a:not(.btn), .arthead a:not(.btn), .banner a:not(.btn) { color: inherit; }
.section--mist + .paths { background: var(--ground); }
.move a:not(.btn), .calc a:not(.btn), .can a:not(.btn) { color: var(--accent); }
.move .btn--white { background: var(--ink); color: #fff; }

/* ---- Square corners, decided once ------------------------------------- */
.btn, .chip, .seg span, .card, .guide, .job, .pcard, .post, .duo__card, .formcard, .calc__tool, .tablecard,
.book, .acalc, .af__form, .taxeg__sum, .taxeg__case, .referral__types, .referral__way, .typecard, .mosaic__tile,
.stats li, .photo img, .photo::before, .post__pic, .guide__cover, .acalc__opt span, .acalc__ages span,
.acalc__total, .acalc__tax, .acalc__child, .acalc__table, .paywork__card, .callout, .spanel, .af__item,
.typejump a, .guide__lang, .booktabs [role="tab"], .promisehead__list a, .af__steps a, .map, .map__card,
.docfacts li, .routes .route, input:not([type=radio]):not([type=checkbox]), select, textarea, .book__btn,
.af__add, .af__remove, .popup, .popup__close, .menu, .menu__list a, .menu__img, .row, .typecard__suits,
.taxeg__rows .taxeg__total, .can__answers, .near__check input, .jobs__list .job, .arthead img, .article img {
  border-radius: 0 !important;
}

/* ---- Blocks: a step in tone, no outline, no shadow -------------------- */
.card, .guide, .job, .pcard, .post, .duo__card, .formcard, .calc__tool, .tablecard, .acalc, .af__form,
.taxeg__sum, .referral__types, .typecard, .mosaic__tile, .stats li, .paywork__card, .spanel, .book {
  border: 0 !important; box-shadow: none !important; background: var(--tone) !important; background-image: none !important;
}
/* On sand bands, blocks are white */
:is(.section--mist, .section--warm, .can, .move, .calc, .paywork, .field-mist) :is(.card, .guide, .job, .pcard, .post, .duo__card, .formcard, .calc__tool, .tablecard, .taxeg__sum, .referral__types, .typecard, .mosaic__tile, .stats li, .paywork__card, .spanel, .book, .taxeg__case) { background: var(--ground) !important; }
/* On dark bands, blocks are a step lighter than the band */
:is(.hero, .banner, .arthead, .section.field-plum, .section.field-purple, .section.field-indigo, .section.field-ocean) :is(.card, .duo__card, .tablecard, .formcard) { background: var(--ink-2) !important; color: var(--on-dark); }
.field-indigo .duo__card, .ratesband .tablecard, .ratesband table { background: var(--ground) !important; color: var(--ink) !important; }
.cards--dark .card { background: var(--ink-2) !important; color: var(--on-dark) !important; }

/* No decorative colour block behind photos */
.photo::before { display: none !important; }
.photo { margin: 0 !important; }
.photo__fact { background: var(--ink); left: 0 !important; bottom: 0 !important; }
.photo__fact strong { color: var(--gold); }

/* ---- Cards become text-led ------------------------------------------- */
.cards { gap: 2px !important; }
.card { padding: clamp(22px, 2.4vw, 32px) !important; }
.card h3 { margin-top: 0 !important; font-size: clamp(1.2rem, 1.5vw, 1.4rem); line-height: 1.2; }
.card p { margin-top: 10px; }
.cards--compact .card h3 { font: 500 clamp(1.1rem, 1.35vw, 1.25rem)/1.4 var(--text); letter-spacing: 0; }
.card h3 a::after { border-radius: 0; }

/* Ten ways to foster: names large, no tiles of colour */
.mosaic { gap: 2px !important; }
.mosaic__tile { color: var(--ink) !important; padding: 22px !important; }
.mosaic h3 { margin-top: 0 !important; font-size: 1.25rem; }
.mosaic p { color: var(--ink); opacity: .82; }

/* Figures: large magenta numbers on a quiet block */
.stats { gap: 2px !important; }
.stats li { color: var(--ink) !important; padding: 26px 24px !important; }
.stats strong { color: var(--accent); font-size: clamp(2.4rem, 4vw, 3.4rem); }

/* ---- Small things ---------------------------------------------------- */
.ico { background: none !important; color: var(--accent) !important; width: auto !important; height: auto !important; }
.contact-list .ico svg { width: 1.35rem; height: 1.35rem; }
.callout .ico { color: var(--accent) !important; }
.ticks li svg { background: var(--accent); border-radius: 50%; }
.post__tag { background: var(--sand) !important; color: var(--ink); border-radius: 0; }
.acalc__resultlabel { text-transform: none !important; letter-spacing: 0 !important; font-size: 1rem !important; color: var(--accent); }
.guide__body { display: flex; flex-direction: column; align-items: flex-start; }
.guide__body h3 { order: 1; margin-top: 0 !important; }
.guide__tag { order: 2; margin-top: 4px; background: none !important; color: var(--note) !important; font-size: .9375rem !important; }
.guide__body > p:not(.guide__tag) { order: 3; }
.guide__actions, .guide__langs { order: 4; }
.typejump svg { display: none; }
.typejump a { padding: 8px 14px !important; background: var(--tone); box-shadow: none !important; }

/* Chips and option buttons */
.chip { background: var(--ground); color: var(--ink); box-shadow: none; }
.chip[aria-pressed="true"], .seg input:checked + span, .acalc__ages input:checked + span,
.booktabs [role="tab"][aria-selected="true"] { background: var(--ink) !important; color: #fff !important; box-shadow: none !important; }
.seg span, .acalc__ages span { background: var(--tone); box-shadow: none !important; }
:is(.section--mist, .section--warm, .can, .calc) .seg span { background: var(--ground); }

/* Steps, progress and toggles */
.stepper__fill, .af__bar span, .acalc__progress span { background: var(--accent) !important; }
.snode.is-done .snode__ico, .snode[aria-selected="true"] .snode__ico { background: var(--ink) !important; color: #fff; }
.snode[aria-selected="true"] .snode__ico { box-shadow: 0 0 0 5px rgb(179 20 93 / .18); }
.spanel:nth-of-type(n) .spanel__art { background: var(--sand) !important; }
.flow li::before { background: var(--ink) !important; }
.duo__card { --dc: var(--ink) !important; --dc2: var(--ink) !important; }
.acalc__dots li { font-size: .875rem; color: var(--note); }
.acalc__dots .is-on { color: var(--ink); font-weight: 600; }
.acalc__dots .is-done { color: var(--accent); }

/* Types of fostering: one column, no strip */
.typecard { display: block !important; }
.typecard__main { background: transparent !important; }
.typecard__len { background: var(--ground); color: var(--ink); border-radius: 0; }
.typecard h4 { color: var(--ink); }
.typecard .ticks li svg { background: var(--accent); }
.typecard__cols { border-top: 0 !important; }
.typecard__suits { background: var(--ground) !important; }
.typecard__suits .ticks li svg { color: var(--accent); }

/* Promise page and careers */
.pcard h2 { margin-top: 0 !important; }
.promisehead__list a { background: var(--ink-2) !important; }
.job h3 { margin-top: 0 !important; }

/* Allowances */
.ratesband thead tr, .ratesband thead th, table thead th { background: var(--ink) !important; color: #fff; }
.ratesband tbody tr:nth-child(even) { background: var(--tone); }
.ratesband tbody th { color: var(--ink); }
.ratesband tbody td:nth-child(2) { color: var(--accent); }
.acalc__table thead th { background: var(--sand) !important; color: var(--ink) !important; }
.acalc__opt span { background: var(--ground) !important; box-shadow: none !important; }
.acalc__opt svg { color: var(--ink); }
.acalc__opt--num strong { background: none; color: var(--ink); -webkit-text-fill-color: currentColor; }
.acalc__opt input:checked + span { background: var(--ink) !important; color: #fff !important; }
.acalc__opt input:checked + span strong, .acalc__opt input:checked + span svg { color: #fff !important; -webkit-text-fill-color: #fff; }
.acalc__total--week { background: var(--accent); }
.acalc__total--year { background: var(--ink); }
.acalc__tax { background: var(--sand) !important; }
.acalc__taxico, .taxeg__ico, .paywork__ico, .referral__ico, .job__ico, .pcard__ico { display: none !important; }
.acalc__child { background: var(--tone) !important; }
.acalc__child legend svg { display: none; }
.taxeg__case { box-shadow: none !important; }
.taxeg__rows li { border-bottom: 0 !important; }
.taxeg__rows .taxeg__total { background: var(--ink) !important; }
.paywork__card h3 { margin-top: 0 !important; }
.calc__big { color: var(--accent); }

/* Forms */
.af__sub { border-left: 0 !important; padding-left: 0 !important; }
.af__item { box-shadow: none !important; background: var(--tone); }
.af__add { background: var(--tone); color: var(--ink); }
.af__num { display: none !important; }
.af__steps a { padding: 10px 12px !important; }
.af__steps a.is-current { background: var(--ground) !important; box-shadow: inset 3px 0 0 var(--accent) !important; font-weight: 600; }
.af__steps a.is-done { color: var(--note); }
.af__yn, .af__declare .check { background: var(--tone); }
@media (max-width: 900px) {
  .af__steps a { min-width: auto !important; padding: 8px 12px !important; white-space: nowrap; }
  .af__steps a > span:last-child { font-size: .8125rem !important; }
  .af__steps a.is-current { box-shadow: inset 0 -3px 0 var(--accent) !important; }
}

/* Routes under the hero */
.route, .route--pink, .route--amber, .route--blue { background: var(--ink-2) !important; color: #fff !important; }
.route--pink { background: var(--accent) !important; }

/* Pop-ups: they float, so they keep one shadow; no blur */
.popup__head { background: var(--ink) !important; }
.popup::backdrop { backdrop-filter: none !important; background: rgb(30 26 29 / .6); }
.popup__ico { display: none; }
.af__doneicon, .popup__doneico { background: var(--sand); color: var(--accent); }

/* Childline bar */
.callout { background: var(--ground) !important; color: var(--ink) !important; box-shadow: none !important; }
.callout strong { color: var(--accent); }

/* Buttons: flat, no sweep, no glow */
.btn::after { display: none !important; }
.btn--pink:hover, .btn--ink:hover, .btn--white:hover { box-shadow: none !important; }
.btn--ink:hover { background: #000; }
.btn--white:hover { background: var(--sand); }
.btn--line-white { box-shadow: inset 0 0 0 2px #fff; }

/* Hover: a change of tone, no shadow */
@media (hover: hover) and (pointer: fine) {
  .card:hover, .guide:hover, .job:hover, .pcard:hover, .post:hover, .duo__card:hover, .typecard:hover,
  .mosaic__tile:hover, .stats li:hover, .paywork__card:hover, .taxeg__case:hover, .referral__way:hover {
    box-shadow: none !important; transform: none !important;
  }
  .card:has(a):hover, .mosaic__tile:hover { background: var(--sand-2) !important; }
  .post:hover .post__pic img { transform: scale(1.04); }
  .photo:hover img { transform: none; }
  .menu__list a:hover { box-shadow: inset 3px 0 0 var(--accent); }
  .chip:hover { background: var(--sand-2); }
}

/* Footer */
.foot { background: var(--ink) !important; }

/* Last tells: tinted icon squares, resting shadows, rounded badges */
.referral__types a svg { display: none; }
.referral__types a { padding: 10px 0 !important; font-size: 1rem !important; }
.referral__types ul { gap: 0 24px !important; }
.referral__way { box-shadow: none !important; background: var(--ground) !important; }
.photo__fact, .docfacts li { border-radius: 0 !important; }

/* Neighbouring bands always differ by a step in tone */
.journey.section--mist { background: var(--ground) !important; }
.section--warm + .paths, .section--warm + .section--mist { background: var(--ground) !important; }
.foot { background: #141113 !important; }
/* Form step links: finger-sized on phones */
.af__steps a { min-height: 44px; display: flex; align-items: center; }

/* ---- Headers and dark bands back in the logo's aubergine purple ---------- */
:root {
  --band: #2A1436;
  --band-2: #3A1E4A;
  --band-bg: radial-gradient(120% 140% at 85% 0%, #46245A 0%, transparent 55%), linear-gradient(160deg, #2A1436 0%, #331A42 100%);
}
.hero, .banner, .banner[class*="field-"], .arthead,
.section.field-plum, .section.field-purple, .section.field-indigo:not(.paywork), .section.field-ocean,
.section.field-pink:not(.move), .field-mauve, .field-green, .field-blue {
  background: var(--band-bg) !important; color: #F6F1F8 !important;
}
.foot { background: #1F0F29 !important; }
:is(.hero, .banner, .arthead, .section.field-plum, .section.field-purple, .section.field-indigo, .section.field-ocean) :is(.card, .duo__card, .formcard),
.cards--dark .card, .promisehead__list a, .route, .route--amber, .route--blue { background: var(--band-2) !important; }
.route--pink { background: var(--accent) !important; }
.popup__head, .taxeg__rows .taxeg__total, .acalc__total--year, .ratesband thead tr, .ratesband thead th, table thead th { background: var(--band) !important; }

/* Our staff */
.staff__grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: clamp(24px, 3vw, 44px) clamp(16px, 2vw, 28px); list-style: none; margin: 0; padding: 0; }
.staff__grid--lg { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.person img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; background: var(--sand); }
.person h3 { margin-top: 16px; font-size: clamp(1.2rem, 1.6vw, 1.45rem); line-height: 1.15; }
.staff__grid--lg .person h3 { font-size: clamp(1.35rem, 2vw, 1.75rem); }
.person p { margin-top: 4px; color: var(--note); }
@media (max-width: 1000px) { .staff__grid, .staff__grid--lg { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 420px) { .staff__grid, .staff__grid--lg { gap: 22px 12px; } .person h3 { font-size: 1.1rem; } .person p { font-size: .9375rem; } }

.staff__grid { grid-template-columns: repeat(3, minmax(0, 1fr)); max-width: 1100px; }
@media (max-width: 1000px) { .staff__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }


/* Our staff: smaller portraits, so each group fits on screen */
.staff__grid, .staff__grid--lg { grid-template-columns: repeat(auto-fill, minmax(170px, 210px)) !important; max-width: none; gap: 28px 28px; }
.staff__grid--lg { grid-template-columns: repeat(auto-fill, minmax(190px, 240px)) !important; }
.person h3, .staff__grid--lg .person h3 { margin-top: 12px; font-size: 1.15rem; }
.person p { font-size: .9375rem; }
.staff.section { padding-block: clamp(44px, 5vw, 72px); }
@media (max-width: 480px) { .staff__grid, .staff__grid--lg { grid-template-columns: repeat(2, minmax(0, 1fr)) !important; gap: 20px 14px; } }

/* ---- Chat with us ------------------------------------------------------- */
.chatbtn { position: fixed; right: 24px; bottom: 24px; z-index: 65; display: inline-flex; align-items: center; gap: 10px; min-height: 52px; padding: 0 22px 0 18px; border: 0; background: var(--accent); color: #fff; font: 700 1rem var(--display); cursor: pointer; box-shadow: 0 10px 28px rgb(30 20 36 / .28); transition: background-color .2s, transform .2s; }
.chatbtn svg { width: 22px; height: 22px; }
.chatbtn:hover { background: var(--accent-deep); transform: translateY(-2px); }
.chatbtn:focus-visible, .chat button:focus-visible, .chat input:focus-visible, .callbar button:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; }
.chat-open .chatbtn { display: none; }
.chat { position: fixed; right: 24px; bottom: 24px; z-index: 80; display: flex; flex-direction: column; width: min(400px, calc(100vw - 48px)); height: min(640px, calc(100dvh - 48px)); background: var(--ground); color: var(--ink); box-shadow: 0 24px 60px rgb(30 20 36 / .32); }
.chat[hidden] { display: none; }
.chat__head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; padding: 18px 14px 18px 20px; background: var(--band-bg); color: #F6F1F8; }
.chat__head h2 { font-size: 1.3rem; color: #fff; }
.chat__head p { margin: 5px 0 0; font-size: .875rem; line-height: 1.4; color: #E4D9EA; }
.chat__x { display: grid; place-items: center; flex: none; width: 40px; height: 40px; border: 0; background: transparent; color: inherit; cursor: pointer; transition: background-color .2s; }
.chat__x:hover { background: var(--band-2); }
.chat__x svg { width: 22px; height: 22px; }
.chat__log { flex: 1; display: flex; flex-direction: column; gap: 12px; overflow-y: auto; overscroll-behavior: contain; padding: 20px 18px; }
.chat__msg { max-width: 90%; padding: 12px 15px; font-size: .9375rem; line-height: 1.5; }
.chat__msg p { margin: 0; }
.chat__msg p + p, .chat__msg :is(ul, ol) + p { margin-top: 8px; }
.chat__msg :is(ul, ol) { margin: 8px 0 0; padding-left: 20px; }
.chat__msg li + li { margin-top: 4px; }
.chat__msg--bot { align-self: flex-start; background: var(--tone); }
.chat__msg--bot a { color: var(--accent-deep); font-weight: 600; text-decoration: underline; text-underline-offset: 2px; }
.chat__msg--bot a:hover { color: var(--accent); }
.chat__msg--me { align-self: flex-end; background: var(--band); color: #fff; }
.chat__chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chat__chip { min-height: 40px; padding: 8px 14px; border: 0; background: var(--sand); color: var(--ink); font: 600 .875rem/1.3 var(--text); text-align: left; cursor: pointer; transition: background-color .2s, color .2s; }
.chat__chip:hover { background: var(--accent); color: #fff; }
.chat__chip--msg { background: var(--accent); color: #fff; }
.chat__chip--msg:hover { background: var(--accent-deep); }
.chat__form { display: flex; gap: 8px; padding: 12px; background: var(--tone); }
.chat__form input:not(.sr-only) { flex: 1; min-width: 0; min-height: 48px; padding: 0 14px; border: 0; background: #fff; color: var(--ink); font: 400 1rem var(--text); }
.chat__form button { display: grid; place-items: center; flex: none; width: 48px; height: 48px; border: 0; background: var(--accent); color: #fff; cursor: pointer; transition: background-color .2s; }
.chat__form button:hover { background: var(--accent-deep); }
.chat__form button svg { width: 22px; height: 22px; }
@media (max-width: 760px) {
  .chatbtn { display: none; }
  .callbar { grid-template-columns: 1fr 1fr 1fr !important; }
  .callbar button { display: flex; align-items: center; justify-content: center; min-height: 57.2px; border: 0; background: var(--band-2); color: #fff; font: 700 1.1rem var(--display); cursor: pointer; }
  .chat { inset: 0; width: 100%; height: 100dvh; }
  .chat-open, .chat-open body { overflow: hidden; }
}
@media (prefers-reduced-motion: reduce) { .chatbtn:hover { transform: none; } }

/* ---- Photographs added November 2026 ----------------------------------- */
.photorow { display: grid; gap: clamp(12px, 1.6vw, 20px); margin: clamp(28px, 4vw, 48px) 0 0; padding: 0; list-style: none; }
.photorow--2 { grid-template-columns: 1fr 1fr; }
.photorow--3 { grid-template-columns: repeat(3, 1fr); }
.photorow li { overflow: hidden; }
.photorow img { display: block; width: 100%; height: auto; object-fit: cover; transition: transform .6s var(--ease); }
@media (hover: hover) { .photorow li:hover img { transform: scale(1.03); } }
.field-purple .photorow { margin-bottom: clamp(28px, 4vw, 40px); }
.sec-head + .photorow { margin-top: 0; margin-bottom: clamp(24px, 3vw, 36px); }

.typecard { display: grid !important; grid-template-columns: clamp(220px, 26vw, 320px) minmax(0, 1fr); overflow: hidden; }
.typecard__pic { position: relative; min-height: 100%; overflow: hidden; background: var(--sand); }
.typecard__pic img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform .6s var(--ease); }
@media (hover: hover) { .typecard:hover .typecard__pic img { transform: scale(1.04); } }
@media (max-width: 760px) {
  .photorow--2, .photorow--3 { grid-template-columns: 1fr; }
  .photorow--3 li:nth-child(n+2) { display: none; }
  .typecard { grid-template-columns: minmax(0, 1fr); }
  .typecard__pic { min-height: 0; aspect-ratio: 16 / 9; }
}
@media (prefers-reduced-motion: reduce) { .photorow li:hover img, .typecard:hover .typecard__pic img { transform: none; } }

/* ---- Picture frames ------------------------------------------------------
   Main photographs sit on an offset frame line (magenta, gold on dark bands);
   smaller pictures inside cards have a fine white frame inset within them. */
:root { --frame: var(--accent); --frame-off: 14px; }
:is(.hero, .banner, .section.field-plum, .section.field-purple, .section.field-indigo, .section.field-ocean, .vidband) { --frame: var(--gold); }
.photo, .photorow li, .vid__frame { position: relative; isolation: isolate; }
.photo { margin: 0 var(--frame-off) var(--frame-off) 0 !important; }
.photo::after, .photorow li::after, .vid__frame::after {
  content: ''; position: absolute; z-index: -1; inset: var(--frame-off) calc(var(--frame-off) * -1) calc(var(--frame-off) * -1) var(--frame-off);
  border: 2px solid var(--frame); pointer-events: none; transition: inset .45s var(--ease);
}
.photo img { position: relative; z-index: 1; display: block; }
.photo__fact { z-index: 2; }
.photorow { gap: calc(var(--frame-off) * 2 + 8px) !important; padding: 0 var(--frame-off) var(--frame-off) 0 !important; }
.photorow__in { display: block; overflow: hidden; background: var(--sand); }
@media (hover: hover) {
  .photo:hover::after, .photorow li:hover::after, .vid__frame:hover::after { inset: 6px -6px -6px 6px; }
}
/* Inset frames */
.typecard__pic::after, .person__pic::after {
  content: ''; position: absolute; inset: 10px; border: 2px solid rgb(255 255 255 / .85); pointer-events: none; z-index: 1;
}
.person__pic { position: relative; display: block; overflow: hidden; }
.person__pic img { display: block; }
@media (max-width: 760px) {
  :root { --frame-off: 10px; }
  .photorow { gap: calc(var(--frame-off) * 2 + 6px) !important; }
}
@media (prefers-reduced-motion: reduce) { .photo::after, .photorow li::after, .vid__frame::after { transition: none; } }

/* ---- Film band ---------------------------------------------------------- */
.vidband__grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(280px, 400px); gap: clamp(32px, 6vw, 96px); align-items: center; }
.vidband__copy > * + * { margin-top: 16px; }
.vidband__notes { display: grid; gap: 10px; margin: 22px 0 0; padding: 0; list-style: none; }
.vidband__notes li { position: relative; padding-left: 22px; font-size: 1.0625rem; line-height: 1.45; }
.vidband__notes li::before { content: ''; position: absolute; left: 0; top: .55em; width: 10px; height: 2px; background: var(--gold); }
.vidband__cta { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 24px; margin-top: 28px !important; }
.vidband__tel { color: #fff; font-weight: 600; text-decoration: underline; text-underline-offset: 4px; }
.vid { margin: 0 var(--frame-off) var(--frame-off) 0; }
.vid__frame video { position: relative; z-index: 1; display: block; width: 100%; height: auto; aspect-ratio: 678 / 848; background: #000; }
.vid figcaption { margin-top: calc(var(--frame-off) + 14px); font-size: .9375rem; color: #E4D9EA; }
@media (max-width: 960px) {
  .vidband__grid { grid-template-columns: minmax(0, 1fr); }
  .vid { max-width: 400px; width: calc(100% - var(--frame-off)); }
}
.photorow li { overflow: visible !important; }
.typecard__pic::after, .person__pic::after { box-shadow: 0 0 0 1px rgb(30 20 36 / .12), inset 0 0 0 1px rgb(30 20 36 / .12); }

/* ---- How fostering pays (no amounts) ----------------------------------- */
.paycard__list { display: grid; gap: 22px; margin: 0; padding: 0; list-style: none; }
.paycard__list li { display: grid; grid-template-columns: 44px minmax(0, 1fr); gap: 16px; align-items: start; }
.paycard__ico { display: grid; place-items: center; width: 44px; height: 44px; background: var(--sand); color: var(--accent); }
.paycard__ico svg { width: 22px; height: 22px; }
.paycard h3 { font-size: 1.2rem; line-height: 1.2; }
.paycard p { margin-top: 4px; }
.paycard__cta, .payask__cta { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 22px; margin-top: 28px; }
.paycard__tel { font-weight: 600; color: var(--ink); text-decoration: underline; text-underline-offset: 4px; }
.paywork { background: var(--ground); }
.paywork .paywork__card { background: var(--tone) !important; }
.payask { display: grid; grid-template-columns: minmax(0, 1.4fr) auto; gap: 18px 40px; align-items: center; margin-top: clamp(20px, 3vw, 32px); padding: clamp(22px, 3vw, 34px); background: var(--band-bg); color: #F6F1F8; }
.payask h3 { font-size: clamp(1.3rem, 2vw, 1.6rem); color: #fff; }
.payask p { margin-top: 8px; max-width: 62ch; }
.payask__cta { margin-top: 0; }
.payask .btn--ghost { background: var(--band-2); color: #fff; }
.payask .btn--ghost:hover { background: #4A2A5C; }
@media (max-width: 760px) { .payask { grid-template-columns: minmax(0, 1fr); } }

/* ---- One type scale for the whole site ---------------------------------
   Two typefaces only: Gabarito for headings, buttons and menus; Instrument Sans for reading.
   Body 1.1rem · lead var(--t-lead) · small .9375rem · fine print .875rem.
   Card headings come in three sizes: large, standard and small. */
:root {
  --t-small: .9375rem;
  --t-fine: .875rem;
  --t-card-lg: clamp(1.35rem, 2vw, 1.75rem);
  --t-card: clamp(1.2rem, 1.5vw, 1.375rem);
  --t-card-sm: 1.2rem;
}
input, select, textarea, button { font-family: inherit; }
.chat__form input:not(.sr-only), .af__form :is(input, select, textarea), .form :is(input, select, textarea), .near__check input { font-family: var(--text); }

/* Headings */
.arthead h1 { font-size: var(--t-h1) !important; line-height: 1.05; }
.typecard h3, .job h3, .pcard h2, .spanel h3, .payask h3 { font: 600 var(--t-card-lg)/1.15 var(--display) !important; letter-spacing: -.015em; }
.card h3, .duo__card h3, .post h3, .formcard h3, .guide h3, .paywork__card h3, .paycard h3, .promise h3, .article__side h2, .staff__grid--lg .person h3 { font: 600 var(--t-card)/1.2 var(--display) !important; letter-spacing: -.01em; }
.cards--compact .card h3, .person h3, .af__sub { font: 600 var(--t-card-sm)/1.25 var(--display) !important; letter-spacing: -.005em; }
.post--feature h3 { font-size: var(--t-h2) !important; line-height: 1.1 !important; }
h4, .typecard h4 { font: 600 1.05rem/1.25 var(--display); }

/* Reading text */
.can__a, .ask__call, .foot__lead, .taxeg__case p, .near__out, .contact-list, .near li, .vidband__notes li, .paycard p, .payask p { font-size: var(--t-body) !important; line-height: 1.55; }
:is(main, footer) .lead, .paths__intro .lead { font-size: var(--t-lead) !important; line-height: 1.5; }
.note, .guide__tag, figcaption, .vid figcaption, .snode, .photo__fact span, .af__hint, .form .hint { font-size: var(--t-small); }
.check { font-size: var(--t-small) !important; line-height: 1.45 !important; }
.foot__legal, .taxeg__note { font-size: var(--t-fine) !important; }

/* Controls */
.chip, .chips--plain .chip, .chat__chip { font: 500 var(--t-small)/1.2 var(--text) !important; }
.row summary { font: 500 1.15rem/1.3 var(--display) !important; }
.btn { font-family: var(--display); font-weight: 600; }
h3 { font-size: var(--t-card); line-height: 1.2; }
.mosaic__tile h3, .taxeg h3 { font: 600 var(--t-card)/1.2 var(--display) !important; }
/* Transfer: How to transfer, light with readable cards */
.howt { background: var(--ground); color: var(--ink); }
.howt .duo__card { background: var(--tone) !important; color: var(--ink) !important; }
.howt .duo__card h3 { color: var(--ink); }
.howt .flow li { color: var(--ink); }
.paycard .paycard__cta { margin-top: 30px; }

/* Homepage hero routes: the three brand colours from the logo */
.routes .route--pink { background: var(--accent) !important; color: #fff !important; }
.routes .route--amber { background: var(--gold) !important; color: var(--ink) !important; }
.routes .route--blue { background: #6E2C93 !important; color: #fff !important; }
.routes .route { transition: background-color .25s var(--ease); }
.routes .route--pink:hover { background: var(--accent-deep) !important; }
.routes .route--amber:hover { background: #E5A52C !important; }
.routes .route--blue:hover { background: #5A2179 !important; }
.photo img[src*="talking-about-feelings"] { box-sizing: border-box; padding: clamp(12px, 2vw, 22px); background: #fff; }

/* Homepage: the seven steps as a flow */
.flowline { position: relative; display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 12px; margin: 0; padding: 0; list-style: none; }
.flowline::before { content: ''; position: absolute; top: 28px; left: calc(100% / 14); right: calc(100% / 14); height: 2px; background: var(--accent); opacity: .35; }
.flowline li { position: relative; display: grid; justify-items: center; gap: 14px; text-align: center; }
.flowline__ico { display: grid; place-items: center; width: 56px; height: 56px; border-radius: 50%; background: var(--ground); color: var(--accent); box-shadow: 0 0 0 4px var(--sand); transition: background-color .25s var(--ease), color .25s var(--ease); }
.flowline__ico svg { width: 24px; height: 24px; }
.flowline li:hover .flowline__ico { background: var(--accent); color: #fff; }
.flowline__t { max-width: 13ch; font: 600 1.05rem/1.25 var(--display); color: var(--ink); }
.flowline__more { margin-top: clamp(28px, 4vw, 44px); text-align: center; }
@media (max-width: 960px) {
  .flowline { grid-template-columns: minmax(0, 1fr); gap: 0; max-width: 460px; }
  .flowline::before { top: 28px; bottom: 28px; left: 27px; right: auto; width: 2px; height: auto; }
  .flowline li { grid-template-columns: 56px minmax(0, 1fr); justify-items: start; align-items: center; gap: 16px; padding: 8px 0; text-align: left; }
  .flowline__t { max-width: none; }
  .flowline__more { text-align: left; }
}
.canshort__list { display: grid; gap: 12px; margin-bottom: 26px; }
.canshort__list li { font-size: var(--t-body); }
.canshort .lead { margin-top: 16px; max-width: 34ch; }
.canshort .can__grid { align-items: center; }

/* Homepage FAQ: the picture and the questions start on the same line and share a height */
.faqhome { display: grid; grid-template-columns: 4fr 7fr; gap: 28px clamp(36px, 4.4vw, 70px); align-items: stretch; }
.faqhome .photo { height: calc(100% - var(--frame-off)); margin-top: 0 !important; }
.faqhome .photo img { height: 100%; min-height: 300px; aspect-ratio: auto !important; object-fit: cover; }
.faqhome__list { display: flex; flex-direction: column; }
.faqhome__list .btn { align-self: flex-start; margin-top: 24px; }
@media (max-width: 960px) {
  .faqhome { grid-template-columns: minmax(0, 1fr); }
  .faqhome .photo { height: auto; max-width: 620px; }
  .faqhome .photo img { min-height: 0; aspect-ratio: 4 / 3 !important; }
}
/* Can I foster? photo under the intro */
.canshort .photo { margin-top: 26px !important; }
.canshort .can__grid { align-items: start; }
.canshort__grid { display: grid; grid-template-columns: 1fr 1fr; gap: 32px clamp(36px, 5vw, 80px); align-items: stretch; }
.canshort .can__answers { margin-top: 26px; }
.canshort .photo { height: calc(100% - var(--frame-off)); margin-top: 0 !important; }
.canshort .photo img { height: 100%; min-height: 320px; aspect-ratio: auto !important; object-fit: cover; }
@media (max-width: 960px) {
  .canshort__grid { grid-template-columns: minmax(0, 1fr); }
  .canshort .photo { height: auto; max-width: 620px; }
  .canshort .photo img { min-height: 0; aspect-ratio: 4 / 3 !important; }
}

/* Film band: the same size and shape as the photos in two-column sections */
.vidband__grid { grid-template-columns: 1fr 1fr !important; gap: 36px clamp(26px, 4.4vw, 70px) !important; }
.vid { width: auto !important; max-width: none !important; }
.vid__frame video { aspect-ratio: 3 / 2 !important; object-fit: contain; background: #000; }
@media (max-width: 960px) {
  .vidband__grid { grid-template-columns: minmax(0, 1fr) !important; }
  .vid { max-width: 620px !important; width: calc(100% - var(--frame-off)) !important; }
}
.can.canshort .can__answers.card { background: transparent !important; padding: 0 !important; box-shadow: none !important; }

/* Figure tiles: the brand colours, in the same order as the homepage route cards */
main .stats li:nth-child(4n+1) { background: var(--accent) !important; color: #fff !important; }
main .stats li:nth-child(4n+2) { background: var(--gold) !important; color: var(--ink) !important; }
main .stats li:nth-child(4n+3) { background: #6E2C93 !important; color: #fff !important; }
main .stats li:nth-child(4n)   { background: var(--band) !important; color: #fff !important; }
main .stats li strong { color: inherit !important; }
main .stats li:nth-child(4n) strong { color: var(--gold) !important; }
main .stats li span { color: inherit !important; opacity: .92; }

/* Contact details: more space and larger type */
.contact-list { gap: 20px !important; margin-top: 24px !important; font-size: 1.1rem !important; line-height: 1.5 !important; }
.contact-list li { gap: 14px !important; align-items: flex-start; }
.contact-list .ico { width: 2.6rem !important; height: 2.6rem !important; flex: none; }
.contact-list .ico svg { width: 1.3rem !important; height: 1.3rem !important; }
.contact-list li > div { align-self: center; }
.contact-list__big { font-size: clamp(1.4rem, 1.9vw, 1.6rem) !important; margin-bottom: 4px; }
.paths__intro .contact-list + .photo { margin-top: 36px !important; }
.foot__ofstedlink { display: inline-block; }
.foot__ofstedlink .foot__ofsted { transition: background-color .2s, transform .2s var(--ease); }
.foot__ofstedlink:hover .foot__ofsted { background: rgb(255 255 255 / .2); transform: translateY(-2px); }
.foot__ofstedlink:focus-visible { outline: 3px solid var(--gold); outline-offset: 3px; }

/* Our staff: one list, in order of seniority, one person per row */
.stafflist { display: grid; gap: 14px; max-width: 900px; margin: 0; padding: 0; list-style: none; }
.staffrow { display: grid; grid-template-columns: clamp(110px, 14vw, 150px) minmax(0, 1fr); gap: clamp(18px, 3vw, 36px); align-items: center; padding: clamp(14px, 2vw, 20px); background: var(--tone); transition: background-color .25s var(--ease); }
.staffrow:hover { background: var(--sand); }
.staffrow__pic img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; background: var(--sand); }
.staffrow h3 { font: 600 clamp(1.35rem, 2vw, 1.7rem)/1.15 var(--display) !important; letter-spacing: -.015em; }
.staffrow__role { margin-top: 6px; font-size: var(--t-lead); line-height: 1.35; color: var(--accent-deep); font-weight: 500; }
.staffrow__team { margin-top: 8px; font-size: var(--t-small); color: var(--note); }
.stafflist { max-width: none; }
.staffrow { grid-template-columns: clamp(110px, 12vw, 150px) minmax(0, 1fr) minmax(0, 15rem); padding-right: clamp(20px, 3vw, 40px); }
.staffrow__body { display: contents; }
.staffrow h3, .staffrow__role { grid-column: 2; }
.staffrow h3 { align-self: end; }
.staffrow__role { align-self: start; margin-top: 0; }
.staffrow__pic { grid-row: 1 / span 2; }
.staffrow__team { grid-column: 3; grid-row: 1 / span 2; align-self: center; justify-self: end; margin: 0; padding: 8px 14px; background: var(--ground); color: var(--ink); font-weight: 500; text-align: right; }
.staffrow { row-gap: 6px; }
@media (max-width: 760px) {
  .staffrow { grid-template-columns: 110px minmax(0, 1fr); padding-right: 14px; }
  .staffrow__body { display: block; grid-column: 2; grid-row: 1 / span 2; align-self: center; }
  .staffrow__role { margin-top: 6px; }
  .staffrow__team { justify-self: start; margin-top: 10px; padding: 0; background: none; color: var(--note); text-align: left; }
}

/* Our staff: one row per team, from leadership down */
.stafflevels { display: grid; gap: clamp(36px, 5vw, 56px); margin: 0; padding: 0; list-style: none; }
.stafflevel__h { margin-bottom: 18px; text-align: center; font: 600 var(--t-card)/1.2 var(--display) !important; }
.stafflevel__people { display: flex; flex-wrap: wrap; justify-content: center; gap: clamp(16px, 2.4vw, 32px); margin: 0; padding: 0; list-style: none; }
.staffcard { width: clamp(150px, 18vw, 220px); text-align: center; }
.staffcard__pic img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; background: var(--sand); transition: transform .5s var(--ease); }
@media (hover: hover) { .staffcard:hover .staffcard__pic img { transform: scale(1.03); } }
.staffcard h4 { margin-top: 14px; font: 600 1.2rem/1.2 var(--display); }
.staffcard p { margin-top: 4px; color: var(--accent-deep); font-size: var(--t-small); line-height: 1.4; }
.stafflevel + .stafflevel { padding-top: clamp(36px, 5vw, 56px); box-shadow: inset 0 2px 0 var(--tone); }
@media (max-width: 520px) {
  .stafflevel__people { gap: 16px 12px; }
  .staffcard { width: calc(50% - 6px); }
}
.staffcard h4 { margin-bottom: 0 !important; }
.staffcard h4 + p { margin-top: 4px !important; }
.stafflevel__h { font-size: clamp(1.35rem, 2vw, 1.6rem) !important; margin-bottom: 22px; }
@media (max-width: 520px) {
  .stafflevel__people:has(> :nth-child(3)) { gap: 14px 8px; }
  .stafflevel__people:has(> :nth-child(3)) .staffcard { width: calc((100% - 16px) / 3); }
  .stafflevel__people:has(> :nth-child(3)) .staffcard h4 { font-size: 1rem; }
  .stafflevel__people:has(> :nth-child(3)) .staffcard p { font-size: .875rem; }
  .stafflevel__people:has(> :nth-child(3)) .person__pic::after { inset: 6px; }
}
@media (max-width: 520px) {
  .stafflevel__people { gap: 14px 8px !important; }
  .stafflevel__people .staffcard { width: calc((100% - 16px) / 3) !important; }
  .stafflevel__people .staffcard h4 { font-size: 1rem; }
  .stafflevel__people .staffcard p { font-size: .875rem; }
  .stafflevel__people .person__pic::after { inset: 6px; }
}
.staffpage .sec-head { margin-bottom: clamp(40px, 6vw, 72px) !important; }

/* Figure tiles in the logo's blue, green and orange; the last tile stays aubergine */
main .stats li:nth-child(4n+1) { background: #15739A !important; color: #fff !important; }
main .stats li:nth-child(4n+2) { background: #12822A !important; color: #fff !important; }
main .stats li:nth-child(4n+3) { background: #F4AB06 !important; color: var(--ink) !important; }

/* Types of fostering: a two-column grid of cards, details in a fold-out */
.typegrid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(20px, 2.6vw, 32px); margin: clamp(24px, 3vw, 36px) 0 0; padding: 0; list-style: none; }
.typetile { display: flex; flex-direction: column; background: var(--tone); scroll-margin-top: 100px; transition: background-color .25s var(--ease); }
.typetile:hover { background: var(--sand); }
.typetile__pic { position: relative; overflow: hidden; aspect-ratio: 16 / 9; background: var(--sand); }
.typetile__pic img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform .6s var(--ease); }
.typetile__pic::after { content: ''; position: absolute; inset: 10px; border: 2px solid rgb(255 255 255 / .85); pointer-events: none; }
@media (hover: hover) { .typetile:hover .typetile__pic img { transform: scale(1.04); } }
.typetile__body { display: flex; flex: 1; flex-direction: column; padding: clamp(20px, 2.4vw, 30px); }
.typetile__len { display: inline-flex; align-items: center; gap: 8px; align-self: flex-start; margin: 0; padding: 6px 12px; background: var(--ground); color: var(--ink); font-size: var(--t-small); line-height: 1.2; }
.typetile__len svg { width: 16px; height: 16px; color: var(--accent); flex: none; }
.typetile h3 { margin-top: 16px; font: 600 var(--t-card-lg)/1.15 var(--display) !important; letter-spacing: -.015em; }
.typetile__lead { margin-top: 10px; }
.typetile__more { margin-top: auto; padding-top: 20px; }
.typetile__more summary { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 48px; padding: 10px 16px; background: var(--ground); font: 600 1rem/1.25 var(--display); cursor: pointer; list-style: none; transition: background-color .2s, color .2s; }
.typetile__more summary::-webkit-details-marker { display: none; }
.typetile__more summary::after { content: '+'; font-size: 1.3rem; line-height: 1; color: var(--accent); transition: transform .25s var(--ease); }
.typetile__more[open] summary::after { transform: rotate(45deg); }
.typetile__more summary:hover { background: var(--accent); color: #fff; }
.typetile__more summary:hover::after { color: #fff; }
.typetile__cols { display: grid; grid-template-columns: 1fr 1fr; gap: 18px 24px; padding: 18px 16px 4px; }
.typetile__cols h4 { margin-bottom: 8px; }
.typetile__cols .ticks li { font-size: var(--t-small); line-height: 1.45; }
.typetile__cols .ticks li svg { background: var(--accent); }
.typetile__cols > div + div .ticks li svg { background: transparent; color: var(--accent); }
@media (max-width: 960px) { .typetile__cols { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 760px) { .typegrid { grid-template-columns: minmax(0, 1fr); } }
@media (prefers-reduced-motion: reduce) { .typetile:hover .typetile__pic img { transform: none; } }

/* Homepage figure cards: slimmer */
.stats-wrap .stats li { padding: 16px 22px !important; }
.stats-wrap .stats strong { font-size: clamp(1.9rem, 3vw, 2.6rem) !important; line-height: 1 !important; }
.stats-wrap .stats li span { margin-top: 6px; display: block; }

/* Types of fostering: each card a clear white block on sand */
.typesec { background: var(--sand); }
.typesec .typejump a { background: var(--ground) !important; }
.typegrid { row-gap: clamp(32px, 4vw, 48px) !important; column-gap: clamp(20px, 2.6vw, 32px) !important; }
.typetile, .typetile:hover { background: var(--ground) !important; }
.typetile { padding: 12px; }
.typetile__pic::after { inset: 8px; }
.typetile__body { padding: clamp(18px, 2.2vw, 26px) clamp(10px, 1.6vw, 18px) clamp(10px, 1.4vw, 14px); }
.typetile__len { background: var(--sand); }
.typetile__more summary { background: var(--sand); }
.typetile__more summary:hover { background: var(--accent); }
.typegrid { align-items: start; }
.banner .docfacts--banner { width: min(100%, 520px); margin-top: 4px; }
.booktabs__note { margin: 0 0 18px; color: var(--note); font-size: var(--t-small); }
.popup [hidden], .form[hidden] { display: none !important; }
