/* Faces look: white, near-black, grey, square corners, spaced capitals. */
@font-face { font-family: "Barlow Condensed"; font-weight: 400; font-display: swap; src: url("fonts/BarlowCondensed-Regular.ttf"); }
@font-face { font-family: "Barlow Condensed"; font-weight: 500; font-display: swap; src: url("fonts/BarlowCondensed-Medium.ttf"); }
@font-face { font-family: "Barlow Condensed"; font-weight: 600; font-display: swap; src: url("fonts/BarlowCondensed-SemiBold.ttf"); }
@font-face { font-family: "Barlow Condensed"; font-weight: 700; font-display: swap; src: url("fonts/BarlowCondensed-Bold.ttf"); }
@font-face { font-family: "Barlow Semi Condensed"; font-weight: 700; font-display: swap; src: url("fonts/BarlowSemiCondensed-Bold.ttf"); }

:root {
  --ink: #131516; --text: #545454; --muted: #737373; --rule: #dedede; --wash: #f5f5f5; --white: #fff;
  --ok: #17603a; --ok-wash: #e7f3ec; --bad: #a3231f; --bad-wash: #fbeaea; --warn: #7a5200; --warn-wash: #fbf3df;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--white); color: var(--text); font: 400 18px/1.4 "Barlow Condensed", "Arial Narrow", sans-serif; letter-spacing: .02em; }
h1 { font: 700 40px/1.05 "Barlow Semi Condensed", "Barlow Condensed", sans-serif; color: var(--ink); letter-spacing: -.01em; margin: 0 0 12px; }
h2 { font: 500 15px/1.3 "Barlow Condensed", sans-serif; color: var(--ink); letter-spacing: .14em; text-transform: uppercase; margin: 0 0 10px; }
h3 { font: 600 20px/1.2 "Barlow Condensed", sans-serif; color: var(--ink); margin: 0 0 8px; }
a { color: var(--ink); }
p { margin: 0 0 12px; }
.muted { color: var(--muted); }
.small { font-size: 15px; }
.eyebrow { font-size: 14px; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); }

button, .btn { display: inline-block; font: 500 16px/1.2 "Barlow Condensed", sans-serif; letter-spacing: .12em; text-transform: uppercase; text-decoration: none; text-align: center; padding: 11px 18px; border: 1px solid var(--ink); background: var(--ink); color: var(--white); border-radius: 0; cursor: pointer; }
button:hover, .btn:hover { background: #3a3d3f; border-color: #3a3d3f; }
button:disabled { background: #bdbdbd; border-color: #bdbdbd; cursor: not-allowed; }
button.ghost, .btn.ghost { background: var(--white); color: var(--ink); }
button.ghost:hover, .btn.ghost:hover { background: var(--wash); color: var(--ink); border-color: var(--ink); }
button.link { background: none; border: 0; color: var(--muted); text-decoration: underline; padding: 6px; letter-spacing: .02em; text-transform: none; font-size: 15px; font-weight: 400; }
button.link:hover { background: none; color: var(--ink); }
button.tiny, .btn.tiny { padding: 4px 8px; font-size: 13px; letter-spacing: .08em; }
button:focus-visible, a:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible { outline: 2px solid #2d6cdf; outline-offset: 2px; }

input, select, textarea { font: 400 18px/1.3 "Barlow Condensed", sans-serif; color: var(--ink); background: var(--white); border: 1px solid #a8a8a8; border-radius: 0; padding: 8px 10px; max-width: 100%; }
textarea { width: 100%; min-height: 150px; }
label { display: block; color: var(--ink); font-weight: 500; }
.field { margin-bottom: 14px; }
.field input[type=text], .field input[type=email], .field input[type=number], .field input[type=password], .field input[type=url] { width: 100%; }
.hint { color: var(--muted); font-size: 15px; font-weight: 400; margin-top: 3px; }
.check { display: flex; gap: 10px; align-items: flex-start; font-weight: 500; }
.check input { width: 20px; height: 20px; margin-top: 3px; flex: none; }

.notice { padding: 10px 14px; margin: 0 0 16px; border-left: 4px solid; }
.notice.ok { background: var(--ok-wash); border-color: var(--ok); color: var(--ok); }
.notice.bad { background: var(--bad-wash); border-color: var(--bad); color: var(--bad); }
.notice.warn { background: var(--warn-wash); border-color: var(--warn); color: var(--warn); }

/* ---------- scout screens ---------- */
.scout { min-height: 100dvh; display: flex; flex-direction: column; max-width: 560px; margin: 0 auto; padding: 0 16px; }
.scout-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 0; border-bottom: 1px solid var(--rule); }
.scout-head img { height: 22px; display: block; }
.scout-main { flex: 1; padding: 24px 0; display: flex; flex-direction: column; gap: 14px; }
.event-button { display: block; width: 100%; padding: 26px 16px; font: 700 30px/1.1 "Barlow Semi Condensed", sans-serif; letter-spacing: 0; text-transform: none; }
.event-button small { display: block; font: 500 14px/1.3 "Barlow Condensed", sans-serif; letter-spacing: .12em; text-transform: uppercase; margin-bottom: 6px; opacity: .8; }
.event-button .room { display: block; font: 400 15px/1.25 "Barlow Condensed", sans-serif; letter-spacing: .02em; margin-top: 8px; opacity: .85; }
.event-button.secondary { background: var(--white); color: var(--ink); padding: 18px 16px; font-size: 24px; }
.event-button.secondary:hover { background: var(--wash); color: var(--ink); }
.next-card { border: 1px solid var(--rule); padding: 18px; }
.next-card .big { font: 700 28px/1.1 "Barlow Semi Condensed", sans-serif; color: var(--ink); }
.edit-link { display: block; padding: 14px; border: 1px solid var(--ink); color: var(--ink); text-decoration: none; font-weight: 500; text-align: center; }
.edit-link:hover { background: var(--wash); }

.flow { flex: 1; display: flex; flex-direction: column; padding: 8px 0 16px; min-height: 0; }
.flow-top { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 4px; }
.flow-title { font-weight: 600; color: var(--ink); font-size: 18px; }
.progress { height: 3px; background: var(--rule); margin-bottom: 10px; }
.progress > i { display: block; height: 100%; background: var(--ink); width: 0; transition: width .2s; }
.stage { display: grid; grid-template-columns: 64px 1fr 64px; align-items: center; margin: 2px 0 6px; }
.arrow { height: 96px; font-size: 30px; padding: 0; background: var(--white); color: var(--ink); border-color: var(--rule); letter-spacing: 0; }
.arrow:hover { background: var(--wash); color: var(--ink); border-color: var(--ink); }
.arrow:disabled { background: var(--white); color: #cfcfcf; border-color: #eee; }
.current { text-align: center; color: var(--ink); }
.current .label { font-size: 13px; letter-spacing: .16em; text-transform: uppercase; color: var(--muted); }
.current .num { font: 700 92px/1 "Barlow Semi Condensed", sans-serif; letter-spacing: -.02em; }
.current.has-photo { position: relative; overflow: hidden; height: 96px; margin: 7px 6px; display: flex; flex-direction: column; justify-content: center; color: #fff; cursor: zoom-in; }
.current.has-photo .num { font-size: 70px; }
.current.has-photo .label { font-size: 12px; }
.current.has-photo .bg-photo { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 50% 25%; }
.current.has-photo .bg-shade { position: absolute; inset: 0; background: linear-gradient(to right, rgba(0,0,0,.25), rgba(0,0,0,.5) 50%, rgba(0,0,0,.25)); }
.current.has-photo .label, .current.has-photo .num { position: relative; color: #fff; text-shadow: 0 1px 8px rgba(0,0,0,.7); }
.current.has-photo .label { color: rgba(255,255,255,.9); }
.photo-overlay { position: fixed; inset: 0; z-index: 50; background: rgba(19, 21, 22, .94); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px; padding: 16px; cursor: zoom-out; }
.photo-overlay img { max-width: 100%; max-height: calc(100dvh - 80px); object-fit: contain; }
.photo-overlay-num { color: #fff; font-size: 18px; letter-spacing: .08em; }
.state-chip { min-height: 24px; text-align: center; font-size: 15px; color: var(--ok); font-weight: 500; }
.score-readout { text-align: center; margin: 8px 0 2px; }
input.score-input { width: 130px; text-align: center; font: 700 38px/1.1 "Barlow Semi Condensed", sans-serif; padding: 6px; }
input.score-input.bad { border-color: var(--bad); background: var(--bad-wash); }
.field-error { min-height: 21px; color: var(--bad); text-align: center; font-size: 15px; }
input[type=range].slider { -webkit-appearance: none; appearance: none; width: 100%; height: 44px; background: transparent; border: 0; padding: 0; margin: 2px 0; touch-action: pan-y; }
input[type=range].slider::-webkit-slider-runnable-track { height: 6px; background: var(--ink); }
input[type=range].slider::-moz-range-track { height: 6px; background: var(--ink); }
input[type=range].slider::-webkit-slider-thumb { -webkit-appearance: none; width: 34px; height: 34px; margin-top: -14px; border-radius: 50%; background: var(--ink); border: 3px solid var(--white); box-shadow: 0 0 0 1px var(--ink); }
input[type=range].slider::-moz-range-thumb { width: 28px; height: 28px; border-radius: 50%; background: var(--ink); border: 3px solid var(--white); box-shadow: 0 0 0 1px var(--ink); }
input[type=range].slider.unset::-webkit-slider-thumb { background: var(--white); }
input[type=range].slider.unset::-moz-range-thumb { background: var(--white); }
input[type=range].slider.unset::-webkit-slider-runnable-track { background: #bdbdbd; }
input[type=range].slider.unset::-moz-range-track { background: #bdbdbd; }
.scale { display: flex; justify-content: space-between; color: var(--muted); font-size: 14px; margin-top: -4px; }
.actions { display: grid; gap: 8px; margin-top: 12px; }
.actions .primary { padding: 18px; font-size: 20px; }
.quiet-row { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 4px 12px; margin-top: 8px; }
.sync-chip { font-size: 14px; color: var(--ok); white-space: nowrap; }
.sync-chip.waiting { color: var(--warn); font-weight: 500; }
.request-big { padding: 34px 16px !important; font-size: 26px !important; }
.request-big.on { background: var(--ok); border-color: var(--ok); }
.jump { display: flex; gap: 8px; margin-top: 10px; }
.jump input { flex: 1; min-width: 0; }

.review-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(92px, 1fr)); gap: 6px; }
.review-item { display: flex; flex-direction: column; align-items: center; padding: 9px 4px; background: var(--white); color: var(--ink); border-color: var(--rule); letter-spacing: 0; text-transform: none; }
.review-item:hover { background: var(--wash); color: var(--ink); border-color: var(--ink); }
.review-item b { font-size: 22px; line-height: 1; }
.review-item span { font-size: 15px; color: var(--muted); }
.review-item.done { border-color: var(--ink); }
.review-item.done span { color: var(--ink); font-weight: 600; }
.review-item.requested { background: var(--ok-wash); border-color: var(--ok); }
.review-item.requested span { color: var(--ok); }
.thanks { text-align: center; padding: 28px 0 12px; }

/* ---------- admin ---------- */
.admin-bar { background: var(--ink); color: var(--white); padding: 0 24px; display: flex; align-items: center; gap: 22px; flex-wrap: wrap; position: sticky; top: 0; z-index: 5; }
.admin-bar img { height: 20px; display: block; }
.admin-bar nav { display: flex; flex-wrap: wrap; flex: 1; }
.admin-bar nav a { color: #cfcfcf; text-decoration: none; padding: 16px 10px; font-size: 15px; letter-spacing: .1em; text-transform: uppercase; }
.admin-bar nav a:hover { color: var(--white); }
.admin-bar nav a.on { color: var(--white); box-shadow: inset 0 -3px 0 var(--white); }
.admin-bar button { background: none; border: 0; color: #cfcfcf; font-size: 14px; padding: 6px; }
.admin-bar button:hover { background: none; color: var(--white); }
.admin-main { max-width: 1320px; margin: 0 auto; padding: 26px 24px 70px; }
.page-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; flex-wrap: wrap; margin-bottom: 16px; }
.page-head h1 { margin: 0; }
.panel { border: 1px solid var(--rule); padding: 18px; margin-bottom: 18px; }
.toolbar { display: flex; gap: 10px; flex-wrap: wrap; align-items: flex-end; }
.table-wrap { overflow-x: auto; }
table { border-collapse: collapse; width: 100%; font-size: 17px; }
th { text-align: left; font-weight: 500; font-size: 13px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); padding: 7px 8px; border-bottom: 1px solid var(--ink); white-space: nowrap; }
td { padding: 7px 8px; border-bottom: 1px solid var(--rule); vertical-align: middle; color: var(--ink); }
td.num, th.num { text-align: right; font-variant-numeric: tabular-nums; }
.pill { display: inline-block; padding: 1px 7px; font-size: 13px; letter-spacing: .06em; text-transform: uppercase; border: 1px solid var(--rule); color: var(--muted); white-space: nowrap; }
.pill.open { background: var(--ok); border-color: var(--ok); color: #fff; }
.pill.youth { background: var(--warn-wash); border-color: var(--warn); color: var(--warn); }

.grand-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(290px, 1fr)); gap: 14px; margin-bottom: 26px; }
.events-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(440px, 1fr)); gap: 14px; }
.card { border: 1px solid var(--rule); padding: 14px 16px; min-width: 0; }
.card.grand { border-color: var(--ink); }
.card-head { display: flex; justify-content: space-between; gap: 8px; align-items: baseline; margin-bottom: 8px; }
.card-head h3 { margin: 0; font-size: 24px; }
.divs { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.divs.single { grid-template-columns: 1fr; }
.place { padding: 6px 0; border-top: 1px solid var(--rule); }
.place .tag { font-size: 12px; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }
.place.first .who { font-weight: 700; font-size: 20px; }
.who { color: var(--ink); font-weight: 500; line-height: 1.2; overflow-wrap: anywhere; }
.who small { color: var(--muted); font-weight: 400; font-size: 14px; }
.tie { color: var(--warn); font-weight: 600; font-size: 13px; letter-spacing: .06em; text-transform: uppercase; }
.repeat-note { margin-top: 6px; padding: 7px 9px; background: var(--warn-wash); color: var(--warn); font-size: 15px; line-height: 1.25; }
.repeat-note form { margin-top: 4px; }
.empty { color: var(--muted); font-size: 16px; padding: 6px 0; }
.paper-input { width: 78px; text-align: center; font-size: 20px; font-weight: 600; padding: 4px; }
.paper-input.bad { border-color: var(--bad); background: var(--bad-wash); }
.sticky-save { position: sticky; bottom: 0; background: var(--white); padding: 12px 0; border-top: 1px solid var(--ink); display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; margin-top: 8px; }
.two { display: grid; grid-template-columns: repeat(auto-fit, minmax(340px, 1fr)); gap: 18px; align-items: start; }
.lock-row { display: flex; justify-content: space-between; align-items: center; gap: 14px; flex-wrap: wrap; padding: 8px 0; }
.lock-row + .lock-row { border-top: 1px solid var(--rule); }
.reminder-row { display: flex; justify-content: space-between; align-items: center; gap: 14px; padding: 8px 0; border-top: 1px solid var(--rule); color: var(--ink); }
.reminders { border-color: var(--warn); }
.qr-dialog { border: 1px solid var(--ink); border-radius: 0; padding: 22px; width: min(440px, calc(100vw - 32px)); text-align: center; color: var(--text); }
.qr-dialog::backdrop { background: rgba(19, 21, 22, .72); }
.qr-org { font: 700 32px/1.1 "Barlow Semi Condensed", sans-serif; letter-spacing: 0; text-transform: none; margin: 6px 0 2px; overflow-wrap: anywhere; }
.qr-person { font-size: 20px; color: var(--ink); min-height: 28px; }
.qr-dialog img { display: block; width: min(340px, 100%); height: auto; margin: 6px auto; }
.qr-status { min-height: 28px; font-size: 19px; color: var(--muted); }
.qr-status.done { color: var(--ok); font-weight: 600; }
.qr-actions { display: flex; justify-content: space-between; gap: 8px; margin-top: 10px; }
[hidden] { display: none !important; }
.check-row { display: flex; align-items: center; gap: 12px; padding: 10px 0; border-top: 1px solid var(--rule); color: var(--ink); }
.check-row:first-child { border-top: 0; }
.check-text { flex: 1; }
.check-mark { width: 28px; height: 28px; flex: none; display: flex; align-items: center; justify-content: center; font-weight: 700; color: #fff; background: var(--muted); }
.check-row.ok .check-mark { background: var(--ok); }
.check-row.warn .check-mark { background: var(--warn); }
.check-row.warn b { color: var(--warn); }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.matrix td { text-align: center; padding: 4px 6px; font-variant-numeric: tabular-nums; }
.matrix td:first-child { text-align: left; white-space: nowrap; }
.matrix td.zero { color: #c9c9c9; }
.matrix td.full { background: var(--ok-wash); color: var(--ok); font-weight: 600; }
.qr-mini { width: 54px; height: 54px; display: block; }
.login-box { max-width: 420px; margin: 0 auto; padding: 40px 16px; }
.login-box img { height: 30px; display: block; margin-bottom: 26px; }
pre.mail { white-space: pre-wrap; background: var(--wash); padding: 12px; font: 400 16px/1.35 "Barlow Condensed", sans-serif; color: var(--ink); margin: 0; }
.cards-print { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; padding: 14px; }
.qr-card { border: 1px solid var(--ink); padding: 18px; text-align: center; break-inside: avoid; }
.qr-card img.logo { height: 20px; }
.qr-card img.code { width: 210px; height: 210px; display: block; margin: 8px auto; }
.qr-card .org { font: 700 24px/1.1 "Barlow Semi Condensed", sans-serif; color: var(--ink); margin-top: 10px; }
.no-print { padding: 14px; }
@media print { .no-print { display: none; } .cards-print { padding: 0; } }
@media (max-width: 720px) {
  .admin-main { padding: 18px 16px 60px; }
  .admin-bar { padding: 0 16px; gap: 8px; position: static; }
  .admin-bar img { margin-top: 12px; }
  .admin-bar nav { order: 3; flex-basis: 100%; }
  .admin-bar nav a { padding: 10px 7px; }
  .events-grid { grid-template-columns: 1fr; }
  .divs { grid-template-columns: 1fr; }
  h1 { font-size: 32px; }
}
@media (max-height: 640px) {
  .current .num { font-size: 68px; }
  .current.has-photo { height: 70px; margin: 8px 4px; }
  .current.has-photo .num { font-size: 48px; }
  .arrow { height: 70px; }
  .actions .primary { padding: 13px; }
  .request-big { padding: 22px 16px !important; }
}
