/* Voz do Fato - Main Styles with Dark Mode - HEADER SUPER COMPACTO */

/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    /* Light mode colors */
    --bg-primary: #f5f5f5;
    --bg-secondary: #ffffff;
    --text-primary: #333333;
    --text-secondary: #666666;
    --text-meta: #999999;
    --header-gradient: linear-gradient(135deg, #1e40af, #3b82f6);
    --nav-bg: #1e3a8a;
    --accent-color: #ef4444;
    --border-color: #eeeeee;
    --widget-bg: #ffffff;
    --shadow: rgba(0,0,0,0.1);
}

[data-theme="dark"] {
    /* Dark mode colors */
    --bg-primary: #1a1a1a;
    --bg-secondary: #2a2a2a;
    --text-primary: #e0e0e0;
    --text-secondary: #b0b0b0;
    --text-meta: #888888;
    --header-gradient: linear-gradient(135deg, #0f1a3a, #1e40af);
    --nav-bg: #0f1a3a;
    --accent-color: #ef4444;
    --border-color: #404040;
    --widget-bg: #2a2a2a;
    --shadow: rgba(0,0,0,0.3);
}

body {
    font-family: 'Arial', sans-serif;
    background-color: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    transition: background-color 0.3s ease, color 0.3s ease;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Fixed Buttons */
.fixed-buttons {
    position: fixed;
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
    display: flex;
    flex-direction: column;
    gap: 10px;
    z-index: 9999;
}

.theme-toggle,
.scroll-top {
    width: 50px;
    height: 50px;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    color: white;
    box-shadow: 0 4px 15px var(--shadow);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.theme-toggle {
    background: linear-gradient(135deg, #ef4444, #dc2626);
}

.scroll-top {
    background: linear-gradient(135deg, #ef4444, #dc2626);
}

.theme-toggle:hover,
.scroll-top:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 20px var(--shadow);
}

.theme-icon,
.scroll-icon {
    font-size: 20px;
    font-weight: bold;
}

.scroll-top {
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.scroll-top.visible {
    opacity: 1;
    visibility: visible;
}

/* Header Styles - HEADER SUPER COMPACTO */
header {
    background: var(--header-gradient);
    color: white;
    box-shadow: 0 2px 10px var(--shadow);
}

/* REDUÇÃO DRÁSTICA: Altura da barra do topo de 5px para 3px */
.header-top {
    padding: 3px 0; /* Reduzido de 5px para 3px */
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

.header-top-content {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    font-size: 11px; /* Reduzido de 12px para 11px */
    gap: 15px; /* Reduzido de 20px para 15px */
}


.date-time {
    display: flex;
}

.social-links {
    display: flex;
    gap: 4px; /* REDUZIDO de 8px para 4px - ícones bem mais próximos */
}

.social-links a {
    color: white;
    text-decoration: none;
    padding: 6px 8px; /* Reduzido de 8px 12px para 6px 8px */
    border-radius: 6px; /* Reduzido de 8px para 6px */
    font-size: 16px; /* Reduzido de 18px para 16px */
    transition: all 0.3s ease;
    min-width: 32px; /* Reduzido de 40px para 32px */
    text-align: center;
}

.social-links a:hover {
    background-color: rgba(255,255,255,0.1);
}

/* REDUÇÃO DRÁSTICA: Altura do header principal de 8px para 5px */
.header-main {
    padding: 5px 0; /* Reduzido de 8px para 5px */
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
}

.logo {
    font-size: 2.2em; /* Reduzido de 2.5em para 2.2em */
    font-weight: bold;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
    color: white;
}

.search-box {
    display: flex;
    background: white;
    border-radius: 25px;
    overflow: hidden;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    max-width: 300px;
}

.search-box input {
    border: none;
    padding: 10px 18px; /* Reduzido de 12px 20px para 10px 18px */
    outline: none;
    width: 250px;
    color: var(--text-primary);
    background: white;
}

.search-box button {
    background: var(--accent-color);
    border: none;
    padding: 10px 18px; /* Reduzido de 12px 20px para 10px 18px */
    color: white;
    cursor: pointer;
    transition: background-color 0.3s;
    flex-shrink: 0;
}

.search-box button:hover {
    background: #dc2626;
}

/* Navigation Styles - ALTURA TAMBÉM REDUZIDA */
nav {
    background: var(--nav-bg);
    padding: 0;
    position: relative;
}

/* Mobile Menu Toggle Button */
.mobile-menu-toggle {
    display: none;
    background: none;
    border: none;
    color: white;
    font-size: 24px;
    cursor: pointer;
    padding: 10px;
    border-radius: 5px;
    transition: background-color 0.3s;
}

.mobile-menu-toggle:hover {
    background: rgba(255,255,255,0.1);
}

.hamburger-icon {
    display: block;
    font-size: 24px;
}

/* Mobile Navigation Menu */
.mobile-nav-menu {
    display: none;
    background: var(--nav-bg);
    margin-top: 15px;
    border-radius: 10px;
    box-shadow: 0 4px 10px var(--shadow);
    overflow: hidden;
    opacity: 0;
    transform: translateY(-10px);
    transition: all 0.3s ease;
    max-height: 0;
}

.mobile-nav-menu.active {
    opacity: 1;
    transform: translateY(0);
    max-height: 500px;
}

.mobile-nav-menu ul {
    list-style: none;
    margin: 0;
    padding: 0;
}

.mobile-nav-menu li {
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

.mobile-nav-menu li:last-child {
    border-bottom: none;
}

.mobile-nav-menu a {
    color: white;
    text-decoration: none;
    padding: 15px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: background-color 0.2s;
}

.mobile-nav-menu a:hover {
    background: rgba(255,255,255,0.1);
}

/* Mobile dropdown styling */
.mobile-nav-menu .dropdown {
    display: none;
    background: #1e40af;
    margin: 0;
    opacity: 0;
    max-height: 0;
    overflow: hidden;
    transition: all 0.3s ease-in-out;
}

.mobile-nav-menu li.active .dropdown {
    display: block;
    opacity: 1;
    max-height: 300px;
}

.mobile-nav-menu .dropdown a {
    padding: 12px 40px;
    font-size: 14px;
    background: #1e40af;
}

.mobile-nav-menu .dropdown a:hover {
    background: rgba(255,255,255,0.1);
}

.mobile-nav-menu .dropdown-arrow {
    transition: transform 0.2s ease;
    font-size: 12px;
}

.mobile-nav-menu li.active .dropdown-arrow {
    transform: rotate(180deg);
}

/* Desktop Navigation - PADDING AINDA MAIS REDUZIDO */
.nav-menu {
    display: flex;
    list-style: none;
    gap: 0;
}

.nav-menu li {
    position: relative;
}

.nav-menu a {
    color: white;
    text-decoration: none;
    padding: 8px 18px; /* Reduzido de 12px 22px para 8px 18px */
    display: block;
    transition: background-color 0.3s;
    font-weight: 500;
    font-size: 14px; /* Adicionado tamanho de fonte menor */
}

.nav-menu a:hover {
    background: rgba(255,255,255,0.1);
}

.dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    background: var(--nav-bg);
    min-width: 200px;
    box-shadow: 0 4px 10px var(--shadow);
    display: none;
    z-index: 1000;
}

.nav-menu li:hover .dropdown {
    display: block;
}

.dropdown a {
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

/* Main Content Layout */
main {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 30px;
    padding: 30px 0;
}

.content-area {
    background: var(--bg-secondary);
    border-radius: 10px;
    box-shadow: 0 2px 10px var(--shadow);
    overflow: hidden;
    transition: background-color 0.3s ease;
}

/* Featured News */
.featured-news {
    position: relative;
    height: 400px;
    overflow: hidden;
}

.featured-news img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.featured-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(transparent, rgba(0,0,0,0.8));
    color: white;
    padding: 40px 30px 30px;
}

.featured-category {
    background: var(--accent-color);
    color: white;
    padding: 5px 15px;
    border-radius: 15px;
    font-size: 12px;
    font-weight: bold;
    display: inline-block;
    margin-bottom: 10px;
}

.featured-title {
    font-size: 1.8em;
    font-weight: bold;
    margin-bottom: 10px;
    line-height: 1.3;
}

.featured-meta {
    font-size: 14px;
    opacity: 0.9;
}

/* News List */
.news-list {
    padding: 30px;
}

.section-title {
    font-size: 1.8em;
    color: #1e40af;
    margin-bottom: 25px;
    padding-bottom: 10px;
    border-bottom: 3px solid var(--accent-color);
    font-weight: bold;
}

.news-item {
    display: flex;
    gap: 20px;
    margin-bottom: 25px;
    padding-bottom: 25px;
    border-bottom: 1px solid var(--border-color);
    transition: border-color 0.3s ease;
}

.news-item:last-child {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

.news-thumb {
    flex: 0 0 150px;
    height: 100px;
    overflow: hidden;
    border-radius: 8px;
}

.news-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s;
}

.news-thumb:hover img {
    transform: scale(1.1);
}

.news-content h3 {
    font-size: 1.1em;
    margin-bottom: 10px;
    color: #1e40af;
    line-height: 1.4;
    transition: color 0.3s ease;
}

.news-content h3:hover {
    color: var(--accent-color);
    cursor: pointer;
}

.news-excerpt {
    font-size: 14px;
    color: var(--text-secondary);
    margin-bottom: 8px;
    line-height: 1.5;
    transition: color 0.3s ease;
}

.news-meta {
    font-size: 12px;
    color: var(--text-meta);
    display: flex;
    gap: 15px;
    transition: color 0.3s ease;
}

/* Sidebar Styles */
.sidebar {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.widget {
    background: var(--widget-bg);
    border-radius: 10px;
    box-shadow: 0 2px 10px var(--shadow);
    overflow: hidden;
    transition: background-color 0.3s ease;
}

.widget-header {
    background: #1e40af;
    color: white;
    padding: 15px 20px;
    font-size: 1.2em;
    font-weight: bold;
}

.widget-content {
    padding: 20px;
}

/* Weather Widget */
.weather-info {
    text-align: center;
}

.weather-main {
    font-size: 2.5em;
    color: #1e40af;
    margin: 10px 0;
    font-weight: bold;
}

.weather-desc {
    color: var(--text-secondary);
    margin-bottom: 15px;
    transition: color 0.3s ease;
}

.weather-details {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
    font-size: 14px;
}

/* Most Read Widget */
.most-read-item {
    display: flex;
    gap: 15px;
    margin-bottom: 15px;
    padding-bottom: 15px;
    border-bottom: 1px solid var(--border-color);
    transition: border-color 0.3s ease;
}

.most-read-item:last-child {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

.most-read-number {
    flex: 0 0 30px;
    width: 30px;
    height: 30px;
    background: var(--accent-color);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 14px;
}

.most-read-content h4 {
    font-size: 14px;
    color: #1e40af;
    line-height: 1.4;
    margin-bottom: 5px;
    transition: color 0.3s ease;
}

.most-read-content h4:hover {
    color: var(--accent-color);
    cursor: pointer;
}

.most-read-meta {
    font-size: 12px;
    color: var(--text-meta);
    transition: color 0.3s ease;
}

/* Footer Styles */
footer {
    background: var(--nav-bg);
    color: white;
    margin-top: 50px;
}

.footer-content {
    /* Reduz o padding superior e inferior para 20px */
    padding: 20px 0;
    /* Altera o grid para ter 4 colunas em telas maiores, incluindo "Links Úteis" */
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    /* Reduz o espaçamento entre as colunas */
    gap: 20px;
}

.footer-section h3 {
    margin-bottom: 15px; /* Reduz a margem inferior do título */
    color: #60a5fa;
    font-size: 1.1em; /* Reduz o tamanho da fonte dos títulos */
}

.footer-section ul {
    list-style: none;
}

.footer-section li {
    margin-bottom: 5px; /* Reduz o espaçamento entre os itens da lista */
}

.footer-section a {
    color: white;
    text-decoration: none;
    font-size: 13px;
    transition: color 0.3s;
}

.footer-section a:hover {
    color: #60a5fa;
}

.footer-bottom {
    border-top: 1px solid rgba(255,255,255,0.1);
    padding: 15px 0;
    text-align: center;
    font-size: 13px;
}

/* Animation Effects */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.news-item {
    animation: fadeIn 0.6s ease-out;
}

/* Touch device optimizations */
.touch-device .nav-menu a,
.touch-device button,
.touch-device .clickable {
    -webkit-tap-highlight-color: rgba(0,0,0,0.1);
}

.touch-active {
    opacity: 0.7;
    transform: scale(0.98);
    transition: all 0.1s ease;
}

/* Mobile viewport height fix */
.mobile-height {
    height: 100vh;
    height: calc(var(--vh, 1vh) * 100);
}

/* AJUSTES PARA O LAYOUT DO HEADER-TOP */
.header-top-content {
    /* Esta regra vai empurrar o primeiro elemento (o tocador) para a esquerda
    e o restante (data e ícones) para a direita */
    justify-content: space-between;
}

/* Estilos para o tocador de áudio no header-top */
.audio-player-container {
    max-width: 250px;
    height: auto;
    display: flex;
    align-items: center;
}

.audio-player-container audio {
    width: 100%;
    height: 30px; 
    background-color: var(--nav-bg);
    border-radius: 5px;
}

/* Estilos para os controles do player (visuais) */
.audio-player-container audio::-webkit-media-controls-panel {
    background-color: transparent;
    border-radius: 5px;
}

/* Media query para dispositivos móveis */
@media (max-width: 768px) {
    .audio-player-container {
        max-width: 150px;
    }

    .date-time {
        display: none; /* Oculta a data para economizar espaço em telas pequenas */
    }
}

/* AJUSTES PARA O LAYOUT DO HEADER-TOP */
.header-top-content {
    justify-content: space-between;
}

/* Estilos para o contêiner do tocador */
.audio-player-container {
    display: flex;
    align-items: center;
    max-width: 250px; /* Largura ajustável para o seu design */
}

/* Estilos do tocador minimalista que você forneceu */
.minimal-player {
    display: flex;
    align-items: center;
    gap: 12px;
    background: #ffffff; /* Fundo branco ou outro que combine com seu tema */
    border: 1px solid #eeeeee;
    border-radius: 8px;
    padding: 6px 10px; /* Ajuste para caber melhor no cabeçalho */
    font-family: Arial, sans-serif;
    width: 100%;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    transition: background-color 0.3s;
}

.minimal-player .play {
    width: 24px;
    height: 24px;
    background: none;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    outline: none;
    position: relative;
}

/* Ícone de play */
.minimal-player .play::before {
    content: '';
    display: block;
    width: 0;
    height: 0;
    border-style: solid;
    border-width: 7px 0 7px 12px;
    border-color: transparent transparent transparent #1e40af; /* Cor do ícone */
    margin-left: 4px;
}

/* Ícone de pause */
.minimal-player .play.playing::before {
    border-width: 0 0 0 0;
    width: 14px;
    height: 14px;
    background: #1e40af;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.minimal-player .play.playing::after {
    content: '';
    display: block;
    width: 4px;
    height: 14px;
    background: #1e40af;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-90%, -50%);
}

.minimal-player .progress-bar {
    flex: 1;
    height: 4px;
    background: #eeeeee;
    border-radius: 2px;
    position: relative;
    cursor: pointer;
}

.minimal-player .progress {
    height: 100%;
    width: 0%;
    background: #ef4444; /* Cor da barra de progresso */
    border-radius: 2px;
    transition: width 0.2s linear;
}

.minimal-player .time {
    font-size: 11px; /* Tamanho da fonte menor para o cabeçalho */
    color: var(--text-primary);
    min-width: 36px;
    text-align: right;
}

/* Estilos para o modo escuro */
[data-theme="dark"] .minimal-player {
    background: #2a2a2a;
    border-color: #404040;
}

[data-theme="dark"] .minimal-player .play::before,
[data-theme="dark"] .minimal-player .play.playing::before,
[data-theme="dark"] .minimal-player .play.playing::after {
    background-color: #60a5fa;
    border-color: transparent transparent transparent #60a5fa;
}

[data-theme="dark"] .minimal-player .progress-bar {
    background: #404040;
}

@media (max-width: 768px) {
    .audio-player-container {
        max-width: 150px;
    }
    
    .date-time {
        display: none; /* Esconde a data no celular para economizar espaço */
    }
}

/* Modern Radio Player */
.modern-player {
    display: flex;
    align-items: center;
    gap: 12px;
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    padding: 8px 14px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
}

[data-theme="dark"] .modern-player {
    background: #2a2a2a;
    border: 1px solid #404040;
    box-shadow: 0 4px 8px rgba(0,0,0,0.4);
}

.modern-player:hover {
    box-shadow: 0 6px 12px rgba(0,0,0,0.15);
}

[data-theme="dark"] .modern-player:hover {
    box-shadow: 0 6px 12px rgba(0,0,0,0.6);
}

.play-pause {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    border: none;
    background: #ef4444;
    color: white;
    font-size: 18px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.3s ease, transform 0.2s;
}

.play-pause:hover {
    background: #dc2626;
    transform: scale(1.05);
}

.radio-info {
    display: flex;
    flex-direction: column;
}

.radio-title {
    font-weight: bold;
    font-size: 14px;
    color: #1e3a8a;
}

[data-theme="dark"] .radio-title {
    color: #60a5fa;
}

.radio-status {
    font-size: 12px;
    color: #ef4444;
    font-weight: bold;
}

/* Ajuste para mobile */
@media (max-width: 768px) {
    .modern-player {
        padding: 6px 10px;
    }
    .radio-title {
        font-size: 13px;
    }
    .radio-status {
        font-size: 11px;
    }
}
