/* Bongovo! Yr.no Weather – https://www.bongovo.cz – GPLv3 */

.byn-weather {
    --byn-bg: #16213e;
    --byn-bg-2: #0f3460;
    --byn-bg-3: #1e1e2f;
    --byn-text: #e8eaf0;
    --byn-text-2: #c8c8d0;
    --byn-strong: #fff;
    --byn-accent: #00aaff;
    --byn-border: rgba(255, 255, 255, .08);
    --byn-hover: rgba(255, 255, 255, .06);
    --byn-rain: #4fc3f7;
    --byn-line: #ff6b81;

    box-sizing: border-box;
    width: 100%;
    padding: 1rem;
    border-radius: .75rem;
    background: var(--byn-bg);
    color: var(--byn-text);
    box-shadow: 0 4px 8px rgba(0, 0, 0, .25);
}

.byn-weather *,
.byn-weather *::before,
.byn-weather *::after {
    box-sizing: border-box;
}

.byn-weather.theme-sand {
    --byn-bg: #f9f4e7;
    --byn-bg-2: #efe7d5;
    --byn-bg-3: #e3dac6;
    --byn-text: #2a2a2a;
    --byn-text-2: #5a5a5a;
    --byn-strong: #191919;
    --byn-accent: #b77a00;
    --byn-border: rgba(0, 0, 0, .1);
    --byn-hover: rgba(0, 0, 0, .05);
    --byn-rain: #1e88c9;
    --byn-line: #d6453d;
}

.byn-weather.theme-ice {
    --byn-bg: #f0f6fb;
    --byn-bg-2: #e3eef7;
    --byn-bg-3: #d4e6f5;
    --byn-text: #1d2a35;
    --byn-text-2: #4b5b68;
    --byn-strong: #0f1720;
    --byn-accent: #157bff;
    --byn-border: rgba(0, 0, 0, .1);
    --byn-hover: rgba(0, 0, 0, .04);
    --byn-rain: #157bff;
    --byn-line: #d6453d;
}

.byn-weather.theme-mono {
    --byn-bg: #1c1c1f;
    --byn-bg-2: #26262a;
    --byn-bg-3: #303036;
    --byn-text: #f0f0f0;
    --byn-text-2: #b8b8c2;
    --byn-accent: #ff3f81;
    --byn-border: rgba(255, 255, 255, .1);
    --byn-hover: rgba(255, 255, 255, .07);
}

.byn-weather.theme-contrast {
    --byn-bg: #0b0b0b;
    --byn-bg-2: #141414;
    --byn-bg-3: #1f1f1f;
    --byn-text: #fff;
    --byn-text-2: #d4d4d4;
    --byn-accent: #ffd400;
    --byn-border: rgba(255, 255, 255, .25);
    --byn-hover: rgba(255, 255, 255, .12);
}

.byn-error {
    margin: 0;
}

.byn-weather.theme-ocean {
    --byn-bg: #0b2530;
    --byn-bg-2: #0f3a49;
    --byn-bg-3: #134c5f;
    --byn-text: #e3f4f6;
    --byn-text-2: #a9cdd4;
    --byn-accent: #2dd4bf;
    --byn-border: rgba(255, 255, 255, .1);
    --byn-hover: rgba(45, 212, 191, .1);
    --byn-rain: #38bdf8;
    --byn-line: #fbbf24;
}

.byn-weather.theme-forest {
    --byn-bg: #14251a;
    --byn-bg-2: #1c3a26;
    --byn-bg-3: #26502f;
    --byn-text: #e6f2e8;
    --byn-text-2: #aecdb4;
    --byn-accent: #84cc16;
    --byn-border: rgba(255, 255, 255, .1);
    --byn-hover: rgba(132, 204, 22, .1);
    --byn-rain: #5eead4;
    --byn-line: #fb923c;
}

.byn-weather.theme-sunset {
    --byn-bg: #2a1620;
    --byn-bg-2: #3d1f2b;
    --byn-bg-3: #552a37;
    --byn-text: #fbebe4;
    --byn-text-2: #e0b9a8;
    --byn-accent: #fb923c;
    --byn-border: rgba(255, 255, 255, .1);
    --byn-hover: rgba(251, 146, 60, .1);
    --byn-rain: #7dd3fc;
    --byn-line: #fde047;
}

.byn-weather.theme-violet {
    --byn-bg: #1e1733;
    --byn-bg-2: #2b2150;
    --byn-bg-3: #3a2c6b;
    --byn-text: #eeeaff;
    --byn-text-2: #bdb4e6;
    --byn-accent: #a78bfa;
    --byn-border: rgba(255, 255, 255, .1);
    --byn-hover: rgba(167, 139, 250, .12);
    --byn-rain: #67e8f9;
    --byn-line: #f472b6;
}

.byn-weather.theme-mint {
    --byn-bg: #eefaf3;
    --byn-bg-2: #dcf3e6;
    --byn-bg-3: #c6ead6;
    --byn-text: #1b2e24;
    --byn-text-2: #4a6556;
    --byn-strong: #0e1c15;
    --byn-accent: #0f9d63;
    --byn-border: rgba(0, 0, 0, .1);
    --byn-hover: rgba(0, 0, 0, .04);
    --byn-rain: #0b83c4;
    --byn-line: #d6453d;
}

.byn-place {
    margin-bottom: .5rem;
    font-size: 1.5rem;
    color: var(--byn-strong);
}

.byn-icon {
    display: block;
    max-width: 100%;
    height: auto;
}

.byn-condition {
    display: block;
    font-size: 1.1rem;
    font-weight: 400;
    color: var(--byn-text-2);
}

.byn-badge {
    display: inline-block;
    padding: .1rem .5rem;
    border-radius: 1rem;
    color: #111;
    background: #8bc34a;
}

.byn-badge-moderate { background: #ffeb3b; }
.byn-badge-high { background: #ffb300; }
.byn-badge-very-high { background: #ff7043; }
.byn-badge-extreme { background: #ab47bc; color: #fff; }

.byn-day-name {
    font-weight: 600;
}

.byn-day-max {
    font-size: 1.1rem;
    font-weight: 700;
}

.byn-day-min {
    font-size: .9rem;
    opacity: .7;
}

/* Temperature colours */
.temp-cold-4 { color: #7aa8ff; }
.temp-cold-3 { color: #7fd1ff; }
.temp-cold-2 { color: #9ee6e0; }
.temp-cold-1 { color: #b5e9a4; }
.temp-warm-1 { color: #ffe27a; }
.temp-warm-2 { color: #ffb86b; }
.temp-warm-3 { color: #ff8a65; }
.temp-warm-4 { color: #ff5252; }

.theme-sand .temp-cold-4, .theme-ice .temp-cold-4, .theme-mint .temp-cold-4 { color: #1d4fd8; }
.theme-sand .temp-cold-3, .theme-ice .temp-cold-3, .theme-mint .temp-cold-3 { color: #0b74c4; }
.theme-sand .temp-cold-2, .theme-ice .temp-cold-2, .theme-mint .temp-cold-2 { color: #0a8a86; }
.theme-sand .temp-cold-1, .theme-ice .temp-cold-1, .theme-mint .temp-cold-1 { color: #3d8b1f; }
.theme-sand .temp-warm-1, .theme-ice .temp-warm-1, .theme-mint .temp-warm-1 { color: #9a7400; }
.theme-sand .temp-warm-2, .theme-ice .temp-warm-2, .theme-mint .temp-warm-2 { color: #c26a00; }
.theme-sand .temp-warm-3, .theme-ice .temp-warm-3, .theme-mint .temp-warm-3 { color: #c2410c; }
.theme-sand .temp-warm-4, .theme-ice .temp-warm-4, .theme-mint .temp-warm-4 { color: #b91c1c; }

/* Chart */
.byn-chart-box {
    margin: 1rem 0 0;
    padding: .75rem;
    border: 1px solid var(--byn-border);
    border-radius: .6rem;
    background: var(--byn-bg-2);
}

.byn-chart {
    display: block;
    width: 100%;
    height: auto;
}

.byn-chart-grid {
    stroke: var(--byn-border);
    stroke-width: 1;
}

.byn-chart-midnight {
    stroke: var(--byn-text-2);
    stroke-dasharray: 3 3;
}

.byn-chart-text {
    fill: var(--byn-text-2);
    font-size: 11px;
}

.byn-chart-bar {
    fill: var(--byn-rain);
    opacity: .8;
}

.byn-chart-line {
    fill: none;
    stroke: var(--byn-line);
    stroke-width: 2.5;
    stroke-linejoin: round;
    stroke-linecap: round;
}

.byn-chart-legend {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: .5rem 1.5rem;
    margin-top: .25rem;
    font-size: .85rem;
    color: var(--byn-text-2);
}

.byn-legend-temp::before,
.byn-legend-rain::before {
    content: "";
    display: inline-block;
    width: .9rem;
    height: .5rem;
    margin-right: .35rem;
    border-radius: 2px;
}

.byn-legend-temp::before { background: var(--byn-line); }
.byn-legend-rain::before { background: var(--byn-rain); }

/* Chart with printed values */
.byn-chart-fill-a { stop-color: var(--byn-line); stop-opacity: .35; }
.byn-chart-fill-b { stop-color: var(--byn-line); stop-opacity: 0; }

.byn-chart-dot {
    fill: var(--byn-bg);
    stroke: var(--byn-line);
    stroke-width: 2;
}

.byn-chart-value {
    fill: var(--byn-strong);
    font-size: 11px;
    font-weight: 700;
}

.byn-chart-value-rain {
    fill: var(--byn-rain);
    font-weight: 600;
}

.byn-chart-title {
    margin: 0 0 .25rem .25rem;
    font-size: .85rem;
    font-weight: 700;
    color: var(--byn-strong);
}

.byn-weather {
    --byn-s1: #f59e0b;
    --byn-s2: #22c55e;
    --byn-s3: #38bdf8;
    --byn-s4: #a78bfa;
    --byn-s5: #f472b6;
    --byn-s6: #94a3b8;
}

.byn-chart-series {
    fill: none;
    stroke-width: 2.2;
    stroke-linejoin: round;
    stroke-linecap: round;
}

.byn-chart-series.byn-dash { stroke-dasharray: 6 4; }

.byn-chart-series.byn-s1, .byn-chart-dot.byn-s1 { stroke: var(--byn-s1); }
.byn-chart-series.byn-s2, .byn-chart-dot.byn-s2 { stroke: var(--byn-s2); }
.byn-chart-series.byn-s3, .byn-chart-dot.byn-s3 { stroke: var(--byn-s3); }
.byn-chart-series.byn-s4, .byn-chart-dot.byn-s4 { stroke: var(--byn-s4); }
.byn-chart-series.byn-s5, .byn-chart-dot.byn-s5 { stroke: var(--byn-s5); }
.byn-chart-series.byn-s6, .byn-chart-dot.byn-s6 { stroke: var(--byn-s6); }

.byn-legend-item::before {
    content: "";
    display: inline-block;
    width: .9rem;
    height: .5rem;
    margin-right: .35rem;
    border-radius: 2px;
    background: currentColor;
}

.byn-legend-item.byn-s1::before { background: var(--byn-s1); }
.byn-legend-item.byn-s2::before { background: var(--byn-s2); }
.byn-legend-item.byn-s3::before { background: var(--byn-s3); }
.byn-legend-item.byn-s4::before { background: var(--byn-s4); }
.byn-legend-item.byn-s5::before { background: var(--byn-s5); }
.byn-legend-item.byn-s6::before { background: var(--byn-s6); }

.byn-modern .byn-chart-box + .byn-chart-box,
.byn-table-layout .byn-chart-box + .byn-chart-box {
    margin-top: .75rem;
}

/* Modern table layout */
.byn-modern {
    padding: 1.25rem;
    border-radius: 1rem;
    background: linear-gradient(160deg, var(--byn-bg) 0%, var(--byn-bg-2) 140%);
    box-shadow: 0 10px 30px rgba(0, 0, 0, .25);
}

.byn-modern-head {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 1rem;
    text-align: center;
}

.byn-modern-now {
    display: flex;
    flex-direction: column;
}

.byn-modern-place {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--byn-accent);
}

.byn-modern-temp {
    font-size: 2.6rem;
    font-weight: 800;
    line-height: 1.1;
}

.byn-modern-wrap {
    border: 1px solid var(--byn-border);
    border-radius: .8rem;
    background: var(--byn-bg);
}

.byn-modern-table thead th {
    background: var(--byn-bg-3);
    border-bottom: 2px solid var(--byn-accent);
    font-size: .78rem;
    letter-spacing: .04em;
    text-transform: uppercase;
}

.byn-modern-table tbody tr:not(.byn-table-day):nth-child(even) td {
    background: var(--byn-hover);
}

.byn-modern-table .byn-table-day th {
    background: var(--byn-bg-2);
    color: var(--byn-accent);
    text-align: left;
    padding-left: 1rem;
    border-bottom: 1px solid var(--byn-accent);
}

.byn-modern-time {
    font-weight: 600;
    color: var(--byn-text-2);
}

.byn-pill {
    display: inline-block;
    min-width: 3.2rem;
    padding: .15rem .6rem;
    border-radius: 999px;
    font-weight: 700;
    background: color-mix(in srgb, currentColor 16%, transparent);
    box-shadow: inset 0 0 0 1px color-mix(in srgb, currentColor 40%, transparent);
}

.byn-rainbar {
    display: block;
    width: 100%;
    height: .3rem;
    margin: 0 0 .2rem;
    border-radius: 999px;
    background: var(--byn-border);
    overflow: hidden;
}

.byn-rainbar.is-wet::after {
    content: "";
    display: block;
    width: var(--byn-w, 0);
    min-width: 6%;
    height: 100%;
    border-radius: inherit;
    background: var(--byn-rain);
}

.byn-modern .byn-chart-box {
    border-radius: .8rem;
    background: var(--byn-bg);
}

@media (max-width: 600px) {
    .byn-modern-table tbody tr:not(.byn-table-day) {
        background: var(--byn-bg-2);
    }

    .byn-modern-table tbody tr:not(.byn-table-day) td {
        background: transparent !important;
    }

    .byn-rainbar {
        width: 4rem;
        margin: 0 0 0 auto;
    }

    .byn-modern-table td:has(.byn-rainbar) {
        flex-wrap: wrap;
    }
}

.byn-attribution {
    margin: 1rem 0 0;
    font-size: .75rem;
    text-align: right;
}

.byn-attribution a {
    color: var(--byn-text-2);
}

/* Compact layout */
.byn-compact-head {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: .5rem 1.25rem;
}

.byn-compact-temp {
    display: block;
    font-size: 3.2rem;
    font-weight: 800;
    line-height: 1;
}

.byn-compact-cond {
    display: block;
    margin-top: .25rem;
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--byn-strong);
}

.byn-compact-place {
    margin-left: auto;
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--byn-accent);
}

.byn-compact-facts {
    margin: .4rem 0 0;
    padding: 0;
    list-style: none;
    font-size: 1.05rem;
    line-height: 1.5;
}

.byn-compact-days {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(7.5rem, 1fr));
    gap: .5rem;
    margin: 1rem 0 0;
    padding: 0;
    list-style: none;
}
.byn-compact-days li {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: .6rem .4rem;
    border: 1px solid var(--byn-border);
    border-radius: .5rem;
    text-align: center;
}

.byn-compact-days .byn-day-name {
    font-weight: 700;
    font-size: 1.05rem;
}

.byn-compact-range {
    font-size: 1.25rem;
    font-weight: 700;
    white-space: nowrap;
}

.byn-compact-range .byn-day-min {
    color: var(--byn-text-2);
    font-weight: 400;
}
/* Minimal layout */
.byn-minimal {
    max-width: 22rem;
    margin-inline: auto;
    text-align: center;
}

.byn-minimal-place {
    margin: 0 0 .5rem;
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--byn-accent);
}

.byn-minimal-now {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: .5rem 1.5rem;
}

.byn-minimal-main {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.byn-minimal-temp {
    font-size: 2.6rem;
    font-weight: 800;
    line-height: 1.1;
}

.byn-minimal-facts {
    margin: 0;
    padding: 0;
    list-style: none;
    line-height: 1.5;
}

.byn-minimal-cond {
    font-weight: 700;
    color: var(--byn-strong);
}

.byn-minimal-days {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: .75rem 1.5rem;
    margin: 1.25rem 0 0;
    padding: 0;
    list-style: none;
}

.byn-minimal-days li {
    display: flex;
    flex-direction: column;
    align-items: center;
    min-width: 5rem;
}

.byn-minimal-range .byn-day-min {
    color: var(--byn-text-2);
}

.byn-minimal-alert {
    margin: 1.25rem 0 0;
    padding: .7rem .9rem;
    border: 1px solid transparent;
    border-radius: .5rem;
    text-align: left;
    font-size: .88rem;
}

.byn-minimal-alert.lv2 { background: #fff3c4; border-color: #e3c24a; color: #3b3000; }
.byn-minimal-alert.lv3 { background: #ffd9b0; border-color: #e38a2d; color: #3d1f00; }
.byn-minimal-alert.lv4 { background: #ffc4c4; border-color: #d94a4a; color: #4a0000; }

.byn-minimal-alert strong {
    font-size: 1rem;
}

.byn-minimal-valid {
    margin-top: .2rem;
}

.byn-minimal-alert details {
    margin-top: .35rem;
}

.byn-minimal-alert summary {
    cursor: pointer;
}

.byn-minimal-alert p {
    margin: .4rem 0 0;
}

.byn-minimal-source {
    margin-top: .75rem;
    text-align: center;
}
/* Table layout */
.byn-table-title {
    text-align: center;
}

.byn-table-wrap {
    max-height: 26rem;
    overflow: auto;
}

.byn-table {
    width: 100%;
    border-collapse: collapse;
    font-size: .9rem;
}

.byn-table th,
.byn-table td {
    padding: .4rem .5rem;
    text-align: center;
    vertical-align: middle;
    white-space: nowrap;
    border-bottom: 1px solid var(--byn-border);
}

.byn-table thead th {
    position: sticky;
    top: 0;
    z-index: 1;
    background: var(--byn-bg-2);
    color: var(--byn-strong);
}

.byn-table tbody tr:hover td {
    background: var(--byn-hover);
}

.byn-table .byn-table-day th {
    background: var(--byn-bg-3);
    color: var(--byn-accent);
    font-weight: 700;
}

.byn-table .byn-strong {
    font-weight: 700;
    color: var(--byn-strong);
}

.byn-table .byn-icon {
    margin: 0 auto;
}

.byn-wind-arrow {
    display: inline-block;
    color: var(--byn-accent);
}

.byn-sr {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
}

@media (max-width: 600px) {
    .byn-table thead {
        position: absolute;
        width: 1px;
        height: 1px;
        overflow: hidden;
        clip: rect(0 0 0 0);
    }

    .byn-table,
    .byn-table tbody,
    .byn-table tr,
    .byn-table td {
        display: block;
        width: 100%;
    }

    .byn-table tbody tr:not(.byn-table-day) {
        margin-bottom: .5rem;
        border: 1px solid var(--byn-border);
        border-radius: .4rem;
    }

    .byn-table td {
        display: flex;
        justify-content: space-between;
        align-items: center;
        text-align: right;
        padding: .3rem .75rem;
    }

    .byn-table td::before {
        content: attr(data-label);
        margin-right: 1rem;
        font-weight: 700;
        color: var(--byn-text-2);
    }

    .byn-table .byn-table-day,
    .byn-table .byn-table-day th {
        display: block;
    }
}

@media (max-width: 768px) {
    .byn-top {
        grid-template-columns: minmax(0, 1fr);
    }

    .byn-temp {
        font-size: 2.4rem;
    }
}

@media (prefers-reduced-motion: reduce) {
    .byn-hourly-scroll {
        scroll-behavior: auto;
    }
}

/* Overview layout */
.byn-ov-head {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: .75rem;
}

.byn-ov-now {
    display: flex;
    align-items: center;
    gap: .9rem;
}

.byn-ov-now > div {
    display: flex;
    flex-direction: column;
}

.byn-ov-place {
    font-size: .95rem;
    font-weight: 600;
    color: var(--byn-accent);
}

.byn-ov-temp {
    font-size: 2.6rem;
    font-weight: 800;
    line-height: 1.1;
}

.byn-ov-badge {
    display: inline-flex;
    align-items: center;
    gap: .4rem;
    padding: .35rem .8rem;
    border-radius: 999px;
    font-size: .82rem;
    font-weight: 700;
    color: #fff;
}

.byn-ov-badge.lv2, .byn-ov-seg.lv2 { background: #f5c518; color: #2b2300; }
.byn-ov-badge.lv3, .byn-ov-seg.lv3 { background: #ee7d11; color: #fff; }
.byn-ov-badge.lv4, .byn-ov-seg.lv4 { background: #d62b2b; color: #fff; }

.byn-ov-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(7.5rem, 1fr));
    gap: .5rem;
    margin: 1rem 0 0;
    padding: .75rem;
    list-style: none;
    border-radius: .7rem;
    background: var(--byn-bg-2);
}

.byn-ov-stats li {
    display: flex;
    flex-direction: column;
    gap: .1rem;
}

.byn-ov-stat-label {
    font-size: .75rem;
    color: var(--byn-text-2);
}

.byn-ov-days {
    display: flex;
    gap: .5rem;
    margin: 0;
    overflow-x: auto;
    scrollbar-width: none;
}

.byn-ov-days::-webkit-scrollbar,
.byn-ov-scroll::-webkit-scrollbar {
    display: none;
}

.byn-ov-sw {
    position: relative;
}

.byn-ov-days-wrap {
    margin-top: 1rem;
}

.byn-ov > .byn-ov-sw {
    margin-top: 1rem;
}

.byn-ov-arrow {
    position: absolute;
    top: 50%;
    z-index: 3;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 2rem;
    height: 2rem;
    padding: 0;
    transform: translateY(-50%);
    border: 1px solid var(--byn-border);
    border-radius: 50%;
    background: var(--byn-bg);
    color: var(--byn-strong);
    box-shadow: 0 2px 6px rgba(0, 0, 0, .4);
    cursor: pointer;
    opacity: .92;
}

.byn-ov-arrow[hidden] {
    display: none;
}

.byn-ov-arrow:hover,
.byn-ov-arrow:focus-visible {
    background: var(--byn-accent);
    opacity: 1;
}

.byn-ov-arrow.is-left { left: .25rem; }
.byn-ov-arrow.is-right { right: .25rem; }

.is-dragging {
    cursor: grabbing;
    user-select: none;
}

.byn-ov-days, .byn-ov-scroll {
    cursor: grab;
}

.byn-ov-sun {
    position: absolute;
    z-index: 2;
    display: inline-flex;
    align-items: center;
    gap: .25rem;
    transform: translateX(-50%);
    padding: .1rem .4rem;
    border-radius: 999px;
    background: rgba(0, 0, 0, .4);
    font-size: .72rem;
    font-weight: 700;
    white-space: nowrap;
}

.byn-ov-sun.is-sun { bottom: .15rem; }
.byn-ov-sun.is-moon { top: .15rem; }
.byn-ov-sun.is-sun .fa-sun { color: #ffc83d; }
.byn-ov-sun .fa-arrow-up { color: #7ee787; }
.byn-ov-sun .fa-arrow-down { color: #ff9f5a; }
.byn-ov-sun svg { display: block; }

.byn-moon-dark { fill: rgba(255, 255, 255, .15); }
.byn-moon-lit { fill: #ffd86b; }

.byn-ov-day {
    flex: 1 0 5.5rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: .2rem;
    padding: .55rem .4rem;
    border: 1px solid var(--byn-border);
    border-radius: .7rem .7rem 0 0;
    background: var(--byn-bg-3);
    color: var(--byn-text);
    font: inherit;
    cursor: pointer;
}

.byn-ov-day.is-active {
    background: var(--byn-bg-2);
    border-color: var(--byn-accent);
    border-bottom-color: var(--byn-bg-2);
}

.byn-ov-day:focus-visible {
    outline: 2px solid var(--byn-accent);
    outline-offset: 1px;
}

.byn-ov-day-head {
    display: flex;
    justify-content: space-between;
    width: 100%;
    font-size: .8rem;
    color: var(--byn-text-2);
}

.byn-ov-day-head strong {
    color: var(--byn-text);
}

.byn-ov-day-temps strong {
    font-size: 1.45rem;
    line-height: 1.2;
}

.byn-ov-day-temps span {
    font-size: 1.1rem;
    color: var(--byn-text-2);
}

.byn-ov-panel {
    padding: .75rem 0 .25rem;
    border-radius: 0 0 .7rem .7rem;
    background: var(--byn-bg-2);
}

.byn-ov-panel[hidden] {
    display: none;
}

.byn-ov-scroll {
    overflow-x: auto;
    scrollbar-width: none;
    padding: 0 .5rem .5rem;
}

/* Scrollers must not widen their parents (flex/grid templates): zero intrinsic width, full available width */
.byn-ov-scroll,
.byn-ov-days {
    width: 0;
    min-width: 100%;
}

.byn-ov {
    min-width: 0;
    max-width: 100%;
}

.byn-ov-grid {
    min-width: calc(var(--n) * 3.6rem);
}

.byn-ov-cols {
    display: grid;
    grid-template-columns: repeat(var(--n), minmax(0, 1fr));
    gap: .2rem;
}

.byn-ov-col {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: .15rem;
    font-size: .8rem;
}

.byn-ov-time {
    color: var(--byn-text-2);
    font-size: .75rem;
}

.byn-ov-val {
    font-weight: 700;
}

.byn-ov-curve {
    position: relative;
    height: 7.5rem;
    margin: .4rem 0;
    color: var(--byn-accent);
}

.byn-ov-curve svg {
    display: block;
    width: 100%;
    height: 100%;
    overflow: visible;
}

.byn-ov-line {
    fill: none;
    stroke: currentColor;
    stroke-width: 2px;
}

.byn-ov-press {
    fill: none;
    stroke: var(--byn-text-2);
    stroke-width: 1px;
    opacity: .85;
}

.byn-ov-pkey {
    display: flex;
    align-items: center;
    gap: .4rem;
    font-size: .72rem;
    color: var(--byn-text-2);
}

.byn-ov-pkey-line {
    display: inline-block;
    width: 1.6rem;
    border-top: 1px solid var(--byn-text-2);
}

.byn-ov-zero {
    stroke: var(--byn-text-2);
    stroke-width: 1px;
    stroke-dasharray: 4 4;
    opacity: .6;
}

.byn-ov-dot {
    position: absolute;
    width: .6rem;
    height: .6rem;
    margin: -.3rem 0 0 -.3rem;
    border-radius: 50%;
    background: var(--byn-bg-2);
    border: 2px solid currentColor;
}

.byn-ov-dot.is-now {
    width: .85rem;
    height: .85rem;
    margin: -.425rem 0 0 -.425rem;
    background: #fff;
}

.byn-ov-row-title {
    margin: .6rem 0 .2rem;
    font-size: .72rem;
    letter-spacing: .03em;
    text-transform: uppercase;
    color: var(--byn-text-2);
}

.byn-ov-cell {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: .2rem;
    min-height: 1.7rem;
    border-radius: .4rem;
    font-size: .8rem;
    font-weight: 600;
}

.byn-ov-windrow .byn-ov-cell {
    background: var(--byn-hover);
}

.byn-ov-rain .rain0 { background: var(--byn-hover); color: var(--byn-text-2); font-weight: 400; }
.byn-ov-rain .rain1 { background: #2f6f9e; color: #fff; }
.byn-ov-rain .rain2 { background: #1f5fc4; color: #fff; }
.byn-ov-rain .rain3 { background: #1a3fa8; color: #fff; }
.byn-ov-rain .rain4 { background: #3a1d8f; color: #fff; }

.byn-ov-seg {
    display: flex;
    align-items: center;
    gap: .35rem;
    min-width: 0;
    min-height: 1.9rem;
    padding: 0 .6rem;
    border-radius: .4rem;
    font-size: .78rem;
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.byn-ov-seg.none {
    justify-content: center;
    background: repeating-linear-gradient(135deg, var(--byn-hover), var(--byn-hover) 4px, transparent 4px, transparent 8px);
    color: var(--byn-text-2);
    font-weight: 400;
}

@media (max-width: 600px) {
    .byn-ov-temp {
        font-size: 2.1rem;
    }

    .byn-ov-grid {
        min-width: calc(var(--n) * 3.2rem);
    }
}

/* Full layout */
.byn-fl {
    min-width: 0;
    max-width: 100%;
}

.byn-fl-hero {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 17rem), 1fr));
    gap: 1rem;
    padding: 1.25rem;
    border: 1px solid var(--byn-border);
    border-radius: 1rem;
    background:
        radial-gradient(circle at 12% 0%, color-mix(in srgb, var(--byn-accent) 30%, transparent), transparent 60%),
        linear-gradient(135deg, var(--byn-bg-2), var(--byn-bg-3));
}

.byn-fl-now {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: .5rem 1.25rem;
}

.byn-fl-icon {
    width: min(180px, 42vw);
    filter: drop-shadow(0 6px 14px rgba(0, 0, 0, .25));
}

.byn-fl-place {
    margin-bottom: .25rem;
    color: var(--byn-text-2);
    font-weight: 600;
}

.byn-fl-temp {
    font-size: clamp(3rem, 9vw, 4.75rem);
    font-weight: 800;
    line-height: 1;
}

.byn-fl-cond {
    margin-top: .3rem;
    color: var(--byn-strong);
    font-size: 1.3rem;
    font-weight: 700;
}

.byn-fl-hilo {
    display: flex;
    gap: 1rem;
    margin-top: .4rem;
    color: var(--byn-strong);
    font-size: 1.15rem;
    font-weight: 600;
}

.byn-fl-hilo .fa-solid {
    color: var(--byn-accent);
    font-size: .9rem;
}

.byn-fl-sky {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: .4rem;
    padding: .75rem 1rem;
    border-radius: .85rem;
    background: var(--byn-hover);
}

.byn-fl-arc {
    display: block;
    width: 100%;
    max-width: 22rem;
    margin-inline: auto;
}

.byn-fl-arc-track {
    fill: none;
    stroke: var(--byn-text-2);
    stroke-width: 2;
    stroke-dasharray: 4 5;
    opacity: .5;
}

.byn-fl-arc-done {
    fill: none;
    stroke: #ffc107;
    stroke-width: 3;
    stroke-linecap: round;
}

.byn-fl-sun { fill: #ffc107; }
.byn-fl-sun-glow { fill: #ffc107; opacity: .3; }
.byn-fl-moonarc-track {
    fill: none;
    stroke: #9fb4d9;
    stroke-width: 1.5;
    stroke-dasharray: 3 5;
    opacity: .6;
}

.byn-fl-moonarc-done {
    fill: none;
    stroke: #9fb4d9;
    stroke-width: 2.5;
    stroke-linecap: round;
}

.byn-fl-moon-glow { fill: #9fb4d9; opacity: .3; }
.byn-fl-horizon {
 stroke: var(--byn-text-2); stroke-width: 1; opacity: .5; }

.byn-fl-sun-times {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: .5rem;
    font-weight: 600;
}

.byn-fl-sun-times .fa-sun {
    color: #f5b301;
}

.byn-fl-sun-times .fa-arrow-up,
.byn-fl-sun-times .fa-arrow-down,
.byn-fl-moon .fa-arrow-up,
.byn-fl-moon .fa-arrow-down {
    margin-left: .15rem;
    font-size: .7rem;
}

.byn-fl-daylen {
    color: var(--byn-text-2);
    font-size: .9rem;
    font-weight: 400;
}

.byn-fl-moon {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: .25rem .75rem;
    padding-top: .45rem;
    border-top: 1px solid var(--byn-border);
    color: var(--byn-text-2);
    font-size: .9rem;
}

.byn-fl .byn-moon-dark {
    fill: rgba(128, 128, 128, .4);
}

.byn-fl-alert {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: .4rem .75rem;
    margin-top: .75rem;
    padding: .55rem .75rem;
    border: 1px solid var(--byn-border);
    border-radius: .7rem;
    background: var(--byn-bg-2);
}

.byn-fl-alert-text {
    color: var(--byn-text-2);
    font-size: .9rem;
}

.byn-fl-tiles {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(9.5rem, 1fr));
    gap: .6rem;
    margin: .9rem 0 0;
    padding: 0;
    list-style: none;
}

.byn-fl-tile {
    display: grid;
    grid-template-columns: auto 1fr;
    align-items: center;
    gap: .15rem .5rem;
    padding: .65rem .8rem;
    border: 1px solid var(--byn-border);
    border-radius: .8rem;
    background: var(--byn-bg-2);
    cursor: help;
}

.byn-fl-tile-icon {
    color: var(--byn-accent);
    text-align: center;
}

.byn-fl-tile-label {
    min-width: 0;
    color: var(--byn-text-2);
    font-size: .8rem;
}

.byn-fl-tile-value {
    grid-column: 1 / -1;
    color: var(--byn-strong);
    font-size: 1.35rem;
    line-height: 1.3;
}

.byn-fl-tile-value small {
    color: var(--byn-text-2);
    font-size: .8rem;
    font-weight: 400;
}

.byn-fl-meter {
    display: block;
    height: .35rem;
    margin-top: .3rem;
    overflow: hidden;
    border-radius: 1rem;
    background: var(--byn-hover);
}

.byn-fl-meter i {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: var(--byn-accent);
}

.byn-fl-trend {
    margin-left: .4rem;
    color: var(--byn-accent);
    font-size: .9rem;
}

.byn-fl-daysw {
    margin-top: 1rem;
}

.byn-fl-days,
.byn-fl-hours {
    display: flex;
    gap: .6rem;
    width: 0;
    min-width: 100%;
    overflow-x: auto;
    padding: .2rem;
    scrollbar-width: none;
    cursor: grab;
}

.byn-fl-days::-webkit-scrollbar,
.byn-fl-hours::-webkit-scrollbar {
    display: none;
}

.byn-fl-day {
    flex: 1 0 8.5rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: .25rem;
    padding: .8rem .6rem;
    border: 2px solid transparent;
    border-radius: .9rem;
    background: var(--byn-bg-2);
    color: var(--byn-strong);
    font: inherit;
    text-align: center;
}

button.byn-fl-day {
    cursor: pointer;
    transition: background-color .2s, border-color .2s, transform .2s;
}

button.byn-fl-day:hover {
    background: var(--byn-bg-3);
}

button.byn-fl-day:focus-visible,
.byn-fl-day.is-active {
    border-color: var(--byn-accent);
    background: var(--byn-bg-3);
}

.byn-fl-day.is-active {
    box-shadow: 0 4px 14px rgba(0, 0, 0, .2);
}

.byn-fl-day-name {
    font-size: 1.05rem;
    font-weight: 700;
}

.byn-fl-day-date {
    color: var(--byn-text-2);
    font-size: .8rem;
}

.byn-fl-range {
    font-size: 1.25rem;
    font-weight: 700;
    white-space: nowrap;
}

.byn-fl-low,
.byn-fl-sep {
    color: var(--byn-text-2);
    font-weight: 400;
}

.byn-fl-bar {
    position: relative;
    width: 80%;
    height: .4rem;
    border-radius: 1rem;
    background: var(--byn-hover);
}

.byn-fl-bar i {
    position: absolute;
    top: 0;
    bottom: 0;
    border-radius: inherit;
    background: linear-gradient(90deg, #4fc3f7, #ffb74d, #ff7043);
}

.byn-fl-day-meta {
    display: flex;
    align-items: center;
    gap: .5rem;
    font-size: .85rem;
}

.byn-fl-day-meta .has-rain { color: var(--byn-rain); font-weight: 600; }
.byn-fl-day-meta .is-dry { color: var(--byn-text-2); opacity: .7; }

.byn-fl-day-alert {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 1.5rem;
    height: 1.5rem;
    border-radius: 50%;
    font-size: .75rem;
}

.byn-fl-day-alert.lv2 { background: #f5c518; color: #2b2300; }
.byn-fl-day-alert.lv3 { background: #ee7d11; color: #fff; }
.byn-fl-day-alert.lv4 { background: #d62b2b; color: #fff; }

.byn-fl-panel {
    margin-top: .75rem;
    padding: .9rem;
    border: 1px solid var(--byn-border);
    border-radius: 1rem;
    background: var(--byn-bg-2);
}

.byn-fl-panel[hidden] {
    display: none;
}

.byn-fl-panel-head {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: .5rem 1rem;
}

.byn-fl-panel-title {
    margin: 0;
    color: var(--byn-strong);
    font-size: 1.15rem;
}

.byn-fl-chips {
    display: flex;
    flex-wrap: wrap;
    gap: .4rem;
    margin: 0;
    padding: 0;
    list-style: none;
}

.byn-fl-chips li {
    padding: .25rem .7rem;
    border: 1px solid var(--byn-border);
    border-radius: 1rem;
    background: var(--byn-hover);
    font-size: .9rem;
    white-space: nowrap;
}

.byn-fl-chips .fa-solid {
    color: var(--byn-accent);
}

.byn-fl-hours {
    margin-top: .75rem;
}

.byn-fl-hour {
    flex: 0 0 5.4rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: .25rem;
    padding: .6rem .3rem;
    border: 1px solid var(--byn-border);
    border-radius: .85rem;
    background: var(--byn-bg);
    font-size: .85rem;
}

.byn-fl-hour.is-night {
    background: var(--byn-bg-3);
}

.byn-fl-hour.is-now {
    border-color: var(--byn-accent);
    box-shadow: 0 0 0 1px var(--byn-accent);
}

.byn-fl-hour-time {
    color: var(--byn-strong);
    font-weight: 700;
}

.byn-fl-hour-temp {
    font-size: 1.15rem;
    font-weight: 700;
}

.byn-fl-hour-feels,
.byn-fl-hour-wind {
    color: var(--byn-text-2);
    white-space: nowrap;
}

.byn-fl-rain {
    display: flex;
    align-items: flex-end;
    width: .9rem;
    height: 2.4rem;
    overflow: hidden;
    border-radius: .3rem;
    background: var(--byn-hover);
}

.byn-fl-rain i {
    display: block;
    width: 100%;
    background: var(--byn-rain);
}

.byn-fl-hour-rain {
    color: var(--byn-rain);
    font-weight: 600;
    white-space: nowrap;
}

.byn-fl-hour-rain.is-dry {
    color: var(--byn-text-2);
    font-weight: 400;
    opacity: .6;
}

.byn-fl-dir {
    display: inline-block;
    color: var(--byn-accent);
    font-size: .8rem;
}

.byn-weather.fx-none { box-shadow: none; }

/* Effects */
.byn-weather.fx-shadow { box-shadow: 0 4px 12px rgba(0, 0, 0, .25); }
.byn-weather.fx-gradient { background: linear-gradient(145deg, var(--byn-bg), var(--byn-bg-2)); }
.byn-weather.fx-glass {
    background: color-mix(in srgb, var(--byn-bg) 55%, transparent);
    border: 1px solid var(--byn-border);
    -webkit-backdrop-filter: blur(12px) saturate(140%);
    backdrop-filter: blur(12px) saturate(140%);
}
.byn-weather.fx-glow { box-shadow: 0 0 0 1px color-mix(in srgb, var(--byn-accent) 45%, transparent), 0 0 22px color-mix(in srgb, var(--byn-accent) 35%, transparent); }
.byn-weather.fx-accent { border-top: 4px solid var(--byn-accent); }
.byn-weather.fx-animated {
    background: linear-gradient(120deg, var(--byn-bg), var(--byn-bg-2), color-mix(in srgb, var(--byn-accent) 30%, var(--byn-bg)), var(--byn-bg-2), var(--byn-bg));
    background-size: 300% 300%;
    animation: byn-shift 16s ease-in-out infinite;
}

@keyframes byn-shift {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}

@media (prefers-reduced-motion: reduce) {
    .byn-weather.fx-animated { animation: none; }
}