/* ============================================
   MAPA DEL SITIO - VERSIÓN ACCESIBLE
   Sin íconos, diseño limpio y claro
   ============================================ */

.sitemap-container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 2rem 1.5rem;
}

/* ============================================
   ENCABEZADO
   ============================================ */

.sitemap-header {
  margin-bottom: 2rem;
  text-align: center;
}

.sitemap-title {
  font-size: 2rem;
  font-weight: 700;
  color: #1a365d;
  margin-bottom: 0.5rem;
}

.sitemap-description {
  font-size: 1.1rem;
  color: #4a5568;
}

/* ============================================
   NAVEGACIÓN RÁPIDA (SKIP LINKS)
   ============================================ */

.sitemap-skip-nav {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 0.5rem;
  padding: 0.75rem 1.25rem;
  margin-bottom: 2rem;
}

.skip-label {
  font-weight: 600;
  font-size: 0.9rem;
  color: #1e293b;
  margin-right: 1rem;
}

.skip-links {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 1rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.skip-links li {
  margin: 0;
}

.skip-links a {
  font-size: 0.9rem;
  color: #cd0000;
  text-decoration: none;
  font-weight: 500;
  padding: 0.25rem 0;
  border-bottom: 1px solid transparent;
  transition: border-color 0.2s ease;
}

.skip-links a:hover,
.skip-links a:focus {
  border-bottom-color: #cd0000;
  outline: none;
}

/* ============================================
   GRID PRINCIPAL
   ============================================ */

.sitemap-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
}

@media (max-width: 768px) {
  .sitemap-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }
}

.sitemap-col {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

/* ============================================
   SECCIONES
   ============================================ */

.sitemap-section {
  border: 1px solid #e2e8f0;
  border-radius: 0.75rem;
  padding: 1.25rem 1.5rem;
  background: white;
  scroll-margin-top: 80px;
}

.sitemap-section h2 {
  font-size: 1.25rem;
  font-weight: 700;
  color: #1a365d;
  margin: 0 0 1rem 0;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid #cd0000;
  display: inline-block;
}

/* ============================================
   LISTAS DE ENLACES - ESTILO CLARO
   ============================================ */

.sitemap-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.sitemap-list li {
  margin-bottom: 0.5rem;
  padding: 0;
}

.sitemap-list li:last-child {
  margin-bottom: 0;
}

.sitemap-list a {
  display: block;
  padding: 0.5rem 0;
  color: #334155;
  text-decoration: none;
  font-size: 0.9rem;
  border-bottom: 1px solid #f1f5f9;
  transition: all 0.2s ease;
}

.sitemap-list a:hover,
.sitemap-list a:focus {
  color: #cd0000;
  padding-left: 0.5rem;
  border-bottom-color: #cd0000;
  outline: none;
}

/* Estilo para focus visible */
.sitemap-list a:focus-visible {
  outline: 2px solid #cd0000;
  outline-offset: 2px;
  border-radius: 0.25rem;
}

/* ============================================
   GRID PARA COORDINACIONES (2 columnas)
   ============================================ */

.sitemap-list-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0 1.5rem;
}

.sitemap-list-grid li {
  margin-bottom: 0.25rem;
}

@media (max-width: 600px) {
  .sitemap-list-grid {
    grid-template-columns: 1fr;
    gap: 0;
  }
}

/* ============================================
   BOTÓN VOLVER ARRIBA
   ============================================ */

.sitemap-back-to-top {
  margin-top: 2.5rem;
  text-align: center;
  padding-top: 1rem;
  border-top: 1px solid #e2e8f0;
}

.back-to-top-link {
  display: inline-block;
  padding: 0.5rem 1rem;
  color: #cd0000;
  text-decoration: none;
  font-weight: 500;
  font-size: 0.9rem;
  border: 1px solid #cd0000;
  border-radius: 2rem;
  transition: all 0.2s ease;
}

.back-to-top-link:hover,
.back-to-top-link:focus {
  background: #cd0000;
  color: white;
  outline: none;
}

/* ============================================
   RESPONSIVE
   ============================================ */

@media (max-width: 1024px) {
  .sitemap-container {
    padding: 1.5rem;
  }
}

@media (max-width: 768px) {
  .sitemap-container {
    padding: 1rem;
  }
  
  .sitemap-title {
    font-size: 1.75rem;
  }
  
  .sitemap-description {
    font-size: 1rem;
  }
  
  .sitemap-section {
    padding: 1rem 1.25rem;
  }
  
  .sitemap-section h2 {
    font-size: 1.1rem;
  }
  
  .skip-links {
    margin-top: 0.5rem;
    display: flex;
  }
  
  .skip-label {
    display: block;
    margin-bottom: 0.5rem;
  }
}

@media (max-width: 480px) {
  .sitemap-section {
    padding: 1rem;
  }
  
  .sitemap-list a {
    font-size: 0.85rem;
    padding: 0.4rem 0;
  }
  
  .back-to-top-link {
    padding: 0.4rem 0.8rem;
    font-size: 0.85rem;
  }
}

/* ============================================
   IMPRESIÓN - Para accesibilidad en papel
   ============================================ */

@media print {
  .sitemap-skip-nav,
  .sitemap-back-to-top {
    display: none;
  }
  
  .sitemap-section {
    break-inside: avoid;
    page-break-inside: avoid;
    border: 1px solid #ccc;
  }
  
  .sitemap-list a {
    color: black;
    text-decoration: none;
  }
}

/* ============================================
   ANCLAJES PARA NAVEGACIÓN (compensan header fijo)
   ============================================ */

.sitemap-section-anchor {
  display: block;
  position: relative;
  top: -100px; /* Altura del header fijo + margen extra */
  visibility: hidden;
}

/* Alternativa: scroll-margin-top en las secciones */
.sitemap-section {
  scroll-margin-top: 100px;
}