/* Counter Hax account pages. Same tokens and fonts as the main site (website/assets/css/site.css). */
@font-face { font-family: "Barlow Condensed"; src: url("fonts/BarlowCondensed-Bold.woff2") format("woff2"); font-weight: 700; font-display: swap; }
@font-face { font-family: "JetBrains Mono"; src: url("fonts/JetBrainsMono-Regular.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "JetBrains Mono"; src: url("fonts/JetBrainsMono-Bold.woff2") format("woff2"); font-weight: 700; font-display: swap; }

:root {
  --bg: #0B0D11; --surface: #14171D; --surface-2: #1A1E26; --line: #232833; --line-2: #2E3441;
  --ink: #ECEEF2; --muted: #949CAA; --lime: #C3F53C; --good: #3FB97A; --warn: #E3A33B; --bad: #F0605A;
  --accent: var(--lime); --cta: var(--lime); --cta-ink: #0B0D11; --input: #6F7888;
  --display: "Barlow Condensed", "Arial Narrow", sans-serif;
  --body: "Segoe UI Variable Text", "Segoe UI", system-ui, -apple-system, "Helvetica Neue", Roboto, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, Consolas, monospace;
  --r: 14px; --r-sm: 8px; --gutter: clamp(16px, 4vw, 48px);
}

*, *::before, *::after { box-sizing: border-box; }
body { margin: 0; min-height: 100vh; display: flex; flex-direction: column; background: var(--bg); color: var(--ink); font: 500 16px/1.6 var(--body); -webkit-font-smoothing: antialiased; }
h1, h2, p { margin: 0; }
a { color: var(--accent); font-weight: 700; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 4px; }
[hidden] { display: none !important; }

.skip { position: absolute; left: 16px; top: -60px; z-index: 100; background: var(--cta); color: var(--cta-ink); padding: 10px 14px; border-radius: var(--r-sm); font-weight: 700; text-decoration: none; }
.skip:focus { top: 12px; }

.topbar { display: flex; align-items: center; gap: 16px; min-height: 60px; padding: 8px var(--gutter); border-bottom: 1px solid var(--line); }
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; color: var(--ink); }
.brand-mark { width: 36px; height: 36px; flex: none; }
.brand-name { font: 700 1.375rem/1 var(--display); text-transform: uppercase; letter-spacing: .04em; }
.brand-name b { color: var(--lime); }
.topbar-actions { margin-left: auto; display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 10px; }

.sheet { flex: 1; width: 100%; max-width: 640px; margin: 0 auto; padding: clamp(32px, 6vw, 72px) var(--gutter); display: grid; gap: 20px; align-content: start; }
body[data-page="account"] .sheet { max-width: 860px; }

h1 { font: 700 clamp(2.25rem, 6vw, 3.5rem)/.95 var(--display); text-transform: uppercase; letter-spacing: .005em; text-wrap: balance; }
h2 { font: 700 1.0625rem/1.3 var(--body); }
.eyebrow { display: flex; align-items: center; gap: 10px; font: 400 .75rem/1.4 var(--mono); letter-spacing: .14em; text-transform: uppercase; color: var(--accent); }
.eyebrow::before { content: ""; width: 8px; height: 8px; background: currentColor; flex: none; }
.lede { font-size: 1.0625rem; color: var(--muted); max-width: 58ch; overflow-wrap: anywhere; }
.small { font-size: .875rem; color: var(--muted); }
.mono { font-family: var(--mono); letter-spacing: .06em; }

.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 46px; padding: 0 20px; border-radius: var(--r-sm); font: 700 .9375rem/1 var(--body); text-decoration: none; cursor: pointer; white-space: nowrap; border: 1px solid var(--line-2); background: var(--surface-2); color: var(--ink); }
.btn:hover { border-color: var(--muted); }
.btn.primary { background: var(--cta); border-color: var(--cta); color: var(--cta-ink); }
.btn.primary:hover { filter: brightness(1.08); }
.btn.small { min-height: 36px; padding: 0 14px; font-size: .8125rem; }
.btn:disabled { opacity: .6; cursor: progress; }
.link { background: none; border: 0; padding: 0; font: inherit; font-weight: 700; color: var(--accent); text-decoration: underline; cursor: pointer; }

.form { display: grid; gap: 18px; justify-items: start; }
.form.inline { grid-template-columns: minmax(0, 1fr) auto; align-items: end; }
.field { display: grid; gap: 8px; width: 100%; }
.field label { font-weight: 700; font-size: .875rem; }
.field input { width: 100%; min-height: 46px; padding: 0 14px; border-radius: var(--r-sm); border: 1px solid var(--input); background: var(--bg); color: var(--ink); font: 500 1rem var(--body); }
.field input.mono { font-family: var(--mono); text-transform: uppercase; }
.field input.code { font-size: 1.5rem; letter-spacing: .2em; max-width: 14ch; }
.field input::placeholder { color: var(--muted); opacity: .7; }
.hint { font-size: .8125rem; color: var(--muted); }
.tick { display: flex; gap: 12px; align-items: flex-start; color: var(--muted); }
.tick input { width: 20px; height: 20px; margin: 3px 0 0; flex: none; accent-color: var(--lime); }

.note, .panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 20px; display: grid; gap: 10px; }
.note p { color: var(--muted); font-size: .9375rem; }
.note.warn { border-color: color-mix(in srgb, var(--warn) 45%, transparent); background: color-mix(in srgb, var(--warn) 8%, var(--surface)); }
.panel-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.panel .row { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; padding-top: 10px; border-top: 1px solid var(--line); }
#products { display: grid; gap: 20px; }

.tag { display: inline-flex; align-items: center; gap: 6px; font: 400 .6875rem/1 var(--mono); letter-spacing: .1em; text-transform: uppercase; padding: 6px 8px; border-radius: 6px; border: 1px solid var(--line-2); color: var(--muted); white-space: nowrap; }
.tag.live { color: var(--good); border-color: color-mix(in srgb, var(--good) 45%, transparent); background: color-mix(in srgb, var(--good) 10%, transparent); }

/* Messages stay in view at the bottom of the window, wherever the form that caused them is. */
.status { position: sticky; bottom: 16px; z-index: 5; font-weight: 700; color: var(--good); }
.status:empty { display: none; }
.status:not(:empty) { background: var(--surface-2); border: 1px solid currentColor; border-radius: var(--r-sm); padding: 12px 16px; box-shadow: 0 8px 24px rgb(0 0 0 / .5); }
.status.bad { color: var(--bad); }

.scroll { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: .875rem; }
th, td { text-align: left; padding: 8px 12px 8px 0; border-bottom: 1px solid var(--line); white-space: nowrap; }
th { font: 400 .6875rem/1.5 var(--mono); letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }

.footer { border-top: 1px solid var(--line); padding: 20px var(--gutter); display: grid; gap: 6px; font-size: .8125rem; color: var(--muted); }
.footer a { color: var(--muted); font-weight: 500; margin-right: 16px; }
.footer a:hover { color: var(--ink); }

@media (max-width: 560px) {
  .form.inline { grid-template-columns: 1fr; }
  .brand-name { font-size: 1.125rem; }
}
