/* 
==================================================
EPIC CAR RENTAL - MODERN COOKIE NOTICE 2025
Premium Cookie Consent with Glass Morphism
==================================================
*/

:root {
    --cookie-primary: #800000;
    --cookie-secondary: #600000;
    --cookie-gradient: linear-gradient(135deg, #800000 0%, #600000 50%, #800000 100%);
    --cookie-dark-bg: #1d1d1d;
    --cookie-darker-bg: #121212;
    --cookie-text-primary: #fff;
    --cookie-text-secondary: #e0e0e0;
    --cookie-border-light: rgba(255, 255, 255, 0.1);
    --cookie-border-medium: rgba(255, 255, 255, 0.2);
    --cookie-shadow-heavy: rgba(0, 0, 0, 0.4);
    --cookie-shadow-gold: rgba(128, 0, 0, 0.3);
    --cookie-border-radius: 20px;
    --cookie-transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --cookie-gradient-glass: linear-gradient(135deg, rgba(255, 255, 255, 0.1) 0%, rgba(255, 255, 255, 0.05) 100%);
    --cookie-blur-backdrop: blur(20px);
}

/* Modern Cookie Consent Modal */
.cookie_consent_modal {
    position: fixed;
    bottom: 30px;
    left: 30px;
    right: 30px;
    max-width: 500px;
    width: 100%;
    padding: 35px;
    background: var(--cookie-gradient-glass);
    backdrop-filter: var(--cookie-blur-backdrop);
    border: 2px solid var(--cookie-border-light);
    border-radius: var(--cookie-border-radius);
    z-index: 10000;
    box-shadow: 
        0 25px 50px var(--cookie-shadow-heavy),
        0 0 0 1px rgba(255, 255, 255, 0.05),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
    transform: translateY(100px);
    opacity: 0;
    transition: var(--cookie-transition);
    color: var(--cookie-text-primary);
    overflow: hidden;
}

/* Show animation */
.cookie_consent_modal:not(.d-none) {
    transform: translateY(0);
    opacity: 1;
    animation: cookieSlideIn 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes cookieSlideIn {
    0% {
        transform: translateY(100px) scale(0.9);
        opacity: 0;
    }
    100% {
        transform: translateY(0) scale(1);
        opacity: 1;
    }
}

/* Background overlay pattern */
.cookie_consent_modal::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        radial-gradient(circle at 20% 80%, rgba(128, 0, 0, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(128, 0, 0, 0.1) 0%, transparent 50%);
    border-radius: var(--cookie-border-radius);
    z-index: -1;
}

/* Close button styling */
.cookie_consent_modal .btn-close {
    position: absolute;
    top: 20px;
    right: 20px;
    width: 35px;
    height: 35px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid var(--cookie-border-light);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 1;
    transition: var(--cookie-transition);
    backdrop-filter: blur(10px);
    z-index: 10;
}

.cookie_consent_modal .btn-close:hover {
    background: rgba(255, 255, 255, 0.2);
    border-color: var(--cookie-border-medium);
    transform: scale(1.1);
}

.cookie_consent_modal .btn-close::before {
    content: '×';
    font-size: 20px;
    font-weight: 300;
    color: var(--cookie-text-primary);
    line-height: 1;
}

/* Cookie icon */
.cookie_consent_modal::after {
    content: '🍪';
    position: absolute;
    top: 25px;
    left: 30px;
    font-size: 28px;
    opacity: 0.8;
    animation: cookieBounce 2s ease-in-out infinite;
}

@keyframes cookieBounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateY(0);
    }
    40% {
        transform: translateY(-5px);
    }
    60% {
        transform: translateY(-3px);
    }
}

/* Title styling */
.cookie_consent_modal h5 {
    font-size: 24px;
    font-weight: 700;
    color: var(--cookie-text-primary);
    margin: 0 0 15px 0;
    padding-left: 50px;
    line-height: 1.3;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

/* Message text styling */
.cookie_consent_modal p {
    font-size: 16px;
    line-height: 1.6;
    color: var(--cookie-text-secondary);
    margin: 0 0 25px 0;
    padding-right: 15px;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
}

/* Button container */
.cookie_consent_modal .common-modal-btn {
    display: flex;
    gap: 15px;
    align-items: center;
    justify-content: flex-end;
    margin: 0;
}

/* Accept button - enhanced theme styling */
.cookie_consent_modal .cookie_consent_accept_btn {
    padding: 14px 28px;
    background: var(--cookie-gradient);
    color: var(--cookie-text-primary);
    font-size: 16px;
    font-weight: 600;
    border: 2px solid var(--cookie-primary);
    border-radius: 12px;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: var(--cookie-transition);
    position: relative;
    overflow: hidden;
    min-width: 120px;
    box-shadow: 
        0 4px 15px rgba(128, 0, 0, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
}

.cookie_consent_modal .cookie_consent_accept_btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.6s;
}

.cookie_consent_modal .cookie_consent_accept_btn:hover::before {
    left: 100%;
}

.cookie_consent_modal .cookie_consent_accept_btn:hover {
    background: linear-gradient(135deg, #900000 0%, #700000 50%, #900000 100%);
    transform: translateY(-2px);
    box-shadow: 
        0 6px 20px rgba(128, 0, 0, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
    border-color: #900000;
}

.cookie_consent_modal .cookie_consent_accept_btn:active {
    transform: translateY(0);
    box-shadow: 
        0 2px 10px rgba(128, 0, 0, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

/* Add checkmark icon to accept button */
.cookie_consent_modal .cookie_consent_accept_btn::after {
    content: '✓';
    font-size: 16px;
    margin-left: 5px;
    transition: var(--cookie-transition);
}

.cookie_consent_modal .cookie_consent_accept_btn:hover::after {
    transform: scale(1.2);
}

/* Decline button (if needed in future) */
.cookie_consent_modal .cookie_consent_decline_btn {
    padding: 14px 20px;
    background: transparent;
    color: var(--cookie-text-secondary);
    font-size: 16px;
    font-weight: 500;
    border: 2px solid var(--cookie-border-light);
    border-radius: 12px;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: var(--cookie-transition);
    backdrop-filter: blur(10px);
}

.cookie_consent_modal .cookie_consent_decline_btn:hover {
    background: rgba(255, 255, 255, 0.1);
    color: var(--cookie-text-primary);
    border-color: var(--cookie-border-medium);
    transform: translateY(-1px);
}

/* Progress bar animation */
.cookie_consent_modal .cookie-progress {
    position: absolute;
    bottom: 0;
    left: 0;
    height: 3px;
    background: var(--cookie-gradient);
    border-radius: 0 0 var(--cookie-border-radius) var(--cookie-border-radius);
    animation: cookieProgress 10s linear infinite;
    box-shadow: 0 0 10px rgba(128, 0, 0, 0.5);
}

@keyframes cookieProgress {
    0% { width: 100%; }
    100% { width: 0%; }
}

/* Responsive Design */
@media (max-width: 768px) {
    .cookie_consent_modal {
        bottom: 20px;
        left: 20px;
        right: 20px;
        max-width: none;
        padding: 25px;
        border-radius: 16px;
    }
    
    .cookie_consent_modal h5 {
        font-size: 20px;
        padding-left: 45px;
    }
    
    .cookie_consent_modal::after {
        font-size: 24px;
        top: 20px;
        left: 25px;
    }
    
    .cookie_consent_modal p {
        font-size: 15px;
        margin-bottom: 20px;
    }
    
    .cookie_consent_modal .common-modal-btn {
        flex-direction: column;
        gap: 12px;
    }
    
    .cookie_consent_modal .cookie_consent_accept_btn {
        width: 100%;
        padding: 16px 20px;
        font-size: 15px;
    }
    
    .cookie_consent_modal .btn-close {
        top: 15px;
        right: 15px;
        width: 30px;
        height: 30px;
    }
    
    .cookie_consent_modal .btn-close::before {
        font-size: 18px;
    }
}

@media (max-width: 480px) {
    .cookie_consent_modal {
        bottom: 15px;
        left: 15px;
        right: 15px;
        padding: 20px;
        border-radius: 14px;
    }
    
    .cookie_consent_modal h5 {
        font-size: 18px;
        padding-left: 40px;
    }
    
    .cookie_consent_modal::after {
        font-size: 20px;
        top: 18px;
        left: 20px;
    }
    
    .cookie_consent_modal p {
        font-size: 14px;
        line-height: 1.5;
    }
}

/* Large screen adjustments */
@media (min-width: 1200px) {
    .cookie_consent_modal {
        max-width: 550px;
        padding: 40px;
    }
    
    .cookie_consent_modal h5 {
        font-size: 26px;
        padding-left: 55px;
    }
    
    .cookie_consent_modal::after {
        font-size: 32px;
        top: 30px;
        left: 35px;
    }
    
    .cookie_consent_modal p {
        font-size: 17px;
        margin-bottom: 30px;
    }
    
    .cookie_consent_modal .cookie_consent_accept_btn {
        padding: 16px 32px;
        font-size: 17px;
    }
}

/* Accessibility improvements */
@media (prefers-reduced-motion: reduce) {
    .cookie_consent_modal,
    .cookie_consent_modal *,
    .cookie_consent_modal::before,
    .cookie_consent_modal::after {
        animation: none !important;
        transition: none !important;
    }
}

/* Focus states for accessibility */
.cookie_consent_modal .cookie_consent_accept_btn:focus,
.cookie_consent_modal .btn-close:focus {
    outline: 2px solid var(--cookie-primary);
    outline-offset: 2px;
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    .cookie_consent_modal {
        border-color: var(--cookie-text-primary);
        background: var(--cookie-darker-bg);
    }
    
    .cookie_consent_modal .cookie_consent_accept_btn {
        border-color: var(--cookie-text-primary);
    }
}

/* Body scroll management when cookie modal is open */
body.cookie-modal-open {
    /* Keep body scrolling enabled for cookie notice */
}

/* Ensure cookie notice appears above other elements */
.cookie_consent_modal {
    z-index: 99999 !important;
}

/* Smooth positioning for different screen orientations */
@media (orientation: landscape) and (max-height: 600px) {
    .cookie_consent_modal {
        bottom: 15px;
        max-height: calc(100vh - 30px);
        overflow-y: auto;
    }
}

/* RTL support */
[dir="rtl"] .cookie_consent_modal {
    left: auto;
    right: 30px;
}

[dir="rtl"] .cookie_consent_modal::after {
    left: auto;
    right: 30px;
}

[dir="rtl"] .cookie_consent_modal h5 {
    padding-left: 0;
    padding-right: 50px;
}

@media (max-width: 768px) {
    [dir="rtl"] .cookie_consent_modal {
        left: 20px;
        right: 20px;
    }
    
    [dir="rtl"] .cookie_consent_modal::after {
        left: auto;
        right: 25px;
    }
    
    [dir="rtl"] .cookie_consent_modal h5 {
        padding-right: 45px;
    }
}

/* Print styles - hide cookie notice when printing */
@media print {
    .cookie_consent_modal {
        display: none !important;
    }
}

/* Enhanced focus ring for better accessibility */
.cookie_consent_modal .cookie_consent_accept_btn:focus-visible,
.cookie_consent_modal .btn-close:focus-visible {
    outline: 3px solid var(--cookie-primary);
    outline-offset: 3px;
    box-shadow: 
        0 6px 20px rgba(128, 0, 0, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.1),
        0 0 0 3px rgba(128, 0, 0, 0.3);
}

/* Smooth transitions for better UX */
.cookie_consent_modal.d-none {
    transform: translateY(100px);
    opacity: 0;
    pointer-events: none;
    transition: var(--cookie-transition);
}
