/* ============================================================
   Pages stations SEO — fidèle à l'écran « Marée » de l'app
   (thème océan / glass). S'appuie sur les tokens de styles.css.
   ============================================================ */

.station-main { padding: var(--space-md) 0 var(--space-xxl); }
section[id], [id] { scroll-margin-top: 84px; }

/* Tableau de bord : grille intentionnelle (ordre de lecture préservé), 1 colonne
   sur mobile → 2 colonnes alignées sur grand écran. Remplace l'ancien
   `column-count: 3` (masonry) qui éparpillait les cartes par hauteur. */
.station-main > .container { max-width: 1100px; }
.st-dash { display: grid; grid-template-columns: 1fr; gap: var(--space-md); }
.st-dash > .glass-card { margin-bottom: 0; }
@media (min-width: 900px) {
  .st-dash { grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: start; }
  .st-dash .span-2 { grid-column: 1 / -1; }
  /* Toutes les sections sont visibles d'un coup → onglets inutiles. */
  .tide-tabs { display: none !important; }
}

/* Recherche dans le header */
.header-content { flex-wrap: wrap; gap: 12px; }
.header-search {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 1 1 200px;
  max-width: 340px;
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-pill);
  padding: 8px 16px;
}
.header-search-icon { opacity: 0.7; font-size: 14px; }
.header-search input {
  flex: 1;
  min-width: 0;
  background: none;
  border: none;
  color: var(--text);
  font-size: 14px;
  outline: none;
}
.header-search input::placeholder { color: var(--text-dim); }
@media (max-width: 760px) {
  .header-search { order: 5; flex-basis: 100%; max-width: none; }
}

.breadcrumb {
  display: flex; flex-wrap: wrap; align-items: center; gap: 8px;
  font-size: 13px; color: var(--text-dim); margin-bottom: var(--space-md);
}
.breadcrumb a { color: var(--text-muted); text-decoration: none; }
.breadcrumb a:hover { color: var(--cyan-300); }
.breadcrumb span[aria-current] { color: var(--text-muted); }

.glass-card {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-glass);
  padding: var(--space-lg);
  margin-bottom: var(--space-md);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
}
.card-title {
  display: flex; align-items: center; gap: 8px;
  font-size: 14px; text-transform: uppercase; letter-spacing: 0.08em;
  color: var(--text-dim); margin-bottom: var(--space-sm);
}
.card-title .ico { width: 16px; height: 16px; color: var(--cyan-300); }

/* === Hero station (nom + panneau marée en vedette) === */
.st-hero {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-glass);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  padding: var(--space-lg);
  margin-bottom: var(--space-md);
}
.st-hero-head h1 {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  font-size: clamp(26px, 4.5vw, 40px); font-weight: 800; letter-spacing: -0.02em;
}
.st-pin { width: 0.9em; height: 0.9em; color: var(--cyan-300); }
.station-country {
  font-size: 0.42em; font-weight: 600; vertical-align: middle; color: var(--text-muted);
  border: 1px solid var(--glass-border); border-radius: var(--radius-pill);
  padding: 3px 12px; letter-spacing: 0.02em;
}
.st-hero-meta { color: var(--text-muted); margin-top: 8px; font-size: 14px; }

.st-status { display: grid; grid-template-columns: 1fr; gap: var(--space-md); margin-top: var(--space-lg); }
@media (min-width: 620px) {
  .st-status { grid-template-columns: minmax(170px, 230px) 1fr; }
}
.st-status .tide-gauge {
  border: 1px solid var(--glass-border); border-radius: var(--radius-md); min-height: 188px;
}
.st-facts { display: grid; grid-template-columns: 1fr; gap: var(--space-sm); align-content: stretch; }
@media (min-width: 440px) { .st-facts { grid-template-columns: 1fr 1fr; } }
.st-fact {
  background: var(--glass-bg-strong); border: 1px solid var(--glass-border);
  border-radius: var(--radius-md); padding: var(--space-md);
  display: flex; flex-direction: column; justify-content: center; gap: 5px;
}
.st-fact-l { font-size: 12px; text-transform: uppercase; letter-spacing: 0.06em; color: var(--text-dim); }
.st-fact-v { font-size: 32px; font-weight: 800; line-height: 1; color: var(--cyan-300); font-variant-numeric: tabular-nums; }
.st-fact-s { font-size: 13px; color: var(--text-muted); }
.st-fact-s.int-strong, .st-fact-s.int-verystrong, .st-fact-s.int-exceptional { color: var(--tide-low); font-weight: 600; }

/* Bandeau astro */
.astro-strip {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: 8px;
  background: var(--glass-bg); border: 1px solid var(--glass-border);
  border-radius: var(--radius-lg); padding: 18px 16px; margin-bottom: var(--space-md);
}
.astro-item { text-align: center; display: flex; flex-direction: column; gap: 5px; align-items: center; justify-content: flex-start; }
.astro-ico { width: 26px; height: 26px; color: var(--cyan-300); }
.astro-emoji { font-size: 24px; line-height: 1; }
.astro-label { font-size: 11px; color: var(--text-dim); text-transform: uppercase; letter-spacing: 0.04em; }
.astro-sub { font-size: 15px; font-weight: 600; color: var(--text); font-variant-numeric: tabular-nums; }
.astro-sub.int-strong, .astro-sub.int-verystrong, .astro-sub.int-exceptional { color: var(--tide-low); }

/* Onglets Marée / Météo / Mer / Plage */
.tide-tabs {
  display: flex; gap: 6px; padding: 5px; overflow-x: auto;
  background: var(--glass-bg); border: 1px solid var(--glass-border);
  border-radius: var(--radius-md); margin-bottom: var(--space-md);
}
.tide-tabs .tab {
  flex: 1; text-align: center; padding: 10px 14px; border-radius: 10px;
  color: var(--text-muted); text-decoration: none; font-weight: 600;
  font-size: 14px; white-space: nowrap;
}
.tide-tabs .tab.active { background: var(--cyan-400); color: #06222f; }

/* Jauge de marée « liquide » */
.tide-gauge {
  position: relative; overflow: hidden; min-height: 196px; padding: 0;
  display: flex; align-items: center; justify-content: center;
  background: var(--ocean-700);
}
.tide-gauge-fill {
  position: absolute; left: 0; right: 0; bottom: 0;
  background: linear-gradient(180deg, rgba(0, 180, 216, 0.55), rgba(27, 123, 184, 0.7));
  transition: height 0.6s ease;
}
.tide-gauge-fill::before {
  content: ""; position: absolute; top: -13px; left: 0;
  width: 200%; height: 16px; background-repeat: repeat-x; background-size: 50% 100%;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='100' height='16' viewBox='0 0 100 16'%3E%3Cpath d='M0 8 Q25 0 50 8 T100 8 V16 H0 Z' fill='%2300B4D8' fill-opacity='0.55'/%3E%3C/svg%3E");
  animation: tide-wave 6s linear infinite;
}
@keyframes tide-wave { to { transform: translateX(-50%); } }
.tide-gauge-inner { position: relative; z-index: 1; text-align: center; padding: var(--space-md); }
.gauge-pct { font-size: 46px; font-weight: 800; line-height: 1; color: #fff; text-shadow: 0 2px 12px rgba(0,0,0,0.35); }
.gauge-dir {
  display: inline-block; margin-top: 12px; padding: 6px 16px;
  border-radius: var(--radius-pill); background: rgba(10, 22, 40, 0.5);
  border: 1px solid var(--glass-border); font-size: 13px; color: #fff;
}
@media (prefers-reduced-motion: reduce) { .tide-gauge-fill::before { animation: none; } }

/* Courbe + météo */
.curve-head { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 8px; }
.curve-wx { display: flex; gap: 14px; font-size: 14px; color: var(--text-muted); }
.tide-curve-wrap { width: 100%; margin-top: var(--space-sm); }
.tide-curve { width: 100%; height: auto; display: block; }
.tide-line { stroke: var(--cyan-300); stroke-width: 3; stroke-linejoin: round; stroke-linecap: round; }
.tide-dot-high { fill: var(--tide-high); }
.tide-dot-low { fill: var(--tide-low); }
.tide-now-line { stroke: #fff; stroke-opacity: 0.4; stroke-width: 2; stroke-dasharray: 4 4; }
.tide-axis-label { fill: var(--text-dim); font-size: 13px; text-anchor: middle; font-family: var(--font); }
.tide-legend { display: flex; gap: var(--space-md); margin-top: var(--space-sm); font-size: 13px; color: var(--text-muted); }
.tide-legend i { display: inline-block; width: 10px; height: 10px; border-radius: 50%; margin-right: 6px; vertical-align: middle; }
.dot-high { background: var(--tide-high); }
.dot-low { background: var(--tide-low); }

/* Liste des marées */
.tide-list { list-style: none; }
.tide-row { display: grid; grid-template-columns: 28px 1fr auto auto; align-items: center; gap: 12px; padding: 12px 4px; border-bottom: 1px solid var(--glass-border); }
.tide-list.compact .tide-row { padding: 8px 4px; }
.tide-row:last-child { border-bottom: none; }
.tide-arrow { font-size: 18px; text-align: center; }
.tide-arrow.up { color: var(--tide-high); }
.tide-arrow.down { color: var(--tide-low); }
.tide-type { color: var(--text); }
.tide-time { color: var(--cyan-300); font-variant-numeric: tabular-nums; font-weight: 600; }
.tide-height { color: var(--text-muted); font-variant-numeric: tabular-nums; min-width: 64px; text-align: right; }

/* Prévision multi-jours */
.forecast-grid { display: grid; grid-template-columns: 1fr; gap: var(--space-md); }
.forecast-date { font-weight: 600; margin-bottom: 6px; color: var(--text); }
@media (min-width: 760px) { .forecast-grid { grid-template-columns: 1fr 1fr; gap: var(--space-md) var(--space-lg); } }

/* Grilles de stats (météo / mer / plage) */
.stat-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.stat { background: var(--glass-bg-strong); border: 1px solid var(--glass-border); border-radius: var(--radius-md); padding: 14px; text-align: center; display: flex; flex-direction: column; gap: 4px; }
.stat-v { font-size: 22px; font-weight: 700; color: var(--cyan-300); }
.stat-l { font-size: 12px; color: var(--text-muted); }
@media (max-width: 520px) { .stat-grid { grid-template-columns: repeat(2, 1fr); } }

.station-cta { text-align: center; }
.station-cta p { color: var(--text-muted); margin-bottom: var(--space-md); max-width: 540px; margin-left: auto; margin-right: auto; }
.station-cta .hero-buttons { justify-content: center; }

/* Page recherche */
.search-box { display: flex; gap: var(--space-sm); flex-wrap: wrap; margin: var(--space-md) 0; }
.search-box input[type="search"] { flex: 1 1 280px; padding: 14px 18px; border-radius: var(--radius-md); border: 1px solid var(--glass-border); background: var(--glass-bg); color: var(--text); font-size: 16px; }
.search-box input[type="search"]::placeholder { color: var(--text-dim); }
.search-results { list-style: none; margin-top: var(--space-md); }
.search-results li { border-bottom: 1px solid var(--glass-border); }
.search-results a { display: flex; justify-content: space-between; align-items: center; padding: 16px 8px; text-decoration: none; color: var(--text); }
.search-results a:hover { color: var(--cyan-300); }
.search-results .res-country { color: var(--text-dim); font-size: 13px; }

/* Stations à proximité (maillage interne) */
.nearby-list { list-style: none; display: grid; grid-template-columns: 1fr 1fr; gap: 0 var(--space-lg); }
.nearby-list a { display: flex; justify-content: space-between; gap: 10px; padding: 9px 4px; text-decoration: none; color: var(--text); border-bottom: 1px solid var(--glass-border); }
.nearby-list a:hover { color: var(--cyan-300); }
.nearby-list .res-country { color: var(--text-dim); font-size: 13px; }
@media (max-width: 560px) { .nearby-list { grid-template-columns: 1fr; } }

/* Index : grille de stations (parcourir) */
.station-tiles { list-style: none; display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 10px; margin-top: var(--space-md); }
.station-tiles a { display: flex; justify-content: space-between; gap: 8px; padding: 12px 14px; text-decoration: none; color: var(--text); background: var(--glass-bg); border: 1px solid var(--glass-border); border-radius: var(--radius-md); }
.station-tiles a:hover { color: var(--cyan-300); border-color: var(--glass-border-strong); }
.station-tiles .res-country { color: var(--text-dim); font-size: 13px; }

/* Intro unique + FAQ (contenu SEO) */
.station-intro { color: var(--text-muted); font-size: 17px; line-height: 1.6; max-width: 760px; margin: 0 auto var(--space-md); text-align: center; }
.faq-item { border-bottom: 1px solid var(--glass-border); }
.faq-item:last-child { border-bottom: none; }
.faq-item summary { cursor: pointer; padding: 14px 4px; font-weight: 600; color: var(--text); list-style: none; display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after { content: '+'; color: var(--cyan-300); font-size: 20px; line-height: 1; }
.faq-item[open] summary::after { content: '\2212'; }
.faq-item p { color: var(--text-muted); padding: 0 4px 14px; }

/* « Stations près de moi » */
.near-me-wrap { margin: var(--space-md) 0; }
.near-me-wrap #nearMeResults { margin-top: var(--space-md); }

/* === Polish recherche / index (titres + réactivité) === */
.glass-card > h1 { font-size: clamp(26px, 4vw, 36px); font-weight: 800; letter-spacing: -0.02em; margin-bottom: 6px; }
.station-sub { color: var(--text-muted); font-size: 16px; margin-bottom: var(--space-sm); max-width: 640px; }

/* Champ de recherche : anneau de focus cyan. */
.search-box input[type="search"] { transition: border-color 0.2s ease, box-shadow 0.2s ease; }
.search-box input[type="search"]:focus {
  outline: none;
  border-color: var(--cyan-400);
  box-shadow: 0 0 0 3px rgba(0, 180, 216, 0.25);
}

/* Réactivité des listes/tuiles (cohérent avec le hover des cartes vitrine). */
.station-tiles a, .nearby-list a, .search-results a {
  transition: color 0.2s ease, background 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}
.station-tiles a:hover { transform: translateY(-2px); box-shadow: var(--shadow-glass); }
.search-results a:hover { background: var(--glass-bg); border-radius: var(--radius-sm); padding-left: 14px; }
.nearby-list a:hover { padding-left: 8px; }
