/* ===== MEJORAS PARA EL LOGO - SISTEMA DE RIFAS ===== */

/* Contenedor principal del logo */
.navbar-brand {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.5rem 1rem;
    border-radius: 0.75rem;
    transition: all 0.3s ease;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.navbar-brand:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2);
}

/* Logo circular mejorado */
.navbar-brand img,
.navbar-brand .logo-image {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid rgba(255, 255, 255, 0.3);
    box-shadow: 
        0 4px 15px rgba(0, 0, 0, 0.3),
        inset 0 0 0 1px rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
    background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);
}

.navbar-brand:hover img,
.navbar-brand:hover .logo-image {
    border-color: rgba(255, 255, 255, 0.6);
    box-shadow: 
        0 8px 25px rgba(0, 0, 0, 0.4),
        inset 0 0 0 2px rgba(255, 255, 255, 0.2);
    transform: scale(1.05);
}

/* Texto del logo */
.navbar-brand .logo-text {
    font-size: 1.4rem;
    font-weight: 800;
    color: #ffffff !important;
    text-shadow: 
        0 2px 4px rgba(0, 0, 0, 0.3),
        0 0 20px rgba(255, 255, 255, 0.2);
    letter-spacing: 1px;
    white-space: nowrap;
    transition: all 0.3s ease;
}

.navbar-brand:hover .logo-text {
    text-shadow: 
        0 4px 8px rgba(0, 0, 0, 0.4),
        0 0 30px rgba(255, 255, 255, 0.3);
    transform: scale(1.02);
}

/* Logo con ícono (si no hay imagen) */
.navbar-brand .logo-icon {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    background: linear-gradient(135deg, #fbbf24 0%, #f59e0b 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    border: 3px solid rgba(255, 255, 255, 0.3);
    box-shadow: 
        0 4px 15px rgba(0, 0, 0, 0.3),
        inset 0 0 0 1px rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
}

.navbar-brand .logo-icon i {
    font-size: 1.8rem;
    color: #ffffff;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.navbar-brand:hover .logo-icon {
    border-color: rgba(255, 255, 255, 0.6);
    box-shadow: 
        0 8px 25px rgba(0, 0, 0, 0.4),
        inset 0 0 0 2px rgba(255, 255, 255, 0.2);
    transform: scale(1.05);
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
}

/* Logo en modo móvil */
@media (max-width: 768px) {
    .navbar-brand {
        padding: 0.4rem 0.8rem;
        gap: 0.5rem;
    }
    
    .navbar-brand img,
    .navbar-brand .logo-image,
    .navbar-brand .logo-icon {
        width: 38px;
        height: 38px;
    }
    
    .navbar-brand .logo-text {
        font-size: 1.1rem;
        letter-spacing: 0.5px;
    }
    
    .navbar-brand .logo-icon i {
        font-size: 1.5rem;
    }
}

@media (max-width: 576px) {
    .navbar-brand {
        padding: 0.3rem 0.6rem;
        gap: 0.4rem;
    }
    
    .navbar-brand img,
    .navbar-brand .logo-image,
    .navbar-brand .logo-icon {
        width: 32px;
        height: 32px;
    }
    
    .navbar-brand .logo-text {
        font-size: 0.95rem;
        letter-spacing: 0.3px;
    }
    
    .navbar-brand .logo-icon i {
        font-size: 1.3rem;
    }
}

/* Logo en modo oscuro */
@media (prefers-color-scheme: dark) {
    .navbar-brand {
        background: rgba(0, 0, 0, 0.2);
    }
    
    .navbar-brand:hover {
        background: rgba(0, 0, 0, 0.3);
    }
    
    .navbar-brand img,
    .navbar-brand .logo-image {
        border-color: rgba(255, 255, 255, 0.4);
        box-shadow: 
            0 4px 15px rgba(0, 0, 0, 0.5),
            inset 0 0 0 1px rgba(255, 255, 255, 0.2);
    }
    
    .navbar-brand:hover img,
    .navbar-brand:hover .logo-image {
        border-color: rgba(255, 255, 255, 0.7);
        box-shadow: 
            0 8px 25px rgba(0, 0, 0, 0.6),
            inset 0 0 0 2px rgba(255, 255, 255, 0.3);
    }
}

/* Logo con animación de entrada */
.navbar-brand {
    animation: logoEntrance 0.8s ease-out;
}

@keyframes logoEntrance {
    0% {
        opacity: 0;
        transform: translateY(-20px) scale(0.8);
    }
    50% {
        opacity: 0.7;
        transform: translateY(-5px) scale(0.9);
    }
    100% {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

/* Logo con efecto de brillo */
.navbar-brand::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        90deg,
        transparent,
        rgba(255, 255, 255, 0.2),
        transparent
    );
    transition: left 0.5s ease;
}

.navbar-brand:hover::before {
    left: 100%;
}

/* Logo con borde animado */
.navbar-brand img,
.navbar-brand .logo-image,
.navbar-brand .logo-icon {
    position: relative;
}

.navbar-brand img::after,
.navbar-brand .logo-image::after,
.navbar-brand .logo-icon::after {
    content: '';
    position: absolute;
    top: -3px;
    left: -3px;
    right: -3px;
    bottom: -3px;
    border-radius: 50%;
    background: linear-gradient(45deg, #fbbf24, #f59e0b, #d97706, #fbbf24);
    background-size: 400% 400%;
    animation: borderRotate 3s ease infinite;
    z-index: -1;
}

@keyframes borderRotate {
    0% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0% 50%;
    }
}

/* Logo con sombra de texto mejorada */
.navbar-brand .logo-text {
    position: relative;
    z-index: 2;
}

/* Logo con efecto de profundidad */
.navbar-brand {
    position: relative;
    z-index: 10;
}

/* Logo con estado activo */
.navbar-brand.active {
    background: rgba(255, 255, 255, 0.25);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

/* Logo con estado de carga */
.navbar-brand.loading {
    animation: logoPulse 1.5s ease-in-out infinite;
}

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