/* ===== COOKIE MANAGEMENT STYLES ===== */

/* Cookie Banner */
.cookie-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background-color: var(--background-white);
    border-top: 3px solid var(--primary-color);
    box-shadow: var(--shadow-medium);
    padding: 1.5rem;
    z-index: 1000;
    transform: translateY(100%);
    transition: transform 0.3s ease;
}

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

.cookie-content {
    max-width: var(--container-max-width);
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 2rem;
    flex-wrap: wrap;
}

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

.cookie-text h3 {
    color: var(--primary-color);
    margin-bottom: 0.5rem;
    font-size: var(--font-size-large);
}

.cookie-text p {
    margin: 0;
    color: var(--text-secondary);
    line-height: 1.5;
}

.cookie-actions {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.cookie-actions .btn {
    white-space: nowrap;
    min-width: 120px;
}

/* Cookie Modal */
.cookie-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    z-index: 1001;
    display: none;
    justify-content: center;
    align-items: center;
    padding: 1rem;
}

.cookie-modal.show {
    display: flex;
}

.cookie-modal-content {
    background-color: var(--background-white);
    border-radius: var(--border-radius);
    max-width: 600px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: var(--shadow-large);
    position: relative;
}

.cookie-modal-header {
    padding: 2rem 2rem 1rem;
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    background-color: var(--background-white);
    z-index: 1;
}

.cookie-modal-header h2 {
    color: var(--primary-color);
    margin: 0;
    font-size: var(--font-size-xl);
}

.cookie-close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: var(--text-secondary);
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: var(--transition);
}

.cookie-close:hover {
    background-color: var(--background-light);
    color: var(--text-primary);
}

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

.cookie-description {
    margin-bottom: 2rem;
    color: var(--text-secondary);
    line-height: 1.6;
}

/* Cookie Categories */
.cookie-categories {
    margin-bottom: 2rem;
}

.cookie-category {
    margin-bottom: 2rem;
    padding: 1.5rem;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    background-color: var(--background-light);
}

.cookie-category:last-child {
    margin-bottom: 0;
}

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

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

.cookie-category-title {
    color: var(--primary-color);
    margin: 0 0 0.5rem 0;
    font-size: var(--font-size-large);
    font-weight: 600;
}

.cookie-category-description {
    margin: 0;
    color: var(--text-secondary);
    font-size: var(--font-size-small);
    line-height: 1.4;
}

/* Custom Checkbox Styles */
.cookie-checkbox {
    position: relative;
    display: flex;
    align-items: center;
    margin-left: 1rem;
}

.cookie-checkbox input[type="checkbox"] {
    appearance: none;
    width: 20px;
    height: 20px;
    border: 2px solid var(--border-color);
    border-radius: 4px;
    background-color: var(--background-white);
    cursor: pointer;
    position: relative;
    transition: var(--transition);
}

.cookie-checkbox input[type="checkbox"]:checked {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
}

.cookie-checkbox input[type="checkbox"]:checked::after {
    content: '✓';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: white;
    font-size: 14px;
    font-weight: bold;
}

.cookie-checkbox input[type="checkbox"]:disabled {
    background-color: var(--background-light);
    border-color: var(--border-color);
    cursor: not-allowed;
    opacity: 0.7;
}

.cookie-checkbox input[type="checkbox"]:disabled:checked {
    background-color: var(--primary-color);
    opacity: 0.8;
}

.cookie-checkbox input[type="checkbox"]:focus {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
}

.cookie-checkbox-label {
    margin-left: 0.5rem;
    font-size: var(--font-size-small);
    color: var(--text-secondary);
    cursor: pointer;
    user-select: none;
}

.cookie-checkbox input[type="checkbox"]:disabled + .cookie-checkbox-label {
    cursor: not-allowed;
    opacity: 0.7;
}

/* Cookie Details */
.cookie-details {
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid var(--border-color);
}

.cookie-details h4 {
    color: var(--primary-color);
    margin: 0 0 0.5rem 0;
    font-size: var(--font-size-base);
}

.cookie-details ul {
    margin: 0;
    padding-left: 1.5rem;
    color: var(--text-secondary);
    font-size: var(--font-size-small);
}

.cookie-details li {
    margin-bottom: 0.25rem;
}

/* Modal Actions */
.cookie-modal-actions {
    padding: 1rem 2rem 2rem;
    border-top: 1px solid var(--border-color);
    display: flex;
    gap: 1rem;
    justify-content: flex-end;
    background-color: var(--background-white);
    position: sticky;
    bottom: 0;
}

.cookie-modal-actions .btn {
    min-width: 120px;
}

/* Required Badge */
.required-badge {
    display: inline-block;
    background-color: var(--warning-color);
    color: white;
    font-size: var(--font-size-xs);
    padding: 0.25rem 0.5rem;
    border-radius: 12px;
    font-weight: 500;
    margin-left: 0.5rem;
}

/* Responsive Design */
@media (max-width: 768px) {
    .cookie-content {
        flex-direction: column;
        text-align: center;
        gap: 1rem;
    }
    
    .cookie-text {
        min-width: auto;
    }
    
    .cookie-actions {
        justify-content: center;
        width: 100%;
    }
    
    .cookie-actions .btn {
        flex: 1;
        min-width: auto;
    }
    
    .cookie-modal-content {
        margin: 1rem;
        max-height: 90vh;
    }
    
    .cookie-modal-header,
    .cookie-modal-body,
    .cookie-modal-actions {
        padding-left: 1rem;
        padding-right: 1rem;
    }
    
    .cookie-category-header {
        flex-direction: column;
        align-items: stretch;
        gap: 1rem;
    }
    
    .cookie-checkbox {
        margin-left: 0;
        justify-content: center;
    }
    
    .cookie-modal-actions {
        flex-direction: column;
    }
}

@media (max-width: 480px) {
    .cookie-banner {
        padding: 1rem;
    }
    
    .cookie-actions {
        flex-direction: column;
    }
    
    .cookie-modal-actions .btn {
        width: 100%;
    }
}