body {
    background: #2b2b2b;
}

.navbar.red {
    --bs-navbar-color: rgba(255, 255, 255, .75);
    --bs-navbar-hover-color: #fff;
    --bs-navbar-active-color: #fff;
    --bs-navbar-brand-color: #fff;
    background: #e53935;
}

.navbar .navbar-nav.icons {
    flex-direction: row;
    gap: 1.1rem;
    align-items: center;
}

.navbar-brand-logo {
    height: 80px;
    width: auto;
}

.icon-faded {
    opacity: .7;
}

.grid-dense {
    row-gap: .5rem;
}

@media (min-width:576px) {
    .grid-dense {
        column-gap: .5rem;
    }
}

.card {
    background: #000;
    color: #fff;
    border: none;
    border-radius: .7rem;
}

.card-body {
    padding: .65rem .75rem;
}

.card .card-title {
    margin: 0 0 .3rem;
    font-size: 1.05rem; /* Überschrift etwas größer */
    line-height: 1.1;
    color: #ff3d00;
    font-weight: 600;
}

.metric {
    display: flex;
    align-items: baseline;
    gap: .35rem;
}

.metric .val {
    font-size: 1.45rem;
    font-weight: 700;
}

.metric .unit {
    font-size: .95rem;
    opacity: .85;
}

.meta {
    display: flex;
    justify-content: space-between;
    margin-top: .2rem;
    font-size: .78rem;
    color: #bdbdbd;
}

/* Kachel-Stil wie "costum" */
.kachel .card-title {
  display: flex;
  align-items: center;
  gap: .35rem;
  color: #ff3d00; /* Titel rot */
  font-size: 1.15rem; /* Kachel-Überschrift größer */
  justify-content: center; /* Überschrift mittig */
  text-align: center;
}
.kachel .card-title .wi { font-size: 1.25rem; opacity: .9; }
.kachel .weatherdata { font-size: 1.8rem; font-weight: 800; letter-spacing: .02em; color: #fff; }
.kachel table.meta { width: 100%; margin-top: .25rem; font-size: .88rem; color: #c7c7c7; }
.kachel table.meta td { padding: .05rem .25rem; white-space: nowrap; }
.kachel .highlight { color: #ffcc80; }

/* Zusätze hellgrau in allen Kacheln */
.kachel .small, .kachel .text-muted { color: #c7c7c7 !important; }

/* Spezielles Layout für Luftdruck-Kachel */
.kachel.pressure .card-title {
  color: inherit; /* gleiche Titel-Farbe wie andere Kacheln */
  justify-content: center;
}
.kachel .small { font-size: .85rem; }
/* Druckwert nutzt nun die allgemeine .weatherdata-Optik */

.chart-box {
    width: 100%;
    height: 320px;
}

/* Charts kompakter und Titel mittig */
.chart-card .card-body { padding: .4rem .5rem; }
.chart-card .card-title { text-align: center; margin: 0 0 .25rem; font-size: 1.15rem; }

@media (max-width: 575.98px){
  .chart-box { height: 260px; }
}

.chart-tooltip-time {
    display: inline-block;
    margin-top: .2rem;
    opacity: .7;
}

footer .topbar {
    background: #e53935;
    color: #fff;
    padding: 1.2rem 0;
}

footer .topbar h6 {
    text-transform: uppercase;
    letter-spacing: .02em;
    opacity: .95;
}

footer .bottombar {
    background: #d33b37;
    color: #fff;
    padding: .6rem 0;
    font-size: .9rem;
    opacity: .95;
}

footer a {
    color: #fff;
    text-decoration: none;
    opacity: .9;
}

footer a:hover {
    opacity: 1;
    text-decoration: underline;
}

/* Archiv-Tabellen */
.archive-main {
    padding: 1.5rem 0 3rem;
}

.archive-container {
    color: #f3f3f3;
}

.archive-divider {
    border: 0;
    height: 1px;
    background: linear-gradient(90deg, rgba(0,0,0,0), #ff3d00 45%, rgba(0,0,0,0));
    margin: 2.5rem 0 1.75rem;
}

.archive-block + .archive-block {
    margin-top: 3rem;
}

.archive-title {
    color: #ff3d00;
    text-transform: uppercase;
    letter-spacing: .06em;
    font-size: 1.45rem;
    font-weight: 700;
    margin-bottom: 1.4rem;
}

.archive-subtitle {
    color: #ff7961;
    text-transform: uppercase;
    letter-spacing: .04em;
    font-size: 1.05rem;
    font-weight: 600;
    margin: 1.6rem 0 .75rem;
}

.archive-subtitle-row {
    display: flex;
    align-items: center;
    gap: .75rem;
    flex-wrap: wrap;
    margin: 1.6rem 0 .75rem;
}

.archive-subtitle-row .archive-subtitle {
    margin: 0;
}

.archive-table-wrapper {
    background: #050505;
    border: 1px solid #222;
    border-radius: .85rem;
    padding: .75rem;
    box-shadow: 0 16px 32px rgba(0,0,0,.45);
}

/* Prognose – Kartenlook an restliches Theme anpassen */
.forecast-section { margin-bottom: 2.5rem; }
.forecast-section h2 {
    color: #ff3d00;
    text-transform: uppercase;
    letter-spacing: .05em;
    font-weight: 700;
}

.forecast-info-btn {
    border-radius: 999px;
    font-size: .72rem;
    padding: .25rem .65rem;
    color: #ffccbc;
    border-color: rgba(255, 204, 188, .5);
}

.forecast-info-btn:hover,
.forecast-info-btn:focus {
    color: #fff;
    border-color: #ff7043;
    background: #ff7043;
}

.forecast-info {
    background: #101010;
    border: 1px solid rgba(255, 255, 255, .08);
    border-radius: .75rem;
    padding: .75rem 1rem;
    color: #cfcfcf;
    font-size: .85rem;
}

.forecast-info a { color: #ffab91; }
.forecast-info a:hover { color: #ffc4b3; }
.forecast-info ul { margin-bottom: 0; padding-left: 1.1rem; }
.forecast-info li { margin-bottom: .25rem; }

.forecast-tabs .nav-link {
    border-radius: 999px;
    color: #ff9e80;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.06);
    padding: .3rem 1rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .04em;
}

.forecast-tabs .nav-link.active,
.forecast-tabs .nav-link:hover {
    color: #fff;
    background: #e53935;
    border-color: #e53935;
}

.forecast-model-card {
    background: #050505;
    border: 1px solid #1f1f1f;
    border-radius: .9rem;
    box-shadow: 0 20px 40px rgba(0, 0, 0, .45);
    overflow: hidden;
}

.forecast-model-card .card-header {
    background: #111;
    border-bottom: 1px solid #242424;
    color: #ff3d00;
    text-transform: uppercase;
    letter-spacing: .05em;
    font-weight: 700;
    font-size: 1rem;
}

.forecast-model-card .card-body {
    padding: 1rem;
}

.forecast-model-card .table-responsive {
    overflow-x: auto;
}

.forecast-model-card table,
.forecast-model-card .forecast-table {
    background: #080808;
    color: #f5f5f5;
    border-radius: .6rem;
    overflow: hidden;
    border-collapse: separate;
    min-width: 540px;
}

.forecast-table {
    width: auto !important;
    min-width: 540px;
    table-layout: auto;
}

.forecast-card .table-responsive > .forecast-table,
.forecast-model-card .table-responsive > .forecast-table {
    min-width: 540px;
}

.forecast-model-card thead th {
    font-size: .9rem;
    color: #ff9e80;
    border-bottom: 1px solid rgba(255, 255, 255, .08);
    background: #121212;
    text-transform: uppercase;
    letter-spacing: .03em;
}

.forecast-model-card tbody th {
    color: #ff7043;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .04em;
}

.forecast-model-card tbody tr:not(.forecast-model-icons):not(.forecast-model-desc) th {
    color: #ff7043;
}

.forecast-model-card tbody tr {
    background: #111;
    border-bottom: 1px solid rgba(255, 255, 255, .05);
}

.forecast-model-card tbody tr:nth-child(even) {
    background: #0b0b0b;
}

.forecast-model-card tbody tr.forecast-model-icons,
.forecast-model-card tbody tr.forecast-model-desc {
    background: #101010;
}

.forecast-model-card table td,
.forecast-model-card table th {
    background: transparent;
    border: none;
}

.forecast-model-card tbody tr td {
    background: inherit;
}

.forecast-model-card tbody tr:not(.forecast-model-icons):not(.forecast-model-desc) td,
.forecast-model-card tbody tr:not(.forecast-model-icons):not(.forecast-model-desc) th {
    padding: .55rem .6rem;
    color: #f2f2f2;
}

.forecast-model-card tbody tr:not(.forecast-model-icons):not(.forecast-model-desc) th {
    color: #ff7043 !important;
}

.forecast-model-card tbody tr.forecast-model-desc td {
    font-size: .85rem;
    color: #c7c7c7;
}

.forecast-updated {
    letter-spacing: .02em;
}

@media (max-width: 575.98px) {
    .forecast-card .table-responsive > .forecast-table,
    .forecast-model-card .table-responsive > .forecast-table,
    .forecast-table {
        min-width: 480px;
    }

    .forecast-model-card table,
    .forecast-model-card .forecast-table {
        min-width: 480px;
    }
}

.archive-table {
    width: 100%;
    border-collapse: collapse;
    color: #f1f1f1;
    text-align: center;
    font-size: .9rem;
}

.archive-table thead th {
    background: #101010;
    color: #ff3d00;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .03em;
    padding: .55rem .65rem;
    border: 1px solid #1f1f1f;
}

.archive-table td {
    padding: .45rem .55rem;
    border: 1px solid #1f1f1f;
    vertical-align: middle;
}

.archive-table tbody tr:nth-child(odd) {
    background: #0a0a0a;
}

.archive-table tbody tr:nth-child(even) {
    background: #111;
}

.archive-table .year-cell {
    font-weight: 600;
    color: #ffb74d;
    white-space: nowrap;
}

.archive-table .spacer-cell {
    border: none;
    background: transparent;
    width: .5rem;
}

.archive-table .border-start {
    border-left: 2px solid #ff3d00;
}

.archive-table a {
    color: #ffcc80;
    text-decoration: none;
}

.archive-table a:hover {
    color: #ffffff;
    text-decoration: underline;
}

.archive-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: .25rem .65rem;
    border-radius: 999px;
    background: #1c1c1c;
    border: 1px solid #ff3d00;
    color: #ffcc80;
    font-size: .75rem;
    font-weight: 600;
    letter-spacing: .05em;
    text-transform: uppercase;
    transition: background .2s ease, border-color .2s ease, color .2s ease;
}

.archive-btn:hover {
    background: #ff3d00;
    border-color: #ff3d00;
    color: #fff;
    text-decoration: none;
}

.archive-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: .25rem .8rem;
    border-radius: 999px;
    background: #ff3d00;
    border: 1px solid #ff3d00;
    color: #fff;
    font-size: .75rem;
    letter-spacing: .05em;
    text-transform: uppercase;
    transition: background .2s ease, color .2s ease;
}

.archive-toggle:hover {
    background: #ff6d65;
    color: #fff;
    text-decoration: none;
}

/* Forecast page (DWD MOSMIX) */
.forecast-main {
    padding: 2.5rem 0 3.5rem;
}

.forecast-header {
    max-width: 720px;
    margin: 0 auto;
}

.forecast-title {
    font-size: 2.25rem;
    text-transform: uppercase;
    letter-spacing: .08em;
    font-weight: 700;
    color: #ff3d00;
}

.forecast-subtitle {
    font-size: 1rem;
    letter-spacing: .04em;
    text-transform: uppercase;
}

@media (max-width: 575.98px) {
    .forecast-title {
        font-size: 1.85rem;
    }
}

.forecast-card {
    background: #050505;
    border: 1px solid #1f1f1f;
    border-radius: 1rem;
}

.forecast-card .card-body {
    padding: 1.75rem;
}

@media (max-width: 575.98px) {
    .forecast-card .card-body {
        padding: 1.35rem;
    }
}

.forecast-section + .forecast-section {
    margin-top: 3rem;
}

.forecast-tabs {
    display: flex;
    gap: .35rem;
    flex-wrap: wrap;
}

.forecast-tabs .nav-link {
    border-radius: 999px;
    border: 1px solid rgba(255, 61, 0, .45);
    padding: .4rem 1rem;
    font-weight: 600;
    letter-spacing: .04em;
    text-transform: uppercase;
    color: #ffab91;
    background: rgba(255, 61, 0, .1);
    transition: all .2s ease;
}

.forecast-tabs .nav-link:hover {
    color: #fff;
    background: rgba(255, 61, 0, .22);
    border-color: rgba(255, 61, 0, .65);
}

.forecast-tabs .nav-link.active {
    background: #ff3d00;
    color: #fff;
    border-color: #ff3d00;
    box-shadow: 0 12px 24px rgba(255, 61, 0, .25);
}

.forecast-note {
    text-align: right;
}

.dwdforecast-horizontal {
    overflow-x: auto;
    padding-bottom: .25rem;
}

.dwdforecast-horizontal::-webkit-scrollbar {
    height: 8px;
}

.dwdforecast-horizontal::-webkit-scrollbar-track {
    background: #1a1a1a;
    border-radius: 8px;
}

.dwdforecast-horizontal::-webkit-scrollbar-thumb {
    background: #ff6f61;
    border-radius: 8px;
}

.dwdforecasttable {
    width: 100%;
    min-width: 720px;
    border-collapse: separate;
    border-spacing: 0;
    line-height: 1.05;
    text-align: center;
    color: #f5f5f5;
    font-size: .9rem;
}

.dwdforecasttable td {
    padding: .45rem .5rem;
    border-bottom: 1px solid rgba(255, 255, 255, .06);
}

.dwdforecasttable tr:first-child td {
    border-top: 1px solid rgba(255, 255, 255, .08);
}

.dwdforecasttable td:first-child {
    text-align: left;
    font-weight: 600;
    color: #ffab91;
    white-space: nowrap;
}

.dwdforecasttable .dwdforecast-unit {
    color: #ff7961;
    font-weight: 600;
    text-transform: uppercase;
    font-size: .75rem;
    padding-right: .75rem;
}

.dwdforecasttable .dwdforecast-symbol {
    color: #ffccbc;
    font-size: .85rem;
}

.dwdforecasttable .icons td {
    padding-top: .65rem;
    padding-bottom: .45rem;
    border-bottom: none;
}

.dwdforecasttable .icons img {
    max-width: 48px;
    filter: drop-shadow(0 4px 8px rgba(0, 0, 0, .4));
}

.dwdforecasttable .topdist td {
    padding-top: .8rem;
}

.dwdforecasttable td.weekend {
    background: rgba(255, 61, 0, .12);
}

@media (max-width: 991.98px) {
    .dwdforecasttable {
        font-size: .85rem;
        min-width: 640px;
    }
}

@media (max-width: 575.98px) {
    .dwdforecasttable {
        font-size: .8rem;
        min-width: 560px;
    }

    .forecast-note {
        text-align: left;
    }
}
