/* Import Bootstrap Icons */
/*@import url('https://cdnjs.cloudflare.com/ajax/libs/bootstrap-icons/1.10.5/font/bootstrap-icons.min.css');*/

html, body {
    font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
}

body {
    background: linear-gradient(270deg, #edf4ff, #82e0ff, #91f6ef, #d0e9ff);
    background-size: 300% 300%;
    animation: waveColors 15s ease-in-out infinite;
    min-height: 100vh;
    text-shadow: 1px 1px 3px #474747, 0px 0px 1px #797979;
}

.background-title {
    background: #61d1e67d;
    border-radius: 4px;
    -webkit-box-shadow: inset 0px 0px 10px 0px rgb(75 206 249);
    -moz-box-shadow: inset 0px 0px 10px 0px rgb(75 206 249);
    box-shadow: inset 0px 0px 10px 0px rgb(75 206 249);
}

    .background-title h1, h2 {
        color: #76c7ff;
        color: #2ccbe9;
        text-transform: uppercase;
    }

.laguna-font {
    color: #2ccbe9 !important;
}

.app-btn {
    background: #0f5c89;
    border-color: #98c9ed;
    
    box-shadow: 0 3px 18px rgba(0, 121, 194, 0.35), 0 0 0 1px rgba(138, 181, 214, 0.35) inset;
    color: #dfe6f5;
    cursor: pointer;
    transition: transform 120ms ease, box-shadow 120ms ease, background 120ms ease, border-color 120ms ease;
}

    .app-btn:hover {
        transform: translateY(-1px) scale(1.03);
        box-shadow: 0 6px 12px rgba(0, 121, 194, 0.25), 0 0 0 1px rgba(120, 149, 208, 0.4);
        background: #18b7d5;
        border-color: #10a2bd;
        color: #e2fbfd;
    }

.text-app-color {
    color: #08537b !important;
}

.app-panels-Ai {
    border-radius: 14px;
    -webkit-box-shadow: inset 3px -2px 14px 5px rgb(6 141 209 / 68%);
    -moz-box-shadow: inset 3px -2px 14px 5px rgb(6 141 209 / 68%);
    box-shadow: inset 3px -2px 14px 5px rgb(6 141 209 / 68%);
}

.app-panels-homes {
    border-radius: 14px;
    -webkit-box-shadow: inset 0px -1px 10px 4px rgb(6 50 209 / 68%);
    -moz-box-shadow: inset 0px -1px 10px 4px rgb(6 50 209 / 68%);
    box-shadow: inset 0px -1px 10px 4px rgb(6 50 209 / 68%);
}

.app-panels-Apps {
    background: #142947;
    border: 2px solid #19263f;
    border-radius: 14px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    -webkit-box-shadow: inset 3px -2px 14px 5px rgb(6 141 209 / 68%);
    -moz-box-shadow: inset 3px -2px 14px 5px rgb(6 141 209 / 68%);
    box-shadow: inset 3px -2px 14px 5px rgb(6 141 209 / 68%);
}

/* === Bezpieczny wrapper: nic nie rozpycha DOM, animacja tylko wewnątrz === */
.crazy-card {
    position: relative;
    display: inline-block;
    overflow: hidden; /* żeby efekty nie wychodziły poza kartę */
    border-radius: 16px; /* dopasuj do swoich rounded */
    isolation: isolate; /* własny stacking context */
    contain: layout paint; /* izolacja od reszty layoutu */
    transform: translateZ(0); /* wymuszenie kompozycji GPU */
    will-change: transform;
}

/* Upewniamy się, że picture zachowuje się przewidywalnie */
.crazy-media {
    display: block;
    position: relative;
}

/* Sam obraz animujemy tylko transform/filter -> nie wpływa na layout */
.crazy-img {
    display: block;
    width: 100%;
    height: auto;
    transform-origin: 50% 50%;
    will-change: transform, filter;
    backface-visibility: hidden;
    /* spokojna animacja w tle */
    animation: calmFloat 8s ease-in-out infinite;
    transition: filter 250ms ease, transform 250ms ease;
}

/* Delikatny “oddech” w tle */
@keyframes calmFloat {
    0% {
        transform: translate3d(0,0,0) scale(1) rotate(0deg);
        filter: saturate(1) contrast(1);
    }

    25% {
        transform: translate3d(0,-6px,0) scale(1.01) rotate(-0.25deg);
        filter: saturate(1.05) contrast(1.02);
    }

    50% {
        transform: translate3d(0,0,0) scale(1.015) rotate(0.15deg);
        filter: saturate(1.02) contrast(1.00);
    }

    75% {
        transform: translate3d(0,5px,0) scale(1.01) rotate(0.1deg);
        filter: saturate(1.06) contrast(1.03);
    }

    100% {
        transform: translate3d(0,0,0) scale(1) rotate(0deg);
        filter: saturate(1) contrast(1);
    }
}

/* === Efekty "odjechane" jako overlay, bez wpływu na layout === */
.crazy-card::before,
.crazy-card::after {
    content: "";
    position: absolute;
    inset: -20%;
    pointer-events: none;
    opacity: 0;
    mix-blend-mode: screen;
    will-change: transform, opacity, filter;
}

/* Lekki "neonowy" gradient / flare */
.crazy-card::before {
    background: radial-gradient(circle at 30% 20%, rgba(0,255,255,.35), transparent 55%), radial-gradient(circle at 70% 60%, rgba(255,0,200,.25), transparent 60%), linear-gradient(120deg, transparent 35%, rgba(255,255,255,.18), transparent 65%);
    filter: blur(8px) saturate(1.4);
}

/* Glitch stripes */
.crazy-card::after {
    background: repeating-linear-gradient( 0deg, rgba(255,255,255,.06) 0px, rgba(255,255,255,.06) 2px, transparent 2px, transparent 7px );
    filter: blur(0.5px);
    transform: translate3d(0,0,0);
}

/* === HOVER: spokojna animacja stop, odpalamy szaleństwo === */
.crazy-card:hover .crazy-img {
    animation: insaneWarp 900ms linear infinite;
    filter: saturate(1.35) contrast(1.25) hue-rotate(12deg);
}

/* "Odjazd": szybkie mikroprzesunięcia + skale + rotacje (transform-only) */
@keyframes insaneWarp {
    0% {
        transform: translate3d(0,0,0) scale(1.02) rotate(0deg) skew(0deg);
    }

    10% {
        transform: translate3d(-3px,1px,0) scale(1.05) rotate(-0.8deg) skew(-0.3deg);
    }

    20% {
        transform: translate3d(4px,-2px,0) scale(1.03) rotate(1.2deg) skew(0.2deg);
    }

    30% {
        transform: translate3d(-2px,-4px,0) scale(1.06) rotate(-1.5deg) skew(0.6deg);
    }

    40% {
        transform: translate3d(6px,3px,0) scale(1.04) rotate(1.0deg) skew(-0.4deg);
    }

    50% {
        transform: translate3d(-5px,2px,0) scale(1.07) rotate(-1.8deg) skew(0.8deg);
    }

    60% {
        transform: translate3d(3px,-3px,0) scale(1.04) rotate(1.6deg) skew(-0.2deg);
    }

    70% {
        transform: translate3d(-2px,4px,0) scale(1.06) rotate(-1.1deg) skew(0.4deg);
    }

    80% {
        transform: translate3d(5px,0px,0) scale(1.03) rotate(1.4deg) skew(-0.6deg);
    }

    90% {
        transform: translate3d(-4px,-1px,0) scale(1.05) rotate(-0.9deg) skew(0.3deg);
    }

    100% {
        transform: translate3d(0,0,0) scale(1.02) rotate(0deg) skew(0deg);
    }
}

.crazy-card:hover::before {
    opacity: 1;
    animation: flareDance 700ms ease-in-out infinite;
}

.crazy-card:hover::after {
    opacity: .85;
    animation: glitchScan 220ms steps(2) infinite;
}

/* Overlay "tańczy" */
@keyframes flareDance {
    0% {
        transform: translate3d(-2%, -1%, 0) rotate(0deg) scale(1.02);
    }

    50% {
        transform: translate3d(2%, 1%, 0) rotate(1.2deg) scale(1.08);
    }

    100% {
        transform: translate3d(-1%, 2%, 0) rotate(-0.8deg) scale(1.03);
    }
}

/* Szybkie przesuwanie pasków glitch */
@keyframes glitchScan {
    0% {
        transform: translate3d(0,-2%,0);
    }

    50% {
        transform: translate3d(0, 2%,0);
    }

    100% {
        transform: translate3d(0,-1%,0);
    }
}

/* Dostępność: jak ktoś ma wyłączone animacje */
@media (prefers-reduced-motion: reduce) {
    .crazy-img,
    .crazy-card::before,
    .crazy-card::after {
        animation: none !important;
        transition: none !important;
    }
}



    @keyframes waveColors {
        0% {
            background-position: 0% 50%;
        }

        50% {
            background-position: 100% 50%;
        }

        100% {
            background-position: 0% 50%;
        }
    }

    @keyframes zoomBackground {
        0% {
            background-size: 100% 100%;
        }

        50% {
            background-size: 190% 150%;
        }

        100% {
            background-size: 100% 100%;
        }
    }

    .sidebar {
        background-image: linear-gradient(180deg, rgb(58 120 153) 10%, #865293 60%);
        background-repeat: no-repeat;
        background-size: 100% 100%;
        animation: zoomBackground 9s ease-in-out infinite;
    }

    a, .btn-link {
        color: #006bb7;
    }

    .btn-primary {
        color: #fff;
        background-color: #1b6ec2;
        border-color: #1861ac;
    }

    .btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-check-input:focus {
        box-shadow: 0 0 0 0.1rem white, 0 0 0 0.25rem #258cfb;
    }

    .content {
        padding-top: 1.1rem;
    }

    h1:focus {
        outline: none;
    }

    .valid.modified:not([type=checkbox]) {
        outline: 1px solid #26b050;
    }

    .invalid {
        outline: 1px solid #e50000;
    }

    .validation-message {
        color: #e50000;
    }

    .blazor-error-boundary {
        background: url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNTYiIGhlaWdodD0iNDkiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIG92ZXJmbG93PSJoaWRkZW4iPjxkZWZzPjxjbGlwUGF0aCBpZD0iY2xpcDAiPjxyZWN0IHg9IjIzNSIgeT0iNTEiIHdpZHRoPSI1NiIgaGVpZ2h0PSI0OSIvPjwvY2xpcFBhdGg+PC9kZWZzPjxnIGNsaXAtcGF0aD0idXJsKCNjbGlwMCkiIHRyYW5zZm9ybT0idHJhbnNsYXRlKC0yMzUgLTUxKSI+PHBhdGggZD0iTTI2My41MDYgNTFDMjY0LjcxNyA1MSAyNjUuODEzIDUxLjQ4MzcgMjY2LjYwNiA1Mi4yNjU4TDI2Ny4wNTIgNTIuNzk4NyAyNjcuNTM5IDUzLjYyODMgMjkwLjE4NSA5Mi4xODMxIDI5MC41NDUgOTIuNzk1IDI5MC42NTYgOTIuOTk2QzI5MC44NzcgOTMuNTEzIDI5MSA5NC4wODE1IDI5MSA5NC42NzgyIDI5MSA5Ny4wNjUxIDI4OS4wMzggOTkgMjg2LjYxNyA5OUwyNDAuMzgzIDk5QzIzNy45NjMgOTkgMjM2IDk3LjA2NTEgMjM2IDk0LjY3ODIgMjM2IDk0LjM3OTkgMjM2LjAzMSA5NC4wODg2IDIzNi4wODkgOTMuODA3MkwyMzYuMzM4IDkzLjAxNjIgMjM2Ljg1OCA5Mi4xMzE0IDI1OS40NzMgNTMuNjI5NCAyNTkuOTYxIDUyLjc5ODUgMjYwLjQwNyA1Mi4yNjU4QzI2MS4yIDUxLjQ4MzcgMjYyLjI5NiA1MSAyNjMuNTA2IDUxWk0yNjMuNTg2IDY2LjAxODNDMjYwLjczNyA2Ni4wMTgzIDI1OS4zMTMgNjcuMTI0NSAyNTkuMzEzIDY5LjMzNyAyNTkuMzEzIDY5LjYxMDIgMjU5LjMzMiA2OS44NjA4IDI1OS4zNzEgNzAuMDg4N0wyNjEuNzk1IDg0LjAxNjEgMjY1LjM4IDg0LjAxNjEgMjY3LjgyMSA2OS43NDc1QzI2Ny44NiA2OS43MzA5IDI2Ny44NzkgNjkuNTg3NyAyNjcuODc5IDY5LjMxNzkgMjY3Ljg3OSA2Ny4xMTgyIDI2Ni40NDggNjYuMDE4MyAyNjMuNTg2IDY2LjAxODNaTTI2My41NzYgODYuMDU0N0MyNjEuMDQ5IDg2LjA1NDcgMjU5Ljc4NiA4Ny4zMDA1IDI1OS43ODYgODkuNzkyMSAyNTkuNzg2IDkyLjI4MzcgMjYxLjA0OSA5My41Mjk1IDI2My41NzYgOTMuNTI5NSAyNjYuMTE2IDkzLjUyOTUgMjY3LjM4NyA5Mi4yODM3IDI2Ny4zODcgODkuNzkyMSAyNjcuMzg3IDg3LjMwMDUgMjY2LjExNiA4Ni4wNTQ3IDI2My41NzYgODYuMDU0N1oiIGZpbGw9IiNGRkU1MDAiIGZpbGwtcnVsZT0iZXZlbm9kZCIvPjwvZz48L3N2Zz4=) no-repeat 1rem/1.8rem, #b32121;
        padding: 1rem 1rem 1rem 3.7rem;
        color: white;
    }

        .blazor-error-boundary::after {
            content: "An error has occurred."
        }

    .darker-border-checkbox.form-check-input {
        border-color: #929292;
    }

    .form-floating > .form-control-plaintext::placeholder, .form-floating > .form-control::placeholder {
        color: var(--bs-secondary-color);
        text-align: end;
    }

    .form-floating > .form-control-plaintext:focus::placeholder, .form-floating > .form-control:focus::placeholder {
        text-align: start;
    }

    section {
        padding-top: 40px;
        padding-bottom: 40px;
        text-align: center;
    }

    ul {
        list-style: none;
    }
    /* Blazor reconnect modal — ensure visible and branded on all pages */
    #components-reconnect-modal.components-reconnect-show {
        display: flex !important;
        position: fixed;
        inset: 0;
        z-index: 10000;
        align-items: center;
        justify-content: center;
        background: rgba(0, 20, 40, 0.75);
        backdrop-filter: blur(4px);
        color: #0b2b4a;
        text-shadow: 1px 1px 2px #dfeeff;
    }

    #components-reconnect-modal .reconnect-modal {
        background: #f9fcff;
        border-radius: 14px;
        padding: 24px 28px 28px;
        box-shadow: 0 18px 42px rgba(0, 61, 122, 0.35), 0 0 0 1px rgba(157, 195, 255, 0.4);
        min-width: 320px;
        max-width: 520px;
        text-align: center;
        display: grid;
        gap: 14px;
        place-items: center;
    }

    #components-reconnect-modal .reconnect-title {
        font-size: 1.15rem;
        font-weight: 700;
        color: #0b2b4a;
    }

    #components-reconnect-modal .reconnect-message {
        color: #2d4563;
        font-size: 0.98rem;
    }
    /* Simple spinner ring */
    #components-reconnect-modal .reconnect-spinner {
        width: 72px;
        height: 72px;
        border-radius: 50%;
        border: 6px solid #dcecff;
        border-top-color: #61b5ff;
        animation: reconnect-spin 1s linear infinite;
    }

    @keyframes reconnect-spin {
        to {
            transform: rotate(360deg);
        }
    }

.cookie-notice {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 18px;
    display: flex;
    justify-content: center;
    padding: 0 16px;
    z-index: 1200;
    pointer-events: none;
}

.cookie-notice__card {
    background: rgba(10, 34, 58, 0.92);
    color: #e9f6ff;
    border-radius: 14px;
    box-shadow: 0 14px 38px rgba(0, 51, 102, 0.35), 0 0 0 1px rgba(98, 171, 220, 0.4);
    padding: 16px 18px;
    width: 100%;
    max-width: 960px;
    display: flex;
    gap: 16px;
    align-items: center;
    justify-content: space-between;
    backdrop-filter: blur(6px);
    pointer-events: auto;
}

.cookie-notice__content {
    display: grid;
    gap: 6px;
    text-align: left;
}

.cookie-notice__actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
}

.cookie-notice__title {
    font-weight: 700;
    font-size: 1.05rem;
    color: #8ee0ff;
    letter-spacing: 0.02em;
    text-transform: uppercase;
}

.cookie-notice__text {
    font-size: 0.95rem;
    line-height: 1.45;
    color: #d2e9ff;
}

.cookie-notice__links {
    display: flex;
    gap: 8px;
    align-items: center;
    flex-wrap: wrap;
}

.cookie-notice__links a {
    color: #b8e7ff;
    font-weight: 600;
    text-decoration: underline;
}

.cookie-notice__dot {
    color: #69c7ff;
}

.cookie-notice__button {
    background: linear-gradient(135deg, #1c86d1, #1aa6e8);
    border: none;
    color: #f6fbff;
    padding: 10px 16px;
    border-radius: 10px;
    font-weight: 700;
    box-shadow: 0 10px 20px rgba(0, 122, 204, 0.25), 0 0 0 1px rgba(110, 190, 255, 0.4);
    min-width: 88px;
    cursor: pointer;
    transition: transform 120ms ease, box-shadow 120ms ease, background 120ms ease;
}

.cookie-notice__button:hover {
    transform: translateY(-1px);
    box-shadow: 0 14px 26px rgba(0, 122, 204, 0.28), 0 0 0 1px rgba(110, 190, 255, 0.4);
}

@media (max-width: 768px) {
    .cookie-notice__card {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }

    .cookie-notice__button {
        width: 100%;
        text-align: center;
    }
}

@media (max-width: 480px) {
    .cookie-notice {
        bottom: 12px;
        padding: 0 12px;
    }

    .cookie-notice__card {
        padding: 14px 14px;
    }

    .cookie-notice__text {
        font-size: 0.9rem;
    }
}