/* ==============================================
   FOOTER PIRANOT PORTAL NACIONAL v2.0
   Profissional, sem emojis, ícones TSI
   ============================================== */

:root {
  --footer-bg-primary: #1a1a2e;
  --footer-bg-secondary: #16213e;
  --footer-bg-tertiary: #0f3460;
  --footer-text: #eaeaea;
  --footer-text-muted: #a0a0a0;
  --footer-link-hover: #e94560;
  --footer-border: rgba(255,255,255,0.1);
  --transition: all 0.3s ease;
}

/* Acessibilidade - screen reader only */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ==============================================
   NIVEL 1: NEWSLETTER
   ============================================== */
.footer-newsletter {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  padding: 50px 0;
  color: white;
}

.newsletter-grid {
  display: grid;
  grid-template-columns: 1.5fr 2fr 0.8fr;
  gap: 40px;
  align-items: center;
}

.footer-newsletter h3 {
  font-size: 26px;
  font-weight: 700;
  margin-bottom: 8px;
}

.footer-newsletter p {
  font-size: 15px;
  opacity: 0.95;
  margin: 0;
  line-height: 1.5;
}

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

.newsletter-form input[type="email"] {
  flex: 2;
  min-width: 220px;
  padding: 12px 18px;
  border: none;
  border-radius: 6px;
  font-size: 14px;
  background: rgba(255,255,255,0.95);
  color: #333;
}

.newsletter-form select {
  flex: 1;
  min-width: 160px;
  padding: 12px 18px;
  border: none;
  border-radius: 6px;
  font-size: 14px;
  background: rgba(255,255,255,0.95);
  color: #333;
}

.newsletter-form button {
  padding: 12px 28px;
  background: #1a1a2e;
  color: white;
  border: none;
  border-radius: 6px;
  font-weight: 600;
  font-size: 14px;
  cursor: pointer;
  transition: var(--transition);
}

.newsletter-form button:hover {
  background: #0f3460;
  transform: translateY(-2px);
}

.newsletter-stats {
  text-align: center;
  border-left: 1px solid rgba(255,255,255,0.3);
  padding-left: 30px;
}

.stat-number {
  display: block;
  font-size: 38px;
  font-weight: 800;
  line-height: 1;
}

.stat-label {
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 1px;
  opacity: 0.9;
}

/* ==============================================
   NIVEL 2: EDITORIAS
   ============================================== */
.footer-editorias {
  background: var(--footer-bg-primary);
  padding: 50px 0 40px;
  color: var(--footer-text);
}

.editorias-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 35px;
}

.editoria-col h4 {
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 18px;
  color: var(--footer-link-hover);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.editoria-col h4 a {
  color: inherit;
  text-decoration: none;
  transition: var(--transition);
}

.editoria-col h4 a:hover {
  opacity: 0.8;
}

.editoria-col h4::before {
  content: '';
  display: block;
  width: 35px;
  height: 3px;
  background: var(--footer-link-hover);
  margin-bottom: 12px;
}

.editoria-col ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.editoria-col li {
  margin-bottom: 8px;
}

.editoria-col li a {
  color: var(--footer-text-muted);
  text-decoration: none;
  font-size: 13px;
  transition: var(--transition);
  display: inline-block;
}

.editoria-col li a:hover {
  color: var(--footer-link-hover);
  padding-left: 5px;
}

/* ==============================================
   NIVEL 3: INSTITUCIONAL (MAPA + REDES + CONTATO)
   ============================================== */
.footer-institucional {
  background: var(--footer-bg-secondary);
  padding: 45px 0 35px;
  border-top: 1px solid var(--footer-border);
  color: var(--footer-text);
}

.institucional-grid {
  display: grid;
  grid-template-columns: 2fr 1.5fr 1.5fr 1fr;
  gap: 40px;
}

.inst-col h5 {
  font-size: 14px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 18px;
  color: var(--footer-text);
  position: relative;
  padding-bottom: 10px;
}

.inst-col h5::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 25px;
  height: 2px;
  background: var(--footer-link-hover);
}

/* Mapa do Site */
.inst-mapa .mapa-list {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px 20px;
  list-style: none;
  padding: 0;
  margin: 0;
}

.inst-mapa li a {
  color: var(--footer-text-muted);
  text-decoration: none;
  font-size: 13px;
  transition: var(--transition);
}

.inst-mapa li a:hover {
  color: var(--footer-link-hover);
}

/* Redes Sociais */
.redes-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.redes-list li {
  margin-bottom: 10px;
}

.redes-list li a {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--footer-text);
  text-decoration: none;
  padding: 8px 10px;
  border-radius: 6px;
  background: rgba(255,255,255,0.05);
  transition: var(--transition);
}

.redes-list li a:hover {
  background: rgba(255,255,255,0.1);
  transform: translateX(3px);
}

.redes-list li a .tsi {
  font-size: 16px;
  width: 20px;
  text-align: center;
}

.rede-nome {
  flex: 1;
  font-size: 13px;
}

.rede-seguidores {
  font-size: 11px;
  color: var(--footer-text-muted);
  background: rgba(255,255,255,0.1);
  padding: 2px 8px;
  border-radius: 10px;
}

/* Contato */
.inst-contato .contact-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.inst-contato li {
  margin-bottom: 12px;
}

.inst-contato .label {
  display: block;
  font-size: 11px;
  color: var(--footer-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 2px;
}

.inst-contato a {
  color: var(--footer-text);
  text-decoration: none;
  font-size: 13px;
  transition: var(--transition);
}

.inst-contato a:hover {
  color: var(--footer-link-hover);
}

/* Apps */
.inst-apps .app-links {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.app-link {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  background: rgba(255,255,255,0.05);
  border-radius: 6px;
  color: var(--footer-text);
  text-decoration: none;
  font-size: 13px;
  transition: var(--transition);
  border: 1px solid rgba(255,255,255,0.1);
}

.app-link:hover {
  background: rgba(255,255,255,0.1);
  border-color: rgba(255,255,255,0.2);
}

.app-icon {
  font-size: 18px;
  opacity: 0.8;
}

/* ==============================================
   NIVEL 4: LEGAL
   ============================================== */
.footer-legal {
  background: var(--footer-bg-tertiary);
  padding: 25px 0;
  border-top: 1px solid var(--footer-border);
}

.legal-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 20px;
}

.legal-left {
  display: flex;
  align-items: center;
  gap: 15px;
}

.logo-text {
  font-size: 22px;
  font-weight: 800;
  color: white;
  letter-spacing: 1px;
}

.copyright {
  color: var(--footer-text-muted);
  font-size: 13px;
  margin: 0;
}

.legal-nav ul {
  display: flex;
  gap: 25px;
  list-style: none;
  padding: 0;
  margin: 0;
  flex-wrap: wrap;
}

.legal-nav a {
  color: var(--footer-text);
  text-decoration: none;
  font-size: 12px;
  opacity: 0.8;
  transition: var(--transition);
}

.legal-nav a:hover {
  opacity: 1;
  color: var(--footer-link-hover);
}

.acessibilidade {
  display: flex;
  align-items: center;
  gap: 8px;
}

.btn-contraste,
.btn-fonte {
  background: rgba(255,255,255,0.1);
  border: none;
  color: var(--footer-text);
  padding: 6px 12px;
  border-radius: 4px;
  cursor: pointer;
  font-size: 13px;
  transition: var(--transition);
}

.btn-contraste:hover,
.btn-fonte:hover {
  background: rgba(255,255,255,0.2);
}

.btn-contraste .tsi {
  font-size: 14px;
}

/* ==============================================
   ACESSIBILIDADE - ALTO CONTRASTE
   ============================================== */
body.alto-contraste .footer-newsletter {
  background: #000;
  border-bottom: 3px solid #fff;
}

body.alto-contraste .footer-editorias,
body.alto-contraste .footer-institucional,
body.alto-contraste .footer-legal {
  background: #000;
  border-color: #fff;
}

body.alto-contraste .footer-text {
  color: #fff;
}

/* ==============================================
   RESPONSIVO
   ============================================== */
@media (max-width: 1024px) {
  .newsletter-grid {
    grid-template-columns: 1fr 1.5fr;
    gap: 30px;
  }
  
  .newsletter-stats {
    display: none;
  }
  
  .editorias-grid {
    grid-template-columns: repeat(3, 1fr);
  }
  
  .institucional-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  
  .inst-mapa .mapa-list {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  .footer-newsletter {
    padding: 35px 0;
  }
  
  .newsletter-grid {
    grid-template-columns: 1fr;
    text-align: center;
    gap: 25px;
  }
  
  .newsletter-form {
    flex-direction: column;
    width: 100%;
    max-width: 350px;
    margin: 0 auto;
  }
  
  .editorias-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 25px;
  }
  
  .institucional-grid {
    grid-template-columns: 1fr;
    gap: 30px;
  }
  
  .inst-mapa .mapa-list {
    grid-template-columns: repeat(2, 1fr);
  }
  
  .legal-inner {
    flex-direction: column;
    text-align: center;
  }
  
  .legal-left {
    flex-direction: column;
  }
  
  .legal-nav ul {
    justify-content: center;
    gap: 15px;
  }
}

@media (max-width: 480px) {
  .editorias-grid {
    grid-template-columns: 1fr;
  }
  
  .inst-mapa .mapa-list {
    grid-template-columns: 1fr;
  }
}

/* ==============================================
   ANIMAÇÕES
   ============================================== */
@keyframes fade-in-up {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.footer-newsletter,
.footer-editorias,
.footer-institucional,
.footer-legal {
  animation: fade-in-up 0.5s ease-out;
}

html {
  scroll-behavior: smooth;
}
