/* Cookie Consent Manager - Frontend Styles */

.ccm-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    animation: ccmFadeIn 0.3s ease forwards;
}

.ccm-overlay.ccm-position-bottom {
    position: sticky;
    bottom: 0;
    top: auto;
    height: auto;
    background-color: transparent;
    padding: 0;
    margin: 0;
    width: 100vw;
    display: block;
    opacity: 1;
    animation: none;
}

@keyframes ccmFadeIn {
    to {
        opacity: 1;
    }
}

.ccm-overlay.ccm-hiding {
    animation: ccmFadeOut 0.3s ease forwards;
}

@keyframes ccmFadeOut {
    to {
        opacity: 0;
    }
}

.ccm-banner {
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
    transform: scale(0.9);
    animation: ccmScaleIn 0.3s ease 0.1s forwards;
    direction: rtl;
}

.ccm-position-bottom .ccm-banner {
    position: relative;
    width: 100vw;
    max-width: 100vw;
    margin-left: calc(50% - 50vw);
    margin-right: calc(50% - 50vw);
    box-shadow: 0 -5px 20px rgba(0, 0, 0, 0.2);
    transform: none;
    animation: ccmSlideUp 0.4s ease forwards;
    box-sizing: border-box;
}

@keyframes ccmSlideUp {
    from {
        transform: translateY(100%);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

@keyframes ccmScaleIn {
    to {
        transform: scale(1);
    }
}

.ccm-banner-content {
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-orient: vertical;
    -webkit-box-direction: normal;
    -ms-flex-direction: column;
    flex-direction: column;
    width: 100%;
}

.ccm-banner-content.horizontal {
    -webkit-box-orient: horizontal;
    -webkit-box-direction: normal;
    -ms-flex-direction: row;
    flex-direction: row;
    -ms-flex-wrap: wrap;
    flex-wrap: wrap;
    -webkit-box-align: center;
    -ms-flex-align: center;
    align-items: center;
    -webkit-box-pack: center;
    -ms-flex-pack: center;
    justify-content: center;
    gap: 20px;
}

.ccm-banner-text {
    line-height: 1.6;
    margin-bottom: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

.ccm-banner-text .ccm-link {
    color: inherit;
    text-decoration: underline;
    font-weight: 600;
    transition: opacity 0.2s ease;
}

.ccm-banner-text .ccm-link:hover {
    opacity: 0.8;
    text-decoration: underline;
}

.ccm-banner-content.horizontal .ccm-banner-text {
    flex: 0 0 auto;
}

.ccm-button-wrapper {
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    width: 100%;
}

.ccm-button-wrapper[data-align="right"] {
    -webkit-box-pack: end;
    -ms-flex-pack: end;
    justify-content: flex-end;
}

.ccm-button-wrapper[data-align="center"] {
    -webkit-box-pack: center;
    -ms-flex-pack: center;
    justify-content: center;
}

.ccm-button-wrapper[data-align="left"] {
    -webkit-box-pack: start;
    -ms-flex-pack: start;
    justify-content: flex-start;
}

.ccm-banner-content.horizontal .ccm-button-wrapper {
    width: auto;
}

.ccm-accept-button {
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: 600;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    display: inline-block;
}

.ccm-accept-button:hover {
    transform: translateY(-2px);
}

.ccm-accept-button:active {
    transform: translateY(0);
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .ccm-overlay.ccm-position-bottom {
        padding: 0;
    }
    
    .ccm-position-bottom .ccm-banner {
        position: relative;
        width: 100vw;
        max-width: 100vw;
        margin-left: calc(50% - 50vw);
        margin-right: calc(50% - 50vw);
        box-sizing: border-box;
    }
    
    .ccm-banner-content.horizontal {
        -webkit-box-orient: vertical;
        -webkit-box-direction: normal;
        -ms-flex-direction: column;
        flex-direction: column;
    }
    
    .ccm-banner-content.horizontal .ccm-button-wrapper {
        width: 100%;
    }
}

/* Accessibility */
.ccm-accept-button:focus {
    outline: none;
}

/* RTL Support */
[dir="rtl"] .ccm-banner {
    text-align: center;
}

/* Print - Hide banner when printing */
@media print {
    .ccm-overlay {
        display: none !important;
    }
}

