:root {
  --accent: #3b82f6;
  --accent-strong: #2563eb;
  --background: #07111f;
  --border: #243249;
  --border-bright: #334155;
  --ink: #f8fafc;
  --muted: #94a3b8;
  --surface: #0f172a;
  --surface-raised: #111d31;
  --focus: #60a5fa;
  color: var(--ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-synthesis: none;
  line-height: 1.5;
}

html[data-skin="personal"] {
  --accent: #22d3ee;
  --accent-strong: #0891b2;
  --focus: #67e8f9;
}

* {
  box-sizing: border-box;
}

html {
  background: var(--background);
  scroll-behavior: smooth;
}

body {
  background: var(--background);
  color: var(--ink);
  margin: 0;
  min-height: 100vh;
}

a {
  color: inherit;
}

button,
input {
  font: inherit;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 4px;
}

[hidden] {
  display: none !important;
}

.skip-link {
  background: var(--ink);
  color: var(--background);
  font-family: ui-monospace, "SFMono-Regular", Consolas, monospace;
  font-size: 0.75rem;
  font-weight: 800;
  left: 1rem;
  padding: 0.75rem 1rem;
  position: fixed;
  text-transform: uppercase;
  top: -5rem;
  z-index: 100;
}

.skip-link:focus {
  top: 1rem;
}

.site-header,
.site-footer,
.chooser,
.score-page,
.not-found {
  margin: 0 auto;
  max-width: 82rem;
}

.site-header {
  align-items: center;
  border-bottom: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  min-height: 5.25rem;
  padding: 1rem 2rem;
}

.brand-lockup {
  align-items: center;
  display: inline-flex;
  gap: 0.8rem;
  text-decoration: none;
}

.brand-owl {
  display: block;
  flex: 0 0 auto;
}

.brand-names {
  display: grid;
  line-height: 1;
}

.brand-names > strong {
  font-family: "Space Grotesk", Inter, ui-sans-serif, system-ui, sans-serif;
  font-size: 1.25rem;
  font-weight: 800;
  letter-spacing: 0.08em;
}

.maker-wordmark {
  color: var(--muted);
  font-family: ui-monospace, "SFMono-Regular", Consolas, monospace;
  font-size: 0.57rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  margin-top: 0.35rem;
}

.maker-wordmark > span {
  color: var(--accent);
}

.header-context {
  align-items: center;
  color: var(--muted);
  display: flex;
  font-family: ui-monospace, "SFMono-Regular", Consolas, monospace;
  font-size: 0.68rem;
  gap: 1rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.phase-badge {
  border: 1px solid var(--accent);
  color: var(--accent);
  padding: 0.35rem 0.55rem;
}

.chooser {
  padding: clamp(4.5rem, 10vw, 8.5rem) 2rem 2rem;
}

.chooser-intro {
  max-width: 68rem;
}

.system-label,
.eyebrow,
.choice-kicker,
.choice-number,
.choice-status,
.choice-action,
.panel-index,
.result-label,
.result-heading > span,
.diagnostic-specs dt {
  font-family: ui-monospace, "SFMono-Regular", Consolas, monospace;
  font-size: 0.7rem;
  font-weight: 750;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.system-label,
.eyebrow,
.choice-kicker,
.result-label {
  color: var(--accent);
}

.system-label > span {
  font-size: 0.55rem;
  margin-right: 0.35rem;
}

h1,
h2,
p {
  margin-top: 0;
}

h1,
h2,
.skin-choice > strong,
.error-code {
  font-family: "Space Grotesk", Inter, ui-sans-serif, system-ui, sans-serif;
}

h1 {
  font-size: clamp(3.5rem, 8.6vw, 7.5rem);
  font-weight: 750;
  letter-spacing: -0.065em;
  line-height: 0.91;
  margin: 1.4rem 0 2rem;
  max-width: 70rem;
}

.chooser h1::after {
  background: var(--accent);
  content: "";
  display: block;
  height: 0.45rem;
  margin-top: 1.5rem;
  width: clamp(8rem, 20vw, 18rem);
}

.intro-copy {
  color: #cbd5e1;
  font-size: clamp(1.05rem, 2vw, 1.4rem);
  line-height: 1.65;
  max-width: 48rem;
}

.brand-promise {
  border-bottom: 1px solid var(--border);
  border-top: 1px solid var(--border);
  display: flex;
  flex-wrap: wrap;
  gap: 0;
  margin-top: 3.5rem;
  max-width: 55rem;
}

.brand-promise span {
  color: var(--muted);
  font-family: ui-monospace, "SFMono-Regular", Consolas, monospace;
  font-size: 0.68rem;
  letter-spacing: 0.08em;
  padding: 0.85rem 1.5rem 0.85rem 0;
  text-transform: uppercase;
}

.brand-promise span + span::before {
  color: var(--accent);
  content: "/";
  margin-right: 1.5rem;
}

.skin-choices {
  border: 1px solid var(--border);
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin-top: clamp(4rem, 9vw, 7rem);
}

.skin-choice {
  background: var(--surface);
  display: flex;
  flex-direction: column;
  min-height: 31rem;
  overflow: hidden;
  padding: clamp(1.5rem, 4vw, 3rem);
  position: relative;
  text-decoration: none;
  transition: background-color 160ms ease, border-color 160ms ease;
}

.skin-choice::before {
  background: var(--accent);
  content: "";
  height: 0.3rem;
  left: 0;
  position: absolute;
  right: 0;
  top: 0;
}

.skin-choice:first-child {
  border-right: 1px solid var(--border);
}

.skin-choice-personal::before {
  background: #22d3ee;
}

.skin-choice:hover {
  background: var(--surface-raised);
}

.skin-choice:hover .choice-action {
  color: var(--ink);
}

.choice-topline {
  align-items: center;
  display: flex;
  justify-content: space-between;
}

.choice-number {
  color: var(--ink);
  font-size: 1.2rem;
}

.choice-status,
.choice-copy {
  color: var(--muted);
}

.choice-kicker {
  margin-top: 4rem;
}

.skin-choice-personal .choice-kicker,
.skin-choice-personal .choice-action {
  color: #22d3ee;
}

.skin-choice > strong {
  font-size: clamp(2.25rem, 4.5vw, 4.25rem);
  font-weight: 700;
  letter-spacing: -0.055em;
  line-height: 0.97;
  margin: 1rem 0 1.5rem;
  max-width: 32rem;
}

.choice-copy {
  font-size: 1rem;
  line-height: 1.65;
  max-width: 31rem;
}

.choice-action {
  align-items: center;
  color: var(--accent);
  display: flex;
  gap: 0.75rem;
  justify-content: space-between;
  margin-top: auto;
  padding-top: 3rem;
}

.site-footer {
  align-items: center;
  border-top: 1px solid var(--border);
  color: var(--muted);
  display: grid;
  font-family: ui-monospace, "SFMono-Regular", Consolas, monospace;
  font-size: 0.67rem;
  gap: 1.5rem;
  grid-template-columns: minmax(13rem, 1fr) auto auto;
  letter-spacing: 0.06em;
  margin-top: clamp(4rem, 10vw, 8rem);
  padding: 2rem;
  text-transform: uppercase;
}

.footer-brand {
  display: grid;
  gap: 0.25rem;
}

.footer-brand strong {
  color: var(--ink);
  font-family: "Space Grotesk", Inter, sans-serif;
  font-size: 1rem;
  letter-spacing: 0.12em;
}

.site-footer p {
  margin: 0;
}

.site-footer p span {
  color: var(--accent);
  margin: 0 0.35rem;
}

.site-footer > a {
  color: var(--ink);
  font-weight: 800;
  text-underline-offset: 0.25em;
}

.score-page {
  display: grid;
  gap: clamp(3rem, 7vw, 6rem);
  grid-template-columns: minmax(0, 0.92fr) minmax(30rem, 1.08fr);
  padding: clamp(3.5rem, 7vw, 6.5rem) 2rem 2rem;
}

.back-link {
  color: var(--muted);
  display: inline-flex;
  font-family: ui-monospace, "SFMono-Regular", Consolas, monospace;
  font-size: 0.69rem;
  gap: 0.6rem;
  letter-spacing: 0.08em;
  margin-bottom: 5rem;
  text-decoration: none;
  text-transform: uppercase;
}

.back-link:hover {
  color: var(--accent);
}

.score-intro h1 {
  font-size: clamp(3.25rem, 6.5vw, 6.5rem);
  overflow-wrap: anywhere;
}

.public-note {
  border-left: 0.25rem solid var(--accent);
  color: var(--muted);
  margin-top: 3rem;
  max-width: 38rem;
  padding: 0.15rem 0 0.15rem 1.25rem;
}

.public-note strong {
  color: var(--ink);
}

.diagnostic-specs {
  border-bottom: 1px solid var(--border);
  margin: 4rem 0 0;
}

.diagnostic-specs > div {
  border-top: 1px solid var(--border);
  display: grid;
  gap: 1rem;
  grid-template-columns: 7rem 1fr;
  padding: 0.8rem 0;
}

.diagnostic-specs dt {
  color: var(--muted);
}

.diagnostic-specs dd {
  font-family: ui-monospace, "SFMono-Regular", Consolas, monospace;
  font-size: 0.7rem;
  margin: 0;
  text-transform: uppercase;
}

.score-workbench {
  align-self: start;
  background: var(--surface);
  border: 1px solid var(--border-bright);
  box-shadow: 0.8rem 0.8rem 0 var(--accent);
  padding: clamp(1.5rem, 4vw, 3rem);
  position: relative;
}

.panel-index {
  color: var(--muted);
  position: absolute;
  right: 1.25rem;
  top: 1rem;
}

.workbench-heading h2 {
  font-size: clamp(2rem, 4vw, 3.5rem);
  font-weight: 700;
  letter-spacing: -0.05em;
  line-height: 0.98;
  margin: 0.75rem 0 1rem;
  max-width: 32rem;
}

.workbench-heading > p:last-child,
.field-note,
.price-note {
  color: var(--muted);
}

.workbench-heading > p:last-child {
  line-height: 1.65;
}

.workbench-heading strong {
  color: var(--ink);
}

.score-form {
  border-bottom: 1px solid var(--border);
  border-top: 1px solid var(--border);
  margin: 2rem 0;
  padding: 2rem 0;
}

.score-form label {
  display: block;
  font-family: ui-monospace, "SFMono-Regular", Consolas, monospace;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  margin-bottom: 0.65rem;
  text-transform: uppercase;
}

.input-row {
  display: flex;
}

.input-row input {
  background: var(--background);
  border: 1px solid var(--border-bright);
  border-radius: 0;
  color: var(--ink);
  min-width: 0;
  padding: 1rem;
  width: 100%;
}

.input-row input:focus {
  border-color: var(--accent);
}

button,
.primary-link {
  background: var(--accent-strong);
  border: 1px solid var(--accent-strong);
  border-radius: 0;
  color: white;
  cursor: pointer;
  display: inline-flex;
  font-family: ui-monospace, "SFMono-Regular", Consolas, monospace;
  font-size: 0.72rem;
  font-weight: 800;
  justify-content: center;
  letter-spacing: 0.06em;
  padding: 1rem 1.25rem;
  text-decoration: none;
  text-transform: uppercase;
}

button:hover,
.primary-link:hover {
  background: var(--ink);
  border-color: var(--ink);
  color: var(--background);
}

button:disabled {
  cursor: wait;
  opacity: 0.6;
}

.field-note,
.price-note {
  font-family: ui-monospace, "SFMono-Regular", Consolas, monospace;
  font-size: 0.67rem;
  letter-spacing: 0.03em;
  margin: 0.75rem 0 0;
}

.result-panel {
  border-left: 0.3rem solid var(--accent);
  padding-left: 1.5rem;
}

.result-panel[data-state="error"] {
  --accent: #f87171;
}

.result-heading {
  align-items: center;
  display: flex;
  justify-content: space-between;
}

.result-heading > span {
  color: var(--muted);
}

.result-label {
  margin-bottom: 0;
}

.result-score {
  font-family: "Space Grotesk", Inter, sans-serif;
  font-size: clamp(5.5rem, 12vw, 9rem);
  font-weight: 750;
  letter-spacing: -0.09em;
  line-height: 0.88;
  margin: 1.25rem 0;
}

.result-score small {
  color: var(--muted);
  font-family: ui-monospace, "SFMono-Regular", Consolas, monospace;
  font-size: 0.75rem;
  letter-spacing: 0.06em;
}

.result-leak {
  font-size: 1.15rem;
  font-weight: 700;
  line-height: 1.55;
  max-width: 34rem;
}

.report-button {
  margin-top: 1rem;
}

.artifact-links {
  display: flex;
  flex-wrap: wrap;
  gap: 1.25rem;
  margin-top: 1.5rem;
}

.artifact-links a {
  color: var(--accent);
  font-family: ui-monospace, "SFMono-Regular", Consolas, monospace;
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-underline-offset: 0.25em;
  text-transform: uppercase;
}

.price-note {
  border-top: 1px solid var(--border);
  margin-top: 2rem;
  padding-top: 1rem;
}

.not-found {
  min-height: 60vh;
  padding: clamp(4rem, 10vw, 8rem) 2rem;
  position: relative;
}

.not-found .error-code {
  color: var(--surface-raised);
  font-size: clamp(9rem, 27vw, 24rem);
  font-weight: 800;
  letter-spacing: -0.1em;
  line-height: 0.7;
  margin: 2rem 0 0;
  pointer-events: none;
}

.not-found h1 {
  font-size: clamp(3rem, 7vw, 6.5rem);
  margin-top: -1.5rem;
  position: relative;
}

.not-found > p:not(.system-label, .error-code) {
  color: var(--muted);
  font-size: 1.1rem;
  max-width: 37rem;
}

.not-found .primary-link {
  margin-top: 1.5rem;
}

@media (max-width: 62rem) {
  .score-page {
    grid-template-columns: 1fr;
  }

  .score-intro {
    max-width: 52rem;
  }

  .back-link {
    margin-bottom: 3rem;
  }

  .score-workbench {
    box-shadow: 0.55rem 0.55rem 0 var(--accent);
  }
}

@media (max-width: 50rem) {
  .skin-choices {
    grid-template-columns: 1fr;
  }

  .skin-choice {
    min-height: 27rem;
  }

  .skin-choice:first-child {
    border-bottom: 1px solid var(--border);
    border-right: 0;
  }

  .site-footer {
    align-items: start;
    grid-template-columns: 1fr;
  }
}

@media (max-width: 38rem) {
  .site-header,
  .site-footer,
  .chooser,
  .score-page,
  .not-found {
    padding-left: 1.15rem;
    padding-right: 1.15rem;
  }

  .header-context > span:first-child {
    display: none;
  }

  .brand-owl {
    height: 34px;
    width: 34px;
  }

  .brand-names > strong {
    font-size: 1rem;
  }

  h1 {
    font-size: clamp(3.1rem, 16vw, 5rem);
  }

  .brand-promise {
    display: grid;
  }

  .brand-promise span {
    border-bottom: 1px solid var(--border);
    padding-right: 0;
  }

  .brand-promise span:last-child {
    border-bottom: 0;
  }

  .brand-promise span + span::before {
    margin-right: 0.75rem;
  }

  .skin-choice {
    min-height: 28rem;
    padding: 1.75rem;
  }

  .choice-status {
    max-width: 10rem;
    text-align: right;
  }

  .input-row {
    align-items: stretch;
    flex-direction: column;
    gap: 0.75rem;
  }

  .input-row button {
    width: 100%;
  }

  .score-workbench {
    padding: 1.5rem;
  }

  .panel-index {
    position: static;
  }

  .result-heading {
    align-items: start;
    flex-direction: column;
    gap: 0.4rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }
}
