/* Footer legal line: operator identity required by 152-FZ. */
.site-footer__legal {
    /* Own row in the centred flex footer: the line carries name, INN, OGRNIP and phone. */
    flex-basis: 100%;
    margin: 0;
    color: var(--muted);
    font-size: 14px;
    line-height: 1.6;
}

.site-footer__legal a,
.site-footer__legal a:visited {
    color: inherit;
    text-decoration: none;
    transition: color 0.2s ease;
}

.site-footer__legal a:hover {
    color: var(--accent);
}

.site-footer__cookie-btn {
    padding: 0;
    border: 0;
    background: none;
    color: var(--muted);
    font: inherit;
    cursor: pointer;
    text-decoration: underline dotted;
    transition: color 0.2s ease;
}

.site-footer__cookie-btn:hover {
    color: var(--accent);
}

/* Cookie consent banner */
.cookie-consent {
    position: fixed;
    inset: auto 0 0 0;
    z-index: 9999;
    display: flex;
    justify-content: center;
    padding: 16px;
    pointer-events: none;
}

.cookie-consent__panel {
    pointer-events: auto;
    width: min(980px, 100%);
    max-height: 80vh;
    overflow-y: auto;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 16px 24px;
    padding: 20px 24px;
    background: linear-gradient(180deg, var(--panel), var(--panel-2));
    border: 1px solid var(--border);
    border-radius: 20px;
    box-shadow: 0 22px 60px rgba(0, 0, 0, 0.55);
}

.cookie-consent__body {
    flex: 1 1 420px;
    min-width: 0;
}

.cookie-consent__title {
    margin: 0 0 8px;
    font-size: 18px;
    line-height: 1.3;
}

.cookie-consent__intro {
    margin: 0;
    color: var(--muted);
    font-size: 14px;
}

.cookie-consent__intro a,
.cookie-consent__cat-text a {
    color: var(--accent);
}

/* .btn and the grid below set `display`, which would otherwise beat the UA rule for [hidden]. */
.cookie-consent [hidden] {
    display: none !important;
}

.cookie-consent__cats {
    display: grid;
    gap: 12px;
    margin-top: 16px;
}

.cookie-consent__cat {
    padding: 12px 14px;
    border: 1px solid var(--border);
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.02);
}

.cookie-consent__cat-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.cookie-consent__cat-title {
    font-weight: 700;
}

.cookie-consent__cat-locked {
    color: var(--muted);
    font-size: 13px;
    white-space: nowrap;
}

.cookie-consent__cat-text {
    margin: 6px 0 0;
    color: var(--muted);
    font-size: 13px;
}

.cookie-consent__switch input {
    width: 42px;
    height: 22px;
    accent-color: var(--accent);
    cursor: pointer;
}

.cookie-consent__actions {
    flex: 0 1 auto;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px 14px;
}

.cookie-consent__link {
    padding: 0;
    border: 0;
    background: none;
    color: var(--muted);
    font: inherit;
    cursor: pointer;
    text-decoration: underline dotted;
}

.cookie-consent__link:hover {
    color: var(--accent);
}

.cookie-consent.is-expanded .cookie-consent__panel {
    align-items: flex-start;
}

@media (max-width: 700px) {
    .cookie-consent__panel {
        padding: 18px;
        border-radius: 16px;
    }

    .cookie-consent__actions {
        width: 100%;
    }

    .cookie-consent__actions .btn {
        flex: 1 1 140px;
        text-align: center;
    }
}
