/* =========================================================
   CapeFear.ai — Shared design tokens + utilities
   New design system: General Sans + House Teal
   Light default / Obsidian dark — CSS variable architecture
   Used by SEO landing pages; index.html carries its own
   inline copy of the token block.
   ========================================================= */

/* ── Self-hosted General Sans ── */
@font-face {
  font-family: 'General Sans';
  src: url('/fonts/general-sans-300.woff2') format('woff2');
  font-weight: 300;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'General Sans';
  src: url('/fonts/general-sans-400.woff2') format('woff2');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'General Sans';
  src: url('/fonts/general-sans-500.woff2') format('woff2');
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'General Sans';
  src: url('/fonts/general-sans-600.woff2') format('woff2');
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'General Sans';
  src: url('/fonts/general-sans-700.woff2') format('woff2');
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

/* ── Light theme (default) ── */
:root,
[data-theme="light"] {
  --bg:            #f8fafc;
  --card:          #ffffff;
  --surf:          #f1f5f9;
  --border:        #e2e8f0;
  --border-2:      #eef2f7;

  --ink:           #14201d;
  --ink-2:         #44524d;
  --ink-3:         #7b8884;

  --teal:          #0c6b62;
  --teal-hover:    #064a44;
  --teal-soft:     #dcefe9;
  --teal-ink:      #064a44;

  --grad:          linear-gradient(120deg, #0c6b62 0%, #0f8174 52%, #1aa18f 100%);

  --good:          #1f7a4d;
  --good-soft:     #dcefe1;
  --warn:          #9a6212;
  --warn-soft:     #f8ead0;
  --info:          #0c6b62;
  --info-soft:     #dcefe9;

  /* Brand band (ownership / CTA section) */
  --on-brand:      #ffffff;
  --on-brand-soft: rgba(255,255,255,0.9);
  --on-brand-muted:rgba(255,255,255,0.65);
  --brand-chip-bd: rgba(255,255,255,0.28);

  /* Footer */
  --footer-bg:     #0e1a18;
  --footer-fg:     #e8f2f0;
  --footer-fg-2:   rgba(232,242,240,0.7);
  --footer-fg-3:   rgba(232,242,240,0.45);

  /* Functional aliases (match old var names for SEO pages) */
  --paper:         var(--bg);
  --paper-2:       var(--surf);
  --paper-3:       #e2e8f0;
  --rule:          var(--border);
  --rule-strong:   #cbd5e1;
  --brand:         var(--teal);
  --brand-deep:    var(--teal-hover);
  --brand-fg:      #ffffff;
}

/* ── Obsidian dark theme ── */
[data-theme="dark"] {
  --bg:            #0e1113;
  --card:          #171b1f;
  --surf:          #1c2126;
  --border:        #262c31;
  --border-2:      #2e3540;

  --ink:           #f1efe9;
  --ink-2:         #a9b0b4;
  --ink-3:         #637076;

  /* Champagne brass accent on dark */
  --teal:          #c8a86a;
  --teal-hover:    #e0c080;
  --teal-soft:     rgba(200,168,106,0.12);
  --teal-ink:      #e0c080;

  --grad:          linear-gradient(120deg, #c8a86a 0%, #d4b876 52%, #e0c080 100%);

  --good:          #4caf7d;
  --good-soft:     rgba(76,175,125,0.14);
  --warn:          #e0a957;
  --warn-soft:     rgba(224,169,87,0.14);
  --info:          #c8a86a;
  --info-soft:     rgba(200,168,106,0.12);

  --on-brand:      #0e1113;
  --on-brand-soft: rgba(14,17,19,0.9);
  --on-brand-muted:rgba(14,17,19,0.65);
  --brand-chip-bd: rgba(200,168,106,0.28);

  --footer-bg:     #080b0d;
  --footer-fg:     #c8cfd3;
  --footer-fg-2:   rgba(200,207,211,0.65);
  --footer-fg-3:   rgba(200,207,211,0.4);

  --paper:         var(--bg);
  --paper-2:       var(--surf);
  --paper-3:       #222830;
  --rule:          var(--border);
  --rule-strong:   #303840;
  --brand:         var(--teal);
  --brand-deep:    var(--teal-hover);
  --brand-fg:      #0e1113;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; background: var(--bg); color: var(--ink); }
body {
  font-family: 'General Sans', -apple-system, BlinkMacSystemFont, system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
  line-height: 1.55;
}
.ms-mono { font-family: 'JetBrains Mono', ui-monospace, monospace; font-variant-numeric: tabular-nums; }

a { text-decoration: none; }
a:hover { text-decoration: underline; }

/* ── Layout helpers ── */
.ms-hero         { display: grid; grid-template-columns: 1fr 560px; gap: 48px; align-items: start; }
.ms-grid-3       { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.ms-grid-4       { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.ms-grid-3-foot  { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; padding-top: 12px; }
.ms-grid-compare { display: grid; grid-template-columns: 1fr 1.2fr 1fr; gap: 18px; }
.ms-grid-own     { display: grid; grid-template-columns: 1fr 1fr; gap: 64px; align-items: center; }
.ms-tech-row     { display: flex; align-items: center; justify-content: space-between; gap: 32px; }
.ms-nav-links    { display: flex; gap: 22px; align-items: center; }
.ms-section-inner { max-width: 1180px; margin: 0 auto; padding: 0 56px; }

/* ── Nav dropdown ── */
.ms-nav-dd { position: relative; display: inline-flex; align-items: center; }
.ms-nav-dd-trigger {
  font-size: 13px;
  font-weight: 400;
  color: var(--ink);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  user-select: none;
  white-space: nowrap;
}
.ms-nav-dd-trigger:hover,
.ms-nav-dd:hover .ms-nav-dd-trigger,
.ms-nav-dd:focus-within .ms-nav-dd-trigger { color: var(--ink); }
.ms-nav-dd-trigger:focus-visible { outline: 2px solid var(--teal); outline-offset: 3px; border-radius: 3px; }
.ms-nav-dd-caret { font-size: 9px; line-height: 1; color: var(--ink-3); transition: transform 160ms ease, color 160ms ease; }
.ms-nav-dd:hover .ms-nav-dd-caret,
.ms-nav-dd:focus-within .ms-nav-dd-caret { transform: rotate(180deg); color: var(--ink-2); }
.ms-nav-dd-menu {
  position: absolute;
  top: 100%;
  left: 50%;
  margin-top: 10px;
  min-width: 176px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 10px;
  box-shadow: 0 14px 36px -22px rgba(0,0,0,0.45), 0 2px 8px -4px rgba(0,0,0,0.22);
  padding: 6px;
  display: flex;
  flex-direction: column;
  gap: 2px;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateX(-50%) translateY(-4px);
  transition: opacity 150ms ease, transform 150ms ease, visibility 0s linear 150ms;
  z-index: 30;
}
.ms-nav-dd-menu::before {
  content: "";
  position: absolute;
  top: -10px;
  left: 0;
  right: 0;
  height: 10px;
}
.ms-nav-dd:hover .ms-nav-dd-menu,
.ms-nav-dd:focus-within .ms-nav-dd-menu {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateX(-50%) translateY(0);
  transition: opacity 150ms ease, transform 150ms ease, visibility 0s;
}
.ms-nav-dd-menu a {
  display: block;
  font-size: 13px;
  font-weight: 500;
  color: var(--ink-2);
  padding: 8px 12px;
  border-radius: 7px;
  white-space: nowrap;
  transition: background 140ms ease, color 140ms ease;
}
.ms-nav-dd-menu a:hover { text-decoration: none; color: var(--ink); background: var(--surf); }

/* ── Responsive ── */
@media (max-width: 1024px) {
  .ms-hero         { grid-template-columns: 1fr; gap: 32px; }
  .ms-grid-compare { grid-template-columns: 1fr; }
  .ms-grid-own     { grid-template-columns: 1fr; gap: 28px; }
}
@media (max-width: 768px) {
  .ms-section-inner { padding: 0 24px; }
  .ms-grid-3       { grid-template-columns: 1fr; }
  .ms-grid-4       { grid-template-columns: 1fr 1fr; }
  .ms-grid-3-foot  { grid-template-columns: 1fr; gap: 18px; }
  .ms-tech-row     { flex-direction: column; align-items: flex-start; gap: 18px; }
  .ms-nav-links a:not(.ms-nav-cta) { display: none; }
  .ms-nav-dd       { display: none; }
  .ms-h1           { font-size: 40px !important; }
  .ms-h2           { font-size: 28px !important; }
  .ms-section-pad-lg { padding-top: 48px !important; padding-bottom: 48px !important; }
}
@media (max-width: 480px) {
  .ms-grid-4 { grid-template-columns: 1fr; }
  .ms-h1     { font-size: 34px !important; }
}
@media (max-width: 768px) {
  .ms-hero-anim-frame { padding: 48px 16px 24px !important; }
  .ms-hero-card, .ms-hero-pill { min-width: 0 !important; width: 100% !important; }
  .ms-hero-row { flex-direction: column !important; align-items: stretch !important; gap: 8px !important; }
  .ms-hero-conn { height: 16px !important; width: 1px !important; flex: 0 0 16px !important; align-self: center; min-width: 0 !important; }
  .ms-track { padding-left: 0 !important; }
  .ms-track-label { position: static !important; margin-bottom: 12px !important; }
  .ms-track-timeline { flex-wrap: wrap !important; row-gap: 8px !important; padding-top: 4px !important; }
  .ms-track-line { display: none !important; }
  .ms-track-step { margin-right: 0 !important; margin-bottom: 0 !important; }
  .ms-anim-frame { padding: 20px 14px !important; }
}

/* ── Typography ── */
.ms-eyebrow {
  font-family: 'General Sans', system-ui, sans-serif;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--teal);
  margin: 0 0 18px;
}
.ms-h1 {
  font-family: 'General Sans', system-ui, sans-serif;
  font-size: 58px;
  line-height: 1.02;
  letter-spacing: -0.03em;
  font-weight: 600 !important;
  margin: 0 0 22px;
  color: var(--ink);
}
.ms-h1 em { font-style: italic; color: var(--teal); }
.ms-h2 {
  font-family: 'General Sans', system-ui, sans-serif;
  font-size: 40px;
  line-height: 1.08;
  letter-spacing: -0.025em;
  font-weight: 600 !important;
  margin: 0 0 16px;
  color: var(--ink);
}
.ms-h3 {
  font-family: 'General Sans', system-ui, sans-serif;
  font-size: 22px;
  font-weight: 600;
  letter-spacing: -0.01em;
  line-height: 1.25;
  margin: 0 0 10px;
  color: var(--ink);
}
.ms-lede {
  font-family: 'General Sans', system-ui, sans-serif;
  font-size: 18px;
  line-height: 1.6;
  color: var(--ink-2);
  max-width: 640px;
  margin: 0 0 30px;
}
.ms-prose { font-size: 16px; line-height: 1.7; color: var(--ink-2); max-width: 720px; }
.ms-prose p { margin: 0 0 18px; }
.ms-prose strong { color: var(--ink); font-weight: 600; }
.ms-prose a { color: var(--teal); font-weight: 500; }
.ms-prose ul, .ms-prose ol { margin: 0 0 22px; padding-left: 22px; }
.ms-prose li { margin: 0 0 10px; }

/* ── Buttons ── */
.ms-btn {
  font-family: 'General Sans', system-ui, sans-serif;
  font-weight: 600;
  font-size: 14px;
  padding: 12px 22px;
  border-radius: 11px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border: 1px solid transparent;
  text-decoration: none;
  transition: background 0.16s, color 0.16s, border-color 0.16s;
}
.ms-btn:hover { text-decoration: none; }
.ms-btn-primary   { background: var(--teal); color: #fff; }
.ms-btn-primary:hover { background: var(--teal-hover); }
.ms-btn-secondary { background: var(--card); color: var(--ink); border-color: var(--border); }
.ms-btn-secondary:hover { border-color: var(--teal); color: var(--teal); }
.ms-btn-sm { font-size: 12px; padding: 8px 14px; border-radius: 8px; }

/* ── Header / nav ── */
.ms-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: var(--bg);
  backdrop-filter: saturate(180%) blur(14px);
  border-bottom: 1px solid var(--border);
}
.ms-header-inner {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 56px;
  height: 68px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.ms-brand { display: flex; align-items: center; gap: 13px; color: inherit; }
.ms-brand:hover { text-decoration: none; }
/* __CF_THEME_SUITE_v1__ (2026-06-19): brand lockup 1.5x larger, matching the homepage logo bump. */
.ms-brand-mark svg { width: 36px; height: 36px; }
.ms-brand-name { font-size: 27px; font-weight: 600; letter-spacing: -0.02em; color: var(--ink); }
.ms-brand-name span { color: var(--ink-3); font-weight: 500; }
.ms-nav-links a { font-size: 13px; font-weight: 400; color: var(--ink); cursor: pointer; }
.ms-nav-links a:hover { color: var(--ink); text-decoration: none; }

/* ── Sections ── */
.ms-section { background: transparent; }
.ms-section-surf { background: var(--surf); }
.ms-section-brand { background: var(--grad); }
.ms-pad-lg { padding-top: 96px; padding-bottom: 96px; }
.ms-pad-md { padding-top: 64px; padding-bottom: 64px; }

/* ── Cards ── */
.ms-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 26px 28px;
  transition: transform 0.18s, box-shadow 0.18s, border-color 0.18s;
}
.ms-card:hover { transform: translateY(-2px); box-shadow: 0 18px 48px -32px rgba(12,107,98,.22); border-color: #cdd8d5; }
.ms-section-surf .ms-card { background: var(--card); }
.ms-card .ms-tag {
  font-family: 'General Sans', system-ui, sans-serif;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--teal);
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 12px;
}
.ms-card .ms-tag .ms-dot { width: 5px; height: 5px; border-radius: 50%; background: var(--teal); }
.ms-card p { font-size: 14px; color: var(--ink-2); line-height: 1.65; margin: 0; }
.ms-card h3 { font-family: 'General Sans', system-ui, sans-serif; font-size: 19px; font-weight: 600; letter-spacing: -0.01em; margin: 0 0 8px; color: var(--ink); }

/* ── Step number badge ── */
.ms-step-num {
  width: 38px;
  height: 38px;
  border-radius: 11px;
  background: var(--teal-soft);
  color: var(--teal-ink);
  display: grid;
  place-items: center;
  font-weight: 600;
  font-size: 16px;
  flex: none;
}

/* ── Trust / icon list ── */
.ms-trust-item { display: flex; gap: 14px; align-items: flex-start; }
.ms-trust-icon {
  width: 36px; height: 36px;
  border-radius: 10px;
  background: rgba(12,107,98,0.12);
  color: var(--teal);
  display: grid;
  place-items: center;
  flex: none;
}
[data-theme="dark"] .ms-trust-icon { background: rgba(200,168,106,0.14); color: var(--teal); }
.ms-trust-title { font-size: 14px; font-weight: 600; color: var(--ink); }
.ms-trust-desc { font-size: 13px; color: var(--ink-2); margin-top: 2px; }

/* ── Vertical cards (colored) ── */
.ms-vcard {
  border-radius: 18px;
  padding: 32px;
  color: #fff;
  position: relative;
  overflow: hidden;
  min-height: 200px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
}
.ms-vcard.a { background: linear-gradient(160deg, #0f8174, #064a44); }
.ms-vcard.b { background: linear-gradient(160deg, #15727f, #0a3f49); }
.ms-vcard.c { background: linear-gradient(160deg, #1a8f7a, #0c5a44); }
.ms-vcard-kicker { font-size: 11px; letter-spacing: 0.1em; text-transform: uppercase; opacity: 0.8; font-weight: 600; }
.ms-vcard h3 { font-size: 22px; font-weight: 600; margin-top: 8px; letter-spacing: -0.01em; }
.ms-vcard p  { font-size: 14px; opacity: 0.9; margin-top: 8px; }

/* ── Security list ── */
.ms-sec-item { display: flex; gap: 14px; align-items: flex-start; }
.ms-sec-check {
  width: 26px; height: 26px;
  border-radius: 8px;
  background: rgba(127,216,200,0.15);
  color: #7fd8c8;
  display: grid;
  place-items: center;
  flex: none;
}
.ms-sec-title { font-size: 15px; font-weight: 600; color: #eaf5f1; }
.ms-sec-desc  { font-size: 13px; color: #84a59e; margin-top: 2px; }

/* ── Final CTA card ── */
.ms-finalcard {
  background: var(--grad);
  border-radius: 24px;
  padding: 72px 56px;
  text-align: center;
  color: #fff;
  position: relative;
  overflow: hidden;
}
.ms-finalcard::after {
  content: "";
  position: absolute;
  right: -80px;
  bottom: -100px;
  width: 340px;
  height: 340px;
  border-radius: 50%;
  background: rgba(255,255,255,0.08);
}
.ms-finalcard h2 { color: #fff; font-size: 40px; max-width: 18ch; margin: 0 auto; position: relative; letter-spacing: -0.025em; }
.ms-finalcard p  { font-size: 17px; opacity: 0.92; margin-top: 16px; position: relative; }
.ms-finalcard .ms-finalcard-cta { margin-top: 30px; display: flex; gap: 14px; justify-content: center; position: relative; flex-wrap: wrap; }

/* ── FAQ ── */
.ms-faq { max-width: 820px; }
.ms-faq-item { border-top: 1px solid var(--border); padding: 26px 0; }
.ms-faq-item:first-of-type { border-top: none; }
.ms-faq-item h3 { font-family: 'General Sans', system-ui, sans-serif; font-size: 21px; font-weight: 600; letter-spacing: -0.01em; margin: 0 0 12px; color: var(--ink); }
.ms-faq-item p { font-size: 15px; line-height: 1.7; color: var(--ink-2); margin: 0 0 12px; max-width: 760px; }
.ms-faq-item p:last-child { margin-bottom: 0; }

/* ── Product screenshot frame ── */
.ms-shot {
  background: var(--surf);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 16px;
  max-width: 980px;
  box-shadow: 0 18px 56px -32px rgba(0,0,0,0.35);
}
.ms-shot img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 9px;
  border: 1px solid var(--border);
}
figure.ms-shot { margin: 0; }

/* ── Blog list ── */
.ms-post-list { max-width: 820px; display: grid; gap: 4px; }
.ms-post { border-top: 1px solid var(--border); padding: 26px 0; display: block; color: inherit; }
.ms-post:hover { text-decoration: none; }
.ms-post:first-of-type { border-top: none; }
.ms-post .ms-post-meta { font-family: 'JetBrains Mono', ui-monospace, monospace; font-size: 10px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--teal); margin-bottom: 10px; }
.ms-post h3 { font-family: 'General Sans', system-ui, sans-serif; font-size: 24px; font-weight: 600; letter-spacing: -0.015em; margin: 0 0 8px; color: var(--ink); }
.ms-post:hover h3 { color: var(--teal); }
.ms-post p { font-size: 14px; line-height: 1.65; color: var(--ink-2); margin: 0; max-width: 720px; }

/* ── Article ── */
.ms-article { max-width: 720px; }
.ms-article .ms-article-meta { font-family: 'JetBrains Mono', ui-monospace, monospace; font-size: 11px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--ink-3); margin: 0 0 18px; }
.ms-article h2 { font-family: 'General Sans', system-ui, sans-serif; font-size: 28px; font-weight: 600; letter-spacing: -0.02em; line-height: 1.2; margin: 36px 0 14px; color: var(--ink); }
.ms-article h3 { font-family: 'General Sans', system-ui, sans-serif; font-size: 20px; font-weight: 600; margin: 28px 0 10px; color: var(--ink); }
.ms-article p { font-size: 16px; line-height: 1.75; color: var(--ink-2); margin: 0 0 18px; }
.ms-article strong { color: var(--ink); font-weight: 600; }
.ms-article a { color: var(--teal); font-weight: 500; }
.ms-article ul, .ms-article ol { margin: 0 0 22px; padding-left: 22px; }
.ms-article li { font-size: 16px; line-height: 1.7; color: var(--ink-2); margin: 0 0 10px; }

/* ── Link chips ── */
.ms-links-row { display: flex; flex-wrap: wrap; gap: 10px; }
.ms-link-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 16px;
  border-radius: 999px;
  border: 1px solid var(--border);
  font-size: 13px;
  font-weight: 500;
  color: var(--ink-2);
  background: var(--card);
}
.ms-link-chip:hover { text-decoration: none; border-color: var(--teal); color: var(--teal); }
.ms-link-chip .ms-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--teal); }

/* ── Brand / CTA band ── */
.ms-section-brand .ms-eyebrow { color: rgba(255,255,255,0.7); }
.ms-section-brand h2 { color: #fff; }
.ms-section-brand p { color: rgba(255,255,255,0.88); }

/* ── Footer ── */
.ms-footer { background: var(--footer-bg); color: var(--footer-fg); }
.ms-footer-inner { max-width: 1180px; margin: 0 auto; padding: 0 56px; }
.ms-footer-links {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 32px;
  padding: 48px 0 36px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}
.ms-footer-links h4 { font-family: 'JetBrains Mono', ui-monospace, monospace; font-size: 10px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--footer-fg-3); margin: 0 0 14px; }
.ms-footer-links a { display: block; font-size: 13px; font-weight: 500; color: var(--footer-fg-2); margin-bottom: 9px; }
.ms-footer-links a:hover { color: var(--footer-fg); text-decoration: none; }
.ms-footer-blurb { font-size: 13px; line-height: 1.65; color: var(--footer-fg-2); max-width: 300px; margin: 12px 0 0; }
.ms-footer-bar { display: flex; align-items: center; justify-content: space-between; gap: 32px; padding: 22px 0; }
.ms-footer-bar .ms-mono { font-size: 11px; }
.ms-footer-bar .l { letter-spacing: 0.14em; text-transform: uppercase; color: var(--footer-fg-2); }
.ms-footer-bar .r { letter-spacing: 0.04em; color: var(--footer-fg-3); }

@media (max-width: 768px) {
  .ms-header-inner { padding: 0 24px; }
  .ms-footer-inner { padding: 0 24px; }
  .ms-footer-links { grid-template-columns: 1fr 1fr; gap: 24px; }
  .ms-footer-bar { flex-direction: column; align-items: flex-start; gap: 12px; }
  .ms-h1 { font-size: 38px; }
  .ms-h2 { font-size: 28px; }
}
@media (max-width: 480px) {
  .ms-footer-links { grid-template-columns: 1fr; }
  .ms-h1 { font-size: 32px; }
}

/* --- Dental "Try it live" demo — the AI calls the visitor back (form + card) --- */
.ms-demo-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 28px;
  align-items: center;
}
@media (min-width: 860px) {
  .ms-demo-grid { grid-template-columns: 1.05fr 0.95fr; gap: 48px; }
}
.ms-demo-points {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 9px;
}
.ms-demo-points li {
  position: relative;
  padding-left: 26px;
  font-size: 14.5px;
  color: var(--ink-2);
}
.ms-demo-points li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 2px;
  width: 17px;
  height: 17px;
  border-radius: 50%;
  background: var(--teal-soft);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230c6b62' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='20 6 9 17 4 12'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: center;
  background-size: 11px;
}
.ms-demo-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 24px;
  box-shadow: 0 10px 30px rgba(0,0,0,.06);
}
.ms-field { display: block; margin-bottom: 14px; }
.ms-field-label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--ink-2);
  margin-bottom: 6px;
}
.ms-field-opt { font-weight: 400; color: var(--ink-3); }
.ms-field input {
  width: 100%;
  box-sizing: border-box;
  padding: 11px 13px;
  font-size: 15px;
  color: var(--ink);
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 10px;
  outline: none;
  transition: border-color .12s ease, box-shadow .12s ease;
  font-family: inherit;
}
.ms-field input::placeholder { color: var(--ink-3); }
.ms-field input:focus { border-color: var(--teal); box-shadow: 0 0 0 3px var(--teal-soft); }
/* Animated "Call me now" CTA — a live AI-voice feel: gradient + breathing glow,
   a pulsing "listening" halo, a voice-waveform, and a sheen sweep. */
.ms-demo-submit {
  position: relative;
  isolation: isolate;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  margin-top: 6px;
  padding: 15px 20px;
  font-family: inherit;
  font-size: 15.5px;
  font-weight: 600;
  color: #fff;
  border: none;
  border-radius: 12px;
  cursor: pointer;
  overflow: hidden;
  background: linear-gradient(120deg, var(--teal) 0%, #0e7d72 50%, var(--teal-hover) 100%);
  background-size: 200% 100%;
  box-shadow: 0 6px 18px rgba(12, 107, 98, 0.28);
  transition: transform 0.12s ease, box-shadow 0.2s ease;
  animation: ms-cta-breathe 2.6s ease-in-out infinite, ms-cta-flow 6s linear infinite;
}
.ms-demo-submit:hover { transform: translateY(-1px); box-shadow: 0 10px 26px rgba(12, 107, 98, 0.36); }
.ms-demo-submit:focus-visible { outline: 3px solid var(--teal-soft); outline-offset: 2px; }
.ms-demo-submit[disabled] { cursor: default; }
.ms-demo-submit::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(100deg, transparent 20%, rgba(255, 255, 255, 0.28) 50%, transparent 80%);
  transform: translateX(-120%);
  animation: ms-cta-sheen 3.4s ease-in-out infinite;
}
.ms-demo-halo {
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: -2;
  width: 62px;
  height: 62px;
  margin: -31px 0 0 -31px;
  border-radius: 50%;
  background: var(--teal);
  opacity: 0.35;
  pointer-events: none;
  animation: ms-cta-halo 2.2s ease-out infinite;
}
.ms-demo-wave { display: inline-flex; align-items: center; gap: 3px; height: 18px; }
.ms-demo-wave i {
  display: block;
  width: 3px;
  height: 6px;
  border-radius: 2px;
  background: rgba(255, 255, 255, 0.92);
  animation: ms-cta-wave 1s ease-in-out infinite;
}
.ms-demo-wave i:nth-child(2) { animation-delay: 0.15s; }
.ms-demo-wave i:nth-child(3) { animation-delay: 0.3s; }
.ms-demo-wave i:nth-child(4) { animation-delay: 0.45s; }
.ms-demo-wave i:nth-child(5) { animation-delay: 0.6s; }
.ms-demo-submit.is-loading { animation-play-state: paused; }
.ms-demo-submit.is-loading .ms-demo-wave,
.ms-demo-submit.is-loading .ms-demo-halo { display: none; }
.ms-demo-submit-spin { display: none; width: 16px; height: 16px; border: 2px solid rgba(255, 255, 255, 0.45); border-top-color: #fff; border-radius: 50%; animation: ms-spin 0.7s linear infinite; }
.ms-demo-submit.is-loading .ms-demo-submit-spin { display: inline-block; }

@keyframes ms-spin { to { transform: rotate(360deg); } }
@keyframes ms-cta-breathe { 0%, 100% { box-shadow: 0 6px 18px rgba(12, 107, 98, 0.28); } 50% { box-shadow: 0 6px 26px rgba(12, 107, 98, 0.5); } }
@keyframes ms-cta-flow { to { background-position: 200% 0; } }
@keyframes ms-cta-sheen { 0% { transform: translateX(-120%); } 55%, 100% { transform: translateX(120%); } }
@keyframes ms-cta-halo { 0% { transform: scale(0.9); opacity: 0.4; } 100% { transform: scale(1.9); opacity: 0; } }
@keyframes ms-cta-wave { 0%, 100% { height: 5px; } 50% { height: 16px; } }

.ms-demo-status { margin: 12px 0 0; font-size: 13.5px; line-height: 1.5; min-height: 1px; }
.ms-demo-status.is-ok { color: var(--teal); font-weight: 600; }
.ms-demo-status.is-err { color: #b4231f; font-weight: 500; }
[data-theme="dark"] .ms-demo-status.is-err { color: #f0857f; }
.ms-demo-call-note { margin-top: 14px; font-size: 12.5px; color: var(--ink-3); }

/* Post-call booking panel (revealed by demo-call.js when the call ends). */
.ms-demo-booked {
  margin-top: 8px;
  padding: 22px;
  text-align: center;
  border: 1px solid var(--teal);
  border-radius: 16px;
  background: var(--teal-soft);
  animation: ms-booked-in 0.35s ease both;
}
.ms-demo-booked-badge { display: inline-flex; align-items: center; justify-content: center; width: 40px; height: 40px; border-radius: 50%; background: var(--teal); color: #fff; margin-bottom: 10px; }
[data-theme="dark"] .ms-demo-booked-badge { color: var(--bg); }
.ms-demo-booked-title { margin: 0 0 6px; font-size: 18px; font-weight: 650; color: var(--ink); }
.ms-demo-booked-copy { margin: 0 0 16px; font-size: 14px; line-height: 1.5; color: var(--ink-2); }
@keyframes ms-booked-in { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }

@media (prefers-reduced-motion: reduce) {
  .ms-demo-submit, .ms-demo-submit::after, .ms-demo-halo, .ms-demo-wave i, .ms-demo-submit-spin, .ms-demo-booked { animation: none !important; }
  .ms-demo-wave i { height: 11px; }
  .ms-demo-halo { opacity: 0.18; }
}
