/* Pavryn — three colours only: slate, off-white, teal. Teal is never text on light backgrounds. */
@font-face { font-family: "Space Grotesk"; font-weight: 300; font-display: swap; src: url("/fonts/space-grotesk-300.woff2") format("woff2"); }
@font-face { font-family: "Space Grotesk"; font-weight: 500; font-display: swap; src: url("/fonts/space-grotesk-500.woff2") format("woff2"); }
@font-face { font-family: "Space Grotesk"; font-weight: 600; font-display: swap; src: url("/fonts/space-grotesk-600.woff2") format("woff2"); }
@font-face { font-family: "Inter"; font-weight: 400; font-display: swap; src: url("/fonts/inter-400.woff2") format("woff2"); }
@font-face { font-family: "Inter"; font-weight: 600; font-display: swap; src: url("/fonts/inter-600.woff2") format("woff2"); }

/* Palette + roles. Light is the default; dark swaps the roles (see the two dark blocks below). */
:root {
  --slate: #1F2A37;
  --off-white: #F2F1EC;
  --teal: #29CBBB;
  --display: "Space Grotesk", system-ui, sans-serif;
  --body: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --radius: 12px;

  --bg: var(--off-white);        /* page */
  --fg: var(--slate);            /* text, lines, logo */
  --band-bg: var(--slate);       /* the contrasting "How we work" band */
  --band-fg: var(--off-white);
  --band-num: var(--teal);       /* step numbers: teal only on a slate band */
  --focus: var(--slate);
  --band-focus: var(--teal);
  color-scheme: light;
}
/* Dark: the device asks for it and the visitor hasn't chosen light ... */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: var(--slate); --fg: var(--off-white);
    --band-bg: var(--off-white); --band-fg: var(--slate); --band-num: var(--slate);
    --focus: var(--teal); --band-focus: var(--slate);
    color-scheme: dark;
  }
}
/* ... or the visitor chose dark with the toggle. Keep in sync with the block above. */
:root[data-theme="dark"] {
  --bg: var(--slate); --fg: var(--off-white);
  --band-bg: var(--off-white); --band-fg: var(--slate); --band-num: var(--slate);
  --focus: var(--teal); --band-focus: var(--slate);
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { background: var(--bg); color: var(--fg); font: 400 1rem/1.625 var(--body); -webkit-text-size-adjust: 100%; }
body { margin: 0; }
img, svg { display: block; max-width: 100%; }
h1, h2, h3 { font-family: var(--display); font-weight: 600; line-height: 1.15; margin: 0 0 .5em; }
h1 { font-size: clamp(2.4rem, 6vw, 4rem); letter-spacing: -.01em; }
h2 { font-size: clamp(1.75rem, 3.5vw, 2.25rem); }
h3 { font-size: 1.3rem; font-weight: 500; }
p { margin: 0 0 1em; }
.wrap { max-width: 72rem; margin: 0 auto; padding: 0 1.5rem; }

/* Logo and mark: their slate parts follow the text colour, so they flip with the theme. */
svg [fill="#1F2A37"] { fill: var(--fg); }

/* links: always underlined, teal underline */
a { color: inherit; text-decoration: underline; text-decoration-color: var(--teal); text-decoration-thickness: 2px; text-underline-offset: .2em; }
a:hover { text-decoration-thickness: 4px; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; border-radius: 4px; }
.process :focus-visible { outline-color: var(--band-focus); }
.site-footer :focus-visible { outline-color: var(--teal); }

.skip { position: absolute; left: 1rem; top: -4rem; background: var(--fg); color: var(--bg); padding: .6rem 1rem; border-radius: 8px; z-index: 10; }
.skip:focus { top: 1rem; }

.label { font: 500 .78rem/1.4 var(--display); letter-spacing: .18em; text-transform: uppercase; margin-bottom: .75rem; }
.label::before { content: ""; display: inline-block; width: 1.4rem; height: 3px; background: var(--teal); margin-right: .6rem; vertical-align: middle; }

/* buttons: teal fill + slate label (7.2:1) */
.btn { display: inline-block; font: 600 1rem/1 var(--body); padding: .9rem 1.3rem; border-radius: 8px; border: 2px solid var(--teal); text-decoration: none; }
.btn-primary { background: var(--teal); color: var(--slate); }
.btn-primary:hover { background: var(--fg); color: var(--bg); border-color: var(--fg); }
.btn-small { padding: .65rem 1rem; font-size: .95rem; }

.site-header { padding: 1.25rem 0; }
.header-row { display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.header-actions { display: flex; align-items: center; gap: .75rem; }
.brand { display: block; text-decoration: none; }
.brand svg { width: 178px; height: auto; }  /* symbol lockup: keeps the word at ~36 px */

/* light/dark toggle: shown only when JavaScript runs (theme.js removes `hidden`) */
.theme-toggle { display: inline-flex; align-items: center; justify-content: center; width: 2.75rem; height: 2.75rem;
  border: 2px solid var(--fg); border-radius: 8px; background: transparent; color: var(--fg); cursor: pointer; padding: 0; }
.theme-toggle[hidden] { display: none; }
.theme-toggle:hover { background: var(--fg); color: var(--bg); }
.theme-toggle svg { width: 1.3rem; height: 1.3rem; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.theme-toggle .sun { display: none; }
.theme-toggle[aria-pressed="true"] .sun { display: block; }
.theme-toggle[aria-pressed="true"] .moon { display: none; }

.hero { padding: clamp(2.5rem, 7vw, 6rem) 0 clamp(3rem, 7vw, 6rem); }
.hero-grid { display: grid; grid-template-columns: 1.5fr 1fr; gap: 3rem; align-items: center; }
.hl { background: linear-gradient(transparent 72%, var(--teal) 72%, var(--teal) 92%, transparent 92%); padding: 0 .05em; }
.lead { font-size: 1.15rem; max-width: 38rem; }
.actions { display: flex; flex-wrap: wrap; align-items: center; gap: 1rem 1.75rem; margin-top: 1.75rem; }
.link { font-weight: 600; }
.hero-mark svg { width: min(100%, 300px); height: auto; margin-left: auto; }

.services { padding: 4rem 0 5rem; }
.cards { display: grid; grid-template-columns: 1fr 1fr; gap: 1.5rem; margin-top: 2rem; }
.card { border: 2px solid var(--fg); border-radius: var(--radius); padding: 2rem; }
.card p { max-width: 32rem; }
.card ul { margin: 0; padding-left: 1.1rem; }
.card li { margin-bottom: .35rem; }
.card li::marker { color: var(--teal); }
.icon { width: 40px; height: 40px; fill: none; stroke: var(--fg); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; margin-bottom: 1.25rem; }

/* The contrasting band: slate on light pages, off-white on dark pages. */
.process { background: var(--band-bg); color: var(--band-fg); padding: 5rem 0; }
.steps { list-style: none; margin: 2.5rem 0 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 2rem; }
.steps li { border-top: 3px solid var(--teal); padding-top: 1.25rem; }
.num { display: block; font: 600 1rem var(--display); color: var(--band-num); margin-bottom: .5rem; }

.name { padding: 5rem 0; }
.name-grid { display: grid; grid-template-columns: auto 1fr; gap: 2.5rem; align-items: center; max-width: 52rem; }
.name-mark svg { width: 96px; height: auto; }

/* The teal band and the footer look the same in both themes. */
.contact { background: var(--teal); color: var(--slate); padding: 5rem 0; }
.contact h2 { font-size: clamp(2.2rem, 5vw, 3.5rem); }
.email { font: 600 clamp(1.5rem, 4vw, 2.4rem)/1.2 var(--display); margin: 1.5rem 0 0; }
.contact a { text-decoration-color: var(--slate); }
.contact :focus-visible { outline-color: var(--slate); }

.site-footer { background: var(--slate); color: var(--off-white); padding: 3rem 0; font-size: .92rem; }
.footer-grid { display: grid; grid-template-columns: auto 1fr; gap: 3rem; align-items: start; }
.site-footer svg { width: 160px; height: auto; }
.legal p { margin: 0 0 .35rem; }

/* Text pages (privacy): comfortable reading width */
.page { padding: clamp(2rem, 5vw, 4rem) 0 5rem; }
.prose { max-width: 46rem; }
.prose h1 { font-size: clamp(2.2rem, 5vw, 3.25rem); }
.prose h2 { font-size: 1.5rem; margin-top: 2.5rem; }
.prose h3 { font-size: 1.1rem; margin-top: 1.5rem; }
.prose ul { padding-left: 1.2rem; margin: 0 0 1em; }
.prose li { margin-bottom: .5rem; }
.prose li::marker { color: var(--teal); }
.updated { font-size: .92rem; margin-bottom: 1.5rem; }

@media (max-width: 760px) {
  .hero-grid, .cards, .steps, .footer-grid { grid-template-columns: 1fr; }
  .hero-mark { display: none; }
  .name-grid { grid-template-columns: 1fr; gap: 1.25rem; }
  .brand svg { width: 146px; }
  .header-actions { gap: .5rem; }
}
@media (prefers-reduced-motion: no-preference) {
  .btn, a, .theme-toggle { transition: background-color .15s, color .15s, text-decoration-thickness .15s; }
}
