/* The public ElevatED page (#57), on the cwc-brand tokens (tokens.css is a byte-equal copy of the brand's template).
   Only semantic token names below; the dark values keep each meaning and are the web app's checked pairs
   (src/main/frontend/src/styles/app-theme.css). The board is docs/design/product-page/. */

@font-face { font-family: "Inter"; font-weight: 400; font-style: normal; font-display: swap; src: url(fonts/Inter-Regular.ttf) format("truetype"); }
@font-face { font-family: "Inter"; font-weight: 500; font-style: normal; font-display: swap; src: url(fonts/Inter-Medium.ttf) format("truetype"); }
@font-face { font-family: "Inter"; font-weight: 600; font-style: normal; font-display: swap; src: url(fonts/Inter-SemiBold.ttf) format("truetype"); }
@font-face { font-family: "Libre Baskerville"; font-weight: 400; font-style: normal; font-display: swap; src: url(fonts/LibreBaskerville-Regular.ttf) format("truetype"); }
@font-face { font-family: "JetBrains Mono"; font-weight: 400; font-style: normal; font-display: swap; src: url(fonts/JetBrainsMono-Regular.ttf) format("truetype"); }

@media (prefers-color-scheme: dark) {
  :root {
    color-scheme: dark;
    --cwc-paper: #161514;
    --cwc-surface: #1F1E1D;
    --cwc-ghost: #2A2826;
    --cwc-ink: #F4F1EC;
    --cwc-text-2: #CFCBC4;
    --cwc-text-3: #A5A29C;
    --cwc-accent: #C9A0E0;
    --cwc-hairline: #3A3836;
    --cwc-white: #F4F1EC;
    --action-primary-bg-hover: #D9D5CE;
    --action-primary-text: #161514;
    --selected-text: #161514;
    --status-pass: #7FD1A0;
    --status-fail: #F0A196;
    --status-warn: #E3B26A;
    --status-info: #9DB6F2;
  }
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg-page);
  color: var(--text-body);
  font: 400 16px/1.6 var(--type-ui);
  -webkit-font-smoothing: antialiased;
}
img, svg { display: block; max-width: 100%; }
a { color: var(--text-link); text-underline-offset: 3px; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 2px solid var(--focus-ring); outline-offset: 2px; }
[hidden] { display: none !important; }
.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;
}

.wrap { width: 100%; max-width: 1200px; margin: 0 auto; padding: 0 32px; }

.skip {
  position: absolute; left: 16px; top: -48px; z-index: 10;
  padding: 8px 14px; border-radius: var(--radius);
  background: var(--action-primary-bg); color: var(--action-primary-text); font-weight: 600; text-decoration: none;
}
.skip:focus { top: 12px; }

/* ── Header and footer ───────────────────────────────────────────────── */
.site-header { border-bottom: var(--border-width) solid var(--line-divider); }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 68px; }
.brand { display: inline-flex; align-items: center; gap: 12px; color: var(--text-body); text-decoration: none; }
.brand-mark { width: 40px; height: auto; }
.brand-name { font-weight: 600; font-size: 20px; letter-spacing: -0.01em; line-height: 1; }
.brand-by {
  font: 400 11px/1 var(--type-data); letter-spacing: .16em; text-transform: uppercase;
  color: var(--text-meta-on-paper); padding-left: 12px; border-left: var(--border-width) solid var(--line-divider);
}
.header-link { color: var(--action-tertiary-text); font-weight: 500; text-decoration: none; }
.header-link:hover { text-decoration: underline; }

.site-footer { border-top: var(--border-width) solid var(--line-divider); margin-top: 96px; }
.site-footer .wrap {
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px 32px; padding-top: 28px; padding-bottom: 40px;
  font-size: 14px; color: var(--text-meta-on-paper);
}
.site-footer a { color: var(--text-link); }

/* ── Type ────────────────────────────────────────────────────────────── */
.eyebrow {
  margin: 0 0 16px; font: 400 12px/1.4 var(--type-data); letter-spacing: .16em; text-transform: uppercase;
  color: var(--identity);
}
h1, h2 { font-family: var(--type-display); font-weight: 400; color: var(--text-body); margin: 0; }
h1 { font-size: clamp(36px, 5vw, 58px); line-height: 1.12; letter-spacing: -0.015em; }
h2 { font-size: clamp(26px, 3.2vw, 36px); line-height: 1.2; letter-spacing: -0.01em; }
h3 { font: 600 18px/1.35 var(--type-ui); margin: 0 0 8px; letter-spacing: -0.005em; }
p { margin: 0 0 16px; }
.lede { font-size: 19px; line-height: 1.6; color: var(--text-secondary); max-width: 58ch; margin: 24px 0 0; }

/* ── Actions ─────────────────────────────────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; padding: 12px 22px;
  border-radius: var(--radius); border: var(--border-width) solid transparent;
  font: 600 16px/1.2 var(--type-ui); text-decoration: none; cursor: pointer;
}
.btn-primary { background: var(--action-primary-bg); color: var(--action-primary-text); }
.btn-primary:hover { background: var(--action-primary-bg-hover); }
.btn-primary[aria-disabled="true"] { background: var(--action-disabled-bg); color: var(--action-disabled-text); border-color: var(--action-disabled-line); cursor: progress; }
.btn-secondary { background: var(--action-secondary-bg); color: var(--action-secondary-text); border-color: var(--action-secondary-line); }
.btn-secondary:hover { background: var(--action-secondary-bg-hover); }

/* ── Status (always with words) ──────────────────────────────────────── */
.status { border-radius: var(--radius); border: var(--border-width) solid; padding: 14px 16px; }
.status-info { background: var(--status-info-bg); border-color: var(--status-info); color: var(--status-info); }
.status-pass { background: var(--status-pass-bg); border-color: var(--status-pass); color: var(--status-pass); }
.status-fail { background: var(--status-fail-bg); border-color: var(--status-fail); color: var(--status-fail); }
.status-warn { background: var(--status-warn-bg); border-color: var(--status-warn); color: var(--status-warn); }
.status-word { font: 400 12px/1.4 var(--type-data); letter-spacing: .14em; text-transform: uppercase; margin-right: 8px; }

/* ── Hero ────────────────────────────────────────────────────────────── */
.hero { padding: 72px 0 64px; }
.hero-grid { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: 64px; align-items: center; }
.hero-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 16px 28px; margin-top: 36px; }
.hero-note { margin-top: 32px; max-width: 58ch; font-size: 15px; }
.hero-note p { margin: 0; }
.hero-figure { margin: 0; }
.hero-figure svg { width: 100%; height: auto; color: var(--identity); }
.hero-figure .shaft { stroke: var(--line-control); }
.hero-figure .car { stroke: var(--identity); }
.hero-figure .rule { stroke: var(--line-divider); }
.hero-figure text { font: 400 11px var(--type-data); letter-spacing: .14em; fill: var(--text-meta-on-paper); }

/* ── Sections ────────────────────────────────────────────────────────── */
.section { padding: 72px 0 0; }
.section-head { max-width: 60ch; margin-bottom: 40px; }
.section-head p { color: var(--text-secondary); margin-top: 16px; }

.features { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; list-style: none; margin: 0; padding: 0; }
.feature {
  background: var(--bg-card); border: var(--border-width) solid var(--line-divider); border-radius: var(--radius);
  padding: 24px;
}
.feature-label {
  margin: 0 0 14px; font: 400 11px/1.4 var(--type-data); letter-spacing: .16em; text-transform: uppercase;
  color: var(--text-meta-on-card);
}
.feature p { margin: 0; color: var(--text-secondary); font-size: 15px; }

.pillars { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0; border-top: var(--border-width) solid var(--line-divider); }
.pillar { padding: 28px 28px 8px 0; }
.pillar + .pillar { padding-left: 28px; border-left: var(--border-width) solid var(--line-divider); }
.pillar p { color: var(--text-secondary); font-size: 15px; }

/* ── Sign-up ─────────────────────────────────────────────────────────── */
.signup-grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: 64px; align-items: start; }
.steps { list-style: none; counter-reset: step; margin: 28px 0 0; padding: 0; }
.steps li { counter-increment: step; display: grid; grid-template-columns: 36px 1fr; gap: 12px; padding: 14px 0; border-top: var(--border-width) solid var(--line-divider); }
.steps li::before {
  content: counter(step); display: inline-flex; align-items: center; justify-content: center; width: 28px; height: 28px;
  border-radius: 50%; background: var(--selected-bg); color: var(--selected-text); font: 600 14px/1 var(--type-ui);
}
.steps li strong { display: block; font-weight: 600; }
.steps li span { color: var(--text-secondary); font-size: 15px; }

.privacy { margin-top: 36px; padding-top: 24px; border-top: var(--border-width) solid var(--line-divider); }
.privacy h3 { font-size: 16px; }
.privacy p, .privacy li { font-size: 14px; color: var(--text-secondary); }
.privacy ul { margin: 0 0 12px; padding-left: 20px; }

.card {
  background: var(--bg-card); border: var(--border-width) solid var(--line-divider); border-radius: var(--radius);
  padding: 32px;
}
.form-title { font: 600 20px/1.3 var(--type-ui); margin: 0 0 6px; }
.form-intro { color: var(--text-meta-on-card); font-size: 14px; margin: 0 0 24px; }
.field { margin: 0 0 20px; }
.field label { display: block; font-weight: 500; font-size: 15px; margin-bottom: 6px; }
.field .hint { display: block; font-size: 13px; color: var(--text-meta-on-card); margin: -2px 0 6px; }
.field input, .field select {
  display: block; width: 100%; min-height: 46px; padding: 10px 12px;
  font: 400 16px/1.4 var(--type-ui); color: var(--text-body);
  background: var(--bg-page); border: var(--border-width) solid var(--line-control); border-radius: var(--radius);
}
.field select { appearance: none; background-image: linear-gradient(45deg, transparent 50%, currentColor 50%), linear-gradient(135deg, currentColor 50%, transparent 50%); background-position: calc(100% - 20px) 50%, calc(100% - 15px) 50%; background-size: 5px 5px; background-repeat: no-repeat; padding-right: 36px; }
.field input:focus-visible, .field select:focus-visible { outline: 2px solid var(--focus-ring); outline-offset: 2px; }
.field-error input, .field-error select { border-color: var(--status-fail); border-width: 2px; padding: 9px 11px; }
.field-msg { display: flex; gap: 6px; margin: 6px 0 0; font-size: 14px; font-weight: 500; color: var(--status-fail); }
.field-msg::before { content: "!"; flex: none; display: inline-flex; align-items: center; justify-content: center; width: 18px; height: 18px; margin-top: 1px; border-radius: 50%; background: var(--status-fail); color: var(--bg-page); font: 700 12px/1 var(--type-ui); }
.two { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 0 16px; }
.check { margin: 4px 0 20px; min-height: 65px; }
.form-alert { margin: 0 0 20px; font-size: 15px; }
.form-alert p { margin: 0; }
.form-alert .ref { display: block; margin-top: 6px; font: 400 13px/1.4 var(--type-data); }
.form-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 20px; }
.form-note { margin: 16px 0 0; font-size: 13px; color: var(--text-meta-on-card); }
.sent:focus { outline: 2px solid var(--focus-ring); outline-offset: 2px; }
.sent h3 { color: var(--status-pass); font-size: 20px; }
.sent p { color: var(--text-body); margin: 0 0 10px; }
.sent .sent-address { font-weight: 600; word-break: break-all; }

/* ── Link pages (/confirm) and other single notices ──────────────────── */
.notice { max-width: 640px; margin: 0 auto; padding: 96px 0 0; }
.notice h1 { font-size: clamp(30px, 4vw, 44px); margin-bottom: 20px; }
.notice p { font-size: 18px; color: var(--text-secondary); }
.notice .status { margin: 0 0 28px; font-size: 15px; }
.notice .ref { font: 400 14px/1.4 var(--type-data); color: var(--text-meta-on-paper); }
.notice .actions { margin-top: 32px; display: flex; flex-wrap: wrap; gap: 16px; }

/* ── The team's list (/admin/) ───────────────────────────────────────── */
.admin { padding: 48px 0 0; }
.admin h1 { font-size: clamp(28px, 3.4vw, 40px); margin-bottom: 8px; }
.admin .counts { display: flex; flex-wrap: wrap; gap: 12px; list-style: none; margin: 24px 0 28px; padding: 0; }
.admin .counts li { background: var(--bg-card); border: var(--border-width) solid var(--line-divider); border-radius: var(--radius); padding: 10px 16px; font-size: 15px; }
.admin .counts strong { font-size: 20px; margin-right: 6px; }
.table-wrap { overflow-x: auto; border: var(--border-width) solid var(--line-divider); border-radius: var(--radius); }
table { width: 100%; border-collapse: collapse; font-size: 14px; background: var(--bg-page); }
caption { text-align: left; padding: 12px 16px; color: var(--text-meta-on-paper); font-size: 13px; caption-side: bottom; }
th, td { text-align: left; padding: 12px 16px; border-bottom: var(--border-width) solid var(--line-divider); vertical-align: top; }
th { font: 400 11px/1.4 var(--type-data); letter-spacing: .14em; text-transform: uppercase; color: var(--text-meta-on-paper); white-space: nowrap; }
td.when { white-space: nowrap; font: 400 13px/1.5 var(--type-data); }
.state { display: inline-block; padding: 2px 10px; border-radius: var(--radius); border: var(--border-width) solid; font-size: 13px; font-weight: 500; white-space: nowrap; }
.state-PENDING { background: var(--status-warn-bg); color: var(--status-warn); border-color: var(--status-warn); }
.state-CONFIRMED { background: var(--status-pass-bg); color: var(--status-pass); border-color: var(--status-pass); }
.state-EXPIRED { background: var(--bg-sunken); color: var(--text-secondary); border-color: var(--line-control); }
.empty { padding: 28px 16px; color: var(--text-meta-on-paper); }

/* ── Narrow screens ──────────────────────────────────────────────────── */
@media (max-width: 960px) {
  .hero-grid, .signup-grid { grid-template-columns: minmax(0, 1fr); gap: 40px; }
  .hero-figure { max-width: 420px; }
  .features { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .pillars { grid-template-columns: minmax(0, 1fr); }
  .pillar, .pillar + .pillar { padding: 24px 0 8px; border-left: 0; }
  .pillar + .pillar { border-top: var(--border-width) solid var(--line-divider); }
}
@media (max-width: 600px) {
  .wrap { padding: 0 16px; }
  .site-header .wrap { min-height: 60px; }
  .brand-mark { width: 32px; }
  .brand-by { display: none; }
  .hero { padding: 40px 0 32px; }
  .lede { font-size: 17px; }
  .section { padding-top: 56px; }
  .features { grid-template-columns: minmax(0, 1fr); }
  .card { padding: 20px; }
  .two { grid-template-columns: minmax(0, 1fr); }
  .btn { width: 100%; }
  .hero-actions .btn { width: auto; }
  .notice { padding-top: 56px; }
  .site-footer { margin-top: 72px; }
}
