/* =============================================================================
   PAGE « PLAN DU SITE / SITEMAP »
   Palette Franco-Américaine · Icônes · Animations · Responsive
   ============================================================================= */

.sitemap-page {
  position: relative;
}

.sitemap-page::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 320px;
  background: linear-gradient(
    135deg,
    rgba(0, 35, 149, 0.14) 0%,
    rgba(255, 255, 255, 0.03) 48%,
    rgba(178, 34, 52, 0.12) 100%
  );
  pointer-events: none;
  z-index: 0;
}

.sitemap-page > * {
  position: relative;
  z-index: 1;
}

/* Hero sans image — bandeau décoratif tricolore */
.sitemap-hero {
  padding: 2.5rem 1.25rem 2rem;
  margin-bottom: 0.5rem;
}

.sitemap-hero-inner {
  max-width: var(--max-width, 1100px);
  margin: 0 auto;
  text-align: center;
  animation: sitemapHeroIn 0.9s ease-out both;
}

@keyframes sitemapHeroIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.sitemap-hero-banner {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1.25rem;
  padding: 1.5rem 1rem;
  border-radius: var(--radius-md);
  background: linear-gradient(160deg, #0a2463 0%, #1a3a6e 45%, #2d1b3d 100%);
  border: 1px solid var(--border-soft);
  position: relative;
  overflow: hidden;
}

.sitemap-hero-banner::before {
  content: "";
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(
    -45deg,
    transparent,
    transparent 8px,
    rgba(255, 255, 255, 0.03) 8px,
    rgba(255, 255, 255, 0.03) 16px
  );
  pointer-events: none;
}

.sitemap-hero-icon {
  font-size: 3.5rem;
  line-height: 1;
  filter: drop-shadow(0 4px 12px rgba(0, 0, 0, 0.35));
  animation: sitemapIconFloat 3s ease-in-out infinite;
}

.sitemap-hero-icon:nth-child(2) {
  animation-delay: 0.5s;
}

@keyframes sitemapIconFloat {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-6px);
  }
}

.sitemap-kicker {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.4rem;
  margin-bottom: 0.75rem;
}

.sitemap-kicker span {
  display: inline-block;
  padding: 0.28rem 0.65rem;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  animation: sitemapBadgeIn 0.65s ease-out both;
}

.sitemap-kicker span:nth-child(1) {
  background: rgba(0, 35, 149, 0.25);
  color: #93c5fd;
  border: 1px solid rgba(0, 85, 164, 0.45);
  animation-delay: 0.05s;
}

.sitemap-kicker span:nth-child(2) {
  background: rgba(178, 34, 52, 0.2);
  color: #fecaca;
  border: 1px solid rgba(178, 34, 52, 0.4);
  animation-delay: 0.15s;
}

.sitemap-kicker span:nth-child(3) {
  background: rgba(244, 213, 138, 0.15);
  color: var(--gold);
  border: 1px solid rgba(244, 213, 138, 0.35);
  animation-delay: 0.25s;
}

@keyframes sitemapBadgeIn {
  from {
    opacity: 0;
    transform: scale(0.9);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

.sitemap-hero h1 {
  font-family: var(--font-title);
  font-size: clamp(1.55rem, 4vw, 2.35rem);
  margin: 0 0 0.75rem;
  color: var(--text-100);
  line-height: 1.22;
}

.sitemap-hero .lead {
  max-width: 720px;
  margin: 0 auto 1rem;
  color: var(--text-300);
  line-height: 1.75;
  font-size: 1.02rem;
}

.sitemap-stats {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.65rem;
  margin-top: 1rem;
}

.sitemap-stat {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.4rem 0.85rem;
  border-radius: 999px;
  font-size: 0.84rem;
  font-weight: 600;
  border: 1px solid var(--border-soft);
  background: rgba(255, 255, 255, 0.04);
  color: var(--text-200);
}

/* Barre de recherche */
.sitemap-search-wrap {
  max-width: 560px;
  margin: 1.5rem auto 0;
  position: relative;
}

.sitemap-search {
  width: 100%;
  padding: 0.85rem 1rem 0.85rem 2.75rem;
  border-radius: var(--radius-md);
  border: 1px solid rgba(44, 95, 78, 0.25);
  background: linear-gradient(145deg, #fdfbf8 0%, #ffffff 100%);
  color: #14110e;
  font-size: 1rem;
  transition: border-color 0.25s ease, box-shadow 0.25s ease;
}

.sitemap-search::placeholder {
  color: #6b6560;
}

.sitemap-search:focus {
  outline: none;
  border-color: #2c5f4e;
  box-shadow: 0 0 0 3px rgba(44, 95, 78, 0.18);
}

.sitemap-search-icon {
  position: absolute;
  left: 1rem;
  top: 50%;
  transform: translateY(-50%);
  font-size: 1.1rem;
  pointer-events: none;
  opacity: 0.7;
}

.sitemap-no-results {
  display: none;
  text-align: center;
  padding: 2rem;
  color: var(--text-400);
  font-size: 0.95rem;
}

.sitemap-no-results.visible {
  display: block;
}

/* Sections — surface claire (harmonisée realestate-guide.css) */
.sitemap-section {
  scroll-margin-top: 92px;
  background: linear-gradient(145deg, #fdfbf8 0%, #ffffff 100%);
  border: 1px solid rgba(44, 95, 78, 0.2);
  border-radius: var(--radius-md);
  padding: 1.35rem 1.4rem;
  margin-bottom: 1.25rem;
  position: relative;
  overflow: hidden;
  color: #3d3834;
}

.sitemap-section::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 4px;
  height: 100%;
  background: linear-gradient(180deg, #002395 0%, #ffffff 50%, #ed2939 100%);
  opacity: 0.6;
  border-radius: 4px 0 0 4px;
}

.sitemap-section-head {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid rgba(44, 95, 78, 0.15);
}

.sitemap-section-icon {
  flex-shrink: 0;
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.45rem;
  border-radius: 12px;
  background: linear-gradient(135deg, rgba(44, 95, 78, 0.12), rgba(26, 61, 50, 0.08));
  border: 1px solid rgba(44, 95, 78, 0.2);
}

.sitemap-section h2 {
  margin: 0;
  font-family: var(--font-title);
  font-size: clamp(1.15rem, 2.5vw, 1.45rem);
  color: #2c5f4e;
}

.sitemap-section-count {
  margin-left: auto;
  font-size: 0.78rem;
  font-weight: 700;
  padding: 0.25rem 0.6rem;
  border-radius: 999px;
  background: rgba(44, 95, 78, 0.1);
  color: #2c5f4e;
  border: 1px solid rgba(44, 95, 78, 0.2);
}

.sitemap-grid {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.65rem;
}

.sitemap-item {
  margin: 0;
}

.sitemap-item a {
  display: flex;
  align-items: flex-start;
  gap: 0.65rem;
  padding: 0.75rem 0.85rem;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(44, 95, 78, 0.15);
  text-decoration: none;
  color: #3d3834;
  background: #ffffff;
  transition: transform 0.25s ease, border-color 0.25s ease, background 0.25s ease, box-shadow 0.25s ease;
  height: 100%;
}

.sitemap-item a:hover,
.sitemap-item a:focus-visible {
  transform: translateX(4px);
  border-color: rgba(184, 112, 58, 0.45);
  background: linear-gradient(145deg, #fff9f3 0%, #ffffff 100%);
  box-shadow: 0 6px 20px rgba(25, 35, 30, 0.1);
  color: #14110e;
}

.sitemap-item.hidden {
  display: none;
}

.sitemap-icon {
  flex-shrink: 0;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  border-radius: 10px;
  background: linear-gradient(135deg, #2c5f4e, #1a3d32);
  border: 1px solid rgba(26, 61, 50, 0.35);
}

.sitemap-text {
  flex: 1;
  min-width: 0;
}

.sitemap-label {
  display: block;
  font-weight: 700;
  font-size: 0.94rem;
  color: #14110e;
  margin-bottom: 0.15rem;
}

.sitemap-desc {
  display: block;
  font-size: 0.8rem;
  line-height: 1.45;
  color: #3d3834;
}

.sitemap-item a:hover .sitemap-label,
.sitemap-item a:focus-visible .sitemap-label {
  color: #1d4ed8;
}

.sitemap-xml-card {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem;
  padding: 1.15rem 1.25rem;
  border-radius: var(--radius-md);
  border: 1px solid rgba(44, 95, 78, 0.2);
  border-left: 4px solid #2c5f4e;
  background: linear-gradient(135deg, #eff6ff 0%, #f0f7ff 100%);
  margin-bottom: 1.25rem;
  color: #3d3834;
}

.sitemap-xml-card .sitemap-icon {
  width: 48px;
  height: 48px;
  font-size: 1.5rem;
}

.sitemap-xml-card p {
  flex: 1;
  min-width: 200px;
  margin: 0;
  font-size: 0.92rem;
  line-height: 1.65;
  color: #3d3834;
}

.sitemap-xml-card strong {
  color: #14110e;
}

.sitemap-xml-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.65rem 1.1rem;
  border-radius: var(--radius-sm);
  font-weight: 700;
  font-size: 0.9rem;
  text-decoration: none;
  color: #f1f5f9;
  background: linear-gradient(135deg, #2c5f4e, #1a3d32);
  border: 1px solid rgba(255, 255, 255, 0.14);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
  white-space: nowrap;
}

.sitemap-xml-btn:hover,
.sitemap-xml-btn:focus-visible {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(26, 61, 50, 0.35);
  color: #f4d58a;
}

@media (max-width: 900px) {
  .sitemap-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 600px) {
  .sitemap-hero {
    padding: 1.75rem 1rem 1.25rem;
  }

  .sitemap-hero-banner {
    padding: 1.15rem 0.75rem;
  }

  .sitemap-hero-icon {
    font-size: 2.5rem;
  }

  .sitemap-section {
    padding: 1rem;
  }

  .sitemap-section-head {
    flex-wrap: wrap;
  }

  .sitemap-section-count {
    margin-left: 0;
  }

  .sitemap-xml-card {
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (prefers-reduced-motion: reduce) {
  .sitemap-hero-inner,
  .sitemap-kicker span,
  .sitemap-hero-icon {
    animation: none;
  }

  .sitemap-item a:hover {
    transform: none;
  }
}
