/* css-mapa-do-site.css
   Estilos do Mapa do Site.
   Baseado em css-acessibilidade.css (modo escuro/claro, cartões, TOC e breadcrumbs).
*/

/* Paleta base (referência; tokens reais vêm do css-reorganizado.css) */
:root{
  --bg-dark: #0a0a0a;
  --bg-card: #1a1a1a;
  --text-white: #ffffff;
  --text-gray: #b0b0b0;
  --alarm-primary: #00d4ff;
  --alarm-secondary: #0099cc;
  --alarm-success: #00ff88;
  --alarm-warning: #ffaa00;
  --alarm-danger: #ff4757;

  --gradient-primary: linear-gradient(135deg, var(--alarm-primary) 0%, var(--alarm-secondary) 100%);
  --gradient-dark: linear-gradient(135deg, #1a1a1a 0%, #2d2d2d 100%);
  --gradient-bg: linear-gradient(135deg, #0a0a0a 0%, #1a1a1a 100%);
  --shadow-soft: 0 4px 20px rgba(0,0,0,.3);
  --shadow-glow: 0 0 30px rgba(0, 212, 255, 0.35);

  --radius-lg: 16px;
  --transition-fast: .2s ease;
  --transition-medium: .3s ease;

  /* Mapeamento local desta página */
  --page-bg: var(--gradient-bg);
  --card-bg: var(--bg-card);
  --text: var(--text-white);
  --text-muted: var(--text-gray);
  --border: rgba(255,255,255,0.12);

  /* Alias para compatibilidade com outras folhas (breadcrumbs) */
  --muted: var(--text-gray, #64748b);
}

[data-theme="light"]{
  --bg-dark: #ffffff;
  --bg-card: #ffffff;
  --text-white: #1e293b;
  --text-gray: #64748b;
  --alarm-primary: #0ea5e9;
  --alarm-secondary: #38bdf8;
  --alarm-success: #10b981;
  --alarm-warning: #f59e0b;
  --alarm-danger: #ef4444;

  --gradient-primary: linear-gradient(135deg, #0ea5e9 0%, #3b82f6 100%);
  --gradient-dark: linear-gradient(135deg, #f1f5f9 0%, #e2e8f0 100%);
  --gradient-bg: #ffffff;

  --shadow-soft: 0 4px 20px rgba(15,23,42,.08);
  --shadow-glow: 0 0 30px rgba(14,165,233,.25);

  --page-bg: var(--gradient-bg);
  --card-bg: var(--bg-card);
  --text: var(--text-white);
  --text-muted: var(--text-gray);
  --border: #cbd5e1;

  --muted: var(--text-gray);
}

/* Layout base da página (usando a mesma classe do main fornecido) */
.acessibilidade.container,
.sitemap.container{
  color: var(--text);
  background: transparent;
  padding-block: clamp(1rem, 2.5vw, 2rem);
  max-width: 800px;
  margin: auto;
}

/* Breadcrumbs — padrão unificado */
.breadcrumbs{
  margin-bottom: 14px;
  font-size: 14px;
  color: var(--muted);
}
.breadcrumbs ol{
    
  list-style: none;
  margin: 0;
  margin-left: 1rem;
  padding: 0;
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}
.breadcrumbs li+li::before{
  content: "›";
  color: var(--muted);
  opacity: .7;
  margin: 0 6px 0 2px;
}
.breadcrumbs a{
  color: #00d4ff;
  text-decoration: none;
}
.breadcrumbs a:hover{
  text-decoration: underline;
}

/* Hero */
.hero{
  
  background: var(--card-bg);
  border: 1px solid rgba(0, 212, 255, 0.6);
  border-radius: var(--radius-lg);
  padding: clamp(1rem, 2.5vw, 1.5rem);
  box-shadow: var(--shadow-soft);
}
.hero h1{
  margin: 0 0 .4rem 0;
  font-size: clamp(1.6rem, 3vw, 2.2rem);
}
.hero .lead{
  margin: .25rem 0 0;
  color: var(--text-muted);
}

/* TOC */
.toc{
  margin: 1rem 0 1.25rem;
  background: var(--card-bg);
  border: 1px solid rgba(0, 212, 255, 0.6);
  border-radius: var(--radius-lg);
  padding: .75rem 1rem;
}
.toc strong{ display:block; margin-bottom:.25rem; }
.toc ul{
  margin: .25rem 0 0;
  padding-left: 1.1rem;
  columns: 2;
  column-gap: 2rem;
}
@media (max-width: 720px){
  .toc ul{ columns: 1; }
}

/* Seções em layout de cartão */
.section{
  margin: 1.25rem 0;
  background: var(--card-bg);
  border: 1px solid rgba(0, 212, 255, 0.6);
  border-radius: var(--radius-lg);
  padding: clamp(1rem, 2.5vw, 1.25rem);
  box-shadow: var(--shadow-soft);
}
.section h2{
  margin: 0 0 .5rem 0;
  font-size: clamp(1.25rem, 2.5vw, 1.6rem);
}
.section .note{
  margin-top: .5rem;
  color: var(--text-muted);
  font-size: .95rem;
}

/* Listas do mapa: espaçamento e melhor legibilidade */
.section ul{
  margin: .25rem 0 0 1.1rem;
  padding: 0;
}
.section li{
  margin: .35rem 0;
}

/* Links do mapa: mesmo padrão de acessibilidade */
.acessibilidade a,
.sitemap a{
  color: var(--alarm-primary);
  text-decoration: none;
  transition: color var(--transition-fast);
}
.acessibilidade a:hover,
.sitemap a:hover{
  color: var(--alarm-secondary);
  text-decoration: underline;
}

/* Acessibilidade de foco */
.acessibilidade :focus-visible,
.sitemap :focus-visible{
  outline: 3px solid var(--alarm-primary);
  outline-offset: 2px;
}

/* Meta rodapé da página */
.meta{
  margin: 1.25rem 0 0;
  color: var(--text-muted);
  font-size: .95rem;
}

/* Redução de movimento */
@media (prefers-reduced-motion: reduce){
  *{ animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}

html{
  scroll-behavior: smooth;
  /* Espaço reservado acima do alvo ao rolar para uma âncora */
  scroll-padding-top: var(--header-offset, 88px);
}

/* Garante que qualquer elemento com id não fique oculto sob o header */
[id]{
  scroll-margin-top: var(--header-offset, 88px);
}