.cookie-banner,
.cookie-dialog,
.cookie-revisit {
    font-family: "Manrope", "Segoe UI", Arial, sans-serif;
}

.cookie-banner[hidden],
.cookie-revisit[hidden] {
    display: none !important;
}

.cookie-banner {
    position: fixed;
    z-index: 1000;
    right: 22px;
    bottom: 22px;
    left: 22px;
    display: grid;
    width: min(1180px, calc(100% - 44px));
    max-height: calc(100vh - 44px);
    max-height: calc(100dvh - 44px);
    overflow: auto;
    overscroll-behavior: contain;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 30px;
    margin: 0 auto;
    padding: 22px 24px;
    color: #eaf7ff;
    background: #071f34;
    border: 1px solid rgba(126, 219, 255, 0.28);
    border-radius: 22px;
    box-shadow: 0 24px 70px rgba(0, 15, 29, 0.36);
}

.cookie-banner-copy {
    display: flex;
    min-width: 0;
    align-items: flex-start;
    gap: 16px;
}

.cookie-banner-icon {
    display: grid;
    width: 42px;
    height: 42px;
    flex: 0 0 42px;
    place-items: center;
    color: #071f34;
    background: #ffd34f;
    border-radius: 50%;
    font-size: 22px;
    font-weight: 800;
}

.cookie-banner h2 {
    margin: 0 0 5px;
    color: #fff;
    font-size: 17px;
    font-weight: 800;
    line-height: 1.25;
}

.cookie-banner p {
    max-width: 690px;
    margin: 0;
    color: rgba(234, 247, 255, 0.77);
    font-size: 13px;
    line-height: 1.55;
}

.cookie-banner a {
    color: #8fe1ff;
    font-weight: 700;
    text-underline-offset: 3px;
}

.cookie-banner-actions,
.cookie-dialog-actions {
    display: flex;
    align-items: center;
    gap: 9px;
}

.cookie-button {
    display: inline-flex;
    min-height: 44px;
    align-items: center;
    justify-content: center;
    padding: 10px 16px;
    border: 1px solid transparent;
    border-radius: 999px;
    cursor: pointer;
    font: inherit;
    font-size: 12px;
    font-weight: 800;
    line-height: 1.2;
    text-align: center;
    transition: background-color 180ms ease, border-color 180ms ease, color 180ms ease, transform 180ms ease;
}

.cookie-button:hover,
.cookie-button:focus-visible {
    transform: translateY(-1px);
}

.cookie-button-primary {
    color: #082038;
    background: #ffd34f;
    border-color: #ffd34f;
}

.cookie-button-primary:hover,
.cookie-button-primary:focus-visible {
    background: #ffe17d;
    border-color: #ffe17d;
}

.cookie-button-secondary {
    color: #eaf7ff;
    background: transparent;
    border-color: rgba(234, 247, 255, 0.34);
}

.cookie-button-secondary:hover,
.cookie-button-secondary:focus-visible {
    color: #fff;
    background: rgba(255, 255, 255, 0.09);
    border-color: rgba(234, 247, 255, 0.68);
}

.cookie-dialog {
    width: min(680px, calc(100% - 32px));
    max-height: min(780px, calc(100vh - 32px));
    padding: 0;
    overflow-x: hidden;
    overflow-y: auto;
    color: #233b4b;
    background: #fff;
    border: 0;
    border-radius: 26px;
    box-shadow: 0 32px 90px rgba(0, 20, 38, 0.38);
}

.cookie-dialog::backdrop {
    background: rgba(2, 19, 34, 0.72);
}

.cookie-dialog-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 24px;
    padding: 28px 30px 15px;
}

.cookie-dialog-head > div {
    min-width: 0;
    flex: 1 1 auto;
}

.cookie-dialog-kicker {
    margin: 0 0 6px;
    color: #0879b2;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.18em;
    text-transform: uppercase;
}

.cookie-dialog h2 {
    margin: 0;
    color: #073052;
    font-size: 30px;
    font-weight: 800;
    line-height: 1.15;
}

.cookie-dialog-close {
    display: grid;
    width: 44px;
    height: 44px;
    flex: 0 0 44px;
    place-items: center;
    padding: 0;
    color: #526b7a;
    background: #eef4f6;
    border: 0;
    border-radius: 50%;
    cursor: pointer;
    font-size: 27px;
}

.cookie-dialog-intro {
    margin: 0;
    padding: 0 30px 22px;
    color: #637783;
    font-size: 14px;
    line-height: 1.6;
}

.cookie-category-list {
    display: grid;
    gap: 10px;
    padding: 0 30px 24px;
}

.cookie-category {
    display: flex;
    min-height: 82px;
    align-items: center;
    justify-content: space-between;
    gap: 22px;
    padding: 16px 18px;
    background: #f5f8f9;
    border: 1px solid #e0e9ed;
    border-radius: 16px;
}

.cookie-category h3,
.cookie-category strong {
    display: block;
    margin: 0 0 3px;
    color: #103d59;
    font-size: 14px;
    font-weight: 800;
}

.cookie-category p,
.cookie-category small {
    display: block;
    margin: 0;
    color: #667a86;
    font-size: 12px;
    line-height: 1.45;
}

.cookie-always,
.cookie-inactive-label {
    flex: 0 0 auto;
    color: #0879b2;
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
}

.cookie-category-inactive {
    opacity: 0.72;
}

.cookie-inactive-label {
    color: #64737b;
}

.cookie-switch {
    position: relative;
    display: block;
    width: 50px;
    height: 28px;
    flex: 0 0 50px;
}

.cookie-switch input {
    position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
}

.cookie-switch span {
    position: absolute;
    inset: 0;
    background: #b8c6cd;
    border-radius: 999px;
    transition: background-color 180ms ease;
}

.cookie-switch span::after {
    position: absolute;
    top: 4px;
    left: 4px;
    width: 20px;
    height: 20px;
    background: #fff;
    border-radius: 50%;
    box-shadow: 0 2px 8px rgba(0, 24, 42, 0.22);
    content: "";
    transition: transform 180ms ease;
}

.cookie-switch input:checked + span {
    background: #0879b2;
}

.cookie-switch input:checked + span::after {
    transform: translateX(22px);
}

.cookie-switch input:focus-visible + span {
    outline: 3px solid rgba(8, 121, 178, 0.25);
    outline-offset: 3px;
}

.cookie-dialog-actions {
    justify-content: flex-end;
    padding: 19px 30px 26px;
    background: #edf3f5;
    border-radius: 0 0 26px 26px;
}

.cookie-dialog .cookie-button-secondary {
    color: #194258;
    border-color: #b8c8d0;
}

.cookie-dialog .cookie-button-secondary:hover,
.cookie-dialog .cookie-button-secondary:focus-visible {
    color: #073052;
    background: #fff;
    border-color: #7893a1;
}

.cookie-revisit {
    position: fixed;
    z-index: 950;
    bottom: 18px;
    left: 18px;
    min-height: 42px;
    padding: 9px 14px;
    color: #fff;
    background: #073052;
    border: 1px solid rgba(255, 255, 255, 0.35);
    border-radius: 999px;
    box-shadow: 0 8px 24px rgba(0, 20, 38, 0.24);
    cursor: pointer;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.cookie-policy-hero {
    padding: 74px 0 78px;
    color: #fff;
    background: linear-gradient(125deg, #061c2f, #073e63 58%, #183a7d);
}

.cookie-policy-heading h1 {
    margin: 0 0 14px;
    color: #fff;
    font-size: clamp(3.2rem, 7vw, 5.7rem);
    line-height: 1;
}

.cookie-policy-heading > p:last-child {
    max-width: 670px;
    margin: 0;
    color: rgba(255, 255, 255, 0.8);
}

.cookie-policy {
    max-width: 940px;
    padding-top: 72px;
    padding-bottom: 100px;
}

.cookie-policy h2 {
    margin: 50px 0 12px;
    color: #073052;
    font-size: 27px;
}

.cookie-policy p,
.cookie-policy li {
    color: #536976;
    line-height: 1.75;
}

.cookie-policy a {
    color: #0879b2;
    text-decoration: underline;
    text-decoration-thickness: 0.09em;
    text-underline-offset: 0.16em;
}

.cookie-policy-updated {
    font-size: 13px;
    font-weight: 700;
}

.cookie-policy-table-wrap {
    overflow-x: auto;
    margin-top: 22px;
    border: 1px solid #dce6ea;
    border-radius: 16px;
}

.cookie-policy-table {
    width: 100%;
    min-width: 690px;
    border-collapse: collapse;
}

.cookie-policy-table th,
.cookie-policy-table td {
    padding: 15px 17px;
    text-align: left;
    vertical-align: top;
    border-bottom: 1px solid #e5ecef;
}

.cookie-policy-table th {
    color: #49616e;
    background: #f2f6f8;
    font-size: 11px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.cookie-policy-table tr:last-child td {
    border-bottom: 0;
}

.cookie-policy-open {
    margin-top: 8px;
}

.home-footer-legal {
    display: block;
    width: max-content;
    margin: 20px auto 0;
    color: #526671;
    font-size: 12px;
    font-weight: 700;
    text-decoration: underline;
    text-underline-offset: 4px;
}

@media (max-width: 1280px) {
    .footer-bottom .container {
        padding-right: 62px;
    }

    .cookie-revisit {
        right: 10px;
        bottom: 10px;
        left: auto;
        width: 44px;
        height: 44px;
        min-height: 44px;
        padding: 0;
        overflow: hidden;
        font-size: 0;
    }

    .cookie-revisit::before {
        content: "◎";
        font-size: 20px;
        line-height: 1;
    }
}

@media (max-width: 900px) {
    .cookie-banner {
        grid-template-columns: 1fr;
        gap: 18px;
    }

    .cookie-banner-actions {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 640px) {
    .cookie-banner {
        right: 10px;
        bottom: 10px;
        left: 10px;
        width: calc(100% - 20px);
        max-height: calc(100vh - 20px);
        max-height: calc(100dvh - 20px);
        padding: 18px;
        border-radius: 18px;
    }

    .cookie-banner-copy {
        gap: 11px;
    }

    .cookie-banner-icon {
        width: 34px;
        height: 34px;
        flex-basis: 34px;
        font-size: 18px;
    }

    .cookie-banner-actions {
        grid-template-columns: 1fr;
        gap: 7px;
    }

    .cookie-dialog-head {
        padding: 23px 20px 13px;
    }

    .cookie-dialog h2 {
        font-size: 25px;
    }

    .cookie-dialog-intro,
    .cookie-category-list {
        padding-right: 20px;
        padding-left: 20px;
    }

    .cookie-category {
        align-items: flex-start;
        padding: 14px;
    }

    .cookie-always,
    .cookie-inactive-label {
        max-width: 72px;
        text-align: right;
    }

    .cookie-dialog-actions {
        display: grid;
        grid-template-columns: 1fr;
        padding: 16px 20px 20px;
    }

    .cookie-revisit {
        width: 44px;
        height: 44px;
        min-height: 44px;
        padding: 0;
        overflow: hidden;
        font-size: 0;
    }

    .cookie-revisit::before {
        content: "◎";
        font-size: 20px;
        line-height: 1;
    }

    .cookie-policy {
        padding-top: 52px;
        padding-bottom: 72px;
    }
}

@media (prefers-reduced-motion: reduce) {
    html:not(.motion-force) .cookie-button,
    html:not(.motion-force) .cookie-switch span,
    html:not(.motion-force) .cookie-switch span::after {
        transition: none;
    }
}
