/* TinkySpeak Hospitals & Clinical landing page stylesheet.
   Extracted verbatim from /public/medical.html on 2026-05-04 (Pass 1 of multi-pass refactor).
   Order is load-bearing — append-only. Do not reorder rules without verifying byte-equivalent rendering.
   Brace balance at extraction: 468 open / 468 close. */

/* ═══════════════════════════════════════════
   FOUNDATIONS — shared with main site
   ═══════════════════════════════════════════ */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }

:root {
  --f-serif: 'Fraunces', 'Georgia', serif;
  --f-sans: 'General Sans', system-ui, -apple-system, sans-serif;

  --ink: #0d0b0e;
  --ink-soft: #2a2433;
  --ink-muted: #6b6177;
  --surface: #f7f6f4;
  --surface-warm: #f0ede8;
  --surface-dark: #13111a;
  --surface-deep: #0d0b10;

  /* Medical palette — muted, dignified */
  --med-blue: #4a6fa5;
  --med-blue-soft: #6b8ec2;
  --med-blue-pale: #e8eef6;
  --med-blue-glow: rgba(74, 111, 165, 0.12);
  --med-warm: #b8937a;
  --med-warm-soft: #d4b8a4;
  --med-warm-pale: #f5ede7;
  --med-slate: #64748b;
  --med-rose: #c4707a;
  --med-rose-pale: #fce8ea;
  --med-green: #5a9e6f;
  --med-green-pale: #e5f2e8;

  /* Keep amber for brand consistency in nav */
  --amber: #e8a33d;
  --amber-light: #f4c97b;
  --green-soft: #4ade80;

  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
  --container: min(1120px, 88vw);
  --section-gap: clamp(5rem, 12vw, 8rem);
}

html { scroll-behavior: smooth; scroll-padding-top: 80px; }

body {
  font-family: var(--f-sans);
  color: var(--ink);
  background: var(--surface);
  line-height: 1.7;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5 {
  font-family: var(--f-serif);
  font-weight: 600;
  line-height: 1.15;
  letter-spacing: -0.01em;
}

a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; border: none; }
.container { width: var(--container); margin: 0 auto; }

/* Subtle grain overlay */
body::after {
  content: '';
  position: fixed; inset: 0;
  background: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.03'/%3E%3C/svg%3E");
  pointer-events: none;
  z-index: 9999;
}

/* Reveal system */
.rv {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.8s var(--ease-out), transform 0.8s var(--ease-out);
}
.rv.vis { opacity: 1; transform: translateY(0); }
.rv-d1 { transition-delay: 0.08s; }
.rv-d2 { transition-delay: 0.16s; }
.rv-d3 { transition-delay: 0.24s; }
.rv-d4 { transition-delay: 0.32s; }
.rv-d5 { transition-delay: 0.40s; }
.rv-d6 { transition-delay: 0.48s; }

/* ═══════════════════════════════════════════
   NAV — matches main site
   ═══════════════════════════════════════════ */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
  padding: 1.1rem 0;
  transition: all 0.5s var(--ease-out);
}
.nav.scrolled {
  background: rgba(13, 11, 14, 0.92);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  padding: 0.65rem 0;
  box-shadow: 0 1px 40px rgba(0,0,0,0.25);
}
.nav-inner {
  width: var(--container); margin: 0 auto;
  display: flex; align-items: center; justify-content: space-between;
}
.nav-logo {
  font-family: var(--f-serif);
  font-size: 1.35rem;
  font-weight: 700;
  color: #fff;
  display: flex; align-items: center; gap: 0.5rem;
}
.nav-logo-dot {
  width: 10px; height: 10px; border-radius: 50%;
  background: var(--amber);
  box-shadow: 0 0 12px var(--amber);
}
.nav-links { display: flex; gap: 2rem; list-style: none; }
.nav-links a {
  color: rgba(255,255,255,0.7);
  font-size: 0.85rem;
  font-weight: 500;
  letter-spacing: 0.03em;
  transition: color 0.3s;
}
.nav-links a:hover { color: var(--amber); }
.nav-links a.active { color: #fff; font-weight: 700; }
.nav-cta-btn {
  background: #9b8ec4;
  color: #fff;
  font-weight: 600;
  font-size: 0.82rem;
  padding: 0.55rem 1.3rem;
  border-radius: 100px;
  letter-spacing: 0.02em;
  transition: all 0.3s var(--ease-spring);
}
.nav-cta-btn:hover { transform: scale(1.05); box-shadow: 0 4px 20px rgba(155,142,196,0.4); }
.hamburger { display: none; background: none; border: none; padding: 0.5rem; cursor: pointer; }
.hamburger span {
  display: block; width: 22px; height: 2px; background: #fff;
  margin: 5px 0; border-radius: 2px;
}
.mob-menu {
  display: none; position: fixed; inset: 0;
  background: rgba(13,11,14,0.96); z-index: 999;
  flex-direction: column; align-items: center; justify-content: center; gap: 2rem;
}
.mob-menu.open { display: flex; }
.mob-menu a {
  color: #fff; font-size: 1.3rem; font-family: var(--f-serif);
  opacity: 0.8; transition: opacity 0.3s;
}
.mob-menu a:hover { opacity: 1; }
.mob-close {
  position: absolute; top: 1.5rem; right: 1.5rem;
  background: none; border: none; color: #fff; font-size: 2rem; cursor: pointer;
}

/* ═══════════════════════════════════════════
   HERO — Quiet, dignified, urgent
   ═══════════════════════════════════════════ */
.hero {
  min-height: 100vh;
  background: var(--surface-dark);
  color: #fff;
  display: flex; align-items: center;
  position: relative;
  overflow: hidden;
  padding: 8rem 0 5rem;
}
.hero::before {
  content: '';
  position: absolute; inset: 0;
  background:
    radial-gradient(ellipse 50% 60% at 70% 35%, rgba(74,111,165,0.1), transparent),
    radial-gradient(ellipse 40% 50% at 25% 75%, rgba(184,147,122,0.07), transparent);
  pointer-events: none;
}
/* Subtle heartbeat line across hero */
.hero::after {
  content: '';
  position: absolute;
  bottom: 0; left: 0; right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(74,111,165,0.3), rgba(196,112,122,0.3), transparent);
}

.hero-content {
  max-width: 680px;
  position: relative;
  z-index: 1;
}
.hero-badge {
  display: inline-flex; align-items: center; gap: 0.6rem;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--med-blue-soft);
  margin-bottom: 2rem;
  padding: 0.5rem 1rem;
  background: rgba(74,111,165,0.1);
  border: 1px solid rgba(74,111,165,0.2);
  border-radius: 100px;
}
.hero-badge-dot {
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--med-blue-soft);
  animation: pulse-dot 2s ease-in-out infinite;
}
@keyframes pulse-dot {
  0%, 100% { opacity: 0.4; }
  50% { opacity: 1; box-shadow: 0 0 8px var(--med-blue-soft); }
}

.hero h1 {
  font-size: clamp(2.4rem, 5vw, 3.8rem);
  font-weight: 700;
  line-height: 1.1;
  margin-bottom: 1.8rem;
  max-width: 600px;
}
.hero h1 em {
  font-style: italic;
  color: var(--med-warm-soft);
  font-weight: 600;
}
.hero-quote {
  font-family: var(--f-serif);
  font-style: italic;
  font-size: 1.25rem;
  line-height: 1.6;
  color: rgba(255,255,255,0.6);
  border-left: 3px solid var(--med-warm);
  padding-left: 1.5rem;
  margin-bottom: 2.5rem;
  max-width: 520px;
}
.hero-sub {
  font-size: 1.05rem;
  line-height: 1.75;
  color: rgba(255,255,255,0.6);
  max-width: 500px;
  margin-bottom: 2.5rem;
}
.hero-sub strong { color: rgba(255,255,255,0.85); font-weight: 600; }
.hero-actions { display: flex; gap: 1rem; flex-wrap: wrap; margin-bottom: 3rem; }
.btn-med {
  background: var(--med-blue);
  color: #fff;
  font-weight: 700;
  font-size: 0.95rem;
  padding: 0.85rem 2rem;
  border-radius: 100px;
  display: inline-flex; align-items: center; gap: 0.5rem;
  transition: all 0.3s var(--ease-spring);
}
.btn-med:hover { transform: translateY(-2px); box-shadow: 0 8px 30px rgba(74,111,165,0.35); }
.btn-outline {
  background: transparent;
  color: #fff;
  font-weight: 600;
  font-size: 0.95rem;
  padding: 0.85rem 2rem;
  border-radius: 100px;
  border: 1px solid rgba(255,255,255,0.2);
  display: inline-flex; align-items: center; gap: 0.5rem;
  transition: all 0.3s;
}
.btn-outline:hover { background: rgba(255,255,255,0.08); border-color: rgba(255,255,255,0.35); }

.hero-stats {
  display: flex; gap: 3rem;
}
.hero-stat {
  display: flex; flex-direction: column;
}
.hero-stat-val {
  font-family: var(--f-serif);
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--med-blue-soft);
  line-height: 1;
}
.hero-stat-label {
  font-size: 0.7rem;
  color: rgba(255,255,255,0.4);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 500;
  margin-top: 0.3rem;
}

/* Floating tablet visual on right side */
.hero-visual {
  position: absolute;
  right: 8%;
  top: 50%;
  transform: translateY(-50%);
  opacity: 0.12;
  pointer-events: none;
}
.hero-tablet-ghost {
  width: 300px; height: 420px;
  border: 2px solid rgba(74,111,165,0.3);
  border-radius: 24px;
  display: flex; flex-direction: column;
  padding: 2rem 1.5rem;
  gap: 1rem;
}
.ghost-tile {
  height: 48px;
  border-radius: 10px;
  border: 1px solid rgba(74,111,165,0.2);
  display: flex; align-items: center;
  padding: 0 1rem;
  gap: 0.8rem;
}
.ghost-dot {
  width: 24px; height: 24px;
  border-radius: 6px;
  background: rgba(74,111,165,0.15);
}
.ghost-line {
  flex: 1; height: 8px;
  border-radius: 4px;
  background: rgba(74,111,165,0.1);
}
.ghost-line.short { max-width: 60%; }

/* ═══════════════════════════════════════════
   STORY — "She couldn't tell us what hurt"
   ═══════════════════════════════════════════ */
.story-section {
  padding: var(--section-gap) 0;
  background: #fff;
  position: relative;
}
.story-section::before {
  content: '';
  position: absolute; top: 0; left: 0; right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--med-blue-pale), transparent);
}

.story-grid {
  display: grid;
  grid-template-columns: 1fr 1.1fr;
  gap: 5rem;
  align-items: center;
}
.story-label {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--med-blue);
  margin-bottom: 1rem;
  display: flex; align-items: center; gap: 0.6rem;
}
.story-label::before {
  content: '';
  width: 24px; height: 2px;
  background: var(--med-blue);
  border-radius: 2px;
}
.story-title {
  font-size: clamp(1.8rem, 3.5vw, 2.6rem);
  font-weight: 700;
  margin-bottom: 1.5rem;
  line-height: 1.15;
}
.story-title em {
  font-style: italic;
  color: var(--med-warm);
}
.story-body p {
  font-size: 1rem;
  line-height: 1.8;
  color: var(--ink-soft);
  margin-bottom: 1.2rem;
}
.story-body strong { color: var(--ink); font-weight: 600; }

.story-right {
  position: relative;
}
.story-card {
  background: var(--surface);
  border-radius: 20px;
  padding: 2.5rem;
  border: 1px solid rgba(0,0,0,0.06);
  box-shadow: 0 20px 60px rgba(0,0,0,0.04);
}
.story-card-label {
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--med-slate);
  margin-bottom: 1.5rem;
}
.story-timeline {
  display: flex;
  flex-direction: column;
  gap: 1.2rem;
}
.timeline-item {
  display: flex; gap: 1rem; align-items: flex-start;
}
.timeline-marker {
  width: 36px; height: 36px;
  border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  font-size: 1rem;
  flex-shrink: 0;
}
.timeline-marker.urgent { background: var(--med-rose-pale); }
.timeline-marker.build { background: var(--med-blue-pale); }
.timeline-marker.hope { background: var(--med-green-pale); }

.timeline-text {
  font-size: 0.88rem;
  line-height: 1.6;
  color: var(--ink-soft);
}
.timeline-text strong {
  color: var(--ink);
  display: block;
  font-size: 0.82rem;
  margin-bottom: 0.15rem;
}

/* ═══════════════════════════════════════════
   STROKE MODE FEATURES
   ═══════════════════════════════════════════ */
.stroke-section {
  padding: var(--section-gap) 0;
  background: var(--surface-dark);
  color: #fff;
  position: relative;
  overflow: hidden;
}
.stroke-section::before {
  content: '';
  position: absolute; inset: 0;
  background:
    radial-gradient(ellipse 60% 40% at 80% 20%, rgba(74,111,165,0.08), transparent),
    radial-gradient(ellipse 50% 50% at 10% 80%, rgba(196,112,122,0.05), transparent);
  pointer-events: none;
}

.section-label-med {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--med-blue-soft);
  margin-bottom: 1rem;
  display: flex; align-items: center; gap: 0.6rem;
}
.section-label-med::before {
  content: '';
  width: 24px; height: 2px;
  background: var(--med-blue-soft);
  border-radius: 2px;
}

.section-title-med {
  font-size: clamp(1.8rem, 3.5vw, 2.8rem);
  font-weight: 700;
  margin-bottom: 0.8rem;
  max-width: 600px;
}
.section-desc-med {
  font-size: 1.05rem;
  color: rgba(255,255,255,0.55);
  max-width: 560px;
  line-height: 1.7;
  margin-bottom: 3rem;
}

.stroke-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.5rem;
}
.stroke-card {
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 16px;
  padding: 2rem;
  transition: all 0.4s var(--ease-out);
  position: relative;
}
.stroke-card:hover {
  background: rgba(255,255,255,0.06);
  border-color: rgba(255,255,255,0.12);
  transform: translateY(-2px);
}
.stroke-card-icon {
  width: 44px; height: 44px;
  border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.3rem;
  margin-bottom: 1.2rem;
}
.stroke-card-icon.pain { background: rgba(196,112,122,0.15); }
.stroke-card-icon.vitals { background: rgba(74,111,165,0.15); }
.stroke-card-icon.alert { background: rgba(239,68,68,0.12); }
.stroke-card-icon.emergency { background: rgba(239,68,68,0.15); }
.stroke-card-icon.recovery { background: rgba(90,158,111,0.15); }
.stroke-card-icon.report { background: rgba(155,142,196,0.15); }
.stroke-card-icon.interface { background: rgba(184,147,122,0.15); }

.stroke-card h4 {
  font-size: 1.05rem;
  font-weight: 600;
  margin-bottom: 0.6rem;
  color: #fff;
  font-family: var(--f-sans);
}
.stroke-card p {
  font-size: 0.88rem;
  line-height: 1.65;
  color: rgba(255,255,255,0.55);
}

/* ═══════════════════════════════════════════
   DEMENTIA COMMUNICATION
   ═══════════════════════════════════════════ */
.dementia-section {
  padding: var(--section-gap) 0;
  background: #fff;
  position: relative;
}

.dementia-header {
  max-width: 600px;
  margin-bottom: 3.5rem;
}
.dementia-header .section-label-med { color: var(--med-warm); }
.dementia-header .section-label-med::before { background: var(--med-warm); }

.dignity-callout {
  background: var(--med-warm-pale);
  border-left: 4px solid var(--med-warm);
  border-radius: 0 12px 12px 0;
  padding: 1.5rem 2rem;
  margin-bottom: 3rem;
}
.dignity-callout p {
  font-family: var(--f-serif);
  font-style: italic;
  font-size: 1.05rem;
  line-height: 1.65;
  color: var(--ink-soft);
}

.dementia-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
}
.dementia-card {
  background: var(--surface);
  border: 1px solid rgba(0,0,0,0.06);
  border-radius: 14px;
  padding: 1.8rem;
  transition: all 0.3s;
}
.dementia-card:hover {
  box-shadow: 0 8px 30px rgba(0,0,0,0.06);
  transform: translateY(-2px);
}
.dementia-card-icon {
  width: 40px; height: 40px;
  border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.15rem;
  margin-bottom: 1rem;
  background: var(--med-warm-pale);
}
.dementia-card h4 {
  font-size: 0.95rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
  font-family: var(--f-sans);
}
.dementia-card p {
  font-size: 0.85rem;
  line-height: 1.65;
  color: var(--ink-muted);
}

/* ═══════════════════════════════════════════
   INPATIENT ONBOARDING
   ═══════════════════════════════════════════ */
.intake-section {
  padding: var(--section-gap) 0;
  background: var(--surface-dark);
  color: #fff;
  position: relative;
  overflow: hidden;
}
.intake-section::before {
  content: '';
  position: absolute; inset: 0;
  background:
    radial-gradient(ellipse 50% 50% at 20% 30%, rgba(232,163,61,0.06), transparent),
    radial-gradient(ellipse 40% 60% at 80% 70%, rgba(74,111,165,0.06), transparent);
  pointer-events: none;
}
.intake-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.5rem;
  margin-top: 2.5rem;
}
.intake-card {
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 16px;
  padding: 2rem;
  transition: all 0.4s var(--ease-out);
}
.intake-card:hover {
  background: rgba(255,255,255,0.06);
  border-color: rgba(255,255,255,0.12);
  transform: translateY(-2px);
}
.intake-card-icon {
  width: 44px; height: 44px;
  border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.3rem;
  margin-bottom: 1.2rem;
}
.intake-card-icon.er { background: rgba(239,68,68,0.15); }
.intake-card-icon.lang { background: rgba(74,111,165,0.15); }
.intake-card-icon.injury { background: rgba(232,163,61,0.15); }
.intake-card-icon.boards { background: rgba(90,158,111,0.15); }
.intake-card-icon.speed { background: rgba(155,142,196,0.15); }
.intake-card-icon.privacy { background: rgba(184,147,122,0.15); }

.intake-card h4 {
  font-size: 1.05rem;
  font-weight: 600;
  margin-bottom: 0.6rem;
  color: #fff;
  font-family: var(--f-sans);
}
.intake-card p {
  font-size: 0.88rem;
  line-height: 1.65;
  color: rgba(255,255,255,0.55);
}
.intake-workflow {
  margin-top: 2.5rem;
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}
.intake-step {
  flex: 1;
  min-width: 180px;
  background: rgba(232,163,61,0.06);
  border: 1px solid rgba(232,163,61,0.15);
  border-radius: 14px;
  padding: 1.5rem;
  text-align: center;
  position: relative;
}
.intake-step-num {
  width: 28px; height: 28px;
  background: var(--med-warm);
  color: var(--surface-dark);
  font-family: var(--f-serif);
  font-weight: 800;
  font-size: 0.8rem;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  margin: 0 auto 0.8rem;
}
.intake-step h5 {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--med-warm);
  margin-bottom: 0.3rem;
  font-family: var(--f-sans);
}
.intake-step p {
  font-size: 0.78rem;
  color: rgba(255,255,255,0.5);
  line-height: 1.5;
}
@media (max-width: 768px) {
  .intake-workflow { flex-direction: column; }
}

/* ═══════════════════════════════════════════
   HOSPITALS & FACILITIES
   ═══════════════════════════════════════════ */
.facility-section {
  padding: var(--section-gap) 0;
  background: var(--surface);
  position: relative;
}

.facility-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: start;
}
.facility-left {
  position: sticky;
  top: 6rem;
}
.facility-features {
  display: flex;
  flex-direction: column;
  gap: 1.2rem;
}
.facility-feat {
  display: flex;
  gap: 1.2rem;
  align-items: flex-start;
  padding: 1.2rem 1.5rem;
  background: #fff;
  border-radius: 12px;
  border: 1px solid rgba(0,0,0,0.05);
  transition: all 0.3s;
}
.facility-feat:hover {
  box-shadow: 0 4px 20px rgba(0,0,0,0.05);
}
.facility-feat-icon {
  width: 40px; height: 40px;
  border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.1rem;
  flex-shrink: 0;
  background: var(--med-blue-pale);
}
.facility-feat h4 {
  font-size: 0.9rem;
  font-weight: 600;
  margin-bottom: 0.25rem;
  font-family: var(--f-sans);
}
.facility-feat p {
  font-size: 0.82rem;
  color: var(--ink-muted);
  line-height: 1.55;
}

/* Price callout */
.price-card {
  background: var(--surface-dark);
  color: #fff;
  border-radius: 18px;
  padding: 2.5rem;
  margin-top: 2rem;
}
.price-card-eyebrow {
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--med-blue-soft);
  margin-bottom: 0.8rem;
}
.price-card h3 {
  font-size: 2.2rem;
  font-weight: 800;
  margin-bottom: 0.5rem;
}
.price-card h3 span { color: var(--med-blue-soft); }
.price-card-sub {
  font-size: 0.95rem;
  color: rgba(255,255,255,0.55);
  margin-bottom: 1.5rem;
  line-height: 1.6;
}
.price-card-math {
  font-size: 0.82rem;
  color: rgba(255,255,255,0.45);
  padding-top: 1rem;
  border-top: 1px solid rgba(255,255,255,0.08);
  line-height: 1.6;
}
.price-card-math strong { color: rgba(255,255,255,0.7); }

/* ═══════════════════════════════════════════
   CAREGIVER DASHBOARD
   ═══════════════════════════════════════════ */
.caregiver-section {
  padding: var(--section-gap) 0;
  background: #fff;
}
.caregiver-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
}
.caregiver-visual {
  background: var(--surface);
  border-radius: 20px;
  padding: 2rem;
  border: 1px solid rgba(0,0,0,0.06);
}
.dash-header {
  display: flex; justify-content: space-between; align-items: center;
  margin-bottom: 1.5rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid rgba(0,0,0,0.06);
}
.dash-title {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--ink-soft);
  font-family: var(--f-sans);
}
.dash-badge {
  font-size: 0.65rem;
  font-weight: 600;
  padding: 0.3rem 0.7rem;
  border-radius: 100px;
  background: var(--med-green-pale);
  color: var(--med-green);
}
.dash-metrics {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  margin-bottom: 1.5rem;
}
.dash-metric {
  text-align: center;
  padding: 1rem 0.5rem;
  background: #fff;
  border-radius: 10px;
}
.dash-metric-val {
  font-family: var(--f-serif);
  font-size: 1.6rem;
  font-weight: 800;
  color: var(--ink);
  line-height: 1;
}
.dash-metric-label {
  font-size: 0.65rem;
  color: var(--ink-muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-top: 0.3rem;
}
/* Mini bar chart */
.dash-chart {
  display: flex;
  align-items: flex-end;
  gap: 6px;
  height: 80px;
  padding: 0.5rem;
  background: #fff;
  border-radius: 10px;
}
.dash-bar {
  flex: 1;
  border-radius: 4px 4px 0 0;
  min-height: 8px;
  transition: height 0.6s var(--ease-out);
}
.dash-bar.b1 { height: 35%; background: var(--med-blue-pale); }
.dash-bar.b2 { height: 50%; background: var(--med-blue-pale); }
.dash-bar.b3 { height: 42%; background: var(--med-blue-pale); }
.dash-bar.b4 { height: 65%; background: var(--med-blue-pale); }
.dash-bar.b5 { height: 55%; background: var(--med-blue-pale); }
.dash-bar.b6 { height: 72%; background: var(--med-blue); }
.dash-bar.b7 { height: 80%; background: var(--med-blue); }

.caregiver-features {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}
.cg-feat {
  display: flex;
  gap: 1rem;
  align-items: flex-start;
}
.cg-feat-icon {
  width: 36px; height: 36px;
  border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  font-size: 1rem;
  flex-shrink: 0;
  background: var(--med-blue-pale);
}
.cg-feat h4 {
  font-size: 0.9rem;
  font-weight: 600;
  margin-bottom: 0.2rem;
  font-family: var(--f-sans);
}
.cg-feat p {
  font-size: 0.82rem;
  color: var(--ink-muted);
  line-height: 1.55;
}

/* ═══════════════════════════════════════════
   TESTIMONIALS
   ═══════════════════════════════════════════ */
.testi-section {
  padding: var(--section-gap) 0;
  background: var(--surface);
}
.testi-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 1.5rem;
}
.testi-card {
  background: #fff;
  border-radius: 16px;
  padding: 2rem;
  border: 1px solid rgba(0,0,0,0.05);
  transition: all 0.3s;
}
.testi-card:hover {
  box-shadow: 0 8px 30px rgba(0,0,0,0.06);
}
.testi-stars {
  color: var(--amber);
  font-size: 0.85rem;
  margin-bottom: 1rem;
  letter-spacing: 2px;
}
.testi-text {
  font-family: var(--f-serif);
  font-style: italic;
  font-size: 0.95rem;
  line-height: 1.65;
  color: var(--ink-soft);
  margin-bottom: 1.2rem;
}
.testi-author {
  font-size: 0.78rem;
  color: var(--ink-muted);
  font-weight: 500;
}

/* ═══════════════════════════════════════════
   CTA
   ═══════════════════════════════════════════ */
.cta-section {
  padding: var(--section-gap) 0;
  background: var(--surface-dark);
  color: #fff;
  text-align: center;
}
.cta-title {
  font-size: clamp(1.8rem, 3.5vw, 2.6rem);
  font-weight: 700;
  margin-bottom: 1rem;
  max-width: 550px;
  margin-left: auto; margin-right: auto;
}
.cta-desc {
  font-size: 1.05rem;
  color: rgba(255,255,255,0.55);
  max-width: 520px;
  margin: 0 auto 2.5rem;
  line-height: 1.7;
}
.cta-actions {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 1.5rem;
}
.cta-device-box {
  max-width: 560px;
  margin: 1.5rem auto;
  background: rgba(74,111,165,0.1);
  border: 1px solid rgba(74,111,165,0.2);
  border-radius: 12px;
  padding: 1.2rem 1.5rem;
  text-align: left;
}
.cta-device-box p {
  font-size: 0.85rem;
  color: rgba(255,255,255,0.6);
  line-height: 1.65;
}
.cta-device-box strong { color: rgba(255,255,255,0.85); }
.cta-device-box em { color: var(--med-blue-soft); }

.cta-form {
  display: flex;
  max-width: 460px;
  margin: 2rem auto 0;
  gap: 0.5rem;
}
.cta-input {
  flex: 1;
  padding: 0.8rem 1.2rem;
  border-radius: 100px;
  border: 1px solid rgba(255,255,255,0.15);
  background: rgba(255,255,255,0.06);
  color: #fff;
  font-family: var(--f-sans);
  font-size: 0.9rem;
  outline: none;
  transition: border-color 0.3s;
}
.cta-input::placeholder { color: rgba(255,255,255,0.3); }
.cta-input:focus { border-color: var(--med-blue-soft); }

/* ═══════════════════════════════════════════
   CONTACT FORM (dark variant — med-blue accent)
   ═══════════════════════════════════════════ */
.contact-form { max-width: 560px; margin: 2rem auto 0; text-align: left; }
.cf-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; margin-bottom: 1rem; }
.cf-field { display: flex; flex-direction: column; }
.cf-field-full { margin-bottom: 1rem; }
.cf-label {
  font-size: 0.75rem; font-weight: 600; text-transform: uppercase;
  letter-spacing: 0.06em; margin-bottom: 0.4rem; color: rgba(255,255,255,0.5);
  font-family: var(--f-sans);
}
.cf-req { color: var(--med-blue-soft); }
.cf-input, .cf-select, .cf-textarea {
  padding: 0.75rem 1rem; border-radius: 10px; font-family: var(--f-sans);
  font-size: 0.9rem; outline: none; transition: border-color 0.3s, box-shadow 0.3s;
  border: 2px solid rgba(255,255,255,0.1); background: rgba(255,255,255,0.06); color: #fff;
}
.cf-input::placeholder, .cf-textarea::placeholder { color: rgba(255,255,255,0.3); }
.cf-input:focus, .cf-select:focus, .cf-textarea:focus {
  border-color: var(--med-blue-soft); box-shadow: 0 0 0 3px rgba(96,165,250,0.15);
}
.cf-input.cf-invalid, .cf-select.cf-invalid, .cf-textarea.cf-invalid { border-color: #ef4444; }
.cf-select {
  appearance: none; cursor: pointer;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%23999' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 1rem center; padding-right: 2.5rem;
}
.cf-select option { background: #1a1a2e; color: #fff; }
.cf-textarea { resize: vertical; min-height: 100px; }
.cf-submit-row { text-align: center; margin-top: 1.5rem; }
.cf-submit-btn { min-width: 200px; cursor: pointer; border: none; }
.cf-submit-btn:disabled { opacity: 0.6; cursor: not-allowed; }
.cf-btn-loading { display: inline-flex; align-items: center; gap: 0.4rem; }
.cf-spinner {
  display: inline-block; width: 14px; height: 14px;
  border: 2px solid rgba(255,255,255,0.2); border-top-color: #fff;
  border-radius: 50%; animation: cf-spin 0.6s linear infinite;
}
@keyframes cf-spin { to { transform: rotate(360deg); } }
.cf-note { font-size: 0.72rem; margin-top: 0.8rem; color: rgba(255,255,255,0.4); }
.cf-success { text-align: center; padding: 2rem; }
.cf-success-icon {
  width: 48px; height: 48px; border-radius: 50%; background: var(--med-blue-soft);
  color: #fff; display: flex; align-items: center; justify-content: center;
  font-size: 1.5rem; font-weight: 700; margin: 0 auto 1rem;
}
.cf-success h4 { font-family: var(--f-serif); font-size: 1.3rem; margin-bottom: 0.5rem; color: #fff; }
.cf-success p { color: rgba(255,255,255,0.6); }
.cf-error-msg {
  background: rgba(239,68,68,0.15); border: 1px solid rgba(239,68,68,0.3);
  color: #ef4444; padding: 0.8rem 1.2rem; border-radius: 10px;
  font-size: 0.85rem; margin-top: 1rem; text-align: center;
}

/* ═══════════════════════════════════════════
   FOOTER
   ═══════════════════════════════════════════ */
.footer {
  padding: 3rem 0 2rem;
  background: var(--surface-deep, #0d0b10);
  color: rgba(255,255,255,0.4);
  font-size: 0.82rem;
}
.footer-inner {
  display: flex; flex-direction: column; align-items: center; gap: 2rem;
}
.footer-logo {
  font-family: var(--f-serif);
  font-weight: 700;
  color: rgba(255,255,255,0.5);
  font-size: 1.1rem;
}
.footer-columns {
  display: flex; gap: 3rem; justify-content: center; flex-wrap: wrap;
}
.footer-col { min-width: 140px; }
.footer-col-title {
  font-weight: 600; color: rgba(255,255,255,0.6);
  font-size: 0.72rem; text-transform: uppercase;
  letter-spacing: 0.1em; margin-bottom: 0.75rem;
}
.footer-links {
  list-style: none; display: flex; flex-direction: column; gap: 0.45rem;
}
.footer-links a {
  color: rgba(255,255,255,0.4); transition: color 0.3s; font-size: 0.82rem;
}
.footer-links a:hover { color: var(--amber, #e8a33d); }
.footer-bottom {
  text-align: center; font-size: 0.72rem; opacity: 0.5;
  padding-top: 1.5rem; border-top: 1px solid rgba(255,255,255,0.05);
  width: 100%;
}
@media (max-width: 600px) {
  .footer-columns { flex-direction: column; align-items: center; text-align: center; gap: 2rem; }
}

/* ═══════════════════════════════════════════
   RESPONSIVE
   ═══════════════════════════════════════════ */
@media (max-width: 1024px) {
  .hero-visual { display: none; }
  .story-grid, .facility-grid, .caregiver-grid { grid-template-columns: 1fr; gap: 2.5rem; }
  .facility-left { position: static; }
}
@media (max-width: 768px) {
  .nav-links { display: none; }
  .nav-cta-btn { display: none; }
  .hamburger { display: block; }
  .hero { padding: 6rem 0 4rem; }
  .hero h1 { font-size: 2rem; }
  .hero-stats { gap: 1.5rem; flex-wrap: wrap; }
  .stroke-grid { grid-template-columns: 1fr; }
  .dementia-grid { grid-template-columns: 1fr; }
  .dash-metrics { grid-template-columns: repeat(3, 1fr); }
  .testi-grid { grid-template-columns: 1fr; }
  .cta-form { flex-direction: column; }
  .cf-row { grid-template-columns: 1fr; }
}
/* ── Auth Nav ── */
.nav-login-btn { padding:0.5rem 1.2rem; border-radius:100px; font-size:0.82rem; font-weight:700; color:#22c55e; border:2px solid #22c55e; text-decoration:none; transition:all 0.3s ease; letter-spacing:0.02em; }
.nav-login-btn:hover { background:#22c55e; color:#fff; transform:scale(1.05); }
.nav-user-wrap { position:relative; }
.nav-user-btn { display:flex; align-items:center; gap:0.5rem; padding:0.4rem 1rem 0.4rem 0.4rem; border-radius:100px; font-size:0.82rem; font-weight:600; color:#22c55e; border:2px solid rgba(34,197,94,0.3); cursor:pointer; transition:all 0.3s ease; background:transparent; white-space:nowrap; }
.nav-user-btn:hover { border-color:#22c55e; }
.nav-user-avatar { width:26px; height:26px; border-radius:50%; background:#22c55e; color:#000; display:flex; align-items:center; justify-content:center; font-size:0.72rem; font-weight:800; flex-shrink:0; }
.nav-user-drop { display:none; position:absolute; top:calc(100% + 0.5rem); right:0; background:#1a1a2e; border:1px solid rgba(255,255,255,0.1); border-radius:12px; padding:0.5rem; min-width:200px; z-index:1000; box-shadow:0 8px 32px rgba(0,0,0,0.4); }
.nav-user-drop.open { display:block; }
.nav-user-drop a { display:block; padding:0.6rem 1rem; color:rgba(255,255,255,0.8); font-size:0.82rem; border-radius:8px; text-decoration:none; transition:background 0.2s; cursor:pointer; }
.nav-user-drop a:hover { background:rgba(255,255,255,0.05); color:#fff; }
.nav-user-drop .drop-divider { height:1px; background:rgba(255,255,255,0.08); margin:0.3rem 0; }
.nav-user-drop .drop-signout { color:#ef4444; }
.nav-user-drop .drop-signout:hover { background:rgba(239,68,68,0.1); }

/* ═══════════════════════════════════════════
   STROKE COMMUNICATION TOOL
   ═══════════════════════════════════════════ */
.stroke-tool {
  padding: var(--section-gap) 0;
  background: linear-gradient(180deg, var(--surface-dark) 0%, #0a0812 100%);
  color: #fff;
  position: relative;
  overflow: hidden;
}
.stroke-tool::before {
  content: '';
  position: absolute; inset: 0;
  background:
    radial-gradient(ellipse 50% 40% at 25% 15%, rgba(196,112,122,0.06), transparent),
    radial-gradient(ellipse 40% 50% at 75% 85%, rgba(74,111,165,0.05), transparent),
    radial-gradient(ellipse 30% 30% at 50% 50%, rgba(90,158,111,0.03), transparent);
  pointer-events: none;
}
.stroke-tool-header { max-width: 700px; margin-bottom: 3rem; }

/* Device frame */
.stroke-device {
  background: #13111a;
  border: 2px solid rgba(255,255,255,0.06);
  border-radius: 28px;
  max-width: 980px;
  margin: 0 auto;
  position: relative;
  overflow: hidden;
  box-shadow:
    0 0 0 1px rgba(255,255,255,0.03),
    0 30px 100px rgba(0,0,0,0.6),
    inset 0 1px 0 rgba(255,255,255,0.04);
}

/* Top bar */
.stroke-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.9rem 2rem;
  border-bottom: 1px solid rgba(255,255,255,0.06);
  background: rgba(255,255,255,0.015);
}
.stroke-bar-left { display: flex; align-items: center; gap: 0.8rem; }
.stroke-bar-dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--med-green);
  box-shadow: 0 0 8px rgba(90,158,111,0.4);
  animation: strokeDotPulse 3s ease infinite;
}
@keyframes strokeDotPulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.5; }
}
.stroke-bar-title {
  font-family: var(--f-sans);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--med-blue-soft);
}
.stroke-bar-badges { display: flex; gap: 0.4rem; }
.stroke-badge {
  font-size: 0.55rem;
  font-weight: 700;
  padding: 0.2rem 0.55rem;
  border-radius: 100px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}
.stroke-badge-offline {
  background: rgba(90,158,111,0.12);
  color: var(--med-green);
  border: 1px solid rgba(90,158,111,0.2);
}
.stroke-badge-hipaa {
  background: rgba(74,111,165,0.12);
  color: var(--med-blue-soft);
  border: 1px solid rgba(74,111,165,0.2);
}

/* Sentence builder */
.stroke-sentence {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1rem 2rem;
  background: linear-gradient(135deg, rgba(74,111,165,0.06), rgba(90,158,111,0.04));
  border-bottom: 1px solid rgba(255,255,255,0.04);
  min-height: 62px;
}
.stroke-sentence-text {
  flex: 1;
  font-size: 1.1rem;
  font-weight: 600;
  color: rgba(255,255,255,0.25);
  line-height: 1.45;
  transition: color 0.3s;
}
.stroke-sentence-text.ss-has { color: #fff; }
.stroke-sentence-actions { display: flex; gap: 0.5rem; flex-shrink: 0; }
.stroke-btn-speak {
  font-family: var(--f-sans);
  font-size: 0.82rem;
  font-weight: 700;
  padding: 0.55rem 1.4rem;
  border-radius: 12px;
  border: none;
  background: var(--med-green);
  color: #fff;
  cursor: pointer;
  transition: all 0.25s;
  letter-spacing: 0.02em;
}
.stroke-btn-speak:hover:not(:disabled) {
  background: #5da87a;
  transform: translateY(-1px);
  box-shadow: 0 4px 20px rgba(90,158,111,0.3);
}
.stroke-btn-speak:disabled { opacity: 0.25; cursor: default; }
.stroke-btn-speak:active:not(:disabled) { transform: scale(0.96); }
.stroke-btn-speak.sbs-pulse {
  animation: speakPulse 0.5s ease;
}
@keyframes speakPulse {
  0%,100% { box-shadow: 0 0 0 0 rgba(90,158,111,0.4); }
  50% { box-shadow: 0 0 0 14px rgba(90,158,111,0); }
}
.stroke-btn-clear {
  font-family: var(--f-sans);
  font-size: 0.85rem;
  font-weight: 600;
  padding: 0.55rem 0.85rem;
  border-radius: 12px;
  border: 1px solid rgba(255,255,255,0.08);
  background: rgba(255,255,255,0.04);
  color: rgba(255,255,255,0.4);
  cursor: pointer;
  transition: all 0.2s;
}
.stroke-btn-clear:hover {
  border-color: rgba(239,68,68,0.3);
  background: rgba(239,68,68,0.06);
  color: #ef4444;
}

/* Category tabs */
.stroke-tabs {
  display: flex;
  gap: 0;
  padding: 0 0.5rem;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  border-bottom: 1px solid rgba(255,255,255,0.06);
  background: rgba(0,0,0,0.2);
}
.stroke-tabs::-webkit-scrollbar { display: none; }
.stroke-tab {
  font-family: var(--f-sans);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 0.85rem 1.1rem;
  color: rgba(255,255,255,0.3);
  background: transparent;
  border: none;
  border-bottom: 2px solid transparent;
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.25s;
}
.stroke-tab:hover { color: rgba(255,255,255,0.55); }
.stroke-tab.st-on {
  color: var(--med-blue-soft);
  border-bottom-color: var(--med-blue-soft);
}
.stroke-tab[data-cat="emergency"] { color: rgba(239,68,68,0.5); }
.stroke-tab[data-cat="emergency"].st-on {
  color: #ef4444;
  border-bottom-color: #ef4444;
}

/* Tile pages */
.stroke-pages { padding: 1.5rem 2rem; min-height: 340px; }
.stroke-page { display: none; }
.stroke-page.sp-on { display: block; animation: spIn 0.25s ease; }
@keyframes spIn {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Sub-headings inside pages */
.stroke-sub {
  font-size: 0.6rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.28);
  margin-bottom: 0.6rem;
  margin-top: 1.3rem;
}
.stroke-sub:first-child { margin-top: 0; }

/* Tile grid */
.stroke-tiles { display: flex; gap: 0.5rem; flex-wrap: wrap; margin-bottom: 0.4rem; }
.stroke-tile {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.3rem;
  min-width: 84px;
  min-height: 74px;
  padding: 0.65rem 0.6rem;
  border-radius: 14px;
  border: 2px solid rgba(255,255,255,0.06);
  background: rgba(255,255,255,0.025);
  cursor: pointer;
  transition: all 0.22s cubic-bezier(0.34,1.56,0.64,1);
  user-select: none;
  -webkit-user-select: none;
  -webkit-tap-highlight-color: transparent;
}
.stroke-tile:hover {
  border-color: rgba(255,255,255,0.14);
  background: rgba(255,255,255,0.05);
  transform: translateY(-2px);
}
.stroke-tile:active { transform: scale(0.92); }
.stroke-tile.st-sel {
  border-color: var(--med-blue-soft);
  background: rgba(74,111,165,0.14);
  box-shadow: 0 0 18px rgba(74,111,165,0.15);
  transform: scale(1.04);
}
.stroke-tile-ico { font-size: 1.55rem; line-height: 1; }
.stroke-tile-lbl {
  font-size: 0.62rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: rgba(255,255,255,0.6);
  text-align: center;
  line-height: 1.2;
}
.stroke-tile.st-sel .stroke-tile-lbl { color: #fff; }

/* Quick tiles — larger */
.stroke-page[data-page="quick"] .stroke-tile {
  min-width: 115px;
  min-height: 86px;
  padding: 0.9rem 0.8rem;
}
.stroke-page[data-page="quick"] .stroke-tile-ico { font-size: 1.8rem; }
.stroke-page[data-page="quick"] .stroke-tile-lbl { font-size: 0.7rem; }

/* YES tile */
.stroke-tile[data-msg="Yes"] { border-color: rgba(90,158,111,0.2); }
.stroke-tile[data-msg="Yes"]:hover, .stroke-tile[data-msg="Yes"].st-sel {
  border-color: var(--med-green); background: rgba(90,158,111,0.12);
  box-shadow: 0 0 20px rgba(90,158,111,0.2);
}
/* NO tile */
.stroke-tile[data-msg="No"] { border-color: rgba(239,68,68,0.15); }
.stroke-tile[data-msg="No"]:hover, .stroke-tile[data-msg="No"].st-sel {
  border-color: #ef4444; background: rgba(239,68,68,0.08);
  box-shadow: 0 0 20px rgba(239,68,68,0.15);
}

/* Pain scale colors */
.stroke-tile[data-pain="0"],.stroke-tile[data-pain="1"],.stroke-tile[data-pain="2"] { border-color: rgba(90,158,111,0.15); }
.stroke-tile[data-pain="0"].st-sel,.stroke-tile[data-pain="1"].st-sel,.stroke-tile[data-pain="2"].st-sel { border-color: var(--med-green); background: rgba(90,158,111,0.12); box-shadow: 0 0 18px rgba(90,158,111,0.15); }
.stroke-tile[data-pain="3"],.stroke-tile[data-pain="4"] { border-color: rgba(232,163,61,0.12); }
.stroke-tile[data-pain="3"].st-sel,.stroke-tile[data-pain="4"].st-sel { border-color: var(--amber); background: rgba(232,163,61,0.1); box-shadow: 0 0 18px rgba(232,163,61,0.12); }
.stroke-tile[data-pain="5"],.stroke-tile[data-pain="6"] { border-color: rgba(232,163,61,0.18); }
.stroke-tile[data-pain="5"].st-sel,.stroke-tile[data-pain="6"].st-sel { border-color: #e8a33d; background: rgba(232,163,61,0.12); box-shadow: 0 0 18px rgba(232,163,61,0.18); }
.stroke-tile[data-pain="7"],.stroke-tile[data-pain="8"] { border-color: rgba(196,112,122,0.18); }
.stroke-tile[data-pain="7"].st-sel,.stroke-tile[data-pain="8"].st-sel { border-color: var(--med-rose); background: rgba(196,112,122,0.12); box-shadow: 0 0 18px rgba(196,112,122,0.18); }
.stroke-tile[data-pain="9"],.stroke-tile[data-pain="10"] { border-color: rgba(239,68,68,0.18); }
.stroke-tile[data-pain="9"].st-sel,.stroke-tile[data-pain="10"].st-sel { border-color: #ef4444; background: rgba(239,68,68,0.12); box-shadow: 0 0 18px rgba(239,68,68,0.18); }

/* Emergency strip */
.stroke-emer {
  display: flex;
  gap: 0.5rem;
  padding: 0.9rem 2rem 1rem;
  border-top: 1px solid rgba(239,68,68,0.12);
  background: linear-gradient(180deg, rgba(239,68,68,0.03), rgba(239,68,68,0.06));
}
.stroke-emer-btn {
  flex: 1;
  font-family: var(--f-sans);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 0.75rem 0.8rem;
  border-radius: 12px;
  border: 2px solid rgba(239,68,68,0.25);
  background: rgba(239,68,68,0.06);
  color: #ef4444;
  cursor: pointer;
  transition: all 0.25s;
}
.stroke-emer-btn:hover {
  background: rgba(239,68,68,0.14);
  border-color: #ef4444;
  transform: translateY(-1px);
  box-shadow: 0 4px 20px rgba(239,68,68,0.2);
}
.stroke-emer-btn:active { transform: scale(0.96); }
.stroke-emer-btn.sef-flash { animation: emerFlash 0.6s ease; }
@keyframes emerFlash {
  0% { background: #ef4444; color: #fff; box-shadow: 0 0 30px rgba(239,68,68,0.5); }
  100% { background: rgba(239,68,68,0.06); color: #ef4444; box-shadow: none; }
}

/* Message history */
.stroke-hist {
  padding: 0.7rem 2rem 1rem;
  border-top: 1px solid rgba(255,255,255,0.04);
}
.stroke-hist-label {
  font-size: 0.55rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.18);
  margin-bottom: 0.4rem;
}
.stroke-hist-item {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.35rem 0;
  font-size: 0.78rem;
  color: rgba(255,255,255,0.3);
  border-bottom: 1px solid rgba(255,255,255,0.025);
}
.stroke-hist-item:last-child { border-bottom: none; }
.stroke-hist-time {
  font-size: 0.6rem;
  color: rgba(255,255,255,0.13);
  flex-shrink: 0;
  font-variant-numeric: tabular-nums;
}
.stroke-hist-msg { flex: 1; }
.stroke-hist-replay {
  font-size: 0.65rem;
  color: var(--med-blue-soft);
  cursor: pointer;
  opacity: 0.4;
  transition: opacity 0.2s;
}
.stroke-hist-replay:hover { opacity: 1; }
.stroke-hist-empty {
  font-size: 0.72rem;
  color: rgba(255,255,255,0.12);
  font-style: italic;
  padding: 0.2rem 0;
}

/* Spoken overlay */
.stroke-overlay {
  position: absolute;
  inset: 0;
  background: rgba(10,8,18,0.94);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 10;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s;
}
.stroke-overlay.so-show {
  opacity: 1;
  pointer-events: auto;
}
.stroke-overlay-ico { font-size: 3.5rem; animation: soBounce 0.8s ease infinite; }
@keyframes soBounce {
  0%,100% { transform: scale(1); }
  50% { transform: scale(1.18); }
}
.stroke-overlay-text {
  font-family: var(--f-serif);
  font-size: clamp(1.4rem, 3vw, 2.2rem);
  font-weight: 700;
  color: #fff;
  text-align: center;
  max-width: 80%;
  margin-top: 1.2rem;
  line-height: 1.4;
}
.stroke-overlay-sub {
  font-size: 0.78rem;
  color: rgba(255,255,255,0.3);
  margin-top: 0.8rem;
}
.stroke-overlay-emer .stroke-overlay-ico { font-size: 4rem; }
.stroke-overlay-emer .stroke-overlay-text { color: #ef4444; }
.stroke-overlay-emer { background: rgba(30,5,5,0.96); }

/* Responsive */
@media (max-width: 700px) {
  .stroke-bar { padding: 0.7rem 1.2rem; }
  .stroke-sentence { padding: 0.7rem 1.2rem; flex-wrap: wrap; gap: 0.6rem; }
  .stroke-sentence-text { font-size: 0.95rem; width: 100%; }
  .stroke-sentence-actions { width: 100%; justify-content: stretch; }
  .stroke-sentence-actions > * { flex: 1; text-align: center; }
  .stroke-pages { padding: 1rem 1.2rem; min-height: 280px; }
  .stroke-tab { padding: 0.7rem 0.7rem; font-size: 0.6rem; }
  .stroke-tile { min-width: 72px; min-height: 64px; padding: 0.5rem 0.4rem; }
  .stroke-tile-ico { font-size: 1.3rem; }
  .stroke-tile-lbl { font-size: 0.55rem; }
  .stroke-page[data-page="quick"] .stroke-tile { min-width: 95px; min-height: 72px; }
  .stroke-emer { padding: 0.7rem 1.2rem; flex-wrap: wrap; }
  .stroke-emer-btn { font-size: 0.7rem; }
  .stroke-hist { padding: 0.5rem 1.2rem; }
}

/* ═══════════════════════════════════════════
   BILATERAL CONVERSATION — HOSPITAL
   ═══════════════════════════════════════════ */
.med-bridge {
  padding: var(--section-gap) 0;
  background: var(--surface);
}
.med-blang-bar {
  margin-top: 2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  flex-wrap: wrap;
  background: #fff;
  border: 1px solid rgba(0,0,0,0.08);
  border-radius: 14px;
  padding: 1rem 1.5rem;
}
.med-blang-picker { display: flex; flex-direction: column; gap: 4px; }
.med-blang-label {
  font-size: 0.6rem; font-weight: 700; text-transform: uppercase;
  letter-spacing: 0.1em; color: var(--ink-muted);
}
.med-blang-select {
  font-family: var(--f-sans); font-size: 0.88rem; font-weight: 600;
  padding: 0.5rem 0.8rem; border: 2px solid rgba(0,0,0,0.08);
  border-radius: 10px; background: var(--surface); color: var(--ink);
  cursor: pointer; transition: border-color 0.2s; min-width: 170px;
}
.med-blang-select:focus { outline: none; border-color: var(--med-blue); }
.med-blang-arrow {
  font-size: 1.5rem; color: var(--med-blue); font-weight: 300; margin-top: 14px;
}
.med-blang-cross-badge {
  display: inline-block; font-size: 0.7rem;
  background: rgba(74,111,165,0.12); border: 1px solid rgba(74,111,165,0.25);
  border-radius: 6px; padding: 2px 8px; margin-left: 8px;
  vertical-align: middle; font-weight: 600;
}
.med-bridge-demo {
  margin-top: 1.5rem; display: grid;
  grid-template-columns: 1fr 1fr; gap: 2rem;
}
.med-bridge-panel {
  background: #fff; border-radius: 18px; padding: 2rem;
  border: 1px solid rgba(0,0,0,0.06);
}
.med-bridge-panel.med-dark-panel {
  background: var(--surface-dark); color: #fff;
  border-color: rgba(255,255,255,0.06);
}
.med-bridge-tag {
  font-size: 0.68rem; font-weight: 700; text-transform: uppercase;
  letter-spacing: 0.1em; color: var(--med-rose); margin-bottom: 0.8rem;
}
.med-dark-panel .med-bridge-tag { color: var(--med-blue-soft); }
.med-bridge-panel h4 { font-size: 1.1rem; margin-bottom: 1rem; }
.med-bridge-convo {
  display: flex; flex-direction: column; gap: 0.8rem; min-height: 320px;
}
.med-bridge-bubble {
  padding: 0.75rem 1rem; border-radius: 12px; font-size: 1rem;
  max-width: 85%; opacity: 0;
  animation: medBridgeFadeIn 0.4s ease forwards;
}
@keyframes medBridgeFadeIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}
.med-bubble-nurse {
  background: var(--med-blue-pale); align-self: flex-start;
  border-bottom-left-radius: 4px;
}
.med-dark-panel .med-bubble-nurse { background: rgba(74,111,165,0.15); }
.med-bubble-patient {
  align-self: flex-end; border-bottom-right-radius: 4px;
}
.med-bubble-old { background: #e8e4de; color: var(--ink-muted); }
.med-bridge-tiles {
  display: flex; gap: 0.5rem; flex-wrap: wrap;
  opacity: 0; animation: medBridgeFadeIn 0.4s ease forwards;
}
.med-bridge-tile {
  background: rgba(74,111,165,0.12); border: 1px solid rgba(74,111,165,0.25);
  border-radius: 8px; padding: 0.4rem 0.8rem; font-size: 0.78rem;
  font-weight: 600; color: var(--med-blue-soft); cursor: pointer;
  transition: all 0.2s ease;
}
.med-bridge-tile:hover {
  background: rgba(74,111,165,0.25); border-color: var(--med-blue);
  transform: translateY(-2px);
}
.med-bridge-tile:active { transform: scale(0.92); }
.med-bridge-tile.mbt-selected {
  background: var(--med-blue); color: #fff;
  border-color: var(--med-blue); transform: scale(1.05);
}
.med-bubble-spoken {
  background: linear-gradient(135deg, rgba(90,158,111,0.15), rgba(74,111,165,0.15));
  border: 1px solid rgba(90,158,111,0.25); color: #fff;
  font-weight: 600; align-self: flex-end; border-bottom-right-radius: 4px;
}
.med-bubble-spoken .mbs-speaker {
  display: inline-block; animation: poSpeakerPulse 0.6s ease 2;
}
.med-bubble-spoken .mbs-original {
  display: block; font-size: 0.72rem; color: rgba(255,255,255,0.45);
  margin-top: 3px; font-weight: 400; font-style: italic;
}
.med-bridge-typing {
  display: flex; align-items: center; gap: 4px;
  padding: 0.6rem 1rem; background: rgba(74,111,165,0.1);
  border-radius: 12px; align-self: flex-start;
  border-bottom-left-radius: 4px;
  opacity: 0; animation: medBridgeFadeIn 0.3s ease forwards;
}
.med-bridge-typing-dot {
  width: 6px; height: 6px; background: rgba(74,111,165,0.4);
  border-radius: 50%; animation: medTypingBounce 1.2s ease infinite;
}
.med-bridge-typing-dot:nth-child(2) { animation-delay: 0.15s; }
.med-bridge-typing-dot:nth-child(3) { animation-delay: 0.3s; }
@keyframes medTypingBounce {
  0%, 60%, 100% { transform: translateY(0); opacity: 0.3; }
  30% { transform: translateY(-4px); opacity: 1; }
}
.med-bridge-restart { margin-top: 1rem; text-align: center; }
.med-bridge-restart-btn {
  font-family: var(--f-sans); font-size: 0.78rem; font-weight: 600;
  color: var(--med-blue); background: rgba(74,111,165,0.08);
  border: 1px solid rgba(74,111,165,0.2); border-radius: 8px;
  padding: 0.5rem 1.2rem; cursor: pointer; transition: all 0.2s;
}
.med-bridge-restart-btn:hover { background: rgba(74,111,165,0.15); border-color: var(--med-blue); }
.med-blang-callout {
  margin-top: 2rem; display: flex; align-items: center;
  gap: 1.2rem; padding: 1.2rem 1.5rem;
  background: linear-gradient(135deg, rgba(74,111,165,0.06), rgba(90,158,111,0.06));
  border: 1px solid rgba(0,0,0,0.06); border-radius: 14px;
}
.med-blang-callout-num {
  font-family: var(--f-serif); font-size: 2rem; font-weight: 800;
  color: var(--med-blue); flex-shrink: 0;
}
.med-blang-callout-text {
  font-size: 1rem; color: var(--ink-muted); line-height: 1.6;
}

/* ═══════════════════════════════════════════
   COMPLIANCE & CERTIFICATION
   ═══════════════════════════════════════════ */
.compliance-section {
  padding: var(--section-gap) 0;
  background: #fff;
  position: relative;
}
.compliance-section::before {
  content: '';
  position: absolute; top: 0; left: 0; right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--med-blue-pale), transparent);
}
.compliance-header { max-width: 640px; margin-bottom: 1.5rem; }
.compliance-callout {
  background: var(--surface-dark);
  border-radius: 16px;
  padding: 2rem 2.5rem;
  margin-bottom: 3rem;
  display: flex;
  align-items: center;
  gap: 1.5rem;
  border: 1px solid rgba(255,255,255,0.05);
}
.compliance-callout-icon {
  font-size: 2.5rem;
  flex-shrink: 0;
}
.compliance-callout-text {
  font-family: var(--f-serif);
  font-size: clamp(1.3rem, 2.5vw, 1.8rem);
  font-weight: 700;
  color: #fff;
  line-height: 1.3;
}
.compliance-callout-text em {
  font-style: italic;
  color: var(--med-green);
}
.compliance-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.2rem;
}
.compliance-card {
  background: var(--surface);
  border: 1px solid rgba(0,0,0,0.06);
  border-radius: 14px;
  padding: 1.8rem;
  transition: all 0.3s;
  display: flex;
  gap: 1.2rem;
  align-items: flex-start;
}
.compliance-card:hover {
  box-shadow: 0 8px 30px rgba(0,0,0,0.06);
  transform: translateY(-2px);
}
.compliance-card-shield {
  width: 44px; height: 44px;
  border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.3rem;
  flex-shrink: 0;
  background: var(--med-blue-pale);
}
.compliance-card-shield.shield-green { background: var(--med-green-pale); }
.compliance-card-shield.shield-rose { background: var(--med-rose-pale); }
.compliance-card-shield.shield-warm { background: var(--med-warm-pale); }
.compliance-card h4 {
  font-size: 0.95rem; font-weight: 700;
  margin-bottom: 0.4rem; color: var(--ink);
  font-family: var(--f-sans);
}
.compliance-card p {
  font-size: 0.85rem; line-height: 1.65;
  color: var(--ink-muted);
}
.compliance-bottom {
  margin-top: 2.5rem;
  text-align: center;
  padding: 1.5rem;
  background: var(--med-blue-pale);
  border-radius: 14px;
  border: 1px solid rgba(74,111,165,0.1);
}
.compliance-bottom p {
  font-size: 0.92rem;
  color: var(--ink-soft);
  line-height: 1.7;
}
.compliance-bottom strong { color: var(--med-blue); }

/* Responsive for new sections */
@media (max-width: 768px) {
  .pain-tablet { padding: 1.2rem; border-radius: 20px; }
  .pain-tile { min-width: 64px; padding: 0.5rem 0.4rem; }
  .pain-tile-emoji { font-size: 1.3rem; }
  .pain-tile-label { font-size: 0.6rem; }
  .med-bridge-demo { grid-template-columns: 1fr; }
  .med-blang-bar { gap: 0.5rem; }
  .compliance-callout { flex-direction: column; text-align: center; padding: 1.5rem; }
  .compliance-grid { grid-template-columns: 1fr; }
}
/* ── Related Resources ── */
.related-resources{padding:5rem 0;background:var(--surface-warm, #f5f0e8)}
.related-resources .container{max-width:min(1120px,88vw);margin:0 auto;padding:0 1rem}
.related-title{font-family:var(--f-serif, 'Fraunces', serif);font-size:clamp(1.6rem,3vw,2.2rem);color:var(--ink, #1a1a2e);text-align:center;margin-bottom:0.5rem}
.related-subtitle{text-align:center;color:rgba(26,26,46,0.6);font-size:1rem;margin-bottom:2.5rem}
.related-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(280px,1fr));gap:1.5rem}
.related-card{background:#fff;border-radius:16px;padding:2rem;text-decoration:none;color:var(--ink, #1a1a2e);transition:transform 0.3s,box-shadow 0.3s;border:1px solid rgba(26,26,46,0.06)}
.related-card:hover{transform:translateY(-4px);box-shadow:0 12px 32px rgba(26,26,46,0.1)}
.related-card-emoji{font-size:2rem;margin-bottom:0.75rem}
.related-card-title{font-family:var(--f-serif, 'Fraunces', serif);font-size:1.15rem;font-weight:700;margin-bottom:0.5rem}
.related-card-desc{font-size:0.9rem;color:rgba(26,26,46,0.65);line-height:1.6;margin-bottom:1rem}
.related-card-link{font-size:0.85rem;font-weight:600;color:var(--amber, #e8a33d)}
/* Language Picker */
.lang-picker { position: relative; margin-left: 0.5rem; }
.lang-picker-btn { background: none; border: 1px solid rgba(255,255,255,0.2); color: #fff; padding: 0.35rem 0.7rem; border-radius: 8px; font-size: 0.75rem; cursor: pointer; font-family: var(--f-sans); display: flex; align-items: center; gap: 0.35rem; transition: all 0.3s; white-space: nowrap; }
.lang-picker-btn:hover { border-color: rgba(255,255,255,0.5); background: rgba(255,255,255,0.05); }
.lang-picker-dropdown { position: absolute; top: calc(100% + 0.5rem); right: 0; background: var(--surface-dark, #13111a); border: 1px solid rgba(255,255,255,0.12); border-radius: 14px; padding: 0.6rem; display: none; grid-template-columns: repeat(3, 1fr); gap: 0.25rem; box-shadow: 0 16px 48px rgba(0,0,0,0.6); z-index: 1001; min-width: 320px; max-height: 70vh; overflow-y: auto; }
.lang-picker-dropdown.open { display: grid; }
.lang-option { padding: 0.45rem 0.55rem; border-radius: 8px; font-size: 0.73rem; color: rgba(255,255,255,0.65); cursor: pointer; text-align: center; transition: all 0.2s; white-space: nowrap; }
.lang-option:hover { background: rgba(255,255,255,0.08); color: #fff; }
.lang-option.active { background: var(--amber, #e8a33d); color: var(--ink, #0d0b0e); font-weight: 700; }
@media (max-width: 768px) {
  .lang-picker { position: fixed; top: 0.8rem; right: 3.5rem; z-index: 1001; }
  .lang-picker-dropdown { min-width: 280px; right: -1rem; }
}
