/* Costco Small Group quote funnel — remake (T1 exemplar).
   Reuses the BLESSED Large Group design system 1:1 (palette + Costco Sans Micro + WCAG defaults),
   EXTENDED for the 3-step funnel: stepper, <select> styling, conditional reveal, review screen,
   and the regulated dialogs as accessible in-page notices.
   Real Costco palette (verified vs live theme.css) + Costco Sans Micro (self-hosted from the clone).
   Mobile-first, WCAG 2.2 AA defaults. No third-party, no pixels (SECURE-MULTISTEP-LEAD-FORM).

   HYBRID look (Joseph 2026-06-17): marketing/landing CHROME (the .intro brand header + the .footband
   footer) = real liquid-glass + .rise reveal over a Costco-brand backdrop, anchored to the B6 sibling.
   FORM-STEP panels (fieldset.step + their inputs) = CLEAN, solid high-contrast card, NO glass behind
   the fields, no reveal motion on the active step. Content stays byte-exact (G-PARITY CSS-only). */

@font-face{font-family:"Costco Sans Micro";src:url("assets/CostcoSansMicro-Regular.woff2") format("woff2");font-weight:400;font-display:swap}
@font-face{font-family:"Costco Sans Micro";src:url("assets/CostcoSansMicro-Medium.woff2") format("woff2");font-weight:500;font-display:swap}
@font-face{font-family:"Costco Sans Micro";src:url("assets/CostcoSansMicro-Semibold.woff2") format("woff2");font-weight:600;font-display:swap}
@font-face{font-family:"Costco Sans Micro";src:url("assets/CostcoSansMicro-Black.woff2") format("woff2");font-weight:800;font-display:swap}

:root{
  --blue:#005DAB; --blue-dark:#004a8a;        /* Costco primary (Continue) */
  --red:#E31936; --red-dark:#c2142e;          /* .greenButton CTA + accent (NOT Costco master #C8102E) */
  --focus:#DE2127;                            /* input focus ring (theme.css:1701) */
  --ink:#1f2733; --body:#444; --muted:#6a717b;
  --line:#d9dee4; --soft:#f4f7fa; --bg:#fff;
  --font:"Costco Sans Micro",-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,Helvetica,Arial,sans-serif;
  --maxw:660px; --radius:14px;                /* ONE card-radius family (C6): card/glass/gate surfaces */
  --btn-radius:10px;                          /* ONE control radius (C6): buttons + inputs + small panels */
  --shadow:0 6px 28px rgba(15,30,50,.10),0 1px 2px rgba(15,30,50,.06);   /* ONE shadow recipe (C6) */
}
*{box-sizing:border-box}
html{ -webkit-text-size-adjust:100%; }
/* Costco-brand backdrop: a LIGHT field (keeps glass text >=4.5:1) with soft blue + faint red radials
   so the glass actually has something to blur. CSS gradient only (no url() = no LAW-2 invented image). */
body{margin:0;color:var(--body);font-family:var(--font);font-size:16px;line-height:1.5;
  background:
    radial-gradient(1100px 560px at 12% -8%, rgba(0,93,171,.12), transparent 60%),
    radial-gradient(900px 520px at 112% 6%, rgba(227,25,54,.07), transparent 55%),
    linear-gradient(180deg,#eef3f8 0%,#f4f7fa 42%,#eaeff5 100%);
  background-attachment:fixed;
  display:flex;flex-direction:column;align-items:center;justify-content:flex-start;
  gap:6px;padding:26px 16px;min-height:100vh}
img{max-width:100%;height:auto;display:block}

/* ---- the three stacked bands share ONE centered column width (C1/C2) ---- */
.intro,.card,.footband{width:100%;max-width:var(--maxw)}
.wrap{width:100%}

/* ---- marketing chrome bands: vertical padding leaves gradient margin around the glass (C7 rhythm) ---- */
.intro{padding:26px 0}
.footband{padding:26px 0}
.intro .wrap.glass{padding:16px 22px}
.footband .wrap.glass{padding:18px 22px;text-align:center}
@media(max-width:480px){ .intro,.footband{padding:18px 0} .intro .wrap.glass,.footband .wrap.glass{padding:14px 16px} }

.card{background:var(--bg);border-radius:var(--radius);box-shadow:var(--shadow);overflow:hidden}
.card__bar{height:5px;background:var(--red)}
.card__pad{padding:28px}
@media(max-width:480px){ .card__pad{padding:20px 16px} }

.brand{display:flex;align-items:center;justify-content:space-between;gap:12px}
.brand__logos{display:inline-flex;align-items:center;gap:28px;min-width:0}
.brand .logo-cbc{height:96px;width:auto;display:block}
.brand .logo-costco{height:30px;width:auto;display:block}
.brand .logo-div{width:1px;height:64px;background:rgba(0,0,0,.18);flex:none}
@media(max-width:480px){ .brand__logos{gap:14px} .brand .logo-cbc{height:52px} .brand .logo-costco{height:16px} .brand .logo-div{height:34px} }
.brand__step{font-size:.82rem;font-weight:600;color:var(--muted);white-space:nowrap}

h1{font-weight:800;color:var(--ink);font-size:clamp(1.5rem,5vw,2rem);line-height:1.12;margin:.1em 0 .35em}
.lede{color:var(--body);font-size:1rem;margin:0 0 1.25rem}

/* progress */
.prog{display:flex;gap:8px;margin:0 0 20px}
.prog span{flex:1;height:6px;border-radius:999px;background:#e6ebf1}
.prog span.on{background:var(--blue)}

fieldset{border:0;margin:0;padding:0;min-width:0}
legend{padding:0;font-weight:600;color:var(--ink);font-size:1.05rem;margin-bottom:.75rem}
.grid{display:grid;grid-template-columns:1fr 1fr;gap:14px 16px}
.full{grid-column:1/-1}
@media(max-width:560px){ .grid{grid-template-columns:1fr} }

.field{display:flex;flex-direction:column;gap:6px;min-width:0}
.field label{font-weight:500;color:var(--ink);font-size:.92rem}
.req{color:var(--red);font-weight:700}
.field input,.field textarea{font-family:inherit;font-size:16px;color:var(--ink);background:#fff;
  border:1px solid var(--line);border-radius:var(--btn-radius);padding:12px 13px;width:100%;transition:border-color .12s,box-shadow .12s}
.field textarea{min-height:130px;resize:vertical}
.field input::placeholder,.field textarea::placeholder{color:#9aa3ad}
.field input:focus,.field textarea:focus{outline:none;border-color:var(--focus);box-shadow:0 0 0 3px rgba(222,33,39,.18)}
.field input[aria-invalid="true"],.field textarea[aria-invalid="true"]{border-color:var(--red);background:#fff7f8}

/* summary of step 1 shown on step 2 */
.who{display:flex;justify-content:space-between;align-items:center;gap:10px;background:var(--soft);
  border:1px solid var(--line);border-radius:var(--btn-radius);padding:10px 13px;margin-bottom:18px;font-size:.9rem}
.who b{color:var(--ink)} .who a{color:var(--blue);font-weight:600;text-decoration:none}
.who a:hover{text-decoration:underline}

/* error summary */
.errs{display:none;border:1px solid var(--red);background:#fff5f6;border-radius:var(--btn-radius);padding:12px 14px;margin-bottom:18px}
.errs.show{display:block} .errs h2{margin:0 0 6px;color:var(--red-dark)}
.errs ul{margin:0;padding-left:18px} .errs a{color:var(--red-dark)}

.actions{display:flex;gap:12px;align-items:center;margin-top:24px;flex-wrap:wrap}
.btn{font-family:inherit;font-weight:700;font-size:1.02rem;border:0;border-radius:var(--btn-radius);padding:14px 22px;
  cursor:pointer;min-height:50px;display:inline-flex;align-items:center;gap:9px;justify-content:center}
.btn--primary{background:var(--blue);color:#fff} .btn--primary:hover{background:var(--blue-dark)}
.btn--send{background:var(--red);color:#fff} .btn--send:hover{background:var(--red-dark)}
.btn:focus-visible{outline:3px solid var(--focus);outline-offset:2px}
.btn--back{background:none;color:var(--muted);font-weight:600;padding:14px 6px;min-height:50px}
.btn--back:hover{color:var(--ink)}
@media(max-width:480px){ .actions{flex-direction:column-reverse;align-items:stretch} .btn{width:100%} }

/* footer line (lives in the .footband glass chrome; darker ink for contrast on the glass) */
.foot{margin:0;color:var(--body);font-size:.8rem;text-align:center}

.step[hidden]{display:none}

/* ===== SG EXTENSIONS (new parts; LG system above is untouched) ===== */

/* <select> — match the input look exactly + a native caret, 16px (no iOS zoom), >=44px target */
.field select{font-family:inherit;font-size:16px;color:var(--ink);background:#fff;
  border:1px solid var(--line);border-radius:var(--btn-radius);padding:12px 38px 12px 13px;width:100%;
  min-height:48px;appearance:none;-webkit-appearance:none;cursor:pointer;
  transition:border-color .12s,box-shadow .12s;
  background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%236a717b' d='M1 1l5 5 5-5'/%3E%3C/svg%3E");
  background-repeat:no-repeat;background-position:right 14px center}
.field select:focus{outline:none;border-color:var(--focus);box-shadow:0 0 0 3px rgba(222,33,39,.18)}
.field select[aria-invalid="true"]{border-color:var(--red);background-color:#fff7f8}
.field select:invalid{color:#9aa3ad}            /* placeholder option dims like ::placeholder */
.field .hint{color:var(--muted);font-size:.82rem;margin:0}

/* conditional-reveal wrapper (B1 Website URL) — animates in, removed from a11y tree when hidden */
.reveal{overflow:hidden}
.reveal[hidden]{display:none}

/* the per-page regulated note (Subsidy note, membership tooltip) — calm, in-flow, not a popup */
.note{background:var(--soft);border:1px solid var(--line);border-left:4px solid var(--blue);
  border-radius:var(--btn-radius);padding:10px 13px;color:var(--body);font-size:.82rem;margin:4px 0 0}
.note b{color:var(--ink)}

/* ===== Review / check-answers screen (Step 3) ===== */
.review{margin:0 0 8px}
.review__grp{border:1px solid var(--line);border-radius:var(--btn-radius);padding:14px 16px;margin-bottom:14px}
.review__head{display:flex;justify-content:space-between;align-items:baseline;gap:10px;margin-bottom:8px}
.review__head h2{color:var(--ink);margin:0}
.review__head a{color:var(--blue);font-weight:600;text-decoration:none;font-size:.9rem}
.review__head a:hover{text-decoration:underline}
.review dl{display:grid;grid-template-columns:minmax(40%,auto) 1fr;gap:6px 14px;margin:0}
.review dt{color:var(--muted);font-size:.88rem}
.review dd{color:var(--ink);font-size:.92rem;margin:0;word-break:break-word}
@media(max-width:480px){ .review dl{grid-template-columns:1fr} .review dt{margin-top:4px} }

/* ===== Regulated dialogs rendered as accessible in-page notices (not colorbox iframes) ===== */
.gate{display:none;border-radius:var(--radius);padding:18px 18px 20px;margin:18px 0 0;border:1px solid var(--line);
  background:#fff;box-shadow:var(--shadow)}
.gate.show{display:block}
.gate--warn{border-color:var(--red);background:#fff5f6}
.gate h2{margin:0 0 8px;color:var(--ink);display:flex;align-items:center;gap:8px}
.gate--warn h2{color:var(--red-dark)}
.gate .gate__warnicon{font-size:1.15rem}
.gate p{margin:0 0 10px;font-size:1rem}
.gate p:last-of-type{margin-bottom:14px}
.gate .gate__actions{display:flex;gap:10px;flex-wrap:wrap}
.gate .btn--ghost{background:#fff;color:var(--blue);border:1px solid var(--blue)}
.gate .btn--ghost:hover{background:var(--soft)}
@media(max-width:480px){ .gate .gate__actions{flex-direction:column} .gate .btn{width:100%} }

/* ONE H2 type scale across the page (C3): error / review / gate sub-heads all match */
.errs h2,.review__head h2,.gate h2{font-size:1.05rem;font-weight:700;line-height:1.2}

/* consent checkbox row (TCPA) — large target, label clickable */
.consent{display:flex;gap:10px;align-items:flex-start;background:var(--soft);border:1px solid var(--line);
  border-radius:var(--btn-radius);padding:12px 13px;margin-top:6px}
.consent input[type="checkbox"]{width:24px;height:24px;min-width:24px;margin-top:0;accent-color:var(--blue);cursor:pointer}
.consent label{font-weight:400;color:var(--body);font-size:.82rem;line-height:1.45;cursor:pointer}
/* Phone tap target: WCAG 2.5.5 / mobile — the consent checkbox gets a >=44px hit area. */
@media (max-width:480px){
  .consent input[type="checkbox"]{width:44px;height:44px;min-width:44px}
}

/* thank-you */
.done{text-align:center;padding:18px 4px}
.done__mark{width:64px;height:64px;border-radius:50%;background:rgba(0,93,171,.10);color:var(--blue);
  display:grid;place-items:center;margin:0 auto 16px;font-size:30px;font-weight:800}
.done h1{margin-bottom:.4em}
.done p{font-size:1rem;max-width:42ch;margin:0 auto}

/* ========================================================================
   LOOK-LAYER (T1 Costco): liquid-glass marketing chrome + entrance-reveal.
   Recipe anchored to the blessed B6 Costco sibling (real backdrop-filter + a
   painted ::before sheen, NOT the rejected rgba(255,255,255,.07) frosting).
   Glass sits on the LIGHT brand backdrop, so dark ink stays >=4.5:1.
   ======================================================================== */

/* ---- liquid glass (real backdrop-filter + ::before sheen) ---- */
.glass{
  background: rgba(255,255,255,.58);
  -webkit-backdrop-filter: blur(18px) saturate(1.5);
  backdrop-filter: blur(18px) saturate(1.5);
  border: 1px solid rgba(255,255,255,.75);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  position: relative;
}
.glass::before{                 /* top-edge sheen — REQUIRED, this is what reads as glass */
  content:""; position:absolute; inset:0 0 auto 0; height:40%;
  border-radius: var(--radius) var(--radius) 0 0;
  background: linear-gradient(180deg, rgba(255,255,255,.5), rgba(255,255,255,0));
  pointer-events:none;
}
.glass > *{ position:relative; z-index:1 }      /* content paints above the sheen, full contrast */
@media (prefers-reduced-motion: reduce){        /* non-Chromium / reduced-motion fallback, never below the contrast gate */
  .glass{ -webkit-backdrop-filter: blur(4px) saturate(1.12) brightness(1.03); backdrop-filter: blur(4px) saturate(1.12) brightness(1.03); }
}

/* ---- entrance-reveal (.rise) — capture-safe, ported 1:1 from the blessed B6/B1 sibling (C9).
   opacity stays 1 at ALL times; only transform animates, so a full-page capture paints fully with
   NO scroll trigger and a no-JS / un-observed element is never blank. Applied to the CHROME bands
   only (.intro/.footband) — the active form step has NO reveal motion (HYBRID). ---- */
@keyframes rise { from { transform:translateY(16px) } to { transform:translateY(0) } }
.rise{ opacity:1 }                              /* no-JS / pre-JS default = visible (HARD) */
.js .rise{ opacity:1; transform:translateY(16px) }
.js .rise.is-in{ transform:translateY(0); animation: rise .9s cubic-bezier(.2,.7,.2,1) forwards }
.no-js .rise{ opacity:1 !important; animation:none !important; transform:none !important }
@media (prefers-reduced-motion: reduce){
  .rise, .js .rise, .js .rise.is-in{ opacity:1 !important; animation:none !important; transform:none !important }
}

/* ===== C4 INDIVIDUAL FUNNEL EXTENSIONS (QLE wall paragraph + inline subsidy row) ===== */

/* QLE wall regulated paragraph — calm in-flow lede above the LifeEvent select (not a popup) */
.qle-lede{background:var(--soft);border:1px solid var(--line);border-left:4px solid var(--blue);
  border-radius:var(--btn-radius);padding:12px 14px;color:var(--ink);font-size:.92rem;line-height:1.5;margin:0 0 14px}

/* inline subsidy household/income row — "There are [N] people ... & my family makes [$] per year." */
.subsidy-row{display:flex;flex-wrap:wrap;align-items:center;gap:8px 10px;font-size:.95rem;color:var(--ink)}
.subsidy-row .field{flex:0 0 auto}
.subsidy-row select{min-width:4em;width:auto}
.subsidy-row input{width:9em}
@media(max-width:480px){ .subsidy-row{align-items:stretch;flex-direction:column} .subsidy-row .field{width:100%} .subsidy-row input{width:100%} }

/* third-party disclaimer in the header chrome — regulated text byte-exact; sized >=12px with >=24px tap links (G-A11Y) */
.thirdparty{margin:0 0 10px;color:var(--body);font-size:.8rem;line-height:1.5}
.thirdparty a{color:var(--blue);text-decoration:underline;display:inline-block;padding:5px 2px;line-height:1.5}

/* inline links inside in-flow notes (topDisclaimer2, etc.) get a >=24px tap height (G-A11Y AA floor) */
.note a{color:var(--blue);text-decoration:underline;display:inline-block;padding:5px 2px;line-height:1.5}

/* skip-to-content link — clipped (NOT off-canvas at -9999) until focused (WCAG 2.4.1); stays in-canvas so the
   overflow gate does not read it as clipped content. Becomes a normal button on focus. */
.skipLink{position:absolute;left:8px;top:8px;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0);
  clip-path:inset(50%);white-space:nowrap;background:var(--blue);color:#fff;padding:0;
  border-radius:var(--btn-radius);z-index:1000;font-weight:600;text-decoration:none}
.skipLink:focus{width:auto;height:auto;overflow:visible;clip:auto;clip-path:none;padding:10px 16px}
/* thank-you heading keeps the h1 visual scale though it is an h2 (single-h1 contract) */
.done .done__h{font-weight:800;color:var(--ink);font-size:clamp(1.5rem,5vw,2rem);line-height:1.12;margin-bottom:.4em}

/* COHERENCE C5: global anchor color so no link falls back to UA default #0000EE (gate healthcare.gov link, etc.) */
a{color:var(--blue)}
/* COHERENCE C3: thank-you headline uses the ONE canonical H2 scale (matches error/review/gate H2) */
.done .done__h{font-size:1.05rem;font-weight:700;line-height:1.2;color:var(--ink)}

/* COHERENCE C3 (body sizes <=2): collapse the smallest text tier (~13px notes/disclaimer/step) up to the
   label tier (.92rem ~15px), so the page carries TWO body sizes {15,16}, not three. Regulated text unchanged. */
.note,.thirdparty,.subsidy-note,.brand__step,.foot,.qle-lede,.who,.review dt,.review dd,.consent label{font-size:.92rem}

/* NO-JS FALLBACK: app.js adds .js to <html>. Without JS the step fieldsets + conditional reveals stay
   [hidden] and their content (QLE paragraph, membership tooltip, subsidy note, step legends) would be
   display:none — failing the no-JS parity rule. When JS has NOT run, reveal every step + every conditional
   block so ALL content is present and the form is fully usable as one long page (graceful degradation). */
html:not(.js) .step[hidden],
html:not(.js) .reveal[hidden],
html:not(.js) #County_div[hidden],
html:not(.js) #subsidyDetail[hidden]{display:block !important}
html:not(.js) .gate[hidden]{display:none}   /* dialogs stay hidden (they are JS-triggered alerts, not content) */
