/* Parkinu - mobile first, RTL/LTR aware (logical properties only). */
:root {
  --brand: #0b6e69;
  --brand-dark: #08524e;
  --brand-soft: #e3f3f1;
  --accent: #ffb020;
  --ink: #16211f;
  --muted: #5d6b69;
  --line: #dfe6e4;
  --bg: #f5f7f6;
  --card: #ffffff;
  --danger: #c0362c;
  --ok: #10805a;
  --radius: 14px;
  --shadow: 0 1px 2px rgba(16, 33, 31, .06), 0 4px 16px rgba(16, 33, 31, .08);
  --topbar-h: 56px;
  --tabbar-h: 62px;
  --warn-bg: #fff8e8;
  color-scheme: light;
}
[data-theme="dark"] {
  --brand: #2bb3a6;
  --brand-dark: #7fdcd2;
  --brand-soft: #173b38;
  --ink: #e6eeec;
  --muted: #9fb0ad;
  --line: #2f3e3c;
  --bg: #0f1716;
  --card: #18221f;
  --danger: #ff7b6e;
  --ok: #4cd19a;
  --warn-bg: #3a3120;
  --shadow: 0 1px 2px rgba(0, 0, 0, .4), 0 4px 16px rgba(0, 0, 0, .35);
  color-scheme: dark;
}
/* only the plain-OSM fallback needs darkening; the vector map has its own dark style */
[data-theme="dark"] .leaflet-tile-pane .pk-raster { filter: invert(1) hue-rotate(180deg) brightness(.9) contrast(.9); }
[data-theme="dark"] .leaflet-control-zoom a, [data-theme="dark"] .leaflet-container .leaflet-control-attribution { background: var(--card); color: var(--muted, #9aa); }
[data-theme="dark"] .btn-primary { color: #06201d; }
[data-theme="dark"] .chip input:checked + span, [data-theme="dark"] .seg input:checked + span { color: #06201d; }
[data-theme="dark"] .badge-ok, [data-theme="dark"] .status-active { background: #16392b; }
[data-theme="dark"] .status-overstay { background: #3d1c19; }
[data-theme="dark"] .map-status { background: rgba(0, 0, 0, .75); }
[data-theme="dark"] .pin-off::after { border-top-color: var(--card); }
.icon-btn .ic-sun { display: none; }
[data-theme="dark"] .icon-btn .ic-sun { display: block; }
[data-theme="dark"] .icon-btn .ic-moon { display: none; }
* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  font-family: "Heebo", system-ui, -apple-system, "Segoe UI", Arial, sans-serif;
  color: var(--ink); background: var(--bg); line-height: 1.5; font-size: 16px;
  -webkit-text-size-adjust: 100%;
}
a { color: var(--brand); }
h1 { font-size: 1.5rem; margin: 0 0 .5rem; line-height: 1.25; }
h2 { font-size: 1.15rem; margin: 0 0 .5rem; }
.muted { color: var(--muted); }
.small { font-size: .875rem; }
.center { text-align: center; }
.nowrap { white-space: nowrap; }
.ok-text { color: var(--ok); font-weight: 500; }
.danger { color: var(--danger) !important; }
[hidden] { display: none !important; }

/* ---------------------------------------------------------------- top bar & drawer */
.topbar {
  position: sticky; top: 0; z-index: 1000; height: var(--topbar-h);
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 12px; padding-top: env(safe-area-inset-top);
  background: var(--card); border-bottom: 1px solid var(--line);
}
.brand { display: flex; align-items: center; gap: 8px; text-decoration: none; color: var(--ink); }
.brand-mark {
  width: 34px; height: 34px; border-radius: 10px; background: var(--brand); color: #fff;
  display: grid; place-items: center; font-weight: 800; font-size: 20px;
  box-shadow: inset 0 -3px 0 var(--accent);
}
.brand-name { font-weight: 800; font-size: 20px; letter-spacing: -.3px; }
.topbar-actions { display: flex; align-items: center; gap: 4px; }
.lang-link { font-size: .9rem; text-decoration: none; padding: 8px 10px; border-radius: 8px; }
.icon-btn {
  background: none; border: 0; padding: 8px; border-radius: 10px; color: var(--ink); cursor: pointer;
  display: grid; place-items: center; min-width: 44px; min-height: 44px;
}
.icon-btn:hover, .lang-link:hover { background: var(--bg); }

.drawer {
  position: fixed; top: 0; bottom: 0; right: 0; width: min(300px, 85vw); z-index: 1200;
  background: var(--card); box-shadow: var(--shadow); padding: 16px; padding-top: calc(16px + env(safe-area-inset-top));
  display: flex; flex-direction: column; gap: 2px;
  transform: translateX(100%); transition: transform .22s ease; visibility: hidden;
}
.drawer.open { transform: none; visibility: visible; }
.drawer a, .drawer .link-btn {
  display: block; padding: 12px 10px; border-radius: 10px; color: var(--ink); text-decoration: none;
  font-size: 1rem; text-align: start; width: 100%;
}
.drawer a:hover, .drawer .link-btn:hover { background: var(--bg); }
.drawer-head { display: flex; gap: 10px; align-items: center; padding: 4px 4px 14px; margin-bottom: 8px; border-bottom: 1px solid var(--line); }
.drawer-backdrop, .sheet-backdrop { position: fixed; inset: 0; background: rgba(10, 20, 18, .35); z-index: 1100; }
.avatar {
  width: 40px; height: 40px; border-radius: 50%; background: var(--brand-soft); color: var(--brand-dark);
  display: grid; place-items: center; font-weight: 700; flex: none;
}
.avatar.sm { width: 28px; height: 28px; font-size: .85rem; }

/* ---------------------------------------------------------------- layout */
.page { padding: 16px; padding-bottom: calc(40px + var(--tabbar-h) + env(safe-area-inset-bottom)); }
.narrow { max-width: 640px; margin-inline: auto; }
.card { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); padding: 18px; margin-bottom: 14px; }
.card.narrow { margin-inline: auto; }
.auth-card { margin-top: 2vh; }
.auth-go { transition: transform .15s, box-shadow .15s; }
.auth-go.ready { box-shadow: 0 0 0 4px var(--brand-soft); transform: scale(1.02); }
.auth-go::after { content: " ←"; } [dir="ltr"] .auth-go::after { content: " →"; }
.page-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 12px; }
.page-head h1 { margin: 0; }
.stack { display: flex; flex-direction: column; gap: 14px; }
.notice { background: var(--brand-soft); color: var(--brand-dark); border-radius: 10px; padding: 10px 12px; margin: 8px 0 12px; }

/* ---------------------------------------------------------------- forms */
.field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 12px; font-size: .95rem; }
.field > span { font-weight: 500; }
input, select, textarea {
  font: inherit; color: inherit; width: 100%; padding: 11px 12px; min-height: 46px;
  border: 1px solid var(--line); border-radius: 10px; background: var(--card);
}
textarea { min-height: 90px; resize: vertical; }
input:focus, select:focus, textarea:focus, button:focus-visible, a:focus-visible {
  outline: 3px solid rgba(11, 110, 105, .25); outline-offset: 1px; border-color: var(--brand);
}
input:disabled { background: var(--bg); color: var(--muted); }
.code-input { font-size: 1.6rem; letter-spacing: .5em; text-align: center; font-weight: 700; }
.check { display: flex; align-items: center; gap: 10px; margin: 6px 0 14px; cursor: pointer; }
.check input { width: 22px; height: 22px; min-height: 0; accent-color: var(--brand); }
.grid-2, .grid-3 { display: grid; gap: 10px; grid-template-columns: 1fr 1fr; }
.grid-3 { grid-template-columns: 2fr 1fr 2fr; }
@media (max-width: 480px) { .grid-3 { grid-template-columns: 1fr 1fr; } .grid-3 .grow2:first-child { grid-column: 1 / -1; } }
.row-form { display: flex; gap: 10px; align-items: flex-end; flex-wrap: wrap; }
.row-form .grow { flex: 1 1 160px; }
.row-form .field { margin: 0; }
.row-form .btn { min-height: 46px; }

.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { position: relative; cursor: pointer; }
.chip input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.chip span {
  display: inline-block; padding: 9px 14px; border-radius: 999px; border: 1px solid var(--line);
  background: var(--card); font-size: .95rem; user-select: none; min-width: 44px; text-align: center;
}
.chip input:checked + span { background: var(--brand); border-color: var(--brand); color: #fff; }
.chip input:focus-visible + span { outline: 3px solid rgba(11, 110, 105, .3); }

.money-input { position: relative; }
.money-input { direction: ltr; }
.money-input .cur { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); color: var(--muted); pointer-events: none; }
.money-input input { padding-left: 36px; text-align: left; }

.step {
  display: inline-grid; place-items: center; width: 26px; height: 26px; border-radius: 50%;
  background: var(--brand-soft); color: var(--brand-dark); font-size: .85rem; font-weight: 700;
  margin-inline-end: 8px;
}
.spot-form h1 { margin: 4px 0 14px; }
.lock::before { content: "🔒 "; }
.search-row { display: flex; gap: 8px; }
.search-row .btn { flex: none; }
.pick-map { height: 300px; border-radius: 12px; margin: 10px 0 14px; border: 1px solid var(--line); z-index: 0; }
.pick-map.needs-pin { outline: 3px solid var(--danger); }
.form-actions { display: flex; gap: 10px; align-items: center; margin: 8px 0 24px; }

.photo-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 10px; }
.photo { position: relative; aspect-ratio: 1; border-radius: 12px; overflow: hidden; background: var(--bg); display: block; }
.photo img { width: 100%; height: 100%; object-fit: cover; display: block; }
.photo-remove {
  position: absolute; inset-inline: 0; bottom: 0; background: rgba(0, 0, 0, .55); color: #fff;
  font-size: .8rem; padding: 4px 6px; display: flex; gap: 4px; align-items: center;
}
.photo-remove input { width: 16px; height: 16px; min-height: 0; }
.photo-add { border: 2px dashed var(--line); display: grid; place-items: center; cursor: pointer; color: var(--muted); font-size: 2rem; }
.photo-add input { position: absolute; inset: 0; opacity: 0; cursor: pointer; }

/* ---------------------------------------------------------------- buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  font: inherit; font-weight: 600; padding: 11px 18px; min-height: 44px; border-radius: 12px;
  border: 1px solid transparent; cursor: pointer; text-decoration: none; white-space: nowrap;
}
.btn-primary { background: var(--brand); color: #fff; }
.btn-primary:hover { background: var(--brand-dark); }
.btn-primary:disabled { background: #b7c7c4; cursor: not-allowed; }
.btn-secondary { background: var(--brand-soft); color: var(--brand-dark); }
.btn-ghost { background: transparent; color: var(--ink); border-color: var(--line); }
.btn-block { width: 100%; }
.btn-sm { padding: 7px 12px; min-height: 36px; font-size: .9rem; }
.btn-lg { padding: 14px 26px; font-size: 1.05rem; }
.link-btn { background: none; border: 0; padding: 0; font: inherit; color: var(--brand); cursor: pointer; }

/* ---------------------------------------------------------------- flashes */
.flashes { position: fixed; top: calc(var(--topbar-h) + 10px); inset-inline: 12px; z-index: 1300; display: flex; flex-direction: column; gap: 8px; align-items: center; pointer-events: none; }
.flash { pointer-events: auto; max-width: 560px; width: 100%; padding: 12px 14px; border-radius: 12px; box-shadow: var(--shadow); background: var(--card); border-inline-start: 5px solid var(--brand); transition: opacity .6s; }
.flash-error { border-color: var(--danger); }
.flash-ok { border-color: var(--ok); }
.flash-dev { border-color: var(--accent); background: var(--warn-bg); font-weight: 600; }
.flash.fade { opacity: 0; pointer-events: none; }

/* ---------------------------------------------------------------- my spots */
.spot-list { display: flex; flex-direction: column; }
.spot-card { display: flex; gap: 14px; padding: 12px; }
.spot-card.is-paused { opacity: .7; }
.spot-thumb {
  width: 96px; height: 96px; flex: none; border-radius: 12px; overflow: hidden; background: var(--brand-soft);
  display: grid; place-items: center; color: var(--brand); font-weight: 800; font-size: 2rem;
}
.spot-thumb img { width: 100%; height: 100%; object-fit: cover; }
.spot-body { flex: 1; min-width: 0; }
.spot-top { display: flex; justify-content: space-between; gap: 8px; align-items: flex-start; }
.spot-top h2 { font-size: 1.05rem; margin: 0; overflow: hidden; text-overflow: ellipsis; }
.spot-meta { margin-top: 4px; }
.spot-meta .dot { margin: 0 4px; color: var(--muted); }
.hours span { display: inline-block; margin-inline-end: 10px; }
.spot-actions { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 10px; }
.spot-actions form { display: flex; gap: 6px; }
.badge { font-size: .75rem; padding: 3px 8px; border-radius: 999px; flex: none; }
.badge-ok { background: #dff5ea; color: var(--ok); }
.badge-muted { background: var(--bg); color: var(--muted); }
.empty { padding: 32px 18px; }
.empty-icon { width: 64px; height: 64px; margin: 0 auto 10px; border-radius: 18px; background: var(--brand-soft); color: var(--brand); display: grid; place-items: center; font-size: 2rem; font-weight: 800; }
.list { list-style: none; padding: 0; margin: 0 0 12px; }
.list-row { display: flex; align-items: center; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.list-row form { margin-inline-start: auto; }
.plate { background: #ffd83d; color: #111; font-weight: 700; padding: 2px 10px; border-radius: 6px; border: 2px solid #111; letter-spacing: 1px; }

/* ---------------------------------------------------------------- map page */
.map-page { overflow: hidden; }
.map-main { position: relative; height: calc(100dvh - var(--topbar-h) - var(--tabbar-h) - env(safe-area-inset-bottom)); }
.map { position: absolute; inset: 0; z-index: 0; }
.map-search { position: absolute; top: 12px; inset-inline: 12px; z-index: 500; max-width: 520px; margin-inline: auto; }
.map-search input { box-shadow: var(--shadow); border-color: transparent; padding-inline-start: 16px; min-height: 50px; border-radius: 14px; }
.suggestions { list-style: none; margin: 6px 0 0; padding: 6px; background: var(--card); border-radius: 12px; box-shadow: var(--shadow); max-height: 50vh; overflow: auto; position: relative; z-index: 600; }
.suggestions li { padding: 0; }
.suggestions li.muted { padding: 10px; }
.suggestions button { width: 100%; text-align: start; background: none; border: 0; padding: 11px 10px; border-radius: 8px; font: inherit; cursor: pointer; }
.suggestions button:hover, .suggestions button:focus { background: var(--bg); }
.map-status {
  display: table; margin: 8px auto 0; position: relative;
  background: rgba(22, 33, 31, .85); color: #fff; padding: 6px 14px; border-radius: 999px; font-size: .875rem; white-space: nowrap;
}
.fab { position: absolute; z-index: 500; box-shadow: var(--shadow); border: 0; cursor: pointer; }
.fab-locate {
  bottom: 84px; inset-inline-end: 12px; width: 48px; height: 48px; border-radius: 50%;
  background: var(--card); color: var(--brand); display: grid; place-items: center;
}
.fab-add {
  bottom: 16px; left: 50%; transform: translateX(-50%);
  background: var(--brand); color: #fff; text-decoration: none; font-weight: 700; padding: 13px 20px; border-radius: 999px; white-space: nowrap;
}
#map .leaflet-bottom { margin-bottom: 76px; }  /* only the full-screen map sits above the tab bar */
.empty-card {
  position: absolute; z-index: 450; top: 110px; inset-inline: 12px; max-width: 420px; margin-inline: auto;
  background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); padding: 14px 16px;
}
.empty-card p { margin: 4px 0 10px; }
.row-actions { display: flex; gap: 8px; flex-wrap: wrap; }

.pin-wrap { background: none; border: 0; direction: ltr; }
.pin {
  /* explicit left/top: without them an RTL page places the pin one pin-width off its point */
  position: absolute; left: 0; top: 0; transform: translate(-50%, -100%); white-space: nowrap;
  background: var(--brand); color: #fff; font-weight: 700; font-size: .9rem;
  padding: 5px 10px; border-radius: 999px; box-shadow: 0 2px 6px rgba(0, 0, 0, .25); cursor: pointer;
}
.pin::after {
  content: ""; position: absolute; left: 50%; bottom: -6px; transform: translateX(-50%);
  border: 6px solid transparent; border-top-color: var(--brand); border-bottom: 0;
}
.pin-off { background: var(--card); color: var(--muted); border: 1px solid var(--line); }
.pin-off::after { border-top-color: #fff; }
.pin:hover { z-index: 10; transform: translate(-50%, -100%) scale(1.08); }

.sheet {
  position: fixed; z-index: 1150; inset-inline: 0; bottom: 0; max-height: 82vh; overflow: auto;
  background: var(--card); border-radius: 20px 20px 0 0; box-shadow: 0 -6px 24px rgba(0, 0, 0, .18);
  transform: translateY(105%); transition: transform .25s ease; max-width: 640px; margin-inline: auto;
  padding-bottom: env(safe-area-inset-bottom);
}
.sheet.open { transform: none; }
.sheet-grip { width: 40px; height: 5px; border-radius: 3px; background: var(--line); margin: 8px auto 4px; }
.sheet-close { position: absolute; top: 8px; inset-inline-end: 10px; background: var(--card); color: var(--ink); border: 0; width: 36px; height: 36px; border-radius: 50%; font-size: 1.4rem; cursor: pointer; z-index: 2; }
.sheet-photos { display: flex; gap: 8px; overflow-x: auto; scroll-snap-type: x mandatory; padding: 6px 16px 0; }
.sheet-photos img { height: 170px; width: auto; max-width: 85%; border-radius: 12px; object-fit: cover; scroll-snap-align: start; }
.sheet-body { padding: 12px 18px 20px; }
.sheet-body h2 { margin: 0 0 2px; font-size: 1.2rem; padding-inline-end: 36px; }
.sheet-price { font-size: 1.05rem; margin: 10px 0 2px; }
.sheet-price strong { font-size: 1.5rem; }
.sheet-avail { margin-bottom: 10px; }
.tags { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 12px; }
.tag { background: var(--bg); border-radius: 999px; padding: 4px 10px; font-size: .85rem; }
.owner-line { display: flex; align-items: center; gap: 8px; margin-bottom: 6px; }

.distance { font-weight: 500; margin: -4px 0 10px; }
.gate-hint { margin: -4px 0 12px; font-size: .9rem; color: var(--brand-dark); }
.gate-hint::before { content: "🔑 "; }
.options { display: flex; flex-direction: column; gap: 8px; }
.option { position: relative; cursor: pointer; }
.option input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.option > span { display: flex; flex-direction: column; gap: 2px; padding: 10px 14px; border: 1px solid var(--line); border-radius: 12px; background: var(--card); }
.option small { color: var(--muted); font-size: .85rem; }
.option input:checked + span { border-color: var(--brand); box-shadow: inset 0 0 0 1px var(--brand); background: var(--brand-soft); }
.option input:focus-visible + span { outline: 3px solid rgba(11, 110, 105, .3); }

.pin-modes { display: flex; gap: 8px; margin: 10px 0 4px; flex-wrap: wrap; }
.pin-mode {
  display: inline-flex; align-items: center; gap: 8px; font: inherit; cursor: pointer;
  padding: 8px 14px; min-height: 44px; border-radius: 999px; border: 1px solid var(--line); background: var(--card); color: var(--ink);
}
.pin-mode.active { border-color: var(--brand); background: var(--brand-soft); color: var(--brand-dark); font-weight: 600; }
.pm-dot { width: 22px; height: 22px; border-radius: 50%; display: inline-grid; place-items: center; font-size: .75rem; font-weight: 800; color: #fff; flex: none; }
.pm-gate { background: #2a81cb; }
.pm-inner { background: var(--accent); color: #16211f; }
.inner-pin {
  position: absolute; left: 0; top: 0; transform: translate(-50%, -50%); width: 30px; height: 30px; border-radius: 50%;
  background: var(--accent); color: #16211f; font-weight: 800; display: grid; place-items: center;
  border: 3px solid #fff; box-shadow: 0 2px 6px rgba(0, 0, 0, .3); cursor: grab;
}
#clearInner { margin: -6px 0 12px; }

.when-btn {
  margin-top: 8px; width: 100%; font: inherit; background: var(--card); color: var(--ink); text-align: start;
  border: 1px solid var(--line); border-radius: 14px; padding: 8px 12px; box-shadow: var(--shadow); cursor: pointer;
  display: flex; align-items: center; gap: 10px; min-height: 52px;
}
.when-ic { color: var(--brand); flex: none; }
.when-lines { flex: 1; min-width: 0; display: flex; flex-direction: column; line-height: 1.25; }
.when-lines small { color: var(--muted); font-size: .78rem; }
.when-lines strong { font-size: .95rem; color: var(--brand-dark); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
[data-theme="dark"] .when-lines strong { color: var(--brand); }
.when-edit { flex: none; font-size: .82rem; font-weight: 700; color: var(--brand-dark); background: var(--brand-soft); padding: 6px 12px; border-radius: 999px; }
[data-theme="dark"] .when-edit { color: var(--ink); }
.when-panel { margin-top: 8px; background: var(--card); border-radius: 14px; box-shadow: var(--shadow); padding: 14px; }
.seg { display: flex; gap: 6px; margin-bottom: 12px; }
.seg label { flex: 1; position: relative; }
.seg input { position: absolute; opacity: 0; }
.seg span { display: block; text-align: center; padding: 9px; border-radius: 10px; border: 1px solid var(--line); cursor: pointer; }
.seg input:checked + span { background: var(--brand); color: #fff; border-color: var(--brand); }
.empty-card { top: 170px; }
.chip-btn { font: inherit; padding: 8px 14px; border-radius: 999px; border: 1px solid var(--line); background: var(--card); cursor: pointer; min-height: 40px; }
.chip-btn.on { border-color: var(--brand); background: var(--brand-soft); }
@media (hover: hover) { .chip-btn:hover { border-color: var(--brand); background: var(--brand-soft); } }
.book-spot { display: flex; gap: 12px; align-items: center; }
.spot-thumb.sm { width: 64px; height: 64px; font-size: 1.4rem; }
.summary .sum-row { display: flex; justify-content: space-between; align-items: baseline; font-size: 1.1rem; }
.summary .sum-row strong { font-size: 1.6rem; }
.sum-leave { font-weight: 500; color: var(--brand-dark); margin: 4px 0 8px; }
.flash.inline { position: static; box-shadow: none; margin: 8px 0; }
.mock-note { background: var(--warn-bg); border-radius: 10px; padding: 8px 12px; font-size: .9rem; font-weight: 500; }
.booking .page-head h1 { font-size: 1.3rem; }
.times { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.times > div { display: flex; flex-direction: column; }
.times strong { font-size: 1.1rem; }
.times .arrow { color: var(--muted); font-size: 1.4rem; }
[dir="rtl"] .times .arrow { transform: scaleX(-1); }
.countdown { margin-top: 12px; font-size: 1.1rem; }
.countdown strong { font-size: 1.8rem; color: var(--brand-dark); }
.countdown.late strong, .overdue { color: var(--danger); font-weight: 700; }
.extend-row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin-top: 12px; }
.address { font-size: 1.1rem; font-weight: 600; margin: 0 0 10px; }
.nav-buttons { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 12px; }
.nav-buttons .btn { flex: 1 1 110px; }
.bk-map { height: 220px; border-radius: 12px; margin-bottom: 8px; z-index: 0; }
.instructions { white-space: pre-line; background: var(--bg); border-radius: 10px; padding: 10px 12px; }
.sheet-photos.inline { padding: 6px 0 0; }
.contact { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.contact > div:first-child { display: flex; flex-direction: column; gap: 4px; }
.contact-actions { display: flex; gap: 6px; }
.actions form { margin-bottom: 10px; }
.actions .row-actions form { margin: 0; }
.money-list { margin: 14px 0 0; border-top: 1px solid var(--line); padding-top: 10px; }
.money-list > div { display: flex; justify-content: space-between; padding: 4px 0; }
.money-list dt { color: var(--muted); } .money-list dd { margin: 0; font-weight: 600; }
.stars { display: flex; gap: 6px; justify-content: center; }
.stars label { position: relative; cursor: pointer; }
.stars input { position: absolute; opacity: 0; }
.stars span { font-size: 2.2rem; color: #cfd8d6; }
.stars label:has(~ label input:checked) span, .stars label:has(input:checked) span { color: var(--accent); }
.booking-row { display: flex; justify-content: space-between; gap: 10px; text-decoration: none; color: inherit; }
.br-main { min-width: 0; } .br-side { display: flex; flex-direction: column; align-items: flex-end; gap: 6px; flex: none; }
.status-confirmed { background: var(--brand-soft); color: var(--brand-dark); }
.status-active { background: #dff5ea; color: var(--ok); }
.status-overstay { background: #fde8e6; color: var(--danger); }
.status-completed, .status-cancelled, .status-no_show { background: var(--bg); color: var(--muted); }
h3 { font-size: 1rem; margin: 14px 0 6px; }
.grid-2 > *, .grid-3 > * { min-width: 0; }
input[type="datetime-local"] { min-width: 0; max-width: 100%; }
.book-times { grid-template-columns: 1fr; }
@media (min-width: 560px) { .book-times { grid-template-columns: 1fr 1fr; } }

.lang-link { display: inline-flex; align-items: center; gap: 4px; font-weight: 600; min-height: 44px; }
.nav-ic { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; flex: none; color: var(--brand); }
.drawer a, .drawer .link-btn { display: flex; align-items: center; gap: 12px; }
.pin small { font-weight: 500; font-size: .75em; opacity: .85; }
.stars-wrap { display: flex; flex-direction: column; align-items: center; gap: 4px; }
.stars label { display: flex; flex-direction: column; align-items: center; }
.stars .n { font-size: .8rem; color: var(--muted); line-height: 1; }
.stars-scale { display: flex; justify-content: space-between; width: 100%; max-width: 280px; font-size: .8rem; color: var(--muted); }
.access::before { content: "🔑 "; }

:root { --free: #1f9d55; --soon: #1c7ed6; --busy: #d64545; }
[data-theme="dark"] { --free: #3cc47a; --soon: #4dabf7; --busy: #ff6b6b; }
.pin-free { background: var(--free); color: #fff; }
.pin-free::after { border-top-color: var(--free); }
.pin-soon { background: var(--soon); color: #fff; }
.pin-soon::after { border-top-color: var(--soon); }
.pin-busy { background: var(--busy); color: #fff; }
.pin-busy::after { border-top-color: var(--busy); }
.soon-text { color: var(--soon); font-weight: 600; }
.busy-text { color: var(--busy); font-weight: 600; }
.legend { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; margin-top: 8px; font-size: .8rem; }
.legend em { font-style: normal; font-weight: 600; color: var(--ink); background: var(--card); padding: 4px 10px; border-radius: 999px; box-shadow: var(--shadow); }
.legend button { font: inherit; border: 2px solid transparent; cursor: pointer; display: inline-flex; align-items: center; gap: 5px; background: var(--card); color: var(--ink); padding: 4px 10px; border-radius: 999px; box-shadow: var(--shadow); }
.legend i { width: 10px; height: 10px; border-radius: 50%; display: inline-block; }
.lg-free { background: var(--free); } .lg-soon { background: var(--soon); } .lg-busy { background: var(--busy); }
.empty-card { top: auto; bottom: 96px; }

/* top bar buttons, C2Stox style: framed squares, active language highlighted */
.topbar-actions { gap: 6px; }
.tb-btn {
  display: inline-grid; place-items: center; width: 42px; height: 40px; padding: 0;
  border: 1px solid var(--line); border-radius: 10px; background: var(--card); color: var(--ink);
  cursor: pointer; text-decoration: none; font-size: 1.15rem; line-height: 1;
}
.tb-btn:hover { background: var(--bg); }
.tb-btn.flag svg { width: 26px; height: 19px; border-radius: 2px; box-shadow: 0 0 0 1px rgba(0,0,0,.12); }
.tb-btn.flag { opacity: .75; }
.tb-btn.flag.active { opacity: 1; border-color: var(--brand); background: var(--brand-soft); box-shadow: inset 0 0 0 1px var(--brand); }
.tb-btn.theme .ic-sun { display: none; }
[data-theme="dark"] .tb-btn.theme .ic-sun { display: inline; }
[data-theme="dark"] .tb-btn.theme .ic-moon { display: none; }


.plate-row { display: flex; gap: 8px; } .plate-row input { flex: 1; } .plate-row .btn { flex: none; min-height: 46px; }
.v-status { min-height: 1.2em; }
.add-vehicle { margin-top: 10px; } .add-vehicle > summary { list-style: none; cursor: pointer; display: inline-flex; margin-bottom: 10px; }
.add-vehicle > summary::-webkit-details-marker { display: none; }
.option small { display: block; margin-top: 4px; }
.warn-note { background: var(--warn-bg); border-radius: 10px; padding: 8px 12px; font-size: .9rem; margin-top: 10px; }

.dup-form { margin-top: 18px; } .dup-form p { margin-top: 4px; }

.drawer-close { align-self: flex-end; margin-bottom: 6px; flex: none; }
[dir="rtl"] .drawer-close { align-self: flex-start; } /* next to the menu button, on the right */
.drawer a.btn-primary, .drawer a.btn-primary:visited { background: var(--brand); color: #fff; justify-content: center; }
.drawer a.btn-primary:hover, .drawer a.btn-primary:focus-visible { background: var(--brand-dark); color: #fff; }

.extend-card.urgent { border: 2px solid var(--accent); }
.extend-card .chips { margin-bottom: 10px; }
.ext-sum { min-height: 1.2em; margin: 4px 0 10px; font-size: .92rem; }
.ext-sum.err { color: var(--danger, #c0392b); }

.when-caret { font-size: .8em; opacity: .7; }
.when-panel .flash.inline { margin: 0 0 10px; }

/* bottom tab bar */
.tabbar {
  position: fixed; inset-inline: 0; bottom: 0; z-index: 1050; display: flex;
  height: calc(var(--tabbar-h) + env(safe-area-inset-bottom)); padding-bottom: env(safe-area-inset-bottom);
  background: var(--card); border-top: 1px solid var(--line); box-shadow: 0 -2px 10px rgba(0, 0, 0, .06);
}
.tabbar a {
  flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px;
  color: var(--muted); text-decoration: none; font-size: .74rem; font-weight: 600; min-width: 0;
}
.tabbar a span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; padding: 0 2px; }
.tabbar .nav-ic { color: currentColor; width: 24px; height: 24px; }
.tabbar a.on { color: var(--brand); }
.tabbar a.on .nav-ic { stroke-width: 2.3; }
.tabbar a.on::before { content: ""; position: absolute; top: 0; width: 36px; height: 3px; border-radius: 0 0 3px 3px; background: var(--brand); }
.tabbar a { position: relative; }

.map-status { cursor: pointer; }

/* notification badges */
#menuBtn { position: relative; }
.dot-badge { position: absolute; top: 6px; inset-inline-end: 6px; width: 11px; height: 11px; border-radius: 50%; background: var(--busy); border: 2px solid var(--card); }
.count-badge { margin-inline-start: auto; min-width: 22px; height: 22px; padding: 0 6px; border-radius: 11px; background: var(--busy); color: #fff; font-size: .78rem; font-weight: 700; display: inline-grid; place-items: center; }

/* feedback */
.fb-list { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 8px; }
.fb-item { display: flex; gap: 10px; align-items: center; padding: 12px; border: 1px solid var(--line); border-radius: 12px; text-decoration: none; color: var(--ink); }
.fb-item.unread { border-color: var(--brand); background: var(--brand-soft); }
.fb-item .fb-main { flex: 1; min-width: 0; }
.fb-item .fb-snippet { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; color: var(--muted); font-size: .9rem; }
.fb-chat { display: flex; flex-direction: column; gap: 10px; margin: 12px 0 16px; }
.fb-msg { max-width: 85%; padding: 10px 12px; border-radius: 14px; word-wrap: break-word; }
.fb-text { white-space: pre-wrap; }
.fb-msg small { display: block; color: var(--muted); font-size: .75rem; margin-top: 4px; }
.fb-msg.mine { align-self: flex-start; background: var(--brand-soft); border-end-start-radius: 4px; }
.fb-msg.theirs { align-self: flex-end; background: var(--bg); border: 1px solid var(--line); border-end-end-radius: 4px; }
.fb-who { font-weight: 700; font-size: .8rem; display: block; margin-bottom: 2px; }

/* legend = one row of equal filter chips, also on narrow phones */
.legend { flex-wrap: nowrap; gap: 6px; }
.legend button { flex: 1 1 0; min-width: 0; justify-content: center; white-space: nowrap; font-size: .8rem; padding: 6px 6px; }
/* the chosen state stands out (filled in its own colour); the others stay exactly as they were */
.legend button[aria-pressed="true"] { font-weight: 700; color: #fff; box-shadow: 0 0 0 2px var(--card), var(--shadow); }
.legend button[aria-pressed="true"][data-state="free"] { background: var(--free); }
.legend button[aria-pressed="true"][data-state="soon"] { background: var(--soon); }
.legend button[aria-pressed="true"][data-state="busy"] { background: var(--busy); }
.legend button[aria-pressed="true"] i { background: #fff; }
@media (max-width: 360px) { .legend button { font-size: .74rem; padding: 6px 4px; gap: 4px; } }

.fb-new-sep { display: flex; align-items: center; gap: 8px; color: var(--brand); font-size: .8rem; font-weight: 700; }
.fb-new-sep::before, .fb-new-sep::after { content: ""; flex: 1; height: 1px; background: var(--brand); opacity: .5; }
.fb-msg.fresh { box-shadow: 0 0 0 2px var(--brand); }
.toast-link { pointer-events: auto; text-decoration: none; cursor: pointer; }

.new-fb > summary { list-style: none; cursor: pointer; }
.new-fb > summary::-webkit-details-marker { display: none; }
.new-fb[open] > summary { margin-bottom: 14px; }

/* top bar: same layout in every language - logo on the left, menu button at the far right */
.topbar { direction: ltr; }
.topbar .brand { flex: none; }
/* wordmark: "Park" in the brand green, "inu" in the text colour (black on light, white on dark) */
.brand-name { font-size: 22px; letter-spacing: -.2px; display: inline-block; line-height: 1; white-space: nowrap; color: var(--ink); }
.brand-name b { font-weight: 800; vertical-align: baseline; }
.brand-name b:nth-child(-n+4) { color: var(--brand); }
.brand-name b:first-child { font-size: 1.12em; }
@media (max-width: 400px) {
  .topbar { padding: 0 8px; }
  .topbar-actions { gap: 4px; }
  .tb-btn { width: 38px; height: 38px; }
  .brand { gap: 6px; }
  .brand-mark { width: 30px; height: 30px; font-size: 18px; }
  .brand-name { font-size: 19px; }
}
@media (max-width: 350px) { #backBtn { display: none; } }

.drawer-sep { height: 1px; background: var(--line); margin: 8px 4px; }
/* about / guide */
.info-page h1 { margin-bottom: 12px; }
.info-page .card { margin-bottom: 12px; }
.info-hero { text-align: center; }
.info-hero h1 { margin: 10px 0 4px; }
.info-hero .brand-name { font-size: 34px; }
.brand-mark.big { width: 64px; height: 64px; font-size: 38px; border-radius: 18px; margin: 0 auto; }
.lead { font-size: 1.1rem; color: var(--muted); margin: 0; }
.info-cols { display: grid; gap: 14px; }
@media (min-width: 560px) { .info-cols { grid-template-columns: 1fr 1fr; } }
.info-cols h3 { margin: 0 0 6px; }
.info-page ul, .info-page ol { padding-inline-start: 22px; margin: 6px 0; }
.info-page li { margin: 6px 0; line-height: 1.55; }
.info-list { list-style: none; padding: 0 !important; }
.info-page .btn { margin: 4px; }
.guide-toc { display: flex; gap: 8px; flex-wrap: wrap; }
.guide-toc a { flex: 1; text-align: center; padding: 10px 8px; border-radius: 12px; background: var(--brand-soft); color: var(--brand-dark); text-decoration: none; font-weight: 700; white-space: nowrap; }
[data-theme="dark"] .guide-toc a { color: var(--ink); }
.guide-part { margin: 22px 4px 10px; scroll-margin-top: calc(var(--topbar-h) + 10px); }
details.guide { padding: 0; }
details.guide > summary { cursor: pointer; list-style: none; padding: 14px 16px; font-weight: 700; display: flex; justify-content: space-between; align-items: center; gap: 10px; }
details.guide > summary::-webkit-details-marker { display: none; }
details.guide > summary::after { content: "▾"; color: var(--brand); transition: transform .2s; }
details.guide[open] > summary::after { transform: rotate(180deg); }
details.guide > :not(summary) { margin-inline: 16px; }
details.guide[open] { padding-bottom: 12px; }
.lg-inline { display: inline-flex; align-items: center; gap: 4px; margin-inline-end: 10px; white-space: nowrap; }
.lg-inline i { width: 10px; height: 10px; border-radius: 50%; display: inline-block; }

/* ---------------------------------------------------------------- menu: floating rounded panel, coloured icon tiles */
:root { --radius: 18px; }
.drawer {
  top: 8px; bottom: 8px; right: 8px; width: min(310px, calc(100vw - 56px));
  background: var(--bg); border-radius: 24px; border: 1px solid var(--line);
  box-shadow: 0 18px 50px rgba(0, 0, 0, .28); padding: 14px; overflow-y: auto; gap: 10px;
  transform: translateX(calc(100% + 16px));
}
.drawer-backdrop { background: rgba(10, 20, 18, .45); backdrop-filter: blur(2px); }
.drawer-head { background: var(--card); border-radius: 18px; padding: 12px; margin: 0; border: 0; box-shadow: var(--shadow); }
.drawer-group { background: var(--card); border-radius: 18px; padding: 6px; box-shadow: var(--shadow); display: flex; flex-direction: column; gap: 2px; }
.drawer-group form { margin: 0; }
.drawer a, .drawer .link-btn { padding: 8px 10px; border-radius: 12px; font-weight: 600; }
.drawer-sep { display: none; }
.nav-tile { width: 36px; height: 36px; border-radius: 11px; display: grid; place-items: center; flex: none; color: #fff; box-shadow: inset 0 -2px 0 rgba(0, 0, 0, .12); }
.nav-tile .nav-ic { color: #fff; width: 20px; height: 20px; stroke-width: 2; }
.t-map { background: #0e8c83; }  .t-add { background: #2f9e44; }   .t-book { background: #1c7ed6; }
.t-spots { background: #7048e8; } .t-incoming { background: #f08c00; } .t-profile { background: #d6336c; }
.t-fb { background: #1098ad; } .t-mail { background: #c2255c; }   .t-admin { background: #e8590c; } .t-guide { background: #4263eb; }
.t-about { background: #868e96; } .t-out { background: #e03131; }
.drawer .link-btn[type=submit] { color: var(--busy); }
.drawer-close { margin: 0; }
/* rounder corners across the app */
.btn { border-radius: 14px; }
input, select, textarea { border-radius: 12px; }
.sheet { border-radius: 26px 26px 0 0; }

/* favourites */
.fav-btn { background: none; border: 0; padding: 6px; cursor: pointer; color: var(--muted); display: inline-grid; place-items: center; border-radius: 50%; flex: none; }
.fav-btn svg { width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 1.8; }
.fav-btn.on { color: #e03131; }
.fav-btn.on svg { fill: currentColor; }
.fav-btn.inline { vertical-align: middle; margin-inline-end: 4px; padding: 2px; }
.row-wrap { position: relative; }
.row-wrap > .fav-btn { position: absolute; z-index: 2; bottom: 10px; inset-inline-start: 10px; }
.fav-title { font-size: 1.05rem; margin: 6px 4px 10px; }
.fav-card { display: flex; gap: 10px; align-items: flex-start; flex-wrap: wrap; }
.fav-main { flex: 1; min-width: 60%; }
.fav-actions { width: 100%; display: flex; justify-content: flex-end; }
.fav-actions .btn { min-width: 48%; }
.fav-state { display: flex; align-items: center; gap: 6px; font-weight: 600; font-size: .9rem; margin-top: 6px; }
.fav-state i { width: 10px; height: 10px; border-radius: 50%; background: var(--muted); flex: none; }
.fav-state.st-free i { background: var(--free); } .fav-state.st-free { color: var(--free); }
.fav-state.st-soon i { background: var(--soon); } .fav-state.st-soon { color: var(--soon); }
.fav-state.st-busy i { background: var(--busy); } .fav-state.st-busy { color: var(--busy); }
.fav-state.st-off { color: var(--muted); }
.fav-hint { margin: 0 auto 10px; padding: 0 4px; }

/* compact menu: the main items as a 3-column launcher grid, so everything fits without scrolling */
.drawer { gap: 8px; padding: 12px; }
.drawer-close { position: absolute; top: 20px; inset-inline-end: 20px; width: 36px; height: 36px; z-index: 2; }
[dir="rtl"] .drawer-close { align-self: auto; }
.drawer-head { padding: 10px 12px; padding-inline-end: 56px; min-height: 56px; }
.drawer-group.grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 4px; padding: 8px 6px; }
.drawer-group.grid > a {
  flex-direction: column; justify-content: flex-start; text-align: center; gap: 5px;
  padding: 8px 2px; font-size: .74rem; line-height: 1.2; font-weight: 600; min-height: 76px;
}
.drawer-group.grid > a > span:not(.nav-tile):not(.count-badge) { display: block; }
.drawer-group.grid .nav-tile { width: 42px; height: 42px; border-radius: 13px; position: relative; }
.drawer-group.grid .nav-tile .nav-ic { width: 22px; height: 22px; }
.drawer-group.grid > a { position: relative; }
.drawer-group.grid .count-badge { position: absolute; top: 2px; inset-inline-start: calc(50% + 12px); margin: 0; }
.drawer-group:not(.grid) > a, .drawer-group:not(.grid) .link-btn { padding: 6px 10px; }
.drawer-group:not(.grid) .nav-tile { width: 32px; height: 32px; border-radius: 10px; }
.drawer-group:not(.grid) .nav-tile .nav-ic { width: 18px; height: 18px; }
.drawer { bottom: auto; max-height: calc(100% - 16px); }
.drawer-group.grid { grid-template-columns: repeat(4, 1fr); }
.drawer-group.grid > a { font-size: .7rem; padding: 8px 1px; }

.t-privacy { background: #2b8a3e; }

/* ================================================================ animation (everywhere, gentle) */
@keyframes pk-rise { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
@keyframes pk-drop { 0% { opacity: 0; transform: translate(-50%, -160%); } 70% { transform: translate(-50%, -92%); } 100% { opacity: 1; transform: translate(-50%, -100%); } }
@keyframes pk-float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-10px); } }
@keyframes pk-glow { 0%, 100% { background-position: 0% 50%; } 50% { background-position: 100% 50%; } }
@media (prefers-reduced-motion: no-preference) {
  main.page .card, .side-item { animation: pk-rise .45s cubic-bezier(.2, .7, .2, 1) backwards; }
  main.page .card:nth-child(2) { animation-delay: .05s; } main.page .card:nth-child(3) { animation-delay: .1s; }
  main.page .card:nth-child(4) { animation-delay: .15s; } main.page .card:nth-child(5) { animation-delay: .2s; }
  main.page .card:nth-child(n+6) { animation-delay: .25s; }
  .leaflet-marker-icon .pin { animation: pk-drop .45s ease-out backwards; }
  .btn, .card, .side-item, .tb-btn { transition: transform .15s ease, box-shadow .15s ease, background .15s ease; }
}

/* ================================================================ wide screens (computer) */
.desk-nav, .site-footer, .auth-hero, .side-list { display: none; }
@media (min-width: 960px) {
  :root { --topbar-h: 68px; }
  body:not(.map-page) {
    background:
      radial-gradient(1100px 500px at 100% -10%, color-mix(in srgb, var(--brand) 14%, transparent), transparent 60%),
      radial-gradient(900px 500px at -10% 110%, color-mix(in srgb, #f0a500 12%, transparent), transparent 60%),
      var(--bg);
    background-attachment: fixed;
  }
  .topbar { padding: 0 28px; box-shadow: 0 1px 0 var(--line), 0 6px 24px rgba(0, 0, 0, .04); backdrop-filter: blur(8px); }
  .brand-mark { width: 40px; height: 40px; font-size: 23px; }
  .brand-name { font-size: 26px; }
  .desk-nav { display: flex; align-items: center; gap: 4px; flex: 1; justify-content: center; }
  .desk-nav a { padding: 9px 16px; border-radius: 12px; color: var(--ink); text-decoration: none; font-weight: 600; position: relative; }
  .desk-nav a:hover { background: var(--brand-soft); }
  .desk-nav a.on { color: var(--brand); }
  .desk-nav a.on::after { content: ""; position: absolute; inset-inline: 16px; bottom: 2px; height: 3px; border-radius: 3px; background: var(--brand); }
  .desk-nav .desk-cta { background: var(--brand); color: #fff; margin-inline-start: 10px; box-shadow: 0 6px 16px color-mix(in srgb, var(--brand) 35%, transparent); }
  .desk-nav .desk-cta:hover { background: var(--brand-dark, var(--brand)); transform: translateY(-1px); }
  .tabbar { display: none; }
  .map-main { height: calc(100dvh - var(--topbar-h)); }
  .page { padding: 32px 24px 40px; }
  .narrow { max-width: 760px; }
  .card:hover { box-shadow: 0 10px 30px rgba(0, 0, 0, .08); }
  .btn:hover { transform: translateY(-1px); }

  /* footer */
  .site-footer { display: flex; align-items: center; justify-content: space-between; gap: 20px; flex-wrap: wrap;
    max-width: 1100px; margin: 10px auto 0; padding: 22px 24px 30px; border-top: 1px solid var(--line); }
  .site-footer .sf-brand { display: flex; align-items: center; gap: 8px; direction: ltr; }
  .site-footer .brand-mark { width: 30px; height: 30px; font-size: 17px; }
  .site-footer .brand-name { font-size: 19px; }
  .site-footer nav { display: flex; gap: 18px; flex-wrap: wrap; }
  .site-footer nav a { color: var(--muted); text-decoration: none; font-weight: 600; }
  .site-footer nav a:hover { color: var(--brand); }

  /* map: a side panel with search, filters and the list of spots */
  .map-search { top: 16px; bottom: 16px; inset-inline-start: 16px; inset-inline-end: auto; width: 400px; max-width: none; margin: 0;
    background: color-mix(in srgb, var(--card) 94%, transparent); backdrop-filter: blur(10px); border-radius: 24px; padding: 16px;
    box-shadow: 0 18px 50px rgba(0, 0, 0, .18); display: flex; flex-direction: column; overflow: hidden; }
  .map-search input { box-shadow: none; border-color: var(--line); }
  .map-search .when-btn { box-shadow: none; }
  .map-search .legend button { box-shadow: none; border-color: var(--line); }
  .map-status { background: none; color: var(--muted); padding: 10px 2px 6px; margin: 0; font-weight: 600; }
  .side-list { display: flex; flex-direction: column; gap: 8px; overflow-y: auto; margin: 4px -6px 0; padding: 4px 6px 8px; flex: 1; }
  .side-item { display: flex; gap: 12px; align-items: center; text-align: start; width: 100%; font: inherit; color: var(--ink);
    background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: 12px; cursor: pointer; }
  .side-item:hover { transform: translateY(-2px); box-shadow: 0 8px 22px rgba(0, 0, 0, .1); border-color: var(--brand); }
  .si-price { position: static; transform: none; flex: none; min-width: 64px; text-align: center; }
  .si-price::after { display: none; }
  .si-main { display: flex; flex-direction: column; min-width: 0; gap: 2px; }
  .si-main strong { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .si-sub { color: var(--muted); font-size: .85rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .si-state { display: flex; align-items: center; gap: 6px; font-size: .82rem; font-weight: 700; }
  .si-state i { width: 8px; height: 8px; border-radius: 50%; }
  .si-state.st-free { color: var(--free); } .si-state.st-free i { background: var(--free); }
  .si-state.st-soon { color: var(--soon); } .si-state.st-soon i { background: var(--soon); }
  .si-state.st-busy { color: var(--busy); } .si-state.st-busy i { background: var(--busy); }
  .leaflet-marker-icon.hl .pin { transform: translate(-50%, -100%) scale(1.25); z-index: 1000; box-shadow: 0 6px 18px rgba(0, 0, 0, .35); }
  .leaflet-marker-icon.hl { z-index: 10000 !important; }
  [dir="rtl"] .leaflet-right { right: 424px; }
  [dir="ltr"] .leaflet-left { left: 424px; }
  #map .leaflet-bottom { margin-bottom: 16px; }
  [dir="rtl"] .fab-add { left: calc((100% - 432px) / 2); }
  [dir="ltr"] .fab-add { left: calc(432px + (100% - 432px) / 2); }
  .fab-add { bottom: 28px; padding: 15px 26px; font-size: 1.05rem; box-shadow: 0 12px 30px color-mix(in srgb, var(--brand) 40%, transparent); }
  .fab-add:hover { transform: translateX(-50%) translateY(-2px); }
  .fab-locate { bottom: 28px; }
  .empty-card { bottom: 110px; top: auto; inset-inline-start: 440px; inset-inline-end: 24px; }
  /* spot details open as a floating card over the side panel instead of a bottom sheet */
  .sheet { top: calc(var(--topbar-h) + 16px); bottom: 16px; inset-inline-start: 16px; inset-inline-end: auto; width: 400px; max-height: none;
    border-radius: 24px; margin: 0; transform: translateX(0) scale(.97); opacity: 0; visibility: hidden;
    transition: opacity .2s ease, transform .2s ease, visibility .2s; box-shadow: 0 24px 60px rgba(0, 0, 0, .28); }
  .sheet.open { opacity: 1; visibility: visible; transform: none; }
  .sheet-backdrop { display: none; }
  .sheet-grip { display: none; }
  .sheet-photos img { height: 200px; }

  /* sign in: brand panel next to the form */
  .auth-layout { display: grid; grid-template-columns: 1fr 1fr; gap: 0; max-width: 980px; margin: 4vh auto 0;
    border-radius: 28px; overflow: hidden; box-shadow: 0 24px 70px rgba(0, 0, 0, .14); background: var(--card); }
  .auth-layout .auth-card { margin: 0; box-shadow: none; border-radius: 0; padding: 48px 44px; display: flex; flex-direction: column; justify-content: center; }
  .auth-hero { display: flex; flex-direction: column; justify-content: center; gap: 10px; position: relative; overflow: hidden;
    padding: 48px 44px; color: #fff; direction: inherit;
    background: linear-gradient(135deg, #0b6e69, #12938a, #0b5f7a, #0b6e69); background-size: 300% 300%; animation: pk-glow 14s ease infinite; }
  .auth-hero h2 { margin: 6px 0 0; direction: ltr; text-align: start; }
  .auth-hero .brand-name { font-size: 42px; color: #fff; }
  .auth-hero .brand-name b:nth-child(-n+4) { color: #b8f2ea; }
  .auth-hero .brand-mark.big { margin: 0; background: #fff; color: #0b6e69; }
  .auth-hero p { font-size: 1.15rem; opacity: .95; margin: 0 0 8px; }
  .auth-hero ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; font-size: 1.02rem; }
  .auth-hero li { background: rgba(255, 255, 255, .12); border-radius: 14px; padding: 10px 14px; }
  .ah-pins { position: absolute; inset: 0; pointer-events: none; opacity: .55; }
  .ah-pins .pin { position: absolute; left: auto; right: auto; top: auto; transform: none; opacity: .9; animation: pk-float 5s ease-in-out infinite; }
  .ah-pins .pin:nth-child(1) { top: 6%; inset-inline-end: 8%; }
  .ah-pins .pin:nth-child(2) { top: 14%; inset-inline-end: 30%; animation-delay: -1.5s; }
  .ah-pins .pin:nth-child(3) { bottom: 4%; inset-inline-end: 12%; animation-delay: -3s; }
  .ah-pins .pin:nth-child(4) { bottom: 5%; inset-inline-end: 40%; animation-delay: -2s; }

  /* about page hero */
  .info-hero { background: linear-gradient(135deg, var(--brand-soft), var(--card)); padding: 40px 24px; }
}

@media (min-width: 960px) {
  [dir="rtl"] .auth-hero h2 { text-align: right; }
  .auth-hero > *:not(.ah-pins) { position: relative; }
  .si-photo { width: 56px; height: 56px; border-radius: 12px; object-fit: cover; flex: none; }
}

/* profile pictures */
img.avatar { object-fit: cover; padding: 0; background: var(--line); }
.avatar.xs { width: 24px; height: 24px; font-size: .7rem; }
.avatar.xl { width: 92px; height: 92px; font-size: 2.2rem; }
.avatar.tab { width: 26px; height: 26px; font-size: .75rem; }
.tabbar a.on .avatar.tab { box-shadow: 0 0 0 2px var(--brand); }
.avatar-link { text-decoration: none; }
.photo-edit { display: flex; gap: 16px; align-items: center; margin: 4px 0 18px; }
.photo-pick { position: relative; cursor: pointer; flex: none; }
.photo-cam { position: absolute; bottom: -2px; inset-inline-end: -2px; width: 32px; height: 32px; border-radius: 50%;
  background: var(--card); box-shadow: var(--shadow); display: grid; place-items: center; font-size: 16px; }
.photo-edit .row-actions { margin-top: 8px; }
.card.contact { display: flex; gap: 12px; align-items: center; }
.card.contact .contact-who { flex: 1; min-width: 0; }
.renter-line { display: flex; align-items: center; gap: 6px; }
.dn-profile { display: inline-flex; align-items: center; gap: 8px; }

/* admin email page + mail prefs */
.row-btns { display: flex; gap: 10px; flex-wrap: wrap; justify-content: flex-end; }
.plain-list { list-style: none; margin: 0; padding: 0; } .plain-list li { padding: 8px 0; border-bottom: 1px solid var(--line); }
#prefs .check { display: flex; align-items: center; gap: 8px; margin: 4px 0; font-weight: 500; }

/* in-app booking notices */
.tabbar a { position: relative; }
.tabbar a span.tab-dot, .tab-dot { position: absolute; top: 4px; inset-inline-start: calc(50% + 8px); width: 10px; height: 10px; max-width: none;
  padding: 0; border-radius: 50%; background: var(--busy); border: 2px solid var(--card); overflow: visible; }
.desk-nav a .tab-dot { top: 4px; inset-inline-start: auto; inset-inline-end: 4px; }
.tab-dot[hidden] { display: none; }
.booking-row.fresh { box-shadow: 0 0 0 2px var(--busy) inset; animation: pk-pulse 1.4s ease-out 2; }
@keyframes pk-pulse { 0% { transform: scale(1); } 30% { transform: scale(1.015); } 100% { transform: scale(1); } }
@media (prefers-reduced-motion: reduce) { .booking-row.fresh { animation: none; } }
.badge-new { background: var(--busy); color: #fff; }
.consent-points { margin: 8px 0 14px; padding-inline-start: 20px; line-height: 1.7; }
.consent-card .check span { line-height: 1.5; }
.option.no-fit { opacity: .6; cursor: not-allowed; }
.option.no-fit .no-fit-note { display: block; color: var(--busy); font-weight: 600; }
.no-fit-warn { background: color-mix(in srgb, var(--busy) 12%, transparent); color: var(--busy); border-radius: 12px; padding: 10px 12px; font-weight: 600; margin: 8px 0; }
.owner-cancel { width: 100%; } .owner-cancel[open] { background: var(--bg); border-radius: 14px; padding: 10px; }
.owner-cancel summary { list-style: none; display: inline-flex; } .owner-cancel summary::-webkit-details-marker { display: none; }
.btn.danger-solid { background: var(--danger); color: #fff; }
.cancel-note { border-inline-start: 4px solid var(--danger); }
.push-status.on { font-weight: 700; color: var(--free); }
.push-prompt { display: flex; gap: 12px; align-items: flex-start; }
.push-prompt .pp-ic { font-size: 1.6rem; line-height: 1; }
.push-prompt .row-btns { justify-content: flex-start; margin-top: 8px; }
.price-hints p { margin: 6px 0; padding: 8px 12px; border-radius: 12px; font-size: .92rem; }
.price-hints .ph-err { background: color-mix(in srgb, var(--busy) 12%, transparent); color: var(--busy); font-weight: 600; }
.price-hints .ph-warn { background: #fff4d6; color: #7a5200; }
[data-theme="dark"] .price-hints .ph-warn { background: #3a3014; color: #ffd98a; }
.price-hints .ph-info { background: var(--brand-soft); color: var(--brand-dark); }

/* what's new */
.news-banner { display: flex; align-items: center; gap: 8px; margin-top: 8px; padding: 6px 6px 6px 12px; border-radius: 14px;
  background: linear-gradient(135deg, #0b6e69, #12938a); color: #fff; box-shadow: 0 6px 18px rgba(11,110,105,.25); animation: pk-drop .5s ease-out backwards; }
[dir="rtl"] .news-banner { padding: 6px 12px 6px 6px; }
.news-banner[hidden] { display: none; }
.news-banner a { color: #fff; text-decoration: none; }
.nb-main { display: flex; align-items: center; gap: 8px; flex: 1; min-width: 0; }
.nb-new { background: #ffd43b; color: #3b2f00; font-weight: 800; font-size: .72rem; padding: 2px 8px; border-radius: 999px; flex: none; }
.nb-text { font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.nb-more { font-size: .8rem; opacity: .9; white-space: nowrap; text-decoration: underline !important; }
.nb-close { background: rgba(255,255,255,.18); border: 0; color: #fff; width: 30px; height: 30px; border-radius: 50%; font-size: 1.2rem; line-height: 1; cursor: pointer; flex: none; }
.news-item { display: flex; gap: 14px; align-items: flex-start; }
.news-item .ni-icon { font-size: 2rem; line-height: 1; }
.news-item h2 { margin: 0 0 6px; font-size: 1.1rem; }
.news-item.unseen { box-shadow: 0 0 0 2px var(--brand) inset; }
.news-item .row-btns { justify-content: flex-start; margin: 10px 0 6px; }
.t-news { background: #f59f00; }
.flash-target { animation: pk-pulse 1.2s ease-out 2, pk-hl 2.4s ease-out; }
@keyframes pk-hl { 0%, 60% { box-shadow: 0 0 0 3px var(--brand); border-radius: 14px; } 100% { box-shadow: 0 0 0 0 transparent; } }
main [id] { scroll-margin-top: 84px; }
.t-terms { background: #5c7cfa; } .consent-links { display: flex; flex-wrap: wrap; gap: 8px 18px; }
.tb-btn.flag { opacity: 1; }
.tb-btn.home-btn { color: var(--brand); }
@media (max-width: 370px) { .tb-btn { width: 38px; } .topbar-actions { gap: 4px; } }
.tb-btn.home-btn.active { background: var(--brand-soft); border-color: var(--brand); box-shadow: inset 0 0 0 1px var(--brand); }

/* install the app */
.in-app .install-link, .in-app .install-banner { display: none !important; }
.t-install { background: #12b886; }
.inst-hero { display: flex; gap: 16px; align-items: center; }
.inst-hero h1 { margin: 0 0 4px; }
.inst-icon { width: 64px; height: 64px; border-radius: 16px; box-shadow: 0 4px 14px rgba(0,0,0,.15); flex: none; }
.inst-tabs { margin: 4px 0 12px; }
.steps { list-style: none; padding: 0; margin: 0 0 12px; counter-reset: none; }
.steps li { display: flex; gap: 12px; align-items: flex-start; padding: 10px 0; border-bottom: 1px dashed var(--line); line-height: 1.6; }
.steps li:last-child { border-bottom: 0; }
.st-n { flex: none; width: 30px; height: 30px; border-radius: 50%; background: var(--brand); color: #fff; font-weight: 800; display: grid; place-items: center; }
.ui-chip { display: inline-flex; align-items: center; gap: 4px; padding: 2px 10px; border-radius: 10px; background: var(--brand-soft); color: var(--brand-dark); white-space: nowrap; }
.inline-ic { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; vertical-align: -3px; }
.inline-ic circle { fill: currentColor; stroke: none; }
.inst-done { background: var(--brand-soft); color: var(--brand-dark); font-weight: 700; }
.install-banner { display: flex; align-items: center; gap: 10px; }
.t-testers { background: #7048e8; }
.tester-list { list-style: none; margin: 0; padding: 0; }
.tester-list li { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.tester-list li:last-child { border-bottom: 0; }
.tl-main { display: flex; gap: 10px; align-items: center; min-width: 0; }
.tl-actions { display: flex; gap: 6px; align-items: center; flex: none; }
.ok-txt { color: var(--free); font-weight: 600; }
.pick-choose { margin-top: 12px; padding: 12px; border-radius: 14px; background: var(--bg); }
.pick-person { padding: 8px 0; border-bottom: 1px solid var(--line); display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.pick-person .pp-name { width: 100%; font-weight: 700; }
.pick-choose { margin-top: 12px; padding: 12px; border-radius: 14px; background: var(--bg); border: 1px solid var(--line); }
.pick-person { padding: 8px 0; border-bottom: 1px dashed var(--line); }
.pick-person:last-child { border-bottom: 0; }
.pp-name { font-weight: 700; margin-bottom: 4px; }
.pick-choose .check { margin: 4px 0; }
.shared-card { box-shadow: 0 0 0 2px var(--brand) inset; }
.bulk-bar { display: flex; flex-wrap: wrap; gap: 6px 16px; align-items: center; padding: 8px 0 4px; border-bottom: 1px solid var(--line); }
.bulk-bar .check { margin: 0; }
.bulk-actions, .wa-queue { flex-basis: 100%; display: flex; flex-wrap: wrap; gap: 8px; align-items: center; padding: 8px 0; }
.wa-queue { background: var(--brand-soft); border-radius: 12px; padding: 10px 12px; justify-content: space-between; }
.tester-list li { align-items: center; }
.tester-list .sel { width: 22px; height: 22px; accent-color: var(--brand); flex: none; }
.tester-list li .tl-main { flex: 1; }

/* testers list: clean checkboxes, compact buttons on phones */
.tester-list .sel, .bulk-bar input[type=checkbox] {
  width: 22px; height: 22px; min-height: 0; padding: 0; margin: 0; border: 0; border-radius: 4px;
  box-shadow: none; outline-offset: 2px; accent-color: var(--brand); flex: none; cursor: pointer;
}
.tester-list .sel:focus, .bulk-bar input[type=checkbox]:focus { box-shadow: none; outline: none; }
.tester-list .sel:focus-visible, .bulk-bar input[type=checkbox]:focus-visible { outline: 2px solid var(--brand); }
@media (max-width: 600px) {
  .tester-list .tl-actions { gap: 6px; }
  .tester-list .tl-actions .btn { width: 44px; height: 44px; min-height: 0; padding: 0; justify-content: center; border-radius: 12px; font-size: 1.15rem; }
  .tester-list .wa-btn .wa-label { display: none; }
  .tester-list li { gap: 8px; }
}
.when-quick { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; margin: -4px 0 10px; }
.when-quick .chip-btn { padding: 8px 4px; min-height: 0; font-size: .9rem; text-align: center; }

/* friendly date/time picker (day chips + 15-minute time chips) */
.dtp-native { position: absolute !important; opacity: 0; pointer-events: none; width: 1px !important; height: 1px; min-height: 0 !important; padding: 0 !important; border: 0 !important; }
.dtp { display: grid; gap: 8px; margin-top: 4px; min-width: 0; }
.dtp-row { display: flex; gap: 8px; overflow-x: auto; scroll-behavior: smooth; padding: 2px 2px 6px; scrollbar-width: thin; -webkit-overflow-scrolling: touch; }
.dtp-chip { flex: none; display: grid; place-items: center; gap: 1px; min-width: 64px; padding: 8px 10px; border-radius: 14px;
  border: 1px solid var(--line); background: var(--card); color: var(--ink); cursor: pointer; font: inherit; line-height: 1.15; }
.dtp-chip b { font-weight: 700; font-size: .98rem; }
.dtp-chip small { font-size: .74rem; color: var(--muted); }
.dtp-times .dtp-chip { min-width: 62px; }
.dtp-times .dtp-chip b { direction: ltr; unicode-bidi: isolate; }
.dtp-chip.on { background: var(--brand); border-color: var(--brand); color: #fff; }
.dtp-chip.on small { color: rgba(255,255,255,.85); }
.dtp-empty { color: var(--muted); font-size: .9rem; padding: 8px 2px; }
.testers-add { display: grid; grid-template-columns: 1fr 1fr; gap: 8px 10px; margin-top: 12px; align-items: end; }
.testers-add label { display: grid; gap: 4px; font-size: .9rem; color: var(--muted); }
.testers-add input, .testers-add textarea { min-height: 40px; height: 40px; padding: 8px 10px; resize: none; overflow: hidden; line-height: 1.4; }
.testers-add .ta-go { grid-column: 1 / -1; min-height: 40px; }
.testers-add .ta-hint { grid-column: 1 / -1; margin-top: -2px; }
.tester-list li { padding: 8px 0; }
.tl-name { display: block; font-size: 1rem; line-height: 1.25; }
.tl-phone { font-size: .85rem; color: var(--muted); }
.tl-status { font-size: .8rem; line-height: 1.3; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
@media (max-width: 600px) {
  .tester-list .tl-actions .btn { width: 38px; height: 38px; font-size: 1rem; border-radius: 10px; }
  .tester-list .tl-actions { gap: 4px; }
}
.photo.no-preview { display: grid; place-items: center; align-content: center; gap: 2px; background: var(--brand-soft); color: var(--brand-dark); text-align: center; padding: 6px; }
.photo.no-preview .np-ic { font-size: 1.8rem; }
.photo.no-preview small { font-size: .72rem; line-height: 1.2; word-break: break-all; }
.photo.no-preview .np-note { color: var(--muted); word-break: normal; }
.photo-edit + .photo-hint { margin: -8px 0 14px; }
.photo-edit { margin-bottom: 12px; }
/* spot form: new photos */
.photo.preview .photo-x { position: absolute; top: 6px; inset-inline-end: 6px; width: 30px; height: 30px; min-height: 0; padding: 0;
  border-radius: 50%; border: 0; background: rgba(0,0,0,.6); color: #fff; font-size: .95rem; line-height: 30px; cursor: pointer; }
.photo.preview .photo-new { position: absolute; bottom: 6px; inset-inline-start: 6px; background: var(--brand); color: #fff;
  font-size: .7rem; font-weight: 700; padding: 1px 8px; border-radius: 99px; }
.photo.preview.loading { background: var(--brand-soft); }
.photo.preview.loading img { opacity: 0; }
.photo.preview.loading::after { content: ""; position: absolute; inset: 50% auto auto 50%; width: 26px; height: 26px; margin: -13px;
  border: 3px solid var(--brand); border-top-color: transparent; border-radius: 50%; animation: spin .8s linear infinite; }
.photo.no-preview .np-box { position: absolute; inset: 0; display: grid; place-items: center; align-content: center; gap: 2px; padding: 6px; }
.photo.removing img { opacity: .35; }
@keyframes spin { to { transform: rotate(360deg); } }
.photo.no-preview .photo-new { display: none; }
/* map pin: the spot has photos */
.pin-cam { display: inline-grid; place-items: center; width: 18px; height: 18px; margin-inline-start: 5px; vertical-align: -3px;
  border-radius: 50%; background: rgba(255,255,255,.95); color: #333; font-style: normal; }
.pin-off .pin-cam { background: var(--bg); }
.si-cam { font-size: .75rem; color: var(--muted); margin-inline-start: 6px; font-weight: 600; }
/* phone map: search + time filter as one compact card, smaller state chips, so more map shows */
@media (max-width: 959px) {
  .map-search { top: 8px; inset-inline: 10px; }
  .map-search input#mapSearch { min-height: 44px; border-radius: 14px 14px 0 0; box-shadow: 0 2px 10px rgba(0,0,0,.12); }
  .map-search .when-btn { margin-top: 0; min-height: 40px; padding: 4px 10px; border-radius: 0 0 14px 14px; border: 0;
    border-top: 1px solid var(--line); box-shadow: 0 6px 14px rgba(0,0,0,.12); gap: 8px; }
  .map-search .when-ic { width: 18px; height: 18px; }
  .map-search .when-lines small { display: none; }
  .map-search .when-edit { padding: 3px 10px; font-size: .78rem; }
  .map-search .legend { margin-top: 6px; }
  .map-search .legend button { padding: 3px 6px; font-size: .76rem; min-height: 0; }
  .map-search .news-banner { margin-top: 6px; padding-block: 4px; }
  .map-search .news-banner .nb-close { width: 30px; height: 30px; min-height: 0; }
}
@media (max-width: 959px) {
  .map-empty .fab-add { display: none; }
  .empty-card { padding: 10px 12px; bottom: 76px; }
  .map-empty .fab-locate { bottom: 196px; }
  .empty-card strong, .empty-card h3 { font-size: .95rem; }
  .empty-card p { margin: 2px 0 8px; font-size: .85rem; }
  .empty-card .btn { min-height: 38px; padding-block: 6px; font-size: .88rem; }
}
/* search box: recent searches */
.suggestions .sg-head { display: flex; justify-content: space-between; align-items: center; padding: 6px 14px 2px;
  font-size: .78rem; color: var(--muted); font-weight: 600; }
.suggestions .sg-head .sg-clear { width: auto; padding: 2px 6px; min-height: 0; background: none; border: 0; color: var(--brand); font: inherit; cursor: pointer; }
.suggestions .sg-recent button { color: var(--ink); }
@media (max-width: 959px) { .map-search .suggestions { position: absolute; top: 46px; inset-inline: 0; margin: 0; z-index: 700; } }
.map-status { white-space: normal; max-width: 100%; text-align: center; border-radius: 16px; line-height: 1.35; }
html, body.map-page { overflow-x: hidden; }
.dm-place { color: var(--ink); text-decoration: none; font-weight: 600; }
.tb-btn[hidden] { display: none; }
/* spot form: compact */
.grid-addr { display: grid; grid-template-columns: 1fr 88px; gap: 10px; }
.addr-summary { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; margin: 10px 0 4px; font-size: .95rem; }
.addr-summary[hidden], #addrFields[hidden] { display: none; }
.options.compact { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.options.compact .option > span { padding: 9px 12px; min-height: 44px; justify-content: center; }
.options.compact .option strong { font-size: .92rem; }
.options.compact .option small { display: none; }
.options.compact .option input:checked + span small { display: block; }
.options.compact .option:has(input:checked) { grid-column: 1 / -1; }
.price-row { grid-template-columns: repeat(3, 1fr) !important; gap: 8px; }
.price-row .money-input input { padding-left: 28px; padding-right: 8px; min-width: 0; }
.chips.days { display: grid; grid-template-columns: repeat(7, 1fr); gap: 5px; }
.chips.days .chip span { width: 100%; min-width: 0; padding-inline: 0; aspect-ratio: 1; display: grid; place-items: center; max-width: 48px; margin-inline: auto; }
.more-opts { margin-top: 14px; border-top: 1px solid var(--line); padding-top: 10px; }
.more-opts > summary { cursor: pointer; color: var(--brand-dark); font-weight: 600; font-size: .92rem; list-style: none; }
.more-opts > summary::before { content: "▸ "; }
.more-opts[open] > summary::before { content: "▾ "; }
.more-opts > summary::-webkit-details-marker { display: none; }
[data-theme="dark"] .more-opts > summary { color: var(--brand); }
/* map: a permanent "what's new" button (the banner can be closed, this one stays) */
.fab-news { bottom: 142px; inset-inline-end: 12px; height: 40px; padding: 0 12px 0 10px; border-radius: 999px; background: var(--card);
  color: var(--brand-dark); display: inline-flex; align-items: center; gap: 5px; font-weight: 700; font-size: .82rem; text-decoration: none; }
[data-theme="dark"] .fab-news { color: var(--brand); }
.fab-news .fn-dot { position: absolute; top: -5px; inset-inline-start: -5px; min-width: 18px; height: 18px; padding: 0 4px; border-radius: 9px;
  background: #e5484d; color: #fff; font-size: .7rem; display: grid; place-items: center; }
@media (max-width: 959px) { .map-empty .fab-news { bottom: 254px; } }
@media (min-width: 960px) { .fab-news { bottom: 84px; } }
/* bottom tab bar: every tab has its own colour, the icon sits in a soft tile; the current tab is a solid tile */
.tabbar a.tc-map { --tc: #0e8c83; } .tabbar a.tc-book { --tc: #1c7ed6; } .tabbar a.tc-spots { --tc: #7048e8; }
.tabbar a.tc-profile { --tc: #d6336c; } .tabbar a.tc-add { --tc: #2f9e44; }
.tabbar a { gap: 2px; }
.tabbar a .nav-ic { width: 40px; height: 30px; padding: 4px 9px; box-sizing: border-box; border-radius: 11px; color: var(--tc);
  background: color-mix(in srgb, var(--tc) 13%, transparent); stroke-width: 2; transition: background .2s, color .2s, transform .2s; }
.tabbar a.on .nav-ic { background: var(--tc); color: #fff; box-shadow: 0 3px 8px color-mix(in srgb, var(--tc) 40%, transparent); transform: translateY(-1px); }
.tabbar a.on { color: var(--tc); }
.tabbar a.on::before { display: none; }
.tabbar a:active .nav-ic { transform: scale(.92); }
.tabbar a .avatar.tab { box-shadow: 0 0 0 2px color-mix(in srgb, var(--tc) 35%, transparent); }
.tabbar a.on .avatar.tab { box-shadow: 0 0 0 2.5px var(--tc); }
[data-theme="dark"] .tabbar a .nav-ic { background: color-mix(in srgb, var(--tc) 24%, transparent); color: color-mix(in srgb, var(--tc) 65%, #fff); }
[data-theme="dark"] .tabbar a.on .nav-ic { background: var(--tc); color: #fff; }
.pin-modes { flex-wrap: nowrap; gap: 6px; }
.pin-modes .pin-mode { flex: 1 1 0; min-width: 0; justify-content: center; font-size: .85rem; padding: 6px 8px; white-space: nowrap; }
/* spot form: price suggestion + step-by-step for a first listing */
.price-suggest { display: flex; align-items: center; justify-content: space-between; gap: 10px; background: #fff8e1; border: 1px solid #ffe08a;
  border-radius: 12px; padding: 10px 12px; margin-bottom: 12px; font-size: .9rem; }
.price-suggest[hidden] { display: none; }
.price-suggest .btn { flex: none; }
.price-suggest.used { background: var(--brand-soft); border-color: transparent; }
[data-theme="dark"] .price-suggest { background: #3a3218; border-color: #5c4d1c; }
.wiz-bar { display: flex; align-items: center; gap: 10px; margin: -4px 0 12px; }
.wiz-track { flex: 1; height: 6px; border-radius: 3px; background: var(--line); overflow: hidden; }
.wiz-track i { display: block; height: 100%; background: var(--brand); border-radius: 3px; transition: width .3s; }
.wiz-bar small { color: var(--muted); font-weight: 600; white-space: nowrap; }
.wiz-nav { display: flex; justify-content: space-between; gap: 10px; margin: 14px 0 10px; }
.wiz-nav[hidden] { display: none; }
.wiz-nav #wizNext { flex: 1; max-width: 260px; margin-inline-start: auto; }
.spot-form > section.card[hidden], .form-actions[hidden] { display: none; }
@media (max-width: 520px) { .price-suggest { flex-direction: column; align-items: stretch; } .price-suggest .btn { width: 100%; } }
/* "why can't I book": the spot's hours and the next free time */
.hours-line { margin: -2px 0 12px; font-size: .9rem; line-height: 1.5; }
.suggest-next { display: flex; align-items: center; justify-content: space-between; gap: 8px; flex-wrap: wrap; margin-top: 8px;
  padding-top: 8px; border-top: 1px solid rgba(0,0,0,.08); color: var(--ink); font-weight: 600; }
.next-free { margin-top: 4px; font-weight: 700; color: var(--brand-dark); }
[data-theme="dark"] .next-free { color: var(--brand); }
.hours-line strong { display: block; }
/* date/time picker: lower chips, greyed-out times, start and end look different */
.dtp-chip { padding: 5px 8px; border-radius: 12px; min-width: 56px; }
.dtp-chip b { font-size: .92rem; }
.dtp-chip small { font-size: .7rem; }
.dtp-times .dtp-chip { min-width: 56px; }
.dtp-chip.off { opacity: .38; background: repeating-linear-gradient(135deg, transparent 0 5px, rgba(0,0,0,.05) 5px 7px); cursor: not-allowed; }
.dtp-chip.off b { text-decoration: line-through; text-decoration-thickness: 1px; }
.book-times { display: grid; gap: 10px; }
.book-times .when-from, .book-times .when-to { border-radius: 14px; padding: 8px 10px 4px; margin: 0; }
.book-times .when-from { background: color-mix(in srgb, var(--brand) 8%, transparent); border-inline-start: 4px solid var(--brand); }
.book-times .when-to { background: color-mix(in srgb, #f08c00 9%, transparent); border-inline-start: 4px solid #f08c00; }
.when-tag { font-weight: 800; font-size: .88rem; }
.when-from .when-tag { color: var(--brand-dark); }
.when-to .when-tag { color: #c26d00; }
[data-theme="dark"] .when-from .when-tag { color: var(--brand); } [data-theme="dark"] .when-to .when-tag { color: #ffb347; }
.when-to .dtp-chip.on { background: #f08c00; border-color: #f08c00; }
.quick-row { display: flex; gap: 6px; overflow-x: auto; padding: 2px 2px 6px; scrollbar-width: thin; -webkit-overflow-scrolling: touch; }
.quick-row .chip-btn { flex: none; padding: 6px 12px; min-height: 0; font-size: .85rem; }
/* booking page: tighter */
.times .arrow { display: flex; flex-direction: column; align-items: center; line-height: 1; }
.times .arrow small { font-size: .72rem; color: var(--brand-dark); font-weight: 700; margin-top: 4px; }
[dir="rtl"] .times .arrow small { transform: scaleX(-1); }
.nav-buttons { flex-wrap: nowrap; gap: 6px; }
.nav-buttons .btn { flex: 1 1 0; min-width: 0; padding-inline: 6px; font-size: .88rem; min-height: 42px; }
.bk-map { height: 170px; }
.booking .address { font-weight: 700; font-size: 1.05rem; margin: 0 0 10px; }
.ext-wrap > summary { list-style: none; cursor: pointer; display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; }
.ext-wrap > summary::-webkit-details-marker { display: none; }
.ext-wrap > summary h2 { margin: 0; }
.ext-wrap > summary h2::after { content: " ▾"; font-size: .8em; color: var(--muted); }
.ext-wrap:not([open]) > summary h2::after { content: " ◂"; }
.ext-wrap[open] > summary { margin-bottom: 8px; }
/* booking: extension + actions explained */
.ext-explain { margin: 0 0 10px; font-size: .95rem; }
.ext-chips { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; margin-bottom: 8px; }
.ext-chips .chip-btn { display: grid; gap: 1px; padding: 6px 4px; border-radius: 12px; min-height: 0; text-align: center; }
.ext-chips .chip-btn b { font-size: .9rem; }
.ext-chips .chip-btn small { font-size: .72rem; color: var(--muted); direction: rtl; }
.ext-chips .chip-btn.off { opacity: .35; cursor: not-allowed; }
.ext-other { margin: 4px 0 8px; }
.ext-other > summary { cursor: pointer; color: var(--brand-dark); font-weight: 600; font-size: .9rem; list-style: none; }
.ext-other > summary::-webkit-details-marker { display: none; }
.act-list { flex-direction: column; align-items: stretch; gap: 10px; }
.act-item { display: flex; align-items: center; gap: 10px; }
.act-item .btn { flex: none; }
.act-item small { line-height: 1.35; }
/* bookings list: grouped */
.list-title { font-size: 1.05rem; margin: 18px auto 8px; }
.list-title .muted { font-weight: 500; font-size: .9rem; }
.br-time { font-size: .92rem; color: var(--ink); margin-top: 3px; }
.past-list .booking-row { opacity: .8; }
.past-list .booking-row .br-time { color: var(--muted); }
/* bookings list: each section has its own colour */
.list-title { display: flex; align-items: center; gap: 8px; }
.list-title::before { content: ""; width: 6px; height: 22px; border-radius: 3px; background: var(--gc, var(--muted)); }
.lt-now { --gc: #2f9e44; color: #2b8a3e; } .lt-upcoming { --gc: #1c7ed6; color: #1864ab; } .lt-past { --gc: #adb5bd; color: var(--muted); }
[data-theme="dark"] .lt-now { color: #69db7c; } [data-theme="dark"] .lt-upcoming { color: #74c0fc; }
.grp .booking-row { border-inline-start: 5px solid var(--gc, transparent); }
.grp-now { --gc: #2f9e44; } .grp-now .booking-row { background: color-mix(in srgb, #2f9e44 7%, var(--card)); }
.grp-upcoming { --gc: #1c7ed6; } .grp-upcoming .booking-row { background: color-mix(in srgb, #1c7ed6 5%, var(--card)); }
.grp-past { --gc: #ced4da; } .grp-past .booking-row { background: var(--bg); box-shadow: none; border: 1px solid var(--line); border-inline-start: 5px solid #ced4da; }
.fav-section .fav-title { display: flex; align-items: center; gap: 8px; color: #c2255c; }
[data-theme="dark"] .fav-section .fav-title { color: #f783ac; }
.fav-section .fav-card { border-inline-start: 5px solid #e64980; background: color-mix(in srgb, #e64980 4%, var(--card)); }
/* quick actions under a booking in the list */
.has-qa .booking-row { border-end-start-radius: 0; border-end-end-radius: 0; margin-bottom: 0; }
.br-actions { display: flex; gap: 6px; flex-wrap: wrap; padding: 8px 12px 10px; background: var(--card); border-top: 1px dashed var(--line);
  border-end-start-radius: var(--radius); border-end-end-radius: var(--radius); box-shadow: var(--shadow); margin-bottom: 12px;
  border-inline-start: 5px solid var(--gc, transparent); }
.grp-now .br-actions { background: color-mix(in srgb, #2f9e44 7%, var(--card)); }
.grp-upcoming .br-actions { background: color-mix(in srgb, #1c7ed6 5%, var(--card)); }
.br-actions form { margin: 0; display: contents; }
.qa { font: inherit; font-size: .85rem; font-weight: 700; padding: 6px 12px; border-radius: 999px; border: 1px solid var(--line);
  background: var(--card); color: var(--ink); text-decoration: none; cursor: pointer; display: inline-flex; align-items: center; gap: 4px; }
.qa-main { background: var(--brand); border-color: var(--brand); color: #fff; }
.qa-danger { color: #c92a2a; border-color: #ffc9c9; margin-inline-start: auto; }
.has-qa > .fav-btn { bottom: 62px; }
/* status badges: booked (waiting) blue, parked now green with a live dot, late red */
.badge.status-confirmed { background: #e7f1fc; color: #1864ab; border: 1px solid #c5ddf7; }
.badge.status-active { background: #2f9e44; color: #fff; display: inline-flex; align-items: center; gap: 5px; }
.badge.status-active::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: #fff; animation: pk-live 1.4s ease-in-out infinite; }
.badge.status-overstay { background: #e03131; color: #fff; }
@keyframes pk-live { 50% { opacity: .25; } }
[data-theme="dark"] .badge.status-confirmed { background: #15314d; color: #a5d8ff; border-color: #1f4670; }
.qa-off { opacity: .45; cursor: not-allowed; font-weight: 600; }
/* save buttons: quiet with nothing to save, bright when there are changes */
.btn.save-idle { background: var(--bg) !important; color: var(--muted) !important; border: 1px dashed var(--line) !important; box-shadow: none !important; cursor: default; }
.btn.save-dirty { background: #f08c00 !important; border-color: #f08c00 !important; color: #fff !important; animation: pk-save 1.6s ease-in-out infinite; }
@keyframes pk-save { 0%, 100% { box-shadow: 0 0 0 0 rgba(240,140,0,.45); } 50% { box-shadow: 0 0 0 7px rgba(240,140,0,0); } }
.spot-form.is-dirty .form-actions { position: sticky; bottom: calc(var(--tabbar-h, 64px) + 8px); z-index: 20; background: var(--card);
  padding: 10px; border-radius: 16px; box-shadow: 0 -4px 18px rgba(0,0,0,.12); }
@media (min-width: 960px) { .spot-form.is-dirty .form-actions { bottom: 12px; } }
/* history: rate / rated */
.grp-past .br-actions { background: var(--bg); box-shadow: none; border: 1px solid var(--line); border-top: 1px dashed var(--line); border-inline-start: 5px solid #ced4da; align-items: center; }
.qa-rate { background: #fff4d6; border-color: #ffd866; color: #8a5a00; }
[data-theme="dark"] .qa-rate { background: #3a3218; color: #ffd866; border-color: #5c4d1c; }
.rated { font-size: .85rem; color: var(--muted); font-weight: 600; }
.rated span { color: #ced4da; font-size: 1rem; } .rated span.on { color: #f59f00; }
/* small maps (booking, spot form): a slim credits line in the corner */
.bk-map .leaflet-control-attribution, .pick-map .leaflet-control-attribution { font-size: 9px; line-height: 1.3; padding: 0 4px; background: rgba(255,255,255,.7); max-width: 85%; direction: ltr; }
/* bookings list: the heart sits before the spot name (it used to cover the time line) */
.row-wrap > .fav-btn, .has-qa > .fav-btn { top: 14px; bottom: auto; inset-inline-start: 12px; }
.row-wrap .booking-row .br-main { padding-inline-start: 34px; }
.row-wrap .booking-row .br-main .br-time { margin-inline-start: -34px; }
/* floating save bar (any tracked form whose button is scrolled away) */
.save-bar { position: fixed; z-index: 1040; inset-inline: 12px; bottom: calc(var(--tabbar-h, 64px) + env(safe-area-inset-bottom) + 10px);
  max-width: 520px; margin-inline: auto; display: flex; align-items: center; justify-content: space-between; gap: 10px;
  background: var(--card); border-radius: 16px; padding: 10px 12px; box-shadow: 0 6px 24px rgba(0,0,0,.18); border: 1px solid #ffd8a8;
  animation: pk-rise .25s ease-out; }
@keyframes pk-rise { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: none; } }
.save-bar[hidden] { display: none; }
.save-bar span { font-weight: 700; font-size: .9rem; color: #c26d00; }
.save-bar .btn { flex: none; min-height: 42px; padding: 8px 16px; }
@media (min-width: 960px) { .save-bar { bottom: 16px; } }
/* "how do you get in": one clear row per option - icon, name, short explanation, a radio circle */
.gate-opts { display: grid; gap: 6px; }
.gate-opt { position: relative; display: flex; align-items: center; gap: 10px; padding: 8px 12px; border: 1.5px solid var(--line);
  border-radius: 12px; background: var(--card); cursor: pointer; transition: border-color .15s, background .15s; }
.gate-opt input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.go-ic { font-size: 1.3rem; width: 32px; height: 32px; display: grid; place-items: center; border-radius: 10px; background: var(--bg); flex: none; }
.go-txt { flex: 1; min-width: 0; display: flex; flex-direction: column; line-height: 1.3; }
.go-txt strong { font-size: .95rem; }
.go-txt small { color: var(--muted); font-size: .8rem; }
.go-check { width: 20px; height: 20px; border-radius: 50%; border: 2px solid var(--line); flex: none; }
.gate-opt:has(input:checked) { border-color: var(--brand); background: var(--brand-soft); }
.gate-opt:has(input:checked) .go-ic { background: var(--card); }
.gate-opt:has(input:checked) .go-check { border-color: var(--brand); background: radial-gradient(circle, var(--brand) 45%, transparent 50%); }
.gate-opt:has(input:focus-visible) { outline: 3px solid rgba(11,110,105,.3); }
/* gate opened by the owner */
.gate-card .gate-line { margin: 0 0 8px; font-weight: 700; }
.gate-line.ok { color: var(--ok, #2b8a3e); }
.gate-line.wait { color: #c26d00; }
.gate-card form + p, .gate-card p.center { margin-top: 6px; }
/* map pins float gently, like the balloons on the sign-in page (each at its own pace) */
@keyframes pk-bob { 0%, 100% { transform: translate(-50%, -100%); } 50% { transform: translate(-50%, calc(-100% - 5px)); } }
@media (prefers-reduced-motion: no-preference) {
  #map .leaflet-marker-icon .pin { animation: pk-drop .45s ease-out backwards, pk-bob var(--bob, 3.4s) ease-in-out .5s infinite; animation-delay: 0s, var(--bob-d, 0s); }
  #map .leaflet-marker-icon .pin:hover, #map .leaflet-marker-icon.hl .pin { animation-play-state: paused; }
}
/* spot card: the book / edit button is always visible at the bottom */
.sheet-actions { position: sticky; bottom: 0; z-index: 3; background: var(--card); padding: 10px 18px calc(12px + env(safe-area-inset-bottom));
  box-shadow: 0 -6px 14px rgba(0,0,0,.08); }
.sheet-actions.mine { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.sheet-actions.mine span { font-weight: 700; color: var(--brand-dark); }
[data-theme="dark"] .sheet-actions.mine span { color: var(--brand); }
.sheet-actions.mine .btn { flex: none; min-width: 120px; }
.sheet .sheet-body { padding-bottom: 8px; }
@media (max-width: 959px) { .sheet-photos img { height: 130px; } }
.why-busy { font-size: .85rem; margin-top: 3px; color: var(--ink); }
.why-busy a { font-weight: 700; }
.occ-link { font-weight: 700; text-decoration: none; }
.occ-range { color: var(--ink); margin-top: 2px; flex-basis: 100%; }
/* my spots: a spot someone is parked in right now stands out */
.spot-card.is-occupied { border-inline-start: 5px solid #e03131; background: color-mix(in srgb, #e03131 4%, var(--card)); }
.occ-pill { background: #e03131; color: #fff; font-weight: 700; font-size: .78rem; padding: 2px 10px; border-radius: 999px; white-space: nowrap; }
.occ-box { display: flex; flex-direction: column; gap: 2px; margin: 8px 0 4px; padding: 8px 12px; border-radius: 12px; text-decoration: none;
  background: #fff0f0; border: 1px solid #ffc9c9; color: var(--ink); }
.occ-box strong { color: #c92a2a; font-size: .95rem; }
.occ-box span { font-size: .85rem; }
.occ-box .occ-more { color: #c92a2a; font-weight: 700; font-size: .8rem; }
[data-theme="dark"] .occ-box { background: #3d1c19; border-color: #6b2b27; }
[data-theme="dark"] .occ-box strong, [data-theme="dark"] .occ-box .occ-more { color: #ffa8a8; }
.occ-free { margin: 4px 0 6px; }
/* our own confirm box */
.pk-confirm { position: fixed; inset: 0; z-index: 3000; background: rgba(10, 20, 18, .45); display: grid; place-items: center; padding: 16px;
  animation: pkc-fade .15s ease-out; }
.pk-confirm[hidden] { display: none; }
.pkc-card { width: 100%; max-width: 380px; background: var(--card); border-radius: 20px; padding: 22px 20px 18px; text-align: center;
  box-shadow: 0 20px 50px rgba(0,0,0,.25); animation: pkc-pop .18s ease-out; }
.pkc-ic { font-size: 2rem; line-height: 1; margin-bottom: 8px; }
.pkc-text { margin: 0 0 18px; font-size: 1.02rem; line-height: 1.5; font-weight: 600; color: var(--ink); white-space: pre-line; }
.pkc-btns { display: flex; flex-direction: column; gap: 8px; }
.pkc-btns .btn { width: 100%; min-height: 46px; }
.pkc-ok.danger-solid { background: #e03131; border-color: #e03131; color: #fff; }
@keyframes pkc-fade { from { opacity: 0; } }
@keyframes pkc-pop { from { transform: scale(.94); opacity: 0; } }
body.pkc-open { overflow: hidden; }
input.field-error { border-color: #e03131 !important; box-shadow: 0 0 0 3px rgba(224,49,49,.15); }
.err-text { color: #c92a2a; font-weight: 700; margin-top: 4px; display: block; }
/* keyboard open: no tab bar, the sticky save bar / floating save bar go right above the keyboard */
body.kb-open .tabbar { display: none; }
body.kb-open .spot-form.is-dirty .form-actions { bottom: 6px; }
body.kb-open .save-bar { bottom: 8px; }
body.kb-open .fab { display: none; }
/* errors stand out: red card with an icon; the field's own hint is a red box */
.flash.flash-error { background: #fff0f0; color: #a51d1d; font-weight: 700; border: 1px solid #ffc9c9; border-inline-start: 6px solid #e03131; }
.flash.flash-error::before { content: "⚠️ "; }
[data-theme="dark"] .flash.flash-error { background: #3d1c19; color: #ffc9c9; border-color: #6b2b27; }
.err-text { background: #fff0f0; border: 1px solid #ffc9c9; border-radius: 10px; padding: 6px 10px; animation: pk-shake .4s ease-in-out 2; }
[data-theme="dark"] .err-text { background: #3d1c19; border-color: #6b2b27; color: #ffc9c9; }
@keyframes pk-shake { 25% { transform: translateX(-4px); } 75% { transform: translateX(4px); } }
/* keyboard open on browsers that don't shrink the page: lift the sticky save bar by the keyboard height */
body.kb-open .spot-form.is-dirty .form-actions { bottom: calc(var(--kb, 0px) + 6px); }
body.kb-open .save-bar { bottom: calc(var(--kb, 0px) + 8px); }
