/* ============================================================================
   ORBITAL CHILD THEME - CORRECCIONES DE UX v23.0.2
   ============================================================================
   
   Archivo: fix-comments-avatar.css
   Versión: 23.0.2 (MEJORADA - Avatares profesionales)
   Fecha: 4 de Diciembre de 2025
   
   Correcciones incluidas:
   1. Mensaje elegante para comentarios vacíos
   2. Avatares perfectamente circulares y profesionales (36px)
   3. Badge "NUEVA" discreto pero visible (10px)
   
   ========================================================================== */


/* ============================================================================
   SECCIÓN 1: CORRECCIÓN DE COMENTARIOS VACÍOS
   ============================================================================
   
   Problema: La pestaña "Comentarios (0)" mostraba pantalla en blanco
   Solución: Mensaje elegante con emoji cuando no hay comentarios
   
   Mejora: Usuario sabe claramente que no tiene comentarios todavía
   ========================================================================== */

/* Forzar visibilidad de contenedores de comentarios vacíos */
#bbpress-forums .bbp-replies,
#bbpress-forums .bbp-body,
.comment-list,
.bbp-reply-content,
#bbpress-forums .bbp-topic-content,
#bbpress-forums div.bbp-the-content-wrapper {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    min-height: 50px !important;
}

/* Mensaje para cuando no hay comentarios - Solo con pseudo-elemento */
.bbp-replies:empty::after,
.comment-list:empty::after,
#bbpress-forums .bbp-body:empty::after,
.no-comments::before {
    content: '💬' !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 60px 20px !important;
    background: #f8f9fa !important;
    border-radius: 8px !important;
    text-align: center !important;
    font-size: 64px !important;
    opacity: 0.2 !important;
    min-height: 200px !important;
}

/* Texto del mensaje de comentarios vacíos */
.no-comments::after {
    content: 'No has hecho comentarios todavía.' !important;
    display: block !important;
    margin-top: 20px !important;
    font-size: 16px !important;
    color: #a0a0a0 !important;
    font-family: Georgia, serif !important;
    font-style: italic !important;
    opacity: 1 !important;
}

/* Contenedor de mensaje vacío - estilo profesional */
.empty-comments-message {
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 80px 20px !important;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%) !important;
    border-radius: 12px !important;
    text-align: center !important;
    min-height: 250px !important;
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.06) !important;
}

/* Emoji en mensaje vacío - más grande y elegante */
.empty-comments-message .emoji {
    font-size: 72px !important;
    opacity: 0.25 !important;
    margin-bottom: 20px !important;
    filter: grayscale(20%) !important;
}

/* Texto en mensaje vacío - tipografía elegante */
.empty-comments-message p {
    font-size: 17px !important;
    color: #6c757d !important;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Arial, sans-serif !important;
    font-weight: 400 !important;
    line-height: 1.6 !important;
    max-width: 400px !important;
    margin: 0 !important;
}


/* ============================================================================
   SECCIÓN 2: AVATARES PROFESIONALES Y PERFECTAMENTE CIRCULARES
   ============================================================================
   
   Problema: Avatares demasiado grandes (80px) y deformados (cuadrados)
   Solución: 36px perfectamente circulares con diseño profesional
   
   Mejora: Aspecto moderno, compacto y visualmente atractivo
   ========================================================================== */

/* Avatares en comentarios y respuestas - Diseño profesional definitivo */
.comment-author .avatar,
#bbpress-forums .bbp-reply-author .avatar,
#bbpress-forums .bbp-topic-author .avatar,
.bbp-reply-author img.avatar,
.bbp-topic-author img.avatar,
.bbp-author-avatar img.avatar,
img.avatar,
.avatar {
    /* Tamaño optimizado y compacto */
    width: 36px !important;
    height: 36px !important;
    max-width: 36px !important;
    max-height: 36px !important;
    min-width: 36px !important;
    min-height: 36px !important;
    
    /* Forma circular PERFECTA - Sin deformación */
    border-radius: 50% !important;
    
    /* Evitar cualquier deformación de imagen */
    object-fit: cover !important;
    object-position: center !important;
    aspect-ratio: 1/1 !important;
    
    /* Diseño profesional con borde y sombra sutil */
    border: 2px solid rgba(255, 255, 255, 0.95) !important;
    box-shadow: 
        0 2px 4px rgba(0, 0, 0, 0.08),
        0 1px 2px rgba(0, 0, 0, 0.06) !important;
    
    /* Espaciado y alineación */
    margin-right: 10px !important;
    margin-bottom: 0 !important;
    flex-shrink: 0 !important;
    vertical-align: middle !important;
    display: inline-block !important;
    
    /* Transición suave para hover */
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1) !important;
    
    /* Mejorar calidad de renderizado */
    image-rendering: -webkit-optimize-contrast !important;
    image-rendering: crisp-edges !important;
}

/* Efecto hover profesional en avatares */
.comment-author .avatar:hover,
#bbpress-forums .bbp-reply-author .avatar:hover,
#bbpress-forums .bbp-topic-author .avatar:hover,
.bbp-reply-author img.avatar:hover,
.bbp-topic-author img.avatar:hover,
.bbp-author-avatar img.avatar:hover,
img.avatar:hover,
.avatar:hover {
    transform: scale(1.08) translateY(-1px) !important;
    box-shadow: 
        0 4px 12px rgba(0, 0, 0, 0.12),
        0 2px 4px rgba(0, 0, 0, 0.08) !important;
    border-color: rgba(255, 255, 255, 1) !important;
    z-index: 10 !important;
}

/* Contenedor de autor - Flexbox para alineación perfecta */
.comment-author,
.bbp-reply-author,
.bbp-topic-author,
.bbp-author-avatar,
.comment-meta {
    display: flex !important;
    align-items: center !important;
    gap: 10px !important;
    flex-wrap: nowrap !important;
}

/* Avatares en listados de foros - Compactos pero profesionales */
#bbpress-forums li.bbp-header .bbp-author-avatar img.avatar,
#bbpress-forums .bbp-forum-info .bbp-author-avatar img.avatar,
#bbpress-forums .bbp-topic-info .bbp-author-avatar img.avatar,
.forum-list .avatar {
    width: 30px !important;
    height: 30px !important;
    max-width: 30px !important;
    max-height: 30px !important;
    min-width: 30px !important;
    min-height: 30px !important;
    border-radius: 50% !important;
    object-fit: cover !important;
    object-position: center !important;
    aspect-ratio: 1/1 !important;
    border: 1.5px solid rgba(255, 255, 255, 0.9) !important;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08) !important;
    margin-right: 8px !important;
}

/* Avatares en widgets y sidebar - Pequeños y elegantes */
.widget_recent_comments .avatar,
.widget_recent_entries .avatar,
.widget .avatar,
.sidebar .avatar {
    width: 28px !important;
    height: 28px !important;
    max-width: 28px !important;
    max-height: 28px !important;
    min-width: 28px !important;
    min-height: 28px !important;
    border-radius: 50% !important;
    object-fit: cover !important;
    object-position: center !important;
    aspect-ratio: 1/1 !important;
    border: 1.5px solid rgba(255, 255, 255, 0.85) !important;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.06) !important;
    margin-right: 8px !important;
}

/* Avatares en perfil de usuario - Grande pero profesional */
.user-profile .avatar,
.author-avatar .avatar,
#bbpress-forums .bbp-user-section .avatar,
.bbp-user-avatar .avatar,
.profile-avatar .avatar {
    width: 80px !important;
    height: 80px !important;
    max-width: 80px !important;
    max-height: 80px !important;
    min-width: 80px !important;
    min-height: 80px !important;
    border-radius: 50% !important;
    object-fit: cover !important;
    object-position: center !important;
    aspect-ratio: 1/1 !important;
    border: 3px solid rgba(255, 255, 255, 0.98) !important;
    box-shadow: 
        0 6px 16px rgba(0, 0, 0, 0.12),
        0 2px 6px rgba(0, 0, 0, 0.08) !important;
}

/* Responsive: Móvil - Avatares optimizados para espacio reducido */
@media screen and (max-width: 768px) {
    .comment-author .avatar,
    #bbpress-forums .bbp-reply-author .avatar,
    #bbpress-forums .bbp-topic-author .avatar,
    .bbp-reply-author img.avatar,
    .bbp-topic-author img.avatar,
    .bbp-author-avatar img.avatar,
    img.avatar,
    .avatar {
        width: 32px !important;
        height: 32px !important;
        max-width: 32px !important;
        max-height: 32px !important;
        min-width: 32px !important;
        min-height: 32px !important;
        margin-right: 8px !important;
        border-width: 1.5px !important;
    }
    
    /* Listados en móvil - Aún más compactos */
    #bbpress-forums li.bbp-header .bbp-author-avatar img.avatar,
    #bbpress-forums .bbp-forum-info .bbp-author-avatar img.avatar,
    #bbpress-forums .bbp-topic-info .bbp-author-avatar img.avatar,
    .forum-list .avatar {
        width: 26px !important;
        height: 26px !important;
        max-width: 26px !important;
        max-height: 26px !important;
        min-width: 26px !important;
        min-height: 26px !important;
        margin-right: 6px !important;
    }
    
    /* Widgets en móvil */
    .widget_recent_comments .avatar,
    .widget_recent_entries .avatar,
    .widget .avatar,
    .sidebar .avatar {
        width: 24px !important;
        height: 24px !important;
        max-width: 24px !important;
        max-height: 24px !important;
        min-width: 24px !important;
        min-height: 24px !important;
    }
}

/* Responsive: Tablets - Tamaño intermedio */
@media screen and (min-width: 769px) and (max-width: 1024px) {
    .comment-author .avatar,
    #bbpress-forums .bbp-reply-author .avatar,
    #bbpress-forums .bbp-topic-author .avatar,
    .bbp-reply-author img.avatar,
    .bbp-topic-author img.avatar,
    .bbp-author-avatar img.avatar,
    img.avatar,
    .avatar {
        width: 34px !important;
        height: 34px !important;
        max-width: 34px !important;
        max-height: 34px !important;
        min-width: 34px !important;
        min-height: 34px !important;
    }
}


/* ============================================================================
   SECCIÓN 3: BADGES "NUEVA" DISCRETOS PERO VISIBLES
   ============================================================================
   
   Problema: Badge "NUEVA" muy grande y llamativo (14-16px)
   Solución: Reducir a 10px manteniendo legibilidad
   
   Mejora: Mejor jerarquía visual, menos distracción
   ========================================================================== */

/* Badge "NUEVA" - Diseño discreto y profesional */
.badge,
.nueva-badge,
span[class*="nueva"],
span[class*="NUEVA"],
span[class*="new"],
span[class*="NEW"] {
    /* Tamaño reducido pero legible */
    font-size: 10px !important;
    padding: 2px 8px !important;
    line-height: 1.4 !important;
    
    /* Colores llamativos pero no excesivos */
    background: #e74c3c !important;
    color: #ffffff !important;
    
    /* Forma y bordes */
    border-radius: 3px !important;
    border: none !important;
    
    /* Tipografía */
    font-weight: 600 !important;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Arial, sans-serif !important;
    text-transform: uppercase !important;
    letter-spacing: 0.3px !important;
    
    /* Espaciado y posición */
    display: inline-block !important;
    margin-left: 6px !important;
    vertical-align: middle !important;
    
    /* Sombra sutil */
    box-shadow: 0 1px 2px rgba(231, 76, 60, 0.25) !important;
    
    /* Transición */
    transition: all 0.2s ease !important;
}

/* Hover en badges */
.badge:hover,
.nueva-badge:hover,
span[class*="nueva"]:hover,
span[class*="NUEVA"]:hover {
    background: #c0392b !important;
    box-shadow: 0 2px 4px rgba(231, 76, 60, 0.35) !important;
    transform: translateY(-1px) !important;
}

/* Responsive: Badge en móvil - Aún más pequeño */
@media screen and (max-width: 768px) {
    .badge,
    .nueva-badge,
    span[class*="nueva"],
    span[class*="NUEVA"],
    span[class*="new"],
    span[class*="NEW"] {
        font-size: 9px !important;
        padding: 2px 6px !important;
        margin-left: 4px !important;
    }
}


/* ============================================================================
   FIN DE CORRECCIONES
   ============================================================================
   
   Versión: 23.0.2
   Última actualización: 4 de Diciembre de 2025
   Compatibilidad: Todos los navegadores modernos
   
   ========================================================================== */
