/* Cookie consent modal and overlay */

#cookie-consent-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.65);
    z-index: 9998;
}

body.consent-required #cookie-consent-overlay {
    display: block;
}

body.consent-required #wrapper {
    filter: blur(4px);
    pointer-events: none;
    user-select: none;
}

#cookie-consent-modal {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    background: #fff;
    color: #333;
    z-index: 9999;
    box-shadow: 0 -4px 24px rgba(0, 0, 0, 0.18);
    transform: translateY(100%);
    transition: transform 0.35s ease;
}

#cookie-consent-modal.is-visible {
    transform: translateY(0);
}

#cookie-consent-modal .cookie-consent-inner {
    max-width: 960px;
    margin: 0 auto;
    padding: 28px 24px 24px;
}

#cookie-consent-modal h4 {
    margin: 0 0 12px;
    font-size: 20px;
    font-weight: 700;
    color: #222;
}

#cookie-consent-modal p {
    margin: 0 0 16px;
    line-height: 1.6;
    font-size: 14px;
}

#cookie-consent-modal a {
    color: #c0392b;
    text-decoration: underline;
}

.cookie-consent-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 16px;
}

.cookie-consent-btn {
    display: inline-block;
    padding: 10px 18px;
    border: none;
    border-radius: 3px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    transition: background 0.2s ease, color 0.2s ease;
}

.cookie-consent-btn-primary {
    background: #c0392b;
    color: #fff;
}

.cookie-consent-btn-primary:hover {
    background: #a93226;
    color: #fff;
}

.cookie-consent-btn-secondary {
    background: #eee;
    color: #333;
}

.cookie-consent-btn-secondary:hover {
    background: #ddd;
}

.cookie-consent-btn-outline {
    background: transparent;
    color: #333;
    border: 1px solid #ccc;
}

.cookie-consent-btn-outline:hover {
    background: #f5f5f5;
}

#cookie-consent-settings {
    display: none;
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid #e5e5e5;
}

#cookie-consent-settings.is-open {
    display: block;
}

.cookie-consent-category {
    padding: 14px 0;
    border-bottom: 1px solid #eee;
}

.cookie-consent-category:last-child {
    border-bottom: none;
}

.cookie-consent-category-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
}

.cookie-consent-category h5 {
    margin: 0 0 6px;
    font-size: 15px;
    font-weight: 600;
}

.cookie-consent-category p {
    margin: 0;
    font-size: 13px;
    color: #666;
}

.cookie-consent-toggle {
    position: relative;
    display: inline-block;
    width: 44px;
    min-width: 44px;
    height: 24px;
    flex-shrink: 0;
}

.cookie-consent-toggle input {
    opacity: 0;
    width: 0;
    height: 0;
}

.cookie-consent-toggle-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: #ccc;
    border-radius: 24px;
    transition: background 0.2s ease;
}

.cookie-consent-toggle-slider:before {
    position: absolute;
    content: "";
    height: 18px;
    width: 18px;
    left: 3px;
    bottom: 3px;
    background: #fff;
    border-radius: 50%;
    transition: transform 0.2s ease;
}

.cookie-consent-toggle input:checked + .cookie-consent-toggle-slider {
    background: #c0392b;
}

.cookie-consent-toggle input:checked + .cookie-consent-toggle-slider:before {
    transform: translateX(20px);
}

.cookie-consent-toggle input:disabled + .cookie-consent-toggle-slider {
    opacity: 0.6;
    cursor: not-allowed;
}

#cookie-consent-error {
    display: none;
    margin-top: 12px;
    padding: 10px 12px;
    background: #fdecea;
    color: #c0392b;
    font-size: 13px;
    border-radius: 3px;
}

#cookie-consent-error.is-visible {
    display: block;
}

@media (max-width: 767px) {
    #cookie-consent-modal .cookie-consent-inner {
        padding: 20px 16px 16px;
    }

    .cookie-consent-actions {
        flex-direction: column;
    }

    .cookie-consent-btn {
        width: 100%;
        text-align: center;
    }
}
