/*
 * copax.app — shared styles (D86). Brand = the app's design C (docs/design/UI-DIRECTION.md):
 * CoPAX blue, Manrope, IBM Plex Mono only for flight / train / seat codes (as in the app).
 * The CSP forbids inline styles and scripts. Page-specific rules live in their own file, linked after this one:
 * assets/home.css (index, 404), assets/legal.css (privacy, terms), assets/pages.css (about, support).
 */

@font-face { font-family: "Manrope"; src: url("/assets/fonts/manrope_medium.ttf") format("truetype"); font-weight: 500; font-display: swap; }
@font-face { font-family: "Manrope"; src: url("/assets/fonts/manrope_semibold.ttf") format("truetype"); font-weight: 600; font-display: swap; }
@font-face { font-family: "Manrope"; src: url("/assets/fonts/manrope_bold.ttf") format("truetype"); font-weight: 700; font-display: swap; }
@font-face { font-family: "Manrope"; src: url("/assets/fonts/manrope_extrabold.ttf") format("truetype"); font-weight: 800; font-display: swap; }
@font-face { font-family: "IBM Plex Mono"; src: url("/assets/fonts/ibmplexmono_medium.ttf") format("truetype"); font-weight: 500; font-display: swap; }

:root {
  --blue: #1F3FBF;          /* primary: buttons, links, the brand mark */
  --blue-deep: #16309A;     /* text on the pale blue */
  --blue-pale: #E3E8FF;     /* tonal fills, selected */
  --teal: #0B7A6E;          /* ONLY for "verified" — as in the app */
  --teal-pale: #DDF3EF;
  --ink: #111726;           /* main text */
  --muted: #556070;         /* secondary text */
  --line: #DDE2EA;          /* hairlines, card borders */
  --ground: #F4F6F9;        /* page background */
  --surface: #FFFFFF;       /* cards */
  --focus: #1F3FBF;

  --font: "Manrope", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, "SF Mono", monospace;

  /* type scale (1.25, base 17px) */
  --t-body: 1.0625rem;
  --t-small: 0.9375rem;
  --t-h3: 1.3125rem;
  --t-h2: 1.875rem;
  --t-h1: clamp(2.25rem, 1.4rem + 3.6vw, 3.75rem);

  --wrap: 72rem;
  --gutter: clamp(1rem, 0.5rem + 2.5vw, 2rem);
  --radius-l: 24px;         /* cards, as in the app */
  --radius-m: 14px;
  --radius-pill: 999px;
}

@media (prefers-color-scheme: dark) {
  :root {
    --blue: #9DB0FF;
    --blue-deep: #DCE3FF;
    --blue-pale: #1C2550;
    --teal: #5ED0C0;
    --teal-pale: #0F3A35;
    --ink: #E8ECF4;
    --muted: #A9B2C3;
    --line: #2A3243;
    --ground: #0F131C;
    --surface: #171C27;
    --focus: #9DB0FF;
  }
  .btn-primary { color: #0F131C; }   /* dark text on the light dark-mode blue (contrast) */
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--ground);
  color: var(--ink);
  font-family: var(--font);
  font-size: var(--t-body);
  font-weight: 500;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
img, svg { max-width: 100%; height: auto; display: block; }

h1, h2, h3 { font-weight: 800; letter-spacing: -0.02em; line-height: 1.12; margin: 0 0 0.5em; }
h1 { font-size: var(--t-h1); }
h2 { font-size: var(--t-h2); }
h3 { font-size: var(--t-h3); letter-spacing: -0.01em; }
p { margin: 0 0 1em; max-width: 68ch; }
a { color: var(--blue); text-underline-offset: 0.18em; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; border-radius: 6px; }
.code { font-family: var(--mono); font-weight: 500; letter-spacing: 0; }
.muted { color: var(--muted); }

.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gutter); }

.skip { position: absolute; left: -999px; top: 0; background: var(--surface); padding: 0.5rem 1rem; z-index: 10; }
.skip:focus { left: 1rem; top: 1rem; }

/* header */
.site-header { background: var(--ground); }
.header-row { display: flex; align-items: center; justify-content: space-between; gap: 1rem; min-height: 4.5rem; }
.brand { display: inline-flex; align-items: center; gap: 0.6rem; color: var(--ink); text-decoration: none; }
.wordmark { font-weight: 800; font-size: 1.25rem; letter-spacing: -0.02em; }
.site-nav { display: flex; gap: clamp(0.75rem, 2vw, 1.75rem); }
.site-nav a { color: var(--ink); text-decoration: none; font-weight: 600; font-size: var(--t-small); padding: 0.5rem 0; }
.site-nav a:hover, .site-nav a[aria-current="page"] { color: var(--blue); }

/* buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem;
  min-height: 3rem; padding: 0 1.4rem; border-radius: var(--radius-pill);
  font: 700 1rem/1 var(--font); text-decoration: none; border: 2px solid transparent;
}
.btn-primary { background: var(--blue); color: #FFFFFF; }
.btn-tonal { background: var(--blue-pale); color: var(--blue-deep); }
.btn-outline { border-color: var(--line); color: var(--ink); background: var(--surface); }

/* cards and chips */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-l); padding: clamp(1.25rem, 3vw, 2rem); }
.chip { display: inline-flex; align-items: center; gap: 0.4rem; min-height: 2rem; padding: 0 0.8rem; border-radius: 10px; font-size: 0.875rem; font-weight: 700; }
.chip-verified { background: var(--teal-pale); color: var(--teal); }
.chip-tonal { background: var(--blue-pale); color: var(--blue-deep); }

/* sections */
.section { padding-top: clamp(3rem, 7vw, 6rem); padding-bottom: clamp(3rem, 7vw, 6rem); }

/* long-form text pages (privacy, terms, about, support) */
.prose { max-width: 46rem; }
.prose h2 { font-size: 1.5rem; margin-top: 2.5rem; }
.prose h3 { font-size: 1.1875rem; margin-top: 1.75rem; }
.prose ul, .prose ol { padding-left: 1.25rem; max-width: 68ch; }
.prose li { margin: 0.35rem 0; }
.page-head { padding-top: clamp(2.5rem, 6vw, 4.5rem); padding-bottom: 1.5rem; }
.page-head p { color: var(--muted); font-size: 1.125rem; }

/* footer */
.site-footer { border-top: 1px solid var(--line); margin-top: 4rem; padding: 2.5rem 0 2rem; }
.footer-row { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 1.5rem; }
.footer-brand p { margin: 0.6rem 0 0; font-size: var(--t-small); }
.footer-nav { display: flex; flex-wrap: wrap; gap: 1.25rem; align-items: center; }
.footer-nav a { color: var(--ink); text-decoration: none; font-weight: 600; font-size: var(--t-small); }
.footer-legal { margin-top: 1.5rem; font-size: 0.875rem; color: var(--muted); }
.footer-legal p { margin: 0; }

@media (max-width: 480px) {
  .site-nav { gap: 0.9rem; }
  .wordmark { font-size: 1.125rem; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}

