/* Cookie consent banner + settings dialog (CookieConsent plugin). */

.cookie-consent {
    font-family: var(--font-body);
    color: #1f2937;
}

.cookie-consent [hidden] {
    display: none !important;
}

.cookie-consent__banner {
    position: fixed;
    left: 16px;
    right: 16px;
    bottom: 16px;
    z-index: 10000;
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    align-items: center;
    justify-content: space-between;
    max-width: 1080px;
    margin: 0 auto;
    padding: 20px 24px;
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 12px 40px rgba(15, 23, 42, 0.18);
}

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

.cookie-consent__title {
    margin: 0 0 6px;
    font-family: var(--font-heading);
    font-size: 18px;
    font-weight: 700;
    line-height: 1.3;
}

.cookie-consent__text {
    margin: 0;
    font-size: 14px;
    line-height: 1.5;
}

.cookie-consent__text a {
    color: #2563eb;
    text-decoration: underline;
}

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

.cookie-consent__button {
    padding: 10px 18px;
    font: inherit;
    font-size: 14px;
    font-weight: 600;
    line-height: 1.2;
    color: #1f2937;
    background: #f3f4f6;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    cursor: pointer;
}

.cookie-consent__button:hover {
    background: #e5e7eb;
}

.cookie-consent__button:focus-visible {
    outline: 3px solid #93c5fd;
    outline-offset: 2px;
}

.cookie-consent__button_primary {
    color: #ffffff;
    background: #2563eb;
    border-color: #2563eb;
}

.cookie-consent__button_primary:hover {
    background: #1d4ed8;
}

.cookie-consent__button_link {
    background: transparent;
    border-color: transparent;
    text-decoration: underline;
}

.cookie-consent__button_link:hover {
    background: transparent;
}

.cookie-consent__overlay {
    position: fixed;
    inset: 0;
    z-index: 10001;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
    background: rgba(15, 23, 42, 0.55);
}

.cookie-consent__modal {
    width: 100%;
    max-width: 560px;
    max-height: calc(100vh - 32px);
    overflow-y: auto;
    padding: 24px;
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 20px 60px rgba(15, 23, 42, 0.3);
}

.cookie-consent__modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 8px;
}

.cookie-consent__close {
    width: 36px;
    height: 36px;
    font-size: 24px;
    line-height: 1;
    color: #6b7280;
    background: transparent;
    border: 0;
    border-radius: 8px;
    cursor: pointer;
}

.cookie-consent__close:hover {
    background: #f3f4f6;
}

.cookie-consent__categories {
    margin: 16px 0 20px;
    padding: 0;
    list-style: none;
}

.cookie-consent__category {
    padding: 12px 0;
    border-top: 1px solid #e5e7eb;
}

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

.cookie-consent__category-name {
    margin: 0;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
}

.cookie-consent__category-text {
    margin: 6px 0 0;
    font-size: 13px;
    line-height: 1.5;
    color: #4b5563;
}

.cookie-consent__always-on {
    font-size: 12px;
    font-weight: 600;
    color: #047857;
    text-transform: uppercase;
}

.cookie-consent__switch {
    appearance: none;
    -webkit-appearance: none;
    position: relative;
    flex: 0 0 auto;
    width: 44px;
    height: 24px;
    margin: 0;
    background: #d1d5db;
    border-radius: 12px;
    cursor: pointer;
    transition: background 0.2s;
}

.cookie-consent__switch::after {
    content: "";
    position: absolute;
    top: 3px;
    left: 3px;
    width: 18px;
    height: 18px;
    background: #ffffff;
    border-radius: 50%;
    transition: transform 0.2s;
}

.cookie-consent__switch:checked {
    background: #2563eb;
}

.cookie-consent__switch:checked::after {
    transform: translateX(20px);
}

.cookie-consent__switch:focus-visible {
    outline: 3px solid #93c5fd;
    outline-offset: 2px;
}

@media (max-width: 640px) {
    .cookie-consent__banner {
        left: 8px;
        right: 8px;
        bottom: 8px;
        padding: 16px;
    }

    .cookie-consent__actions {
        width: 100%;
    }

    .cookie-consent__button {
        flex: 1 1 auto;
        text-align: center;
    }
}

@media (prefers-reduced-motion: reduce) {
    .cookie-consent__switch,
    .cookie-consent__switch::after {
        transition: none;
    }
}
