/**
 * Cookie Consent Banner - Boxing Only
 * GDPR-compliant consent UI, branded to site theme (#7C3636 maroon)
 */

/* ── Banner ── */
#cookie-consent-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: #7C3636;
    color: white;
    padding: 16px;
    box-shadow: 0 -2px 10px rgba(0,0,0,0.25);
    z-index: 9999;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    font-size: 14px;
    line-height: 1.5;
    animation: bo-slide-up 0.3s ease-out;
}

.cookie-consent-content {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 16px;
}

.cookie-consent-text {
    flex: 1;
    min-width: 260px;
}

.cookie-consent-text h3 {
    margin: 0 0 6px 0;
    font-size: 16px;
    font-weight: 700;
    color: #F3CDCD;
    font-family: 'Oswald', 'Arial Narrow', sans-serif;
    letter-spacing: 0.03em;
}

.cookie-consent-text p {
    margin: 0;
    color: rgba(255,255,255,0.92);
    font-size: 13px;
}

.cookie-consent-text a {
    color: #F3CDCD;
    text-decoration: underline;
}
.cookie-consent-text a:hover { color: #fff; }

.cookie-consent-buttons {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    align-items: center;
}

/* ── Buttons ── */
.cookie-btn {
    padding: 9px 18px;
    border: 2px solid transparent;
    border-radius: 6px;
    cursor: pointer;
    font-size: 13px;
    font-weight: 600;
    font-family: inherit;
    text-decoration: none;
    display: inline-block;
    transition: background 0.15s, color 0.15s, transform 0.1s;
    white-space: nowrap;
    line-height: 1.4;
}
.cookie-btn:hover  { transform: translateY(-1px); }
.cookie-btn:active { transform: translateY(0); }

.cookie-btn-accept {
    background: #F3CDCD;
    color: #5F0F0F;
    border-color: #CF9595;
}
.cookie-btn-accept:hover { background: #fff; color: #5F0F0F; }

.cookie-btn-decline {
    background: transparent;
    color: #fff;
    border-color: rgba(255,255,255,0.6);
}
.cookie-btn-decline:hover { background: rgba(255,255,255,0.15); border-color: #fff; }

.cookie-btn-settings {
    background: transparent;
    color: #F3CDCD;
    border-color: #CF9595;
    font-size: 12px;
    padding: 7px 12px;
}
.cookie-btn-settings:hover { background: rgba(207,149,149,0.2); }

/* ── Settings Modal ── */
#cookie-settings-modal {
    position: fixed;
    inset: 0;
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    animation: bo-fade-in 0.2s ease-out;
}

.cookie-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.7);
}

.cookie-modal-content {
    background: #fff;
    border-radius: 10px;
    max-width: 480px;
    width: 100%;
    max-height: 85vh;
    overflow-y: auto;
    box-shadow: 0 20px 60px rgba(0,0,0,0.4);
    position: relative;
    z-index: 1;
}

.cookie-modal-header {
    padding: 20px 24px;
    background: #7C3636;
    color: #fff;
    border-radius: 10px 10px 0 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.cookie-modal-header h2 {
    margin: 0;
    font-size: 20px;
    font-weight: 700;
    font-family: 'Oswald', 'Arial Narrow', sans-serif;
    letter-spacing: 0.04em;
}

.cookie-close-btn {
    background: none;
    border: none;
    color: #F3CDCD;
    font-size: 26px;
    line-height: 1;
    cursor: pointer;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
    transition: background 0.15s;
    padding: 0;
}
.cookie-close-btn:hover { background: rgba(255,255,255,0.2); color: #fff; }

.cookie-modal-body {
    padding: 20px 24px;
    color: #333;
}

.cookie-modal-body > p {
    margin: 0 0 16px 0;
    font-size: 14px;
    color: #555;
}

.cookie-category {
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    margin-bottom: 12px;
    overflow: hidden;
}

.cookie-category-header {
    padding: 13px 16px;
    background: #f9f6f6;
    border-bottom: 1px solid #e5e7eb;
}

.cookie-category-header label {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    margin: 0;
    user-select: none;
}

.cookie-category-header input[type="checkbox"] {
    width: 17px;
    height: 17px;
    cursor: pointer;
    accent-color: #7C3636;
}
.cookie-category-header input[disabled] { cursor: not-allowed; opacity: 0.5; }

.cookie-category-title {
    font-weight: 600;
    color: #4A1B1B;
    font-size: 14px;
}

.cookie-required-badge {
    font-size: 11px;
    background: #e5e7eb;
    color: #6b7280;
    padding: 2px 7px;
    border-radius: 10px;
    margin-left: auto;
}

.cookie-category-desc {
    padding: 12px 16px;
    margin: 0;
    color: #6b7280;
    font-size: 13px;
    line-height: 1.5;
}

.cookie-modal-footer {
    padding: 16px 24px;
    background: #f9f6f6;
    border-top: 1px solid #e5e7eb;
    border-radius: 0 0 10px 10px;
    display: flex;
    justify-content: flex-end;
    gap: 10px;
}

/* ── Responsive ── */
@media (max-width: 640px) {
    #cookie-consent-banner { padding: 14px 12px; }

    .cookie-consent-content {
        flex-direction: column;
        align-items: stretch;
    }

    .cookie-consent-buttons {
        justify-content: stretch;
    }
    .cookie-consent-buttons .cookie-btn { flex: 1; text-align: center; }

    .cookie-modal-content { margin: 0 4px; max-height: 92vh; }
    .cookie-modal-header  { padding: 16px 18px; }
    .cookie-modal-body    { padding: 16px 18px; }
    .cookie-modal-footer  { padding: 14px 18px; }
}

/* ── Animations ── */
@keyframes bo-slide-up {
    from { transform: translateY(100%); opacity: 0; }
    to   { transform: translateY(0);    opacity: 1; }
}
@keyframes bo-fade-in {
    from { opacity: 0; }
    to   { opacity: 1; }
}
