/* The page for pharmacies at /pharmacies (views/public/pharmacies.ejs), on top of home.css.
   Daylight Glass, with the amber pharmacy hue leading. The first half (header, hero, sections,
   cards, steps, notes, FAQ, band) is shared with patients.css and kept word for word the same
   there, apart from the hue tokens; the second half is this page's own.
   One radius per kind of thing: cards var(--rad-card), blocks inside a card --rad-inner, fields and
   QR boxes --rad-field, buttons and pills 999px. The audience mark (a square here, a soft blob for
   patients) is the only shape that changes from page to page; it is a percentage so a small tick and
   a large badge are the same rounded square. */

body.pharmacies {
  --c1: var(--ph-1); --c2: var(--ph-2); --rgb: var(--ph-rgb); --ci: var(--ph-ink); --ci2: var(--ph-ink-2);
  --b1: var(--ph-b1); --b2: var(--ph-b2);
  --mark: 22%;
  --mark-ink: #221004;
  --rad-inner: 22px;
  --rad-field: 14px;
}
body.pharmacies ::selection { background: rgba(var(--ph-rgb), .28); }

/* ───────────────────────── shared: header ───────────────────────── */
body.home .xc-top {
  position: relative; z-index: 2; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 16px;
  padding-top: calc(14px + env(safe-area-inset-top)); padding-bottom: 12px;
}
body.home .xc-nav { display: flex; align-items: center; gap: 4px; }
body.home .xc-nav a {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 0 14px; border-radius: 999px;
  font-size: 14.5px; font-weight: 550; color: var(--ink-2); text-decoration: none; white-space: nowrap;
  transition: background-color .2s, color .2s, box-shadow .2s;
}
body.home .xc-nav a:hover { color: var(--ink); background: rgba(255, 255, 255, .7); }
body.home .xc-nav a:not(.xc-nav-plain)::before { content: ""; width: 7px; height: 7px; flex: none; border-radius: 50%; background: var(--dot); box-shadow: 0 0 8px var(--dot); }
body.home .xc-nav-doc { --dot: var(--doc-1); --dot-rgb: var(--doc-rgb); }
body.home .xc-nav-pat { --dot: var(--pat-1); --dot-rgb: var(--pat-rgb); }
body.home .xc-nav-pat::before { border-radius: 58% 42% 55% 45% / 48% 58% 42% 52% !important; }
body.home .xc-nav-ph { --dot: var(--ph-2); --dot-rgb: var(--ph-rgb); }
body.home .xc-nav-ph::before { border-radius: 1.5px !important; }
body.home .xc-nav a[aria-current="page"] {
  color: var(--ink); font-weight: 650; background: rgba(255, 255, 255, .9);
  box-shadow: inset 0 0 0 1px rgba(var(--dot-rgb), .5), 0 6px 18px -10px rgba(var(--dot-rgb), .9);
}
body.home .xc-nav-plain { border: 1px solid rgba(12, 19, 36, .12); background: rgba(255, 255, 255, .5); }
/* A phone: the three audiences become a row of their own under the logo, and Pricing stays up
   beside the logo, so nothing is hidden behind a menu. No backdrop-filter on that row: it would
   become the containing block of the Pricing pill and pull it down into the row. */
@media (max-width: 759px) {
  body.home .xc-nav {
    flex: 1 0 100%; gap: 2px; padding: 3px; border-radius: 999px;
    background: rgba(255, 255, 255, .74); box-shadow: inset 0 0 0 1px rgba(12, 19, 36, .08), 0 8px 24px -18px rgba(var(--shade), .4);
  }
  body.home .xc-nav a:not(.xc-nav-plain) { flex: 1 1 auto; gap: 6px; padding: 0 8px; font-size: clamp(13px, 3.6vw, 14.5px); }
  body.home .xc-nav-plain { position: absolute; top: calc(14px + env(safe-area-inset-top)); right: var(--gutter-r); }
}

/* ───────────────────────── shared: hero ───────────────────────── */
/* home.css turns .home-main into the live page's two-column grid on a desktop; these pages stack
   their own sections, so it stays a plain block (it keeps home-main for the overflow clip). */
body.home .xc-main { display: block; }
body.home .xc-hero { display: grid; grid-template-columns: minmax(0, 1fr); gap: 32px; padding-top: clamp(22px, 5vw, 48px); }
body.home .xc-hero-copy { display: grid; justify-items: start; }
body.home .xc-eyebrow { margin-bottom: 18px; }
body.home .xc-spark { position: relative; width: 8px; height: 8px; flex: none; border-radius: var(--mark); background: var(--c1); box-shadow: 0 0 10px var(--c1); }
body.home .xc-spark::after { content: ""; position: absolute; inset: -4px; border-radius: inherit; border: 1px solid var(--c1); opacity: 0; animation: home-ping 3.2s ease-out infinite; }
body.home .xc-hue-text {
  display: inline-block; padding-bottom: .06em;
  background: linear-gradient(100deg, var(--ci) 10%, var(--ci2) 90%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
body.home .xc-jumps { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 24px; }
body.home .xc-jumps a {
  display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 16px 0 18px; border-radius: 999px;
  font-size: 15px; font-weight: 600; color: var(--ink); text-decoration: none;
  background: rgba(255, 255, 255, .62); box-shadow: inset 0 0 0 1px rgba(var(--rgb), .34), 0 8px 20px -16px rgba(var(--rgb), .9);
  transition: background-color .2s, box-shadow .2s;
}
body.home .xc-jumps a:hover { background: rgba(255, 255, 255, .9); box-shadow: inset 0 0 0 1px rgba(var(--rgb), .6), 0 10px 24px -14px rgba(var(--rgb), .9); }
body.home .xc-jumps svg { width: 16px; height: 16px; fill: none; stroke: var(--ci); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; transform: rotate(90deg); }
/* The card that does the job of the page (sign in here, check a code on the other) sits beside the
   headline on a desktop and right under it on a phone. */
body.home .xc-lead { align-self: start; }
@media (min-width: 960px) {
  body.home .xc-hero { grid-template-columns: minmax(0, 1.08fr) minmax(0, .92fr); align-items: center; column-gap: 56px; min-height: min(640px, calc(100vh - 90px)); padding-bottom: 24px; }
  body.home .xc-lead { align-self: center; }
}

/* ───────────────────────── shared: sections and cards ───────────────────────── */
body.home .xc-sec { margin-top: clamp(64px, 9vw, 112px); scroll-margin-top: 16px; }
body.home .xc-sec-head { display: grid; gap: 10px; max-width: 40em; margin-bottom: clamp(20px, 3vw, 30px); }
body.home .xc-kicker { font: 600 12.5px/1.3 var(--sans); letter-spacing: .08em; text-transform: uppercase; color: var(--ci); }
body.home .xc-h2 { font: 740 clamp(1.85rem, 6.6vw, 2.75rem)/1.06 var(--display); letter-spacing: -.036em; color: var(--ink); text-wrap: balance; }
body.home .xc-intro { font-size: clamp(16px, 1.3vw, 18px); color: var(--ink-2); max-width: 36em; text-wrap: pretty; }
body.home .xc-card {
  position: relative; padding: clamp(22px, 3.2vw, 38px); border-radius: var(--rad-card);
  background: linear-gradient(180deg, rgba(255, 255, 255, .84), rgba(255, 255, 255, .6) 60%), rgba(255, 255, 255, .32);
  -webkit-backdrop-filter: blur(22px) saturate(170%); backdrop-filter: blur(22px) saturate(170%);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .9), 0 0 0 1px rgba(var(--shade), .05), 0 16px 40px -28px rgba(var(--shade), .22);
}
@media (max-width: 759px) { body.home .xc-card { -webkit-backdrop-filter: blur(14px) saturate(160%); backdrop-filter: blur(14px) saturate(160%); } }
@supports not ((-webkit-backdrop-filter: blur(1px)) or (backdrop-filter: blur(1px))) { body.home .xc-card { background: #fff; } }
/* Heading on the left, card on the right, once there is room for both. */
@media (min-width: 960px) {
  body.home .xc-split { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); column-gap: 56px; align-items: start; }
  body.home .xc-split > .xc-sec-head { position: sticky; top: 24px; margin-bottom: 0; }
}

/* A calm aside inside a card, in the page's hue. */
body.home .xc-note {
  padding: 14px 16px; border-radius: var(--rad-inner); font-size: 14.5px; color: var(--ink-2);
  background: rgba(var(--rgb), .08); box-shadow: inset 0 0 0 1px rgba(var(--rgb), .26);
}
body.home .xc-caption { margin-top: 14px; text-align: center; font-size: 13.5px; color: var(--ink-3); }

/* Numbered steps, each number on the page's own mark. */
body.home .xc-steps { display: grid; gap: 20px; counter-reset: xc-step; }
body.home .xc-steps li { position: relative; display: grid; gap: 3px; min-height: 36px; padding-left: 52px; counter-increment: xc-step; font-size: 15.5px; color: var(--ink-2); }
body.home .xc-steps li::before {
  content: counter(xc-step); position: absolute; left: 0; top: -3px; display: grid; place-items: center; width: 36px; height: 36px;
  border-radius: var(--mark); font: 750 15px/1 var(--display); color: var(--mark-ink);
  background: linear-gradient(140deg, var(--c1), var(--c2));
  box-shadow: 0 0 0 1px rgba(255, 255, 255, .35) inset, 0 6px 16px -8px var(--c1);
}
body.home .xc-steps h3 { font: 700 17.5px/1.3 var(--display); letter-spacing: -.012em; color: var(--ink); }
body.home .xc-steps p { text-wrap: pretty; }

/* Plain statements with a tick on the page's mark. */
body.home .xc-points { display: grid; gap: 16px; }
body.home .xc-points li { position: relative; padding-left: 34px; font-size: 15.5px; color: var(--ink-2); }
body.home .xc-points li::before {
  content: ""; position: absolute; left: 0; top: .2em; width: 20px; height: 20px; border-radius: var(--mark);
  background: rgba(var(--rgb), .14); box-shadow: inset 0 0 0 1.5px rgba(var(--rgb), .7);
}
body.home .xc-points li::after {
  content: ""; position: absolute; left: 7.5px; top: calc(.2em + 4px); width: 5px; height: 9px;
  border: solid var(--ci); border-width: 0 2px 2px 0; transform: rotate(45deg);
}
body.home .xc-points b { color: var(--ink); font-weight: 650; }

/* The scanner's corner brackets, drawn around whatever QR they sit on. */
body.home .xc-aim {
  --l: 22px;
  position: absolute; inset: -9px; z-index: 1; pointer-events: none;
  border: 2px solid #f08a3c; border-radius: var(--rad-field);
  -webkit-mask:
    linear-gradient(#000 0 0) left top / var(--l) var(--l), linear-gradient(#000 0 0) right top / var(--l) var(--l),
    linear-gradient(#000 0 0) left bottom / var(--l) var(--l), linear-gradient(#000 0 0) right bottom / var(--l) var(--l);
  -webkit-mask-repeat: no-repeat;
  mask:
    linear-gradient(#000 0 0) left top / var(--l) var(--l), linear-gradient(#000 0 0) right top / var(--l) var(--l),
    linear-gradient(#000 0 0) left bottom / var(--l) var(--l), linear-gradient(#000 0 0) right bottom / var(--l) var(--l);
  mask-repeat: no-repeat;
  filter: drop-shadow(0 0 4px rgba(var(--ph-rgb), .55));
}

/* FAQ: plain <details>, every answer in the HTML; public/js/faq.js slides them (.is-shutting while one closes). */
body.home .xc-faq { padding-block: 8px; }
body.home .xc-faq details + details { border-top: 1px solid var(--line); }
body.home .xc-faq summary {
  display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 60px; padding: 14px 0;
  cursor: pointer; list-style: none; font: 650 17px/1.35 var(--display); letter-spacing: -.01em; color: var(--ink);
  border-radius: 10px;
}
body.home .xc-faq summary::-webkit-details-marker { display: none; }
body.home .xc-faq summary svg {
  width: 22px; height: 22px; padding: 3px; flex: none; border-radius: 50%; fill: none; stroke: var(--ci); stroke-width: 2.4; stroke-linecap: round;
  background: rgba(var(--rgb), .12); transition: transform .25s cubic-bezier(.2, .8, .2, 1);
}
body.home .xc-faq details[open]:not(.is-shutting) summary svg { transform: rotate(45deg); }
body.home .xc-faq details p { padding: 0 38px 18px 0; font-size: 15.5px; color: var(--ink-2); text-wrap: pretty; transition: opacity .25s cubic-bezier(.2, .8, .2, 1), transform .35s cubic-bezier(.2, .8, .2, 1); }
body.home .xc-faq details[open] p { animation: xc-up .45s cubic-bezier(.2, .8, .2, 1); }
@keyframes xc-up { from { opacity: 0; transform: translateY(18px); } }
body.home .xc-faq details.is-shutting p { opacity: 0; transform: translateY(-6px); }

/* The closing band. */
body.home .xc-band { display: grid; justify-items: center; gap: 12px; text-align: center; overflow: hidden; isolation: isolate; }
body.home .xc-band::before {
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none; border-radius: inherit;
  background: radial-gradient(80% 120% at 50% 120%, rgba(var(--rgb), .2), rgba(var(--rgb), 0) 70%);
}
body.home .xc-band-h { font: 740 clamp(1.6rem, 5.6vw, 2.3rem)/1.1 var(--display); letter-spacing: -.034em; color: var(--ink); text-wrap: balance; }
body.home .xc-band p { color: var(--ink-2); font-size: 16.5px; }
body.home .xc-band .home-btn { margin-top: 8px; }
body.home .xc-band .home-btn svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }
body.home .xc-band .xc-band-links { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px 12px; }
body.home .xc-btn-doc { --b1: var(--doc-b1); --b2: var(--doc-b2); --rgb: var(--doc-rgb); }
body.home .xc-link {
  display: inline-flex; align-items: center; min-height: 52px; padding: 0 12px; font-weight: 600; color: var(--ink);
  text-decoration: underline; text-decoration-color: rgba(12, 19, 36, .28); text-underline-offset: 4px;
}
body.home .xc-link:hover { text-decoration-color: currentColor; }

/* ───────────────────────── this page: how to check ───────────────────────── */
/* The steps in a card, the specimen floating on the sky beside it, as it does on the live page. */
body.pharmacies .xf-check { display: grid; grid-template-columns: minmax(0, 1fr); gap: 28px; }
body.pharmacies .xf-check-copy { display: grid; gap: 20px; align-content: start; }
body.pharmacies .xf-check-copy .xc-h2 { margin-top: -10px; }
body.pharmacies .xf-specimen { width: 100%; max-width: 480px; justify-self: center; }
body.pharmacies .xf-specimen .home-stage::before {
  background: radial-gradient(closest-side, rgba(var(--ph-rgb), .3), rgba(var(--pat-rgb), .14) 55%, rgba(var(--pat-rgb), 0) 80%);
}
body.pharmacies .xf-specimen .home-slab {
  transform: rotateX(6deg) rotateY(-7deg) rotateZ(-1.2deg);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .95), 0 0 0 1px rgba(var(--shade), .07), 0 40px 80px -30px rgba(var(--shade), .38), 0 0 70px -24px rgba(var(--ph-rgb), .55);
}
/* The brackets frame the foot of the paper: where the QR and the code always are. */
body.pharmacies .xf-aim { inset: 6px -10px -10px; --l: 30px; }
@media (prefers-reduced-motion: no-preference) {
  body.pharmacies .xf-aim { animation: xc-aim 3.6s ease-in-out infinite; }
}
@keyframes xc-aim { 0%, 100% { opacity: 1; } 50% { opacity: .55; } }
@media (max-width: 399px) { body.pharmacies .xf-specimen .home-qr { width: 92px; } }
@media (min-width: 960px) {
  body.pharmacies .xf-check { grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr); column-gap: 56px; align-items: center; }
  body.pharmacies .xf-specimen .home-slab { transform: rotateX(8deg) rotateY(-12deg) rotateZ(1.5deg); }
}

/* What the page says at the top: the three notices, in the colours the real page uses. */
body.pharmacies .xf-states-wrap { display: grid; gap: 14px; margin-top: clamp(28px, 4vw, 44px); }
body.pharmacies .xf-h3 { font: 700 clamp(1.25rem, 4.4vw, 1.5rem)/1.2 var(--display); letter-spacing: -.024em; color: var(--ink); }
body.pharmacies .xf-states { display: grid; gap: 12px; }
body.pharmacies .xf-states li {
  display: flex; gap: 14px; align-items: flex-start; padding: 16px 18px; border-radius: var(--rad-inner);
  font-size: 15px; color: var(--ink-2); background: rgba(255, 255, 255, .84);
  box-shadow: inset 0 0 0 1px rgba(var(--s-rgb), .45), 0 14px 34px -26px rgba(var(--s-rgb), .95);
}
body.pharmacies .xf-states b { color: var(--s-ink); font-weight: 700; }
body.pharmacies .xf-ok   { --s-rgb: var(--doc-rgb); --s-ink: var(--doc-ink); --s-bg: var(--doc-b1); }
body.pharmacies .xf-late { --s-rgb: var(--ph-rgb); --s-ink: var(--ph-ink); --s-bg: var(--ph-b1); }
body.pharmacies .xf-void { --s-rgb: 200, 30, 30; --s-ink: #c81e1e; --s-bg: #c81e1e; }
body.pharmacies .xf-state-mark { display: grid; place-items: center; width: 28px; height: 28px; flex: none; border-radius: 50%; color: #fff; background: var(--s-bg); }
body.pharmacies .xf-state-mark svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; }
@media (min-width: 860px) { body.pharmacies .xf-states { grid-template-columns: repeat(3, minmax(0, 1fr)); } }

/* ───────────────────────── this page: recording ───────────────────────── */
body.pharmacies .xf-record { display: grid; grid-template-columns: minmax(0, 1fr); gap: 32px; }
body.pharmacies .xf-record-copy { display: grid; gap: 20px; align-content: start; }
body.pharmacies .xf-record-copy .xc-h2 { margin-top: -10px; }
@media (min-width: 900px) {
  body.pharmacies .xf-record { grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); column-gap: 48px; align-items: center; }
}
/* The log the next pharmacy sees, drawn as the real page draws it: a tick, a half and a ring. */
body.pharmacies .xf-log-fig { width: 100%; max-width: 440px; justify-self: center; }
body.pharmacies .xf-log {
  padding: 18px 18px 6px; border-radius: var(--rad-inner); background: #fff;
  box-shadow: 0 0 0 1px rgba(12, 19, 36, .08), 0 30px 60px -36px rgba(var(--shade), .45), 0 0 50px -22px rgba(var(--ph-rgb), .6);
}
body.pharmacies .xf-log-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 12px; padding-bottom: 12px; border-bottom: 1px solid var(--line); }
body.pharmacies .xf-log-title { font: 700 16.5px/1.2 var(--display); letter-spacing: -.01em; color: var(--ink); }
body.pharmacies .xf-chip {
  padding: 5px 11px; border-radius: 999px; white-space: nowrap;
  font: 650 12.5px/1.2 var(--sans); color: var(--ph-ink); background: rgba(var(--ph-rgb), .14); box-shadow: inset 0 0 0 1px rgba(var(--ph-rgb), .42);
}
body.pharmacies .xf-log-items li { display: flex; gap: 12px; align-items: flex-start; padding: 13px 0; font: 600 14.5px/1.35 var(--sans); color: var(--ink); }
body.pharmacies .xf-log-items li + li { border-top: 1px dashed rgba(12, 19, 36, .14); }
body.pharmacies .xf-log-items small { display: block; margin-top: 3px; font-size: 13px; font-weight: 400; color: var(--ink-3); }
body.pharmacies .xf-log-items small b { font-weight: 650; color: var(--ph-ink); }
body.pharmacies .xf-dot { display: grid; place-items: center; width: 22px; height: 22px; flex: none; margin-top: 0; border-radius: 50%; }
body.pharmacies .xf-dot svg { fill: none; stroke: currentColor; stroke-linecap: round; stroke-linejoin: round; }
body.pharmacies .is-done .xf-dot { color: #fff; background: var(--doc-b1); }
body.pharmacies .is-done .xf-dot svg { width: 13px; height: 13px; stroke-width: 3.2; }
body.pharmacies .is-part .xf-dot { color: var(--ph-b1); }
body.pharmacies .is-part .xf-dot svg { width: 22px; height: 22px; stroke-width: 2; }
body.pharmacies .is-none .xf-dot { box-shadow: inset 0 0 0 2px rgba(12, 19, 36, .22); }

/* ───────────────────────── this page: why it matters ───────────────────────── */
body.pharmacies .xf-why { display: grid; grid-template-columns: minmax(0, 1fr); gap: 16px; }
body.pharmacies .xf-why .xc-card { display: grid; gap: 10px; align-content: start; }
body.pharmacies .xf-why h3 { margin-top: 8px; font: 700 19px/1.25 var(--display); letter-spacing: -.016em; color: var(--ink); text-wrap: balance; }
body.pharmacies .xf-why p { font-size: 15.5px; color: var(--ink-2); text-wrap: pretty; }
body.pharmacies .xf-badge {
  display: grid; place-items: center; width: 46px; height: 46px; border-radius: var(--mark); color: var(--mark-ink);
  background: linear-gradient(140deg, var(--ph-1), var(--ph-2));
  box-shadow: 0 0 0 1px rgba(255, 255, 255, .35) inset, 0 8px 20px -8px var(--ph-1);
}
body.pharmacies .xf-badge svg { width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
@media (min-width: 860px) { body.pharmacies .xf-why { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
