/* Cookie Consent Stylesheet - Pellegrino Auto (Dark Carbon & Rosso Corsa) */

:root {
    --cookie-banner-bg: linear-gradient(135deg, rgba(13, 15, 18, 0.98) 0%, rgba(22, 24, 31, 0.96) 100%);
    --cookie-modal-bg: #ffffff;
    --cookie-border: rgba(235, 25, 32, 0.25);
    --cookie-btn-primary: #eb1920;
    --cookie-btn-primary-hover: #c41218;
    --cookie-btn-secondary: rgba(255, 255, 255, 0.08);
    --cookie-btn-secondary-hover: rgba(255, 255, 255, 0.18);
    --cookie-text: #ffffff;
    --cookie-text-dark: #0d0f12;
    --cookie-text-muted: rgba(255, 255, 255, 0.75);
    --cookie-text-muted-dark: #475569;
    --cookie-shadow: 0 20px 50px rgba(0, 0, 0, 0.65), 0 0 25px rgba(235, 25, 32, 0.1);
}

/* 1. Floating Cookie Trigger */
.pace-cookie-trigger {
    position: fixed;
    bottom: 30px;
    left: 30px;
    width: 52px;
    height: 52px;
    border-radius: 50%;
    background: linear-gradient(135deg, #1e222b 0%, #0d0f12 100%);
    color: #eb1920 !important;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    cursor: pointer;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.6), 0 0 15px rgba(235, 25, 32, 0.25);
    z-index: 9990;
    transition: all 0.35s cubic-bezier(0.22, 0.61, 0.36, 1);
    border: 2px solid rgba(235, 25, 32, 0.4);
    animation: cookiePulse 3s infinite;
}

.pace-cookie-trigger svg {
    transition: all 0.3s ease;
    width: 26px;
    height: 26px;
}

.pace-cookie-trigger:hover {
    transform: scale(1.12) translateY(-4px);
    background: linear-gradient(135deg, #eb1920 0%, #c41218 100%);
    color: #ffffff !important;
    border-color: #ff2a32;
    box-shadow: 0 12px 30px rgba(235, 25, 32, 0.55), 0 0 20px rgba(235, 25, 32, 0.35);
}

.pace-cookie-trigger:hover svg {
    color: #ffffff !important;
    stroke: #ffffff;
}

.pace-cookie-trigger:hover svg circle {
    fill: #ffffff;
}

@keyframes cookiePulse {
    0% {
        box-shadow: 0 0 0 0 rgba(235, 25, 32, 0.4);
    }
    70% {
        box-shadow: 0 0 0 12px rgba(235, 25, 32, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(235, 25, 32, 0);
    }
}

/* 2. Consent Banner Container */
.pace-cookie-banner {
    position: fixed;
    bottom: 25px;
    left: 25px;
    right: 25px;
    max-width: 920px;
    margin: 0 auto;
    background: var(--cookie-banner-bg);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border: 1px solid var(--cookie-border);
    border-radius: 20px;
    padding: 24px 28px;
    color: var(--cookie-text);
    box-shadow: var(--cookie-shadow);
    z-index: 9999;
    opacity: 0;
    transform: translateY(50px) scale(0.95);
    transition: all 0.5s cubic-bezier(0.22, 0.61, 0.36, 1);
    display: none;
}

.pace-cookie-banner.show {
    display: block;
    opacity: 1;
    transform: translateY(0) scale(1);
}

.pace-cookie-banner-layout {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

.pace-cookie-content {
    flex: 1;
}

.pace-cookie-title {
    font-weight: 700;
    font-size: 1.15rem;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 10px;
    color: #ffffff;
}

.pace-cookie-title svg,
.pace-cookie-title i {
    color: #eb1920;
}

.pace-cookie-desc {
    font-size: 0.92rem;
    line-height: 1.55;
    color: var(--cookie-text-muted);
    margin-bottom: 0;
}

.pace-cookie-desc a {
    color: #ffffff;
    text-decoration: underline;
    font-weight: 600;
    transition: color 0.2s ease;
}

.pace-cookie-desc a:hover {
    color: #eb1920;
}

.pace-cookie-buttons {
    display: flex;
    flex-direction: row;
    gap: 12px;
    flex-shrink: 0;
}

/* 3. Button Styles */
.pace-cookie-btn {
    padding: 10px 22px;
    border-radius: 50px;
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.22, 0.61, 0.36, 1);
    border: none;
    outline: none;
    text-align: center;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    white-space: nowrap;
    text-decoration: none;
}

.pace-cookie-btn-accept {
    background: linear-gradient(135deg, #eb1920 0%, #c41218 100%);
    color: #ffffff !important;
    box-shadow: 0 4px 15px rgba(235, 25, 32, 0.4);
}

.pace-cookie-btn-accept:hover {
    background: linear-gradient(135deg, #ff2a32 0%, #eb1920 100%);
    transform: translateY(-2px);
    box-shadow: 0 8px 22px rgba(235, 25, 32, 0.55);
}

.pace-cookie-btn-reject {
    background-color: rgba(255, 255, 255, 0.08);
    color: #ffffff !important;
    border: 1px solid rgba(255, 255, 255, 0.25);
}

.pace-cookie-btn-reject:hover {
    background-color: rgba(255, 255, 255, 0.18);
    border-color: rgba(255, 255, 255, 0.5);
    transform: translateY(-2px);
}

.pace-cookie-btn-settings {
    background-color: transparent;
    color: var(--cookie-text-muted);
    text-decoration: underline;
    padding: 10px 12px;
}

.pace-cookie-btn-settings:hover {
    color: #ffffff;
}

/* 4. Preferences Modal Styles */
.pace-cookie-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(13, 15, 18, 0.85) !important;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    z-index: 10000;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 20px;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.pace-cookie-modal-overlay.show {
    display: flex !important;
    opacity: 1 !important;
}

.pace-cookie-modal {
    background-color: #ffffff !important;
    border-radius: 24px !important;
    width: 100%;
    max-width: 620px;
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.45) !important;
    overflow: hidden;
    transform: translateY(30px) scale(0.95);
    transition: all 0.3s cubic-bezier(0.22, 0.61, 0.36, 1);
    border: 1px solid rgba(0, 0, 0, 0.08);
}

.pace-cookie-modal-overlay.show .pace-cookie-modal {
    transform: translateY(0) scale(1) !important;
}

.pace-cookie-modal-header {
    background: linear-gradient(135deg, #0d0f12 0%, #16181f 100%) !important;
    border-bottom: 2px solid #eb1920 !important;
    color: #ffffff !important;
    padding: 24px 30px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
}

.pace-cookie-modal-title {
    font-weight: 700 !important;
    font-size: 1.3rem !important;
    margin-bottom: 0 !important;
    display: flex !important;
    align-items: center !important;
    gap: 10px !important;
    color: #ffffff !important;
}

.pace-cookie-modal-title i,
.pace-cookie-modal-title svg {
    color: #eb1920 !important;
}

.pace-cookie-modal-close {
    font-size: 28px !important;
    background: transparent !important;
    border: none !important;
    color: rgba(255, 255, 255, 0.7) !important;
    cursor: pointer !important;
    transition: color 0.2s, transform 0.2s !important;
    line-height: 1 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
}

.pace-cookie-modal-close:hover {
    color: #eb1920 !important;
    transform: scale(1.15) !important;
}

.pace-cookie-modal-body {
    padding: 28px 30px !important;
    max-height: 60vh;
    overflow-y: auto;
    background-color: #ffffff !important;
}

.pace-cookie-modal-intro {
    font-size: 0.95rem;
    color: #475569 !important;
    line-height: 1.6;
    margin-bottom: 24px;
}

/* Category Items */
.pace-cookie-cat-item {
    background-color: #f8fafc !important;
    border: 1px solid #e2e8f0 !important;
    border-radius: 16px !important;
    padding: 20px !important;
    margin-bottom: 16px !important;
    display: flex !important;
    align-items: flex-start !important;
    justify-content: space-between !important;
    gap: 20px !important;
    transition: all 0.2s ease !important;
}

.pace-cookie-cat-item:hover {
    border-color: #cbd5e1 !important;
    background-color: #f1f5f9 !important;
}

.pace-cookie-cat-info {
    flex: 1;
}

.pace-cookie-cat-header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 6px;
}

.pace-cookie-cat-name {
    font-weight: 700 !important;
    color: #0d0f12 !important;
    font-size: 1.05rem !important;
}

.pace-cookie-cat-badge {
    font-size: 0.75rem !important;
    padding: 3px 10px !important;
    border-radius: 20px !important;
    font-weight: 700 !important;
}

.pace-cookie-cat-badge.necessary {
    background-color: #fee2e2 !important;
    color: #dc2626 !important;
    border: 1px solid rgba(220, 38, 38, 0.2) !important;
}

.pace-cookie-cat-badge.optional {
    background-color: #f1f5f9 !important;
    color: #475569 !important;
    border: 1px solid #cbd5e1 !important;
}

.pace-cookie-cat-desc {
    font-size: 0.88rem !important;
    color: #475569 !important;
    line-height: 1.5 !important;
    margin-bottom: 0 !important;
}

/* Switch Styles */
.pace-cookie-switch-label {
    position: relative !important;
    display: inline-block !important;
    width: 52px !important;
    height: 28px !important;
    flex-shrink: 0 !important;
    margin-top: 4px !important;
}

.pace-cookie-switch-label input {
    opacity: 0 !important;
    width: 0 !important;
    height: 0 !important;
}

.pace-cookie-slider {
    position: absolute !important;
    cursor: pointer !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    background-color: #cbd5e1 !important;
    transition: .3s !important;
    border-radius: 34px !important;
}

.pace-cookie-slider:before {
    position: absolute !important;
    content: "" !important;
    height: 20px !important;
    width: 20px !important;
    left: 4px !important;
    bottom: 4px !important;
    background-color: white !important;
    transition: .3s !important;
    border-radius: 50% !important;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2) !important;
}

.pace-cookie-switch-label input:checked + .pace-cookie-slider {
    background-color: #eb1920 !important;
}

.pace-cookie-switch-label input:focus + .pace-cookie-slider {
    box-shadow: 0 0 0 2px rgba(235, 25, 32, 0.25) !important;
}

.pace-cookie-switch-label input:checked + .pace-cookie-slider:before {
    transform: translateX(24px) !important;
}

.pace-cookie-switch-label input:disabled + .pace-cookie-slider {
    background-color: #94a3b8 !important;
    cursor: not-allowed !important;
}

.pace-cookie-modal-footer {
    padding: 20px 30px !important;
    border-top: 1px solid #e2e8f0 !important;
    background-color: #f8fafc !important;
    display: flex !important;
    align-items: center !important;
    justify-content: flex-end !important;
    gap: 14px !important;
}

.pace-cookie-modal-btn-save {
    background: linear-gradient(135deg, #16181f 0%, #0d0f12 100%) !important;
    color: #ffffff !important;
    border: 1px solid rgba(255, 255, 255, 0.15) !important;
}

.pace-cookie-modal-btn-save:hover {
    background: linear-gradient(135deg, #eb1920 0%, #c41218 100%) !important;
    transform: translateY(-2px) !important;
    box-shadow: 0 6px 20px rgba(235, 25, 32, 0.4) !important;
}

.pace-cookie-modal-btn-all {
    background: linear-gradient(135deg, #eb1920 0%, #c41218 100%) !important;
    color: #ffffff !important;
    box-shadow: 0 4px 15px rgba(235, 25, 32, 0.35) !important;
}

.pace-cookie-modal-btn-all:hover {
    background: linear-gradient(135deg, #ff2a32 0%, #eb1920 100%) !important;
    transform: translateY(-2px) !important;
    box-shadow: 0 8px 22px rgba(235, 25, 32, 0.5) !important;
}

/* 5. Responsive Styles */
@media (max-width: 991px) {
    .pace-cookie-banner {
        bottom: 20px;
        left: 20px;
        right: 20px;
        padding: 20px;
    }
    
    .pace-cookie-banner-layout {
        flex-direction: column;
        align-items: stretch;
        gap: 16px;
    }
    
    .pace-cookie-buttons {
        justify-content: flex-end;
    }
}

@media (max-width: 576px) {
    .pace-cookie-trigger {
        bottom: 20px;
        left: 20px;
        width: 46px;
        height: 46px;
        font-size: 18px;
    }
    
    .pace-cookie-banner {
        bottom: 0;
        left: 0;
        right: 0;
        border-radius: 20px 20px 0 0;
        border-left: none;
        border-right: none;
        border-bottom: none;
    }
    
    .pace-cookie-buttons {
        flex-direction: column;
        gap: 8px;
        align-items: stretch;
    }
    
    .pace-cookie-btn {
        width: 100%;
        padding: 12px;
    }
    
    .pace-cookie-btn-settings {
        order: 3;
    }
    
    .pace-cookie-modal-body {
        padding: 20px;
    }
    
    .pace-cookie-modal-footer {
        flex-direction: column;
        align-items: stretch;
        padding: 20px;
    }
    
    .pace-cookie-modal-footer .pace-cookie-btn {
        width: 100%;
    }
}

