/* Tankstellen-Ampel: Stationsvergleich (Auswahl in der Liste, Leiste unten, Vollbild-Dialog) */

/* Auswahl je Zeile */
.st-cmp { padding: 0 12px 10px 21px; margin-top: -4px; }
.cmp-chk { position: relative; display: inline-flex; align-items: center; gap: 8px; min-height: 34px; padding: 0 13px 0 9px; border: 1.5px solid var(--line-2); border-radius: 999px; font-size: .84rem; font-weight: 600; color: var(--ink-2); cursor: pointer; background: transparent; }
.cmp-chk:hover { background: var(--sunken); }
.cmp-chk input { appearance: none; -webkit-appearance: none; width: 18px; height: 18px; margin: 0; border: 1.5px solid var(--ink-2); border-radius: 5px; background: transparent; display: grid; place-content: center; cursor: pointer; flex: none; }
.cmp-chk input::after { content: ''; width: 9px; height: 5px; border-left: 2.2px solid var(--btn-fg); border-bottom: 2.2px solid var(--btn-fg); transform: rotate(-45deg) translate(1px, -1px); opacity: 0; }
.cmp-chk input:checked { background: var(--btn-bg); border-color: var(--btn-bg); }
.cmp-chk input:checked::after { opacity: 1; }
.cmp-chk:has(input:checked) { border-color: var(--ink); color: var(--ink); background: var(--sel); }
.cmp-chk:has(input:focus-visible) { outline: 3px solid var(--focus); outline-offset: 2px; }

/* Leiste unten */
.cmpbar { position: fixed; left: 50%; bottom: calc(16px + env(safe-area-inset-bottom, 0px)); transform: translateX(-50%); z-index: 46; width: min(calc(100% - 24px), 620px); display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; padding: 10px 12px 10px 18px; border-radius: 18px; background: var(--btn-bg); color: var(--btn-fg); box-shadow: 0 12px 32px -10px rgba(0, 0, 0, .55); }
.cmpbar[hidden] { display: none; }
:root[data-theme="dark"] .cmpbar { box-shadow: 0 12px 32px -10px rgba(0, 0, 0, .8), inset 0 0 0 1px var(--line-2); }
.cmpbar-t { flex: 1 1 auto; font-weight: 600; font-size: .95rem; }
.cmpbar-b { display: flex; gap: 8px; margin-left: auto; }
.cmpbar button { height: 40px; padding: 0 14px; border-radius: 12px; font-weight: 600; font-size: .9rem; border: 1.5px solid transparent; }
.cmpbar-open { background: var(--btn-fg); color: var(--btn-bg); }
.cmpbar-open:disabled { opacity: .5; cursor: not-allowed; }
.cmpbar-clear { background: transparent; color: var(--btn-fg); border-color: color-mix(in srgb, var(--btn-fg) 55%, transparent) !important; }
.cmpbar button:focus-visible { outline: 3px solid var(--btn-fg); outline-offset: 2px; }
.cmpbar-msg { flex: 1 1 100%; font-size: .86rem; line-height: 1.4; }
.cmpbar-msg:empty { display: none; }
@media (max-width: 899px) {
  .cmpbar { bottom: calc(80px + env(safe-area-inset-bottom, 0px)); }
}
html.has-cmpbar .list-col { padding-bottom: 150px !important; }

/* Vollbild-Dialog */
html.cmp-open { overflow: hidden; }
.cmp { position: fixed; inset: 0; z-index: 3000; background: var(--bg); color: var(--ink); overflow-y: auto; overscroll-behavior: contain; font-family: var(--font-text); }
.cmp-wrap { max-width: 1180px; margin: 0 auto; padding: 0 20px 48px; }
.cmp-top { position: sticky; top: 0; z-index: 5; display: flex; flex-wrap: wrap; align-items: center; gap: 10px 16px; padding: 14px 0 12px; background: var(--bg); border-bottom: 1px solid var(--line); }
.cmp-top h2 { font-size: clamp(1.25rem, 1rem + 1vw, 1.6rem); margin-right: auto; }
.cmp-top .cmp-close { order: 2; }
.cmp-tools { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 10px; }
.cmp-pdfhint { margin: 8px 0 0; }
.cmp-body { display: grid; gap: 16px; padding-top: 14px; }
.cmp-swipe { display: none; font-size: .82rem; color: var(--muted); }
.cmp-scroll { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); -webkit-overflow-scrolling: touch; }
.cmp-scroll:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }
.cmp-table { width: 100%; min-width: 560px; border-collapse: separate; border-spacing: 0; font-size: .92rem; }
.cmp-table th, .cmp-table td { padding: 10px 14px; text-align: left; vertical-align: top; border-bottom: 1px solid var(--line); font-weight: 500; }
.cmp-table tbody:last-of-type tr:last-child th, .cmp-table tbody:last-of-type tr:last-child td { border-bottom: 0; }
.cmp-table thead th, .cmp-corner { vertical-align: top; background: var(--surface); }
.cmp-col { min-width: 150px; }
.cmp-table th[scope="row"] { position: sticky; left: 0; z-index: 2; background: var(--surface); width: 150px; min-width: 130px; font-weight: 600; color: var(--ink-2); font-size: .86rem; border-right: 1px solid var(--line); }
.cmp-corner { position: sticky; left: 0; z-index: 3; border-right: 1px solid var(--line); }
.cmp-table tr.is-active th, .cmp-table tr.is-active td { background: var(--sel); }
.cmp-grp th { background: var(--sunken) !important; font-family: var(--font-display); font-size: .86rem; font-weight: 700; color: var(--ink); padding: 8px 14px; position: static !important; border-right: 0 !important; }
.cmp-grp-l { position: sticky; left: 14px; display: inline-block; }
.cmp-k { display: block; margin-bottom: 6px; color: var(--ink); }
.cmp-n { display: block; font-family: var(--font-display); font-weight: 700; font-size: 1.02rem; line-height: 1.2; overflow-wrap: anywhere; }
.cmp-a { display: block; font-size: .8rem; font-weight: 400; color: var(--muted); margin-top: 2px; }
.cmp-rm { margin-top: 8px; border: 1.5px solid var(--line-2); background: transparent; border-radius: 8px; padding: 4px 10px; font-size: .8rem; font-weight: 600; color: var(--ink); min-height: 30px; }
.cmp-rm:hover { background: var(--sunken); }
.cmp-p { display: inline-flex; align-items: baseline; gap: 3px; margin-right: 8px; white-space: nowrap; }
.cmp-p b { font-family: var(--font-display); font-weight: 800; font-size: 1.25rem; letter-spacing: -.02em; }
.cmp-p sup { font-size: .55em; position: relative; top: -.55em; vertical-align: baseline; line-height: 0; margin-left: 1px; }
.cmp-p small { font: 500 .72rem var(--font-text); color: var(--muted); }
.cmp-table td b { font-weight: 700; }
.cmp-sub { display: block; font-size: .78rem; font-weight: 400; color: var(--muted); margin-top: 1px; }
.cmp-na { color: var(--muted); font-size: .86rem; font-weight: 400; }
.cmp-best { display: block; width: fit-content; margin-top: 6px; padding: 1px 8px; border-radius: 999px; border: 1px solid var(--g); background: var(--g-tint); color: var(--g-ink); font-size: .74rem; font-weight: 700; }
.cmp-table td .badge { margin-top: 2px; }
.cmp-foot { font-size: .8rem; color: var(--muted); }
.cmp-chart { display: grid; gap: 10px; padding: 18px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); min-width: 0; }
.cmp-chart .stat-title, .cmp-chart-title { font-family: var(--font-display); font-weight: 800; font-size: 1.05rem; margin: 0; }
.cmp-sum { font-size: .95rem; line-height: 1.5; }
.cmp-sum:empty { display: none; }
.cmp-missing { font-size: .86rem; color: var(--ink-2); background: var(--sunken); padding: 10px 12px; border-radius: 10px; }
.cmp-miss:empty { display: none; }
.cmp-details[hidden] { display: none; }
@media (max-width: 700px) {
  .cmp-wrap { padding: 0 16px 40px; }
  .cmp-top h2 { font-size: 1.2rem; }
  .cmp-top { display: grid; grid-template-columns: minmax(0, 1fr) auto; padding-bottom: 10px; }
  .cmp-top .cmp-close { order: 0; }
  .cmp-tools { grid-column: 1 / -1; order: 2; }
  .cmp-grp-l { left: 10px; }
  .cmp-swipe { display: block; }
  .cmp-col { min-width: 142px; }
  .cmp-table th[scope="row"] { width: 108px; min-width: 108px; font-size: .78rem; padding-left: 10px; padding-right: 8px; }
  .cmp-table th, .cmp-table td { padding: 9px 10px; }
  .cmp-chart { padding: 14px; }
  .cmp-table { min-width: 0; }
}

/* Druck: Statusanzeige im Vergleichsreport (feste helle Farben) */
#rptRoot .rp-cat { display: inline-flex; align-items: center; gap: 4px; font-size: 8.5pt; font-weight: 700; margin-left: 4px; }
#rptRoot .rp-cat.is-low { color: #0f6b34; }
#rptRoot .rp-cat.is-mid { color: #6f5000; }
#rptRoot .rp-cat.is-high { color: #a52f1f; }
#rptRoot .cmp-tbl-print { table-layout: fixed; }
#rptRoot .cmp-tbl-print th, #rptRoot .cmp-tbl-print td { vertical-align: top; }
#rptRoot .cmp-tbl-print .cmp-n { font-size: 10pt; }
#rptRoot .cmp-tbl-print .cmp-a, #rptRoot .cmp-tbl-print .cmp-sub { font-size: 8pt; color: #566069; display: block; }
#rptRoot .cmp-tbl-print .cmp-na { color: #566069; font-size: 9pt; }
#rptRoot .cmp-tbl-print .cmp-k { display: block; margin-bottom: 3px; }
#rptRoot .cmp-tbl-print .cmp-p { white-space: nowrap; }
#rptRoot .cmp-tbl-print .cmp-p b { font-size: 11pt; font-family: 'Syne', sans-serif; font-weight: 800; }
#rptRoot .cmp-tbl-print .cmp-p small { font-size: 8pt; color: #566069; }
#rptRoot .cmp-tbl-print .cmp-p sup { font-size: .55em; vertical-align: baseline; position: relative; top: -.5em; line-height: 0; }
#rptRoot .cmp-tbl-print .cmp-best { display: inline-block; font-size: 7.5pt; font-weight: 700; color: #0f6b34; border: 1px solid #15803f; border-radius: 99px; padding: 0 6px; margin-top: 2px; }
#rptRoot .cmp-tbl-print .cmp-grp th { background: #efece6 !important; color: #15191f !important; font-family: 'Syne', sans-serif; font-weight: 700; font-size: 9pt; }
#rptRoot .cmp-tbl-print thead th, #rptRoot .cmp-tbl-print thead td { background: #faf8f4 !important; color: #15191f !important; position: static !important; border-bottom: 1px solid #15191f; }
#rptRoot .cmp-tbl-print th, #rptRoot .cmp-tbl-print td { color: #15191f; }
#rptRoot .cmp-tbl-print tr { break-inside: avoid; }
#rptRoot .cmp-tbl-print th[scope="row"] { width: 28%; }
