/*
Theme Name: NUPEP Tema
Author: Yann Dezedias
Description: Tema personalizado para o Núcleo de Pesquisa
Version: 3.1 (Diversas atualizações visuais, melhorias de usabilidade e otimizações de performance. Novo layout para a home, single e produções acadêmicas. Navegação redesenhada com dropdowns modernos. Tipografia aprimorada para melhor leitura. Responsividade otimizada para todos os dispositivos. Novos estilos para blocos de conteúdo, citações e galerias. Correção de bugs e ajustes finos em todo o tema.)
*/

/* --- 1. RESET E BASE --- */
* { margin: 0; padding: 0; box-sizing: border-box; }
body { font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif; background-color: #f9f9f9; }

/* --- 2. TIPOGRAFIA GERAL E TEXTOS --- */
.user-content-style { font-size: 18px; line-height: 1.8; color: #333; }
.user-content-style p { margin-bottom: 25px; text-align: justify; }
.user-content-style h2 { color: #5a2800; font-size: 28px; margin-top: 40px; margin-bottom: 20px; text-transform: uppercase; border-left: 5px solid #d35400; padding-left: 15px; }
.user-content-style h3 { color: #8B4513; font-size: 22px; margin-top: 30px; margin-bottom: 15px; font-weight: bold; }
.user-content-style ul { margin-bottom: 25px; padding-left: 40px; }
.user-content-style ul li { margin-bottom: 10px; list-style-type: disc; }
.user-content-style blockquote { background: #f9f9f9; border-left: 5px solid #5a2800; margin: 30px 0; padding: 20px; font-style: italic; color: #555; }

@media (max-width: 768px) {
    .entry-content, .user-content-style, .user-content-style p { font-size: 16px !important; line-height: 1.6 !important; }
    .user-content-style h2 { font-size: 22px !important; margin-top: 30px !important; margin-bottom: 15px !important; }
    .user-content-style h3 { font-size: 18px !important; margin-top: 25px !important; }
}

/* --- 3. CABEÇALHO E LOGO --- */
header { display: flex; align-items: center; justify-content: space-between; padding: 30px 50px; position: absolute; width: 100%; z-index: 100; color: white; }
.header-logo-img { height: 60px; width: auto; display: block; filter: brightness(0) invert(1) drop-shadow(0 2px 4px rgba(0,0,0,0.9)); }
.footer-logo-img { height: 40px; width: auto; max-width: 200px; display: block; filter: brightness(0) invert(1); }

/* --- 4. NAVEGAÇÃO DESKTOP --- */
@keyframes dynamicIslandPop {
    0% { transform: translateX(-50%) scale(0); opacity: 0; }
    60% { transform: translateX(-50%) scale(1.1); }
    100% { transform: translateX(-50%) scale(1); opacity: 1; }
}

.desktop-pilula { position: absolute; top: 30px; left: 50%; transform: translateX(-50%); z-index: 100; animation: dynamicIslandPop 1s cubic-bezier(0.175, 0.885, 0.32, 1.275) both; }
.desktop-links { list-style: none; display: flex; gap: 5px; margin: 0; padding: 8px 10px; background: rgba(60, 30, 0, 0.85); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); border: 1px solid rgba(255, 255, 255, 0.2); box-shadow: 0 15px 35px rgba(0,0,0,0.3); border-radius: 100px; white-space: nowrap; }
.desktop-links a { color: rgba(255, 255, 255, 0.9); text-decoration: none; font-weight: 700; font-size: 13px; text-transform: uppercase; padding: 8px 18px; border-radius: 50px; transition: all 0.3s ease; display: block; }
.desktop-links a:hover { background-color: rgba(255, 255, 255, 0.2); color: #fff; transform: scale(1.05); }

/* Dropdown Desktop */
.menu-item-has-children > a::after { content: ' ▾'; font-size: 10px; margin-left: 5px; position: relative; top: -1px; transition: transform 0.3s; display: inline-block; }

@media (min-width: 951px) {
    .desktop-links li { position: relative !important; }
    .desktop-links .sub-menu { position: absolute !important; top: calc(100% + 15px) !important; left: 0 !important; min-width: 220px !important; background: rgba(60, 30, 0, 0.95) !important; backdrop-filter: blur(15px) !important; -webkit-backdrop-filter: blur(15px) !important; border: 1px solid rgba(255, 255, 255, 0.2) !important; box-shadow: 0 15px 40px rgba(0,0,0,0.4) !important; border-radius: 15px !important; display: flex !important; flex-direction: column !important; padding: 15px !important; margin-top: 0 !important; gap: 5px !important; opacity: 0 !important; visibility: hidden !important; transform: translateY(10px) !important; transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275) !important; pointer-events: none !important; list-style: none !important; }
    .desktop-links .sub-menu::before { content: ''; position: absolute; top: -20px; left: 0; width: 100%; height: 20px; background: transparent; }
    .desktop-links li:hover > .sub-menu { opacity: 1 !important; visibility: visible !important; transform: translateY(0) !important; pointer-events: auto !important; }
    .desktop-links .sub-menu a { text-align: left !important; font-size: 13px !important; padding: 10px 15px !important; border-radius: 8px !important; white-space: normal !important; line-height: 1.4 !important; display: block !important; }
    .desktop-links .sub-menu a:hover { background-color: rgba(255, 255, 255, 0.1) !important; transform: translateX(5px) !important; }
    .desktop-links .sub-menu .menu-item-has-children > a::after { content: ' ›' !important; }
}

/* --- 5. NAVEGAÇÃO MOBILE --- */
.mobile-menu-wrapper { display: none; }

@media (max-width: 950px) {
    .desktop-pilula { display: none; }
    .mobile-menu-wrapper { display: block; position: fixed; top: 25px !important; right: 20px !important; z-index: 10000; }
    .mobile-toggle { display: flex; flex-direction: column; justify-content: center; align-items: center; gap: 5px; width: 70px; height: 45px; border-radius: 50px; background: rgba(60, 30, 0, 0.85); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); border: 1px solid rgba(255, 255, 255, 0.2); box-shadow: 0 4px 10px rgba(0,0,0,0.3); cursor: pointer; position: relative; z-index: 10002; transition: all 0.3s ease; }
    .mobile-toggle span { display: block; width: 28px; height: 3px; background-color: white; border-radius: 2px; transition: 0.3s; }
    .mobile-toggle:hover { background: rgba(80, 40, 0, 0.95); border-color: rgba(255, 255, 255, 0.4); }
    .mobile-menu-wrapper.menu-open .mobile-toggle { background: #d35400e6; transform: scale(1.05); }
    .mobile-menu-wrapper.menu-open .mobile-toggle span:nth-child(1) { transform: rotate(45deg) translate(5px, 6px); }
    .mobile-menu-wrapper.menu-open .mobile-toggle span:nth-child(2) { opacity: 0; }
    .mobile-menu-wrapper.menu-open .mobile-toggle span:nth-child(3) { transform: rotate(-45deg) translate(5px, -6px); }
    
    .mobile-dropdown { position: absolute; top: 60px; right: 0; width: 220px; background: rgba(60, 30, 0, 0.85); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); border: 1px solid rgba(255, 255, 255, 0.2); border-radius: 35px; padding: 25px; box-shadow: 0 15px 35px rgba(0,0,0,0.3); opacity: 0; visibility: hidden; transform: translateY(-10px) scale(0.95); transform-origin: top right; transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275); pointer-events: none; }
    .mobile-menu-wrapper.menu-open .mobile-dropdown { opacity: 1; visibility: visible; transform: translateY(0) scale(1); pointer-events: auto; }
    
    .mobile-links { list-style: none; padding: 0; margin: 0; }
    .mobile-links li { text-align: right; border-bottom: 1px solid rgba(255,255,255,0.1); margin-bottom: 10px; padding-bottom: 10px; }
    .mobile-links li:last-child { border: none; margin: 0; padding: 0; }
    .mobile-links a { color: white; text-decoration: none; font-weight: 600; font-size: 14px; display: block; text-transform: uppercase; }
    
    /* Dropdown Mobile */
    .mobile-links .sub-menu { display: none; background: rgba(0, 0, 0, 0.2) !important; box-shadow: inset 0 3px 10px rgba(0,0,0,0.1) !important; padding: 10px 0 !important; margin: 5px 0 10px 0 !important; border-radius: 15px !important; list-style: none !important; }
    .mobile-links .sub-menu li { border-bottom: 1px solid rgba(255,255,255,0.05) !important; padding: 0 !important; margin: 0 !important; }
    .mobile-links .sub-menu li:last-child { border: none !important; }
    .mobile-links .sub-menu li::before { display: none !important; }
    .mobile-links .sub-menu a { padding: 10px 25px 10px 15px !important; font-size: 12px !important; opacity: 0.9 !important; color: #ddd !important; text-transform: capitalize !important; margin-top: 5px; }
    .mobile-links .menu-item-has-children.open-submenu > .sub-menu { display: block !important; animation: fadeInDown 0.3s ease; }
    .mobile-links .menu-item-has-children.open-submenu > a::after { transform: rotate(180deg); }
    @keyframes fadeInDown { from { opacity: 0; transform: translateY(-5px); } to { opacity: 1; transform: translateY(0); } }
}

/* --- 6. PAGINAÇÃO E TAGS GERAIS --- */
.pagination { margin-top: 50px; display: flex; justify-content: center; gap: 10px; }
.pagination a, .pagination span { display: inline-block; padding: 10px 18px; background: white; border: 1px solid #ddd; color: #333; text-decoration: none; font-weight: bold; border-radius: 5px; transition: all 0.3s; }
.pagination a:hover { background-color: #f0f0f0; border-color: #ccc; }
.pagination .current { background-color: #5a2800; color: white; border-color: #5a2800; }
.tags-list { display: flex; flex-wrap: wrap; gap: 10px; }
.tag-btn { padding: 8px 16px; border: 1px solid #a05000; color: #a05000; text-decoration: none; font-size: 12px; text-transform: uppercase; transition: all 0.3s; }
.tag-btn:hover { background-color: #a05000; color: white; }

/* --- 7. HOME: HERO E SLIDER --- */
.hero { height: 80vh; width: 100%; background-color: #1a1a1a; background-size: cover; background-position: center; display: flex; flex-direction: column; justify-content: flex-end; padding-bottom: 80px; padding-left: 50px; color: white; }
.hero h1 { font-size: 36px; max-width: 900px; line-height: 1.2; margin-bottom: 15px; text-transform: uppercase; text-shadow: 2px 2px 10px rgba(0,0,0,0.8); }
.hero p { font-size: 18px; max-width: 800px; opacity: 0.95; text-shadow: 1px 1px 5px rgba(0,0,0,0.8); line-height: 1.5; display: -webkit-box; -webkit-line-clamp: 2; line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; text-overflow: ellipsis; }

.hero-slider-container { height: 80vh; width: 100%; position: relative; background-color: #1a1a1a; }
.swiper.heroSwiper { width: 100%; height: 100%; }
.swiper-slide.hero-slide { display: flex; flex-direction: column; justify-content: flex-end; padding-bottom: 80px; padding-left: 50px; box-sizing: border-box; }
.swiper-slide .hero-content { width: 100%; max-width: 1200px; margin: 0 auto; padding: 0 20px; }
.swiper-slide .hero-content h1, .swiper-slide .hero-content .hero-resumo { max-width: 800px; }
.swiper-slide .hero-content h1 a { color: #ffffff !important; text-shadow: 2px 2px 8px rgba(0,0,0,0.9); }
.swiper-slide .hero-content .hero-resumo, .swiper-slide .hero-content .hero-resumo p { color: #ffffff !important; text-shadow: 1px 1px 5px rgba(0,0,0,0.9); font-size: 16px; line-height: 1.5; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; text-overflow: ellipsis; margin-bottom: 0; }
.swiper-button-next, .swiper-button-prev { color: white !important; text-shadow: 0 0 5px rgba(0,0,0,0.5); }
.swiper-button-next:after, .swiper-button-prev:after { font-size: 30px !important; }
.swiper-pagination-bullet { background: white !important; opacity: 0.5; }
.swiper-pagination-bullet-active { opacity: 1; background: #d35400 !important; }

@media (max-width: 768px) {
    .swiper-slide .hero-content h1, .swiper-slide .hero-content h1 a { font-size: 26px !important; line-height: 1.2 !important; margin-bottom: 10px !important; }
    .swiper-slide .hero-content .hero-resumo, .swiper-slide .hero-content .hero-resumo p { font-size: 15px !important; }
}

/* --- 8. NOTÍCIAS (HOME, GRID E SINGLE) --- */
.news-section { background-color: white; padding: 60px 50px; }
.news-section h2, .section-title { color: #5a2800; margin-bottom: 30px; text-transform: uppercase; font-size: 24px; padding-bottom: 10px; }
.news-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 30px; }
.card { background: #fff; border: 1px solid #eee; border-radius: 8px; overflow: hidden; transition: transform 0.2s; }
.card:hover { transform: translateY(-5px); box-shadow: 0 10px 20px rgba(0,0,0,0.1); }
.card img { width: 100%; height: 220px; object-fit: cover; display: block; }
.card-content { padding: 20px; }
.card h3 { font-size: 18px; margin-bottom: 10px; color: #333; }
.card .date { display: block; font-size: 12px; color: #999; margin-bottom: 10px; font-weight: bold; }

.container-flex-news { max-width: 1200px; margin: 0 auto; padding: 0 20px; display: flex; gap: 50px; align-items: flex-start; }
.main-news-column { flex: 2.5; width: 100%; }
.news-sidebar { flex: 1; background-color: #fff; padding: 30px; border-radius: 8px; border: 1px solid #eee; box-shadow: 0 5px 20px rgba(0,0,0,0.05); position: sticky; top: 120px; }
.sidebar-widget { margin-bottom: 40px; }
.sidebar-widget h3 { color: #5a2800; font-size: 18px; text-transform: uppercase; border-bottom: 2px solid #5a2800; padding-bottom: 10px; margin-bottom: 20px; }
.search-field, .sidebar-widget select { width: 100%; padding: 12px; border: 1px solid #ccc; border-radius: 4px; font-size: 14px; background: white; }
.categories-list { list-style: none; padding: 0; margin: 0; }
.categories-list li { border-bottom: 1px solid #eee; padding: 10px 0; display: flex; justify-content: space-between; align-items: center; font-size: 14px; color: #777; }
.categories-list li a { text-decoration: none; color: #333; font-weight: 500; transition: color 0.2s; }
.categories-list li a:hover { color: #d35400; }

.single-hero { height: 60vh; width: 100%; background-size: cover !important; background-position: center !important; margin-bottom: 50px; }
.single-content-container { max-width: 800px; margin: 0 auto; padding: 0 20px; }
.single-title { font-size: 36px; color: #5a2800; text-transform: uppercase; margin-bottom: 10px; }
.single-subtitle { font-size: 14px; color: #d35400; font-weight: bold; text-transform: uppercase; margin-bottom: 30px; }
.post-meta { display: flex !important; align-items: center !important; gap: 15px !important; margin-bottom: 30px !important; }
.author-avatar img { border-radius: 50% !important; width: 60px !important; height: 60px !important; border: 2px solid #eee !important; display: block !important; margin: 0 !important; }
.meta-info { display: flex !important; flex-direction: column !important; justify-content: center !important; }
.author-name { font-weight: bold !important; color: #333 !important; font-size: 16px !important; margin: 0 0 2px 0 !important; line-height: 1.2 !important; display: block !important; }
.post-date { font-size: 13px !important; color: #777 !important; margin: 0 !important; line-height: 1.2 !important; display: block !important; }
.entry-content { font-size: 18px; line-height: 1.8; color: #333; margin-bottom: 50px; }
.entry-content img { max-width: 100%; height: auto; border-radius: 8px; margin: 20px 0; }
.related-themes-box { background-color: #eee; padding: 30px; border-radius: 5px; margin-bottom: 80px; }
.related-themes-box h3 { color: #d35400; font-size: 16px; text-transform: uppercase; margin-bottom: 15px; }
.recent-articles-section { background-color: #fff; padding: 50px 0; border-top: 1px solid #eee; }
.container-recent { max-width: 1000px; margin: 0 auto; padding: 0 20px; }

@media (max-width: 900px) {
    .container-flex-news { flex-direction: column; }
    .news-sidebar { width: 100%; position: static; margin-top: 40px; }
}
@media (max-width: 768px) {
    .single-title { font-size: 24px !important; line-height: 1.3 !important; margin-bottom: 15px !important; }
    .single-subtitle { font-size: 13px !important; margin-bottom: 20px !important; }
    .author-name { margin-bottom: 2px; }
}

/* --- 9. PRODUÇÕES ACADÊMICAS --- */
.home-producoes { background-color: #fcfcfc; padding: 60px 50px; border-top: 1px solid #eee; }
.container-producoes { max-width: 1200px; margin: 0 auto; }
.section-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 40px; border-bottom: 2px solid #5a2800; padding-bottom: 10px; }
.section-header h2 { color: #5a2800; font-size: 24px; text-transform: uppercase; margin: 0; }
.btn-ver-todas { color: #d35400; font-weight: bold; font-size: 14px; text-transform: uppercase; text-decoration: none; }
.producoes-home-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 40px; justify-content: center; }
.mini-book-card { transition: transform 0.3s; }
.mini-book-card:hover { transform: translateY(-10px); }
.mini-book-card a { text-decoration: none; color: inherit; }
.book-cover-wrapper { position: relative; box-shadow: 0 5px 15px rgba(0,0,0,0.15); border-radius: 4px; overflow: hidden; margin-bottom: 15px; width: 100%; aspect-ratio: 2 / 3; background: #ddd; }
.book-cover-wrapper img { width: 100%; height: 100%; object-fit: cover; display: block; }
.mini-book-card h3 { font-size: 16px; color: #333; margin-bottom: 5px; font-weight: bold; }
.book-author { font-size: 13px; color: #777; margin: 0; }
.badge-free { position: absolute; top: 10px; right: 10px; background-color: #27ae60; color: white; font-size: 10px; font-weight: bold; padding: 3px 8px; border-radius: 3px; text-transform: uppercase; }

.productions-header, .database-header { background-color: #5a2800; padding: 120px 0 60px 0; text-align: center; color: white; border-bottom-left-radius: 50% 20px; border-bottom-right-radius: 50% 20px; margin-bottom: 50px; }
.productions-header h1, .database-header h1 { font-size: 32px; text-transform: uppercase; letter-spacing: 1px; text-shadow: 2px 2px 4px rgba(0,0,0,0.3); }

.book-page-container { max-width: 1100px; margin: 0 auto; padding: 0 20px; }
.book-details-wrapper { display: flex; gap: 50px; margin-bottom: 50px; align-items: flex-start; }
.book-cover-col { flex: 1; max-width: 400px; }
.book-cover-img { width: 100%; box-shadow: 0 10px 25px rgba(0,0,0,0.2); border-radius: 5px; }
.book-info-col { flex: 1.5; }
.book-title { font-size: 32px; color: #5a2800; text-transform: uppercase; margin-bottom: 10px; line-height: 1.2; }
.book-type { color: #d35400; font-weight: bold; text-transform: uppercase; margin-bottom: 20px; font-size: 18px; }
.book-meta p { font-size: 16px; color: #444; margin-bottom: 8px; line-height: 1.5; }
.book-action { margin-top: 30px; }
.btn-book { display: inline-block; background-color: #8B4513; color: white; padding: 15px 40px; text-decoration: none; font-weight: bold; font-size: 18px; border-radius: 8px; box-shadow: 0 4px 0 #5a2800; transition: transform 0.1s, box-shadow 0.1s; }
.btn-book:hover { background-color: #a05015; transform: translateY(2px); box-shadow: 0 2px 0 #5a2800; color: white; }
.book-description { font-size: 18px; line-height: 1.8; color: #333; margin-bottom: 80px; max-width: 900px; }

.books-archive-section { padding: 50px 20px; background-color: #f9f9f9; min-height: 500px; }
.container-books { max-width: 1200px; margin: 0 auto; }
.books-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 40px; justify-content: center; }
.book-card-item { background: transparent; transition: transform 0.3s; }
.book-card-item:hover { transform: translateY(-10px); }
.book-card-link { text-decoration: none; color: inherit; display: flex; flex-direction: column; height: 100%; }
.book-card-info { text-align: center; }
.book-card-info h3 { font-size: 16px; color: #5a2800; margin-bottom: 5px; line-height: 1.3; text-transform: uppercase; }
.book-year { display: block; font-size: 14px; color: #777; margin-bottom: 10px; }
.btn-details { display: inline-block; font-size: 12px; color: #d35400; font-weight: bold; text-transform: uppercase; border: 1px solid #d35400; padding: 5px 15px; border-radius: 20px; transition: all 0.2s; }
.book-card-item:hover .btn-details { background-color: #d35400; color: white; }

@media (max-width: 768px) {
    .book-details-wrapper { flex-direction: column; }
    .book-cover-col { max-width: 100%; margin: 0 auto; }
}

/* --- 10. EQUIPE E PERFIL --- */
.team-category-header { text-align: center; margin-top: 60px; margin-bottom: 40px; }
.team-cat-title { color: #5a2800; font-size: 28px; text-transform: uppercase; letter-spacing: 2px; margin-bottom: 15px; position: relative; display: inline-block; }
.team-cat-divider { border: 0; height: 3px; width: 80px; background-color: #d35400; margin: 0 auto; border-radius: 2px; }

.team-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 40px; justify-content: center; margin-bottom: 60px; }
.team-card { background: #fff; border: 1px solid #f0f0f0; border-radius: 10px; padding: 30px 20px; text-align: center; transition: transform 0.3s ease, box-shadow 0.3s ease; display: flex; flex-direction: column; justify-content: space-between; height: 100%; }
.team-card:hover { transform: translateY(-5px); box-shadow: 0 10px 25px rgba(0,0,0,0.08); border-color: transparent; }
.team-card a { transition: color 0.2s; }
.team-card h3 a:hover { color: #d35400; }

.team-photo-wrapper { width: 140px; height: 140px; margin: 0 auto 20px auto; border-radius: 50%; overflow: hidden; border: 3px solid #f9f9f9; box-shadow: 0 5px 15px rgba(0,0,0,0.1); transition: transform 0.3s ease, border-color 0.3s; }
.team-card:hover .team-photo-wrapper { border-color: #d35400; transform: scale(1.05); }
.team-photo-wrapper img { width: 100%; height: 100%; object-fit: cover; }
.team-info h3 { font-size: 18px; color: #5a2800; margin-bottom: 10px; font-weight: 700; }
.team-meta-text { margin-bottom: 25px; min-height: 50px; }
.team-role { display: block; font-size: 14px; color: #555; font-weight: 600; margin-bottom: 4px; }
.team-uni { display: block; font-size: 13px; color: #888; font-style: italic; }

.team-actions { display: flex; justify-content: center; align-items: center; gap: 10px; margin-top: auto; }
.btn-lattes { display: inline-block; padding: 8px 16px; border: 1px solid #d35400; color: #d35400; text-decoration: none; font-size: 12px; font-weight: bold; border-radius: 20px; text-transform: uppercase; transition: all 0.3s; }
.btn-lattes:hover { background-color: #d35400; color: white; }
.btn-email { display: flex; align-items: center; justify-content: center; width: 34px; height: 34px; border: 1px solid #ccc; border-radius: 50%; color: #555; text-decoration: none; font-size: 16px; transition: all 0.3s; }
.btn-email:hover { background-color: #555; color: white; border-color: #555; }

.profile-layout { display: flex; gap: 60px; }
.profile-sidebar { flex: 1; min-width: 250px; }
.profile-photo-wrapper { width: 200px; height: 200px; border-radius: 50%; overflow: hidden; border: 5px solid white; box-shadow: 0 10px 30px rgba(0,0,0,0.15); margin: 0 auto 30px auto; background: white; }
.profile-photo-wrapper img { width: 100%; height: 100%; object-fit: cover; }
.profile-actions { display: flex; flex-direction: column; gap: 10px; align-items: center; }
.btn-lattes-profile { display: block; width: 100%; max-width: 200px; padding: 10px; background: #d35400; color: white; text-decoration: none; font-weight: bold; border-radius: 30px; text-transform: uppercase; font-size: 14px; transition: background 0.3s; }
.btn-lattes-profile:hover { background: #a05000; }
.btn-email-profile { display: block; color: #555; text-decoration: none; font-size: 14px; }
.btn-email-profile:hover { color: #d35400; text-decoration: underline; }
.profile-bio { flex: 2.5; padding-top: 40px; }

.bio-collapsed { max-height: 300px; overflow: hidden; position: relative; transition: max-height 0.8s ease-in-out; }
.bio-expanded { max-height: 5000px; transition: max-height 1s ease-in-out; }
.bio-fade-overlay { position: absolute; bottom: 0; left: 0; width: 100%; height: 100px; background: linear-gradient(to bottom, rgba(255,255,255,0), rgba(255,255,255,1) 90%); pointer-events: none; transition: opacity 0.5s; }
.bio-expanded .bio-fade-overlay { opacity: 0; }

@media (max-width: 768px) {
    .profile-layout { flex-direction: column; gap: 20px; }
    .profile-sidebar { margin-top: -80px !important; }
    .profile-bio { padding-top: 0; }
}

/* --- 11. PROJETOS DE PESQUISA --- */
.projects-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(350px, 1fr)); gap: 30px; }
.project-card { background: white; border-radius: 12px; box-shadow: 0 5px 20px rgba(0,0,0,0.05); overflow: hidden; position: relative; border-left: 5px solid #5a2800; transition: transform 0.3s; padding: 25px; display: flex; flex-direction: column; }
.project-card:hover { transform: translateY(-5px); box-shadow: 0 10px 30px rgba(0,0,0,0.1); }
.project-status { position: absolute; top: 20px; right: 20px; font-size: 11px; font-weight: bold; text-transform: uppercase; padding: 4px 10px; border-radius: 20px; }
.status-green { background-color: #e6f9ed; color: #27ae60; }
.status-gray { background-color: #eee; color: #777; }
.project-type { display: block; font-size: 12px; color: #d35400; font-weight: bold; text-transform: uppercase; margin-bottom: 5px; }
.project-card h3 { font-size: 20px; margin: 5px 0 15px 0; line-height: 1.3; }
.project-card h3 a { text-decoration: none; color: #333; }
.project-author { font-size: 14px; color: #555; margin-bottom: 15px; border-bottom: 1px solid #eee; padding-bottom: 10px; }
.project-excerpt { font-size: 14px; color: #666; margin-bottom: 20px; flex-grow: 1; }
.btn-project-details { text-decoration: none; color: #5a2800; font-weight: bold; font-size: 14px; }
.project-year { position: absolute; bottom: 20px; right: 20px; font-size: 30px; font-weight: 800; color: #f0f0f0; z-index: 0; pointer-events: none; }
.project-status-pill { padding: 6px 12px; border-radius: 4px; font-weight: bold; font-size: 12px; text-transform: uppercase; background: white; }
.project-status-pill.status-green { color: #27ae60; }
.project-status-pill.status-gray { color: #777; }

/* --- 12. PLUGINS E EXTRAS (DataTables) --- */
.wpDataTablesWrapper table { font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif !important; }
.wpDataTablesWrapper table thead th { background-color: #5a2800 !important; color: white !important; text-transform: uppercase; padding: 15px !important; border: none !important; }
.wpDataTablesWrapper table tbody td { padding: 12px !important; border-bottom: 1px solid #eee !important; color: #333; }
.wpDataTablesWrapper table tbody tr:nth-child(odd) td { background-color: #fcfcfc; }
.wpDataTablesWrapper table tbody tr:hover td { background-color: #ffe6d5; }
.wpDataTableFilterSection input, .wpDataTableFilterSection select { padding: 8px; border: 1px solid #ccc; border-radius: 4px; width: 100%; }

/* --- 13. ALINHAMENTOS GERAIS PARA CELULAR (Evitar Vazamentos) --- */
@media (max-width: 768px) {
    .news-section, .home-producoes, .projects-section { padding: 40px 20px !important; }
    .news-grid, .projects-grid, .team-grid, .producoes-home-grid { grid-template-columns: 1fr !important; }
}

/* --- 14. RODAPÉ --- */
.nupep-footer { background-color: #3e1e09; color: white; padding: 60px 0 40px 0; position: relative; overflow: hidden; margin-top: 0; }
.footer-container { max-width: 1200px; margin: 0 auto; padding: 0 40px; position: relative; z-index: 2; }
.footer-top-row { display: flex; justify-content: space-between; align-items: center; margin-bottom: 50px; }
.footer-socials { display: flex; gap: 20px; }
.footer-socials a { color: white; transition: transform 0.2s, color 0.2s; }
.footer-socials a:hover { color: #d35400; transform: scale(1.1); }
.footer-nav-row { margin-bottom: 40px; }
.footer-menu-list { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 40px; }
.footer-menu-list li a { color: white; text-decoration: none; font-weight: 700; font-size: 16px; text-transform: capitalize; display: block; padding-top: 15px; border-top: 3px solid white; transition: border-color 0.3s, color 0.3s; }
.footer-menu-list li a:hover { color: #ddd; border-color: #d35400; }
.footer-bottom-row { margin-top: 20px; }
.footer-divider { border: 0; border-top: 1px solid rgba(255,255,255,0.2); margin-bottom: 20px; }
.footer-bottom-row p { font-size: 12px; opacity: 0.7; }
.footer-curve-top-right { position: absolute; top: -50px; right: -50px; width: 150px; height: 150px; border-radius: 50%; border: 2px solid rgba(255,255,255,0.3); z-index: 1; }
.footer-curve-bottom-left { position: absolute; bottom: -50px; left: -50px; width: 200px; height: 200px; border-radius: 50%; border: 2px solid rgba(255,255,255,0.3); z-index: 1; }

@media (max-width: 768px) {
    .footer-top-row { flex-direction: column; align-items: flex-start; gap: 30px; }
    .footer-menu-list { flex-direction: column; gap: 20px; }
    .footer-menu-list li a { display: inline-block; }
}

/* =========================================
   PÍLULA BRANCA 10 ANOS (MOCKUP PERFEITO)
   ========================================= */

/* --- 1. DESKTOP (PC) --- */
.desktop-links .menu-item-destaque {
    position: relative !important;
    width: 155px !important; 
    height: 30px !important; 
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    margin: 0 !important;
    padding: 0 !important;
}

.desktop-links .menu-item-destaque a {
    position: absolute !important;
    top: 50% !important;
    left: 50% !important;
    transform: translate(-50%, -50%) !important; 
    background-color: #ffffff !important;
    
    /* Esconde o texto do WordPress */
    color: transparent !important;
    font-size: 0 !important;
    text-indent: -9999px !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    
    width: 165px !important; 
    height: 56px !important; 
    border-radius: 50px !important;
    box-shadow: 0 4px 15px rgba(0,0,0,0.2) !important;
    border: none !important;
    padding: 0 !important;
    transition: all 0.3s ease !important;
}

.desktop-links .menu-item-destaque a:hover {
    transform: translate(-50%, -50%) scale(1.08) !important; 
    box-shadow: 0 8px 25px rgba(0,0,0,0.3) !important;
}

.desktop-links .menu-item-destaque a::after {
    content: "" !important;
    position: absolute !important;
    top: 0 !important; left: 0 !important; right: 0 !important; bottom: 0 !important;
    background-image: url('./assets/img/10-anos-logo.png') !important;
    background-size: 70% auto !important; 
    background-position: center !important;
    background-repeat: no-repeat !important;
    filter: brightness(0.2) sepia(1) hue-rotate(330deg) saturate(3) !important; 
}


/* --- 2. MOBILE (TELEMÓVEL) --- */
@media (max-width: 950px) {
    /* Transforma o <ul> do menu em flexbox para podermos reordenar os itens */
    .mobile-links {
        display: flex;
        flex-direction: column;
    }

    .mobile-links .menu-item-destaque {
        order: -1 !important; /* JOGA A PÍLULA PARA O TOPO DA LISTA */
        display: flex !important;
        justify-content: center !important; /* Centraliza a pílula no telemóvel */
        padding: 5px 0 25px 0 !important; /* Mais espaço por baixo dela */
        border-bottom: 1px solid rgba(255,255,255,0.1); /* Linha divisória após o destaque */
        margin-bottom: 15px;
    }
    
    .mobile-links .menu-item-destaque a {
        position: relative !important;
        display: block !important;
        background-color: #ffffff !important;
        width: 170px !important; /* Um pouco mais larga para ficar bonita no centro */
        height: 55px !important;
        border-radius: 30px !important;
        margin: 0 !important;
        padding: 0 !important;
        box-shadow: 0 4px 10px rgba(0,0,0,0.3) !important;
        
        color: transparent !important;
        font-size: 0 !important;
        line-height: 0 !important;
        text-indent: -9999px !important;
        white-space: nowrap !important;
        overflow: hidden !important;
    }

    .mobile-links .menu-item-destaque a::after {
        content: "" !important;
        position: absolute !important;
        top: 0 !important; left: 0 !important; right: 0 !important; bottom: 0 !important;
        background-image: url('./assets/img/10-anos-logo.png') !important;
        background-size: 65% auto !important;
        background-position: center !important;
        background-repeat: no-repeat !important;
        filter: brightness(0.2) sepia(1) hue-rotate(330deg) saturate(3) !important;
    }
}

/* =========================================
   ÍCONE DE CASA (HOME) NO MENU PRINCIPAL
   ========================================= */

/* Classe específica para transformar qualquer item do menu num ícone de casa */
.desktop-links .menu-item-home a {
    font-size: 0 !important; /* Esconde a palavra "Início" */
    color: transparent !important;
    
    width: 32px !important;
    height: 32px !important;
    padding: 0 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    border-radius: 50% !important; /* Botão redondo */
    margin-right: 5px; /* Dá um respiro para o botão seguinte */
    
    /* Injeta um ícone SVG de Casa diretamente pelo CSS */
    background-image: url("data:image/svg+xml;charset=UTF-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='rgba(255,255,255,0.85)' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3 9l9-7 9 7v11a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2z'/%3E%3Cpolyline points='9 22 9 12 15 12 15 22'/%3E%3C/svg%3E") !important;
    background-size: 18px auto !important;
    background-position: center !important;
    background-repeat: no-repeat !important;
    transition: background-color 0.3s ease !important;
}

/* Efeito ao passar o rato (Fica mais branco) */
.desktop-links .menu-item-home a:hover {
    background-color: rgba(255, 255, 255, 0.15) !important;
    background-image: url("data:image/svg+xml;charset=UTF-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23ffffff' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3 9l9-7 9 7v11a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2z'/%3E%3Cpolyline points='9 22 9 12 15 12 15 22'/%3E%3C/svg%3E") !important;
}

/* Evita que o ícone de casa apareça quebrado no menu mobile.
   No mobile, o texto "Início" volta a aparecer normalmente. */
@media (max-width: 950px) {
    .mobile-links .menu-item-home a {
        font-size: 14px !important;
        color: white !important;
        background-image: none !important;
        width: auto !important;
        height: auto !important;
        border-radius: 0 !important;
        margin: 0 !important;
    }
}

/* =========================================
   CENTRALIZAR TEXTOS DO MENU MOBILE
   ========================================= */
@media (max-width: 950px) {
    /* Centraliza os links principais (Início, Notícias, etc) */
    .mobile-links li {
        text-align: center !important;
    }
    
    /* Centraliza os links de dentro do submenu (dropdown "Mais") e corrige o espaçamento torto */
    .mobile-links .sub-menu a {
        text-align: center !important;
        padding: 10px !important; 
    }
}

/* =========================================
    CAIXA DAS LOGOS (E O TRUQUE DO SAFARI)
========================================= */
    .logo-animada-wrapper {
        display: flex;
        align-items: center !important;
        height: 50px; 
        width: 180px; /* Fundamental para segurar as imagens que vão flutuar */
        position: relative; /* Permite colocar uma imagem em cima da outra */
        margin: 0 !important;
        padding: 0 !important;
        
        /* O TRUQUE: O filtro de cor fica na caixa pai, não nas imagens. 
            Isso mata o bug da sombra preta no iPhone na hora! */
        -webkit-filter: brightness(0) invert(1);
        filter: brightness(0) invert(1);
        
        /* Força a renderização por hardware na Apple */
        -webkit-transform: translate3d(0,0,0);
        transform: translate3d(0,0,0);
    }

    .logo-padrao, .logo-comemorativa {
        position: absolute; /* Coloca uma por cima da outra */
        left: 0; /* Trava as duas no mesmo ponto de partida */
        margin: 0 !important; 
        padding: 0 !important;
        height: auto;
        max-height: 50px; 
        display: block;
        
        /* As imagens já não têm filter aqui! 
            Transição estrita apenas na opacidade para não bugar o Safari */
        -webkit-transition: opacity 1s ease-in-out;
        transition: opacity 1s ease-in-out;
        will-change: opacity;
    }

    /* --- Lógica da Animação (Esconde/Mostra) --- */
    .logo-padrao {
        opacity: 1;
    }
    .logo-comemorativa {
        opacity: 0;
    }

    /* Quando o JavaScript adiciona a classe "efeito-10-anos" */
    .logo-animada-wrapper.efeito-10-anos .logo-padrao {
        opacity: 0;
    }
    .logo-animada-wrapper.efeito-10-anos .logo-comemorativa {
        opacity: 1;
    }

/* Responsivo */
@media (max-width: 900px) {
    .logo-animada-wrapper { height: 45px; width: 170px; }
}

/* =========================================
       MODAL DE METODOLOGIA
       ========================================= */
    .btn-metodologia {
        display: inline-flex;
        align-items: center;
        gap: 8px;
        background: transparent;
        color: rgba(255, 255, 255, 0.8);
        border: 1px solid rgba(255, 255, 255, 0.4);
        padding: 8px 16px;
        border-radius: 20px;
        font-size: 13px;
        text-transform: uppercase;
        cursor: pointer;
        margin-top: 20px;
        transition: 0.3s;
    }
    .btn-metodologia:hover {
        background: rgba(255, 255, 255, 0.1);
        color: #fff;
        border-color: #fff;
    }
    .nupep-modal-overlay {
        position: fixed; top: 0; left: 0; width: 100%; height: 100%;
        background: rgba(0,0,0,0.7); z-index: 9999;
        display: flex; justify-content: center; align-items: center;
        opacity: 0; visibility: hidden; transition: 0.3s ease;
    }
    .nupep-modal-overlay.active {
        opacity: 1; visibility: visible;
    }
    .nupep-modal-content {
        background: #fff; width: 90%; max-width: 650px;
        border-radius: 15px; padding: 40px; position: relative;
        max-height: 85vh; overflow-y: auto; text-align: left;
        transform: translateY(20px); transition: 0.3s ease;
        box-shadow: 0 20px 50px rgba(0,0,0,0.3);
    }
    .nupep-modal-overlay.active .nupep-modal-content {
        transform: translateY(0);
    }
    .nupep-modal-close {
        position: absolute; top: 20px; right: 20px;
        background: #eee; border: none; width: 30px; height: 30px;
        border-radius: 50%; cursor: pointer; font-weight: bold;
        color: #555; transition: 0.3s; display: flex; align-items: center; justify-content: center;
    }
    .nupep-modal-close:hover { background: #d35400; color: #fff; }
    .nupep-modal-title { color: #5a2800; margin-bottom: 20px; font-size: 24px; text-transform: uppercase; font-weight: 800;}
    .nupep-modal-text { color: #444; line-height: 1.7; font-size: 15px; text-align: justify; }
    .nupep-modal-text h4 { color: #d35400; margin-top: 25px; margin-bottom: 10px; font-size: 17px; text-transform: uppercase;}