/* ====== VARIÁVEIS DE CORES E FONTES ====== */
:root {
  --primary-color: #2c3e50;
  --secondary-color: #3498db;
  --accent-color: #e74c3c;
  --light-bg: #f9f9f9;
  --dark-text: #333;
  --light-text: #777;
  --border-color: #e2e8f0;
  --shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  --shadow-hover: 0 8px 15px rgba(0, 0, 0, 0.15);
  --font-main: 'Open Sans', sans-serif;
  --font-heading: 'Cormorant Unicase', serif;
  --transition: all 0.3s ease;
}

/* ====== RESET E ESTILOS BASE ====== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: var(--font-main);
  line-height: 1.7;
  background-color: var(--light-bg);
  color: var(--dark-text);
  padding: 0;
  margin: 0;
}

/* ====== LAYOUT PRINCIPAL ====== */
.container {
  max-width: 1200px;
  margin: 40px auto;
  background: #fff;
  padding: 30px;
  border-radius: 12px;
  box-shadow: var(--shadow);
}

/* ====== CABEÇALHO DO POST ====== */
.post-header {
  text-align: center;
  margin-bottom: 40px;
  padding-bottom: 30px;
  border-bottom: 1px solid var(--border-color);
}

.post-header h1 {
  font-family: var(--font-heading);
  font-size: 2.8rem;
  color: var(--primary-color);
  margin-bottom: 20px;
  line-height: 1.2;
}

.post-meta {
  display: flex;
  justify-content: center;
  gap: 20px;
  margin-bottom: 20px;
  color: var(--light-text);
  font-size: 0.95rem;
}

.post-meta span {
  display: flex;
  align-items: center;
  gap: 5px;
}

.post-meta i {
  font-style: normal;
  color: var(--accent-color);
}

/* ====== TIPOGRAFIA ====== */
h1, h2, h3, h4 {
  color: var(--primary-color);
  margin-bottom: 1em;
  line-height: 1.3;
  font-family: var(--font-heading);
}

h1 {
  font-size: 2.8rem;
}

h2 {
  font-size: 2.2rem;
  border-bottom: 2px solid var(--primary-color);
  padding-bottom: 0.5em;
  margin-top: 1.8em;
}

h3 {
  font-size: 1.8rem;
  margin-top: 1.5em;
  color: #4a5568;
}

h4 {
  font-size: 1.3rem;
  font-weight: 500;
}

/* ====== COMPONENTES DE IMAGEM ====== */
.image-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin: 2.5em 0;
  position: relative;
}

img {
  max-width: 100%;
  height: auto;
  border-radius: 8px;
  box-shadow: var(--shadow);
  transition: var(--transition);
  margin-bottom: 0.8em;
}

img:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-hover);
}

.image-caption {
  font-size: 0.95rem;
  color: var(--light-text);
  text-align: center;
  width: 90%;
  font-style: italic;
  padding: 0.5em 1em;
  background-color: rgba(0,0,0,0.03);
  border-radius: 4px;
}

/* ====== TABELAS ====== */
table {
  width: 100%;
  border-collapse: collapse;
  margin: 2em 0;
  font-size: 0.95em;
  box-shadow: var(--shadow);
  border-radius: 8px;
  overflow: hidden;
}

th, td {
  padding: 15px;
  text-align: left;
  border: 1px solid var(--border-color);
}

th {
  background-color: var(--primary-color);
  color: white;
  font-weight: 600;
}

tr:nth-child(even) {
  background-color: #f8fafc;
}

tr:hover {
  background-color: #f0f5ff;
}

/* ====== LINKS E BOTÕES ====== */
a {
  color: var(--secondary-color);
  text-decoration: none;
  transition: var(--transition);
}

a:hover {
  color: var(--primary-color);
  text-decoration: underline;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 24px;
  margin: 15px 10px 0 0;
  background-color: var(--secondary-color);
  color: white;
  border-radius: 6px;
  text-align: center;
  transition: var(--transition);
  border: none;
  cursor: pointer;
  font-size: 0.95rem;
  font-weight: 600;
  box-shadow: var(--shadow);
}

.btn:hover {
  background-color: #2980b9;
  transform: translateY(-3px);
  box-shadow: var(--shadow-hover);
  text-decoration: none;
}

.btn-outline {
  background-color: transparent;
  border: 2px solid var(--secondary-color);
  color: var(--secondary-color);
}

.btn-outline:hover {
  background-color: var(--secondary-color);
  color: white;
}

.btn-blog {
  background-color: #4a5568;
}

.btn-blog:hover {
  background-color: #2d3748;
}

/* ====== COMPONENTES ESPECÍFICOS ====== */
.aviso-em-desenvolvimento {
  background-color: #fff3cd;
  color: #856404;
  border: 2px dashed #ffeeba;
  padding: 25px;
  border-radius: 12px;
  text-align: center;
  margin: 2em auto;
  max-width: 800px;
  box-shadow: var(--shadow);
}

.aviso-em-desenvolvimento h2 {
  margin: 0 0 15px 0;
  font-size: 1.8rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: #856404;
  border: none;
}

.citacao {
  margin: 2em 0;
  padding: 1.5em 2em;
  border-left: 4px solid var(--secondary-color);
  font-style: italic;
  color: var(--dark-text);
  background-color: #f8fafc;
  border-radius: 0 8px 8px 0;
  position: relative;
}

.citacao:before {
  content: '"';
  font-size: 4rem;
  color: var(--secondary-color);
  opacity: 0.2;
  position: absolute;
  top: 10px;
  left: 10px;
  line-height: 1;
}

.tags {
  margin: 1.5em 0;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: center;
}

.tag {
  background-color: #e0f0ff;
  color: var(--primary-color);
  padding: 8px 16px;
  border-radius: 50px;
  font-size: 0.9rem;
  box-shadow: var(--shadow);
  transition: var(--transition);
  font-weight: 600;
  border: 1px solid rgba(52, 152, 219, 0.3);
}

.tag:hover {
  background-color: var(--secondary-color);
  color: white;
  transform: translateY(-2px);
  box-shadow: var(--shadow-hover);
}

.indice {
  background-color: #f8fafc;
  border-radius: 12px;
  padding: 2em;
  margin: 2.5em 0;
  box-shadow: var(--shadow);
  border: 1px solid var(--border-color);
}

.indice h2 {
  border-bottom: 2px solid var(--secondary-color);
  padding-bottom: 0.5em;
  font-size: 1.8rem;
  margin-top: 0;
  text-align: center;
}

.indice ul {
  list-style-type: none;
  padding: 0;
  margin: 1.5em 0 0 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.indice li {
  margin: 0;
}

.indice a {
  display: flex;
  align-items: center;
  padding: 12px 20px;
  color: var(--primary-color);
  text-decoration: none;
  transition: var(--transition);
  border-radius: 8px;
  background-color: white;
  box-shadow: var(--shadow);
}

.indice a:before {
  content: "→";
  margin-right: 10px;
  color: var(--secondary-color);
  font-weight: bold;
}

.indice a:hover {
  background-color: var(--secondary-color);
  color: white;
  transform: translateX(10px);
}

.indice a:hover:before {
  color: white;
}

.indice ul ul {
  margin: 0.8em 0 0 2em;
}

.indice ul ul a {
  background-color: #f8fafc;
  font-size: 0.95em;
  padding: 10px 15px;
}

/* ====== CARROSSEL ====== */
.carrossel {
  position: relative;
  max-width: 100%;
  margin: 3em auto;
  overflow: hidden;
  border-radius: 12px;
  box-shadow: var(--shadow-hover);
}

.carrossel-container {
  display: flex;
  transition: transform 0.5s ease;
}

.carrossel-slide {
  min-width: 100%;
  box-sizing: border-box;
  padding: 20px;
}

.carrossel-nav {
  text-align: center;
  margin-top: 1.5em;
  display: flex;
  justify-content: center;
  gap: 15px;
}

.carrossel-btn {
  background: var(--primary-color);
  color: white;
  border: none;
  padding: 12px 24px;
  border-radius: 6px;
  cursor: pointer;
  transition: var(--transition);
  font-weight: 600;
  box-shadow: var(--shadow);
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.carrossel-btn:hover {
  background: #1a252f;
  transform: translateY(-2px);
  box-shadow: var(--shadow-hover);
}

.carrossel-indicadores {
  display: flex;
  justify-content: center;
  margin-top: 1.5em;
  gap: 12px;
}

.indicador {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: #ccc;
  cursor: pointer;
  transition: var(--transition);
  border: 2px solid transparent;
}

.indicador:hover {
  transform: scale(1.2);
}

.indicador.ativo {
  background: var(--primary-color);
  border-color: var(--secondary-color);
  transform: scale(1.2);
}

/* ====== REFERÊNCIAS BIBLIOGRÁFICAS ====== */
.referencias {
  list-style-type: none;
  padding: 0;
  margin: 2.5em 0;
  font-size: 0.95em;
}

.referencias li {
  margin-bottom: 1.2em;
  padding-left: 2em;
  text-indent: -2em;
  line-height: 1.7;
  position: relative;
}

.referencias li:before {
  content: "▹";
  color: var(--secondary-color);
  font-weight: bold;
  position: absolute;
  left: 0;
}

.referencias a {
  word-break: break-all;
  color: #4a5568;
  border-bottom: 1px dotted #cbd5e0;
}

.referencias a:hover {
  color: var(--secondary-color);
  border-bottom-color: var(--secondary-color);
}

/* ====== SEÇÕES ====== */
section {
  margin-bottom: 3em;
  position: relative;
}

section:target {
  animation: highlight 1.5s ease;
  padding-top: 20px;
  margin-top: -20px;
}

@keyframes highlight {
  from { background-color: rgba(52, 152, 219, 0.2); }
  to { background-color: transparent; }
}

/* ====== FOOTER ====== */
.footer {
  margin-top: 3em;
  padding-top: 2em;
  border-top: 1px solid var(--border-color);
  text-align: center;
  font-size: 0.9em;
  color: var(--light-text);
}

.license-link {
  font-weight: 600;
  color: var(--primary-color);
  border-bottom: 1px dotted var(--secondary-color);
}

.license-link:hover {
  color: var(--secondary-color);
  text-decoration: none;
}

/* ====== BOTÕES DE NAVEGAÇÃO ====== */
.post-navigation {
  display: flex;
  justify-content: space-between;
  margin: 3em 0;
}

.post-navigation a {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 24px;
  background-color: #f8fafc;
  color: var(--primary-color);
  border-radius: 6px;
  transition: var(--transition);
  font-weight: 600;
  box-shadow: var(--shadow);
}

.post-navigation a:hover {
  background-color: var(--secondary-color);
  color: white;
  text-decoration: none;
  transform: translateY(-2px);
  box-shadow: var(--shadow-hover);
}

/* ====== RESPONSIVIDADE ====== */
@media (max-width: 1024px) {
  .container {
    padding: 25px;
    margin: 20px;
  }

  h1 {
    font-size: 2.4rem;
  }

  h2 {
    font-size: 2rem;
  }

  h3 {
    font-size: 1.6rem;
  }
}

@media (max-width: 768px) {
  .container {
    padding: 20px;
    margin: 15px;
  }

  h1 {
    font-size: 2rem;
  }

  h2 {
    font-size: 1.8rem;
  }

  h3 {
    font-size: 1.4rem;
  }

  .post-meta {
    flex-direction: column;
    gap: 8px;
  }

  .indice {
    padding: 1.5em;
  }

  .tags {
    justify-content: flex-start;
  }

  .carrossel-nav {
    flex-direction: column;
    align-items: center;
  }

  .carrossel-btn {
    width: 100%;
    justify-content: center;
  }

  .post-navigation {
    flex-direction: column;
    gap: 15px;
  }

  .post-navigation a {
    width: 100%;
    justify-content: center;
  }
}

@media (max-width: 480px) {
  h1 {
    font-size: 1.4rem;
  }

  h2 {
    font-size: 1.3rem;
  }

  h3 {
    font-size: 1rem;
  }

  .indice a {
    padding: 10px 15px;
  }

  .referencias li {
    font-size: 0.9em;
    padding-left: 1.5em;
    text-indent: -1.5em;
  }
}

/* ====== ESTILOS PARA MAPAS ====== */
.map-container {
  height: 500px;
  margin: 2em 0;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: var(--shadow-hover);
}

/* ====== DESTAQUES ====== */
.highlight-box {
  background-color: #f0f7ff;
  border-left: 4px solid var(--secondary-color);
  padding: 1.5em;
  margin: 2em 0;
  border-radius: 0 8px 8px 0;
}

.highlight-box h3 {
  margin-top: 0;
  color: var(--primary-color);
}

/* ====== ÍCONES ====== */
.icon {
  width: 24px;
  height: 24px;
  vertical-align: middle;
  margin-right: 8px;
}

/* ====== TOOLTIPS ====== */
.tooltip {
  position: relative;
  display: inline-block;
  border-bottom: 1px dotted var(--secondary-color);
  cursor: help;
}

.tooltip .tooltiptext {
  visibility: hidden;
  width: 200px;
  background-color: var(--primary-color);
  color: #fff;
  text-align: center;
  border-radius: 6px;
  padding: 10px;
  position: absolute;
  z-index: 1;
  bottom: 125%;
  left: 50%;
  margin-left: -100px;
  opacity: 0;
  transition: opacity 0.3s;
  font-size: 0.9em;
}

.tooltip:hover .tooltiptext {
  visibility: visible;
  opacity: 1;
}

/* ====== BADGES ====== */
.badge {
  display: inline-block;
  padding: 3px 8px;
  font-size: 0.75em;
  font-weight: 600;
  line-height: 1;
  color: white;
  text-align: center;
  white-space: nowrap;
  vertical-align: baseline;
  border-radius: 50px;
  background-color: var(--secondary-color);
  margin-left: 8px;
}

/* ====== PROGRESS BAR ====== */
.progress-container {
  width: 100%;
  background-color: #e2e8f0;
  border-radius: 50px;
  margin: 1em 0;
}

.progress-bar {
  height: 10px;
  border-radius: 50px;
  background-color: var(--secondary-color);
  width: 0;
  transition: width 1s ease-in-out;
}

 /* Estilo da linha da avenida */
 .avenida-line {
  filter: drop-shadow(0 0 5px rgba(231, 76, 60, 0.7));
}

/* Estilo dos marcadores */
.marker-inicio {
  font-size: 24px;
  text-align: center;
  transform: translate(-15px, -30px);
}

.marker-fim {
  font-size: 24px;
  text-align: center;
  transform: translate(-15px, -30px);
}

/* Tooltip do mapa */
.leaflet-tooltip {
  background-color: rgba(231, 76, 60, 0.9);
  color: white;
  border: none;
  font-weight: bold;
  padding: 8px 12px;
  border-radius: 4px;
  box-shadow: 0 2px 10px rgba(0,0,0,0.2);
  font-size: 14px;
}

.leaflet-tooltip-top:before {
  border-top-color: rgba(231, 76, 60, 0.9);
}