/* ==========================================================
   Tankpreisjäger · Swiss-Editorial Design System
   ========================================================== */

/* ----- Design Tokens ----- */
:root {
  /* Ink / Typo */
  --ink:    #0a0d14;
  --ink-2:  #2a2f38;
  --ink-3:  #5b6472;
  --ink-4:  #8b93a1;

  /* Surfaces */
  --bg:     #ffffff;
  --bg-2:   #f7f8fa;
  --bg-3:   #eef0f3;

  /* Lines */
  --line:   #e4e6ea;
  --line-2: #f0f1f4;

  /* Accents */
  --accent:       #0d4a80;
  --accent-soft:  #e1ebf4;
  --fuel:         #b61a1a;
  --fuel-soft:    #fbebeb;
  --charge:       #1f6b3a;
  --charge-soft:  #e3efe6;
  --beta:         #c2410c;
  --beta-soft:    #fdf0e3;

  /* Radii */
  --r-xs: 3px;
  --r-sm: 5px;
  --r:    8px;
  --r-lg: 12px;

  /* Shadows */
  --sh-sm: 0 1px 2px rgba(10,13,20,.05);
  --sh:    0 4px 16px rgba(10,13,20,.08);
  --sh-lg: 0 8px 32px rgba(10,13,20,.14);

  /* Spacing */
  --s-1: 4px;
  --s-2: 8px;
  --s-3: 12px;
  --s-4: 16px;
  --s-5: 24px;
  --s-6: 32px;
  --s-7: 48px;

  /* Type */
  --font-sans: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --font-num:  'Inter', ui-monospace, SFMono-Regular, Menlo, monospace;

  --topbar-h: 64px;
}

[data-theme="dark"] {
  --ink:    #e8eaef;
  --ink-2:  #b9bfcb;
  --ink-3:  #8b93a1;
  --ink-4:  #5b6472;
  --bg:     #0c0e12;
  --bg-2:   #14181e;
  --bg-3:   #1b2028;
  --line:   #2a2f38;
  --line-2: #1e232b;
  --accent:       #6fa4d8;
  --accent-soft:  #1b2f44;
  --fuel:         #e35a5a;
  --fuel-soft:    #2f1818;
  --charge:       #4fa868;
  --charge-soft:  #1a2e22;
  --beta:         #f59e4c;
  --beta-soft:    #2a1c10;
  --sh-sm: 0 1px 2px rgba(0,0,0,.4);
  --sh:    0 4px 16px rgba(0,0,0,.5);
  --sh-lg: 0 8px 32px rgba(0,0,0,.6);
}

/* ----- Reset / Base ----- */
*, *::before, *::after { box-sizing: border-box; }

html, body {
  margin: 0; padding: 0;
  font-family: var(--font-sans);
  font-size: 15px;
  line-height: 1.55;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

h1, h2, h3, h4 {
  margin: 0;
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.25;
}

a {
  color: var(--accent);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: border-color .15s;
}
a:hover { border-bottom-color: var(--accent); }

button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  background: none;
  color: inherit;
}

svg { display: block; }

input, select, textarea {
  font-family: inherit;
  font-size: inherit;
  color: var(--ink);
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: var(--r-sm);
  padding: 8px 10px;
  transition: border-color .12s, box-shadow .12s;
}
input:focus, select:focus, textarea:focus {
  outline: none;
  border-color: var(--ink-2);
  box-shadow: 0 0 0 3px var(--bg-3);
}

/* ----- Utility: Icons ----- */
.ico {
  width: 18px; height: 18px;
  stroke: currentColor;
  stroke-width: 1.75;
  stroke-linecap: round;
  stroke-linejoin: round;
  fill: none;
  flex-shrink: 0;
}
.ico-sm { width: 14px; height: 14px; }
.ico-lg { width: 22px; height: 22px; }

/* ----- Topbar ----- */
.topbar {
  display: flex; align-items: center; justify-content: space-between;
  height: var(--topbar-h);
  padding: 0 var(--s-5);
  background: var(--bg);
  border-bottom: 1px solid var(--line);
  position: sticky; top: 0; z-index: 1000;
}

.brand {
  display: flex; align-items: center; gap: var(--s-3);
  color: var(--ink);
  border: 0;
}
.brand:hover { border: 0; }
.brand .mark {
  width: 32px; height: 32px;
  color: var(--ink);
  display: flex; align-items: center; justify-content: center;
}
.brand .mark svg { width: 28px; height: 28px; }
.brand .word {
  font-size: 18px; font-weight: 700; letter-spacing: -0.03em;
  color: var(--ink);
}
.brand .word .accent { color: var(--fuel); }

.beta-tag {
  display: inline-block;
  margin-left: var(--s-2);
  padding: 2px 6px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--beta);
  background: var(--beta-soft);
  border: 1px solid var(--beta);
  border-radius: var(--r-xs);
  text-transform: uppercase;
  vertical-align: middle;
  line-height: 1.3;
}

.top-nav {
  display: flex; align-items: center; gap: var(--s-5);
}
.top-nav a {
  color: var(--ink-2); font-weight: 500; font-size: 14px;
  border-bottom: none;
  padding: 4px 0;
  position: relative;
}
.top-nav a:hover { color: var(--ink); border-bottom: none; }
.top-nav a[aria-current="page"]::after {
  content: ''; position: absolute;
  left: 0; right: 0; bottom: -2px;
  height: 2px; background: var(--ink);
}

.top-actions { display: flex; gap: var(--s-2); align-items: center; }

.icon-btn {
  width: 36px; height: 36px;
  display: flex; align-items: center; justify-content: center;
  border-radius: var(--r-sm);
  color: var(--ink-2);
  transition: background .12s, color .12s;
}
.icon-btn:hover { background: var(--bg-2); color: var(--ink); }
.icon-btn.with-label {
  width: auto; gap: var(--s-2); padding: 0 12px;
  font-size: 13px; font-weight: 500;
}

/* ----- Price Banner (reduziert, editorial) ----- */
.price-banner {
  background: var(--bg-2);
  border-bottom: 1px solid var(--line);
  padding: var(--s-5) var(--s-5);
}
.price-banner-inner { max-width: 1400px; margin: 0 auto; }
.banner-head {
  display: flex; justify-content: space-between; align-items: baseline;
  gap: var(--s-4); flex-wrap: wrap;
  margin-bottom: var(--s-3);
}
.banner-head strong {
  font-size: 11px; font-weight: 600;
  text-transform: uppercase; letter-spacing: 0.12em;
  color: var(--ink-3);
}
.banner-stand { font-size: 12px; color: var(--ink-3); }

.price-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: var(--s-3);
  margin-bottom: var(--s-3);
}
.price-pill {
  display: flex; flex-direction: column;
  padding: var(--s-3) var(--s-4);
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: var(--r);
  font-size: 13px;
}
.price-pill .label {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--ink-3);
  margin-bottom: 2px;
}
.price-pill .val {
  font-weight: 700;
  font-size: 18px;
  letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
  color: var(--ink);
}
.price-pill .unit {
  font-weight: 500; font-size: 13px;
  color: var(--ink-3);
}
.price-banner small {
  font-size: 12px; color: var(--ink-3);
  display: block;
}

/* ----- Layout ----- */
.layout {
  display: grid;
  grid-template-columns: 320px 1fr;
  height: calc(100vh - var(--topbar-h) - 60px);
  min-height: 520px;
}
.price-banner + .layout { height: auto; min-height: calc(100vh - var(--topbar-h) - 60px); }
.layout .sidebar + .map-wrapper { min-height: 520px; }

.sidebar {
  background: var(--bg);
  border-right: 1px solid var(--line);
  overflow-y: auto;
  display: flex; flex-direction: column;
}

/* Sidebar-Tabs */
.sidebar-tabs {
  display: flex;
  border-bottom: 1px solid var(--line);
  position: sticky; top: 0; z-index: 5;
  background: var(--bg);
}
.sidebar-tabs .tab {
  flex: 1; padding: var(--s-3) var(--s-2);
  font-size: 13px; font-weight: 500;
  color: var(--ink-3);
  border-bottom: 2px solid transparent;
  display: inline-flex; align-items: center; justify-content: center;
  gap: var(--s-1);
  transition: color .12s, border-color .12s;
}
.sidebar-tabs .tab:hover { color: var(--ink-2); }
.sidebar-tabs .tab.active {
  color: var(--ink);
  border-bottom-color: var(--ink);
}

.fav-count {
  display: inline-block;
  min-width: 18px; padding: 0 5px;
  font-size: 10px; font-weight: 700;
  background: var(--ink);
  color: var(--bg);
  border-radius: 999px;
  text-align: center;
  line-height: 16px;
}

.tab-panel { padding: var(--s-5) var(--s-4); }

.filter-block { margin-bottom: var(--s-5); }
.filter-block label,
.section-label {
  display: block;
  font-size: 11px; font-weight: 600;
  text-transform: uppercase; letter-spacing: 0.08em;
  color: var(--ink-3);
  margin-bottom: var(--s-2);
}
.filter-block input,
.filter-block select,
.filter-block textarea {
  width: 100%; font-size: 14px;
}

.filter-block.stats {
  font-size: 13px; color: var(--ink-3);
  padding: var(--s-3);
  background: var(--bg-2);
  border-radius: var(--r-sm);
  border: 1px solid var(--line);
}
.filter-block.stats span { color: var(--ink); font-weight: 600; font-variant-numeric: tabular-nums; }
.filter-block.info { font-size: 12px; color: var(--ink-3); }
.filter-block.info p { margin: 0 0 var(--s-1); }

/* Primary button */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  gap: var(--s-2);
  padding: 10px var(--s-4);
  font-size: 14px; font-weight: 600;
  background: var(--ink); color: var(--bg);
  border-radius: var(--r-sm);
  border: 1px solid var(--ink);
  transition: background .12s, border-color .12s, transform .08s;
}
.btn:hover { background: var(--ink-2); border-color: var(--ink-2); }
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: .5; cursor: default; }

.btn-secondary {
  background: var(--bg); color: var(--ink);
  border: 1px solid var(--line);
}
.btn-secondary:hover { background: var(--bg-2); border-color: var(--ink-3); }

.btn-fuel   { background: var(--fuel);   border-color: var(--fuel);   color: #fff; }
.btn-charge { background: var(--charge); border-color: var(--charge); color: #fff; }
.btn-full   { width: 100%; }

/* Legacy-Alias: big-btn wird jetzt als .btn gerendert */
.big-btn {
  display: inline-flex; align-items: center; justify-content: center;
  gap: var(--s-2); width: 100%;
  padding: 10px var(--s-4);
  font-size: 14px; font-weight: 600;
  background: var(--ink); color: var(--bg);
  border-radius: var(--r-sm);
  border: 1px solid var(--ink);
}
.big-btn:hover { background: var(--ink-2); border-color: var(--ink-2); }

/* Nearby / Favoriten-Listenitems */
.nearby-item, .fav-item {
  display: flex; width: 100%;
  align-items: center; gap: var(--s-3);
  padding: var(--s-3);
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: var(--r-sm);
  margin-bottom: var(--s-2);
  text-align: left;
  color: var(--ink);
  font-size: 13px;
  transition: border-color .12s, background .12s;
}
.nearby-item:hover, .fav-item:hover {
  background: var(--bg-2); border-color: var(--ink-3);
}
.nearby-icon, .fav-icon {
  width: 28px; height: 28px;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
  color: var(--ink-3);
}
.nearby-icon .ico, .fav-icon .ico { width: 18px; height: 18px; }
.nearby-main, .fav-main { flex: 1; display: flex; flex-direction: column; min-width: 0; }
.nearby-title, .fav-title {
  font-weight: 600; color: var(--ink);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.nearby-addr, .fav-addr {
  font-size: 11px; color: var(--ink-3);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.nearby-dist {
  font-weight: 700;
  color: var(--ink);
  font-size: 12px;
  font-variant-numeric: tabular-nums;
  flex-shrink: 0;
}
.fav-remove { color: var(--ink-3); padding: 0 var(--s-2); flex-shrink: 0; font-size: 14px; }
.fav-remove:hover { color: var(--fuel); }

.empty-hint {
  color: var(--ink-3); font-size: 13px;
  padding: var(--s-4);
  text-align: center;
}

/* Rechner */
.calc { display: flex; flex-direction: column; gap: var(--s-3); }
.calc-switch {
  display: flex; gap: 0;
  padding: 3px;
  background: var(--bg-2);
  border: 1px solid var(--line);
  border-radius: var(--r-sm);
}
.calc-mode {
  flex: 1; padding: var(--s-2);
  border-radius: var(--r-xs);
  font-weight: 500; font-size: 13px;
  color: var(--ink-3);
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
}
.calc-mode.active {
  background: var(--bg);
  color: var(--ink);
  box-shadow: var(--sh-sm);
}
.calc-form { display: flex; flex-direction: column; gap: var(--s-3); }
.calc-form label {
  display: block;
  font-size: 11px; font-weight: 600;
  color: var(--ink-3);
  text-transform: uppercase; letter-spacing: 0.08em;
}
.calc-form input {
  width: 100%; margin-top: 4px;
  font-size: 14px; font-variant-numeric: tabular-nums;
}
.calc-result {
  background: var(--bg-2);
  border: 1px solid var(--line);
  padding: var(--s-4);
  border-radius: var(--r-sm);
  font-size: 13px; color: var(--ink-3);
  text-align: center;
}
.calc-result strong {
  display: block;
  font-size: 22px; font-weight: 700;
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.02em;
  color: var(--ink);
  margin: 2px 0;
}
.calc-sub { font-size: 12px; color: var(--ink-3); }

/* ----- Map ----- */
.map-wrapper { position: relative; }
#map { width: 100%; height: 100%; min-height: 520px; background: var(--bg-3); }
.map-loading {
  position: absolute; top: var(--s-4); left: 50%; transform: translateX(-50%);
  background: var(--bg);
  padding: var(--s-2) var(--s-4);
  border-radius: var(--r-sm);
  border: 1px solid var(--line);
  box-shadow: var(--sh);
  font-size: 13px; color: var(--ink-2);
  z-index: 500;
}
.map-loading.hidden, .map-loading[hidden] { display: none; }

/* Marker */
.marker-dot {
  width: 26px; height: 26px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 11px; font-weight: 700; color: #fff;
  box-shadow: 0 2px 4px rgba(0,0,0,.25);
  border: 2px solid #fff;
  letter-spacing: -.02em;
}
.marker-charging {
  background: var(--charge);
  font-size: 13px;
}
[data-theme="dark"] .marker-dot { border-color: var(--bg-2); }
.marker-user {
  width: 30px; height: 30px;
  display: flex; align-items: center; justify-content: center;
  color: var(--accent);
  filter: drop-shadow(0 2px 4px rgba(0,0,0,.4));
}
.marker-user svg { width: 24px; height: 24px; fill: currentColor; }

/* Cluster */
.cluster-wrap { background: transparent; border: none; }
.cluster-inner {
  display: flex; align-items: center; justify-content: center;
  border-radius: 50%;
  color: #fff; font-weight: 700; font-size: 13px;
  box-shadow: 0 2px 6px rgba(0,0,0,.3);
  border: 3px solid #fff;
  font-variant-numeric: tabular-nums;
}
[data-theme="dark"] .cluster-inner { border-color: var(--bg-2); }
.cluster-fuel    { background: var(--fuel); }
.cluster-charging{ background: var(--charge); }
.cluster-small   { width: 34px; height: 34px; font-size: 12px; }
.cluster-medium  { width: 40px; height: 40px; font-size: 13px; }
.cluster-large   { width: 50px; height: 50px; font-size: 14px; }

/* ----- Popup ----- */
.leaflet-popup-content-wrapper {
  border-radius: var(--r);
  background: var(--bg);
  color: var(--ink);
  box-shadow: var(--sh-lg);
}
.leaflet-popup-tip { background: var(--bg); }
[data-theme="dark"] .leaflet-popup-content-wrapper,
[data-theme="dark"] .leaflet-popup-tip { background: var(--bg-2); }
.leaflet-popup-content { margin: 14px 16px; font-family: var(--font-sans); }

.station-popup { min-width: 240px; font-size: 13px; position: relative; }
.fav-toggle {
  position: absolute; top: -6px; right: -6px;
  font-size: 18px; color: #d6a30a; line-height: 1;
  padding: 4px 6px; transition: transform .12s;
}
.fav-toggle:hover { transform: scale(1.12); }
.station-popup h3 {
  margin: 0 0 4px;
  font-size: 15px; font-weight: 700;
  color: var(--ink); padding-right: 24px;
}
.station-popup .brand-tag {
  display: inline-block;
  background: var(--fuel-soft); color: var(--fuel);
  padding: 1px 8px; border-radius: 999px;
  font-size: 11px; font-weight: 600;
  margin-bottom: 6px;
  letter-spacing: 0.01em;
}
.station-popup .brand-charging { background: var(--charge-soft); color: var(--charge); }
.station-popup .addr {
  color: var(--ink-3); margin: 4px 0;
  font-size: 12px;
}
.station-popup .fuels { margin: 8px 0 4px; display: flex; flex-wrap: wrap; gap: 4px; }
.station-popup .fuel-chip {
  background: var(--bg-2);
  border: 1px solid var(--line);
  color: var(--ink-2);
  font-size: 11px;
  padding: 2px 8px; border-radius: var(--r-xs);
  font-weight: 500;
}
.station-popup .socket-chip {
  background: var(--charge-soft);
  border-color: var(--charge);
  color: var(--charge);
}
.station-popup .hours {
  margin-top: 6px; font-size: 12px; color: var(--ink-3);
}
.station-popup a.route-link {
  display: inline-flex; align-items: center; gap: 4px;
  margin-top: 10px;
  font-size: 13px; font-weight: 500;
  color: var(--accent);
  border: 0;
}

/* Tarif */
.tariff {
  margin-top: 10px;
  padding: 10px 12px;
  background: var(--charge-soft);
  border: 1px solid var(--charge);
  border-radius: var(--r-sm);
}
.tariff-title {
  font-size: 11px; font-weight: 600;
  color: var(--charge);
  text-transform: uppercase; letter-spacing: 0.06em;
  margin-bottom: 4px;
}
.tariff-row { display: flex; gap: 6px; align-items: center; font-size: 13px; flex-wrap: wrap; }
.tariff-type {
  font-size: 10px; font-weight: 700;
  background: var(--charge); color: #fff;
  padding: 2px 6px; border-radius: 3px;
  letter-spacing: 0.04em;
}
.tariff-val { font-weight: 600; font-variant-numeric: tabular-nums; }
.tariff-hint { margin-top: 6px; font-size: 11px; color: var(--ink-3); line-height: 1.4; }
.tariff-meta { margin-top: 4px; font-size: 10px; color: var(--ink-3); letter-spacing: 0.02em; }

/* ----- Community ----- */
.community {
  margin-top: 10px;
  padding: 10px;
  background: var(--accent-soft);
  border: 1px solid var(--accent);
  border-radius: var(--r-sm);
}
[data-theme="dark"] .community { border-color: var(--accent); }
.comm-title {
  font-size: 11px; font-weight: 600;
  color: var(--accent);
  text-transform: uppercase; letter-spacing: 0.06em;
  margin-bottom: 6px;
}
.comm-row {
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: var(--r-sm);
  padding: 8px 10px;
  margin-bottom: 6px;
}
.comm-row:last-child { margin-bottom: 0; }
.comm-head { display: flex; justify-content: space-between; gap: 6px; font-size: 13px; }
.comm-fuel { font-weight: 600; color: var(--ink); }
.comm-price {
  font-weight: 700; color: var(--fuel);
  font-variant-numeric: tabular-nums;
}
.comm-meta { font-size: 11px; color: var(--ink-3); margin: 2px 0; }
.comm-actions { display: flex; gap: 4px; margin-top: 4px; flex-wrap: wrap; }
.vote-btn, .trend-btn, .report-cta {
  background: var(--bg);
  border: 1px solid var(--line);
  color: var(--ink-2);
  padding: 4px 10px;
  border-radius: var(--r-xs);
  font-size: 11px;
  font-weight: 500;
  transition: all .12s;
}
.vote-btn:hover, .trend-btn:hover, .report-cta:hover {
  background: var(--bg-2);
  border-color: var(--ink-3);
  color: var(--ink);
}
.report-cta {
  display: block; width: 100%;
  text-align: center;
  margin-top: 10px;
  padding: 8px;
  background: var(--bg-2);
  font-weight: 600;
  font-size: 13px;
}

.report-form {
  margin-top: 10px;
  background: var(--bg-2);
  border: 1px solid var(--line);
  border-radius: var(--r-sm);
  padding: 10px;
}
.report-form > summary {
  font-size: 13px; font-weight: 600;
  cursor: pointer;
  color: var(--ink-2);
  list-style: none;
  outline: none;
}
.report-form > summary::-webkit-details-marker { display: none; }
.report-form[open] > summary { margin-bottom: 8px; }
.rform { display: flex; flex-direction: column; gap: 8px; }
.rform label {
  font-size: 11px; font-weight: 600;
  color: var(--ink-3);
  text-transform: uppercase; letter-spacing: 0.06em;
}
.rform input, .rform select {
  width: 100%; margin-top: 3px;
  font-size: 13px;
}
.rform .big-btn, .rform .btn { padding: 8px; font-size: 13px; }
.rform-err { font-size: 12px; color: var(--fuel); min-height: 1em; }

.trend-chart {
  margin-top: 8px;
  background: var(--bg);
  padding: 8px;
  border: 1px solid var(--line);
  border-radius: var(--r-sm);
}
.trend-chart small { color: var(--ink-3); font-size: 11px; }

/* ----- Auth-Modal ----- */
.modal-backdrop {
  position: fixed; inset: 0;
  background: rgba(10,13,20,.55);
  display: flex; align-items: center; justify-content: center;
  z-index: 2000;
  padding: var(--s-4);
  backdrop-filter: blur(2px);
}
[data-theme="dark"] .modal-backdrop { background: rgba(0,0,0,.7); }
.modal-backdrop[hidden] { display: none; }
.modal {
  background: var(--bg);
  color: var(--ink);
  border-radius: var(--r-lg);
  padding: var(--s-6) var(--s-5) var(--s-5);
  width: 100%; max-width: 420px;
  position: relative;
  box-shadow: var(--sh-lg);
  border: 1px solid var(--line);
}
.modal-close {
  position: absolute; top: 10px; right: 14px;
  font-size: 16px;
  color: var(--ink-3);
  padding: 4px 8px;
  transition: color .12s;
}
.modal-close:hover { color: var(--ink); }
.modal-tabs { display: flex; gap: 0; margin-bottom: var(--s-4); border-bottom: 1px solid var(--line); }
.mtab {
  flex: 1; padding: 10px; font-weight: 500; font-size: 14px;
  color: var(--ink-3);
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
}
.mtab.active { color: var(--ink); border-bottom-color: var(--ink); }
.mform { display: flex; flex-direction: column; gap: var(--s-3); }
.mform label {
  display: flex; flex-direction: column;
  font-size: 11px; font-weight: 600;
  color: var(--ink-3);
  text-transform: uppercase; letter-spacing: 0.06em;
}
.mform input {
  margin-top: 4px;
  padding: 10px 12px;
  font-size: 14px;
}
.mform-err { font-size: 12px; color: var(--fuel); min-height: 1em; }
.mform .big-btn, .mform .btn {
  padding: 10px; font-size: 14px; margin-top: var(--s-1);
}

/* Install-Modal (iOS/Android PWA) */
.install-modal { max-width: 440px; }
.install-steps {
  list-style: none; padding: 0; margin: 0;
  display: flex; flex-direction: column; gap: var(--s-3);
}
.install-steps li {
  display: flex; gap: var(--s-3); align-items: flex-start;
  padding: var(--s-3);
  background: var(--bg-2);
  border: 1px solid var(--line);
  border-radius: var(--r-sm);
}
.step-num {
  width: 28px; height: 28px;
  flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  background: var(--ink); color: var(--bg);
  border-radius: 50%;
  font-weight: 700; font-size: 13px;
}
.install-steps strong {
  display: block;
  font-size: 14px; color: var(--ink);
  margin-bottom: 2px;
}
.install-steps p {
  margin: 0;
  font-size: 13px; color: var(--ink-3);
}
.install-hint {
  margin-top: var(--s-3);
  padding: var(--s-2) var(--s-3);
  background: var(--beta-soft);
  border-left: 3px solid var(--beta);
  border-radius: var(--r-xs);
  font-size: 12px; color: var(--ink-2);
}

/* ----- Footer ----- */
.site-footer {
  display: flex; justify-content: space-between; align-items: center;
  padding: var(--s-3) var(--s-5);
  background: var(--bg);
  border-top: 1px solid var(--line);
  font-size: 12px; color: var(--ink-3);
}
.site-footer strong { color: var(--ink-2); font-weight: 600; }
.footer-links { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.footer-links span { color: var(--ink-4); }
.footer-links a {
  color: var(--ink-3); border: 0;
}
.footer-links a:hover { color: var(--ink); }

/* ----- Responsive ----- */
@media (max-width: 820px) {
  .topbar {
    flex-direction: column; gap: var(--s-2);
    align-items: stretch;
    height: auto;
    padding: var(--s-3) var(--s-4);
  }
  .brand { justify-content: center; }
  .top-nav { justify-content: center; font-size: 13px; gap: var(--s-3); flex-wrap: wrap; }
  .layout { grid-template-columns: 1fr; height: auto; }
  .sidebar { border-right: 0; border-bottom: 1px solid var(--line); max-height: none; }
  .map-wrapper { height: 75vh; }
  .site-footer { flex-direction: column; gap: 4px; text-align: center; }
  .price-grid { grid-template-columns: repeat(2, 1fr); }
}
