/* ===== style_publicacoes.css ===== */
/* Complementa style_index.css — mesmas variáveis e fontes */

/* ---- Hero ---- */
.pub-hero {
    min-height: 42vh;
    background: linear-gradient(135deg, #1a1a1a 0%, #2d2d2d 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 120px 5% 60px;
    position: relative;
    overflow: hidden;
    text-align: center;
}

.pub-hero::before {
    content: '';
    position: absolute;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, var(--primary) 0%, transparent 70%);
    opacity: 0.18;
    top: -200px;
    right: -150px;
    animation: float 6s ease-in-out infinite;
}

.pub-hero::after {
    content: '';
    position: absolute;
    width: 350px;
    height: 350px;
    background: radial-gradient(circle, var(--accent) 0%, transparent 70%);
    opacity: 0.08;
    bottom: -120px;
    left: -100px;
    animation: float 8s ease-in-out infinite reverse;
}

.pub-hero-content {
    position: relative;
    z-index: 1;
    max-width: 700px;
}

.pub-hero-tag {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: var(--primary);
    color: white;
    font-size: 0.85rem;
    font-weight: 600;
    letter-spacing: 1px;
    text-transform: uppercase;
    padding: 0.4rem 1.2rem;
    border-radius: 50px;
    margin-bottom: 1.2rem;
}

.pub-hero-content h1 {
    font-family: 'Oswald', sans-serif;
    font-size: 3.5rem;
    color: white;
    line-height: 1.15;
    margin-bottom: 1rem;
}

.pub-hero-content .highlight {
    color: var(--accent);
}

.pub-hero-content p {
    font-size: 1.15rem;
    color: rgba(255,255,255,0.75);
    line-height: 1.7;
}

/* ---- Filtros ---- */
.pub-filtros {
    background: white;
    border-bottom: 1px solid #eee;
    padding: 1rem 5%;
    position: sticky;
    top: 60px;
    z-index: 100;
    box-shadow: 0 4px 20px rgba(0,0,0,0.06);
}

.pub-filtros-inner {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    gap: 0.6rem;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
}

.filtro-btn {
    padding: 0.5rem 1.4rem;
    border-radius: 50px;
    border: 2px solid #ddd;
    background: transparent;
    color: var(--text-dark);
    font-family: 'Oswald', sans-serif;
    font-size: 0.95rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
}

.filtro-btn:hover {
    border-color: var(--primary);
    color: var(--primary);
}

.filtro-btn.active {
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    border-color: transparent;
    color: white;
    box-shadow: 0 4px 15px rgba(139, 0, 0, 0.3);
}

/* ---- Grid ---- */
.pub-main {
    max-width: 1200px;
    margin: 0 auto;
    padding: 3rem 5% 4rem;
}

.pub-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.8rem;
    align-items: start;
}

/* Card em destaque ocupa 2 colunas */
.pub-card--destaque {
    grid-column: span 2;
}

/* Quando há apenas 1 card, ele fica centralizado */
.pub-grid:has(.pub-card:only-child) {
    grid-template-columns: 1fr;
    max-width: 600px;
    margin: 0 auto;
}

/* ---- Cards ---- */
.pub-card {
    background: white;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0,0,0,0.07);
    transition: transform 0.35s ease, box-shadow 0.35s ease;
    border-top: 4px solid transparent;
}

.pub-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 12px 40px rgba(0,0,0,0.13);
}

.pub-card[data-tipo="recital"]   { border-top-color: var(--primary); }
.pub-card[data-tipo="matricula"] { border-top-color: #0a7a3d; }
.pub-card[data-tipo="novidade"]  { border-top-color: #b8860b; }
.pub-card[data-tipo="evento"]    { border-top-color: #1a6b9e; }

/* ---- Badge ---- */
.pub-card-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.8px;
    text-transform: uppercase;
    padding: 0.35rem 1rem;
    border-radius: 0 0 10px 0;
    color: white;
}

.pub-badge--recital   { background: var(--primary); }
.pub-badge--matricula { background: #0a7a3d; }
.pub-badge--novidade  { background: #b8860b; }
.pub-badge--evento    { background: #1a6b9e; }

/* ---- Corpo ---- */
.pub-card-body {
    padding: 1.4rem 1.8rem 1.8rem;
}

.pub-card-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 0.8rem;
}

.pub-card-meta span {
    font-size: 0.82rem;
    color: #888;
    display: flex;
    align-items: center;
    gap: 0.35rem;
}

.pub-card-meta i {
    color: var(--primary);
    font-size: 0.8rem;
}

.pub-card-body h2 {
    font-family: 'Oswald', sans-serif;
    font-size: 1.4rem;
    color: var(--text-dark);
    margin-bottom: 0.7rem;
    line-height: 1.3;
}

.pub-card--destaque .pub-card-body h2 {
    font-size: 1.9rem;
}

.pub-card-body p {
    font-size: 0.97rem;
    color: #555;
    line-height: 1.7;
    margin-bottom: 1.5rem;
}

/* ---- Rodapé do card ---- */
.pub-card-footer {
    display: flex;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
}

.pub-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.6rem 1.5rem;
    border-radius: 50px;
    font-family: 'Oswald', sans-serif;
    font-size: 0.95rem;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
    cursor: pointer;
    border: none;
}

.pub-btn--primary {
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    color: white;
    box-shadow: 0 4px 15px rgba(139, 0, 0, 0.3);
}

.pub-btn--primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 25px rgba(139, 0, 0, 0.45);
}

.pub-btn--outline {
    background: transparent;
    color: var(--primary);
    border: 2px solid var(--primary);
}

.pub-btn--outline:hover {
    background: var(--primary);
    color: white;
}

/* ---- Estado vazio ---- */
.pub-empty {
    text-align: center;
    padding: 4rem 0;
    color: #aaa;
}

.pub-empty i {
    font-size: 3rem;
    margin-bottom: 1rem;
    display: block;
    color: #ddd;
}

.pub-empty p {
    font-size: 1.1rem;
}

/* ---- Garante visibilidade dos cards (o fade-in do index.js precisa de scroll) ---- */
.pub-grid .fade-in {
    opacity: 1;
    transform: translateY(0);
}

/* ---- Nav ativo ---- */
.nav-active {
    color: var(--primary) !important;
    font-weight: 700;
}

.nav-active::after {
    width: 100% !important;
}

/* ---- Responsivo ---- */
@media (max-width: 992px) {
    .pub-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .pub-card--destaque {
        grid-column: span 2;
    }
    .pub-hero-content h1 {
        font-size: 2.6rem;
    }
}

@media (max-width: 600px) {
    .pub-grid {
        grid-template-columns: 1fr;
    }
    .pub-card--destaque {
        grid-column: span 1;
    }
    .pub-hero-content h1 {
        font-size: 2rem;
    }
    .pub-filtros {
        top: 0;
    }
}

/* ---- Imagens dentro dos cards ---- */
.pub-card img {
    width: 100%;
    max-width: 100%;
    height: auto;
    display: block;
    border-radius: 8px;
    margin-top: 0.8rem;
    pointer-events: none;
    user-select: none;
    -webkit-user-drag: none;
}

/* Cartaz em destaque: limita altura e mostra inteiro sem cortar */
.pub-card--destaque img {
    max-height: 520px;
    object-fit: contain;
    background: #1a1a1a;
}

/* Cards normais: altura fixa com crop para imagens paisagem */
.pub-card:not(.pub-card--destaque) img {
    max-height: 220px;
    object-fit: cover;
}

/* ---- Z-index: hierarquia correta ---- */
header {
    z-index: 1050 !important;
}

.dropdown_menu {
    z-index: 1049 !important;
}

.dropdown_menu.open {
    height: 360px;
}

.pub-filtros {
    z-index: 99 !important;
}

.pub-main,
.pub-grid,
.pub-card {
    position: relative;
    z-index: 1;
}