/**
 * @file
 * Estilos para a página de Notícias por Tribunal
 */

:root {
    --primary-green: #2d5f2e;
    --secondary-green: #4a8f4d;
    --light-green: #e8f5e9;
    --accent-green: #66bb6a;
    --dark-gray: #333;
    --medium-gray: #666;
    --light-gray: #f8f9fa;
    --white: #ffffff;
    --shadow: 0 2px 12px rgba(0,0,0,0.08);
    --shadow-hover: 0 8px 24px rgba(0,0,0,0.12);
    /* Consistência de marca - mesmo verde em todas as páginas */
    --tribunal-color: #2d5f2e;
    --tribunal-light: #e8f5e9;
}

/* ============================================
   BARRA DE COMPARTILHAMENTO FLUTUANTE
   ============================================ */
.share-floating {
    position: fixed;
    left: 20px;
    top: 50%;
    transform: translateY(-50%);
    z-index: 90;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.share-floating-btn {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--white);
    font-size: 1.25rem;
    text-decoration: none;
    transition: all 0.3s;
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
    border: none;
    cursor: pointer;
}

.share-floating-btn:hover {
    transform: scale(1.15);
    box-shadow: 0 6px 20px rgba(0,0,0,0.3);
}

.share-floating-btn.whatsapp { background: #25D366; animation: pulse-share 2s ease-in-out infinite; }
.share-floating-btn.telegram { background: #0088cc; }
.share-floating-btn.linkedin { background: #0077B5; }
.share-floating-btn.twitter { background: #1DA1F2; }
.share-floating-btn.facebook { background: #1877F2; }
.share-floating-btn.instagram { background: linear-gradient(45deg, #f09433 0%, #e6683c 25%, #dc2743 50%, #cc2366 75%, #bc1888 100%); }
.share-floating-btn.email { background: var(--secondary-green); }
.share-floating-btn.copy { background: var(--primary-green); }

.share-floating-label {
    background: var(--primary-green);
    color: var(--white);
    padding: 8px 12px;
    border-radius: 8px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    writing-mode: vertical-rl;
    transform: rotate(180deg);
    margin-bottom: 5px;
}

@keyframes pulse-share {
    0%, 100% { box-shadow: 0 4px 15px rgba(37, 211, 102, 0.4); }
    50% { box-shadow: 0 4px 25px rgba(37, 211, 102, 0.7); }
}

/* ============================================
   HERO DO TRIBUNAL
   ============================================ */
.tribunal-hero {
    background: linear-gradient(135deg, var(--primary-green) 0%, #1e4620 100%);
    color: var(--white);
    padding: 50px 20px;
}

.tribunal-hero-container {
    max-width: 1400px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 40px;
    align-items: center;
}

.tribunal-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(255,255,255,0.15);
    padding: 8px 16px;
    border-radius: 8px;
    font-size: 0.875rem;
    font-weight: 600;
    margin-bottom: 20px;
}

.tribunal-title {
    font-size: 2.5rem;
    font-weight: 800;
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 15px;
}

.tribunal-title i {
    font-size: 2.25rem;
    opacity: 0.9;
}

.tribunal-full-name {
    font-size: 1.25rem;
    opacity: 0.9;
    margin-bottom: 15px;
}

.tribunal-description {
    font-size: 1.0625rem;
    opacity: 0.9;
    line-height: 1.7;
    max-width: 700px;
    margin-bottom: 25px;
}

.tribunal-stats {
    display: flex;
    gap: 30px;
    flex-wrap: wrap;
}

.tribunal-stat {
    text-align: center;
    background: rgba(255,255,255,0.1);
    padding: 15px 25px;
    border-radius: 10px;
}

.tribunal-stat-number {
    font-size: 1.75rem;
    font-weight: 800;
    display: block;
}

.tribunal-stat-label {
    font-size: 0.8125rem;
    opacity: 0.85;
}

.tribunal-actions {
    display: flex;
    flex-direction: column;
    gap: 15px;
    align-items: flex-end;
}

.btn-all-news {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(255,255,255,0.15);
    border: 2px solid rgba(255,255,255,0.4);
    color: var(--white);
    padding: 12px 24px;
    border-radius: 10px;
    font-weight: 700;
    text-decoration: none;
    transition: all 0.3s;
}

.btn-all-news:hover {
    background: rgba(255,255,255,0.25);
    border-color: var(--white);
    transform: translateX(-5px);
}

.tribunal-share {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 8px;
}

.tribunal-share-label {
    font-size: 0.8125rem;
    opacity: 0.8;
}

.tribunal-share-buttons {
    display: flex;
    gap: 8px;
}

.tribunal-share-btn {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--white);
    text-decoration: none;
    transition: all 0.3s;
    border: 2px solid rgba(255,255,255,0.3);
    background: rgba(255,255,255,0.1);
}

.tribunal-share-btn:hover {
    transform: scale(1.1);
    border-color: var(--white);
    background: rgba(255,255,255,0.2);
}

/* ============================================
   NAVEGAÇÃO ENTRE TRIBUNAIS
   ============================================ */
.tribunals-nav {
    background: var(--white);
    padding: 20px 0;
    border-bottom: 2px solid #e0e0e0;
    overflow-x: auto;
}

.tribunals-nav-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
}

.tribunals-nav-list {
    display: flex;
    gap: 10px;
    list-style: none;
}

.tribunals-nav-item a {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 10px 18px;
    border-radius: 8px;
    font-size: 0.875rem;
    font-weight: 600;
    text-decoration: none;
    color: var(--medium-gray);
    background: var(--light-gray);
    transition: all 0.3s;
    white-space: nowrap;
}

.tribunals-nav-item a:hover {
    background: var(--light-green);
    color: var(--primary-green);
}

.tribunals-nav-item.active a {
    background: var(--secondary-green);
    color: var(--white);
}

.tribunals-nav-item .count {
    background: rgba(255,255,255,0.2);
    padding: 2px 8px;
    border-radius: 10px;
    font-size: 0.75rem;
}

.tribunals-nav-item:not(.active) .count {
    background: var(--white);
    color: var(--medium-gray);
}

/* ============================================
   BUSCA CONTEXTUAL
   ============================================ */
.contextual-search {
    background: linear-gradient(135deg, var(--light-green) 0%, #c8e6c9 100%);
    padding: 30px 20px;
    border-bottom: 2px solid var(--secondary-green);
}

.contextual-search-container {
    max-width: 700px;
    margin: 0 auto;
    text-align: center;
}

.contextual-search h3 {
    font-size: 1.125rem;
    color: var(--primary-green);
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.contextual-search-form {
    position: relative;
}

.contextual-search-form input {
    width: 100%;
    padding: 16px 60px 16px 20px;
    border: 3px solid var(--secondary-green);
    border-radius: 12px;
    font-size: 1rem;
    transition: all 0.3s;
}

.contextual-search-form input:focus {
    outline: none;
    box-shadow: 0 0 0 4px rgba(74, 143, 77, 0.15);
}

.contextual-search-form button {
    position: absolute;
    right: 6px;
    top: 50%;
    transform: translateY(-50%);
    background: var(--secondary-green);
    color: var(--white);
    border: none;
    width: 44px;
    height: 44px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 1.25rem;
    transition: all 0.3s;
}

.contextual-search-form button:hover {
    background: var(--primary-green);
}

.contextual-search-hint {
    font-size: 0.8125rem;
    color: var(--medium-gray);
    margin-top: 10px;
}

/* ============================================
   MAIN CONTAINER
   ============================================ */
.main-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 40px 20px;
}

/* ============================================
   FILTROS
   ============================================ */
.filters-section {
    background: var(--white);
    border-radius: 16px;
    padding: 25px 30px;
    margin-bottom: 40px;
    box-shadow: var(--shadow);
}

.filters-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 20px;
}

.filters-header-left {
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--primary-green);
}

.filters-header-left i {
    font-size: 1.25rem;
}

.filters-title {
    font-size: 1.125rem;
    font-weight: 700;
    color: var(--primary-green);
    margin: 0;
}

.view-toggle {
    display: flex;
    gap: 6px;
    background: var(--light-gray);
    padding: 4px;
    border-radius: 8px;
}

.view-btn {
    background: transparent;
    border: none;
    padding: 8px 14px;
    border-radius: 6px;
    cursor: pointer;
    color: var(--medium-gray);
    font-weight: 600;
    font-size: 0.875rem;
    display: flex;
    align-items: center;
    gap: 6px;
    transition: all 0.3s;
}

.view-btn.active {
    background: var(--secondary-green);
    color: var(--white);
}

.filters-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin-bottom: 15px;
}

.filter-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.filter-label {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--dark-gray);
    display: flex;
    align-items: center;
    gap: 6px;
}

.filter-label i {
    color: var(--secondary-green);
    font-size: 1rem;
}

.select-wrapper {
    position: relative;
}

.select-wrapper i {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    pointer-events: none;
    color: var(--medium-gray);
    font-size: 0.875rem;
}

.filter-select {
    width: 100%;
    padding: 12px 16px;
    padding-right: 40px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 0.9375rem;
    color: var(--dark-gray);
    cursor: pointer;
    background: white;
    appearance: none;
    transition: all 0.3s ease;
}

.filter-select:hover {
    border-color: var(--secondary-green);
}

.filter-select:focus {
    outline: none;
    border-color: var(--secondary-green);
    box-shadow: 0 0 0 3px rgba(74, 143, 77, 0.1);
}

.filter-actions {
    display: flex;
    gap: 15px;
    align-items: flex-end;
    padding-top: 10px;
}

.filter-actions .search-group {
    flex: 1;
    min-width: 300px;
}

.filter-input {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 0.9375rem;
    color: var(--dark-gray);
    transition: all 0.3s ease;
}

.filter-input:hover {
    border-color: var(--secondary-green);
}

.filter-input:focus {
    outline: none;
    border-color: var(--secondary-green);
    box-shadow: 0 0 0 3px rgba(74, 143, 77, 0.1);
}

.filter-input::placeholder {
    color: var(--medium-gray);
}

.btn-search,
.btn-clear {
    padding: 12px 24px;
    border-radius: 8px;
    font-size: 0.9375rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: all 0.3s ease;
    border: none;
    white-space: nowrap;
}

.btn-search {
    background: var(--secondary-green);
    color: var(--white);
}

.btn-search:hover {
    background: var(--primary-green);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(74, 143, 77, 0.3);
}

.btn-clear {
    background: #f5f5f5;
    color: var(--medium-gray);
    border: 2px solid #e0e0e0;
}

.btn-clear:hover {
    background: #e8e8e8;
    border-color: #ccc;
}

/* ============================================
   CONTEÚDO COM SIDEBAR
   ============================================ */
.content-with-sidebar {
    display: grid;
    grid-template-columns: 1fr 350px;
    gap: 40px;
}

/* ============================================
   GRID DE NOTÍCIAS
   ============================================ */
.news-section { margin-bottom: 40px; }

.results-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
    padding-bottom: 20px;
    border-bottom: 2px solid #e0e0e0;
}

.results-count { color: var(--medium-gray); }
.results-count strong { color: var(--secondary-green); }

.news-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 25px;
    margin-bottom: 40px;
}

.news-card {
    background: var(--white);
    border-radius: 12px;
    overflow: visible;
    box-shadow: var(--shadow);
    transition: all 0.3s;
    text-decoration: none;
    color: inherit;
    display: flex;
    flex-direction: column;
    border-top: 4px solid var(--secondary-green);
}

.news-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-hover);
}

.news-card-image {
    width: 100%;
    height: 160px;
    background: linear-gradient(135deg, var(--light-green) 0%, #c8e6c9 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: visible;
    border-radius: 12px 12px 0 0;
}

.news-card-image i {
    font-size: 3.5rem;
    color: var(--secondary-green);
    opacity: 0.25;
}

.card-badge {
    position: absolute;
    top: 12px;
    right: 12px;
    background: var(--secondary-green);
    color: var(--white);
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 700;
    white-space: nowrap;
    max-width: calc(100% - 24px);
    overflow: visible;
    z-index: 10;
}

.news-card-content {
    padding: 20px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.card-meta {
    display: flex;
    gap: 15px;
    margin-bottom: 12px;
    font-size: 0.8125rem;
    color: var(--medium-gray);
}

.card-meta-item {
    display: flex;
    align-items: center;
    gap: 4px;
}

.card-meta-item i { color: var(--secondary-green); }

.card-title {
    font-size: 1.0625rem;
    font-weight: 700;
    line-height: 1.4;
    color: var(--dark-gray);
    margin-bottom: 12px;
}

.card-excerpt {
    color: var(--medium-gray);
    font-size: 0.9375rem;
    line-height: 1.6;
    margin-bottom: 15px;
    flex: 1;
}

.card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 15px;
    border-top: 1px solid #e0e0e0;
}

.card-category {
    display: flex;
    align-items: center;
    gap: 6px;
    color: var(--secondary-green);
    font-size: 0.8125rem;
    font-weight: 600;
}

.card-read-time {
    color: var(--medium-gray);
    font-size: 0.8125rem;
    display: flex;
    align-items: center;
    gap: 4px;
}

/* ============================================
   PAGINAÇÃO
   ============================================ */
.pagination-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
    margin-top: 30px;
    padding: 20px 0;
}

.pagination-info {
    font-size: 0.9375rem;
    color: var(--medium-gray);
}

.pagination {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 6px;
    list-style: none;
    margin: 0;
    padding: 0;
}

.page-item {
    margin: 0;
}

.page-link {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 42px;
    height: 42px;
    padding: 8px 14px;
    background: var(--white);
    border: 1px solid var(--light-border);
    border-radius: 8px;
    color: var(--dark-gray);
    font-size: 0.9375rem;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.2s ease;
    cursor: pointer;
}

.page-link:hover {
    background: var(--light-green);
    border-color: var(--secondary-green);
    color: var(--secondary-green);
    text-decoration: none;
}

.page-item.active .page-link {
    background: var(--secondary-green);
    border-color: var(--secondary-green);
    color: var(--white);
    font-weight: 600;
}

.page-item.disabled .page-link {
    background: var(--light-gray);
    border-color: var(--light-border);
    color: var(--medium-gray);
    cursor: not-allowed;
    opacity: 0.6;
}

.page-item.disabled .page-link:hover {
    background: var(--light-gray);
    border-color: var(--light-border);
    color: var(--medium-gray);
}

.page-link i {
    font-size: 0.875rem;
}

/* Responsivo para paginação */
@media (max-width: 576px) {
    .pagination {
        gap: 4px;
    }

    .page-link {
        min-width: 36px;
        height: 36px;
        padding: 6px 10px;
        font-size: 0.875rem;
    }

    .page-item:first-child .page-link,
    .page-item:last-child .page-link {
        padding: 6px 12px;
    }

    /* Esconder texto em mobile, manter apenas ícones */
    .page-item:first-child .page-link,
    .page-item:last-child .page-link {
        font-size: 0;
    }

    .page-item:first-child .page-link i,
    .page-item:last-child .page-link i {
        font-size: 1rem;
    }
}

/* Animação de loading */
@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* ============================================
   SIDEBAR
   ============================================ */
.sidebar {
    position: sticky;
    top: 100px;
    height: fit-content;
}

.sidebar-widget {
    background: var(--white);
    border-radius: 16px;
    padding: 25px;
    margin-bottom: 25px;
    box-shadow: var(--shadow);
}

.widget-title {
    font-size: 1.125rem;
    font-weight: 700;
    color: var(--primary-green);
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
}

/* NEWSLETTER WIDGET */
.newsletter-widget {
    background: linear-gradient(135deg, var(--light-green) 0%, #c8e6c9 100%);
    border: 2px solid var(--secondary-green);
}

.newsletter-widget .widget-title {
    color: var(--primary-green);
}

.newsletter-widget p {
    font-size: 0.9375rem;
    color: var(--dark-gray);
    margin-bottom: 20px;
}

.newsletter-form {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.newsletter-form input {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid rgba(255,255,255,0.6);
    border-radius: 8px;
    font-size: 0.9375rem;
    background: rgba(255,255,255,0.8);
}

.newsletter-form input:focus {
    outline: none;
    border-color: var(--secondary-green);
    background: var(--white);
}

.newsletter-form button {
    width: 100%;
    padding: 12px;
    background: var(--secondary-green);
    color: var(--white);
    border: none;
    border-radius: 8px;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: all 0.3s;
}

.newsletter-form button:hover {
    background: var(--primary-green);
}

/* POPULARES */
.popular-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.popular-item {
    display: flex;
    gap: 12px;
    text-decoration: none;
    color: inherit;
    padding-bottom: 15px;
    border-bottom: 1px solid #e0e0e0;
    transition: all 0.3s;
}

.popular-item:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.popular-item:hover { padding-left: 8px; }

.popular-number {
    width: 30px;
    height: 30px;
    background: var(--light-green);
    color: var(--secondary-green);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: 0.875rem;
    flex-shrink: 0;
}

.popular-content { flex: 1; }

.popular-title {
    font-size: 0.9375rem;
    font-weight: 600;
    line-height: 1.4;
    color: var(--dark-gray);
    margin-bottom: 6px;
}

.popular-meta {
    font-size: 0.75rem;
    color: var(--medium-gray);
}

/* ============================================
   MODAL NEWSLETTER
   ============================================ */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s;
    padding: 20px;
}

.modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.modal-content {
    background: var(--white);
    border-radius: 20px;
    padding: 40px;
    max-width: 420px;
    width: 100%;
    text-align: center;
    transform: scale(0.8);
    transition: all 0.3s;
    position: relative;
}

.modal-overlay.active .modal-content {
    transform: scale(1);
}

.modal-close {
    position: absolute;
    top: 15px;
    right: 15px;
    background: none;
    border: none;
    font-size: 1.5rem;
    color: #ccc;
    cursor: pointer;
}

.modal-icon {
    width: 80px;
    height: 80px;
    background: var(--light-green);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 25px;
    font-size: 2.5rem;
    color: var(--secondary-green);
}

.modal-title {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--primary-green);
    margin-bottom: 10px;
}

.modal-subtitle { color: var(--medium-gray); margin-bottom: 25px; }

.modal-email {
    background: var(--light-gray);
    padding: 12px 20px;
    border-radius: 8px;
    font-weight: 600;
    margin-bottom: 25px;
    display: inline-block;
}

.modal-email i { color: var(--secondary-green); margin-right: 8px; }

.modal-instructions {
    background: #fff8e1;
    border: 1px solid #ffe082;
    border-radius: 10px;
    padding: 15px 20px;
    margin-bottom: 25px;
    text-align: left;
}

.modal-instructions p {
    font-size: 0.875rem;
    color: #795548;
    display: flex;
    align-items: flex-start;
    gap: 10px;
}

.modal-instructions i { color: #ff9800; font-size: 1.125rem; }

.modal-btn {
    background: var(--secondary-green);
    color: var(--white);
    border: none;
    padding: 14px 40px;
    border-radius: 10px;
    font-weight: 700;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.modal-btn:hover { background: var(--primary-green); }

.modal-footer {
    margin-top: 20px;
    font-size: 0.8125rem;
    color: var(--medium-gray);
}

.modal-footer a {
    color: var(--secondary-green);
    text-decoration: none;
    font-weight: 600;
}

/* ============================================
   WIDGET DE ESTATÍSTICAS DA PÁGINA
   ============================================ */
.page-stats-widget {
    background: var(--white);
    padding: 15px 20px;
}

.page-stats-container {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 30px;
}

.page-stat-item {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--medium-gray);
    font-size: 0.9375rem;
}

.page-stat-item i {
    font-size: 1.1rem;
    color: var(--secondary-green);
}

.page-stat-item .stat-label {
    color: var(--medium-gray);
}

.page-like-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    background: none;
    border: none;
    color: var(--medium-gray);
    font-size: 0.9375rem;
    cursor: pointer;
    padding: 8px 12px;
    border-radius: 8px;
    transition: all 0.2s ease;
}

.page-like-btn:hover {
    background: var(--light-green);
    color: var(--primary-green);
}

.page-like-btn:hover i {
    color: var(--primary-green);
}

.page-like-btn.active {
    color: var(--primary-green);
    background: var(--light-green);
}

.page-like-btn.active i {
    color: var(--primary-green);
}

/* ============================================
   NOTIFICAÇÕES TOAST
   ============================================ */
.post-notification {
    position: fixed;
    top: 80px;
    right: 20px;
    background: white;
    padding: 1rem 1.5rem;
    border-radius: 8px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    font-size: 0.875rem;
    font-weight: 500;
    z-index: 10001;
    opacity: 0;
    transform: translateX(100px);
    transition: all 0.3s ease;
    min-width: 250px;
}

.post-notification.show {
    opacity: 1;
    transform: translateX(0);
}

.post-notification.toast-success {
    border-left: 4px solid var(--primary-green);
    color: var(--primary-dark);
}

.post-notification.toast-warning {
    border-left: 4px solid #f59e0b;
    color: #92400e;
}

.post-notification.toast-error {
    border-left: 4px solid #ef4444;
    color: #991b1b;
}

.post-notification.toast-info {
    border-left: 4px solid #3b82f6;
    color: #1e40af;
}

/* ============================================
   MODAL DE COMPARTILHAMENTO POR E-MAIL
   ============================================ */
.email-share-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 20000;
    display: flex;
    align-items: center;
    justify-content: center;
}

.email-modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
}

.email-modal-content {
    position: relative;
    background: white;
    border-radius: 12px;
    width: 90%;
    max-width: 500px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
    z-index: 20001;
}

.email-modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 25px;
    border-bottom: 1px solid #e9ecef;
    background: linear-gradient(135deg, var(--primary-green) 0%, var(--secondary-green) 100%);
    border-radius: 12px 12px 0 0;
}

.email-modal-header h3 {
    margin: 0;
    font-size: 20px;
    font-weight: 600;
    color: white;
}

.email-modal-close {
    background: transparent;
    border: none;
    color: white;
    font-size: 20px;
    cursor: pointer;
    padding: 5px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.3s;
}

.email-modal-close:hover {
    opacity: 0.7;
}

.email-modal-form {
    padding: 25px;
}

.email-modal-form .form-group {
    margin-bottom: 20px;
}

.email-modal-form label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: #333;
    font-size: 14px;
}

.email-modal-form .form-control {
    width: 100%;
    padding: 10px 15px;
    border: 1px solid #dee2e6;
    border-radius: 6px;
    font-size: 14px;
    transition: border-color 0.3s, box-shadow 0.3s;
}

.email-modal-form .form-control:focus {
    outline: none;
    border-color: var(--primary-green);
    box-shadow: 0 0 0 3px rgba(26, 89, 67, 0.1);
}

.email-modal-form .form-control:read-only {
    background: #f8f9fa;
    cursor: default;
}

.email-modal-form textarea.form-control {
    resize: vertical;
    min-height: 80px;
}

.email-modal-actions {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
    margin-top: 25px;
}

.email-modal-actions button {
    padding: 10px 20px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s;
    border: none;
    display: flex;
    align-items: center;
    gap: 8px;
}

.email-modal-actions .btn-cancel {
    background: #f8f9fa;
    color: #666;
    border: 1px solid #dee2e6;
}

.email-modal-actions .btn-cancel:hover {
    background: #e9ecef;
}

.email-modal-actions .btn-send {
    background: var(--primary-green);
    color: white;
}

.email-modal-actions .btn-send:hover {
    background: var(--secondary-green);
    transform: translateY(-1px);
}

.email-modal-actions .btn-send:disabled {
    background: #ccc;
    cursor: not-allowed;
    transform: none;
}

.email-share-feedback {
    margin-top: 15px;
    padding: 12px 15px;
    border-radius: 6px;
    font-size: 14px;
}

.email-share-feedback.success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.email-share-feedback.error {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

/* ============================================
   RESPONSIVO
   ============================================ */
@media (max-width: 1200px) {
    .content-with-sidebar { grid-template-columns: 1fr; }
    .sidebar { position: relative; top: 0; }
}

@media (max-width: 1024px) {
    .tribunal-hero-container { grid-template-columns: 1fr; }
    .tribunal-actions { align-items: flex-start; margin-top: 20px; }
    .tribunal-share { align-items: flex-start; }
    .share-floating { display: none; }
}

@media (max-width: 768px) {
    .tribunal-title { font-size: 2rem; }
    .tribunals-nav-list { padding-bottom: 10px; }
    .news-grid { grid-template-columns: 1fr; }
    .filters-grid { grid-template-columns: 1fr; }

    .filter-actions {
        flex-direction: column;
        align-items: stretch;
    }

    .filter-actions .search-group {
        min-width: 100%;
    }

    .btn-search,
    .btn-clear {
        width: 100%;
        justify-content: center;
    }

    .post-notification {
        top: 60px;
        right: 10px;
        left: 10px;
        min-width: auto;
        max-width: calc(100% - 20px);
        padding: 0.875rem 1rem;
        font-size: 0.8125rem;
    }
}
