/**
 * Cookie Banner Styles
 */

/* Banner Container */
.cookie-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: white;
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.15);
    z-index: 9999;
    transform: translateY(100%);
    transition: transform 0.3s ease-in-out;
    border-top: 3px solid #0066CC;
}

.cookie-banner-visible {
    transform: translateY(0);
}

.cookie-banner-content {
    max-width: 1280px;
    margin: 0 auto;
    padding: 1.5rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 2rem;
}

.cookie-banner-text {
    flex: 1;
}

.cookie-banner-title {
    font-size: 1.125rem;
    font-weight: 600;
    color: #1F2937;
    margin: 0 0 0.5rem 0;
}

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

.cookie-banner-link {
    color: #0066CC;
    text-decoration: underline;
    transition: color 0.2s;
}

.cookie-banner-link:hover {
    color: #0052A3;
}

.cookie-banner-buttons {
    display: flex;
    gap: 0.75rem;
    flex-shrink: 0;
}

/* Cookie Buttons */
.cookie-btn {
    padding: 0.625rem 1.25rem;
    font-size: 0.875rem;
    font-weight: 600;
    border-radius: 0.375rem;
    border: none;
    cursor: pointer;
    transition: all 0.2s;
    white-space: nowrap;
}

.cookie-btn-primary {
    background: #0066CC;
    color: white;
}

.cookie-btn-primary:hover {
    background: #0052A3;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 102, 204, 0.3);
}

.cookie-btn-secondary {
    background: #F3F4F6;
    color: #1F2937;
}

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

.cookie-btn-outline {
    background: transparent;
    color: #0066CC;
    border: 2px solid #0066CC;
}

.cookie-btn-outline:hover {
    background: #0066CC;
    color: white;
}

/* Settings Modal */
.cookie-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s, visibility 0.3s;
}

.cookie-modal-visible {
    opacity: 1;
    visibility: visible;
}

.cookie-modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(2px);
}

.cookie-modal-content {
    position: relative;
    background: white;
    border-radius: 0.75rem;
    max-width: 600px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    transform: scale(0.9);
    transition: transform 0.3s;
}

.cookie-modal-visible .cookie-modal-content {
    transform: scale(1);
}

.cookie-modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.5rem;
    border-bottom: 1px solid #E5E7EB;
}

.cookie-modal-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: #1F2937;
    margin: 0;
}

.cookie-modal-close {
    background: transparent;
    border: none;
    cursor: pointer;
    color: #6B7280;
    padding: 0.5rem;
    border-radius: 0.375rem;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.cookie-modal-close:hover {
    background: #F3F4F6;
    color: #1F2937;
}

.cookie-modal-close svg {
    width: 1.5rem;
    height: 1.5rem;
}

.cookie-modal-body {
    padding: 1.5rem;
}

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

/* Cookie Categories */
.cookie-category {
    margin-bottom: 1.5rem;
    padding: 1rem;
    background: #F9FAFB;
    border-radius: 0.5rem;
    border: 1px solid #E5E7EB;
}

.cookie-category-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
}

.cookie-category-info {
    flex: 1;
}

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

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

/* Toggle Switch */
.cookie-toggle {
    flex-shrink: 0;
}

.cookie-toggle input[type="checkbox"] {
    display: none;
}

.cookie-toggle-label {
    display: block;
    cursor: pointer;
}

.cookie-toggle-text {
    font-size: 0.75rem;
    color: #6B7280;
    font-weight: 500;
}

.cookie-toggle-switch {
    position: relative;
    width: 48px;
    height: 24px;
    background: #D1D5DB;
    border-radius: 12px;
    transition: background 0.3s;
}

.cookie-toggle-switch .cookie-toggle-slider {
    position: absolute;
    top: 2px;
    left: 2px;
    width: 20px;
    height: 20px;
    background: white;
    border-radius: 50%;
    transition: transform 0.3s;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.cookie-toggle input[type="checkbox"]:checked + .cookie-toggle-switch {
    background: #0066CC;
}

.cookie-toggle input[type="checkbox"]:checked + .cookie-toggle-switch .cookie-toggle-slider {
    transform: translateX(24px);
}

.cookie-toggle input[type="checkbox"]:disabled + .cookie-toggle-switch {
    background: #9CA3AF;
    cursor: not-allowed;
}

.cookie-modal-info {
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid #E5E7EB;
}

.cookie-modal-footer {
    display: flex;
    gap: 0.75rem;
    padding: 1.5rem;
    border-top: 1px solid #E5E7EB;
    background: #F9FAFB;
    border-bottom-left-radius: 0.75rem;
    border-bottom-right-radius: 0.75rem;
}

.cookie-modal-footer .cookie-btn {
    flex: 1;
}

/* Responsive Design */
@media (max-width: 768px) {
    .cookie-banner-content {
        flex-direction: column;
        align-items: stretch;
        gap: 1rem;
    }

    .cookie-banner-buttons {
        flex-direction: column;
        width: 100%;
    }

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

    .cookie-modal-content {
        width: 95%;
        max-height: 95vh;
    }

    .cookie-modal-header {
        padding: 1rem;
    }

    .cookie-modal-title {
        font-size: 1.25rem;
    }

    .cookie-modal-body {
        padding: 1rem;
    }

    .cookie-modal-footer {
        flex-direction: column;
        padding: 1rem;
    }

    .cookie-category-header {
        flex-direction: column;
        gap: 0.75rem;
    }

    .cookie-toggle {
        align-self: flex-start;
    }
}

/* Accessibility */
.cookie-btn:focus,
.cookie-modal-close:focus {
    outline: 2px solid #0066CC;
    outline-offset: 2px;
}

.cookie-toggle input[type="checkbox"]:focus + .cookie-toggle-switch {
    outline: 2px solid #0066CC;
    outline-offset: 2px;
}

/* Print styles */
@media print {
    .cookie-banner,
    .cookie-modal {
        display: none !important;
    }
}
