/* ============================================================
   UNIPATH — Design System
   "The Ledger" — editorial, precise, trustworthy
   ============================================================ */

/* ----- Design Tokens ----- */
:root {
  /* Color */
  --navy:        #0A1F44;
  --navy-700:    #102a5c;
  --navy-600:    #1a3a73;
  --blue:        #2D6BFF;
  --blue-600:    #1d54d8;
  --blue-tint:   #EAF0FF;
  --paper:       #FBFAF8;
  --paper-2:     #F4F2EC;
  --ink:         #14181F;
  --ink-soft:    #44505F;
  --ink-faint:   #7A8794;
  --line:        #E4E0D6;
  --line-strong: #CFC9BB;
  --white:       #FFFFFF;
  --gold:        #C9A24B;
  --positive:    #1F8A5B;

  /* Type */
  --font-display: "Fraunces", Georgia, "Times New Roman", serif;
  --font-body:    "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-mono:    "IBM Plex Mono", ui-monospace, "SF Mono", Menlo, monospace;

  /* Scale */
  --step--1: clamp(0.79rem, 0.77rem + 0.10vw, 0.84rem);
  --step-0:  clamp(1.00rem, 0.96rem + 0.18vw, 1.10rem);
  --step-1:  clamp(1.20rem, 1.12rem + 0.38vw, 1.45rem);
  --step-2:  clamp(1.44rem, 1.30rem + 0.69vw, 1.91rem);
  --step-3:  clamp(1.73rem, 1.50rem + 1.13vw, 2.52rem);
  --step-4:  clamp(2.07rem, 1.72rem + 1.77vw, 3.33rem);
  --step-5:  clamp(2.49rem, 1.95rem + 2.68vw, 4.39rem);

  /* Space */
  --gap: 1.5rem;
  --section-y: clamp(4rem, 3rem + 5vw, 7.5rem);
  --container: 1180px;
  --container-narrow: 820px;

  /* Misc */
  --radius: 14px;
  --radius-sm: 9px;
  --shadow-sm: 0 1px 2px rgba(10,31,68,.06), 0 1px 1px rgba(10,31,68,.04);
  --shadow-md: 0 8px 30px rgba(10,31,68,.08), 0 2px 8px rgba(10,31,68,.04);
  --shadow-lg: 0 24px 60px rgba(10,31,68,.14), 0 8px 20px rgba(10,31,68,.06);
  --ease: cubic-bezier(.22,.61,.36,1);
}

/* ----- Reset ----- */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; }
}
body {
  font-family: var(--font-body);
  font-size: var(--step-0);
  line-height: 1.6;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img, svg { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; }
ul { list-style: none; padding: 0; }

/* ----- Layout ----- */
.container { width: 100%; max-width: var(--container); margin-inline: auto; padding-inline: clamp(1.25rem, 5vw, 2.5rem); }
.container--narrow { max-width: var(--container-narrow); }
.section { padding-block: var(--section-y); }
.section--tight { padding-block: clamp(3rem, 2rem + 4vw, 5rem); }
.section--paper2 { background: var(--paper-2); }
.section--navy { background: var(--navy); color: rgba(255,255,255,.92); }
.section--navy h1, .section--navy h2, .section--navy h3 { color: #fff; }

/* ----- Typography ----- */
h1, h2, h3, h4 { font-family: var(--font-display); font-weight: 540; line-height: 1.08; letter-spacing: -0.015em; color: var(--navy); font-optical-sizing: auto; }
h1 { font-size: var(--step-5); }
h2 { font-size: var(--step-4); }
h3 { font-size: var(--step-2); }
h4 { font-size: var(--step-1); }
p  { color: var(--ink-soft); }
.lead { font-size: var(--step-1); line-height: 1.5; color: var(--ink-soft); font-weight: 400; }
strong { color: var(--ink); font-weight: 600; }

.eyebrow {
  font-family: var(--font-mono);
  font-size: var(--step--1);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--blue);
  font-weight: 500;
  display: inline-flex;
  align-items: center;
  gap: .6rem;
}
.eyebrow::before {
  content: "";
  width: 1.6rem; height: 1px; background: var(--blue); opacity: .5;
}
.section--navy .eyebrow { color: #8FB0FF; }
.section--navy .eyebrow::before { background: #8FB0FF; }

.section-head { max-width: 60ch; margin-bottom: clamp(2.5rem, 4vw, 3.5rem); }
.section-head .eyebrow { margin-bottom: 1.1rem; }
.section-head p { margin-top: 1rem; font-size: var(--step-1); line-height: 1.5; }
.section-head--center { margin-inline: auto; text-align: center; }
.section-head--center .eyebrow { justify-content: center; }

/* ----- Buttons ----- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .55rem;
  padding: .9rem 1.6rem;
  border-radius: var(--radius-sm);
  font-weight: 600; font-size: var(--step-0);
  border: 1px solid transparent;
  transition: transform .18s var(--ease), background .18s var(--ease), box-shadow .18s var(--ease), border-color .18s var(--ease);
  white-space: nowrap; line-height: 1;
}
.btn svg { width: 1.05em; height: 1.05em; }
.btn--primary { background: var(--blue); color: #fff; box-shadow: 0 1px 2px rgba(45,107,255,.4), inset 0 1px 0 rgba(255,255,255,.18); }
.btn--primary:hover { background: var(--blue-600); transform: translateY(-1px); box-shadow: 0 8px 20px rgba(45,107,255,.28); }
.btn--dark { background: var(--navy); color: #fff; }
.btn--dark:hover { background: var(--navy-700); transform: translateY(-1px); }
.btn--ghost { background: transparent; color: var(--navy); border-color: var(--line-strong); }
.btn--ghost:hover { border-color: var(--navy); background: rgba(10,31,68,.03); }
.btn--light { background: #fff; color: var(--navy); }
.btn--light:hover { transform: translateY(-1px); box-shadow: var(--shadow-md); }
.btn--lg { padding: 1.05rem 2rem; font-size: var(--step-1); }
.btn--block { width: 100%; }
.btn--link { background: none; padding: 0; color: var(--blue); font-weight: 600; gap: .4rem; }
.btn--link:hover .arr { transform: translateX(3px); }
.arr { transition: transform .2s var(--ease); }

/* ----- Focus ----- */
:focus-visible { outline: 2.5px solid var(--blue); outline-offset: 2px; border-radius: 3px; }

/* ----- Reveal animation ----- */
.reveal { opacity: 0; transform: translateY(16px); transition: opacity .7s var(--ease), transform .7s var(--ease); }
.reveal.is-in { opacity: 1; transform: none; }
.reveal[data-delay="1"] { transition-delay: .08s; }
.reveal[data-delay="2"] { transition-delay: .16s; }
.reveal[data-delay="3"] { transition-delay: .24s; }
.reveal[data-delay="4"] { transition-delay: .32s; }

/* ----- Utility ----- */
.mono { font-family: var(--font-mono); font-feature-settings: "tnum"; }
.center { text-align: center; }
.muted { color: var(--ink-faint); }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }

/* ============================================================
   MOBILE OVERFLOW FIX — v2.2.0
   Prevent fixed-width header/form elements from creating right-side whitespace.
   ============================================================ */
html, body {
  max-width: 100%;
  overflow-x: hidden;
}

@supports (overflow-x: clip) {
  html, body { overflow-x: clip; }
}

body, .site-header, main, section, .deskhero, .site-footer {
  width: 100%;
}

.container, .deskhero__inner, .deskhero__lead, .slip, .grid, .card, .trustbar__inner {
  min-width: 0;
}

svg, img, video, iframe {
  max-width: 100%;
}
