/*
 * model5 institutional landing — DS §7.5 / §43.
 * Tokens from apps/data/systemdesign/model5-tokens.css. Do not invent colors.
 */
@font-face { font-family: "Sora"; font-style: normal; font-display: swap; font-weight: 600; src: url("../fonts/sora-latin-600-normal.woff2") format("woff2"); }
@font-face { font-family: "Sora"; font-style: normal; font-display: swap; font-weight: 700; src: url("../fonts/sora-latin-700-normal.woff2") format("woff2"); }
@font-face { font-family: "Inter"; font-style: normal; font-display: swap; font-weight: 400; src: url("../fonts/inter-latin-400-normal.woff2") format("woff2"); }
@font-face { font-family: "Inter"; font-style: normal; font-display: swap; font-weight: 500; src: url("../fonts/inter-latin-500-normal.woff2") format("woff2"); }
@font-face { font-family: "Inter"; font-style: normal; font-display: swap; font-weight: 600; src: url("../fonts/inter-latin-600-normal.woff2") format("woff2"); }

:root {
  --brand-primary: #2563eb;
  --brand-primary-hover: #1d4ed8;
  --brand-secondary: #14b8a6;
  --brand-accent: #8b5cf6;
  --navy: #0f172a;
  --navy-deep: #020617;
  --ink: #0f172a;
  --muted: #64748b;
  --strong: #334155;
  --line: #e2e8f0;
  --bg: #ffffff;
  --bg-alt: #f8fafc;
  --blue-50: #eff6ff;
  --blue-100: #dbeafe;
  --teal-50: #f0fdfa;
  --teal-100: #ccfbf1;
  --teal-700: #0f766e;
  --radius-md: 8px;
  --radius-lg: 12px;
  --radius-xl: 16px;
  --shadow-1: 0 1px 3px rgba(15, 23, 42, 0.08);
  --shadow-2: 0 8px 24px rgba(15, 23, 42, 0.1);
  --font-display: "Sora", ui-sans-serif, system-ui, sans-serif;
  --font-ui: "Inter", ui-sans-serif, system-ui, sans-serif;
  --gradient-brand: linear-gradient(135deg, #2563eb 0%, #14b8a6 100%);
  --max: 1120px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font-ui);
  font-size: 16px;
  color: var(--ink);
  background: var(--bg);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 {
  font-family: var(--font-display);
  line-height: 1.15;
  margin: 0 0 0.5rem;
  letter-spacing: -0.02em;
  text-wrap: balance;
}
h2 { font-size: clamp(1.875rem, 3.2vw, 2.75rem); font-weight: 700; }
h3 { font-size: 1.5rem; font-weight: 600; }
p { margin: 0 0 1rem; text-wrap: pretty; }
a { color: var(--brand-primary); }

.container { width: 100%; max-width: var(--max); margin: 0 auto; }

.topbar {
  position: sticky;
  top: 0;
  z-index: 10;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.topbar-inner {
  max-width: var(--max);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.85rem 1.25rem;
}

.brand { display: inline-flex; align-items: center; gap: 0.65rem; color: var(--ink); text-decoration: none; }
.brand-mark { display: inline-flex; width: 2.1rem; height: 1.6rem; }
.brand-mark svg { width: 100%; height: 100%; }
.brand-wordmark {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.15rem;
  letter-spacing: -0.045em;
  text-transform: lowercase;
  color: var(--navy);
}
.brand-wordmark .omni { color: var(--brand-primary); }
.brand-wordmark .clinic { color: var(--brand-secondary); }

.nav { display: flex; gap: 1.5rem; align-items: center; }
.nav a { color: var(--strong); text-decoration: none; font-weight: 500; font-size: 0.95rem; }
.nav a:hover { color: var(--brand-primary); }
.nav-cta {
  color: #fff !important;
  background: var(--brand-primary);
  border-radius: var(--radius-md);
  padding: 0.5rem 1rem;
  font-weight: 600 !important;
}
.nav-cta:hover { background: var(--brand-primary-hover); }

.nav-toggle {
  display: none;
  border: 1px solid var(--line);
  background: #fff;
  border-radius: var(--radius-md);
  padding: 0.45rem 0.85rem;
  min-height: 40px;
  font: inherit;
  font-weight: 500;
  cursor: pointer;
}

.hero {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  color: #fff;
  background: linear-gradient(160deg, var(--navy) 0%, #0b1a3f 55%, var(--navy-deep) 100%);
  padding: 6rem 1.25rem 4.5rem;
  text-align: center;
}
.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -2;
  background:
    radial-gradient(ellipse 50% 45% at 20% 15%, rgba(37, 99, 235, 0.45), transparent 60%),
    radial-gradient(ellipse 45% 40% at 85% 80%, rgba(20, 184, 166, 0.35), transparent 60%),
    radial-gradient(ellipse 30% 30% at 70% 20%, rgba(139, 92, 246, 0.22), transparent 60%);
  animation: aurora 18s ease-in-out infinite alternate;
}
.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.05) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: radial-gradient(ellipse 70% 60% at 50% 40%, #000 30%, transparent 100%);
  -webkit-mask-image: radial-gradient(ellipse 70% 60% at 50% 40%, #000 30%, transparent 100%);
}

.eyebrow {
  display: inline-block;
  color: #99f6e4;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  margin-bottom: 1.25rem;
}

.hero h1 {
  font-size: clamp(2.25rem, 5vw, 3.75rem);
  font-weight: 700;
  line-height: 1.06;
  max-width: 18ch;
  margin: 0 auto 1.25rem;
}
.hero h1 .text-gradient {
  background: linear-gradient(90deg, #60a5fa 0%, #2dd4bf 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.lead {
  color: rgba(255, 255, 255, 0.78);
  font-size: 1.125rem;
  line-height: 1.65;
  max-width: 58ch;
  margin: 0 auto 2.25rem;
}

.actions { display: flex; gap: 0.75rem; justify-content: center; flex-wrap: wrap; }

.button {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  min-height: 3rem;
  padding: 0 1.5rem;
  border: 0;
  border-radius: var(--radius-md);
  font: inherit;
  font-size: 1rem;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: transform 0.15s ease, background 0.15s ease, border-color 0.15s ease;
}
.button:hover { transform: translateY(-1px); }
.button svg { width: 1.125rem; height: 1.125rem; flex: none; }
.button.primary { background: var(--brand-primary); color: #fff; box-shadow: 0 8px 24px rgba(37, 99, 235, 0.35); }
.button.primary:hover { background: var(--brand-primary-hover); }
.button.ghost { border: 1px solid rgba(255, 255, 255, 0.25); color: #fff; background: transparent; }
.button.ghost:hover { border-color: rgba(255, 255, 255, 0.5); background: rgba(255, 255, 255, 0.06); }

.product-pills {
  display: flex;
  justify-content: center;
  gap: 0.75rem;
  flex-wrap: wrap;
  margin: 2.75rem auto 0;
}
.product-pills a {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  padding: 0.7rem 1rem;
  border-radius: 999px;
  text-decoration: none;
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.06);
  font-weight: 600;
}
.product-pills a:hover { background: rgba(255, 255, 255, 0.12); }
.dot { width: 0.55rem; height: 0.55rem; border-radius: 50%; flex: none; }
.dot.omni { background: #60a5fa; }
.dot.clinic { background: #2dd4bf; }

.section { max-width: var(--max); margin: 0 auto; padding: 5rem 1.25rem; }
.section.alt {
  max-width: none;
  background: var(--bg-alt);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.section.alt > .container { max-width: var(--max); }
.section-eyebrow {
  margin: 0 0 0.75rem;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--brand-primary);
}
.section-eyebrow.teal { color: var(--teal-700); }
.section-lead { color: var(--muted); font-size: 1.125rem; max-width: 60ch; margin-bottom: 2.5rem; }

.grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 1.25rem; }

.card {
  padding: 1.75rem;
  border: 1px solid var(--line);
  border-radius: var(--radius-xl);
  background: var(--bg);
  box-shadow: var(--shadow-1);
}
.card p { color: var(--muted); margin: 0; }
.card-icon {
  display: inline-flex;
  width: 2.5rem;
  height: 2.5rem;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  background: var(--blue-50);
  color: var(--brand-primary);
  margin-bottom: 1rem;
}
.card-icon.teal { background: var(--teal-50); color: var(--teal-700); }
.card-icon svg { width: 1.25rem; height: 1.25rem; }
.card h3 { font-size: 1.5rem; }
.card .tagline { color: var(--ink); font-size: 1.05rem; margin: 0.35rem 0 0.85rem; }

.product {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
  gap: 3rem;
  align-items: start;
}
.product-copy .section-lead { margin-bottom: 1.75rem; }
.feature-list { list-style: none; padding: 0; margin: 0 0 1.75rem; display: grid; gap: 0.85rem; }
.feature-list li { display: flex; gap: 0.75rem; align-items: flex-start; color: var(--strong); }
.feature-list svg { width: 1.15rem; height: 1.15rem; flex: none; margin-top: 0.2rem; }
.feature-list .omni { color: var(--brand-primary); }
.feature-list .clinic { color: var(--brand-secondary); }

.steps { list-style: none; padding: 0; margin: 0; display: grid; gap: 1.25rem; }
@media (min-width: 641px) {
  .product .steps { padding-right: 6.5rem; }
}
.steps li { display: flex; gap: 1rem; align-items: flex-start; }
.steps p { color: var(--muted); margin: 0; }
.step-number {
  flex: none;
  display: grid;
  place-items: center;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 50%;
  color: #fff;
  font-family: var(--font-display);
  font-weight: 700;
}
.step-number.omni { background: var(--brand-primary); }
.step-number.clinic { background: var(--brand-secondary); }

.cta {
  text-align: center;
  background: var(--gradient-brand);
  color: #fff;
  border-radius: var(--radius-xl);
  padding: 4rem 1.5rem;
  margin: 0 auto 3rem;
  max-width: var(--max);
}
.cta h2 { color: #fff; }
.cta .section-lead { color: rgba(255, 255, 255, 0.88); margin-left: auto; margin-right: auto; }
.cta .button.primary { background: #fff; color: var(--brand-primary); box-shadow: none; }
.cta .button.primary:hover { background: var(--blue-50); }
.cta .button.ghost { cursor: pointer; }
.cta-phone {
  display: inline-flex;
  align-items: center;
  color: rgba(255, 255, 255, 0.9);
  font-weight: 600;
}

.footer { border-top: 1px solid var(--line); padding: 2rem 1.25rem; color: var(--muted); font-size: 0.75rem; }
.footer-inner {
  max-width: var(--max);
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}
.footer p { margin: 0; }

.reveal { opacity: 0; transform: translateY(16px); transition: opacity 0.5s ease, transform 0.5s ease; }
.reveal.visible { opacity: 1; transform: none; }

@keyframes aurora {
  from { transform: translate3d(0, 0, 0) scale(1); }
  to { transform: translate3d(-2%, 2%, 0) scale(1.06); }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .hero::before { animation: none; }
  .button:hover { transform: none; }
}

.webchat-widget {
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 60;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 12px;
}
.webchat-launcher {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 52px;
  padding: 0 20px 0 16px;
  border: 0;
  border-radius: 999px;
  background: var(--brand-primary);
  color: #fff;
  font: inherit;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  box-shadow: 0 12px 32px rgba(37, 99, 235, 0.4);
}
.webchat-launcher:hover { background: var(--brand-primary-hover); transform: translateY(-1px); }
.webchat-launcher svg { width: 22px; height: 22px; }
.webchat-launcher[aria-expanded="true"] { background: var(--navy); box-shadow: var(--shadow-1); }
.webchat-panel {
  width: 380px;
  max-width: calc(100vw - 40px);
  height: 600px;
  max-height: calc(100dvh - 100px);
  display: flex;
  flex-direction: column;
  border-radius: var(--radius-xl);
  overflow: hidden;
  background: #fff;
  box-shadow: 0 24px 64px rgba(15, 23, 42, 0.28);
  border: 1px solid var(--line);
}
.webchat-panel[hidden] { display: none; }
.webchat-panel-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 8px 0 14px;
  height: 44px;
  background: var(--navy);
  color: #fff;
  font-size: 14px;
  font-weight: 600;
}
.webchat-panel-bar span { display: inline-flex; align-items: center; gap: 8px; }
.webchat-panel-bar svg { width: 18px; height: 18px; }
.webchat-panel-close {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: #fff;
  cursor: pointer;
}
.webchat-panel-close:hover { background: rgba(255, 255, 255, 0.12); }
.webchat-panel iframe { flex: 1 1 auto; width: 100%; border: 0; background: #fff; }

@media (max-width: 900px) {
  .product { grid-template-columns: 1fr; gap: 2rem; }
}

@media (max-width: 640px) {
  .webchat-widget { right: 16px; bottom: calc(16px + env(safe-area-inset-bottom)); }
  .webchat-launcher span { display: none; }
  .webchat-launcher { width: 56px; height: 56px; padding: 0; justify-content: center; }
  .webchat-widget.is-open { inset: 0; right: 0; bottom: 0; }
  .webchat-panel { width: 100vw; max-width: none; height: 100dvh; max-height: none; border-radius: 0; border: 0; }
  .webchat-panel-bar { padding-top: env(safe-area-inset-top); height: calc(44px + env(safe-area-inset-top)); }
  .webchat-widget.is-open .webchat-launcher { display: none; }
  body.webchat-open { overflow: hidden; }
}

@media (max-width: 720px) {
  .nav-toggle { display: inline-block; }
  .topbar { position: sticky; }
  .nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    background: #fff;
    border-bottom: 1px solid var(--line);
  }
  .nav.open { display: flex; }
  .nav a { padding: 0.9rem 1.25rem; border-top: 1px solid var(--line); }
  .nav-cta { border-radius: 0; }
  .hero { padding-top: 4rem; }
  .hero h1 { max-width: none; }
  .cta { border-radius: 0; margin-bottom: 0; }
}
