/* base.css — reset + design tokens */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}
html {
  -moz-text-size-adjust: none;
  -webkit-text-size-adjust: none;
  text-size-adjust: none;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  scroll-behavior: smooth;
  hanging-punctuation: first last;
  scroll-padding-top: 96px;
}

/* --- Scroll landing (fleet standard) --- */
:target { scroll-margin-top: 96px; }
section[id],
main[id],
.scroll-anchor {
  scroll-margin-top: 96px;
}
@media (max-width: 640px) {
  html { scroll-padding-top: 64px; }
  section[id], main[id], :target, .scroll-anchor { scroll-margin-top: 64px; }
}
body {
  min-height: 100dvh;
  line-height: 1.6;
  font-family: var(--font-body);
  font-size: var(--text-base);
  color: var(--color-text);
  background-color: var(--color-bg);
}
img,
picture,
video,
canvas,
svg {
  display: block;
  max-width: 100%;
  height: auto;
}
ul[role='list'],
ol[role='list'] {
  list-style: none;
}
input,
button,
textarea,
select {
  font: inherit;
  color: inherit;
}
h1,
h2,
h3,
h4,
h5,
h6 {
  text-wrap: balance;
  line-height: 1.1;
  font-family: var(--font-display);
  font-weight: 400;
  letter-spacing: -0.01em;
}
p,
li,
figcaption {
  text-wrap: pretty;
}
::selection {
  background: oklch(from var(--color-primary) l c h / 0.28);
  color: var(--color-text);
}
:focus-visible {
  outline: 2px solid var(--color-primary);
  outline-offset: 3px;
  border-radius: 4px;
}
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
button {
  cursor: pointer;
  background: none;
  border: none;
  font-family: inherit;
}
a {
  color: inherit;
  text-decoration: none;
}

/* ===================== TOKENS ===================== */
:root {
  --font-display: 'Cormorant Garamond', 'Iowan Old Style', 'Times New Roman', Georgia, serif;
  --font-body: 'Inter', 'Helvetica Neue', system-ui, sans-serif;

  --text-xs: clamp(0.7rem, 0.68rem + 0.1vw, 0.78rem);
  --text-sm: clamp(0.82rem, 0.78rem + 0.2vw, 0.9rem);
  --text-base: clamp(0.95rem, 0.92rem + 0.15vw, 1.02rem);
  --text-lg: clamp(1.05rem, 1rem + 0.35vw, 1.2rem);
  --text-xl: clamp(1.3rem, 1.1rem + 0.8vw, 1.75rem);
  --text-2xl: clamp(1.75rem, 1.2rem + 1.8vw, 2.6rem);
  --text-3xl: clamp(2.2rem, 1.2rem + 3vw, 3.6rem);
  --text-hero: clamp(2.4rem, 1.2rem + 4vw, 4.4rem);

  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-5: 1.25rem;
  --space-6: 1.5rem;
  --space-8: 2rem;
  --space-10: 2.5rem;
  --space-12: 3rem;
  --space-16: 4rem;
  --space-20: 5rem;
  --space-24: 6rem;
  --space-32: 8rem;

  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 14px;
  --radius-xl: 20px;
  --radius-pill: 999px;

  --content-narrow: 640px;
  --content-default: 1040px;
  --content-wide: 1240px;

  --transition: 260ms cubic-bezier(0.16, 1, 0.3, 1);
}

/* LIGHT — PMA brand: navy ink on white with teal accent */
:root,
[data-theme='light'] {
  --color-bg: #ffffff;
  --color-surface: #f7faf9;
  --color-surface-2: #ffffff;
  --color-surface-offset: #eef4f4;
  --color-border: #cfd8d8;
  --color-divider: #e2e9e9;
  --color-hairline: #b8c5c5;

  --color-text: #1b3a4b;           /* PMA deep navy — from the brand */
  --color-text-muted: #4c6673;
  --color-text-faint: #8a9ba3;
  --color-text-inverse: #ffffff;

  --color-primary: #1b3a4b;        /* deep navy — text and structure */
  --color-primary-hover: #24485c;
  --color-primary-active: #10293a;
  --color-primary-highlight: #e0edee;

  --color-teal: #189aa4;           /* PMA signature teal */
  --color-teal-hover: #12808a;
  --color-teal-soft: #a8dde2;
  --color-teal-tint: #e3f4f5;

  --color-accent: #189aa4;         /* accent = teal */
  --color-accent-soft: #a8dde2;

  --shadow-sm: 0 1px 2px oklch(0.3 0.05 210 / 0.06);
  --shadow-md: 0 6px 20px oklch(0.3 0.05 210 / 0.08);
  --shadow-lg: 0 20px 50px oklch(0.3 0.05 210 / 0.14);
  --shadow-portrait: 0 30px 60px -25px oklch(0.3 0.05 210 / 0.28);
}

/* DARK — deep teal-navy */
[data-theme='dark'] {
  --color-bg: #0b2530;
  --color-surface: #0f2d3a;
  --color-surface-2: #143845;
  --color-surface-offset: #0d2a35;
  --color-border: #2a4a58;
  --color-divider: #1a3a48;
  --color-hairline: #345666;

  --color-text: #e6f2f3;
  --color-text-muted: #94b1b8;
  --color-text-faint: #607580;
  --color-text-inverse: #0b2530;

  --color-primary: #e6f2f3;
  --color-primary-hover: #ffffff;
  --color-primary-active: #c8e6e9;
  --color-primary-highlight: #1a3a48;

  --color-teal: #4dc7d1;
  --color-teal-hover: #6ad2db;
  --color-teal-soft: #245e66;
  --color-teal-tint: #143845;

  --color-accent: #4dc7d1;
  --color-accent-soft: #6ad2db;

  --shadow-sm: 0 1px 2px oklch(0 0 0 / 0.4);
  --shadow-md: 0 8px 24px oklch(0 0 0 / 0.55);
  --shadow-lg: 0 24px 60px oklch(0 0 0 / 0.7);
  --shadow-portrait: 0 40px 80px -30px oklch(0 0 0 / 0.75);
}
