/* 
 * CSS específico para as Sidebars (Left e Right)
 * VS2 Theme - Sidebars Styles
 */

/* Layout das Sidebars */
.sidebar-left {
    flex: 0 0 250px;
    border-radius: 8px;
    overflow: hidden;
}

.sidebar-right {
    flex: 0 0 250px;
    border-radius: 8px;
    overflow: hidden;
}

.sidebar-section {
    border-bottom: 1px solid #e1e1e1;
}

.sidebar-section:last-child {
    border-bottom: none;
}

/* ==========================================
   SIDEBAR LEFT - MENU PRINCIPAL
   ========================================== */

/* Menu Sidebar */
.sidebar-nav {
    background: #fff;
}

.sidebar-menu {
    list-style: none;
    margin: 0;
    padding: 0;
}

.sidebar-menu li {
    border-bottom: 1px solid #e1e1e1;
}

.sidebar-menu li:last-child {
    border-bottom: none;
}

.sidebar-menu a {
    display: block;
    padding: 12px 20px;
    color: #333;
    text-decoration: none;
    transition: background-color 0.3s ease;
    position: relative;
}

.sidebar-menu a:before {
    content: "»";
    color: #999;
    margin-right: 8px;
}

.sidebar-menu a:hover,
.sidebar-menu .current-menu-item a {
    background-color: #f4f4f4;
    color: #0073aa;
}

.sidebar-menu .current-menu-item a:before {
    color: #0073aa;
}

/* Submenu */
.sidebar-menu .sub-menu {
    background: #f9f9f9;
}

.sidebar-menu .sub-menu a {
    padding-left: 40px;
    font-size: 0.9em;
}

/* ==========================================
   SIDEBAR RIGHT - CONTEÚDO DINÂMICO
   ========================================== */

/* Títulos das seções */
.sidebar-title {
    background: #333;
    color: white;
    margin: 0;
    padding: 15px 20px;
    font-size: 14px;
    font-weight: bold;
    letter-spacing: 1px;
}

/* ==========================================
   NEWSLETTER SECTION
   ========================================== */

.newsletter-item {
    padding: 15px 20px;
    border-bottom: 1px solid #e1e1e1;
    background: white;
}

.newsletter-item:last-child {
    border-bottom: none;
}

.newsletter-date {
    display: block;
    font-size: 12px;
    color: #666;
    font-weight: bold;
    margin-bottom: 5px;
}

.newsletter-title {
    margin: 0 0 8px 0;
    font-size: 13px;
    line-height: 1.4;
}

.newsletter-title a {
    color: #333;
    text-decoration: none;
}

.newsletter-title a:hover {
    color: #0073aa;
}

.newsletter-link {
    color: #ff6600;
    text-decoration: none;
    font-size: 12px;
    font-weight: bold;
}

.newsletter-link:hover {
    color: #e55a00;
}

.no-newsletter {
    padding: 20px;
    color: #666;
    font-size: 13px;
    text-align: center;
    background: white;
}

/* ==========================================
   AGENDA SECTION
   ========================================== */

.agenda-item {
    padding: 15px 20px;
    border-bottom: 1px solid #e1e1e1;
    background: white;
}

.agenda-item:last-child {
    border-bottom: none;
}

.agenda-date {
    display: block;
    font-size: 12px;
    color: #666;
    font-weight: bold;
    margin-bottom: 5px;
}

.agenda-title {
    margin: 0 0 8px 0;
    font-size: 13px;
    line-height: 1.4;
}

.agenda-title a {
    color: #333;
    text-decoration: none;
}

.agenda-title a:hover {
    color: #0073aa;
}

.agenda-link {
    color: #ff6600;
    text-decoration: none;
    font-size: 12px;
    font-weight: bold;
}

.agenda-link:hover {
    color: #e55a00;
}

.no-agenda {
    padding: 20px;
    color: #666;
    font-size: 13px;
    text-align: center;
    background: white;
}

/* ==========================================
   STATS BOX (Estatísticas)
   ========================================== */

.stats-box {
    padding: 20px;
    text-align: center;
}

.stats-text {
    color: #AE3800;
    margin: 0;
    font-size: 13px;
    font-weight: bold;
    line-height: 1.5;
    letter-spacing: 0.5px;
}

/* ==========================================
   BANNER INDIQUE
   ========================================== */

.banner-indique {
    background: white;
    padding: 15px;
    text-align: center;
}

.banner-indique a {
    display: block;
    transition: opacity 0.3s ease;
}

.banner-indique a:hover {
    opacity: 0.8;
}

.banner-indique img {
    width: 100%;
    height: auto;
    max-width: 220px;
    border-radius: 4px;
}

/* ==========================================
   RESPONSIVIDADE DAS SIDEBARS
   ========================================== */

/* Tablets e dispositivos médios */
@media (max-width: 1200px) {
    .sidebar-left,
    .sidebar-right {
        flex: none;
        order: 2;
        margin-bottom: 20px;
    }
    
    .sidebar-right {
        order: 3;
    }
}

/* Sidebars lado a lado em tablets */
@media (min-width: 600px) and (max-width: 1200px) {
    .sidebars-wrapper {
        display: flex;
        gap: 20px;
    }
    
    .sidebar-left,
    .sidebar-right {
        flex: 1;
        margin-bottom: 0;
    }
}

/* Mobile */
@media (max-width: 768px) {
    .sidebar-left,
    .sidebar-right {
        flex: none;
    }
    
    .sidebar-menu a {
        padding: 10px 15px;
        font-size: 0.9em;
    }
    
    .sidebar-menu .sub-menu a {
        padding-left: 30px;
        font-size: 0.85em;
    }
    
    .newsletter-item,
    .agenda-item {
        padding: 12px 15px;
    }
    
    .newsletter-title,
    .agenda-title {
        font-size: 12px;
    }
    
    .newsletter-date,
    .agenda-date {
        font-size: 11px;
    }
    
    .newsletter-link,
    .agenda-link {
        font-size: 11px;
    }
    
    .stats-box {
        padding: 15px;
    }
    
    .stats-text {
        font-size: 12px;
    }
    
    .banner-indique {
        padding: 12px;
    }
    
    .sidebar-title {
        padding: 12px 15px;
        font-size: 13px;
    }
    
    .no-newsletter,
    .no-agenda {
        padding: 15px;
        font-size: 12px;
    }
}

/* Mobile muito pequeno */
@media (max-width: 480px) {
    .sidebar-menu a {
        padding: 8px 12px;
        font-size: 0.85em;
    }
    
    .sidebar-menu .sub-menu a {
        padding-left: 25px;
        font-size: 0.8em;
    }
    
    .newsletter-item,
    .agenda-item {
        padding: 10px 12px;
    }
    
    .stats-box {
        padding: 12px;
    }
    
    .banner-indique {
        padding: 10px;
    }
    
    .sidebar-title {
        padding: 10px 12px;
        font-size: 12px;
    }
}

/* ==========================================
   MELHORIAS DE ACESSIBILIDADE E UX
   ========================================== */

/* Foco para navegação por teclado */
.sidebar-menu a:focus {
    outline: 2px solid #ff6600;
    outline-offset: -2px;
    background-color: #f4f4f4;
}

.newsletter-title a:focus,
.agenda-title a:focus,
.newsletter-link:focus,
.agenda-link:focus {
    outline: 2px solid #ff6600;
    outline-offset: 1px;
}

.banner-indique a:focus {
    outline: 2px solid #ff6600;
    outline-offset: 2px;
}

/* Animações suaves */
.sidebar-section {
    transition: all 0.3s ease;
}

.newsletter-item,
.agenda-item {
    transition: background-color 0.3s ease;
}

.newsletter-item:hover,
.agenda-item:hover {
    background: #f9f9f9;
}

/* Estados de loading */
.sidebar-loading {
    padding: 20px;
    text-align: center;
    color: #999;
    background: white;
}

.sidebar-loading::after {
    content: "Carregando...";
    animation: loading 1.5s infinite;
}

@keyframes loading {
    0%, 100% { opacity: 0.5; }
    50% { opacity: 1; }
}

/* Print styles para sidebars */
@media print {
    .sidebar-left,
    .sidebar-right {
        display: none;
    }
}