/* Booking page mockup. Builds on site.css (tokens, header, buttons, footer, steps, care list).
   Shape system is unchanged: 8px controls and markers, 16px panels. Selection is shown by border, fill and a tick, never by colour alone.
   --error is the one new token and is used for form errors only. */

:root{--error:#b3261e}
@media(prefers-color-scheme:dark){:root{--error:#ff9f98}}

.visually-hidden{position:absolute!important;width:1px;height:1px;margin:-1px;padding:0;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap;border:0}
button.text-link{background:none;border:0;padding:0;color:inherit}
h2[tabindex="-1"]:focus,h3[tabindex="-1"]:focus{outline:none}

/* Mockup banner and hero */
.mock-banner{max-width:none;margin:0;padding:9px 20px;background:var(--lime);color:#091f3c;font-size:13px;line-height:1.5;text-align:center}
.mock-banner strong{font-weight:800}
.book-hero{padding-block:clamp(36px,5vw,64px);background:var(--navy);border-bottom:3px solid var(--lime);color:#f5f7f4}
.book-hero h1{margin-bottom:14px;font-size:clamp(34px,4vw,52px);letter-spacing:-.045em;color:#fff}
.book-hero p{margin:0;max-width:46ch;font-size:18px;color:#d2dfe7}

/* Layout */
.book{padding-block:clamp(36px,5vw,72px) clamp(56px,7vw,96px)}
.book-layout{display:grid;grid-template-columns:minmax(0,1fr) 372px;gap:clamp(32px,5vw,72px);align-items:start}
.book-flow{min-width:0}

/* Stepper */
.stepper{display:flex;align-items:center;margin:0 0 40px;padding:0;list-style:none}
.stepper[hidden]{display:none}
.stepper li{display:flex;align-items:center;gap:12px;flex:0 0 auto;font-size:14px;font-weight:650;color:var(--muted)}
.stepper li:not(:last-child){flex:1 1 auto}
.stepper li:not(:last-child):after{content:'';flex:1;height:1px;min-width:16px;margin-inline:14px;background:var(--line-strong)}
.stepper .num{display:grid;place-items:center;flex:none;width:34px;height:34px;border:1px solid var(--line-strong);border-radius:var(--r-ctl);background:var(--bg);font-variant-numeric:tabular-nums}
.stepper .num .ico{width:18px;height:18px}
.stepper li[aria-current="step"]{color:var(--heading)}
.stepper li[aria-current="step"] .num{border-color:var(--action);background:var(--action);color:#fff}
.stepper li.done{color:var(--heading)}
.stepper li.done .num{border-color:var(--accent-text);background:var(--surface);color:var(--accent-text)}

/* Steps */
.step h2{margin-bottom:28px;font-size:clamp(28px,3vw,38px);letter-spacing:-.04em}
.step-lead{max-width:56ch;margin:-12px 0 28px;color:var(--muted)}
.step[hidden],.confirm[hidden]{display:none}
.field-group{min-width:0;margin:0 0 36px;padding:0;border:0}
.field-group legend{padding:0;margin-bottom:14px;font-size:14px;font-weight:700;color:var(--heading)}
.field-top{margin-top:36px}
.small-copy{font-size:14px;color:var(--muted)}
.step-actions{display:flex;flex-wrap:wrap;align-items:center;gap:12px 28px;margin-top:12px}
.mock-note{display:flex;align-items:baseline;gap:10px;max-width:68ch;margin:0 0 28px;font-size:13px;line-height:1.55;color:var(--muted)}
.tag{display:inline-block;flex:none;padding:1px 8px;border:1px solid var(--line-strong);border-radius:var(--r-ctl);background:var(--surface);font-size:11px;font-weight:750;letter-spacing:.04em;text-transform:uppercase;color:var(--heading)}
.policy .tag{margin-left:4px;vertical-align:1px}

/* Selectable choices: clinic, service, funding, visit history, dates and times */
.choice-grid{display:grid;grid-template-columns:1fr 1fr;gap:14px}
.choice-list{display:grid;gap:12px}
.choice{position:relative;display:flex;align-items:center;gap:16px;min-width:0;padding:16px 18px;border:1px solid var(--line-strong);border-radius:var(--r-box);background:var(--bg);cursor:pointer;transition:border-color .2s,background-color .2s}
.choice:hover{border-color:var(--muted)}
.choice input{position:absolute;inset:0;width:100%;height:100%;margin:0;opacity:0;cursor:pointer}
.choice:has(input:checked){border-color:var(--accent-text);background:var(--bg-soft);box-shadow:inset 0 0 0 1px var(--accent-text)}
.choice:has(input:focus-visible){outline:3px solid var(--focus);outline-offset:3px}
.choice-body{display:flex;flex-direction:column;gap:2px;min-width:0;flex:1;font-size:14px;line-height:1.55;color:var(--muted)}
.choice-body strong{font-size:16px;font-weight:700;line-height:1.4;color:var(--heading)}
.choice-price{flex:none;font-size:16px;font-variant-numeric:tabular-nums;color:var(--heading)}
.choice-tick{display:grid;place-items:center;flex:none;width:26px;height:26px;margin-left:auto;border:1px solid var(--line-strong);border-radius:var(--r-ctl);color:transparent;transition:background-color .2s,border-color .2s}
.choice-tick .ico{width:16px;height:16px}
.choice:has(input:checked) .choice-tick{border-color:var(--action);background:var(--action);color:#fff}
.choice-clinic img{flex:none;width:72px;height:72px;border-radius:var(--r-ctl);object-fit:cover}
.choice-compact{padding:14px 18px}
.choice-compact .choice-body strong{font-size:15px}

.day-grid{display:grid;grid-template-columns:repeat(7,minmax(0,1fr));gap:10px}
.day{flex-direction:column;justify-content:center;gap:0;padding:12px 4px;text-align:center}
.day .choice-tick{display:none}
.day-dow{font-size:13px;font-weight:650;color:var(--muted)}
.day-num{font-size:26px;font-weight:700;line-height:1.2;letter-spacing:-.03em;font-variant-numeric:tabular-nums;color:var(--heading)}
.day-mon{font-size:13px;color:var(--muted)}
.slot-group+.slot-group{margin-top:22px}
.slot-group h3{margin-bottom:10px;font-size:14px;font-weight:650;letter-spacing:0;color:var(--muted)}
.slot-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(98px,1fr));gap:10px}
.slot{justify-content:center;padding:11px 8px;font-size:15px;font-weight:650;font-variant-numeric:tabular-nums;color:var(--heading)}
.slot .choice-tick{display:none}
.empty{margin:0;padding:18px 20px;border:1px dashed var(--line-strong);border-radius:var(--r-box);color:var(--muted)}

/* Form fields */
.fields{display:grid;grid-template-columns:1fr 1fr;gap:22px 20px}
.field{display:flex;flex-direction:column;gap:8px;min-width:0}
.span-2{grid-column:1/-1}
.step>.field{margin-bottom:22px}
.field label{font-size:14px;font-weight:650;color:var(--heading)}
.optional{margin-left:6px;font-weight:500;color:var(--muted)}
.field input[type="text"],.field input[type="tel"],.field input[type="email"],.field input[type="date"],.field textarea{width:100%;min-height:48px;padding:12px 14px;border:1px solid var(--line-strong);border-radius:var(--r-ctl);background:var(--bg);font:inherit;font-size:16px;color:var(--ink);transition:border-color .2s}
.field textarea{resize:vertical}
.field input:focus,.field textarea:focus{outline:3px solid var(--focus);outline-offset:2px;border-color:var(--accent-text)}
.field .hint,.field .error{max-width:none;margin:0;font-size:13px;line-height:1.5}
.field .hint{color:var(--muted)}
.field .error,.form-error{color:var(--error)}
.field[data-invalid] input,.field[data-invalid] textarea{border-color:var(--error)}
.field[data-invalid] .check-box{border-color:var(--error)}
.form-error{display:flex;align-items:center;gap:10px;margin:0 0 20px;font-size:14px;font-weight:650}
.form-error[hidden]{display:none}
.form-error .ico{width:20px;height:20px}
.consent{margin:8px 0 28px}
.check{display:flex;align-items:flex-start;gap:14px;font-size:15px;font-weight:500;line-height:1.55;color:var(--ink);cursor:pointer}
.check input{position:absolute;width:1px;height:1px;opacity:0}
.check-box{display:grid;place-items:center;flex:none;width:26px;height:26px;margin-top:-1px;border:1px solid var(--line-strong);border-radius:var(--r-ctl);background:var(--bg);color:transparent}
.check-box .ico{width:16px;height:16px}
.check:has(input:checked) .check-box{border-color:var(--action);background:var(--action);color:#fff}
.check:has(input:focus-visible) .check-box{outline:3px solid var(--focus);outline-offset:3px}
.check a{font-weight:650;color:var(--accent-text);text-decoration:underline;text-underline-offset:3px}
.check a .ico{width:13px;height:13px;margin-left:3px;vertical-align:-1px}

/* Payment */
.due-list{display:grid;grid-template-columns:1fr 1fr;gap:0 40px;max-width:520px;margin:0 0 28px}
.due-list>div{display:flex;flex-direction:column;gap:2px;padding-top:14px;border-top:1px solid var(--line-strong)}
.due-list dt{font-size:13px;color:var(--muted)}
.due-list dd{margin:0;font-size:28px;font-weight:700;letter-spacing:-.03em;font-variant-numeric:tabular-nums;color:var(--heading)}
.pay-box{max-width:560px;margin-bottom:24px;padding:28px;border:1px solid var(--line-strong);border-radius:var(--r-box);background:var(--bg-soft)}
.pay-head{display:flex;align-items:center;justify-content:space-between;gap:16px;margin-bottom:20px}
.pay-head h3{font-size:20px}
.test-chip{padding:3px 10px;border:1px solid var(--line-strong);border-radius:var(--r-ctl);background:var(--surface);font-size:12px;font-weight:700;color:var(--heading)}
.wallets{display:grid;grid-template-columns:1fr 1fr;gap:12px}
.wallet{display:grid;place-items:center;min-height:56px;border:1px solid var(--heading);border-radius:var(--r-ctl);background:var(--heading);color:var(--bg);transition:opacity .2s,transform .15s}
.wallet:hover{opacity:.9}
.wallet:active{transform:scale(.98)}
.wallet .brand-mark{width:68px;height:44px}
.divider{display:flex;align-items:center;gap:14px;max-width:none;margin:22px 0;font-size:13px;color:var(--muted)}
.divider:before,.divider:after{content:'';flex:1;height:1px;background:var(--line-strong)}
.pay-fields{display:grid;grid-template-columns:1fr 1fr;gap:16px;margin-bottom:24px}
.pay-fields input[readonly]{background:var(--surface);color:var(--ink);cursor:default;font-variant-numeric:tabular-nums}
.pay-btn{width:100%;min-height:52px;font-size:15px}
.pay-btn .ico{width:18px;height:18px}
.pay-btn[aria-busy="true"]{opacity:.75;cursor:progress}
.pay-foot{display:flex;align-items:flex-start;gap:10px;max-width:none;margin:16px 0 0;font-size:13px;line-height:1.55;color:var(--muted)}
.pay-foot .brand-mark{flex:none;width:18px;height:18px;margin-top:1px;color:var(--heading)}

/* Brand marks: monochrome stand-ins */
.brand-mark{display:block;width:30px;height:24px;fill:currentColor}

/* Summary */
.book-summary{padding:30px;border:1px solid var(--line-strong);border-radius:var(--r-box);background:var(--bg-soft)}
.book-summary h2{margin-bottom:18px;font-size:26px;letter-spacing:-.035em}
.sum-list>div,.sum-money>div{display:flex;justify-content:space-between;gap:20px;padding-block:12px;border-top:1px solid var(--line-strong)}
.sum-list dt,.sum-money dt{flex:none;font-size:14px;color:var(--muted)}
.sum-list dd,.sum-money dd{margin:0;font-size:15px;font-weight:650;line-height:1.5;text-align:right;color:var(--heading);font-variant-numeric:tabular-nums}
.sum-money{margin-top:6px}
.sum-money .due dt{font-weight:700;color:var(--heading)}
.sum-money .due dd{font-size:24px;letter-spacing:-.03em}
.sum-funded{margin:14px 0 0;padding-top:14px;border-top:1px solid var(--line-strong);font-size:15px;color:var(--heading)}
.sum-funded[hidden],.sum-money[hidden]{display:none}
.policy{margin:18px 0 0;padding-top:16px;border-top:1px solid var(--line-strong);font-size:13px;line-height:1.6;color:var(--muted)}
.policy strong{color:var(--heading)}
.secure{margin-top:22px;padding-top:20px;border-top:1px solid var(--line-strong)}
.secure-title{display:flex;align-items:center;gap:10px;max-width:none;margin:0 0 14px;font-size:14px;font-weight:700;color:var(--heading)}
.secure-title .ico{width:20px;height:20px;color:var(--accent-text)}
.pay-logos{display:flex;flex-wrap:wrap;gap:8px;margin:0 0 14px;padding:0;list-style:none}
.pay-logos li{display:grid;place-items:center;width:52px;height:34px;border:1px solid var(--line-strong);border-radius:var(--r-ctl);background:var(--bg);color:var(--ink)}
.pay-logos .brand-mark{width:34px;height:22px}
.powered{display:flex;align-items:center;gap:10px;max-width:none;margin:0;font-size:13px;color:var(--muted)}
.powered .brand-mark{width:20px;height:20px;color:var(--heading)}
.powered strong{color:var(--heading)}

/* Confirmation */
.confirm-mark{display:grid;place-items:center;width:52px;height:52px;margin-bottom:22px;border-radius:var(--r-ctl);background:var(--action);color:#fff}
.confirm-mark .ico{width:28px;height:28px}
.confirm h2{margin-bottom:28px;font-size:clamp(30px,3.4vw,44px)}
.conf-details{max-width:560px;margin:0 0 40px}
.conf-details>div{display:flex;gap:24px;padding-block:14px;border-top:1px solid var(--line-strong)}
.conf-details>div:last-child{border-bottom:1px solid var(--line-strong)}
.conf-details dt{flex:0 0 96px;font-size:14px;color:var(--muted)}
.conf-details dd{margin:0;font-weight:650;color:var(--heading)}
.confirm h3{margin-bottom:22px}
.confirm .steps{max-width:560px}

/* About this mockup */
.mock-notes{background:var(--bg-soft);border-top:1px solid var(--line)}
.mock-notes h2{margin-bottom:32px;font-size:clamp(28px,3vw,38px)}
.notes-list{max-width:860px;margin:0}
.notes-list>div{display:grid;grid-template-columns:200px minmax(0,1fr);gap:8px 32px;padding-block:18px;border-top:1px solid var(--line-strong)}
.notes-list>div:last-child{border-bottom:1px solid var(--line-strong)}
.notes-list dt{font-weight:700;color:var(--heading)}
.notes-list dd{margin:0;color:var(--muted)}

@media(min-width:1021px) and (min-height:780px){.book-summary{position:sticky;top:100px}}
@media(max-width:1020px){
  .book-layout{grid-template-columns:minmax(0,1fr)}
}
@media(max-width:767px){
  footer{padding-bottom:56px}
  #a11y-toggle{bottom:20px!important}
  #a11y-panel{bottom:88px!important;max-height:min(80dvh,calc(100dvh - 110px))!important}
  .choice-grid{grid-template-columns:1fr}
  .stepper{margin-bottom:32px}
  .stepper{justify-content:space-between;gap:10px}
  .stepper li:not(:last-child){flex:0 0 auto}
  .stepper li:not(:last-child):after{display:none}
  .stepper .label{display:none}
  .stepper li[aria-current="step"] .label{display:inline;white-space:nowrap}
  .fields,.pay-fields{grid-template-columns:1fr}
  .pay-box{padding:22px 18px}
  .book-summary{padding:24px 20px}
  .notes-list>div{grid-template-columns:1fr}
  .choice{padding:14px}
  .choice-clinic img{width:60px;height:60px}
}
@media(max-width:480px){
  .mock-banner{text-align:left}
  .due-list{gap:0 20px}
  .due-list dd{font-size:24px}
  .day-grid{grid-template-columns:repeat(4,minmax(0,1fr))}
  .slot-grid{grid-template-columns:repeat(3,minmax(0,1fr))}
  .step-actions .btn{width:100%}
}
@media(prefers-color-scheme:dark){
  .choice-clinic img{filter:brightness(.94)}
}
@media(prefers-reduced-motion:reduce){
  .wallet:active{transform:none}
}
