/* =======================================================
   SOFON WEATHER – CONTINUOUS ATMOSPHERE ENGINE v1
   Fáze 10: plynulý denní cyklus + oblačnost 0–100 %.
======================================================= */

.atmosphere-layer {
    position: fixed;
    inset: 0;

    z-index: -2;

    overflow: hidden;
    pointer-events: none;

    opacity: 0;

    background: transparent;

    transition:
        opacity 1100ms ease;

    contain: strict;
}

.atmosphere-canvas {
    display: block;

    width: 100%;
    height: 100%;

    transform: scale(1.012);
    transform-origin: center;
}

body[data-atmosphere="active"][data-effects="enabled"]
.atmosphere-layer {
    opacity: 1;
}

/*
 * Atmosphere Engine přebírá oblačnost. Původní gradientová
 * cloud layer zůstává v kódu jako plný fallback pro WebGL chybu.
 */
body[data-atmosphere="active"]
.weather-cloud-layer {
    opacity: 0;
}

body[data-atmosphere="active"]
.weather-cloud-layer::before,
body[data-atmosphere="active"]
.weather-cloud-layer::after {
    animation-play-state: paused;
}

/*
 * Původní CSS obloha je pod neprůhledným WebGL plátnem.
 * Její animace proto při aktivním enginu zastavujeme kvůli výkonu,
 * ale samotná vrstva zůstává připravená pro okamžitý fallback.
 */
body[data-atmosphere="active"]
.background-layer,
body[data-atmosphere="active"]
.background-layer::before,
body[data-atmosphere="active"]
.background-layer::after {
    animation-play-state: paused;
}

body[data-effects="disabled"]
.atmosphere-layer,
body[data-atmosphere="disabled"]
.atmosphere-layer,
body[data-atmosphere="fallback"]
.atmosphere-layer {
    opacity: 0;
}

@media (prefers-reduced-motion: reduce) {
    .atmosphere-layer {
        transition: none;
    }
}
