/* fidvela.com. Every colour, size and radius comes from DESIGN.md. */

@font-face {
  font-family: "Hanken Grotesk";
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url("/assets/hanken-grotesk-latin-wght.1f21c6eaa0.woff2") format("woff2");
}

:root {
  --canvas: #fafbfc;
  --surface: #f1f3f6;
  --ink: #14181f;
  --ink-muted: #4a5361;
  --hairline: #dde1e7;
  --field-edge: #7d8794;
  --accent: #0b4f6c;
  --accent-hover: #083d54;
  --on-accent: #ffffff;
  --accent-tint: #e7f0f3;
  --attention-ink: #9a3412;
  --attention-tint: #fdf0e8;
  --clear-ink: #166534;
  --clear-tint: #ebf5ee;
  --note-ink: #475569;
  --note-tint: #eef1f5;
  --error-ink: #b42318;

  --radius-control: 6px;
  --radius-panel: 8px;
  --radius-tag: 4px;

  --gutter: 20px;
  --section: 64px;
  --container: 1120px;
  --reading: 720px;
  --header-height: 64px;

  --font: "Hanken Grotesk", system-ui, -apple-system, "Segoe UI", sans-serif;
  color-scheme: light;
}

@media (min-width: 768px) {
  :root { --gutter: 32px; --section: 96px; }
}

*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-padding-top: calc(var(--header-height) + 16px);
}

body {
  margin: 0;
  background: var(--canvas);
  color: var(--ink);
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.65;
}

h1, h2, h3 { margin: 0 0 16px; font-weight: 600; text-wrap: balance; }
h1 { font-size: 30px; line-height: 1.15; letter-spacing: -0.01em; }
h2 { font-size: 24px; line-height: 1.25; }
h3 { font-size: 18px; line-height: 1.4; }
p { margin: 0 0 16px; text-wrap: pretty; }
.hero h1 { font-size: 34px; line-height: 1.12; letter-spacing: -0.015em; }

@media (min-width: 768px) {
  .hero h1 { font-size: 44px; }
}
@media (min-width: 1024px) {
  h1 { font-size: 38px; }
  h2 { font-size: 28px; }
  .hero h1 { font-size: 44px; }
}

a, button, summary { touch-action: manipulation; -webkit-tap-highlight-color: transparent; }
a { color: var(--accent); text-decoration: underline; text-underline-offset: 3px; }
a:hover { color: var(--accent-hover); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

.lead { font-size: 19px; line-height: 1.55; max-width: 60ch; }
.muted { color: var(--ink-muted); }
.small { font-size: 15px; line-height: 1.55; color: var(--ink-muted); }

.visually-hidden {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

.container { max-width: var(--container); margin: 0 auto; padding: 0 var(--gutter); }
.narrow { max-width: calc(var(--reading) + 2 * var(--gutter)); }

.skip-link {
  position: absolute; left: 8px; top: -100px; z-index: 30;
  padding: 12px 16px; background: var(--accent); color: var(--on-accent);
  border-radius: var(--radius-control);
}
.skip-link:focus { top: 8px; color: var(--on-accent); }

.notice {
  margin: 0; padding: 8px var(--gutter); text-align: center;
  background: var(--accent-tint); color: var(--accent); font-size: 14px; line-height: 1.5;
}

/* Header */
.site-header {
  position: sticky; top: 0; z-index: 20;
  background: var(--canvas); border-bottom: 1px solid var(--hairline);
}
.header-row { display: flex; align-items: center; gap: 24px; min-height: var(--header-height); }
.wordmark { font-size: 22px; font-weight: 600; letter-spacing: -0.01em; color: var(--ink); text-decoration: none; }
.wordmark:hover { color: var(--ink); }
.menu-wide { display: none; gap: 24px; margin-left: auto; }
.menu-wide a, .menu-narrow nav a { color: var(--ink); text-decoration: none; font-size: 16px; }
.menu-wide a:hover, .menu-narrow nav a:hover { color: var(--accent); text-decoration: underline; }
.menu-wide a[aria-current="page"], .menu-narrow a[aria-current="page"] { color: var(--accent); font-weight: 600; }
.header-cta { margin-left: auto; }
.menu-narrow summary {
  list-style: none; cursor: pointer; padding: 10px 14px; min-height: 44px;
  display: flex; align-items: center;
  border: 1px solid var(--field-edge); border-radius: var(--radius-control); font-size: 16px;
}
.menu-narrow summary::-webkit-details-marker { display: none; }
.menu-narrow nav {
  position: absolute; left: 0; right: 0; top: 100%;
  display: flex; flex-direction: column; gap: 4px;
  padding: 12px var(--gutter) 20px; background: var(--canvas); border-bottom: 1px solid var(--hairline);
}
.menu-narrow nav a { padding: 10px 0; }

@media (max-width: 479px) {
  .header-row { gap: 12px; }
  .header-cta { padding: 0 14px; }
}
@media (min-width: 900px) {
  .menu-wide { display: flex; }
  .menu-narrow { display: none; }
  .header-cta { margin-left: 0; }
}

/* Buttons */
.button {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 48px; padding: 0 20px; border-radius: var(--radius-control);
  font: 600 16px/1 var(--font); text-decoration: none; white-space: nowrap; cursor: pointer;
  transition: background-color 150ms ease, color 150ms ease, border-color 150ms ease;
}
.button-primary { background: var(--accent); color: var(--on-accent); border: 1px solid var(--accent); }
.button-primary:hover { background: var(--accent-hover); border-color: var(--accent-hover); color: var(--on-accent); }
.button-secondary { background: transparent; color: var(--ink); border: 1px solid var(--field-edge); }
.button-secondary:hover { color: var(--accent); border-color: var(--accent); }
.actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 24px; }

/* Sections */
.section { padding: var(--section) 0; }
.section-tight { padding: 0 0 var(--section); }
.slot-section { padding: 8px 0 0; }
.section-surface { background: var(--surface); }
.page-head { padding: 48px 0 32px; }
@media (min-width: 768px) { .page-head { padding: 72px 0 40px; } }

.hero { padding: 40px 0 var(--section); }
.hero-grid { display: grid; gap: 40px; }
@media (min-width: 1024px) {
  .hero { padding-top: 72px; }
  .hero-grid { grid-template-columns: 1.3fr 1fr; align-items: center; gap: 48px; }
}

.two-col { display: grid; gap: 16px; }
@media (min-width: 900px) { .two-col { grid-template-columns: 1fr 1.2fr; gap: 56px; } }

/* Lists */
.rows { list-style: none; margin: 24px 0 0; padding: 0; }
.rows li { padding: 20px 0; border-top: 1px solid var(--hairline); }
.rows li:last-child { border-bottom: 1px solid var(--hairline); }
.rows h3 { margin-bottom: 6px; }
.rows p { margin: 0; }
.bullets { margin: 16px 0 24px; padding-left: 20px; }
.bullets li { margin-bottom: 12px; padding-left: 4px; }

/* Media slot: fixed ratio so a video can replace the illustration later */
.media-slot { margin: 0; }
.media-frame {
  aspect-ratio: 4 / 3; /* grows if content is taller; a video fills it exactly */
  display: flex; align-items: center; justify-content: center;
  padding: 20px; background: var(--surface);
  border: 1px solid var(--hairline); border-radius: var(--radius-panel);
}
.media-slot figcaption { margin-top: 10px; font-size: 14px; color: var(--ink-muted); }
@media (max-width: 479px) {
  .media-frame { aspect-ratio: auto; min-height: 300px; }
}

/* Illustrations */
.illus { width: 100%; max-width: 440px; display: grid; gap: 12px; font-size: 15px; line-height: 1.5; font-variant-numeric: tabular-nums; }
.illus-card { background: var(--canvas); border: 1px solid var(--hairline); border-radius: var(--radius-panel); padding: 16px; }
.illus-card p { margin: 0 0 8px; }
.illus-card p:last-child { margin-bottom: 0; }
.illus-file, .illus-evidence { color: var(--ink-muted); font-size: 14px; }
.illus-next { font-weight: 600; }
.illus-actions { display: flex; gap: 8px; margin-top: 12px; }
.illus-button {
  padding: 6px 12px; border: 1px solid var(--field-edge); border-radius: var(--radius-control);
  font-size: 14px; font-weight: 600; color: var(--ink);
}
.illus-button-primary { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }
.illus-list { list-style: none; margin: 8px 0 12px; padding: 0; }
.illus-list li { display: flex; justify-content: space-between; gap: 12px; padding: 8px 0; border-top: 1px solid var(--hairline); }
.tag { display: inline-block; padding: 1px 8px; border-radius: var(--radius-tag); font-size: 13px; font-weight: 600; white-space: nowrap; }
.tag-attention { background: var(--attention-tint); color: var(--attention-ink); }
.tag-clear { background: var(--clear-tint); color: var(--clear-ink); }
.tag-note { background: var(--note-tint); color: var(--note-ink); }

/* Governance topics */
.topics { padding-bottom: var(--section); }
.topic { padding: 32px 0; border-top: 1px solid var(--hairline); }
.topic h3 { margin-top: 20px; font-size: 16px; color: var(--ink-muted); }

/* Status table: stacked rows on phones */
.table-wrap { margin-top: 16px; }
.status-table { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; }
.status-table caption { text-align: left; font-size: 15px; color: var(--ink-muted); padding-bottom: 12px; }
.status-table th, .status-table td { text-align: left; vertical-align: top; padding: 12px 0; border-top: 1px solid var(--hairline); }
.status-table thead th { font-size: 15px; color: var(--ink-muted); }
.status-table tbody th { font-weight: 400; padding-right: 24px; }
.status { font-weight: 600; white-space: nowrap; }
.status-built { color: var(--clear-ink); }
.status-partly { color: var(--attention-ink); }
.status-designed { color: var(--note-ink); }
.status-note { display: block; font-size: 14px; color: var(--ink-muted); }
@media (max-width: 599px) {
  .status-table thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  .status-table tr { display: block; padding: 12px 0; border-top: 1px solid var(--hairline); }
  .status-table th, .status-table td { display: block; padding: 0; border: 0; }
  .status-table td { margin-top: 4px; }
}

/* Who it is for */
.audience-grid { display: grid; gap: 16px; margin-bottom: 24px; }
@media (min-width: 768px) { .audience-grid { grid-template-columns: 1fr 1fr; } }
.audience { padding: 24px; border: 1px solid var(--hairline); border-radius: var(--radius-panel); }
.audience:nth-child(-n + 2) { background: var(--surface); }
.audience h2 { font-size: 22px; }

/* Prose */
.prose h2 { margin-top: 32px; font-size: 22px; }

/* Contact form */
.contact-form { display: grid; gap: 20px; max-width: 560px; }
.field { display: grid; gap: 8px; }
.field label { font-size: 15px; font-weight: 600; }
.field input, .field textarea {
  width: 100%; padding: 12px 14px; min-height: 48px;
  font: 400 16px/1.5 var(--font); color: var(--ink); background: #ffffff;
  border: 1px solid var(--field-edge); border-radius: var(--radius-control);
}
.field input:focus-visible, .field textarea:focus-visible { border-color: var(--accent); }
.field [aria-invalid="true"] { border-color: var(--error-ink); }
.field-error { margin: 0; font-size: 15px; color: var(--error-ink); }
.honeypot { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.contact-form .button { justify-self: start; }
.contact-form .button[disabled] { opacity: 0.6; cursor: progress; }
.form-status { margin: 0; font-weight: 600; }
.form-status.is-success { color: var(--clear-ink); }
.form-status.is-error { color: var(--error-ink); }

/* Closing band */
.cta-band { padding: var(--section) 0; border-top: 1px solid var(--hairline); }
.cta-band .container { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 20px; }
.cta-band h2 { margin: 0; }

/* Footer */
.site-footer { border-top: 1px solid var(--hairline); padding: 32px 0 40px; font-size: 15px; color: var(--ink-muted); }
.footer-row { display: grid; gap: 12px; }
.footer-row p { margin: 0; }
.site-footer nav { display: flex; flex-wrap: wrap; gap: 20px; }
.site-footer nav a { color: var(--ink-muted); }
@media (min-width: 768px) {
  .footer-row { grid-template-columns: 1fr auto; align-items: center; }
  .footer-row .small { grid-column: 1 / -1; }
}

@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; }
}
