/* Consent Mode V2 Banner Styles */

/* Modal container */
#cmv2-modal.cmv2-hidden { 
    display: none; 
}

#cmv2-modal { 
    position: fixed; 
    inset: 0; 
    z-index: 2147483647;
    animation: cmv2-fadeIn 0.3s ease-out;
}

/* Backdrop */
#cmv2-modal .cmv2-backdrop { 
    position: absolute; 
    inset: 0;
    animation: cmv2-backdropFade 0.3s ease-out;
}

/* Modal window */
#cmv2-modal .cmv2-window {
    position: relative; 
    max-width: 680px; 
    margin: 10vh auto; 
    box-shadow: 0 10px 40px rgba(0,0,0,0.2);
    padding: 24px;
    font-family: system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
    animation: cmv2-slideUp 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Animations */
@keyframes cmv2-fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes cmv2-backdropFade {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes cmv2-slideUp {
    from {
        opacity: 0;
        transform: translateY(40px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

/* Typography */
#cmv2-modal h2 { 
    margin: 0 0 8px; 
    font-size: 22px; 
}

#cmv2-modal p { 
    margin: 8px 0; 
    line-height: 1.5; 
}

#cmv2-modal a {
    text-decoration: underline;
}

#cmv2-modal a:hover {
    text-decoration: none;
}

/* Views */
.cmv2-view {
    margin-top: 20px;
}

.cmv2-view.cmv2-hidden {
    display: none;
}

/* Groups (detailed view) */
.cmv2-groups { 
    margin-top: 16px; 
    margin-bottom: 20px;
}

.cmv2-row {
    display: flex; 
    align-items: center; 
    justify-content: space-between;
    padding: 14px 0; 
}

.cmv2-row:last-child { 
    border-bottom: none; 
}

.cmv2-row span {
    font-size: 15px;
    font-weight: 500;
}

.cmv2-row input[type="checkbox"] { 
    transform: scale(1.4); 
    cursor: pointer; 
    width: initial !important;
}

.cmv2-disabled { 
    opacity: .6; 
}

.cmv2-disabled input { 
    cursor: not-allowed; 
}

/* Actions (buttons) */
.cmv2-actions { 
    display: flex; 
    gap: 12px; 
    margin-top: 20px; 
    flex-wrap: wrap; 
}

/* Simple view - large buttons stacked */
#cmv2-simple-view .cmv2-actions {
    flex-direction: column;
    gap: 10px;
}

#cmv2-simple-view .cmv2-actions .cmv2-btn {
    width: 100%;
    text-align: center;
    padding: 16px 24px;
    font-size: 16px;
    font-weight: 700;
    border-radius: 10px;
}

/* Detailed view - normal buttons in row */
#cmv2-detailed-view .cmv2-actions {
    flex-direction: row;
    justify-content: flex-end;
    gap: 12px;
}

#cmv2-detailed-view .cmv2-actions .cmv2-btn {
    flex: 0 0 auto;
}

/* Buttons */
.cmv2-btn {
    background: #f8f8f8; 
    padding: 12px 20px; 
    border-radius: 8px;
    cursor: pointer; 
    font-weight: 600;
    transition: all 0.2s ease;
    font-size: 15px;
    border: none;
    outline: none;
    line-height: 1.4;
}

.cmv2-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.18);
}

.cmv2-btn:active {
    transform: translateY(0);
    box-shadow: 0 2px 6px rgba(0,0,0,0.15);
}

.cmv2-primary { 
    /* Colors will be injected via inline style */
}

.cmv2-secondary { 
    /* Colors will be injected via inline style */
}

/* Cookie settings button (reopener) */
.cmv2-open {
    position: fixed; 
    left: 16px; 
    bottom: 16px; 
    z-index: 2147483646;
    border-radius: 999px; 
    padding: 12px 18px; 
    cursor: pointer;
    font-family: system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
    font-weight: 600;
    box-shadow: 0 2px 10px rgba(0,0,0,0.2);
    transition: all 0.2s ease;
    border: none;
    outline: none;
    font-size: 14px;
}

.cmv2-open:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(0,0,0,0.3);
}

/* Responsive */
@media (max-width: 480px) {
    #cmv2-modal .cmv2-window { 
        margin: 4vh 8px; 
        padding: 20px; 
    }
    
    .cmv2-actions { 
        flex-direction: column; 
    }
    
    .cmv2-btn { 
        width: 100%; 
        text-align: center; 
    }
    
    #cmv2-detailed-view .cmv2-actions {
        flex-direction: column;
    }
    
    #cmv2-detailed-view .cmv2-actions .cmv2-btn {
        width: 100%;
    }
}
