/* Sample direction "Atlas" (2026-11-16): map first. The drawn map fills the screen and the
   page sits in one white floating panel, a side panel on a computer and a bottom sheet on a
   phone. Deep violet, slate text, flat rectangles. Fake data only (../data.js). */

:root {
	--violet: #5b3fd9;
	--violet-d: #4a2fc2;
	--tint: #efeafe;
	--tint2: #ddd3fc;
	--ink: #1d2333;
	--soft: #5d6677;
	--faint: #8b93a3;
	--line: #d6dbe4;
	--line2: #e9ecf1;
	--bg: #f4f6f9;
	--green: #15804f;
	--green-t: #e2f3ea;
	--amber: #a86400;
	--amber-t: #fdf0d8;
	--map-land: #e8ecf1;
	--map-water: #c9d9ea;
	--map-park: #dbe5e2;
	--map-road: #ffffff;
	--map-minor: #f5f7fa;
	--map-text: #8a93a3;
	--map-text-strong: #2b3242;
	--map-stop: #ffffff;
	--font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html, body { margin: 0; height: 100%; }
body { background: var(--map-land); color: var(--ink); font: 14px/1.4 var(--font); -webkit-font-smoothing: antialiased; }
a { color: var(--violet); text-decoration: none; }
h1 { font-size: 20px; font-weight: 650; letter-spacing: -0.3px; margin: 0; line-height: 1.2; }
h2 { color: var(--soft); font-size: 11px; font-weight: 650; letter-spacing: 0.06em; margin: 0; text-transform: uppercase; }
p { margin: 0; }
.num, .t td.num { font-variant-numeric: tabular-nums; text-align: right; }
.soft { color: var(--soft); }
.faint { color: var(--faint); }

/* brand */

.brand { align-items: center; color: var(--ink); display: inline-flex; font-size: 15px; font-weight: 700; gap: 9px; letter-spacing: -0.2px; white-space: nowrap; }
.brand svg { flex: none; }

/* controls: small flat rectangles */

.btn { align-items: center; background: #fff; border: 1px solid var(--line); border-radius: 4px; color: var(--ink); cursor: pointer; display: inline-flex; font: inherit; font-weight: 560; gap: 6px; height: 32px; justify-content: center; padding: 0 12px; white-space: nowrap; }
.btn:hover { border-color: #b8bfcc; }
.btn.primary { background: var(--violet); border-color: var(--violet); color: #fff; }
.btn.primary:hover { background: var(--violet-d); }
.btn.big { font-size: 15px; height: 40px; }
.btn.small { font-size: 12px; height: 26px; padding: 0 8px; }
.btn.quiet { background: none; border-color: transparent; color: var(--violet); padding: 0 6px; }
.btn.wide { width: 100%; }
.btn svg { flex: none; }

.seg { background: #fff; border: 1px solid var(--line); border-radius: 4px; display: inline-flex; flex: none; max-width: 100%; overflow: hidden; }
.seg > * { align-items: center; background: none; border: 0; border-left: 1px solid var(--line); color: var(--soft); cursor: pointer; display: flex; font: inherit; font-size: 13px; font-weight: 560; height: 30px; justify-content: center; padding: 0 12px; white-space: nowrap; }
.seg > *:first-child { border-left: 0; }
.seg > .on { background: var(--tint); color: var(--violet); font-weight: 650; }
.seg.full { display: flex; }
.seg.full > * { flex: 1; padding: 0 6px; }
.seg.scroll { overflow-x: auto; scrollbar-width: none; }

input, select, textarea { background: #fff; border: 1px solid var(--line); border-radius: 4px; color: var(--ink); font: inherit; height: 34px; min-width: 0; padding: 0 10px; width: 100%; }
select { padding-right: 4px; }
textarea { height: auto; padding: 8px 10px; resize: none; }
input:focus, select:focus, textarea:focus { border-color: var(--violet); outline: 2px solid var(--tint2); outline-offset: 0; }
input[type=checkbox] { accent-color: var(--violet); height: 15px; margin: 0; width: 15px; }
.field { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.field > span, .lab { color: var(--soft); font-size: 12px; font-weight: 550; }
.row { align-items: end; display: flex; gap: 8px; }
.row > .field { flex: 1; }
.g2 { display: grid; gap: 8px; grid-template-columns: 1fr 1fr; }
.g3 { display: grid; gap: 8px; grid-template-columns: 1fr 1fr 1fr; }
.check { align-items: center; color: var(--ink); display: flex; font-size: 13px; gap: 8px; }

.tag { align-items: center; background: var(--line2); border-radius: 3px; color: var(--soft); display: inline-flex; flex: none; font-size: 11px; font-weight: 650; height: 20px; padding: 0 6px; white-space: nowrap; }
.tag.v { background: var(--tint); color: var(--violet); }
.tag.g { background: var(--green-t); color: var(--green); }
.tag.a { background: var(--amber-t); color: var(--amber); }
.sw { border-radius: 2px; display: inline-block; flex: none; height: 10px; width: 10px; }
.bar-sw { align-self: stretch; border-radius: 2px; flex: none; width: 4px; }

/* the map behind everything */

#map { background: var(--map-land); inset: 0; position: fixed; }
body.muted #map { filter: saturate(0.4); opacity: 0.55; }

/* rider pages: one floating panel */

body.rider { overflow: hidden; }
.panel { background: #fff; border: 1px solid var(--line); border-radius: 8px; box-shadow: 0 10px 30px rgba(28, 34, 60, 0.08); display: flex; flex-direction: column; left: 16px; max-height: calc(100dvh - 32px); overflow: hidden; position: fixed; top: 16px; width: 400px; z-index: 2; }
.panel.full { bottom: 16px; }
.phead { align-items: center; display: flex; justify-content: space-between; padding: 14px 16px 6px; }
.olink { color: var(--soft); font-size: 13px; font-weight: 560; }
.ptabs { border-bottom: 1px solid var(--line2); display: flex; flex: none; overflow-x: auto; padding: 0 8px; scrollbar-width: none; }
.ptabs::-webkit-scrollbar, .otabs::-webkit-scrollbar, .seg.scroll::-webkit-scrollbar { display: none; }
.ptabs a { border-bottom: 2px solid transparent; color: var(--soft); font-size: 13px; font-weight: 560; padding: 9px 8px 8px; white-space: nowrap; }
.ptabs a.on { border-bottom-color: var(--violet); color: var(--violet); font-weight: 650; }
.pbody { display: flex; flex: 1; flex-direction: column; gap: 14px; min-height: 0; overflow-y: auto; padding: 14px 16px 16px; }
.pfoot { border-top: 1px solid var(--line2); display: flex; flex: none; gap: 8px; padding: 10px 16px; }
.sect { display: flex; flex-direction: column; gap: 8px; }
.sect-h { align-items: center; display: flex; justify-content: space-between; min-height: 20px; }

.list { border: 1px solid var(--line); border-radius: 6px; overflow: hidden; }
.item { align-items: center; border-top: 1px solid var(--line2); color: var(--ink); display: flex; gap: 10px; min-height: 44px; padding: 7px 10px; }
.item:first-child { border-top: 0; }
a.item:hover, .item.click:hover { background: #faf9ff; cursor: pointer; }
.item.on { background: var(--tint); }
.item .main { flex: 1; min-width: 0; }
.item b { display: block; font-weight: 620; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.item small { color: var(--soft); display: block; font-size: 12px; }

.tiles { display: grid; gap: 6px; grid-template-columns: 1fr 1fr; }
.tile { align-items: center; border: 1px solid var(--line); border-radius: 4px; color: var(--ink); display: flex; font-weight: 600; gap: 9px; height: 42px; padding: 0 11px; }
.tile svg { color: var(--violet); flex: none; }
.tile:hover { background: var(--tint); border-color: var(--tint2); }
.tile.main { background: var(--violet); border-color: var(--violet); color: #fff; }
.tile.main svg { color: #fff; }

.contact { color: var(--soft); display: flex; flex-wrap: wrap; font-size: 12px; gap: 4px 14px; }
.contact a { align-items: center; color: var(--soft); display: inline-flex; gap: 5px; }

.answer { background: var(--tint); border-radius: 6px; display: flex; flex-direction: column; gap: 6px; padding: 12px 14px; }
.answer .stopn { align-items: baseline; display: flex; gap: 8px; }
.answer .stopn b { color: var(--violet); font-size: 30px; font-weight: 750; line-height: 1; }
.answer .stopn span { font-size: 17px; font-weight: 650; }
.answer p { font-size: 15px; }
.note-ok { align-items: center; background: var(--green-t); border-radius: 6px; color: var(--green); display: flex; font-weight: 600; gap: 8px; padding: 10px 12px; }

/* calendar */

.soon { display: grid; gap: 8px; grid-template-columns: 1fr 1fr; }
.soon > div { border: 1px solid var(--line); border-radius: 6px; padding: 8px 10px; }
.soon .run { align-items: center; display: flex; font-size: 12px; gap: 6px; margin-top: 4px; white-space: nowrap; }
.cal { border-collapse: collapse; table-layout: fixed; width: 100%; }
.cal th { color: var(--faint); font-size: 11px; font-weight: 600; height: 22px; }
.cal td { border: 1px solid var(--line2); font-size: 12px; height: 46px; padding: 3px 4px; vertical-align: top; }
.cal td b { display: block; font-weight: 620; }
.cal td i { border-radius: 1px; display: block; font-style: normal; height: 3px; margin-top: 3px; }
.cal td.off { background: var(--bg); color: var(--faint); }
.cal td.change { background: var(--amber-t); }
.cal td.today { outline: 2px solid var(--violet); outline-offset: -2px; }
.cal td.empty { border: 0; }
.key { color: var(--soft); display: flex; flex-wrap: wrap; font-size: 12px; gap: 4px 12px; }
.key span { align-items: center; display: inline-flex; gap: 5px; }

/* office: a slim top bar, then the full width */

body.office { background: #fff; display: grid; grid-template-columns: minmax(0, 1fr); grid-template-rows: auto 1fr; height: 100dvh; overflow: hidden; }
.obar { align-items: center; background: #fff; border-bottom: 1px solid var(--line); display: flex; gap: 14px; height: 48px; padding: 0 14px; position: relative; z-index: 3; }
.obar .brand span { font-size: 14px; }
.otabs { align-items: center; display: flex; flex: 1; gap: 2px; min-width: 0; overflow-x: auto; scrollbar-width: none; }
.otabs a { align-items: center; border-radius: 4px; color: var(--soft); display: flex; font-size: 13px; font-weight: 560; height: 30px; padding: 0 10px; white-space: nowrap; }
.otabs a:hover { background: var(--bg); }
.otabs a.on { background: var(--tint); color: var(--violet); font-weight: 650; }
.ouser { align-items: center; color: var(--soft); display: flex; font-size: 13px; gap: 10px; white-space: nowrap; }
.omain { min-height: 0; overflow: auto; position: relative; }
.omain #map { position: absolute; }
.tool { align-items: center; border-bottom: 1px solid var(--line2); display: flex; flex-wrap: wrap; gap: 8px; padding: 10px 16px; }
.tool h1 { font-size: 17px; margin-right: 6px; }
.tool .grow { flex: 1; }
.cols { display: grid; height: 100%; min-height: 0; }
.col { display: flex; flex-direction: column; min-height: 0; min-width: 0; overflow: auto; }
.col + .col { border-left: 1px solid var(--line); }
.colh { align-items: center; display: flex; flex: none; gap: 8px; justify-content: space-between; min-height: 44px; padding: 8px 16px; }
.colh h1 { font-size: 17px; }
.pad { padding: 0 16px 16px; }
.stack { display: flex; flex-direction: column; gap: 10px; }
.box { border: 1px solid var(--line); border-radius: 6px; padding: 12px; }
.box.tint { background: var(--tint); border-color: var(--tint2); }

table.t { border-collapse: collapse; font-size: 13px; width: 100%; }
.t th { background: #fff; border-bottom: 1px solid var(--line); color: var(--soft); font-size: 12px; font-weight: 600; height: 32px; padding: 0 10px; position: sticky; text-align: left; top: 0; white-space: nowrap; z-index: 1; }
.t th.num { text-align: right; }
.t th.sort::after { color: var(--violet); content: " \2193"; }
.t td { border-bottom: 1px solid var(--line2); height: 32px; padding: 0 10px; white-space: nowrap; }
.t th:first-child, .t td:first-child { padding-left: 16px; }
.t th:last-child, .t td:last-child { padding-right: 16px; }
.t tr.click { cursor: pointer; }
.t tr.click:hover td { background: #faf9ff; }
.t tr.on td { background: var(--tint); }
.t .act { text-align: right; width: 1%; }
.plus { color: var(--green); }

.stats { display: grid; grid-template-columns: repeat(4, 1fr); }
.stat { border-left: 1px solid var(--line2); padding: 10px 16px; }
.stat:first-child { border-left: 0; }
.stat b { display: block; font-size: 24px; font-variant-numeric: tabular-nums; font-weight: 700; letter-spacing: -0.5px; line-height: 1.15; }
.stat span { color: var(--soft); font-size: 12px; }

.opanel { background: #fff; border: 1px solid var(--line); border-radius: 8px; max-height: calc(100% - 28px); box-shadow: 0 10px 30px rgba(28, 34, 60, 0.08); display: flex; flex-direction: column; overflow: hidden; position: absolute; right: 14px; top: 14px; width: 360px; z-index: 2; }
.opanel.left { left: 14px; right: auto; width: 400px; }

.chart { align-items: end; display: flex; flex: 1; gap: 10px; min-height: 160px; padding: 8px 16px 0; }
.chart .c { align-items: center; display: flex; flex: 1; flex-direction: column; gap: 4px; height: 100%; justify-content: flex-end; }
.chart .c i { background: var(--violet); border-radius: 3px 3px 0 0; display: block; width: 100%; }
.chart .c.dim i { background: var(--tint2); }
.chart .c b { font-size: 12px; font-variant-numeric: tabular-nums; }
.chart .c span { color: var(--soft); font-size: 12px; padding-bottom: 8px; }

.big-money { font-size: 44px; font-variant-numeric: tabular-nums; font-weight: 750; letter-spacing: -1.5px; line-height: 1; }

/* phone */

@media (max-width: 799px) {
	.panel, .panel.full { border-radius: 10px 10px 0 0; border-width: 1px 0 0; bottom: 0; height: 58dvh; left: 0; max-height: none; right: 0; top: auto; width: auto; }
	.panel.tall { height: auto; max-height: 90dvh; }
	.soon { grid-template-columns: 1fr; }
	.panel::before { background: var(--line); border-radius: 2px; content: ""; height: 4px; left: 50%; margin-left: -18px; position: absolute; top: 6px; width: 36px; }
	.phead { padding-top: 16px; }
	.obar { gap: 8px; padding: 0 8px; }
	.obar .brand span, .ouser .who { display: none; }
	.omain { overflow: auto; }
	.cols { display: block; height: auto; }
	.col { overflow: visible; }
	.col + .col { border-left: 0; border-top: 1px solid var(--line); }
	.colh.hide-phone { display: none; }
	.t .hide-phone { display: none; }
	.opanel, .opanel.left { border-radius: 10px 10px 0 0; border-width: 1px 0 0; bottom: 0; left: 0; max-height: 54%; right: 0; top: auto; width: auto; }
	.omain.mapped { overflow: hidden; }
	.stats { grid-template-columns: 1fr 1fr; }
	.stat:nth-child(3) { border-left: 0; }
	.stat:nth-child(n+3) { border-top: 1px solid var(--line2); }
	.stat b { font-size: 20px; }
	.tool { padding: 8px 12px; }
	.tool h1 { display: none; }
	.big-money { font-size: 36px; }
	.cal td { height: 40px; }
}
