/* ─── Geist (same CDN the AI Phone 360 marketing site uses) ─────────────────── */
@font-face {
  font-family: 'Geist'; font-style: normal; font-weight: 400; font-display: swap;
  src: url('https://cdn.jsdelivr.net/npm/geist@1.3.1/dist/fonts/geist-sans/Geist-Regular.woff2') format('woff2');
}
@font-face {
  font-family: 'Geist'; font-style: normal; font-weight: 500; font-display: swap;
  src: url('https://cdn.jsdelivr.net/npm/geist@1.3.1/dist/fonts/geist-sans/Geist-Medium.woff2') format('woff2');
}
@font-face {
  font-family: 'Geist'; font-style: normal; font-weight: 600; font-display: swap;
  src: url('https://cdn.jsdelivr.net/npm/geist@1.3.1/dist/fonts/geist-sans/Geist-SemiBold.woff2') format('woff2');
}
@font-face {
  font-family: 'Geist'; font-style: normal; font-weight: 700; font-display: swap;
  src: url('https://cdn.jsdelivr.net/npm/geist@1.3.1/dist/fonts/geist-sans/Geist-Bold.woff2') format('woff2');
}

:root {
  /* Brand — one decisive blue + the signature gradient as an accent */
  --brand: #3b82f6;
  --brand-hover: #2563eb;
  --brand-dark: #1d4ed8;
  --indigo: #6366f1;
  --violet: #8b5cf6;
  --grad: linear-gradient(118deg, #3b82f6 0%, #6366f1 45%, #8b5cf6 85%, #4f46e5 100%);
  --grad-text: linear-gradient(135deg, #2563eb 0%, #6366f1 50%, #8b5cf6 100%);
  --success: #22c55e;
  --danger: #ef4444;
  --warn: #f59e0b;

  /* Slate neutrals */
  --text: #0f172a;
  --text-2: #334155;
  --text-soft: #64748b;
  --border: #e2e8f0;
  --border-soft: #f1f5f9;
  --bg: #ffffff;
  --bg-soft: #f8fafc;

  /* Dark ink (sidebar + code) — the site's theme-color */
  --ink: #020617;
  --ink-2: #0b1020;
  --ink-card: #1e293b;
  --ink-text: #cbd5e1;
  --ink-text-soft: #94a3b8;

  --code-text: #e2e8f0;
  --sidebar-w: 288px;
  --maxw: 824px;
  --radius: 14px;
  --pill: 980px;

  --mono: 'Geist Mono', ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;
  --sans: 'Geist', -apple-system, BlinkMacSystemFont, system-ui, "Segoe UI", Roboto, sans-serif;
  --ease: cubic-bezier(0.16, 1, 0.3, 1);

  --shadow-s: 0 1px 2px rgba(15,23,42,.04), 0 1px 3px rgba(15,23,42,.06);
  --shadow-m: 0 4px 12px -2px rgba(15,23,42,.08), 0 12px 24px -8px rgba(99,102,241,.10);
  --shadow-l: 0 16px 32px -12px rgba(15,23,42,.12), 0 32px 64px -20px rgba(99,102,241,.14);
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 24px; }
body {
  margin: 0; font-family: var(--sans); color: var(--text); background: var(--bg);
  line-height: 1.65; font-size: 16px; -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
}
a { color: var(--brand-hover); text-decoration: none; transition: color .15s var(--ease); }
a:hover { color: var(--brand-dark); text-decoration: underline; }

/* Layout */
.layout { display: flex; min-height: 100vh; }
.sidebar {
  width: var(--sidebar-w); flex-shrink: 0; background: var(--ink); color: var(--ink-text);
  position: sticky; top: 0; height: 100vh; overflow-y: auto; padding: 26px 0;
  border-right: 1px solid rgba(148,163,184,.12);
}
.content {
  flex: 1; min-width: 0; padding: 0 48px 140px;
  background:
    radial-gradient(56% 460px at 50% 0, rgba(37,99,235,.13) 0%, rgba(99,102,241,.06) 45%, transparent 72%),
    var(--bg);
  background-repeat: no-repeat;
}
.content-inner { max-width: var(--maxw); margin: 0 auto; }

/* Sidebar brand */
.brand { display: flex; align-items: center; gap: 11px; padding: 0 24px 22px; }
.brand-logo { width: 34px; height: 34px; border-radius: 9px; display: block; box-shadow: 0 2px 8px rgba(0,0,0,.35); }
.brand-name { color: #fff; font-weight: 700; font-size: 15px; line-height: 1.15; letter-spacing: -.01em; }
.brand-sub {
  font-size: 11px; font-weight: 600; letter-spacing: .04em; text-transform: uppercase;
  background: var(--grad-text); -webkit-background-clip: text; background-clip: text; color: transparent;
}
.nav-group { padding: 16px 0 4px; }
.nav-group-title {
  padding: 0 24px 7px; font-size: 11px; font-weight: 600; letter-spacing: .08em;
  text-transform: uppercase; color: #64748b;
}
.nav a {
  display: block; padding: 6px 24px; color: var(--ink-text); font-size: 14px;
  border-left: 2px solid transparent; transition: all .15s var(--ease);
}
.nav a:hover { color: #fff; background: rgba(148,163,184,.07); text-decoration: none; }
.nav a.active { color: #fff; border-left-color: var(--brand); background: linear-gradient(90deg, rgba(59,130,246,.16), transparent); }

/* Typography */
h1 { font-size: 40px; line-height: 1.05; margin: 0 0 10px; letter-spacing: -.03em; font-weight: 700; }
h2 {
  font-size: 26px; margin: 60px 0 16px; padding-top: 14px; letter-spacing: -.02em; font-weight: 700;
  border-top: 1px solid var(--border);
}
h2:first-of-type { border-top: none; margin-top: 28px; }
h3 { font-size: 18px; margin: 32px 0 10px; letter-spacing: -.01em; font-weight: 600; }
h4 { font-size: 13px; margin: 22px 0 8px; color: var(--text-soft); text-transform: uppercase; letter-spacing: .05em; font-weight: 600; }
p { margin: 0 0 14px; }
.lead { font-size: 20px; line-height: 1.5; color: var(--text-soft); margin-bottom: 30px; }
ul, ol { margin: 0 0 16px; padding-left: 22px; }
li { margin: 5px 0; }
hr { border: none; border-top: 1px solid var(--border); margin: 44px 0; }

/* Gradient text accent */
.grad-text { background: var(--grad-text); -webkit-background-clip: text; background-clip: text; color: transparent; }

/* Code */
code {
  font-family: var(--mono); font-size: 13.5px; background: var(--bg-soft);
  border: 1px solid var(--border); border-radius: 6px; padding: 1px 6px; color: var(--brand-dark);
}
pre {
  background: var(--ink); color: var(--code-text); border-radius: var(--radius);
  padding: 18px 20px; overflow-x: auto; font-family: var(--mono); font-size: 13.5px;
  line-height: 1.6; margin: 0 0 18px; border: 1px solid rgba(148,163,184,.14);
}
pre code { background: none; border: none; padding: 0; color: inherit; font-size: inherit; }
.tok-c { color: #64748b; }
.tok-s { color: #6ee7b7; }
.tok-k { color: #93c5fd; }
.tok-f { color: #fcd34d; }

/* Tables */
table { width: 100%; border-collapse: collapse; margin: 0 0 22px; font-size: 14.5px; }
th, td { text-align: left; padding: 11px 14px; border-bottom: 1px solid var(--border); vertical-align: top; }
th { font-weight: 600; color: var(--text); background: var(--bg-soft); }
tr:last-child td { border-bottom: none; }
td code { font-size: 12.5px; }

/* Callouts */
.note, .warn-box, .danger-box {
  border-radius: var(--radius); padding: 15px 18px; margin: 0 0 20px; font-size: 14.5px;
  border: 1px solid var(--border); border-left: 3px solid var(--brand); background: linear-gradient(180deg, rgba(59,130,246,.05), rgba(99,102,241,.03));
}
.warn-box { border-left-color: var(--warn); background: rgba(245,158,11,.06); }
.danger-box { border-left-color: var(--danger); background: rgba(239,68,68,.05); }
.note strong, .warn-box strong, .danger-box strong { display: block; margin-bottom: 4px; color: var(--text); }

/* HTTP endpoint pills */
.endpoint {
  display: flex; align-items: center; gap: 11px; font-family: var(--mono); font-size: 14px;
  background: var(--bg-soft); border: 1px solid var(--border); border-radius: 12px;
  padding: 11px 15px; margin: 0 0 6px; overflow-x: auto;
}
.method { font-weight: 600; padding: 3px 9px; border-radius: 6px; font-size: 11.5px; color: #fff; flex-shrink: 0; letter-spacing: .02em; }
.get { background: var(--success); }
.post { background: var(--brand); }
.patch { background: var(--warn); }
.delete { background: var(--danger); }
.endpoint .path { color: var(--text); white-space: nowrap; }

/* Hero — fills to the very top of the content area (no white strip). The glow
   is painted on .content (full width to the top); the hero itself just sets the
   top spacing for the inner column. */
.hero { padding: 60px 0 30px; }
.hero .badge {
  display: inline-block; background: var(--grad); color: #fff;
  font-size: 11.5px; font-weight: 600; padding: 5px 13px; border-radius: var(--pill); margin-bottom: 16px;
  letter-spacing: .04em; text-transform: uppercase; box-shadow: 0 6px 18px -8px rgba(79,70,229,.5);
}
.cards { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin: 26px 0 8px; }
.card {
  border: 1px solid var(--border); border-radius: 16px; padding: 20px; display: block; color: inherit;
  background: #fff; transition: all .2s var(--ease);
}
.card:hover { border-color: rgba(59,130,246,.45); text-decoration: none; box-shadow: var(--shadow-m); transform: translateY(-2px); }
.card h3 { margin: 0 0 6px; font-size: 16px; }
.card h3 { background: var(--grad-text); -webkit-background-clip: text; background-clip: text; color: transparent; }
.card p { margin: 0; font-size: 14px; color: var(--text-soft); }

/* Pills */
.pill { display:inline-block; font-size:12px; font-weight:600; padding:2px 9px; border-radius: var(--pill); }
.pill-scope { background: rgba(59,130,246,.10); color: var(--brand-dark); font-family: var(--mono); font-size: 12px; }

.topbar { display:none; }

/* Footer — full-width dark band below the layout */
.site-footer { background: var(--ink); color: var(--ink-text); border-top: 1px solid rgba(148,163,184,.14); }
.footer-inner { max-width: 1180px; margin: 0 auto; padding: 56px 40px 32px; }
.footer-top { display: grid; grid-template-columns: 1.3fr 2.4fr; gap: 48px; }
.footer-brand-row { display: flex; align-items: center; gap: 11px; font-weight: 700; font-size: 16px; color: #fff; margin-bottom: 14px; }
.footer-brand p { color: var(--ink-text-soft); font-size: 14px; line-height: 1.6; margin: 0 0 16px; max-width: 320px; }
.footer-cta { display: inline-block; font-weight: 600; font-size: 14px; background: var(--grad-text); -webkit-background-clip: text; background-clip: text; color: transparent; }
.footer-cta:hover { text-decoration: none; opacity: .85; }
.footer-cols { display: grid; grid-template-columns: repeat(4, 1fr); gap: 28px; }
.footer-col h4 { color: #fff; font-size: 13px; font-weight: 600; letter-spacing: .03em; margin: 0 0 14px; text-transform: none; }
.footer-col a { display: block; color: var(--ink-text-soft); font-size: 14px; padding: 4px 0; transition: color .15s var(--ease); }
.footer-col a:hover { color: #fff; text-decoration: none; }
.footer-bottom {
  display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 12px;
  margin-top: 40px; padding-top: 22px; border-top: 1px solid rgba(148,163,184,.14);
  color: #64748b; font-size: 13px;
}
.footer-bottom-links { display: flex; gap: 18px; }
.footer-bottom-links a { color: #64748b; }
.footer-bottom-links a:hover { color: var(--ink-text); text-decoration: none; }
@media (max-width: 900px) {
  .footer-inner { padding: 40px 20px 28px; }
  .footer-top { grid-template-columns: 1fr; gap: 32px; }
  .footer-cols { grid-template-columns: 1fr 1fr; gap: 24px; }
  .footer-bottom { flex-direction: column; align-items: flex-start; }
}

/* Mobile */
@media (max-width: 900px) {
  .sidebar { position: fixed; left: 0; top: 0; transform: translateX(-100%); transition: transform .25s var(--ease); z-index: 50; box-shadow: 8px 0 40px rgba(2,6,23,.4); }
  .sidebar.open { transform: translateX(0); }
  .content { padding: 74px 20px 90px; background-position: 50% 54px; }
  .hero { padding: 8px 0 22px; }
  .cards { grid-template-columns: 1fr; }
  .topbar {
    display: flex; align-items: center; gap: 12px; position: fixed; top: 0; left: 0; right: 0; height: 56px;
    background: rgba(2,6,23,.82); backdrop-filter: saturate(180%) blur(20px); -webkit-backdrop-filter: saturate(180%) blur(20px);
    color: #fff; padding: 0 16px; z-index: 40; border-bottom: 1px solid rgba(148,163,184,.14);
  }
  .topbar .menu-btn { background: rgba(148,163,184,.12); border: 1px solid rgba(148,163,184,.2); color: #fff; border-radius: 8px; padding: 5px 11px; font-size: 17px; cursor: pointer; }
  .topbar .brand-logo-sm { width: 26px; height: 26px; border-radius: 7px; }
  .topbar .brand-name { font-size: 14px; }
  .overlay { display: none; position: fixed; inset: 0; background: rgba(2,6,23,.5); z-index: 45; backdrop-filter: blur(2px); }
  .overlay.open { display: block; }
}
