/* Manifest — marshal (mobile-first) and admin pages. Wingman palette, Figtree. */
@font-face { font-family: Figtree; font-weight: 400; font-display: swap; src: url(/assets/fonts/figtree-regular.woff2) format("woff2"); }
@font-face { font-family: Figtree; font-weight: 600; font-display: swap; src: url(/assets/fonts/figtree-600.woff2) format("woff2"); }

:root {
  --slate: #30363b; --slate-2: #3b4248; --slate-3: #4a5259; --yellow: #fffc04; --cool: #a1bed4; --cobalt: #3b4c5d;
  --bg: #f4f6f8; --card: #fff; --text: #1d2226; --muted: #63707b; --line: #dfe4e8;
  --green: #1f9d55; --red: #c62828; --amber: #b7791f; --blue: #3b6ea5; --radius: 12px;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--text); font: 16px/1.45 Figtree, system-ui, -apple-system, sans-serif; }
a { color: var(--blue); }
[hidden] { display: none !important; }
h1 { font-size: 26px; margin: 0 0 12px; }
h2 { font-size: 19px; margin: 24px 0 10px; }
.muted { color: var(--muted); } .small { font-size: 14px; } .warn { color: var(--red); font-weight: 600; }

.bar { background: var(--slate); color: #fff; display: flex; align-items: center; gap: 14px; padding: 8px 14px; flex-wrap: wrap; position: sticky; top: 0; z-index: 5; }
.mark { display: flex; align-items: center; gap: 8px; color: #fff; text-decoration: none; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; font-size: 14px; }
.nav { display: flex; gap: 2px; flex-wrap: wrap; flex: 1; }
.nav a { color: var(--cool); text-decoration: none; padding: 6px 10px; border-radius: 8px; font-size: 15px; }
.nav a.on { background: var(--slate-3); color: #fff; }
.who { display: flex; align-items: center; gap: 10px; font-size: 14px; color: var(--cool); margin: 0; }
.link { background: none; border: 0; color: var(--yellow); font: inherit; cursor: pointer; padding: 0; text-decoration: underline; }

.wrap { max-width: 1100px; margin: 0 auto; padding: 16px; }
.flash { margin: 12px auto 0; max-width: 1100px; padding: 10px 14px; border-radius: 10px; background: #e6f4ea; color: #145a32; }
.flash.err { background: #fdecea; color: #8a1c1c; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; margin-bottom: 16px; }
.narrow { max-width: 420px; width: 100%; }
.center-page { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 16px; background: var(--slate); }
.login { text-align: center; }
.login .stack { text-align: left; }
.pwlogin { margin-top: 14px; text-align: left; } .pwlogin summary { cursor: pointer; color: var(--muted); }

.btn { display: inline-block; border: 0; border-radius: 10px; padding: 11px 18px; font: inherit; font-weight: 600; cursor: pointer; text-decoration: none; text-align: center; line-height: 1.2; }
.btn-yellow { background: var(--yellow); color: var(--slate); }
.btn-dark { background: var(--slate); color: #fff; }
.btn-ghost { background: transparent; color: var(--text); border: 1px solid var(--line); }
.btn-red { background: var(--red); color: #fff; }
.btn-ms { background: #2f2f2f; color: #fff; width: 100%; padding: 14px; margin: 8px 0; }
.btn-sm { padding: 6px 10px; font-size: 14px; }
.btn-huge { width: 100%; font-size: 24px; padding: 22px; border-radius: 14px; }
.btn:disabled { opacity: .5; cursor: default; }

form.stack label, .dlg label, .form label { display: block; margin: 10px 0; font-weight: 600; font-size: 14px; }
input[type=text], input[type=email], input[type=password], input[type=date], input[type=time], input[type=number], input:not([type]), select, textarea {
  display: block; width: 100%; margin-top: 4px; font: inherit; font-weight: 400; padding: 10px 12px; border: 1px solid #c9d1d8; border-radius: 8px; background: #fff; color: var(--text); }
.inline { display: flex; gap: 8px; align-items: end; flex-wrap: wrap; }
.inline label { margin: 0; flex: 1 1 160px; }
.inline input, .inline select { margin-top: 4px; }
.help { font-weight: 400; color: var(--muted); font-size: 13px; display: block; }

/* Live list */
.banner { display: block; padding: 14px 16px; border-radius: var(--radius); color: #fff; font-weight: 600; text-decoration: none; margin-bottom: 14px; font-size: 18px; }
.banner.red { background: var(--red); animation: pulse 1.6s ease-in-out infinite; }
@keyframes pulse { 50% { opacity: .85; } }
.count { font-size: 22px; font-weight: 600; } .count #count { font-size: 56px; line-height: 1; }
.people { list-style: none; margin: 10px 0 24px; padding: 0; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); }
.people li { display: flex; justify-content: space-between; gap: 12px; padding: 12px 14px; border-top: 1px solid var(--line); }
.people li:first-child { border-top: 0; }
.people .name { font-weight: 600; }
.people .sub { color: var(--muted); font-size: 14px; }
.people .when { color: var(--muted); font-size: 14px; white-space: nowrap; text-align: right; }
.tag { display: inline-block; font-size: 11px; font-weight: 600; letter-spacing: .08em; padding: 2px 7px; border-radius: 6px; margin-left: 6px; vertical-align: 2px; }
.tag.visitor { background: var(--yellow); color: var(--slate); }
.tag.staff { background: #e3e9ef; color: var(--cobalt); }
.tag.stale { background: #fff3cd; color: #7a5a00; }
.tag.added { background: #e3e9ef; color: var(--cobalt); }
.evac-start { margin: 20px 0 40px; }
.drill { display: flex; align-items: center; gap: 8px; justify-content: center; margin-top: 12px; font-weight: 600; }
.drill input { width: 22px; height: 22px; }

/* Roll call */
.evac-head { background: var(--red); color: #fff; border-radius: var(--radius); padding: 16px; text-align: center; }
.evac-head.drill { background: var(--amber); }
.evac-kind { font-weight: 600; letter-spacing: .25em; font-size: 14px; }
.evac-score { font-size: 46px; font-weight: 600; line-height: 1.1; }
.sync { margin: 8px 0 0; }
.sect { font-size: 15px; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); }
.roll { list-style: none; margin: 0; padding: 0; }
.roll li { margin: 0 0 8px; }
.roll button { width: 100%; min-height: 64px; display: flex; align-items: center; gap: 14px; text-align: left; background: #fff; border: 2px solid var(--line); border-radius: var(--radius); padding: 12px 14px; font: inherit; cursor: pointer; color: var(--text); }
.roll .box { flex: 0 0 34px; height: 34px; border-radius: 8px; border: 3px solid #9aa6b0; display: flex; align-items: center; justify-content: center; font-weight: 700; color: #fff; }
.roll .nm { font-size: 19px; font-weight: 600; display: block; }
.roll .dt { font-size: 13px; color: var(--muted); display: block; }
.roll.done button { background: #eef8f1; border-color: #bfe3cb; }
.roll.done .box { background: var(--green); border-color: var(--green); }
.roll button.busy { opacity: .6; }
.roll .empty { color: var(--muted); padding: 8px 2px; }
.evac-actions { display: flex; gap: 10px; margin: 22px 0 40px; }
.evac-actions .btn { flex: 1; padding: 16px; }
.ended-note { background: #fff; border: 1px solid var(--line); padding: 14px; border-radius: var(--radius); }
.dlg { border: 0; border-radius: var(--radius); padding: 20px; width: min(480px, 94vw); }
.dlg::backdrop { background: rgba(0,0,0,.5); }
.dlg h2 { margin-top: 0; }
.row-end { display: flex; justify-content: flex-end; gap: 10px; margin-top: 14px; }

/* Admin tables */
.tbl-wrap { overflow-x: auto; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); }
table { border-collapse: collapse; width: 100%; font-size: 14px; }
th, td { padding: 9px 10px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
th { background: #f0f3f5; font-size: 12px; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); white-space: nowrap; }
tr:last-child td { border-bottom: 0; }
td.nowrap, .nowrap { white-space: nowrap; }
.pill { display: inline-block; padding: 2px 8px; border-radius: 999px; font-size: 12px; font-weight: 600; }
.pill.in { background: #e6f4ea; color: #145a32; } .pill.out { background: #eef1f4; color: #4b5863; }
.pill.off { background: #fdecea; color: #8a1c1c; } .pill.src { background: #eef1f4; color: #4b5863; font-weight: 400; }
.mono { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 13px; }
.grid2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 16px; }
.actions { display: flex; gap: 6px; flex-wrap: wrap; }
.actions form { margin: 0; }
.stat { font-size: 32px; font-weight: 600; }
.token-box { font-family: ui-monospace, monospace; font-size: 15px; background: var(--slate); color: var(--yellow); padding: 14px; border-radius: 10px; word-break: break-all; user-select: all; }
.scan-box { border: 2px dashed var(--cool); border-radius: var(--radius); padding: 16px; background: #f8fbfd; }
.scan-box.got { border-color: var(--green); background: #eef8f1; }
.right { text-align: right; }
@media (max-width: 640px) { .who span { display: none; } .wrap { padding: 12px; } }
