/* Base template styling - extracted from base.html - bootstrap first*/

/* ==============================================
   NOTA: Bootstrap button classes werken correct zonder custom CSS.
   Alle button styling komt van Bootstrap 5.3.0
   ============================================== */

/* ==============================================
   HEADER & LAYOUT STYLES
   Bootstrap handles: badges, borders, padding, margins, colors
   ============================================== */

/* Theme toggle: alleen zichtbaar op openbare pagina's (iframe/WordPress) */
.theme-toggle-openbaar {
    display: none !important;
}
body[data-openbaar="true"] .theme-toggle-openbaar {
    display: inline-block !important;
}

/* Openbare pagina's: verberg status-badges voor stillere iframe-header */
body[data-openbaar="true"] #headerStatusBadges {
    display: none !important;
}

/* Cookie Banner - alleen z-index en animatie */
.cookie-banner {
    z-index: 1050;
}

/* Header margin-top wanneer cookie banner zichtbaar is om overlap te voorkomen */
/* Cookie banner heeft variabele hoogte, gebruik JavaScript class voor betere browser support */
body.cookie-banner-visible header {
    margin-top: 80px; /* Ruimte voor cookie banner (kan variëren op mobiel) */
}

@media (max-width: 768px) {
    body.cookie-banner-visible header {
        margin-top: 100px; /* Meer ruimte op mobiel voor langere tekst */
    }
}

/* Cookie Banner Animation - slideDown animatie van boven */
.cookie-banner:not(.d-none) {
    animation: slideDown 0.3s ease-out;
}

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

/* Responsive Design - alleen nodig voor specifieke layout aanpassingen */
@media (max-width: 768px) {
    #periodeRondeSelector .d-flex.justify-content-center {
        flex-direction: row;
        align-items: center !important;
        justify-content: center !important;
        flex-wrap: wrap;
    }

    #periodeRondeSelector select {
        width: auto !important;
        min-width: 90px !important;
    }

    #globalActionButton {
        width: auto !important;
        margin-left: 0.25rem;
    }
    
    /* Button groups better wrapping on mobile */
    .btn-group {
        flex-wrap: wrap;
    }
    
    /* Cookie banner mobile optimization */
    .cookie-banner {
        padding: 0.75rem !important;
    }
    
    .cookie-banner h5 {
        font-size: 1rem;
    }
    
    .cookie-banner p {
        font-size: 0.875rem;
    }
    
    /* Header badges better spacing on mobile */
    header .badge {
        font-size: 0.75rem;
        padding: 0.25rem 0.5rem;
    }
}

/* Reduced Motion Support */
@media (prefers-reduced-motion: reduce) {
    .cookie-banner {
        animation: none;
    }
}

/* Print Styles */
@media print {
    .cookie-banner,
    #periodeRondeSelector,
    #databaseStatusHeader,
    .theme-toggle-openbaar {
        display: none !important;
    }
}

/* Dark Mode Support - Bootstrap compatible */
@media (prefers-color-scheme: dark) {
    .cookie-banner {
        background-color: #2d3748 !important;
        border-bottom-color: #4a5568 !important;
        color: #e2e8f0;
    }

    #periodeRondeSelector {
        background-color: #2d3748 !important;
        border-color: #4a5568 !important;
    }
}
