/* Cookie Consent Modal - Google Ads Compliant */

/* Modal Overlay */
.cookie-consent-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(4px);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    animation: fadeIn 0.3s ease-in-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

/* Modal Container */
.cookie-consent-modal {
    background: #ffffff;
    border-radius: 16px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    max-width: 600px;
    width: 100%;
    max-height: 85vh;
    overflow-y: auto;
    animation: slideUp 0.3s ease-out;
    position: relative;
}

@keyframes slideUp {
    from {
        transform: translateY(30px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

/* Modal Header */
.cookie-consent-header {
    padding: 1.5rem;
    border-bottom: 1px solid #e5e7eb;
}

.cookie-consent-header h2 {
    margin: 0 0 0.5rem 0;
    font-size: 1.25rem;
    font-weight: 700;
    color: #111827;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.cookie-icon {
    font-size: 1.5rem;
}

.cookie-consent-header p {
    margin: 0;
    font-size: 0.875rem;
    color: #6b7280;
    line-height: 1.4;
}

/* Modal Body */
.cookie-consent-body {
    padding: 1.5rem;
}

/* Cookie Categories */
.cookie-category {
    margin-bottom: 1rem;
    padding: 0.75rem;
    background: #f9fafb;
    border-radius: 6px;
    border: 1px solid #e5e7eb;
}

.cookie-category-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
}

.cookie-category-title {
    font-weight: 600;
    font-size: 1rem;
    color: #111827;
    margin: 0;
}

.cookie-category-description {
    font-size: 0.875rem;
    color: #6b7280;
    margin: 0;
    line-height: 1.5;
}

/* Toggle Switch */
.toggle-switch {
    position: relative;
    display: inline-block;
    width: 48px;
    height: 24px;
}

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

.toggle-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #d1d5db;
    transition: 0.3s;
    border-radius: 24px;
}

.toggle-slider:before {
    position: absolute;
    content: "";
    height: 18px;
    width: 18px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: 0.3s;
    border-radius: 50%;
}

.toggle-switch input:checked + .toggle-slider {
    background-color: #3b82f6;
}

.toggle-switch input:checked + .toggle-slider:before {
    transform: translateX(24px);
}

.toggle-switch input:disabled + .toggle-slider {
    background-color: #9ca3af;
    cursor: not-allowed;
}

/* Privacy Link */
.cookie-privacy-link {
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid #e5e7eb;
}

.cookie-privacy-link a {
    color: #3b82f6;
    text-decoration: none;
    font-size: 0.875rem;
    font-weight: 500;
}

.cookie-privacy-link a:hover {
    text-decoration: underline;
}

/* Modal Footer */
.cookie-consent-footer {
    padding: 1.5rem 2rem;
    border-top: 1px solid #e5e7eb;
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

/* Buttons */
.cookie-btn {
    flex: 1;
    min-width: 140px;
    padding: 0.875rem 1.5rem;
    border: none;
    border-radius: 8px;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    text-align: center;
}

.cookie-btn-primary {
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
    color: white;
}

.cookie-btn-primary:hover {
    background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
}

.cookie-btn-secondary {
    background: #f3f4f6;
    color: #374151;
    border: 1px solid #d1d5db;
}

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

.cookie-btn-reject {
    background: transparent;
    color: #6b7280;
    border: 1px solid #d1d5db;
}

.cookie-btn-reject:hover {
    background: #f9fafb;
    color: #374151;
}

/* Responsive */
@media (max-width: 640px) {
    .cookie-consent-modal {
        max-height: 90vh;
        border-radius: 12px 12px 0 0;
    }

    .cookie-consent-header {
        padding: 1rem 1.25rem;
    }

    .cookie-consent-header h2 {
        font-size: 1.1rem;
    }

    .cookie-consent-header p {
        font-size: 0.8rem;
        line-height: 1.3;
    }

    .cookie-icon {
        font-size: 1.25rem;
    }

    .cookie-consent-body {
        padding: 1rem 1.25rem;
    }

    .cookie-category {
        margin-bottom: 0.75rem;
        padding: 0.6rem;
    }

    .cookie-category-title {
        font-size: 0.9rem;
    }

    .cookie-category-description {
        font-size: 0.75rem;
        line-height: 1.3;
    }

    .cookie-privacy-link {
        margin-top: 0.75rem;
        padding-top: 0.75rem;
    }

    .cookie-privacy-link a {
        font-size: 0.75rem;
    }

    .cookie-consent-footer {
        flex-direction: column;
        padding: 0.75rem 1.25rem 1rem;
        gap: 0.5rem;
    }

    .cookie-btn {
        min-width: 100%;
        width: 100%;
        padding: 0.75rem 1rem;
        font-size: 0.875rem;
    }
}

/* Accessibility */
.cookie-consent-modal:focus {
    outline: 2px solid #3b82f6;
    outline-offset: 2px;
}

/* Hidden state */
.cookie-consent-hidden {
    display: none !important;
}

/* Smooth scrollbar */
.cookie-consent-modal::-webkit-scrollbar {
    width: 8px;
}

.cookie-consent-modal::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 10px;
}

.cookie-consent-modal::-webkit-scrollbar-thumb {
    background: #d1d5db;
    border-radius: 10px;
}

.cookie-consent-modal::-webkit-scrollbar-thumb:hover {
    background: #9ca3af;
}

