
/* Lokale Bildausschnitt-Wahl für die Fotoerfassung */
.mle-photo-region-overlay{position:fixed;inset:0;z-index:2147483600;background:rgba(10,22,35,.78);display:flex;align-items:center;justify-content:center;padding:12px}
.mle-photo-region-dialog{box-sizing:border-box;width:min(100%,850px);max-height:96dvh;overflow:auto;background:#fff;color:#263443;border-radius:15px;padding:16px;box-shadow:0 12px 45px #0006}
.mle-photo-region-dialog h3{margin:0 0 8px;font-size:1.12rem}
.mle-photo-region-dialog p{margin:0 0 12px;font-size:.91rem}
.mle-photo-region-dialog canvas{display:block;max-width:100%;width:auto;height:auto;margin:auto;border:1px solid #c6d2dc;border-radius:7px;touch-action:none;cursor:crosshair}
.mle-photo-region-actions{display:flex;justify-content:flex-end;flex-wrap:wrap;gap:8px;margin-top:12px}
.mle-photo-region-actions button{padding:10px 12px;min-height:42px;border:1px solid #9aaebd;border-radius:9px;background:#f5f8fb;color:#234}
.mle-photo-region-actions button[data-action="apply"]{background:#12629a;color:#fff;border-color:#12629a}
.mle-photo-region-actions button:disabled{opacity:.5}

/* Aktionen bleiben im normalen Fachkern-Scrollbereich. */
#mle-save, #r-save { margin-bottom: 0; }
/* Gleichmäßiger Fachkern-Hintergrund statt dunkler Schattenflächen. */
.mle-tanken-fachkern .mle-card,
.mle-tanken-fachkern .mle-btn-primary { box-shadow: none; }
.mle-total-display { display:block;padding:12px 14px;border:1px solid var(--mle-line,#ddd);border-radius:12px;font-size:1.45rem;font-weight:700; }

/* MLE-Auswahl für Benzinsorte und Tankfüllung – statt nativer Dropdowns. */
.mle-choice-group{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px;margin-top:7px}
.mle-choice-button{appearance:none;min-width:0;min-height:48px;padding:10px 7px;border:1px solid #dedbd6;border-radius:12px;background:#f9f8f6;color:#282625;font:inherit;font-size:.91rem;font-weight:600;cursor:pointer;transition:background-color .15s,border-color .15s,box-shadow .15s}
.mle-choice-button:hover{border-color:#fa751d;background:#fff7f1}
.mle-choice-button.is-active{border-color:#fa751d;background:#fff0e6;color:#b84b0b;box-shadow:0 0 0 1px #fa751d33}
.mle-choice-button:focus-visible{outline:3px solid #f97316;outline-offset:2px}
@media(max-width:420px){.mle-choice-group{gap:6px}.mle-choice-button{font-size:.82rem;padding:9px 4px;min-height:46px}}

/* Fahrzeugaktionen: eine Zeile, kompakte Nebenaktion links. */
.mle-btn-row.mle-vehicle-form-actions{display:grid;grid-template-columns:minmax(108px,160px) minmax(0,1fr);align-items:stretch;gap:10px;margin-top:14px;margin-bottom:0;}
.mle-btn-row.mle-vehicle-form-actions > .mle-btn{width:100%;min-width:0;max-width:none;flex:none;margin:0;min-height:50px;box-sizing:border-box;}
.mle-vehicle-form-actions #mle-cancel{padding-inline:12px;}
.mle-vehicle-form-actions #mle-save{margin-bottom:0;}
/* Navigation bleibt direkt oberhalb des Core-Footers. */
.mle-tanken-fachkern .mle-nav {
  position: relative !important;
  inset: auto !important;
  left: auto !important;
  bottom: auto !important;
  transform: none !important;
  flex: 0 0 auto;
  align-self: center;
  margin: 0;
}
@media(max-width:480px){.mle-btn-row.mle-vehicle-form-actions{grid-template-columns:minmax(100px,34%) minmax(0,1fr);}}

/* PDF-Auswertung gehört sichtbar zu den Auswertungsfiltern, nicht unter die feste Navigation. */
.mle-report-pdf-action{display:block;width:100%;margin:8px 0 0;min-height:48px;}

/* Header und Footer stammen aus dem Core. Der Inhalt scrollt auch hinter
   der transparenten Navigationshülle. Die letzte Inhaltszeile lässt sich
   durch den unteren Innenabstand vollständig über die Navigation scrollen. */
html:has(.mle-tanken-fachkern),
body:has(.mle-tanken-fachkern) { height: 100%; overflow: hidden; }
body:has(.mle-tanken-fachkern) {
  display: flex;
  flex-direction: column;
  height: 100dvh;
  min-height: 0;
}
body:has(.mle-tanken-fachkern) > #mle-header,
body:has(.mle-tanken-fachkern) > #mle-footer { flex: 0 0 auto; }
body:has(.mle-tanken-fachkern) > #mle-product-host {
  flex: 1 1 auto;
  min-height: 0;
  overflow: auto;
}
body:has(.mle-tanken-fachkern) #mle-product-root:not([hidden]) {
  height: 100%;
  min-height: 0;
}
.mle-tanken-fachkern.mle-app {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
  height: 100%;
  min-height: 0;
  padding: 0 !important;
  overflow: hidden;
}
.mle-tanken-fachkern .mle-content {
  grid-row: 2 / 4;
  grid-column: 1;
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding-top: 16px;
  padding-bottom: calc(96px + env(safe-area-inset-bottom, 0px));
  scrollbar-width: none; /* Firefox: scrollbar unsichtbar, Scrollen bleibt möglich */
  -ms-overflow-style: none; /* Ältere Edge-Versionen */
}
.mle-tanken-fachkern .mle-license-note { grid-row: 1; grid-column: 1; }
.mle-tanken-fachkern .mle-nav { margin-bottom: 4px; }

/* Chrome, Edge, Safari und Samsung Internet: Scrollbalken nur optisch ausblenden. */
.mle-tanken-fachkern .mle-content::-webkit-scrollbar { display: none; width: 0; height: 0; }

/* Transparente Navigationshülle: Der reservierte Bereich darf den Fachkern
   nicht mit einer eigenen deckenden Hintergrundfläche übermalen. */
.mle-tanken-fachkern .mle-nav-slot {
  grid-row: 3;
  grid-column: 1;
  z-index: 880;
  pointer-events: none;
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 0;
  width: 100%;
  padding: 0 0 max(4px, env(safe-area-inset-bottom, 0px));
  margin: 0;
  background: transparent !important;
  border: 0;
  box-shadow: none;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}
.mle-tanken-fachkern .mle-nav-slot > .mle-nav {
  pointer-events: auto;
  /* Die eigentliche Navigation bleibt die weiße MLE-Pille. */
  background: var(--mle-surface, #fff);
  margin: 0;
}

/* Auswertung: kompakte Filter, klare Zahlen und optionale Vergleichsdetails. */
.mle-reports-page .mle-reports-intro { margin: 4px 2px 18px; font-size: 14px; }
.mle-reports-page .mle-report-filters { padding: 16px; }
.mle-report-filter-grid { display: grid; grid-template-columns: minmax(0,1fr) minmax(0,1.4fr); gap: 16px; }
.mle-report-filter-grid .mle-field { margin-bottom: 0; align-content: start; }
.mle-report-filter-label { font-size: 13px; font-weight: 800; color: var(--mle-text); }
.mle-report-vehicle-choice { display: flex; gap: 9px; align-items: center; min-height: 50px; padding: 8px 12px; border: 1px solid var(--mle-border); border-radius: 14px; cursor: pointer; }
.mle-report-vehicle-choice:has(input:checked) { background: color-mix(in srgb,var(--mle-accent) 6%,var(--mle-surface)); border-color: color-mix(in srgb,var(--mle-accent) 30%,var(--mle-border)); }
.mle-report-vehicle-choice + .mle-report-vehicle-choice { margin-top: 6px; }
.mle-report-vehicle-choice input { flex: 0 0 auto; accent-color: var(--mle-accent); }
.mle-report-vehicle-choice small { display: block; margin-top: 3px; color: var(--mle-text-muted); font-size: 11px; font-weight: 500; }
.mle-reports-page .mle-report-pdf-action { margin-top: 12px; min-height: 40px; font-size: 12px; }
.mle-reports-page .mle-report-period { margin: 0 2px 12px; color: var(--mle-text-muted); font-size: 12px; line-height: 1.5; }
.mle-report-vehicle-heading { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 16px; }
.mle-report-vehicle-heading h3 { margin: 0; font-size: 19px; }
.mle-report-vehicle .mle-tile { padding: 16px; }
.mle-report-vehicle .mle-tile-value { font-size: clamp(21px,4vw,28px); line-height: 1.2; font-variant-numeric: tabular-nums; }
.mle-report-vehicle .mle-tile-label { margin-top: 7px; font-size: 12px; font-weight: 500; }
.mle-report-vehicle .mle-report-cost { background: color-mix(in srgb,var(--mle-accent) 7%,var(--mle-surface)); border-color: color-mix(in srgb,var(--mle-accent) 25%,var(--mle-border)); }
.mle-report-cost .mle-tile-value { color: var(--mle-accent); }
.mle-reports-page .mle-report-note { margin: 12px 0 0; font-size: 12px; line-height: 1.6; color: var(--mle-text-muted); }
.mle-grade-comparison { margin-top: 18px; border-top: 1px solid var(--mle-border); padding-top: 14px; }
.mle-grade-comparison summary { cursor: pointer; font-size: 14px; font-weight: 800; line-height: 1.5; }
.mle-grade-comparison summary small { display: block; margin: 4px 0 0 16px; font-size: 12px; font-weight: 400; color: var(--mle-text-muted); }
.mle-grade-comparison[open] summary { margin-bottom: 14px; }
.mle-report-grade-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 10px; }
.mle-report-grade-price { margin-top: 10px; font-size: 18px; font-weight: 700; }
.mle-report-grade-count { display: block; margin-top: 8px; color: var(--mle-text-muted); font-size: 11px; }
@media(max-width:480px) { .mle-report-filter-grid { grid-template-columns: minmax(0,1fr); gap: 12px; } .mle-report-vehicle .mle-tile { padding: 12px; } }
.mle-report-chart { margin-top: 20px; }
.mle-report-chart-heading { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 8px; }
.mle-report-chart-heading h4 { margin: 0; font-size: 14px; }
.mle-report-chart-heading > span { font-size: 11px; color: var(--mle-text-muted); }
.mle-report-bars { display: flex; gap: 8px; margin-top: 14px; overflow-x: auto; padding-bottom: 6px; }
.mle-report-bar-column { flex: 1 0 34px; max-width: 90px; min-width: 0; text-align: center; }
.mle-report-bar-track { display: flex; align-items: flex-end; justify-content: center; height: 100px; border-bottom: 1px solid var(--mle-border); background: linear-gradient(to top,transparent 49%,var(--mle-border) 50%,transparent 51%); }
.mle-report-bar { width: 65%; max-width: 36px; background: var(--mle-accent); border-radius: 5px 5px 0 0; }
.mle-report-bar-column > span { display: block; margin-top: 7px; font-size: 10px; color: var(--mle-text-muted); font-variant-numeric: tabular-nums; }
.mle-report-chart-values { margin-top: 10px; font-size: 12px; color: var(--mle-text-muted); }
.mle-report-chart-values summary { cursor: pointer; padding-block: 5px; }
.mle-report-chart-values table { margin-top: 8px; }
.mle-report-pdf-feedback { margin-top: 12px; padding: 14px; border: 1px solid var(--mle-border); border-radius: 12px; background: var(--mle-surface-soft); font-size: 13px; line-height: 1.5; color: var(--mle-text); }
.mle-report-pdf-feedback[hidden] { display: none; }
.mle-report-pdf-feedback > span { display: block; margin-top: 4px; color: var(--mle-text-muted); }
.mle-report-pdf-feedback.is-error { border-color: var(--mle-danger); }
.mle-report-pdf-links { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 12px; }
.mle-report-pdf-links a { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; padding: 0 14px; border-radius: 10px; background: var(--mle-accent); color: #fff; font-weight: 700; text-decoration: none; }
.mle-report-pdf-links a:focus-visible { outline: 3px solid var(--mle-text); outline-offset: 3px; }
