/**
 * Cookie Consent Banner Styles
 * Compatible with Ski Hermon Website Design
 */

/* באנר Cookie Consent */
.cookie-consent-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(135deg, #2c3e50 0%, #34495e 100%);
    color: white;
    padding: 20px;
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.3);
    z-index: 9999;
    transform: translateY(100%);
    transition: transform 0.3s ease-in-out;
    border-top: 3px solid #3498db;
}

.cookie-consent-banner.show {
    transform: translateY(0);
}

.cookie-consent-content {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    gap: 20px;
    flex-wrap: wrap;
}

.cookie-consent-text {
    flex: 1;
    min-width: 300px;
}

.cookie-consent-text h4 {
    margin: 0 0 8px 0;
    font-size: 18px;
    font-weight: 600;
    color: #ecf0f1;
}

.cookie-consent-text p {
    margin: 0;
    font-size: 14px;
    line-height: 1.5;
    color: #bdc3c7;
}

.cookie-consent-buttons {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

/* כפתורי Cookie Consent */
.cookie-consent-buttons .btn {
    padding: 10px 20px;
    border: none;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    white-space: nowrap;
    min-width: 120px;
}

.btn-accept {
    background: #27ae60;
    color: white;
}

.btn-accept:hover {
    background: #229954;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(39, 174, 96, 0.4);
}

.btn-reject {
    background: #e74c3c;
    color: white;
}

.btn-reject:hover {
    background: #c0392b;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(231, 76, 60, 0.4);
}

.btn-manage {
    background: transparent;
    color: #ecf0f1;
    border: 2px solid #95a5a6;
}

.btn-manage:hover {
    background: #95a5a6;
    color: #2c3e50;
    transform: translateY(-2px);
}

/* מודל ניהול העדפות */
.cookie-manage-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    padding: 20px;
}

.cookie-manage-modal.show {
    opacity: 1;
    visibility: visible;
}

.cookie-modal-content {
    background: white;
    border-radius: 12px;
    max-width: 600px;
    width: 100%;
    max-height: 80vh;
    overflow-y: auto;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
    transform: scale(0.9);
    transition: transform 0.3s ease;
}

.cookie-manage-modal.show .cookie-modal-content {
    transform: scale(1);
}

.cookie-modal-header {
    padding: 25px 30px 20px;
    border-bottom: 1px solid #ecf0f1;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.cookie-modal-header h3 {
    margin: 0;
    font-size: 24px;
    color: #2c3e50;
    font-weight: 600;
}

.close-modal {
    background: none;
    border: none;
    font-size: 28px;
    color: #95a5a6;
    cursor: pointer;
    padding: 0;
    line-height: 1;
    transition: color 0.3s ease;
}

.close-modal:hover {
    color: #e74c3c;
}

.cookie-modal-body {
    padding: 30px;
}

.cookie-category {
    margin-bottom: 30px;
    padding-bottom: 25px;
    border-bottom: 1px solid #ecf0f1;
}

.cookie-category:last-child {
    border-bottom: none;
    margin-bottom: 0;
}

.cookie-category-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.cookie-category-header h4 {
    margin: 0;
    font-size: 18px;
    color: #2c3e50;
    font-weight: 600;
}

.cookie-category p {
    margin: 0;
    color: #7f8c8d;
    line-height: 1.6;
    font-size: 14px;
}

/* מתגי Toggle */
.switch {
    position: relative;
    display: inline-block;
    width: 50px;
    height: 24px;
}

.switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #ccc;
    transition: .3s;
    border-radius: 24px;
}

.slider:before {
    position: absolute;
    content: "";
    height: 18px;
    width: 18px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: .3s;
    border-radius: 50%;
}

input:checked + .slider {
    background-color: #3498db;
}

input:checked + .slider:before {
    transform: translateX(26px);
}

.switch.disabled {
    opacity: 0.6;
    pointer-events: none;
}

.switch.disabled .slider {
    background-color: #95a5a6;
}

.cookie-modal-footer {
    padding: 20px 30px 30px;
    text-align: center;
    border-top: 1px solid #ecf0f1;
}

.btn-save {
    background: #3498db;
    color: white;
    padding: 12px 30px;
    border: none;
    border-radius: 6px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    min-width: 150px;
}

.btn-save:hover {
    background: #2980b9;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(52, 152, 219, 0.4);
}

/* תמיכה במובייל */
@media (max-width: 768px) {
    .cookie-consent-content {
        flex-direction: column;
        text-align: center;
        gap: 15px;
    }
    
    .cookie-consent-text {
        min-width: auto;
    }
    
    .cookie-consent-buttons {
        justify-content: center;
        width: 100%;
    }
    
    .cookie-consent-buttons .btn {
        flex: 1;
        min-width: auto;
    }
    
    .cookie-modal-content {
        margin: 10px;
        max-height: 90vh;
    }
    
    .cookie-modal-header,
    .cookie-modal-body,
    .cookie-modal-footer {
        padding: 20px;
    }
    
    .cookie-category-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
}

@media (max-width: 480px) {
    .cookie-consent-banner {
        padding: 15px;
    }
    
    .cookie-consent-buttons {
        flex-direction: column;
    }
    
    .cookie-consent-buttons .btn {
        width: 100%;
    }
    
    .cookie-modal-header h3 {
        font-size: 20px;
    }
    
    .cookie-category-header {
        align-items: center;
        flex-direction: row;
    }
}

/* תמיכה ב-RTL לעברית */
[dir="rtl"] .cookie-consent-content {
    direction: rtl;
}

[dir="rtl"] .cookie-modal-content {
    direction: rtl;
}

[dir="rtl"] .close-modal {
    transform: scaleX(-1);
}

/* אנימציות נוספות */
@keyframes slideUp {
    from {
        transform: translateY(100%);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: scale(0.9);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

.cookie-consent-banner.show {
    animation: slideUp 0.3s ease-out;
}

.cookie-manage-modal.show .cookie-modal-content {
    animation: fadeIn 0.3s ease-out;
}

/* עיצוב לינק Cookie Settings בfooter */
.cookie-settings-link {
    color: inherit !important;
    text-decoration: none !important;
    transition: opacity 0.3s ease;
    display: inline-block;
}

.cookie-settings-link:hover {
    opacity: 0.8;
    text-decoration: underline !important;
}

.contact-list_item .cookie-settings-link {
    color: white !important;
}

/* תמיכה נוספת לעיצוב באתר */
.footer .cookie-settings-link {
    color: white !important;
    font-size: inherit;
}

.footer .cookie-settings-link:hover {
    color: #ecf0f1 !important;
}
