/* ================================
   Werkbrug Netherlands Logo Styles
   ================================ */

/* Root Logo Variables */
:root {
    --logo-primary-height: 40px;
    --logo-mobile-height: 32px;
    --logo-footer-height: 30px;
    --logo-transition: all 0.3s ease;
}

/* Main Logo Container */
.navbar-brand {
    display: flex;
    align-items: center;
    gap: 12px;
    transition: var(--logo-transition);
    text-decoration: none;
    padding: 8px 0;
}

.navbar-brand:hover {
    transform: scale(1.02);
    text-decoration: none;
}

/* Logo Image Styles */
.logo-main {
    height: var(--logo-primary-height);
    width: auto;
    max-width: 200px;
    object-fit: contain;
    transition: var(--logo-transition);
}

.logo-mobile {
    height: var(--logo-mobile-height);
    width: auto;
    max-width: 150px;
    object-fit: contain;
    display: none;
}

.logo-footer {
    height: var(--logo-footer-height);
    width: auto;
    max-width: 120px;
    object-fit: contain;
    filter: brightness(0.9);
}

/* Icon Fallback (when no logo image is uploaded) */
.logo-icon-fallback {
    font-size: 1.8rem;
    color: var(--werkbrug-orange);
    margin-right: 8px;
}

.brand-text {
    font-weight: 700;
    font-size: 1.25rem;
    color: var(--werkbrug-dark);
    margin: 0;
}

/* Responsive Logo Behavior */
@media (max-width: 768px) {
    .logo-main {
        display: none;
    }
    
    .logo-mobile {
        display: block;
    }
    
    .brand-text {
        font-size: 1.1rem;
    }
    
    .navbar-brand {
        gap: 8px;
    }
}

@media (max-width: 480px) {
    .logo-mobile {
        height: 28px;
    }
    
    .brand-text {
        display: none; /* Hide text on very small screens, show only logo */
    }
    
    .logo-icon-fallback {
        font-size: 1.5rem;
    }
}

/* Logo Loading States */
.logo-loading {
    opacity: 0.5;
    animation: logoLoading 1.5s infinite;
}

@keyframes logoLoading {
    0%, 100% { opacity: 0.5; }
    50% { opacity: 0.8; }
}

.logo-loaded {
    opacity: 1;
    animation: logoFadeIn 0.5s ease;
}

@keyframes logoFadeIn {
    from { opacity: 0; transform: scale(0.9); }
    to { opacity: 1; transform: scale(1); }
}

/* Dark Theme Logo Support */
@media (prefers-color-scheme: dark) {
    .logo-main,
    .logo-mobile,
    .logo-footer {
        filter: brightness(1.1) contrast(0.9);
    }
}

/* Logo Hover Effects */
.navbar-brand:hover .logo-main,
.navbar-brand:hover .logo-mobile {
    filter: brightness(1.1);
}

/* Footer Logo Styles */
.footer-brand .navbar-brand {
    justify-content: center;
    padding: 0;
}

.footer-brand .brand-text {
    color: #666;
    font-size: 1.1rem;
}

/* Logo Print Styles */
@media print {
    .logo-main,
    .logo-mobile {
        filter: grayscale(1);
        height: 25px;
    }
    
    .brand-text {
        color: #000 !important;
    }
}

/* High DPI Display Support */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
    .logo-main,
    .logo-mobile,
    .logo-footer {
        image-rendering: -webkit-optimize-contrast;
        image-rendering: crisp-edges;
    }
}

/* Logo Accessibility */
.logo-main,
.logo-mobile,
.logo-footer {
    alt: "Werkbrug Netherlands Logo";
}

/* Error State for Missing Logos */
.logo-error {
    background: #f8f9fa;
    border: 2px dashed #dee2e6;
    border-radius: 8px;
    padding: 10px;
    text-align: center;
    color: #6c757d;
    font-size: 0.8rem;
}

.logo-error::before {
    content: "🖼️ Logo niet gevonden";
}

/* Logo Management Styles (for admin) */
.logo-upload-area {
    border: 3px dashed #ddd;
    border-radius: 12px;
    padding: 40px;
    text-align: center;
    transition: all 0.3s ease;
    cursor: pointer;
    background: #fafafa;
}

.logo-upload-area:hover {
    border-color: var(--werkbrug-orange);
    background: #fff5f0;
}

.logo-upload-area.dragover {
    border-color: var(--werkbrug-blue);
    background: #f0f8ff;
    transform: scale(1.02);
}

/* Toast Notifications for Logo System */
.toast-notification {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 9999;
    max-width: 350px;
    border-radius: 10px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    animation: slideInRight 0.3s ease;
}

.toast-info {
    background: linear-gradient(135deg, #d1ecf1, #bee5eb);
    border: 1px solid #bee5eb;
    color: #0c5460;
}

.toast-success {
    background: linear-gradient(135deg, #d4edda, #c3e6cb);
    border: 1px solid #c3e6cb;
    color: #155724;
}

.toast-error {
    background: linear-gradient(135deg, #f8d7da, #f5c6cb);
    border: 1px solid #f5c6cb;
    color: #721c24;
}

.toast-warning {
    background: linear-gradient(135deg, #fff3cd, #ffeaa7);
    border: 1px solid #ffeaa7;
    color: #856404;
}

.toast-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 16px;
}

.toast-close {
    background: none;
    border: none;
    font-size: 18px;
    cursor: pointer;
    padding: 0;
    margin-left: 10px;
    opacity: 0.7;
    transition: opacity 0.2s ease;
}

.toast-close:hover {
    opacity: 1;
}

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

/* Loading Overlay for Logo Operations */
.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 10000;
    animation: fadeIn 0.3s ease;
}

.loading-content {
    background: white;
    padding: 30px;
    border-radius: 15px;
    text-align: center;
    box-shadow: 0 8px 32px rgba(0,0,0,0.3);
}

.spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid var(--werkbrug-orange);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 15px;
}

.loading-text {
    color: var(--werkbrug-dark);
    font-weight: 500;
    font-size: 1.1rem;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* Logo Integration Classes */
.with-logo .logo-icon-fallback {
    display: none;
}

.without-logo .logo-main,
.without-logo .logo-mobile {
    display: none;
}

/* Navbar with Logo Adjustments */
.navbar.with-logo {
    padding-top: 12px;
    padding-bottom: 12px;
}

.navbar.with-logo .navbar-brand {
    padding: 4px 0;
}

/* Logo Preloader */
.logo-preloader {
    display: inline-block;
    width: 40px;
    height: 40px;
    background: linear-gradient(45deg, var(--werkbrug-orange), var(--werkbrug-blue));
    border-radius: 8px;
    animation: logoPreloader 1s ease-in-out infinite;
}

@keyframes logoPreloader {
    0%, 100% { transform: scale(1) rotate(0deg); }
    50% { transform: scale(1.1) rotate(180deg); }
}

/* Mobile Navigation Logo Adjustments */
.navbar-toggler {
    border: none;
    padding: 4px 8px;
}

.navbar-toggler:focus {
    box-shadow: none;
}

/* Ensure proper logo spacing in collapsed navbar */
@media (max-width: 991.98px) {
    .navbar-brand {
        margin-right: auto;
    }
    
    .navbar-nav {
        margin-top: 10px;
    }
}

/* Logo Quality Settings */
.logo-main,
.logo-mobile,
.logo-footer {
    image-rendering: optimizeQuality;
    -ms-interpolation-mode: bicubic;
}

/* Favicon Styles */
link[rel="icon"] {
    transition: all 0.3s ease;
}

/* Company Logo Styles (for company profile pages) */
.company-logo-large {
    width: 120px;
    height: 120px;
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3rem;
    flex-shrink: 0;
    object-fit: contain;
    background: rgba(255,255,255,0.1);
    backdrop-filter: blur(10px);
}

.company-logo-large img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    border-radius: 12px;
}

/* Utility Classes */
.logo-center {
    display: flex;
    justify-content: center;
    align-items: center;
}

.logo-left {
    display: flex;
    justify-content: flex-start;
    align-items: center;
}

.logo-right {
    display: flex;
    justify-content: flex-end;
    align-items: center;
}

/* Logo Animation Classes */
.logo-bounce {
    animation: logoBounce 2s ease-in-out infinite;
}

@keyframes logoBounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-5px); }
}

.logo-pulse {
    animation: logoPulse 2s ease-in-out infinite;
}

@keyframes logoPulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
} 