/* ==========================================================================
   base.css — design tokens, reset, shared building blocks.
   Loaded on every page, first. Page-specific styles live in their own files.
   ========================================================================== */

:root {
  /* Brand */
  --blue: #2563eb;
  --blue-dark: #1d4ed8;
  --blue-soft: #dbeafe;
  --violet: #7c3aed;
  --green: #16a34a;
  --green-soft: #dcfce7;
  --red: #b42318;
  --red-soft: #fef3f2;

  /* Neutrals */
  --ink: #0f172a;
  --bg: #ffffff;
  --surface: #ffffff;
  --surface2: #f1f5f9;
  --border: #e2e8f0;
  --border2: #cbd5e1;
  --text: #0f172a;
  --text2: #64748b;
  --text3: #94a3b8;
  --text2-strong: #475569;  /* secondary text on --surface2, keeps 4.5:1 contrast */

  /* Backgrounds */
  --hero-gradient: linear-gradient(180deg, #eaf1ff 0%, #f6f3ff 62%, #fff 100%);
  --alt-gradient: linear-gradient(180deg, #f6f9ff, #f8f5ff);
  --brand-gradient: linear-gradient(135deg, var(--blue), var(--violet));

  /* Shape & depth */
  --radius-sm: 10px;
  --radius: 14px;
  --radius-lg: 20px;
  --radius-xl: 24px;
  --shadow-soft: 0 4px 14px rgba(30, 64, 175, .08);
  --shadow-card: 0 18px 40px -18px rgba(30, 64, 175, .22);
  --shadow-lift: 0 28px 50px -20px rgba(30, 64, 175, .3);

  /* Type & layout */
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Inter, Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  --max-w: 1120px;
  --gutter: 24px;
  --nav-h: 64px;
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.6;
  background: var(--bg);
  color: var(--text);
  -webkit-font-smoothing: antialiased;
}
img, svg { max-width: 100%; }
a { color: inherit; }

/* ---------- Layout helpers ---------- */
.wrap { max-width: var(--max-w); margin: 0 auto; padding: 0 var(--gutter); }

.section { padding: 96px 0; }
.section.alt { background: var(--alt-gradient); }
.section-head { margin-bottom: 48px; }
.section-head.center { text-align: center; }
.section-head.center .section-title,
.section-head.center .section-sub { margin-left: auto; margin-right: auto; }
.section-tag {
  display: inline-block; margin-bottom: 14px; padding: 5px 12px;
  font-size: 13px; font-weight: 700; color: var(--blue-dark);
  background: var(--blue-soft); border-radius: 100px;
}
.section-title {
  max-width: 760px;
  font-size: clamp(28px, 4vw, 44px); font-weight: 800;
  line-height: 1.1; letter-spacing: -.035em;
}
.section-title strong { color: var(--blue); font-weight: 800; }
.section-sub { max-width: 620px; margin-top: 14px; font-size: 17px; color: var(--text2); }
.prose { max-width: 760px; margin-top: 36px; font-size: 16px; line-height: 1.8; color: var(--text2); }

/* ---------- Components ---------- */
.card {
  background: var(--surface);
  border: 1px solid rgba(226, 232, 240, .6);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-card);
}

.ico {
  width: 46px; height: 46px; margin-bottom: 18px;
  display: grid; place-items: center;
  color: var(--blue); background: var(--blue-soft); border-radius: var(--radius);
}
.ico svg { width: 22px; height: 22px; }

.pill {
  display: inline-block; align-self: flex-start;
  padding: 4px 10px; font-size: 12px; font-weight: 700;
  color: var(--blue); background: var(--blue-soft); border-radius: 100px;
}

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 12px 22px; border: 1px solid var(--border); border-radius: var(--radius);
  font: inherit; font-size: 15px; font-weight: 600; text-decoration: none;
  color: var(--ink); background: var(--surface); cursor: pointer;
  transition: background .15s, border-color .15s, transform .1s;
}
.btn:hover { background: var(--surface2); }
.btn:active { transform: scale(.97); }
.btn-primary {
  color: #fff; background: var(--blue); border-color: var(--blue);
  box-shadow: 0 8px 20px -8px rgba(37, 99, 235, .6);
}
.btn-primary:hover { background: var(--blue-dark); border-color: var(--blue-dark); }


@keyframes spin { to { transform: rotate(360deg); } }
@keyframes rise { from { opacity: 0; transform: translateY(6px); } }

@media (max-width: 640px) {
  :root { --gutter: 16px; }
  .section { padding: 64px 0; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

/* Keyboard focus ring (mouse clicks do not show it). */
:where(a, button, summary, [role="button"], [tabindex]):focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; }
