/* Admin area (admin/index.php, admin/users.php) */
:root { --red: #b3121f; --red-dark: #7d0b15; --ink: #2a1a14; --muted: #7a6a62; --cream: #fff8ef; }
* { box-sizing: border-box; }
body { margin: 0; font: 16px/1.45 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; color: var(--ink);
       background: linear-gradient(180deg, var(--red) 0, var(--red-dark) 200px, #f6ede2 200px); min-height: 100vh; }
main { max-width: 760px; margin: 0 auto; padding: 18px 14px 40px; }
h1 { color: #fff; margin: 4px 0 14px; font-size: 1.5rem; }
h2 { font-size: 1.1rem; color: var(--red-dark); margin: 4px 0 8px; }
main > h2 { margin: 20px 0 6px; }
.card { background: #fff; border-radius: 16px; padding: 16px; margin: 12px 0; box-shadow: 0 6px 18px rgba(60,10,10,.14); }
label { display: block; font-weight: 600; margin: 10px 0; }
label input, select { display: block; width: 100%; margin-top: 4px; font: inherit; padding: 12px; border-radius: 12px; border: 2px solid #e6d9cc; background: var(--cream); }
input[type=password][name=pin] { display: inline-block; width: 160px; font: inherit; padding: 12px; border-radius: 12px; border: 2px solid #e6d9cc; }
input:focus { outline: none; border-color: #f2c14e; }
.go { font: inherit; font-weight: 700; padding: 12px 20px; border-radius: 999px; border: 0; background: var(--red); color: #fff; cursor: pointer; margin-top: 6px; }
.go.green { background: #2bb35a; }
.link { background: none; border: 0; font: inherit; color: var(--red-dark); text-decoration: underline; cursor: pointer; padding: 0; }
.link.light { color: #fff; }
.who { display: flex; justify-content: space-between; flex-wrap: wrap; align-items: center; gap: 6px 10px; color: #fff; margin-bottom: 6px; font-size: .9rem; }
/* Links and buttons in the nav rows are white pills, so they're readable on the red header AND the cream page */
.who a, .who .link.light { display: inline-block; background: rgba(255,255,255,.96); color: var(--red-dark); font-weight: 700; text-decoration: none;
  padding: 7px 14px; border-radius: 999px; box-shadow: 0 2px 8px rgba(60,10,10,.15); }
.who > span:first-child:not(:only-child) { text-shadow: 0 1px 2px rgba(0,0,0,.35); }
.tiles { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
@media (min-width: 620px) { .tiles { grid-template-columns: repeat(3, 1fr); } }
.tile { display: block; background: #fff; border-radius: 16px; padding: 14px; text-decoration: none; color: inherit; box-shadow: 0 6px 18px rgba(60,10,10,.12); border: 2px solid transparent; }
.tile:hover { border-color: #f2c14e; }
.tile .i { font-size: 1.8rem; display: block; }
.tile b { display: block; color: var(--red-dark); margin: 4px 0 2px; }
.tile small { color: var(--muted); }
.badge { display: inline-block; background: #d7263d; color: #fff; border-radius: 999px; padding: 0 8px; font-size: .78rem; font-weight: 700; }
.badge.ok { background: #2bb35a; } .badge.grey { background: #9a8a82; }
.now { display: flex; gap: 10px; align-items: center; } .dot { width: 18px; height: 18px; border-radius: 50%; flex: none; }
.green .dot { background: #2bb35a; } .amber .dot { background: #f0a30a; } .red .dot { background: #d7263d; }
table { width: 100%; border-collapse: collapse; } td, th { padding: 6px 4px; border-bottom: 1px solid #f0e6dc; text-align: left; vertical-align: top; }
td.num { text-align: right; font-weight: 700; }
.err { color: #a3172b; font-weight: 600; } .small { color: var(--muted); font-size: .85rem; }
.notice { background: #e3f6e9; border: 2px solid #2bb35a; }
.temp { font-family: ui-monospace, Menlo, monospace; font-size: 1.4rem; font-weight: 700; background: #fff4d6; border: 2px dashed #e8a317; border-radius: 12px; padding: 10px 14px; display: inline-block; margin: 6px 0; user-select: all; }
.center { text-align: center; }
.row { display: flex; gap: 6px; flex-wrap: wrap; }
.row form { display: inline; }
.mini { font: inherit; font-size: .82rem; font-weight: 600; padding: 6px 10px; border-radius: 999px; border: 0; cursor: pointer; background: var(--cream); color: var(--red-dark); }
.mini.danger { background: #fde8e8; color: #a3172b; }
/* Route planner (admin/routes.php; the leaders' page has its own copy) */
details.round { background: #fff; border-radius: 16px; margin: 10px 0; box-shadow: 0 6px 18px rgba(60,10,10,.12); }
details.round summary { padding: 14px 16px; cursor: pointer; font-weight: 700; color: #7d0b15; display: flex; justify-content: space-between; gap: 10px; }
details.round[open] summary { border-bottom: 1px solid #f0e6dc; }
details.round form { padding: 12px 16px 16px; }
details.round textarea { width: 100%; min-height: 220px; font: inherit; padding: 12px; border-radius: 12px; border: 2px solid #e6d9cc; background: #fff8ef; }
.warn { background: #fff4d6; border: 2px solid #e8a317; }
.saves { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.go.draft { background: #fff; color: var(--ink); border: 2px solid #e6d9cc; }
.hidden-note { background: #fff4d6; border-radius: 10px; padding: 8px 10px; }
.todo ul { margin: 0; padding: 0; list-style: none; }
.todo li { padding: 8px 10px 8px 30px; border-bottom: 1px solid #f0e6dc; position: relative; }
.todo li::before { content: "☐"; position: absolute; left: 6px; top: 7px; color: var(--muted); }
.todo li:last-child { border-bottom: 0; }
.todo li.soon { background: #fff4d6; border-radius: 10px; }
.todo li.soon::before { content: "⚠️"; }
.todo a { color: var(--red-dark); }
details.round textarea.note { min-height: 80px; }
