/* ============================================================
   Sania — Marketing site styles
   Built on the Sania Clinic Suite design tokens
   ============================================================ */

:root {
  --bg: oklch(98.5% 0.004 240);
  --surface: #ffffff;
  --surface-2: oklch(97% 0.005 240);
  --border: oklch(92% 0.008 240);
  --border-strong: oklch(88% 0.01 240);
  --text: oklch(22% 0.02 250);
  --text-2: oklch(45% 0.015 250);
  --text-3: oklch(62% 0.012 250);

  --ink: oklch(22% 0.015 240);
  --ink-2: oklch(17% 0.015 240);
  --ink-3: oklch(13% 0.015 240);
  --ink-text: oklch(72% 0.012 240);

  --brand: oklch(70% 0.16 45);
  --brand-2: oklch(65% 0.17 40);
  --brand-soft: oklch(95% 0.04 45);
  --brand-tint: oklch(97% 0.02 45);

  --accent: oklch(62% 0.11 195);
  --accent-2: oklch(55% 0.12 200);
  --accent-soft: oklch(95% 0.03 195);

  --success: oklch(62% 0.14 150);
  --success-soft: oklch(95% 0.05 150);
  --warn: oklch(72% 0.14 75);
  --danger: oklch(60% 0.19 25);

  --radius: 14px;
  --radius-sm: 10px;
  --radius-lg: 22px;

  --shadow-sm: 0 1px 2px oklch(20% 0.02 240 / 0.05), 0 1px 1px oklch(20% 0.02 240 / 0.03);
  --shadow: 0 1px 2px oklch(20% 0.02 240 / 0.05), 0 12px 28px -10px oklch(20% 0.02 240 / 0.10);
  --shadow-lg: 0 2px 4px oklch(20% 0.02 240 / 0.05), 0 32px 60px -16px oklch(20% 0.02 240 / 0.22);
  --shadow-brand: 0 1px 2px oklch(70% 0.16 45 / 0.3), 0 18px 40px -14px oklch(70% 0.16 45 / 0.5);

  --font-sans: 'DM Sans', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', Helvetica, Arial, sans-serif;
  --font-mono: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, monospace;

  --maxw: 1180px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-sans);
  font-feature-settings: 'ss01', 'cv11';
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  line-height: 1.55;
  overflow-x: hidden;
}
body.nav-open { overflow: hidden; }
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
::selection { background: var(--brand-soft); }

::-webkit-scrollbar { width: 11px; height: 11px; }
::-webkit-scrollbar-thumb { background: var(--border-strong); border-radius: 99px; border: 3px solid var(--bg); }
::-webkit-scrollbar-thumb:hover { background: var(--text-3); }

.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 28px; }

/* ============== HELPERS ============== */
.eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 12px; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--brand-2);
}
.eyebrow::before { content: ''; width: 18px; height: 1.5px; background: var(--brand); border-radius: 2px; }
.eyebrow.center { justify-content: center; }
.eyebrow.on-ink { color: oklch(78% 0.09 45); }

.mono { font-family: var(--font-mono); font-feature-settings: 'tnum'; }

/* ============== BUTTONS ============== */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 12px 20px;
  border-radius: 11px;
  font-size: 15px; font-weight: 600;
  border: 1px solid transparent;
  transition: transform 0.12s, background 0.15s, box-shadow 0.15s, border-color 0.15s;
  white-space: nowrap; cursor: pointer;
}
.btn:active { transform: translateY(1px); }
.btn-brand { background: var(--brand); color: #fff; box-shadow: var(--shadow-brand); }
.btn-brand:hover { background: var(--brand-2); }
.btn-ink { background: var(--text); color: #fff; }
.btn-ink:hover { background: oklch(15% 0.015 240); }
.btn-ghost { background: var(--surface); color: var(--text); border-color: var(--border-strong); }
.btn-ghost:hover { background: var(--surface-2); border-color: var(--text-3); }
.btn-ghost-ink { background: transparent; color: #fff; border-color: oklch(40% 0.02 240); }
.btn-ghost-ink:hover { border-color: oklch(60% 0.02 240); background: oklch(100% 0 0 / 0.04); }
.btn-lg { padding: 15px 26px; font-size: 16px; border-radius: 13px; }
.btn-block { width: 100%; }

/* ============== NAV ============== */
.nav {
  position: sticky; top: 0; z-index: 50;
  background: oklch(98.5% 0.004 240 / 0.82);
  backdrop-filter: blur(14px) saturate(140%);
  border-bottom: 1px solid var(--border);
}
.nav-inner { display: flex; align-items: center; gap: 28px; height: 70px; }
.brand { display: flex; align-items: center; gap: 11px; }
.brand-logo {
  width: 38px; height: 38px; border-radius: 11px;
  background: linear-gradient(135deg, var(--brand) 0%, var(--brand-2) 100%);
  display: grid; place-items: center; color: #fff; font-weight: 700; font-size: 19px;
  box-shadow: 0 6px 16px -6px oklch(70% 0.16 45 / 0.6);
}
.brand-name { font-weight: 700; font-size: 19px; letter-spacing: -0.01em; line-height: 1; }
.brand-name .sub { display: block; font-size: 9.5px; letter-spacing: 0.16em; color: var(--text-3); font-weight: 600; margin-top: 3px; }
.nav-links { display: flex; align-items: center; gap: 6px; margin-left: 8px; }
.nav-links a {
  padding: 9px 14px; border-radius: 9px; font-size: 14.5px; font-weight: 500; color: var(--text-2);
  transition: background 0.12s, color 0.12s;
}
.nav-links a:hover { background: var(--surface-2); color: var(--text); }
.nav-cta { margin-left: auto; display: flex; align-items: center; gap: 10px; }
.nav-toggle { display: none; }

/* ============== HERO ============== */
.hero { position: relative; overflow: hidden; padding: 76px 0 64px; }
.hero-mock { position: relative; }
.hero-phone { position: absolute; right: -22px; bottom: -46px; width: 188px; z-index: 4; }

/* ============== REAL SCREENSHOT FRAMES ============== */
.mock .shot-img { display: block; width: 100%; height: auto; }
.device {
  background: var(--ink-3); border: 1px solid oklch(32% 0.012 240);
  border-radius: 40px; padding: 9px; box-shadow: var(--shadow-lg);
}
.device img { display: block; width: 100%; height: auto; border-radius: 32px; }
.hero-phone .device { border-radius: 32px; padding: 7px; box-shadow: 0 40px 70px -20px oklch(20% 0.02 240 / 0.45); }
.hero-phone .device img { border-radius: 26px; }
.app-device { max-width: 300px; margin: 0 auto; }
.app-device.doc { max-width: 282px; }
.hero::before {
  content: ''; position: absolute; inset: 0; z-index: -1;
  background:
    radial-gradient(60% 50% at 78% 8%, oklch(95% 0.04 45 / 0.9), transparent 70%),
    radial-gradient(50% 45% at 12% 30%, oklch(95% 0.03 195 / 0.7), transparent 70%);
}
.hero-grid { display: grid; grid-template-columns: 1.02fr 1.18fr; gap: 56px; align-items: center; }
.hero h1 {
  font-size: clamp(38px, 5.2vw, 60px); line-height: 1.04; letter-spacing: -0.03em;
  margin: 20px 0 0; font-weight: 700; text-wrap: balance;
}
.hero h1 em { font-style: normal; color: var(--brand-2); }
.hero-lead { font-size: 19px; color: var(--text-2); margin: 22px 0 0; max-width: 30em; text-wrap: pretty; }
.hero-actions { display: flex; gap: 12px; margin-top: 32px; flex-wrap: wrap; }
.hero-trust { display: flex; gap: 24px; margin-top: 30px; flex-wrap: wrap; }
.hero-trust .item { display: flex; align-items: center; gap: 9px; font-size: 13.5px; color: var(--text-2); font-weight: 500; }
.hero-trust .item svg { color: var(--success); flex: 0 0 auto; }

.pill {
  display: inline-flex; align-items: center; gap: 9px;
  padding: 6px 12px 6px 6px; border-radius: 999px;
  background: var(--surface); border: 1px solid var(--border);
  font-size: 13px; font-weight: 500; color: var(--text-2);
  box-shadow: var(--shadow-sm);
}
.pill .tag {
  font-size: 11px; font-weight: 700; letter-spacing: 0.03em;
  background: var(--brand-soft); color: var(--brand-2);
  padding: 3px 9px; border-radius: 999px;
}

/* ============== SECTION SHELLS ============== */
section { position: relative; }
.section { padding: 92px 0; }
.section-head { max-width: 680px; margin: 0 auto 56px; text-align: center; }
.section-head.left { margin-left: 0; text-align: left; }
.section-head h2 {
  font-size: clamp(30px, 3.6vw, 42px); line-height: 1.08; letter-spacing: -0.025em;
  margin: 16px 0 0; font-weight: 700; text-wrap: balance;
}
.section-head p { font-size: 18px; color: var(--text-2); margin: 16px 0 0; text-wrap: pretty; }

/* ============== LOGO / TRUST STRIP ============== */
.strip { border-block: 1px solid var(--border); background: var(--surface); }
.strip-inner { display: flex; align-items: center; justify-content: space-between; gap: 32px; padding: 26px 0; flex-wrap: wrap; }
.strip-label { font-size: 12.5px; font-weight: 600; letter-spacing: 0.04em; color: var(--text-3); text-transform: uppercase; }
.strip-stats { display: flex; gap: 48px; flex-wrap: wrap; }
.strip-stat .n { font-size: 27px; font-weight: 700; letter-spacing: -0.02em; }
.strip-stat .l { font-size: 13px; color: var(--text-2); margin-top: 1px; }

/* ============== TWO APPS ============== */
.apps { background: var(--surface); border-block: 1px solid var(--border); }
.app-row { display: grid; grid-template-columns: 1fr 1fr; gap: 60px; align-items: center; }
.app-row + .app-row { margin-top: 96px; }
.app-row.flip .app-copy { order: 2; }
.app-tag {
  display: inline-flex; align-items: center; gap: 8px; padding: 6px 13px; border-radius: 999px;
  font-size: 12.5px; font-weight: 700; letter-spacing: 0.02em;
}
.app-tag.doc { background: var(--ink); color: #fff; }
.app-tag.pat { background: var(--accent-soft); color: var(--accent-2); }
.app-copy h3 { font-size: clamp(26px, 3vw, 34px); letter-spacing: -0.02em; margin: 18px 0 0; line-height: 1.1; }
.app-copy > p { font-size: 17px; color: var(--text-2); margin: 14px 0 0; text-wrap: pretty; }
.app-list { list-style: none; padding: 0; margin: 26px 0 0; display: grid; gap: 14px; }
.app-list li { display: flex; gap: 13px; align-items: flex-start; }
.app-list .ic {
  width: 30px; height: 30px; flex: 0 0 30px; border-radius: 9px; display: grid; place-items: center;
  background: var(--brand-soft); color: var(--brand-2);
}
.app-list.teal .ic { background: var(--accent-soft); color: var(--accent-2); }
.app-list .t { font-weight: 600; font-size: 15.5px; }
.app-list .d { font-size: 14px; color: var(--text-2); margin-top: 1px; }

/* ============== FEATURE GRID ============== */
.feat-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.feat {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 26px; box-shadow: var(--shadow-sm); transition: transform 0.15s, box-shadow 0.15s, border-color 0.15s;
}
.feat:hover { transform: translateY(-3px); box-shadow: var(--shadow); border-color: var(--border-strong); }
.feat .ic {
  width: 46px; height: 46px; border-radius: 12px; display: grid; place-items: center;
  background: var(--surface-2); color: var(--text); margin-bottom: 18px; border: 1px solid var(--border);
}
.feat.brand .ic { background: var(--brand-soft); color: var(--brand-2); border-color: transparent; }
.feat.teal .ic { background: var(--accent-soft); color: var(--accent-2); border-color: transparent; }
.feat h3 { font-size: 17px; margin: 0; letter-spacing: -0.01em; }
.feat p { font-size: 14.5px; color: var(--text-2); margin: 9px 0 0; text-wrap: pretty; }

/* ============== SANIA IA ============== */
.ia { background: var(--ink-2); color: oklch(90% 0.01 240); overflow: hidden; }
.ia::before {
  content: ''; position: absolute; inset: 0;
  background: radial-gradient(50% 60% at 80% 30%, oklch(70% 0.16 45 / 0.20), transparent 70%);
}
.ia .wrap { position: relative; }
.ia-grid { display: grid; grid-template-columns: 1.05fr 0.95fr; gap: 60px; align-items: center; }
.ia h2 { color: #fff; font-size: clamp(30px, 3.6vw, 42px); letter-spacing: -0.025em; line-height: 1.08; margin: 16px 0 0; }
.ia p.lead { font-size: 18px; color: oklch(78% 0.012 240); margin: 18px 0 0; text-wrap: pretty; }
.ia-points { list-style: none; padding: 0; margin: 28px 0 0; display: grid; gap: 16px; }
.ia-points li { display: flex; gap: 13px; align-items: flex-start; font-size: 15px; color: oklch(85% 0.012 240); }
.ia-points .ic { width: 26px; height: 26px; flex: 0 0 26px; border-radius: 8px; display: grid; place-items: center; background: oklch(70% 0.16 45 / 0.18); color: oklch(80% 0.1 45); }

/* chat mock */
.chat {
  background: var(--ink-3); border: 1px solid oklch(30% 0.015 240); border-radius: var(--radius-lg);
  padding: 18px; box-shadow: var(--shadow-lg);
}
.chat-head { display: flex; align-items: center; gap: 11px; padding: 4px 6px 16px; border-bottom: 1px solid oklch(28% 0.015 240); }
.chat-av { width: 34px; height: 34px; border-radius: 10px; background: linear-gradient(135deg, var(--accent), oklch(48% 0.12 220)); display: grid; place-items: center; color: #fff; }
.chat-head .who .n { font-weight: 700; color: #fff; font-size: 14px; }
.chat-head .who .s { font-size: 12px; color: oklch(70% 0.012 240); }
.chat-body { padding: 16px 4px 6px; display: grid; gap: 12px; }
.bubble { max-width: 86%; padding: 11px 14px; border-radius: 14px; font-size: 13.5px; line-height: 1.5; }
.bubble.bot { background: oklch(26% 0.015 240); color: oklch(90% 0.01 240); border-bottom-left-radius: 4px; }
.bubble.user { background: var(--brand); color: #fff; margin-left: auto; border-bottom-right-radius: 4px; }
.chat-quick { display: flex; flex-wrap: wrap; gap: 7px; padding: 12px 4px 4px; }
.chat-quick span { font-size: 12px; padding: 6px 11px; border-radius: 999px; background: oklch(26% 0.015 240); color: oklch(80% 0.012 240); border: 1px solid oklch(32% 0.015 240); }

/* ============== SECURITY ============== */
.sec-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-top: 12px; }
.sec {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 22px;
}
.sec .ic { width: 40px; height: 40px; border-radius: 11px; display: grid; place-items: center; background: var(--success-soft); color: var(--success); margin-bottom: 14px; }
.sec h3 { font-size: 15.5px; margin: 0; }
.sec p { font-size: 13.5px; color: var(--text-2); margin: 7px 0 0; }

/* ============== CTA ============== */
.cta { padding: 96px 0; }
.cta-card {
  background: linear-gradient(150deg, var(--ink) 0%, var(--ink-3) 100%);
  border-radius: 28px; padding: 64px 56px; text-align: center; position: relative; overflow: hidden;
  box-shadow: var(--shadow-lg);
}
.cta-card::before {
  content: ''; position: absolute; inset: 0;
  background: radial-gradient(50% 80% at 50% -10%, oklch(70% 0.16 45 / 0.3), transparent 65%);
}
.cta-card > * { position: relative; }
.cta-card h2 { color: #fff; font-size: clamp(30px, 4vw, 46px); letter-spacing: -0.03em; line-height: 1.05; margin: 0; text-wrap: balance; }
.cta-card p { color: oklch(78% 0.012 240); font-size: 18px; margin: 18px auto 0; max-width: 34em; }
.cta-actions { display: flex; gap: 13px; justify-content: center; margin-top: 34px; flex-wrap: wrap; }

/* ============== FOOTER ============== */
.footer { background: var(--surface); border-top: 1px solid var(--border); padding: 64px 0 36px; }
.footer-grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1fr; gap: 40px; }
.footer .brand { margin-bottom: 16px; }
.footer-blurb { font-size: 14px; color: var(--text-2); max-width: 28em; }
.footer h4 { font-size: 12px; text-transform: uppercase; letter-spacing: 0.1em; color: var(--text-3); margin: 0 0 16px; font-weight: 600; }
.footer ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 11px; }
.footer ul a { font-size: 14.5px; color: var(--text-2); }
.footer ul a:hover { color: var(--text); }
.footer-bottom {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  margin-top: 48px; padding-top: 26px; border-top: 1px solid var(--border); flex-wrap: wrap;
}
.footer-bottom .copy { font-size: 13px; color: var(--text-3); }
.footer-bottom .legal { display: flex; gap: 20px; }
.footer-bottom .legal a { font-size: 13px; color: var(--text-3); }
.footer-bottom .legal a:hover { color: var(--text); }

/* ============== APP MOCKUP (CSS recreation) ============== */
.mock {
  background: var(--surface); border: 1px solid var(--border-strong); border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg); overflow: hidden;
}
.mock-bar { display: flex; align-items: center; gap: 7px; padding: 12px 16px; background: var(--surface-2); border-bottom: 1px solid var(--border); }
.mock-bar .dots { display: flex; gap: 6px; }
.mock-bar .dots i { width: 11px; height: 11px; border-radius: 50%; display: block; }
.mock-bar .dots i:nth-child(1) { background: oklch(72% 0.14 25); }
.mock-bar .dots i:nth-child(2) { background: oklch(82% 0.12 85); }
.mock-bar .dots i:nth-child(3) { background: oklch(75% 0.14 150); }
.mock-bar .addr { margin-left: 10px; flex: 1; background: var(--surface); border: 1px solid var(--border); border-radius: 7px; padding: 5px 11px; font-size: 11.5px; color: var(--text-3); font-family: var(--font-mono); }
.mock-os { display: grid; grid-template-columns: 168px 1fr; min-height: 388px; }

.m-side { background: var(--ink); padding: 14px 11px; display: flex; flex-direction: column; gap: 3px; }
.m-side .m-brand { display: flex; align-items: center; gap: 9px; padding: 4px 6px 14px; }
.m-side .m-brand .lg { width: 28px; height: 28px; border-radius: 8px; background: linear-gradient(135deg, var(--brand), var(--brand-2)); display: grid; place-items: center; color: #fff; font-weight: 700; font-size: 13px; }
.m-side .m-brand .nm { color: #fff; font-weight: 700; font-size: 14px; }
.m-side .m-brand .nm small { display: block; font-size: 7px; letter-spacing: 0.14em; color: var(--ink-text); font-weight: 600; }
.m-item { display: flex; align-items: center; gap: 9px; padding: 8px 9px; border-radius: 8px; color: var(--ink-text); font-size: 12px; font-weight: 500; }
.m-item.on { background: oklch(32% 0.025 240); color: #fff; position: relative; }
.m-item.on::before { content: ''; position: absolute; left: -11px; top: 8px; bottom: 8px; width: 3px; background: var(--brand); border-radius: 0 3px 3px 0; }
.m-item svg { width: 14px; height: 14px; opacity: 0.9; flex: 0 0 14px; }
.m-lbl { font-size: 8px; text-transform: uppercase; letter-spacing: 0.1em; color: oklch(52% 0.012 240); padding: 10px 9px 4px; font-weight: 600; }

.m-main { background: var(--bg); padding: 16px; overflow: hidden; }
.m-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; }
.m-top .h { font-size: 15px; font-weight: 700; letter-spacing: -0.01em; }
.m-top .h small { display: block; font-size: 9.5px; color: var(--text-3); font-weight: 500; letter-spacing: 0.04em; text-transform: uppercase; margin-bottom: 2px; }
.m-cta { background: var(--brand); color: #fff; font-size: 10.5px; font-weight: 600; padding: 6px 11px; border-radius: 8px; }
.m-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 9px; margin-bottom: 12px; }
.m-stat { background: var(--surface); border: 1px solid var(--border); border-radius: 10px; padding: 11px; }
.m-stat .l { font-size: 9px; color: var(--text-2); display: flex; align-items: center; gap: 5px; }
.m-stat .l .b { width: 16px; height: 16px; border-radius: 5px; background: var(--surface-2); display: grid; place-items: center; }
.m-stat .v { font-size: 19px; font-weight: 700; letter-spacing: -0.02em; margin-top: 5px; }
.m-stat .dl { font-size: 9px; font-weight: 600; color: var(--success); margin-top: 1px; }
.m-card { background: var(--surface); border: 1px solid var(--border); border-radius: 11px; overflow: hidden; }
.m-card .hd { display: flex; align-items: center; justify-content: space-between; padding: 11px 13px; border-bottom: 1px solid var(--border); }
.m-card .hd .t { font-size: 12px; font-weight: 700; }
.m-card .hd .x { font-size: 9px; color: var(--text-3); }
.m-agenda { padding: 4px 0; }
.m-arow { display: grid; grid-template-columns: 42px 1fr auto; gap: 10px; align-items: center; padding: 9px 13px; border-bottom: 1px solid var(--border); }
.m-arow:last-child { border-bottom: 0; }
.m-arow .tm { font-family: var(--font-mono); font-size: 10.5px; font-weight: 600; }
.m-av { width: 26px; height: 26px; border-radius: 8px; display: grid; place-items: center; color: #fff; font-size: 10px; font-weight: 700; }
.m-pt { display: flex; align-items: center; gap: 8px; }
.m-pt .nm { font-size: 11.5px; font-weight: 600; }
.m-pt .rs { font-size: 9px; color: var(--text-3); }
.m-bdg { font-size: 8.5px; font-weight: 700; padding: 3px 7px; border-radius: 999px; }
.m-bdg.ok { background: var(--success-soft); color: var(--success); }
.m-bdg.wn { background: oklch(96% 0.06 80); color: oklch(50% 0.12 75); }

.av-1 { background: linear-gradient(135deg, oklch(60% 0.15 30), oklch(55% 0.17 20)); }
.av-2 { background: linear-gradient(135deg, oklch(60% 0.13 240), oklch(55% 0.15 260)); }
.av-3 { background: linear-gradient(135deg, oklch(60% 0.13 150), oklch(55% 0.15 170)); }
.av-4 { background: linear-gradient(135deg, oklch(60% 0.14 290), oklch(55% 0.16 310)); }

/* phone mockup */
.phone {
  width: 290px; border-radius: 42px; background: var(--ink-3); padding: 11px;
  box-shadow: var(--shadow-lg); border: 1px solid oklch(30% 0.01 240); margin: 0 auto;
}
.phone-screen { border-radius: 32px; overflow: hidden; background: var(--bg); position: relative; }
.phone-notch { position: absolute; top: 9px; left: 50%; transform: translateX(-50%); width: 92px; height: 22px; background: var(--ink-3); border-radius: 99px; z-index: 5; }
.ph-status { display: flex; align-items: center; justify-content: space-between; padding: 11px 22px 6px; font-size: 11px; font-weight: 700; font-family: var(--font-mono); }
.ph-head { padding: 8px 18px 14px; }
.ph-head .greet { font-size: 11px; color: var(--text-3); }
.ph-head .nm { font-size: 17px; font-weight: 700; letter-spacing: -0.01em; }
.ph-body { padding: 0 14px 18px; display: grid; gap: 11px; }
.ph-card { background: var(--surface); border: 1px solid var(--border); border-radius: 14px; padding: 14px; box-shadow: var(--shadow-sm); }
.ph-next { background: linear-gradient(150deg, var(--accent), oklch(48% 0.12 215)); color: #fff; border: 0; }
.ph-next .lbl { font-size: 9.5px; text-transform: uppercase; letter-spacing: 0.1em; opacity: 0.85; font-weight: 600; }
.ph-next .when { font-size: 18px; font-weight: 700; margin-top: 5px; }
.ph-next .doc { font-size: 12px; opacity: 0.9; margin-top: 2px; }
.ph-next .tele { display: inline-flex; align-items: center; gap: 6px; margin-top: 11px; font-size: 11px; font-weight: 600; background: oklch(100% 0 0 / 0.18); padding: 6px 11px; border-radius: 8px; }
.ph-row { display: flex; align-items: center; gap: 11px; }
.ph-ic { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; flex: 0 0 34px; }
.ph-ic.rx { background: var(--brand-soft); color: var(--brand-2); }
.ph-ic.fl { background: var(--accent-soft); color: var(--accent-2); }
.ph-ic.wl { background: var(--success-soft); color: var(--success); }
.ph-t { font-size: 13px; font-weight: 600; }
.ph-d { font-size: 11px; color: var(--text-3); }
.ph-tab { display: flex; justify-content: space-around; padding: 11px 0 16px; border-top: 1px solid var(--border); background: var(--surface); }
.ph-tab i { width: 20px; height: 20px; display: grid; place-items: center; color: var(--text-3); }
.ph-tab i.on { color: var(--brand-2); }

.float-pill {
  position: absolute; display: flex; align-items: center; gap: 9px;
  background: var(--surface); border: 1px solid var(--border); border-radius: 13px;
  padding: 10px 13px; box-shadow: var(--shadow-lg); font-size: 12.5px; font-weight: 600;
}
.float-pill .ic { width: 28px; height: 28px; border-radius: 8px; display: grid; place-items: center; color: #fff; flex: 0 0 28px; }

/* ============== LEGAL PAGES ============== */
.legal-hero { background: var(--surface); border-bottom: 1px solid var(--border); padding: 64px 0 48px; }
.legal-hero h1 { font-size: clamp(32px, 4.4vw, 50px); letter-spacing: -0.03em; margin: 18px 0 0; line-height: 1.05; }
.legal-hero p { font-size: 17px; color: var(--text-2); margin: 14px 0 0; max-width: 44em; }
.legal-hero .updated { font-size: 13px; color: var(--text-3); margin-top: 20px; display: inline-flex; align-items: center; gap: 8px; }
.legal-layout { display: grid; grid-template-columns: 240px 1fr; gap: 56px; padding: 56px 0 90px; align-items: start; }
.toc { position: sticky; top: 96px; }
.toc h4 { font-size: 11px; text-transform: uppercase; letter-spacing: 0.1em; color: var(--text-3); margin: 0 0 14px; font-weight: 600; }
.toc ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 3px; }
.toc a { display: block; padding: 8px 12px; border-radius: 8px; font-size: 13.5px; color: var(--text-2); font-weight: 500; border-left: 2px solid transparent; }
.toc a:hover { background: var(--surface-2); color: var(--text); }
.legal-body { max-width: 720px; }
.legal-body h2 {
  font-size: 23px; letter-spacing: -0.02em; margin: 0 0 16px; scroll-margin-top: 96px;
  display: flex; align-items: baseline; gap: 12px;
}
.legal-body h2 .num { font-family: var(--font-mono); font-size: 14px; color: var(--brand-2); font-weight: 600; }
.legal-body section + section { margin-top: 48px; padding-top: 48px; border-top: 1px solid var(--border); }
.legal-body p { font-size: 15.5px; color: var(--text-2); margin: 0 0 14px; }
.legal-body ul { margin: 0 0 14px; padding-left: 4px; list-style: none; display: grid; gap: 10px; }
.legal-body ul li { position: relative; padding-left: 24px; font-size: 15px; color: var(--text-2); }
.legal-body ul li::before { content: ''; position: absolute; left: 4px; top: 9px; width: 6px; height: 6px; border-radius: 50%; background: var(--brand); }
.legal-body strong { color: var(--text); font-weight: 600; }
.legal-callout {
  background: var(--brand-tint); border: 1px solid var(--brand-soft); border-radius: var(--radius);
  padding: 20px 22px; margin: 22px 0; display: flex; gap: 14px;
}
.legal-callout .ic { width: 36px; height: 36px; flex: 0 0 36px; border-radius: 10px; background: var(--brand-soft); color: var(--brand-2); display: grid; place-items: center; }
.legal-callout p { margin: 0; font-size: 14.5px; }
.legal-callout p strong { color: var(--brand-2); }

/* ============== SANIA IA — capability cards ============== */
.ia-caps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin: 4px 0 14px; }
.ia-cap { background: oklch(26% 0.015 240); border: 1px solid oklch(31% 0.015 240); border-radius: var(--radius); padding: 24px; transition: transform 0.15s, border-color 0.15s; }
.ia-cap:hover { transform: translateY(-3px); border-color: oklch(45% 0.04 45); }
.ia-cap .ic { width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; background: oklch(70% 0.16 45 / 0.16); color: oklch(82% 0.1 45); margin-bottom: 16px; }
.ia-cap.teal .ic { background: oklch(62% 0.11 195 / 0.18); color: oklch(78% 0.09 195); }
.ia-cap h3 { color: #fff; font-size: 16px; margin: 0; letter-spacing: -0.01em; }
.ia-cap p { color: oklch(72% 0.012 240); font-size: 13.5px; margin: 9px 0 0; line-height: 1.55; }
.ia .section-head h2 { color: #fff; }
.ia .section-head p { color: oklch(78% 0.012 240); }
.ia-divider { height: 1px; background: oklch(30% 0.015 240); margin: 56px 0; }

/* ============== NUESTRA HISTORIA ============== */
.story { background: var(--brand-tint); border-block: 1px solid var(--brand-soft); }
.story-cards { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; margin-top: 44px; }
.story-card {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg);
  padding: 34px; box-shadow: var(--shadow-sm); position: relative; overflow: hidden;
}
.story-card .mark {
  font-family: Georgia, 'Times New Roman', serif; font-size: 90px; line-height: 0.6; color: var(--brand-soft);
  position: absolute; top: 24px; right: 26px; pointer-events: none;
}
.story-role { display: inline-flex; align-items: center; gap: 9px; font-size: 12.5px; font-weight: 700; letter-spacing: 0.02em; padding: 7px 14px; border-radius: 999px; margin-bottom: 20px; }
.story-role.pat { background: var(--accent-soft); color: var(--accent-2); }
.story-role.doc { background: var(--ink); color: #fff; }
.story-card .quote { font-size: 16.5px; line-height: 1.65; color: var(--text); text-wrap: pretty; position: relative; }
.story-card .quote + .quote { margin-top: 14px; }
.story-card .sign { margin-top: 22px; font-size: 13.5px; color: var(--text-3); font-weight: 500; }
.story-close {
  max-width: 720px; margin: 40px auto 0; text-align: center;
  font-size: clamp(20px, 2.4vw, 26px); line-height: 1.4; font-weight: 600; letter-spacing: -0.01em; text-wrap: balance;
}
.story-close em { font-style: normal; color: var(--brand-2); }

/* ============== REVEAL ANIMATION ============== */
@media (prefers-reduced-motion: no-preference) {
  .reveal { opacity: 0; transform: translateY(22px); transition: opacity 0.6s cubic-bezier(.22,.61,.36,1), transform 0.6s cubic-bezier(.22,.61,.36,1); }
  .reveal.in { opacity: 1; transform: none; }
}

/* ============== MOBILE NAV ============== */
.nav-toggle {
  display: none;
  width: 42px; height: 42px; border-radius: 10px;
  background: var(--surface); border: 1px solid var(--border-strong);
  cursor: pointer; padding: 0;
  align-items: center; justify-content: center; flex-direction: column; gap: 4px;
  margin-left: auto;
}
.nav-toggle span { display: block; width: 18px; height: 2px; background: var(--text); border-radius: 2px; transition: transform 0.2s, opacity 0.2s; }
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }
.nav-mobile[hidden] { display: none; }
.nav-mobile {
  display: grid; gap: 4px;
  padding: 16px 22px 22px;
  border-top: 1px solid var(--border);
  background: var(--bg);
}
.nav-mobile a {
  padding: 12px 4px;
  font-size: 16px; font-weight: 500; color: var(--text);
  border-bottom: 1px solid var(--border);
}
.nav-mobile a:last-of-type { border-bottom: 0; }
.nav-mobile-cta { display: grid; gap: 10px; margin-top: 14px; }

/* ============== RESPONSIVE ============== */
@media (max-width: 980px) {
  .hero-grid, .app-row, .ia-grid { grid-template-columns: 1fr; gap: 40px; }
  .hero-phone { display: none; }
  .app-row.flip .app-copy { order: 0; }
  .feat-grid { grid-template-columns: repeat(2, 1fr); }
  .ia-caps { grid-template-columns: repeat(2, 1fr); }
  .story-cards { grid-template-columns: 1fr; }
  .sec-grid { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .legal-layout { grid-template-columns: 1fr; gap: 32px; }
  .toc { position: static; }
  .nav-inner { gap: 12px; }
  .nav-links { display: none; }
  .nav-cta { display: none; }
  .nav-toggle { display: inline-flex; }
}
@media (max-width: 900px) {
  .hero { padding: 48px 0 56px; }
  .hero-grid { gap: 32px; }
  .hero h1 { font-size: clamp(34px, 6.4vw, 46px); margin-top: 18px; }
  .hero-lead { font-size: 17px; margin-top: 18px; }
  .hero-actions { margin-top: 26px; }
  .hero-trust { gap: 14px 22px; margin-top: 24px; }
  /* Hide the wide desktop mock on mobile — show the phone instead, larger and centered */
  .hero-mock .mock { display: none; }
  .hero-mock .float-pill { display: none; }
  .hero-phone {
    display: block; position: static;
    width: clamp(220px, 56vw, 280px);
    margin: 8px auto 0;
  }
  .hero-phone .device { box-shadow: 0 30px 60px -22px oklch(20% 0.02 240 / 0.45); }
  .section { padding: 72px 0; }
  .app-row + .app-row { margin-top: 72px; }
  .section-head { margin-bottom: 40px; }
  .cta { padding: 72px 0; }
  .cta-card { padding: 52px 36px; }
  .story-card { padding: 30px 26px; }
  .story-card .mark { font-size: 72px; top: 22px; right: 22px; }
  .ia-divider { margin: 44px 0; }
  .app-device, .app-device.doc { max-width: 280px; }
}
@media (max-width: 600px) {
  .wrap { padding: 0 20px; }
  .nav-inner { height: 64px; gap: 10px; }
  .brand-logo { width: 34px; height: 34px; font-size: 17px; border-radius: 10px; }
  .brand-name { font-size: 17px; }
  .brand-name .sub { font-size: 9px; }

  /* Keep grids at 2 cols where it reads better */
  .feat-grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
  .sec-grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
  .ia-caps { grid-template-columns: repeat(2, 1fr); gap: 12px; }
  .strip-stats { grid-template-columns: repeat(2, 1fr); display: grid; gap: 18px 20px; width: 100%; }
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 28px 24px; }

  .strip-inner { padding: 22px 0; gap: 18px; flex-direction: column; align-items: flex-start; }
  .strip-stat .n { font-size: 22px; }
  .strip-stat .l { font-size: 12px; }

  .cta-card { padding: 40px 22px; border-radius: 22px; }

  .hero { padding: 32px 0 48px; }
  .hero-actions { gap: 10px; }
  .hero-actions .btn { flex: 1 1 auto; }
  .pill { font-size: 12px; }
  .pill .tag { font-size: 10.5px; }

  .section { padding: 56px 0; }
  .section-head { margin-bottom: 36px; }
  .section-head h2 { font-size: clamp(26px, 7vw, 32px); }
  .section-head p { font-size: 16px; }

  .app-copy h3 { font-size: 24px; margin-top: 16px; }
  .app-copy > p { font-size: 15.5px; }
  .app-list { margin-top: 22px; gap: 12px; }
  .app-list .t { font-size: 15px; }
  .app-list .d { font-size: 13.5px; }
  .app-row { gap: 36px; }

  .feat { padding: 18px; border-radius: 12px; }
  .feat .ic { width: 38px; height: 38px; border-radius: 10px; margin-bottom: 12px; }
  .feat .ic svg { width: 18px; height: 18px; }
  .feat h3 { font-size: 15px; }
  .feat p { font-size: 13px; margin-top: 6px; }

  .sec { padding: 18px; }
  .sec .ic { width: 36px; height: 36px; margin-bottom: 10px; }
  .sec h3 { font-size: 14.5px; }
  .sec p { font-size: 13px; }

  .ia-cap { padding: 18px; }
  .ia-cap .ic { width: 38px; height: 38px; margin-bottom: 12px; }
  .ia-cap h3 { font-size: 14.5px; }
  .ia-cap p { font-size: 13px; }

  .chat { padding: 14px; border-radius: 18px; }
  .bubble { max-width: 92%; font-size: 13px; }

  .device { border-radius: 34px; padding: 7px; }
  .device img { border-radius: 28px; }
  .app-device, .app-device.doc { max-width: 240px; }
  .hero-phone { width: clamp(220px, 64vw, 260px); }

  .footer { padding: 48px 0 28px; }
  .footer h4 { font-size: 11px; margin-bottom: 12px; }
  .footer ul { gap: 9px; }
  .footer ul a { font-size: 14px; }
  .footer-blurb { font-size: 13.5px; }
  .footer-bottom { flex-direction: column; align-items: flex-start; gap: 12px; }

  .btn { padding: 11px 18px; font-size: 14.5px; }
  .btn-lg { padding: 14px 22px; font-size: 15.5px; }

  .legal-hero { padding: 48px 0 36px; }
  .legal-body section + section { margin-top: 36px; padding-top: 36px; }
  .legal-body h2 { font-size: 20px; }
  .legal-body p, .legal-body ul li { font-size: 14.5px; }
}
@media (max-width: 420px) {
  /* Very small phones — let single-column feel intentional for the densest grids */
  .feat-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .hero-actions { flex-direction: column; align-items: stretch; }
  .hero-actions .btn { width: 100%; }
  .cta-actions { flex-direction: column; align-items: stretch; width: 100%; }
  .cta-actions .btn { width: 100%; }
}
