/* SCN Loop by MedRite — showcase page */
:root {
  /* MedRite Community Care brand (sampled from the logo) */
  --navy: #2D2E6E;
  --navy-deep: #222355;
  --navy-night: #191A40;
  --teal: #63C2B6;
  --teal-dark: #2C6E62;
  --teal-tint: #E4F4F1;
  --paper: #F1F3F7;
  --white: #FFFFFF;
  --ink: #1E2433;
  --moss: #5F6879;
  --line: #E0E4EC;
  --amber: #9C5409;
  --amber-bg: #F7EEDD;
  --brick: #AE3A2C;
  --brick-bg: #F9ECEA;
  --radius: 12px;
  --radius-lg: 20px;
  --shadow: 0 1px 2px rgba(30,36,51,.05), 0 8px 24px -8px rgba(30,36,51,.12);
  --shadow-lg: 0 2px 4px rgba(30,36,51,.06), 0 24px 60px -20px rgba(34,35,85,.35);
  --font-head: "Montserrat", "Segoe UI", system-ui, sans-serif;
  --font-body: "Atkinson Hyperlegible", "Segoe UI", system-ui, -apple-system, sans-serif;
  --ease: cubic-bezier(.2,.8,.2,1);
  --header-h: 68px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 12px); -webkit-text-size-adjust: 100%; }
body {
  margin: 0; font-family: var(--font-body); font-size: 18px; line-height: 1.55;
  color: var(--ink); background: var(--paper); -webkit-font-smoothing: antialiased;
}
img, svg { display: block; max-width: 100%; }
h1, h2, h3, h4 { font-family: var(--font-head); line-height: 1.12; margin: 0 0 .5em; letter-spacing: -.015em; }
p { margin: 0 0 1em; }
a { color: var(--navy); }
button, input, select, textarea { font: inherit; color: inherit; }
:focus-visible { outline: 3px solid #2F7BE8; outline-offset: 3px; border-radius: 6px; }
.sr-only { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.skip { position: absolute; left: 12px; top: -60px; z-index: 100; background: var(--ink); color: #fff; padding: 10px 16px; border-radius: 8px; }
.skip:focus { top: 12px; }
.wrap { width: min(1200px, 100% - 40px); margin-inline: auto; }
.wrap.narrow { width: min(860px, 100% - 40px); }
.ic { width: 1.15em; height: 1.15em; flex: none; }
svg.ic { display: inline-block; vertical-align: -.2em; }
[data-icon] { display: inline-flex; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .55em;
  min-height: 48px; padding: .7em 1.3em; border-radius: 999px; border: 2px solid transparent;
  font-weight: 700; font-size: 1rem; text-decoration: none; cursor: pointer;
  transition: transform .15s var(--ease), background .2s, box-shadow .2s, color .2s, border-color .2s;
}
.btn:active { transform: translateY(1px) scale(.99); }
.btn-sm { min-height: 44px; padding: .45em 1em; font-size: .95rem; }
.btn-lg { min-height: 58px; padding: .8em 1.6em; font-size: 1.08rem; }
.btn-block { width: 100%; }
.btn-primary { background: var(--navy); color: #fff; box-shadow: 0 6px 16px -6px rgba(45,46,110,.55); }
.btn-primary:hover { background: var(--navy-deep); }
.btn-primary[disabled] { background: #A9AAC6; box-shadow: none; cursor: not-allowed; }
.btn-light { background: #fff; color: var(--navy-deep); box-shadow: 0 10px 30px -10px rgba(0,0,0,.45); }
.btn-light:hover { background: var(--teal-tint); transform: translateY(-1px); }
.btn-ghost-light { background: rgba(255,255,255,.06); color: #fff; border-color: rgba(255,255,255,.45); }
.btn-ghost-light:hover { background: rgba(255,255,255,.14); border-color: #fff; }
.btn-outline { background: #fff; color: var(--navy-deep); border-color: var(--line); }
.btn-outline:hover { border-color: var(--navy); background: var(--teal-tint); }
.btn-text { background: none; border: 0; color: var(--moss); text-decoration: underline; text-underline-offset: 3px; padding: .5em .8em; min-height: 44px; cursor: pointer; font-weight: 400; }
.btn-text:hover { color: var(--ink); }
.btn-icon { width: 36px; height: 36px; border-radius: 50%; border: 1px solid var(--line); background: #fff; display: grid; place-items: center; cursor: pointer; }

.pause-glyph { display: inline-block; width: 10px; height: 12px; border-left: 3px solid currentColor; border-right: 3px solid currentColor; }
.is-paused .pause-glyph { width: 0; height: 0; border-style: solid; border-width: 6px 0 6px 10px; border-color: transparent transparent transparent currentColor; border-right: 0; }

/* ---------- Demo strip & header ---------- */
.demo-strip {
  display: flex; gap: .6em; align-items: center; justify-content: center; text-align: center;
  background: var(--amber-bg); color: var(--amber); font-size: .88rem; padding: 7px 16px;
}
.demo-strip .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--amber); flex: none; animation: pulse 2s infinite; }
.site-header {
  position: sticky; top: 0; z-index: 50; height: var(--header-h);
  background: rgba(255,255,255,.88); backdrop-filter: saturate(1.4) blur(12px); -webkit-backdrop-filter: saturate(1.4) blur(12px);
  border-bottom: 1px solid var(--line);
}
.header-inner { display: flex; align-items: center; gap: 24px; height: 100%; }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: var(--ink); }
.brand-mark { width: 38px; height: 38px; border-radius: 10px; background: var(--navy); color: #fff; display: grid; place-items: center; }
.brand-mark svg { width: 30px; height: 30px; }
.brand-dot { fill: var(--teal); }
.brand-text { display: flex; flex-direction: column; line-height: 1.05; }
.brand-text strong { font-family: var(--font-head); font-size: 1.2rem; letter-spacing: -.02em; }
.brand-text small { font-size: .78rem; color: var(--moss); font-weight: 700; letter-spacing: .08em; text-transform: uppercase; }
.main-nav { display: flex; gap: 4px; margin-left: auto; }
.main-nav a { color: var(--ink); text-decoration: none; font-weight: 700; font-size: .95rem; padding: 10px 12px; border-radius: 8px; }
.main-nav a:hover { background: var(--paper); }
@media (max-width: 900px) { .main-nav { display: none; } .header-cta { margin-left: auto; } }

/* ---------- Hero ---------- */
.hero {
  position: relative; overflow: hidden; color: #fff;
  background: radial-gradient(1200px 600px at 85% 20%, #3A3C86 0%, transparent 60%), linear-gradient(160deg, var(--navy-deep) 0%, var(--navy-night) 100%);
}
.hero-grid { position: relative; display: grid; grid-template-columns: 1.05fr 1fr; gap: 48px; align-items: center; padding: 72px 0 56px; }
.eyebrow { font-family: var(--font-head); font-weight: 700; font-size: .82rem; letter-spacing: .16em; text-transform: uppercase; color: var(--teal-dark); margin-bottom: .9em; }
.eyebrow-light { color: var(--teal); }
.hero h1 { font-size: clamp(2.5rem, 5.4vw, 4.4rem); font-weight: 800; letter-spacing: -.03em; margin-bottom: .4em; }
.hl { color: var(--teal); }
.lede { font-size: clamp(1.08rem, 1.5vw, 1.25rem); color: rgba(255,255,255,.86); max-width: 36em; }
.hero-ctas { display: flex; flex-wrap: wrap; gap: 14px; margin: 28px 0 24px; }
.hero-ctas.center { justify-content: center; }
.hero-points { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 10px 22px; color: rgba(255,255,255,.85); font-size: .98rem; }
.hero-points li { display: inline-flex; align-items: center; gap: 8px; }
.hero-points .ic { color: var(--teal); }

@media (max-width: 960px) {
  .hero-grid { grid-template-columns: 1fr; padding-top: 44px; gap: 8px; }
  .hero-art { max-width: 420px; margin: 0 auto; }
}

/* ---------- Sections ---------- */
.section { padding: 96px 0; }
.section-white { background: #fff; }
.section-tint { background: linear-gradient(180deg, var(--teal-tint), var(--paper)); }
.section-head { max-width: 760px; margin-bottom: 44px; }
.section-head.center { text-align: center; margin-inline: auto; }
.section-head h2 { font-size: clamp(2rem, 3.6vw, 2.9rem); font-weight: 800; }
.section-lede { font-size: 1.12rem; color: var(--moss); }
.section-lede strong { color: var(--ink); }
body.staff .staff-only { display: inline; color: var(--amber); }

/* ---------- Screening ---------- */
.screen-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius-lg); box-shadow: var(--shadow-lg); padding: clamp(22px, 4vw, 44px); min-height: 420px; position: relative; }
.sc-view { animation: fadeUp .4s var(--ease); }
.sc-view.back { animation: fadeDown .4s var(--ease); }
.sc-intro { text-align: center; }
.sc-intro .big-ic { width: 76px; height: 76px; border-radius: 22px; background: var(--teal-tint); color: var(--navy); display: grid; place-items: center; margin: 0 auto 18px; }
.sc-intro .big-ic .ic { width: 38px; height: 38px; }
.sc-intro h3 { font-size: clamp(1.6rem, 3vw, 2.1rem); }
.sc-intro p { color: var(--moss); max-width: 34em; margin-inline: auto; }
.domain-strip { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin: 22px 0 26px; padding: 0; list-style: none; }
.domain-strip li { display: inline-flex; gap: 6px; align-items: center; padding: 6px 12px; border-radius: 99px; background: var(--paper); font-size: .88rem; font-weight: 700; color: var(--moss); }
.domain-strip .ic { color: var(--navy); }
.sc-actions { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; align-items: center; }

.progress { margin-bottom: 26px; }
.progress-top { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 10px; }
.progress-label { font-weight: 700; font-size: .95rem; color: var(--moss); }
.domain-chip { display: inline-flex; gap: 7px; align-items: center; font-weight: 700; font-size: .88rem; padding: 5px 12px; border-radius: 99px; background: var(--teal-tint); color: var(--navy); }
.progress-track { height: 8px; background: var(--paper); border-radius: 99px; overflow: hidden; }
.progress-fill { height: 100%; background: linear-gradient(90deg, var(--navy), #4C4E9A); border-radius: 99px; transition: width .5s var(--ease); }
.q-legend { font-family: var(--font-head); font-size: clamp(1.35rem, 2.6vw, 1.75rem); font-weight: 700; line-height: 1.25; margin-bottom: .4em; padding: 0; outline: none; }
.q-hint { color: var(--moss); margin-bottom: 1em; }
fieldset { border: 0; margin: 0; padding: 0; min-width: 0; }
.choices { display: grid; gap: 10px; margin: 18px 0 26px; }
.choices.cols-2 { grid-template-columns: 1fr 1fr; }
.choice { position: relative; display: flex; align-items: center; gap: 14px; min-height: 60px; padding: 14px 18px; border: 2px solid var(--line); border-radius: var(--radius); background: #fff; cursor: pointer; font-size: 1.05rem; line-height: 1.35; transition: border-color .15s, background .15s, transform .12s; }
.choice:hover { border-color: #B3B5CF; }
.choice:active { transform: scale(.995); }
.choice input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.choice .mark { flex: none; width: 26px; height: 26px; border-radius: 50%; border: 2px solid #AEB6C4; display: grid; place-items: center; transition: all .15s; background: #fff; }
.choice.multi .mark { border-radius: 7px; }
.choice .mark .ic { width: 16px; height: 16px; color: #fff; opacity: 0; transform: scale(.4); transition: all .2s var(--ease); }
.choice:has(input:checked), .choice.checked { border-color: var(--navy); background: var(--teal-tint); }
.choice:has(input:checked) .mark, .choice.checked .mark { background: var(--navy); border-color: var(--navy); }
.choice:has(input:checked) .mark .ic, .choice.checked .mark .ic { opacity: 1; transform: none; }
.choice:has(input:focus-visible) { outline: 3px solid #2F7BE8; outline-offset: 2px; }
.choice.admin { border-style: dashed; color: var(--moss); background: #FAFBFC; font-size: .95rem; min-height: 50px; }
.admin-label { font-size: .78rem; font-weight: 700; color: var(--amber); text-transform: uppercase; letter-spacing: .08em; margin: 6px 0 -2px; }
.q-nav { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; border-top: 1px solid var(--line); padding-top: 20px; }
.q-nav .grow { flex: 1; }
@media (max-width: 560px) { .choices.cols-2 { grid-template-columns: 1fr; } .q-nav .btn { flex: 1; } .q-nav .grow { display: none; } }

.extra-field { margin-bottom: 22px; }
.extra-field > p { font-weight: 700; margin-bottom: 8px; }
.extra-field .choices { margin: 0; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); }
.extra-field .choice { min-height: 50px; padding: 10px 14px; font-size: 1rem; }

.result-head { text-align: center; margin-bottom: 22px; }
.result-badge { width: 84px; height: 84px; border-radius: 50%; margin: 0 auto 14px; background: var(--navy); color: #fff; display: grid; place-items: center; box-shadow: 0 0 0 10px var(--teal-tint); animation: pop .6s var(--ease); }
.result-badge .ic { width: 42px; height: 42px; }
.result-head h3 { font-size: clamp(1.6rem, 3vw, 2.1rem); }
.need-chips { list-style: none; padding: 0; margin: 0 0 26px; display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; }
.need-chips li { display: inline-flex; align-items: center; gap: 8px; padding: 10px 16px; border-radius: 99px; background: var(--teal-tint); color: var(--navy-deep); font-weight: 700; animation: pop .5s var(--ease) both; }
.need-chips .ic { width: 20px; height: 20px; color: var(--navy); }
.support-box { background: #F4F1FA; border: 1px solid #DCD3EE; border-radius: var(--radius); padding: 18px 20px; margin-bottom: 22px; display: grid; grid-template-columns: 40px 1fr; gap: 14px; }
.support-box .ic { width: 28px; height: 28px; color: #5B3F99; }
.support-box p { margin: 0 0 .4em; }
.support-box a { color: #4A2F86; font-weight: 700; }
.staff-summary { font-size: .9rem; background: var(--amber-bg); color: #5C3A10; border-radius: 10px; padding: 12px 14px; margin-bottom: 20px; }
.staff-summary dl { display: grid; grid-template-columns: auto 1fr; gap: 2px 14px; margin: 6px 0 0; }
.staff-summary dt { font-weight: 700; }
.staff-summary dd { margin: 0; }

.send-card { border: 2px solid var(--navy); border-radius: var(--radius-lg); padding: clamp(18px, 3vw, 28px); margin: 6px 0 22px; background: #fff; outline: none; }
.send-card h4 { display: flex; align-items: center; gap: 10px; font-size: 1.3rem; margin-bottom: .3em; }
.send-card h4 .ic { color: var(--navy); width: 26px; height: 26px; }
.send-lede { color: var(--moss); margin-bottom: 18px; }
.send-card.sent { background: var(--teal-tint); border-color: transparent; text-align: center; }
.send-card.sent h4 { justify-content: center; }
.send-card.sent .send-lede { margin: 0; }
.hp { position: absolute !important; left: -10000px; width: 1px; height: 1px; overflow: hidden; }

/* ---------- Call back ---------- */
.callback-grid { display: grid; grid-template-columns: .85fr 1.15fr; gap: 56px; align-items: start; }
.callback-copy h2 { font-size: clamp(2rem, 3.6vw, 2.9rem); font-weight: 800; }
.check-list { list-style: none; padding: 0; margin: 24px 0 0; display: grid; gap: 14px; }
.check-list li { display: flex; gap: 12px; align-items: center; font-weight: 700; }
.check-list .ic { width: 40px; height: 40px; padding: 9px; border-radius: 12px; background: var(--teal-tint); color: var(--navy); }
.form-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius-lg); box-shadow: var(--shadow-lg); padding: clamp(20px, 3.5vw, 36px); }
.form-row.two { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.field { margin-bottom: 18px; }
.field.sub { margin: 12px 0 0; }
.field label, .field legend { display: block; font-weight: 700; margin-bottom: 6px; font-size: .98rem; }
.field input[type="text"], .field input[type="tel"], .field select {
  width: 100%; min-height: 50px; padding: 10px 14px; border: 2px solid var(--line); border-radius: 10px; background: #fff; transition: border-color .15s, box-shadow .15s;
}
.field input:focus, .field select:focus { outline: none; border-color: var(--navy); box-shadow: 0 0 0 4px rgba(45,46,110,.15); }
.field input[aria-invalid="true"], .field select[aria-invalid="true"] { border-color: var(--brick); background: var(--brick-bg); }
.field input.ok { border-color: #63C2B6; }
.hint { font-size: .84rem; color: var(--moss); margin: 5px 0 0; }
.err { font-size: .88rem; color: var(--brick); margin: 5px 0 0; font-weight: 700; }
.err:empty { display: none; }
.note { font-size: .88rem; color: var(--amber); background: var(--amber-bg); padding: 8px 10px; border-radius: 8px; margin: 8px 0 0; }
.note.good { color: var(--navy); background: var(--teal-tint); }
.seg { display: flex; flex-wrap: wrap; gap: 8px; }
.seg label { position: relative; flex: 1 1 auto; margin: 0; }
.seg input { position: absolute; opacity: 0; inset: 0; width: 100%; height: 100%; margin: 0; cursor: pointer; }
.seg span { display: flex; align-items: center; justify-content: center; min-height: 48px; padding: 8px 16px; border: 2px solid var(--line); border-radius: 10px; font-weight: 700; color: var(--moss); transition: all .15s; }
.seg input:checked + span { border-color: var(--navy); background: var(--teal-tint); color: var(--navy-deep); }
.seg input:focus-visible + span { outline: 3px solid #2F7BE8; outline-offset: 2px; }
.optional { border: 1px dashed var(--line); border-radius: 10px; padding: 4px 14px; margin-bottom: 18px; }
.optional summary { cursor: pointer; font-weight: 700; color: var(--navy); min-height: 44px; display: flex; align-items: center; }
.optional[open] { padding-bottom: 6px; }
.consent .check { display: flex; gap: 12px; align-items: flex-start; font-weight: 400; cursor: pointer; padding: 12px 14px; border: 2px solid var(--line); border-radius: 10px; }
.consent .check input { width: 24px; height: 24px; flex: none; margin: 1px 0 0; accent-color: var(--navy); }
.consent .check:has(input:checked) { border-color: var(--navy); background: var(--teal-tint); }
.form-foot { font-size: .84rem; color: var(--moss); text-align: center; margin: 12px 0 0; }
.thanks { text-align: center; padding: 20px 0; animation: fadeUp .5s var(--ease); outline: none; }
.thanks-badge { width: 84px; height: 84px; border-radius: 50%; background: var(--navy); color: #fff; display: grid; place-items: center; margin: 0 auto 16px; box-shadow: 0 0 0 10px var(--teal-tint); animation: pop .6s var(--ease); }
.thanks-badge .ic { width: 42px; height: 42px; }
.thanks h3 { font-size: 2rem; }
.thanks > p { color: var(--moss); font-size: 1.1rem; }
.next-steps { text-align: left; max-width: 400px; margin: 20px auto 26px; padding-left: 1.3em; display: grid; gap: 8px; }
@media (max-width: 900px) { .callback-grid { grid-template-columns: 1fr; gap: 28px; } }
@media (max-width: 520px) { .form-row.two { grid-template-columns: 1fr; gap: 0; } }

/* ---------- Closing & footer ---------- */
.closing { background: radial-gradient(900px 400px at 50% 0%, #3A3C86, transparent 70%), var(--navy-deep); color: #fff; padding: 88px 0; text-align: center; }
.closing h2 { font-size: clamp(2rem, 4.4vw, 3.4rem); font-weight: 800; }
.closing p { color: rgba(255,255,255,.82); font-size: 1.15rem; }
.closing-contact a { color: #fff; font-weight: 700; }
.site-footer { background: var(--navy-night); color: rgba(255,255,255,.75); padding: 56px 0 28px; font-size: .95rem; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 40px; }
.site-footer h3 { color: #fff; font-family: var(--font-body); font-size: .85rem; letter-spacing: .1em; text-transform: uppercase; }
.site-footer ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.site-footer a { color: rgba(255,255,255,.85); text-decoration: none; }
.site-footer a:hover { color: #fff; text-decoration: underline; }
.brand-footer { color: #fff; margin-bottom: 14px; }
.brand-footer .brand-text small { color: rgba(255,255,255,.6); }
.footer-about { max-width: 30em; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.1); margin-top: 36px; padding-top: 20px; font-size: .84rem; }
.footer-bottom p { margin: 0 0 6px; }
@media (max-width: 760px) { .footer-grid { grid-template-columns: 1fr; gap: 24px; } }

/* ---------- Booth controls, idle, toast ---------- */
.booth-btn { position: fixed; right: 16px; bottom: 16px; z-index: 60; width: 46px; height: 46px; border-radius: 50%; border: 1px solid var(--line); background: rgba(255,255,255,.9); color: var(--moss); display: grid; place-items: center; cursor: pointer; box-shadow: var(--shadow); opacity: .55; transition: opacity .2s; }
.booth-btn:hover, .booth-btn[aria-expanded="true"] { opacity: 1; }
.booth-btn .ic { width: 22px; height: 22px; }
.booth-panel { position: fixed; right: 16px; bottom: 72px; z-index: 60; width: 270px; background: #fff; border: 1px solid var(--line); border-radius: 14px; box-shadow: var(--shadow-lg); padding: 10px; animation: fadeUp .25s var(--ease); }
.booth-title { font-weight: 700; font-size: .8rem; letter-spacing: .1em; text-transform: uppercase; color: var(--moss); margin: 4px 8px 6px; }
.booth-row { display: flex; align-items: center; gap: 10px; width: 100%; min-height: 44px; padding: 8px 10px; border: 0; background: none; border-radius: 8px; cursor: pointer; text-align: left; font-weight: 700; font-size: .95rem; }
.booth-row:hover { background: var(--paper); }
.switch input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.sw { width: 38px; height: 22px; border-radius: 99px; background: #CBD2DD; position: relative; flex: none; transition: background .2s; }
.sw::after { content: ""; position: absolute; left: 3px; top: 3px; width: 16px; height: 16px; border-radius: 50%; background: #fff; transition: transform .2s var(--ease); }
.switch input:checked + .sw { background: var(--navy); }
.switch input:checked + .sw::after { transform: translateX(16px); }
.switch input:focus-visible + .sw { outline: 3px solid #2F7BE8; outline-offset: 2px; }
.booth-hint { font-size: .76rem; color: var(--moss); margin: 6px 8px 4px; }
kbd, code { font-size: .74rem; background: var(--paper); border: 1px solid var(--line); border-radius: 4px; padding: 0 4px; }

.idle { position: fixed; inset: 0; z-index: 90; background: rgba(25,26,64,.6); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); display: grid; place-items: center; padding: 20px; animation: fadeIn .3s; }
.idle[hidden] { display: none; }
.idle-card { background: #fff; border-radius: 24px; padding: 36px 32px; text-align: center; max-width: 420px; width: 100%; box-shadow: var(--shadow-lg); animation: pop .4s var(--ease); }
.idle-ring { position: relative; width: 96px; height: 96px; margin: 0 auto 14px; }
.idle-ring svg { width: 100%; height: 100%; transform: rotate(-90deg); }
.idle-ring circle { fill: none; stroke: var(--paper); stroke-width: 6; }
.idle-ring #idle-arc { stroke: var(--navy); stroke-linecap: round; stroke-dasharray: 213.6; transition: stroke-dashoffset 1s linear; }
.idle-ring span { position: absolute; inset: 0; display: grid; place-items: center; font-family: var(--font-head); font-size: 2rem; font-weight: 800; }
.idle-card h2 { font-size: 1.8rem; }
.idle-card p { color: var(--moss); }

.toast { position: fixed; left: 50%; bottom: 24px; transform: translate(-50%, 20px); z-index: 95; background: var(--ink); color: #fff; padding: 12px 20px; border-radius: 99px; font-weight: 700; opacity: 0; pointer-events: none; transition: all .3s var(--ease); }
.toast.show { opacity: 1; transform: translate(-50%, 0); }

/* ---------- Reveal & keyframes ---------- */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity .8s var(--ease), transform .8s var(--ease); transition-delay: var(--d, 0s); }
.reveal.in { opacity: 1; transform: none; }
.stagger > * { opacity: 0; transform: translateY(18px); transition: opacity .6s var(--ease), transform .6s var(--ease); }
.stagger.in > * { opacity: 1; transform: none; }

@keyframes fadeUp { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
@keyframes fadeDown { from { opacity: 0; transform: translateY(-14px); } to { opacity: 1; transform: none; } }
@keyframes fadeIn { from { opacity: 0; } }
@keyframes slideIn { from { opacity: 0; transform: translateX(-12px); } to { opacity: 1; transform: none; } }
@keyframes pop { 0% { opacity: 0; transform: scale(.6); } 70% { transform: scale(1.06); } 100% { opacity: 1; transform: none; } }
@keyframes grow { from { width: 0; } to { width: 100%; } }
@keyframes ripple { 0% { opacity: .9; transform: scale(1); } 100% { opacity: 0; transform: scale(1.7); } }
@keyframes pulse { 50% { opacity: .35; } }
@keyframes livePulse { 0% { box-shadow: 0 0 0 0 rgba(45,190,126,.6); } 70% { box-shadow: 0 0 0 8px rgba(45,190,126,0); } 100% { box-shadow: 0 0 0 0 rgba(45,190,126,0); } }
@keyframes flash { 0% { box-shadow: 0 0 0 0 rgba(45,46,110,.5); } 100% { box-shadow: 0 0 0 10px rgba(45,46,110,0); } }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
  .reveal, .stagger > * { opacity: 1; transform: none; }
}

/* Large landscape screens (booth TV): bump the base size */
@media (min-width: 1700px) and (min-height: 900px) { body { font-size: 20px; } .wrap { width: min(1440px, 100% - 80px); } }

/* =========================================================
   Member page (v2)
   ========================================================= */
.staff-only { display: none; }
.hero-grid { padding: 64px 0 72px; }
.hero h1 { font-size: clamp(2.3rem, 5vw, 4rem); }
.btn .pill { font-size: .78rem; font-weight: 700; padding: 2px 9px; border-radius: 99px; background: var(--teal-tint); color: var(--navy); }
.trust { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 10px 22px; color: rgba(255,255,255,.88); font-size: 1rem; }
.trust li { display: inline-flex; align-items: center; gap: 8px; }
.trust .ic { color: var(--teal); }
.hero-art .art { width: 100%; height: auto; }
.float-a, .float-b, .float-c, .float-s { animation: floaty 6s ease-in-out infinite; transform-box: fill-box; transform-origin: center; }
.float-b { animation-delay: -2s; animation-duration: 7s; }
.float-c { animation-delay: -4s; animation-duration: 8s; }
.float-s { animation: sunny 10s ease-in-out infinite; }
@keyframes floaty { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }
@keyframes sunny { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.06); } }

.big { font-size: 1.15rem; color: var(--ink); }
.what-grid { display: grid; grid-template-columns: 1.1fr .9fr; gap: 56px; align-items: center; }
.what-grid h2 { font-size: clamp(1.9rem, 3.4vw, 2.6rem); font-weight: 800; }
.diff-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; }
.diff-list li { display: grid; grid-template-columns: 56px 1fr; gap: 16px; align-items: start; background: var(--paper); border-radius: var(--radius-lg); padding: 20px; }
.diff-list .di { width: 56px; height: 56px; border-radius: 16px; background: var(--navy); color: #fff; display: grid; place-items: center; }
.diff-list .di .ic { width: 28px; height: 28px; }
.diff-list h3 { font-size: 1.2rem; margin-bottom: .2em; }
.diff-list p { margin: 0; color: var(--moss); }
@media (max-width: 900px) { .what-grid { grid-template-columns: 1fr; gap: 28px; } }

.help-grid { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(5, 1fr); gap: 16px; }
.help-card { background: #fff; border-radius: var(--radius-lg); border: 1px solid var(--line); padding: 26px 20px; transition: transform .3s var(--ease), box-shadow .3s; }
.help-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.help-card .hi { width: 64px; height: 64px; border-radius: 20px; display: grid; place-items: center; margin-bottom: 16px; }
.help-card .hi .ic { width: 32px; height: 32px; }
.help-card h3 { font-size: 1.2rem; }
.help-card p { color: var(--moss); margin: 0; font-size: 1rem; }
.c1 .hi { background: #FBE3DF; color: #B23E33; }
.c2 .hi { background: #FCEBD3; color: #9C5409; }
.c3 .hi { background: var(--teal-tint); color: var(--teal-dark); }
.c4 .hi { background: #E2ECFA; color: #2856A8; }
.c5 .hi { background: #EEE7F7; color: #5B3F99; }
.footnote { text-align: center; color: var(--moss); margin: 22px 0 0; font-size: .95rem; }
@media (max-width: 1080px) { .help-grid { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 680px) { .help-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 440px) { .help-grid { grid-template-columns: 1fr; } }

.steps { list-style: none; margin: 0 0 40px; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.steps li { position: relative; background: var(--paper); border-radius: var(--radius-lg); padding: 24px 22px; }
.steps li:not(:last-child)::after { content: ""; position: absolute; top: 46px; right: -20px; width: 20px; height: 2px; background: var(--navy); opacity: .35; }
.step-top { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; }
.step-n { width: 44px; height: 44px; border-radius: 50%; background: var(--navy); color: #fff; font-family: var(--font-head); font-weight: 800; font-size: 1.3rem; display: grid; place-items: center; }
.step-ic { color: var(--navy); }
.step-ic .ic { width: 28px; height: 28px; }
.steps h3 { font-size: 1.2rem; }
.steps p { margin: 0; color: var(--moss); }
@media (max-width: 900px) { .steps { grid-template-columns: 1fr 1fr; } .steps li::after { display: none; } }
@media (max-width: 520px) { .steps { grid-template-columns: 1fr; } }

.story { display: grid; grid-template-columns: 120px 1fr; gap: 24px; align-items: center; background: var(--amber-bg); border-radius: var(--radius-lg); padding: 24px 28px; max-width: 860px; margin: 0 auto; }
.story-art .art { width: 120px; height: 120px; }
.story-label { display: inline-block; font-size: .78rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--amber); margin-bottom: 6px; }
.story blockquote { margin: 0 0 6px; font-size: 1.15rem; line-height: 1.5; }
.story figcaption { font-size: .88rem; color: var(--moss); }
@media (max-width: 560px) { .story { grid-template-columns: 1fr; text-align: center; } .story-art { margin: 0 auto; } }

.who { padding-top: 0; }
.who-card { display: grid; grid-template-columns: 1.3fr 1fr; gap: 40px; align-items: center; background: #fff; border: 1px solid var(--line); border-radius: var(--radius-lg); padding: clamp(24px, 4vw, 44px); box-shadow: var(--shadow); }
.who-card h2 { font-size: clamp(1.6rem, 3vw, 2.2rem); font-weight: 800; }
.who-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 12px; font-size: 1.1rem; }
.who-list li { display: flex; gap: 12px; align-items: flex-start; }
.who-list .ic { flex: none; width: 28px; height: 28px; padding: 5px; border-radius: 50%; background: var(--navy); color: #fff; margin-top: 1px; }
.who-soft { background: var(--teal-tint); border-radius: var(--radius-lg); padding: 24px; text-align: center; }
.who-soft p { font-size: 1.1rem; font-weight: 700; color: var(--navy-deep); }
@media (max-width: 860px) { .who-card { grid-template-columns: 1fr; } }

.safety-intro { display: flex; gap: 10px; align-items: center; background: #F4F1FA; color: #4A2F86; border-radius: 10px; padding: 12px 16px; margin: -6px 0 18px; font-weight: 700; }
.safety-intro .ic { color: #5B3F99; flex: none; }
.result-head .section-lede { margin: 0 auto 16px; max-width: 32em; }
.support-box { grid-template-columns: 36px 1fr; align-items: center; }
.support-box p { margin: 0; }
.next-line { display: flex; gap: 10px; align-items: center; justify-content: center; font-weight: 700; color: var(--navy-deep); background: var(--teal-tint); border-radius: 12px; padding: 14px 18px; margin-bottom: 22px; }
.next-line .ic { flex: none; color: var(--navy); }
.disclaimer { text-align: center; color: var(--moss); font-size: .92rem; margin: 6px 0 18px; }
.thanks.in-result { border: 2px solid var(--teal-tint); border-radius: var(--radius-lg); margin-bottom: 20px; }

.faq { display: grid; gap: 10px; }
.faq-item { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); }
.faq-item summary { list-style: none; cursor: pointer; display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 18px 20px; font-weight: 700; font-size: 1.08rem; min-height: 60px; }
.faq-item summary::-webkit-details-marker { display: none; }
.faq-plus { flex: none; width: 32px; height: 32px; border-radius: 50%; background: var(--teal-tint); color: var(--navy); display: grid; place-items: center; transition: transform .25s var(--ease); }
.faq-item[open] .faq-plus { transform: rotate(45deg); }
.faq-item p { margin: 0; padding: 0 20px 20px; color: var(--moss); font-size: 1.05rem; }

.closing h2 { max-width: 18em; margin-inline: auto; }
.closing .partners-line { margin: 28px auto 0; max-width: 40em; font-size: .95rem; color: rgba(255,255,255,.7); }
.emergency { display: flex; gap: 8px; align-items: center; color: #fff; }
.emergency .ic { color: #FFB4A8; }
.form-foot .ic { vertical-align: -.2em; }


/* =========================================================
   Brand: MedRite Community Care logo + Montserrat headings
   ========================================================= */
h1, h2 { font-weight: 800; letter-spacing: -.02em; }
h3, h4 { font-weight: 700; letter-spacing: -.01em; }
.hero h1 { font-weight: 800; letter-spacing: -.025em; line-height: 1.08; }
.hl { color: var(--teal); }

.logo { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: var(--navy); line-height: 1; }
.logo-cross { width: 46px; height: 46px; flex: none; fill: var(--teal); }
.logo-words { display: flex; flex-direction: column; align-items: stretch; }
.logo-name { font-family: "Montserrat", var(--font-head); font-weight: 900; font-size: 31px; letter-spacing: .005em; line-height: .9; color: inherit; }
.logo-tag { font-family: "Montserrat", var(--font-head); font-weight: 600; font-size: 11px; letter-spacing: .3em; margin-top: 6px; color: var(--teal-dark); white-space: nowrap; }
.logo-light { color: #fff; }
.logo-light .logo-tag { color: var(--teal); }
.brand-footer.logo { margin-bottom: 16px; }
@media (max-width: 420px) { .logo-cross { width: 34px; height: 34px; } .logo-name { font-size: 23px; } .logo-tag { font-size: 8.2px; } }

/* brand surfaces */
.hero { background: radial-gradient(900px 520px at 85% 15%, rgba(99,194,182,.20) 0%, transparent 60%), linear-gradient(160deg, var(--navy) 0%, var(--navy-night) 100%); }
.closing { background: radial-gradient(900px 400px at 50% 0%, rgba(99,194,182,.18), transparent 70%), var(--navy); }
.btn-primary { background: var(--navy); }
.btn-primary:hover { background: var(--navy-deep); }
.btn-light { color: var(--navy); }
.btn-light:hover { background: var(--teal-tint); }
.btn .pill { background: var(--teal); color: var(--navy-night); }
.diff-list .di, .step-n, .service .si { background: var(--navy); }
.step-ic, .who-list .ic { color: var(--teal-dark); }
.who-list .ic { background: var(--teal); color: var(--navy-night); }
.trust .ic, .hero-points .ic { color: var(--teal); }
.choice:has(input:checked), .choice.checked { border-color: var(--navy); }
.choice:has(input:checked) .mark, .choice.checked .mark { background: var(--navy); border-color: var(--navy); }
.progress-fill { background: linear-gradient(90deg, var(--navy), var(--teal)); }
.domain-chip, .need-chips li, .faq-plus, .next-line { color: var(--navy); }
.need-chips .ic, .next-line .ic, .domain-chip .ic { color: var(--teal-dark); }
.result-badge, .thanks-badge { background: var(--navy); box-shadow: 0 0 0 10px var(--teal-tint); }
.who-soft p { color: var(--navy); }
.site-footer { background: var(--navy-night); }

.hero h1 { font-size: clamp(2.2rem, 4.4vw, 3.5rem); }
.site-header { height: 76px; } :root { --header-h: 76px; }

/* Logo files (brand/*.svg, text converted to outlines) */
.logo img { display: block; height: 50px; width: auto; }
.brand-footer.logo img { height: 46px; }
@media (max-width: 420px) { .logo img { height: 40px; } }

/* Info page before the questions */
.info-step { font-family: "Montserrat", sans-serif; font-weight: 800; font-size: .8rem; letter-spacing: .08em; text-transform: uppercase; color: var(--moss); margin: 0 0 6px; }
.sc-info .contact-form { margin-top: 18px; }
.sc-info .q-nav { margin-top: 14px; }
.saving-line { text-align: center; color: var(--moss); font-weight: 700; margin: 18px 0; }

/* Photos (stock, Unsplash License; see public/img/CREDITS.md) */
.hero-photo img { display: block; width: 100%; height: auto; aspect-ratio: 11 / 9; object-fit: cover; border-radius: 28px; box-shadow: 0 24px 60px rgba(10, 12, 40, .35); border: 6px solid rgba(255,255,255,.12); }
.help-card { overflow: hidden; padding-top: 0; }
.help-card .help-photo { display: block; width: calc(100% + 40px); max-width: none; margin: 0 -20px 0; aspect-ratio: 16 / 10.5; height: auto; object-fit: cover; }
.help-card .hi { position: relative; margin-top: -32px; box-shadow: 0 0 0 5px #fff; }
.callback-photo { display: block; width: 100%; height: auto; aspect-ratio: 900 / 620; object-fit: cover; border-radius: var(--radius-lg); margin-top: 26px; }
@media (max-width: 900px) { .callback-photo { display: none; } }
.who-photo { display: block; width: 100%; height: auto; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 16px; margin: 0 0 18px; }

/* Tighter spacing (less scrolling) */
.section { padding: clamp(48px, 6vw, 64px) 0; }
.section-head { margin-bottom: clamp(24px, 3.5vw, 36px); }
.hero-grid { padding: clamp(36px, 6vw, 56px) 0 clamp(40px, 6vw, 60px); }
.closing { padding: clamp(56px, 8vw, 80px) 0; }
.steps { margin-bottom: 28px; }
/* Phones: help cards side by side with a small photo instead of stacked tall cards */
@media (max-width: 560px) {
  .help-grid { grid-template-columns: 1fr; gap: 12px; }
  .help-card { display: grid; grid-template-columns: 104px 1fr; column-gap: 14px; align-items: start; padding: 0 14px 0 0; }
  .help-card .help-photo { grid-row: 1 / span 2; width: 104px; height: 100%; min-height: 118px; margin: 0; aspect-ratio: auto; }
  .help-card .hi { display: none; }
  .help-card h3 { margin: 14px 0 4px; font-size: 1.08rem; }
  .help-card p { font-size: .95rem; padding-bottom: 14px; }
  .callback-photo { display: none; }
}
/* Background photo behind the closing call-to-action */
.closing { background: linear-gradient(rgba(23, 24, 66, .86), rgba(23, 24, 66, .92)), url("../img/closing-bg.webp") center 35% / cover no-repeat, var(--navy-deep); }

/* English / Español button (header) */
.lang-btn {
  display: inline-flex; align-items: center; gap: 6px; min-height: 44px; padding: 0 12px;
  font: inherit; font-weight: 700; font-size: .95rem; color: var(--navy);
  background: var(--white); border: 2px solid var(--line); border-radius: 999px; cursor: pointer;
}
.lang-btn:hover { border-color: var(--teal); background: var(--teal-tint); }
.lang-btn:focus-visible { outline: 3px solid var(--teal); outline-offset: 2px; }
.lang-btn .ic { width: 20px; height: 20px; }
@media (max-width: 900px) { .lang-btn { margin-left: auto; } .header-cta { margin-left: 0; } .header-inner { gap: 10px; } }
/* Phones: logo keeps its size, "Call me back" becomes a round phone button, language button gets compact */
.site-header .logo { flex: none; }
@media (max-width: 560px) {
  .header-cta { width: 44px; min-width: 44px; padding: 0; justify-content: center; border-radius: 50%; }
  .header-cta span[data-t] { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
}
@media (max-width: 420px) {
  .header-inner { gap: 8px; }
  .lang-btn { padding: 0 10px; font-size: .9rem; }
  .lang-btn .ic { display: none; }
  .logo img { height: 32px; }
}
@media (max-width: 350px) { .logo img { height: 26px; } .header-inner { gap: 6px; } }
.main-nav a { white-space: nowrap; }
@media (max-width: 1120px) { .main-nav { display: none; } .lang-btn { margin-left: auto; } .header-cta { margin-left: 0; } }

/* Both languages' labels sit in the same spot; the hidden one keeps the width steady (no jumping on switch) */
.dual { display: inline-grid; justify-items: center; }
.dual > span { grid-area: 1 / 1; }
.dual > .ghost { visibility: hidden; }

/* Questions: Back / Skip / Next stay pinned to the bottom of the screen while answering (all screen sizes),
   so nobody has to scroll to find "Next". On phones: one row, round Back button, smaller long questions. */
.screen-card { --pad: clamp(22px, 4vw, 44px); padding: var(--pad); }
.screen-card .q-nav.pin {
  position: sticky; bottom: 0; z-index: 5;
  margin: 0 calc(-1 * var(--pad)) calc(-1 * var(--pad)); padding: 14px var(--pad) calc(14px + env(safe-area-inset-bottom));
  background: #fff; border-top: 1px solid var(--line); box-shadow: 0 -8px 18px rgba(20, 24, 60, .08);
  border-radius: 0 0 var(--radius-lg) var(--radius-lg);
}
@media (max-width: 560px) {
  .screen-card .q-nav.pin { flex-wrap: nowrap; gap: 8px; padding: 12px 16px calc(12px + env(safe-area-inset-bottom)); }
  .q-nav.pin .btn { min-height: 52px; white-space: normal; line-height: 1.15; }
  .q-nav.pin .q-back { flex: 0 0 52px; width: 52px; padding: 0; justify-content: center; border-radius: 50%; }
  .q-nav.pin .q-back .lbl { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
  .q-nav.pin .btn-text { flex: none; padding: .5em .6em; }
  .q-nav.pin [data-act="next"] { flex: 1; }
  .screen-card .choices { margin-bottom: 18px; }
  .q-legend.long { font-size: 1.2rem; line-height: 1.3; }
  .choice { min-height: 54px; padding: 12px 16px; }
  body:has(.q-nav.pin) .booth-btn { display: none; } /* would sit on top of Next; booth tablets are wider than this */
}
@media (max-width: 360px) {
  .screen-card .q-nav.pin { gap: 6px; padding-left: 12px; padding-right: 12px; }
  .q-nav.pin .btn { padding-left: .8em; padding-right: .8em; font-size: .95rem; }
  .q-nav.pin .btn-text { padding: .5em .3em; }
}

/* Phones: the big hero buttons fill the width, and the "5 min" tag never breaks or gets cut off */
.btn .pill { white-space: nowrap; flex: none; }
@media (max-width: 560px) {
  .hero-ctas .btn { width: 100%; justify-content: center; padding-left: 1em; padding-right: 1em; }
}
@media (max-width: 380px) { .hero-ctas .btn { font-size: 1rem; gap: .45em; } }
