@font-face{font-family:"IBM Plex Sans";font-weight:400;font-style:normal;font-display:swap;src:url(fonts/ibm-plex-sans-latin-400-normal.woff2) format("woff2")}
@font-face{font-family:"IBM Plex Sans";font-weight:500;font-style:normal;font-display:swap;src:url(fonts/ibm-plex-sans-latin-500-normal.woff2) format("woff2")}
@font-face{font-family:"IBM Plex Sans";font-weight:600;font-style:normal;font-display:swap;src:url(fonts/ibm-plex-sans-latin-600-normal.woff2) format("woff2")}
@font-face{font-family:"IBM Plex Sans";font-weight:700;font-style:normal;font-display:swap;src:url(fonts/ibm-plex-sans-latin-700-normal.woff2) format("woff2")}
@font-face{font-family:"IBM Plex Mono";font-weight:500;font-style:normal;font-display:swap;src:url(fonts/ibm-plex-mono-latin-500-normal.woff2) format("woff2")}
@font-face{font-family:"IBM Plex Mono";font-weight:600;font-style:normal;font-display:swap;src:url(fonts/ibm-plex-mono-latin-600-normal.woff2) format("woff2")}
:root {
  --bg: #f4f2ee;
  --panel: #ffffff;
  --ink: #1c1d1f;
  --muted: #6b6d72;
  --line: #e3e0da;
  --accent: #0f6b5c;
  --accent-ink: #ffffff;
  --accent-soft: #e2f0ec;
  --logo-arrow: #7fe0b4;
  --cheap: #1a8a4a;
  --mid: #c98a12;
  --pricey: #c4442f;
  --closed: #9a9ca1;
  --shadow: 0 1px 2px rgba(0,0,0,.06), 0 4px 16px rgba(0,0,0,.06);
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #141517; --panel: #1d1f22; --ink: #ececec; --muted: #9a9ca3; --line: #2e3135;
    --accent: #3fb59d; --accent-ink: #0d1412; --accent-soft: #1d3330; --logo-arrow: #0d1412;
    --cheap: #44c47a; --mid: #e0a83a; --pricey: #ec6b55; --closed: #6c6f75;
    --shadow: 0 1px 2px rgba(0,0,0,.3), 0 4px 16px rgba(0,0,0,.3);
  }
}
:root[data-theme="dark"] {
  --bg: #141517; --panel: #1d1f22; --ink: #ececec; --muted: #9a9ca3; --line: #2e3135;
  --accent: #3fb59d; --accent-ink: #0d1412; --accent-soft: #1d3330; --logo-arrow: #0d1412;
  --cheap: #44c47a; --mid: #e0a83a; --pricey: #ec6b55; --closed: #6c6f75;
  --shadow: 0 1px 2px rgba(0,0,0,.3), 0 4px 16px rgba(0,0,0,.3);
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body {
  background: var(--bg); color: var(--ink);
  font: 15px/1.45 "IBM Plex Sans", system-ui, sans-serif;
  display: grid; grid-template-columns: 400px 1fr; height: 100vh; overflow: hidden;
}
.num { font-family: "IBM Plex Mono", ui-monospace, monospace; font-variant-numeric: tabular-nums; }
aside { background: var(--panel); border-right: 1px solid var(--line); display: flex; flex-direction: column; min-height: 0; }
header { padding: 18px 20px 12px; border-bottom: 1px solid var(--line); }
h1 { font-size: 20px; margin: 0 0 12px; letter-spacing: -.01em; display: flex; align-items: center; gap: 8px; }
h1 .wordmark { font-size: 22px; }
form.search { display: flex; gap: 6px; }
input[type=search], input[type=text], select {
  font: inherit; color: var(--ink); background: var(--bg); border: 1px solid var(--line);
  border-radius: 8px; padding: 9px 11px; min-width: 0;
}
input[type=search] { flex: 1; }
input:focus-visible, select:focus-visible, button:focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; }
button { font: inherit; cursor: pointer; border-radius: 8px; border: 1px solid var(--line); background: var(--panel); color: var(--ink); padding: 9px 11px; }
button.primary { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); font-weight: 600; }
button.icon { padding: 9px; display: grid; place-items: center; }
.suggest { list-style: none; margin: 6px 0 0; padding: 0; border: 1px solid var(--line); border-radius: 8px; overflow: hidden; }
.suggest:empty { display: none; }
.suggest li button { width: 100%; text-align: left; border: 0; border-radius: 0; border-bottom: 1px solid var(--line); font-size: 14px; }
.suggest li:last-child button { border-bottom: 0; }
.suggest li button:hover { background: var(--accent-soft); }
.filters { padding: 12px 20px; border-bottom: 1px solid var(--line); display: grid; gap: 10px; }
.chips { display: flex; gap: 6px; flex-wrap: wrap; }
.chip { border-radius: 999px; padding: 6px 13px; font-weight: 500; font-size: 14px; }
.chip[aria-pressed="true"] { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }
.row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; font-size: 14px; color: var(--muted); }
.row label { display: flex; gap: 6px; align-items: center; cursor: pointer; }
.row select { padding: 6px 8px; font-size: 14px; }
.status { padding: 8px 20px; font-size: 13px; color: var(--muted); border-bottom: 1px solid var(--line); min-height: 34px; }
.status.warn { color: var(--pricey); }
.banner { margin: 0; padding: 8px 20px; font-size: 13px; background: var(--accent-soft); border-bottom: 1px solid var(--line); }
.banner button { padding: 2px 8px; font-size: 13px; margin-left: 4px; }
ol.list { list-style: none; margin: 0; padding: 0; }
.st { padding: 12px 20px; border-bottom: 1px solid var(--line); cursor: pointer; display: grid; grid-template-columns: 1fr auto; gap: 4px 12px; }
.st:hover, .st.active { background: var(--accent-soft); }
.st .name { font-weight: 600; overflow-wrap: anywhere; }
.st .addr { font-size: 13px; color: var(--muted); grid-column: 1; }
.st .meta { font-size: 12px; color: var(--muted); display: flex; gap: 8px; align-items: center; grid-column: 1; }
.badge { font-size: 11px; font-weight: 600; padding: 1px 6px; border-radius: 4px; text-transform: uppercase; letter-spacing: .03em; }
.badge.open { background: color-mix(in srgb, var(--cheap) 15%, transparent); color: var(--cheap); }
.badge.closed { background: color-mix(in srgb, var(--closed) 20%, transparent); color: var(--muted); }
.prices { grid-column: 2; grid-row: 1 / span 3; display: grid; gap: 3px; align-content: center; justify-items: end; }
.p { display: flex; gap: 8px; align-items: baseline; }
.p .lbl { font-size: 11px; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; }
.p .val { font-size: 18px; font-weight: 600; }
.p .val sup { font-size: 11px; }
.p.main .val { font-size: 22px; }
.tier-0 { color: var(--cheap); } .tier-1 { color: var(--mid); } .tier-2 { color: var(--pricey); } .tier-x { color: var(--closed); }
.empty { padding: 30px 20px; color: var(--muted); text-align: center; }
footer { padding: 8px 20px; font-size: 12px; color: var(--muted); border-top: 1px solid var(--line); }
footer a { color: inherit; }
main { position: relative; min-height: 0; }
#map { position: absolute; inset: 0; background: var(--bg); }
.zoomhint { position: absolute; top: 12px; left: 50%; transform: translateX(-50%); z-index: 500; background: var(--panel); border: 1px solid var(--line); box-shadow: var(--shadow); padding: 8px 14px; border-radius: 999px; font-size: 14px; display: none; }
.zoomhint.show { display: block; }
.pin { background: transparent; border: 0; }
.pin span {
  display: inline-block; transform: translate(-50%, -100%); white-space: nowrap;
  background: var(--panel); color: var(--ink); border: 2px solid currentColor; border-radius: 7px;
  padding: 1px 6px; font: 600 13px "IBM Plex Mono", monospace; box-shadow: var(--shadow); position: relative;
}
.pin span::after { content: ""; position: absolute; left: 50%; bottom: -7px; transform: translateX(-50%); border: 6px solid transparent; border-top-color: currentColor; border-bottom: 0; }
.pin span b { color: var(--ink); font-weight: 600; }
.pin.t0 span { color: var(--cheap); } .pin.t1 span { color: var(--mid); } .pin.t2 span { color: var(--pricey); } .pin.tx span { color: var(--closed); }
.pin.active span { background: var(--ink); } .pin.active span b { color: var(--panel); }
.leaflet-popup-content-wrapper, .leaflet-popup-tip { background: var(--panel); color: var(--ink); }
.leaflet-popup-content { font: 14px/1.4 "IBM Plex Sans", sans-serif; margin: 12px 14px; }
.pop h3 { margin: 0 0 2px; font-size: 15px; }
.pop .addr { color: var(--muted); font-size: 13px; margin-bottom: 8px; }
.pop table { border-collapse: collapse; width: 100%; margin-bottom: 8px; }
.pop td { padding: 2px 0; } .pop td:last-child { text-align: right; font-family: "IBM Plex Mono", monospace; font-weight: 600; }
.pop a { color: var(--accent); font-weight: 600; }
dialog { border: 1px solid var(--line); border-radius: 12px; background: var(--panel); color: var(--ink); max-width: 440px; width: calc(100% - 32px); }
dialog::backdrop { background: rgba(0,0,0,.4); }
dialog h2 { margin: 0 0 8px; font-size: 18px; }
dialog p { font-size: 14px; color: var(--muted); }
dialog input { width: 100%; margin: 6px 0 14px; }
dialog .act { display: flex; gap: 8px; justify-content: flex-end; }
@media (max-width: 760px) {
  body { grid-template-columns: minmax(0, 1fr); grid-template-rows: 42vh minmax(0, 1fr); height: 100dvh; }
  aside { min-width: 0; }
  main { grid-row: 1; }
  aside { grid-row: 2; border-right: 0; border-top: 1px solid var(--line); }
  header { padding: 10px 16px 10px; } h1 { font-size: 17px; margin-bottom: 8px; } h1 .logo { width: 24px; height: 24px; } h1 .wordmark { font-size: 18px; }
  .filters, .status, .banner, footer { padding-left: 16px; padding-right: 16px; }
  .st { padding: 10px 16px; }
}

/* ===== Ansichten in der Seitenleiste ===== */
.view { flex: 1; min-height: 0; overflow-y: auto; overscroll-behavior: contain; }
.view[hidden], .box[hidden], .toast[hidden] { display: none; }
.filters .row select { max-width: 170px; }
.muted { color: var(--muted); }
.small { font-size: 12px; }
.warn { color: var(--pricey); }
.linkbtn { font: inherit; background: none; border: 0; padding: 0; color: var(--accent); font-weight: 600; cursor: pointer; text-decoration: underline; }
.box { margin: 12px 20px 0; padding: 12px 14px; border: 1px solid var(--line); border-radius: 10px; background: var(--bg); }
.box h2 { font-size: 14px; margin: 0 0 6px; }
.box h2 small { font-weight: 400; color: var(--muted); margin-left: 4px; }
.box p { margin: 0 0 8px; font-size: 13px; }
.box p:last-child { margin-bottom: 0; }
.box + .status { margin-top: 12px; border-top: 1px solid var(--line); }
/* (6) Ersparnis */
.sum-row { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin-bottom: 8px; }
.sum-row .k { display: block; font-size: 11px; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; }
.sum-row .v { font-size: 18px; font-weight: 600; }
.sum-text select { padding: 1px 4px; font-size: 13px; border-radius: 6px; }
/* (2) Tagesprofil */
svg.prof { width: 100%; height: auto; display: block; margin-top: 4px; }
svg.prof rect.c0 { fill: var(--cheap); } svg.prof rect.c1 { fill: var(--mid); } svg.prof rect.c2 { fill: var(--pricey); }
svg.prof rect.now { stroke: var(--ink); stroke-width: 1.2; }
svg.prof text { fill: var(--muted); font: 8px "IBM Plex Sans", sans-serif; }
/* (4) Favoriten */
.favlist { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; }
.fav-row { width: 100%; display: flex; justify-content: space-between; align-items: center; gap: 10px; text-align: left; border: 0; border-radius: 6px; padding: 6px 8px; background: transparent; }
.fav-row:hover { background: var(--accent-soft); }
.fav-row .fn { font-weight: 600; font-size: 14px; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.fav-row .fn small { font-weight: 400; color: var(--muted); margin-left: 6px; }
.fav-row .fp { font-weight: 600; white-space: nowrap; }
.star { border: 0; background: none; padding: 2px; margin-left: 4px; color: var(--muted); vertical-align: -3px; border-radius: 4px; }
.star[aria-pressed="true"] { color: var(--mid); }
.star:hover { color: var(--mid); }
.badge.ab { background: color-mix(in srgb, var(--pricey) 14%, transparent); color: var(--pricey); }
.badge.best { background: var(--cheap); color: #fff; }
.diff { font-size: 12px; color: var(--muted); }
.pin.fav span::before { content: "★"; color: var(--mid); margin-right: 3px; font-family: "IBM Plex Sans", sans-serif; }
.pop-act { display: flex; justify-content: space-between; gap: 12px; align-items: center; }
/* (1, 3, 7) Detailansicht */
.detail .back { border: 0; border-bottom: 1px solid var(--line); border-radius: 0; width: 100%; text-align: left; padding: 10px 20px; font-weight: 600; color: var(--accent); background: var(--panel); position: sticky; top: 0; z-index: 2; }
.detail .pad { padding: 14px 20px 24px; }
.d-head { display: flex; justify-content: space-between; gap: 12px; align-items: flex-start; }
.d-head h2 { margin: 0; font-size: 20px; }
.d-head .addr { margin: 2px 0 6px; color: var(--muted); font-size: 14px; }
.d-head .meta { margin: 0; display: flex; gap: 6px; }
.favbtn { display: inline-flex; gap: 4px; align-items: center; font-size: 13px; padding: 6px 10px; white-space: nowrap; }
.favbtn[aria-pressed="true"] { color: var(--mid); border-color: var(--mid); }
.d-prices { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin: 14px 0 4px; }
.d-prices > div { border: 1px solid var(--line); border-radius: 8px; padding: 8px 10px; }
.d-prices .lbl { display: block; font-size: 11px; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; }
.d-prices .val { font-size: 20px; font-weight: 600; }
.routebtn { color: var(--accent); font-weight: 600; font-size: 14px; }
.detail h3 { font-size: 15px; margin: 22px 0 8px; padding-top: 14px; border-top: 1px solid var(--line); }
.seg2 { display: inline-flex; border: 1px solid var(--line); border-radius: 8px; overflow: hidden; margin: 0 6px 8px 0; }
.seg2 button { border: 0; border-radius: 0; padding: 5px 10px; font-size: 13px; border-right: 1px solid var(--line); }
.seg2 button:last-child { border-right: 0; }
.seg2 button[aria-pressed="true"] { background: var(--accent); color: var(--accent-ink); font-weight: 600; }
svg.hist { width: 100%; height: auto; display: block; }
svg.hist .grid { stroke: var(--line); }
svg.hist text { fill: var(--muted); font: 9px "IBM Plex Mono", monospace; }
svg.hist .line { fill: none; stroke: var(--accent); stroke-width: 2; stroke-linejoin: round; }
svg.hist .area { fill: var(--accent-soft); }
svg.hist .dot { fill: var(--cheap); stroke: var(--panel); stroke-width: 1.5; }
table.hours { border-collapse: collapse; font-size: 14px; }
table.hours td { padding: 3px 18px 3px 0; }
.alarm { display: grid; gap: 10px; font-size: 14px; }
.alarm label { display: grid; gap: 4px; }
.alarm label.chk { display: flex; gap: 8px; align-items: flex-start; font-size: 13px; color: var(--muted); }
.alarm label.chk input { margin-top: 3px; }
.alarm .arow { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.alarm input[type=number], .alarm input[type=email] { font: inherit; color: var(--ink); background: var(--bg); border: 1px solid var(--line); border-radius: 8px; padding: 8px 10px; width: 100%; }
.alarm button[disabled] { opacity: .6; cursor: wait; }
.amsg { margin: 0; font-size: 13px; }
.amsg.ok { color: var(--cheap); font-weight: 600; }
.toast { position: fixed; left: 50%; bottom: 20px; transform: translateX(-50%); z-index: 1500; background: var(--ink); color: var(--panel); padding: 10px 16px; border-radius: 10px; box-shadow: var(--shadow); font-size: 14px; max-width: min(92vw, 480px); }
.toast .linkbtn { color: inherit; }
@media (max-width: 760px) {
  .box { margin: 10px 16px 0; }
  .detail .back, .detail .pad { padding-left: 16px; padding-right: 16px; }
  .filters .row select { max-width: 140px; }
}

details.more summary { cursor: pointer; font-size: 14px; color: var(--accent); font-weight: 600; list-style-position: inside; }
details.more summary span { color: var(--muted); font-weight: 400; }
details.more[open] summary { margin-bottom: 8px; }
.alarm label.chk a { color: var(--accent); }
@media (max-width: 760px) {
  aside { overflow-y: auto; }
  .view { flex: none; overflow: visible; }
  .detail .back { position: static; }
}

/* Werbeflächen */
.ad { margin: 12px 20px 0; padding: 6px 0 8px; border-top: 1px dashed var(--line); border-bottom: 1px dashed var(--line); min-height: 60px; }
.ad[hidden] { display: none; }
.ad-label { display: block; font-size: 10px; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); margin-bottom: 4px; }
.ad-detail { margin: 0 20px 24px; }
@media (max-width: 760px) { .ad { margin-left: 16px; margin-right: 16px; } }

/* Logo & Schriftzug Tankkurs.de */
.logo { flex: none; display: block; }
.logo .lg-drop { fill: var(--accent); }
.logo .lg-line, .logo .lg-arrow { fill: none; stroke-width: 4.2; stroke-linecap: round; stroke-linejoin: round; }
.logo .lg-line { stroke: var(--panel); }
.logo .lg-arrow { stroke: var(--logo-arrow); }
.wordmark { font-weight: 700; letter-spacing: -.02em; }
.wordmark span { color: var(--muted); font-weight: 500; }
