/* FestiVall — shared tokens and components
   World: printed site plans (CAD title blocks, hairlines, ruled tables) + Tyvek wristbands.
   Paper, ink, one fluorescent signal colour; status colours only where they mean something. */
@import url('https://fonts.googleapis.com/css2?family=Archivo:wdth,wght@62..125,400..900&family=IBM+Plex+Mono:wght@400;500;600&display=swap');

:root {
  --paper: #efede6;
  --paper-2: #e5e2d8;
  --paper-3: #d9d5c8;
  --ink: #141413;
  --ink-2: #4b4a44;
  --ink-3: #7b7970;
  --rule: rgba(20, 20, 19, .16);
  --rule-strong: rgba(20, 20, 19, .55);
  --band: #c8f23d;          /* Tyvek wristband */
  --band-ink: #1d2400;
  --ok: #1d7a45;
  --ok-bg: #d6efdc;
  --warn: #e86a12;
  --warn-bg: #fbe3cf;
  --deny: #c62a22;
  --deny-bg: #f6d7d3;
  --display: 'Archivo', 'Arial Narrow', sans-serif;
  --mono: 'IBM Plex Mono', ui-monospace, Consolas, monospace;
  --radius: 3px;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--paper); color: var(--ink);
  font-family: var(--display); font-variation-settings: 'wdth' 100; font-size: 17px; line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; }
img, svg { display: block; max-width: 100%; }
button, input, select { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; }
[hidden] { display: none !important; }

.mono { font-family: var(--mono); font-feature-settings: 'zero' 1; }
.eyebrow { font-family: var(--mono); font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-2); }

/* Wordmark: wide, heavy, like stencilled signage */
.wordmark { font-family: var(--display); font-weight: 900; font-variation-settings: 'wdth' 125; letter-spacing: -.02em; text-decoration: none; font-size: 22px; line-height: 1; display: inline-flex; align-items: center; gap: 10px; }
.wordmark .tab { width: 14px; height: 22px; background: var(--band); border: 1.5px solid var(--ink); border-radius: 2px; }

/* Buttons: flat, ruled, no glow */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; padding: 13px 20px; border: 1.5px solid var(--ink); border-radius: var(--radius); background: transparent; font-weight: 700; font-variation-settings: 'wdth' 110; text-decoration: none; cursor: pointer; line-height: 1.1; transition: background .12s, transform .12s; }
.btn:hover { background: var(--paper-2); }
.btn:active { transform: translateY(1px); }
.btn-ink { background: var(--ink); color: var(--paper); }
.btn-ink:hover { background: #2b2b29; }
.btn-band { background: var(--band); color: var(--band-ink); }
.btn-band:hover { background: #b9e52b; }
.btn-sm { padding: 8px 12px; font-size: 14px; }
.btn[disabled] { opacity: .45; cursor: not-allowed; }

/* ---------- Plan sheet: the venue plan as a printed drawing with a title block ---------- */
.sheet { position: relative; background: #fbfaf6; border: 1.5px solid var(--ink); padding: 14px; }
.sheet::before, .sheet::after { content: ''; position: absolute; width: 12px; height: 12px; border-color: var(--ink); border-style: solid; }
.sheet::before { top: 5px; left: 5px; border-width: 1.5px 0 0 1.5px; }
.sheet::after { bottom: 5px; right: 5px; border-width: 0 1.5px 1.5px 0; }
.sheet-plan { position: relative; border: 1px solid var(--rule); background: #fff; overflow: hidden; }
.sheet-plan svg { width: 100%; height: auto; }
.plan-img { filter: grayscale(1) contrast(1.15); opacity: .38; }
.zone-shape { stroke: var(--ink); stroke-width: 1.2; transition: fill .6s ease, fill-opacity .6s ease; }
.zone-shape.is-low { fill: var(--band); fill-opacity: .62; }
.zone-shape.is-mid { fill: #ffb13b; fill-opacity: .62; }
.zone-shape.is-high { fill: var(--deny); fill-opacity: .55; }
.zone-shape.is-empty { fill: #fff; fill-opacity: .15; stroke-dasharray: 3 3; }
.zone-name { font-family: var(--display); font-weight: 800; font-variation-settings: 'wdth' 80; font-size: 11px; fill: var(--ink); text-transform: uppercase; letter-spacing: .02em; }
.zone-count { font-family: var(--mono); font-weight: 600; font-size: 10px; fill: var(--ink); }
.zone-label-bg { fill: #fbfaf6; stroke: var(--ink); stroke-width: .8; }
.gate-dot { fill: var(--ink); }
.gate-label { font-family: var(--mono); font-size: 7px; fill: var(--ink); }

.titleblock { display: grid; grid-template-columns: repeat(4, auto); border: 1px solid var(--ink); border-top: 0; font-family: var(--mono); font-size: 11.5px; }
.titleblock > div { padding: 6px 10px; border-left: 1px solid var(--ink); display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.titleblock > div:first-child { border-left: 0; }
.titleblock dt, .titleblock .k { color: var(--ink-3); font-size: 10px; text-transform: uppercase; letter-spacing: .06em; }
.titleblock .v { font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.live-dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--ok); margin-right: 6px; vertical-align: 1px; animation: blink 1.6s steps(2, start) infinite; }
.live-dot.is-off { background: var(--ink-3); animation: none; }
@keyframes blink { to { visibility: hidden; } }

.legend { display: flex; flex-wrap: wrap; gap: 14px; font-family: var(--mono); font-size: 11.5px; color: var(--ink-2); margin-top: 10px; }
.legend i { display: inline-block; width: 12px; height: 12px; border: 1px solid var(--ink); margin-right: 6px; vertical-align: -2px; }

/* Wristband strip */
.band { background: var(--band); color: var(--band-ink); border-block: 1.5px solid var(--ink); overflow: hidden; white-space: nowrap; font-family: var(--mono); font-weight: 600; font-size: 13px; letter-spacing: .12em; text-transform: uppercase; position: relative; }
.band-inner { display: flex; gap: 28px; padding: 11px 0; }
.band-inner span::after { content: '●'; margin-left: 28px; font-size: 9px; vertical-align: 2px; }
.band::before, .band::after { content: ''; position: absolute; top: 0; bottom: 0; width: 12px; background: radial-gradient(circle at 50% 50%, var(--paper) 2.5px, transparent 3px) 0 0 / 12px 12px repeat-y; }
.band::before { left: 10px; } .band::after { right: 10px; }

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