/* Council & landowner portal. Uses the tokens in parking.css. */
.portal { width: min(1120px, 100% - 32px); margin: 0 auto; padding: 28px 0 80px; display: grid; gap: 22px; }
.portal h1 { font-size: clamp(1.8rem, 4vw, 2.4rem); }
.portal h2 { font-size: 1.3rem; }
.portal .narrow { width: min(460px, 100%); }
/* the portal header has no menu: keep org name and sign out visible on phones */
.nav.portal-nav { display: flex; position: static; flex-direction: row; padding: 0; border: 0; gap: 12px; background: none; }
@media (max-width: 560px) { .org-name { display: none; } }
.org-name { font-weight: 700; color: var(--navy); }
.nav .btn.ghost { min-height: 40px; padding: 0 10px; }

.toolbar { display: flex; flex-wrap: wrap; gap: 10px; align-items: end; justify-content: space-between; }
.toolbar .range { display: flex; flex-wrap: wrap; gap: 8px; align-items: end; }
.toolbar .chip { padding: 8px 12px; font-size: 0.95rem; }
.toolbar label { font-size: 0.85rem; font-weight: 600; color: var(--muted); display: grid; gap: 4px; }
.toolbar input[type=date] { height: 40px; border: 1.5px solid var(--line); border-radius: 10px; padding: 0 10px; font: 500 0.95rem var(--body); color: var(--navy); }

/* stat tiles */
.tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 12px; }
.tile { background: #fff; border: 1px solid var(--line); border-radius: var(--r-md); padding: 16px 18px; display: grid; gap: 4px; }
.tile .k { font-size: 0.85rem; font-weight: 600; color: var(--muted); }
.tile .v { font: 900 1.9rem/1.05 var(--display); color: var(--navy); font-variant-numeric: tabular-nums; }
.tile .s { font-size: 0.85rem; color: var(--muted); }

.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
@media (max-width: 860px) { .grid2 { grid-template-columns: 1fr; } }
.card { background: #fff; border: 1px solid var(--line); border-radius: var(--r-md); padding: 20px; display: grid; gap: 12px; min-width: 0; }
.card header { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; flex-wrap: wrap; }
.card header p { color: var(--muted); font-size: 0.9rem; }

/* horizontal bars (single series) */
.hbars { display: grid; gap: 10px; }
.hbar { display: grid; grid-template-columns: minmax(120px, 38%) 1fr auto; gap: 10px; align-items: center; font-size: 0.95rem; }
.hbar .track { height: 12px; background: var(--paper); border-radius: 4px; overflow: hidden; }
.hbar .track { display: block; }
.hbar .fill { display: block; height: 100%; background: var(--sign); border-radius: 0 4px 4px 0; min-width: 2px; }
.hbar b { font-variant-numeric: tabular-nums; min-width: 3.5em; text-align: right; }

/* daily columns */
.cols { display: flex; align-items: flex-end; gap: 2px; height: 160px; border-bottom: 1px solid var(--line); padding-top: 8px; }
.cols .c { flex: 1; min-width: 3px; background: var(--sign); border-radius: 4px 4px 0 0; position: relative; }
.cols .c:hover, .cols .c:focus-visible { background: var(--navy); }
.cols .hit { flex: 1; height: 100%; display: flex; align-items: flex-end; cursor: default; }
.axis { display: flex; justify-content: space-between; font-size: 0.8rem; color: var(--muted); }

/* weekday x hour heatmap: one hue, light -> dark */
.heat { display: grid; grid-template-columns: 34px repeat(24, minmax(0, 1fr)); gap: 2px; font-size: 0.72rem; color: var(--muted); }
.heat .h { text-align: center; }
.heat .d { align-self: center; font-weight: 600; }
.heat .cell { aspect-ratio: 1 / 1; border-radius: 3px; background: #EEF3F8; }
.heat .cell:hover, .heat .cell:focus-visible { outline: 2px solid var(--navy); outline-offset: 0; }
.scale { display: flex; align-items: center; gap: 6px; font-size: 0.8rem; color: var(--muted); }
.scale i { width: 18px; height: 12px; border-radius: 3px; display: inline-block; }

/* tables */
.tablewrap { overflow-x: auto; }
table.data { width: 100%; border-collapse: collapse; font-size: 0.93rem; }
table.data th { text-align: left; font-weight: 700; color: var(--muted); font-size: 0.82rem; padding: 8px 10px; border-bottom: 1.5px solid var(--line); white-space: nowrap; }
table.data td { padding: 10px; border-bottom: 1px solid var(--line); vertical-align: middle; }
table.data td.n, table.data th.n { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
table.data tr:last-child td { border-bottom: 0; }
table.data .btn { min-height: 36px; padding: 0 12px; font-size: 0.88rem; }
.ev { display: inline-block; background: var(--sky-soft); color: var(--navy); border-radius: 999px; padding: 2px 10px; font-weight: 700; font-size: 0.85rem; }

.tip { position: fixed; z-index: 50; pointer-events: none; background: var(--navy); color: #fff; padding: 8px 10px; border-radius: 8px; font-size: 0.85rem; line-height: 1.35; max-width: 240px; box-shadow: 0 6px 20px rgba(14,42,77,0.25); }
.tip b { font-variant-numeric: tabular-nums; }

.explain { font-size: 0.9rem; color: var(--muted); }
input.field, textarea.field { width: 100%; height: 46px; border: 1.5px solid var(--line); border-radius: 10px; padding: 0 12px; font: 500 1rem var(--body); color: var(--navy); }
textarea.field { height: 80px; padding: 10px 12px; }
label.lbl { font-weight: 600; font-size: 0.93rem; display: grid; gap: 6px; }
