/* ──────────────────────────────────────────────────────────────────────────
   Elinea — shared site CSS
   Loaded by every page. Anything that touches more than one page lives here
   so it only needs to be edited in one place. Page-specific styles stay
   inline in the page that owns them.
   ────────────────────────────────────────────────────────────────────────── */

:root {
  /* Neutrals — cool stone (subtle blue tint to sit with tech accent) */
  --stone-50: oklch(0.985 0.004 250);
  --stone-75: oklch(0.975 0.005 250);
  --stone-100: oklch(0.955 0.006 250);
  --stone-200: oklch(0.9 0.008 250);
  --stone-300: oklch(0.82 0.01 250);
  --stone-500: oklch(0.58 0.012 250);
  --stone-700: oklch(0.4 0.014 250);
  --stone-900: oklch(0.22 0.014 250);
  --stone-950: oklch(0.16 0.014 250);

  /* Accent — deep ink blue (more authoritative than electric blue) */
  --blue-50: oklch(0.96 0.025 255);
  --blue-100: oklch(0.9 0.06 255);
  --blue-500: oklch(0.52 0.18 255);
  --blue-600: oklch(0.42 0.17 255);
  --blue-700: oklch(0.34 0.15 255);
  --blue-800: oklch(0.26 0.12 255);

  /* Secondary — violet */
  --violet-500: oklch(0.62 0.22 305);
  --violet-600: oklch(0.54 0.22 305);

  /* Semantic tokens */
  --surface: var(--stone-50);
  --surface-raised: #ffffff;
  --surface-alt: var(--stone-100);
  --surface-inverse: var(--stone-950);
  --text-primary: var(--stone-950);
  --text-secondary: var(--stone-700);
  --text-tertiary: var(--stone-500);
  --text-inverse: var(--stone-50);
  --border: var(--stone-200);
  --border-strong: var(--stone-300);

  --accent: var(--blue-600);
  --accent-hover: var(--blue-700);
  --accent-active: var(--blue-800);
  --accent-soft: var(--blue-50);
  --accent-secondary: var(--violet-600);

  --font-display: "Inter Tight", "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-body: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;

  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;

  /* Match the nav pill's inner content edges so .wrap content lines up with
     the brand mark on the left and the Sign up button on the right. */
  --max: 1400px;
  --gutter: clamp(24px, 4vw, 56px);
}

* { box-sizing: border-box; }
html {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  scroll-behavior: smooth;
}
body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.55;
  color: var(--text-primary);
  background: #ffffff;
  font-feature-settings: "ss01", "cv11";
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 500;
  letter-spacing: -0.022em;
  margin: 0;
  color: var(--text-primary);
  text-wrap: balance;
}
p { text-wrap: pretty; }

/* ── Layout ── */
.wrap {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 var(--gutter);
}
section {
  padding: clamp(72px, 12vw, 140px) 0;
}

/* ── Top nav: full-width bar at rest, morphs into floating pill on scroll ── */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 50;
  pointer-events: none;
  background: transparent;
  border-bottom: 1px solid transparent;
  transition: background 260ms ease, border-color 260ms ease;
}
body.is-scrolled .nav {
  background: transparent;
  border-bottom-color: transparent;
}
.nav-inner {
  pointer-events: auto;
  display: flex;
  align-items: center;
  gap: 32px;
  height: 72px;
  max-width: 100vw;          /* at rest: span full viewport */
  margin: 0 auto;
  padding: 0 clamp(24px, 4vw, 56px);
  background: transparent;
  border: 1px solid transparent;
  border-radius: 0;
  box-shadow: 0 0 0 rgba(0, 0, 0, 0);
  transition:
    max-width 320ms cubic-bezier(0.22, 0.61, 0.36, 1),
    border-radius 320ms cubic-bezier(0.22, 0.61, 0.36, 1),
    margin-top 320ms cubic-bezier(0.22, 0.61, 0.36, 1),
    background 260ms ease,
    border-color 260ms ease,
    box-shadow 260ms ease,
    backdrop-filter 260ms ease;
}
body.is-scrolled .nav-inner {
  max-width: 1400px;          /* scrolled: collapse into centered pill */
  margin-top: 14px;
  border-radius: 999px;
  background: color-mix(in oklab, #ffffff 82%, transparent);
  backdrop-filter: saturate(1.3) blur(16px);
  -webkit-backdrop-filter: saturate(1.3) blur(16px);
  border-color: color-mix(in oklab, var(--stone-300) 55%, transparent);
  box-shadow: 0 12px 32px -14px oklch(0.16 0.014 250 / 0.18);
}
.brand {
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 600;
  letter-spacing: -0.025em;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--text-primary);
}
.brand .mark { width: 22px; height: 22px; }
.nav-links {
  display: flex;
  align-items: center;
  gap: 28px;
  flex: 1;
}
.nav-links a {
  color: var(--text-secondary);
  font-size: 14.5px;
  font-weight: 500;
  letter-spacing: -0.005em;
  transition: color 160ms ease;
}
.nav-links a:hover { color: var(--text-primary); }
.nav-actions {
  display: flex;
  align-items: center;
  gap: 20px;
}
.nav-actions .link {
  color: var(--text-secondary);
  font-size: 14.5px;
  font-weight: 500;
  transition: color 160ms ease;
}
.nav-actions .link:hover { color: var(--text-primary); }
.nav-hide-md { display: none; }
@media (min-width: 860px) {
  .nav-hide-md { display: inline-flex; }
}

/* ── Buttons ── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 46px;
  padding: 0 20px;
  border-radius: 999px;
  font-family: var(--font-body);
  font-size: 14.5px;
  font-weight: 600;
  letter-spacing: -0.005em;
  border: 1px solid transparent;
  cursor: pointer;
  transition:
    background 180ms ease,
    border-color 180ms ease,
    color 180ms ease,
    transform 180ms ease;
  white-space: nowrap;
}
.btn:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}
.btn-primary {
  background: var(--accent);
  color: #fff;
}
.btn-primary:hover { background: var(--accent-hover); }
.btn-primary:active { background: var(--accent-active); }

/* ── Request Access modal ── */
dialog.modal {
  border: 0;
  padding: 0;
  background: transparent;
  color: var(--text-primary);
  max-width: 520px;
  width: calc(100% - 32px);
  margin: auto;
  max-height: calc(100vh - 32px);
}
dialog.modal::backdrop {
  background: oklch(0.16 0.014 250 / 0.5);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}
dialog.modal[open] {
  animation: modal-in 220ms cubic-bezier(0.22, 0.61, 0.36, 1);
}
@keyframes modal-in {
  from { opacity: 0; transform: translateY(8px) scale(0.985); }
  to   { opacity: 1; transform: none; }
}
.modal-card {
  position: relative;
  background:
    radial-gradient(ellipse 70% 50% at 100% 0%, oklch(0.65 0.18 255 / 0.08), transparent 60%),
    #ffffff;
  border-radius: var(--radius-lg);
  padding: clamp(28px, 4vw, 40px);
  box-shadow:
    0 32px 64px -20px oklch(0.16 0.014 250 / 0.25),
    0 0 0 1px oklch(0.82 0.01 250 / 0.6);
  max-height: calc(100vh - 32px);
  overflow-y: auto;
}
.modal-close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 36px;
  height: 36px;
  border: 0;
  background: transparent;
  border-radius: 999px;
  color: var(--text-tertiary);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: background 160ms ease, color 160ms ease;
  z-index: 1;
}
.modal-close:hover {
  background: var(--surface);
  color: var(--text-primary);
}
.modal-eyebrow {
  font-family: var(--font-body);
  font-size: 12.5px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  margin: 0 0 12px;
}
.modal-title {
  font-family: var(--font-display);
  font-size: clamp(26px, 2.8vw, 32px);
  line-height: 1.1;
  letter-spacing: -0.028em;
  font-weight: 600;
  color: var(--text-primary);
  margin: 0 0 10px;
  text-wrap: balance;
}
.modal-sub {
  font-size: 15px;
  line-height: 1.5;
  color: var(--text-secondary);
  margin: 0 0 24px;
  max-width: 38ch;
}
.modal-form {
  display: grid;
  gap: 14px;
}
.ra-field {
  display: grid;
  gap: 6px;
}
.ra-field label {
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: -0.005em;
  color: var(--text-primary);
}
.ra-optional {
  color: var(--text-tertiary);
  font-weight: 500;
}
.ra-field input,
.ra-field select,
.ra-field textarea {
  font-family: var(--font-body);
  font-size: 14.5px;
  line-height: 1.4;
  color: var(--text-primary);
  background: var(--stone-75);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 10px 12px;
  width: 100%;
  outline: none;
  transition: border-color 160ms ease, background 160ms ease, box-shadow 160ms ease;
  appearance: none;
  -webkit-appearance: none;
}
.ra-field select {
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12' fill='none'><path d='M3 4.5L6 7.5L9 4.5' stroke='%23555' stroke-width='1.4' stroke-linecap='round' stroke-linejoin='round'/></svg>");
  background-repeat: no-repeat;
  background-position: right 12px center;
  padding-right: 32px;
}
.ra-field textarea {
  resize: vertical;
  min-height: 72px;
}
.ra-field input::placeholder,
.ra-field textarea::placeholder {
  color: var(--text-tertiary);
}
.ra-field input:focus,
.ra-field select:focus,
.ra-field textarea:focus {
  border-color: var(--accent);
  background: #ffffff;
  box-shadow: 0 0 0 3px oklch(0.52 0.18 255 / 0.15);
}
.ra-field-invalid input,
.ra-field-invalid select,
.ra-field-invalid textarea {
  border-color: oklch(0.55 0.2 25);
}
.ra-field-row {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
}
@media (min-width: 480px) {
  .ra-field-row { grid-template-columns: 1fr 1fr; }
}
.ra-submit {
  margin-top: 6px;
  width: 100%;
  height: 48px;
}
.ra-submit[aria-busy="true"] {
  opacity: 0.7;
  pointer-events: none;
}
.ra-submit .arrow { transition: transform 220ms ease; }
.ra-submit:hover .arrow { transform: translateX(3px); }
.ra-error {
  font-size: 13.5px;
  color: oklch(0.5 0.2 25);
  margin: 0;
}
.ra-fineprint {
  font-size: 12px;
  line-height: 1.45;
  color: var(--text-tertiary);
  margin: 12px 0 0;
  text-align: center;
}
.modal-success {
  text-align: center;
  padding: 16px 0 4px;
}
.ra-success-mark {
  width: 56px;
  height: 56px;
  margin: 0 auto 20px;
  color: var(--accent);
}
.modal-success .modal-title { margin-bottom: 12px; }
.modal-success .modal-sub { margin: 0 auto 24px; }
.ra-close { min-width: 140px; }
@media (max-width: 520px) {
  .modal-card { padding: 28px 20px; }
}

/* ── Footer ── */
footer.site-footer {
  background: var(--surface);
  border-top: 1px solid var(--border);
  padding: 56px 0 48px;
}
.foot-brand {
  padding-bottom: 32px;
  margin-bottom: 24px;
  border-bottom: 1px solid var(--border);
  max-width: 520px;
}
.foot-wordmark {
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 600;
  letter-spacing: -0.02em;
  color: var(--text-primary);
  margin-bottom: 6px;
}
.foot-tagline {
  margin: 0;
  font-size: 15px;
  line-height: 1.45;
  color: var(--text-secondary);
}
.foot {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  font-size: 13.5px;
  color: var(--text-tertiary);
}
.foot-links { display: flex; gap: 24px; }
.foot-links a {
  color: var(--text-tertiary);
  transition: color 160ms ease;
}
.foot-links a:hover { color: var(--text-primary); }
