/**
 * AleluyApp - Bottom Navigation Bar (Tipo TikTok)
 * Barra de navegación inferior para móvil
 */

/* ============================================
   BOTTOM NAVIGATION BAR
   ============================================ */
.bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background-color: var(--bg-secondary);
    border-top: 1px solid var(--border-color);
    padding: var(--spacing-xs) 0;
    z-index: 999;
    display: none; /* Oculto por defecto, solo visible en móvil */
    box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.3);
}

.bottom-nav-container {
    display: flex;
    justify-content: space-around;
    align-items: center;
    max-width: 100%;
    margin: 0 auto;
    padding: 0 var(--spacing-sm);
}

.bottom-nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: var(--spacing-xs);
    padding: var(--spacing-xs);
    min-width: 60px;
    text-decoration: none;
    color: var(--text-muted);
    transition: all 0.2s ease;
    flex: 1;
    position: relative;
}

.bottom-nav-item:hover,
.bottom-nav-item:active {
    color: var(--text-primary);
}

.bottom-nav-item.active {
    color: var(--like-color);
}

.bottom-nav-icon {
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: var(--font-size-xl);
}

.bottom-nav-icon img {
    width: 24px;
    height: 24px;
    object-fit: contain;
    transition: opacity 0.2s ease;
}

/* Iconos que deben mantener su color original (sin filtros oscuros) */
.bottom-nav-icon img[src*="Reels_icon"],
.bottom-nav-icon img[src*="Messages_icon"],
.bottom-nav-icon img[src*="Home_icon"] {
    filter: none !important;
    opacity: 0.7;
}

.bottom-nav-item.active .bottom-nav-icon img[src*="Reels_icon"],
.bottom-nav-item.active .bottom-nav-icon img[src*="Messages_icon"],
.bottom-nav-item.active .bottom-nav-icon img[src*="Home_icon"] {
    opacity: 1;
}

/* Avatar del perfil - sin filtros */
.bottom-nav-profile-img {
    width: 28px !important;
    height: 28px !important;
    border-radius: 50% !important;
    object-fit: cover !important;
    filter: none !important;
    border: 2px solid var(--border-color);
}

.bottom-nav-profile-placeholder {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background-color: var(--bg-tertiary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: var(--font-size-lg);
    border: 2px solid var(--border-color);
}

/* Solo aplicar filtro rojo al logo (Feed) cuando está activo */
.bottom-nav-item.active .bottom-nav-icon img[src*="logo.png"] {
    filter: brightness(0) saturate(100%) invert(18%) sepia(92%) saturate(4748%) hue-rotate(332deg) brightness(94%) contrast(89%);
}

.bottom-nav-label {
    font-size: var(--font-size-xs);
    font-weight: 500;
    text-align: center;
    line-height: 1;
}

.bottom-nav-item.active .bottom-nav-label {
    font-weight: 600;
}

/* Indicador activo (punto) */
.bottom-nav-item.active::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 4px;
    height: 4px;
    background-color: var(--like-color);
    border-radius: 50%;
}

/* ============================================
   RESPONSIVE - Solo mostrar en móvil
   ============================================ */
@media (max-width: 767px) {
    .bottom-nav {
        display: block;
    }
    
    /* Agregar padding bottom al main-container para evitar que el contenido quede detrás del bottom nav */
    .main-container {
        padding-bottom: calc(70px + var(--spacing-md)); /* Altura del bottom nav + spacing */
    }
    
    body {
        padding-bottom: 70px; /* Espacio para el bottom nav */
    }
}

/* ============================================
   TABLET - Ocultar bottom nav
   ============================================ */
@media (min-width: 768px) and (max-width: 1023px) {
    .bottom-nav {
        display: none;
    }
    
    .main-container {
        padding-bottom: var(--spacing-md);
    }
    
    body {
        padding-bottom: 0;
    }
}

/* ============================================
   DESKTOP - Ocultar bottom nav
   ============================================ */
@media (min-width: 1024px) {
    .bottom-nav {
        display: none;
    }
    
    .main-container {
        padding-bottom: var(--spacing-md);
    }
    
    body {
        padding-bottom: 0;
    }
}
