/* Styles de family.kaldo.ch (même structure que les autres sites kaldo.ch, palette rose pastel). */
@font-face { font-family: "Bebas Neue"; src: url("/fonts/bebas-neue-latin-400-normal.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Source Sans 3"; src: url("/fonts/source-sans-3-latin-400-normal.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Source Sans 3"; src: url("/fonts/source-sans-3-latin-600-normal.woff2") format("woff2"); font-weight: 600; font-display: swap; }
@font-face { font-family: "Source Sans 3"; src: url("/fonts/source-sans-3-latin-700-normal.woff2") format("woff2"); font-weight: 700; font-display: swap; }

:root {
  color-scheme: light;
  --bg: #fdf5f8;
  --card: #ffffff;
  --text: #2a1822;
  --muted: #6a5160;          /* 6,9:1 sur blanc */
  --grid: #f5e4ec;
  --line: #ecc9d8;
  --accent: #b02e6a;         /* rose framboise, 5,8:1 sur blanc */
  --accent-soft: rgba(176, 46, 106, .1);
  --on-accent: #ffffff;
  --focus: #b02e6a;
  --museum: #5a4aa8;   --museum-bg: #ece8fb;   /* musée : lavande */
  --walk: #26698f;     --walk-bg: #e0f0f8;     /* balade : bleu ciel */
  --fun: #a8481c;      --fun-bg: #fde6da;      /* loisir : pêche */
  --craft: #a3307a;    --craft-bg: #fbe3f1;    /* atelier : rose */
  --free: #7a5200;     --free-bg: #fdf0cf;
  --warn: #7a4a00;     --warn-bg: #fff2d6;
  --error: #b3261e;
  --hero-bg: #3b1630;
  --hero-text: #ffffff;
  --hero-muted: #e8c6d7;
  --hero-accent: #f7b6d0;    /* rose pastel */
  --gold: #f7b6d0;
  --font-display: "Bebas Neue", Impact, "Arial Narrow", sans-serif;
  --font-body: "Source Sans 3", system-ui, sans-serif;
  --radius: 18px;
  --shadow: 0 1px 2px rgba(59, 22, 48, .06), 0 4px 16px rgba(59, 22, 48, .07);
  --ease: 180ms ease-out;
}
/* Thème sombre : activé par le bouton de l'en-tête (le thème clair est celui par défaut) */
:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #170d13;
  --card: #24151e;
  --text: #f6e9ef;
  --muted: #c8adbb;
  --grid: #33202b;
  --line: #4d3240;
  --accent: #f4a3c6;
  --accent-soft: rgba(244, 163, 198, .14);
  --on-accent: #170d13;
  --focus: #f4a3c6;
  --museum: #bdb2f5;   --museum-bg: rgba(189, 178, 245, .14);
  --walk: #8fcbea;     --walk-bg: rgba(143, 203, 234, .14);
  --fun: #ffb592;      --fun-bg: rgba(255, 181, 146, .14);
  --craft: #f4a3d6;    --craft-bg: rgba(244, 163, 214, .14);
  --free: #f0c36a;     --free-bg: rgba(240, 195, 106, .14);
  --warn: #f5c98a;     --warn-bg: rgba(245, 201, 138, .12);
  --error: #ff9b94;
  --hero-bg: #1f0b19;
  --shadow: none;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; background: var(--bg); color: var(--text); font: 17px/1.55 var(--font-body); -webkit-font-smoothing: antialiased; }
h1, h2, h3, .display { font-family: var(--font-display); font-weight: 400; letter-spacing: .02em; line-height: 1; }
a { color: var(--accent); text-underline-offset: 3px; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; border-radius: 4px; }
img { max-width: 100%; height: auto; }
.wrap { max-width: 1200px; margin: 0 auto; padding: 0 16px; }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- En-tête ---------- */
.hero {
  background:
    radial-gradient(520px 300px at 90% 0%, rgba(247, 182, 208, .28), transparent 65%),
    radial-gradient(700px 380px at 5% 110%, rgba(189, 178, 245, .22), transparent 70%),
    var(--hero-bg);
  color: var(--hero-text);
  position: relative;
  padding: 20px 0 72px;
}
/* Vague en bas de l'en-tête : signature commune aux sites kaldo.ch, crête rose pastel */
.wave { position: absolute; left: 0; right: 0; bottom: -1px; width: 100%; height: 48px; display: block; }
.wave .water { fill: var(--bg); }
.wave .crest { fill: none; stroke: var(--hero-accent); stroke-width: 3; vector-effect: non-scaling-stroke; }
.skip { position: absolute; left: 16px; top: -60px; z-index: 1000; padding: 10px 16px; border-radius: 10px; background: var(--hero-text); color: var(--hero-bg); font-weight: 700; }
.skip:focus { top: 12px; }

.topbar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 16px; margin-bottom: 26px; }
.topbar-left { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 20px; }
.brand-link { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 12px; min-height: 44px; color: var(--hero-text); text-decoration: none; }
.brand-title { font-family: var(--font-display); font-size: clamp(30px, 5vw, 42px); line-height: 1; letter-spacing: .02em; }
.brand-sub { color: var(--hero-muted); font-size: 15px; }
.tabs { display: inline-flex; flex-wrap: wrap; gap: 2px; padding: 3px; border-radius: 999px; background: rgba(255, 255, 255, .08); border: 1px solid rgba(255, 255, 255, .14); }
.tabs a {
  display: inline-flex; align-items: center; min-height: 44px; padding: 0 14px; border-radius: 999px;
  color: var(--hero-text); text-decoration: none; font-weight: 700; font-size: 15px; transition: background-color var(--ease), color var(--ease);
}
.tabs a:hover { background: rgba(255, 255, 255, .12); }
.tabs a[aria-current="page"] { background: var(--hero-accent); color: var(--hero-bg); }
.actions { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.credit {
  display: inline-flex; align-items: center; gap: 6px; min-height: 44px; padding: 0 16px;
  border: 1.5px solid var(--hero-accent); border-radius: 999px;
  color: var(--hero-text); text-decoration: none; font-size: 15px;
  transition: background-color var(--ease), color var(--ease);
}
.credit strong { color: var(--hero-accent); transition: color var(--ease); }
.credit:hover, .credit:focus-visible { background: var(--hero-accent); color: var(--hero-bg); }
.credit:hover strong, .credit:focus-visible strong { color: var(--hero-bg); }
.theme-toggle {
  display: inline-grid; place-items: center; width: 44px; height: 44px; padding: 0;
  border: 1.5px solid rgba(255, 255, 255, .35); border-radius: 999px;
  background: transparent; color: var(--hero-text); cursor: pointer;
  transition: background-color var(--ease), border-color var(--ease);
}
.theme-toggle:hover { background: rgba(255, 255, 255, .12); border-color: var(--hero-text); }
.theme-toggle .icon-sun, :root[data-theme="dark"] .theme-toggle .icon-moon { display: none; }
:root[data-theme="dark"] .theme-toggle .icon-sun { display: block; }

.eyebrow { margin: 0 0 8px; font-size: 13px; font-weight: 700; text-transform: uppercase; letter-spacing: .12em; color: var(--hero-accent); }
.page-title { margin: 0; font-size: clamp(44px, 8vw, 76px); line-height: .95; }
.page-title.long { font-size: clamp(38px, 6vw, 62px); }
.page-text { margin: 12px 0 0; font-size: clamp(18px, 2.4vw, 21px); max-width: 60ch; }
.hero-count { display: inline-block; margin: 14px 0 0; padding: 6px 14px; border-radius: 999px; background: rgba(255, 255, 255, .1); font-weight: 600; }
.hero-grid { display: grid; gap: 24px 48px; align-items: end; }
@media (min-width: 900px) { .hero-grid { grid-template-columns: minmax(0, 1.3fr) minmax(320px, 1fr); } }
.breadcrumb ol { display: flex; flex-wrap: wrap; margin: 0 0 14px; padding: 0; list-style: none; font-size: 14px; color: var(--hero-muted); }
.breadcrumb li + li::before { content: "›"; margin: 0 8px; }
.breadcrumb a { color: var(--hero-text); }

/* Météo du jour, dans l'en-tête */
.today {
  display: flex; flex-wrap: wrap; gap: 12px 14px; align-items: center; min-height: 108px; padding: 16px 18px;
  border-radius: 16px; background: rgba(255, 255, 255, .08); border: 1px solid rgba(255, 255, 255, .14);
}
.today .icon { flex: none; width: 42px; height: 42px; color: var(--hero-accent); }
.today p { margin: 0; flex: 1 1 200px; color: var(--hero-muted); }
.today strong { display: block; color: var(--hero-text); font-size: 18px; }
.today .kind { display: block; color: var(--gold); font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .1em; }
.today button {
  min-height: 44px; padding: 0 16px; border: 0; border-radius: 999px; background: var(--hero-accent); color: var(--hero-bg);
  font: 700 15px var(--font-body); cursor: pointer; transition: filter var(--ease);
}
.today button:hover { filter: brightness(1.08); }
.skeleton { display: block; height: 1em; border-radius: 6px; background: rgba(255, 255, 255, .12); animation: pulse 1.4s ease-in-out infinite; }
@keyframes pulse { 50% { opacity: .5; } }

/* ---------- Contenu ---------- */
main { padding: 20px 0 48px; }
section.block { margin-bottom: 36px; }
section.block > h2 { margin: 0 0 6px; font-size: 32px; }
.hint { margin: 0 0 14px; color: var(--muted); font-size: 15px; max-width: 75ch; }
.button {
  display: inline-flex; align-items: center; justify-content: center; min-height: 44px; padding: 0 20px; border-radius: 999px;
  border: 2px solid var(--accent); background: var(--accent); color: var(--on-accent); font: 700 16px var(--font-body);
  text-decoration: none; cursor: pointer; transition: filter var(--ease), background-color var(--ease);
}
.button:hover { filter: brightness(1.1); }
.button.ghost { background: transparent; color: var(--accent); }
.button.ghost:hover { background: var(--accent-soft); filter: none; }
.button:disabled { opacity: .5; cursor: progress; }
.button-row { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 16px; }

/* Filtres */
.filters { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 14px 18px; margin-bottom: 14px; }
.filter { display: flex; flex-direction: column; gap: 4px; margin: 0; padding: 0; border: 0; min-width: 0; }
.filter > label, .filter > legend { padding: 0; font-size: 13px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); }
.filter select {
  min-height: 44px; padding: 0 36px 0 14px; border: 1.5px solid var(--line); border-radius: 999px; background-color: var(--card); color: var(--text);
  font: 600 15px var(--font-body); cursor: pointer; appearance: none;
  background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%), linear-gradient(135deg, var(--muted) 50%, transparent 50%);
  background-position: calc(100% - 18px) 19px, calc(100% - 13px) 19px; background-size: 5px 5px; background-repeat: no-repeat;
  transition: border-color var(--ease);
}
.filter select:hover { border-color: var(--accent); }
.chips { display: flex; flex-wrap: wrap; gap: 8px; padding: 0; margin: 0; list-style: none; }
.chip { position: relative; }
.chip input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.chip span {
  display: inline-flex; align-items: center; min-height: 44px; padding: 0 14px; border: 1.5px solid var(--line); border-radius: 999px;
  background: var(--card); color: var(--text); font: 600 15px var(--font-body); cursor: pointer;
  transition: background-color var(--ease), border-color var(--ease), color var(--ease);
}
.chip:hover span { border-color: var(--accent); }
.chip input:checked + span { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }
.chip input:focus-visible + span { outline: 3px solid var(--focus); outline-offset: 2px; }
.result-line { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; margin: 0 0 14px; color: var(--muted); font-weight: 600; }
.link-button { background: none; border: 0; color: var(--accent); font: 700 15px var(--font-body); text-decoration: underline; cursor: pointer; min-height: 44px; padding: 0 4px; }
.empty { margin: 0; padding: 22px; text-align: center; color: var(--muted); border: 1.5px dashed var(--line); border-radius: var(--radius); font-weight: 600; list-style: none; }

/* Cartes d'activités */
.place-grid { display: grid; gap: 14px; grid-template-columns: repeat(auto-fill, minmax(min(100%, 320px), 1fr)); padding: 0; margin: 0; list-style: none; }
.place {
  position: relative; display: flex; flex-direction: column; gap: 6px; padding: 16px 18px 18px;
  border-radius: var(--radius); background: var(--card); box-shadow: var(--shadow); border-top: 5px solid var(--line);
  transition: box-shadow var(--ease), transform var(--ease);
}
/* Photo en tête de carte, collée aux bords ; le bandeau de couleur reste au-dessus.
   overflow: hidden sur la carte : la photo suit ses coins arrondis au lieu de dépasser */
.place:has(.photo) { overflow: hidden; }
.place .photo { display: block; width: calc(100% + 36px); max-width: none; height: auto; aspect-ratio: 16 / 10; object-fit: cover; margin: -16px -18px 8px; background: var(--grid); }
.credit-photo { position: relative; z-index: 1; margin: 2px 0 0; color: var(--muted); font-size: 12px; }
.credit-photo a { color: inherit; }
.place.kind-musee { border-top-color: var(--museum); }
.place.kind-balade { border-top-color: var(--walk); }
.place.kind-loisir { border-top-color: var(--fun); }
.place.kind-atelier { border-top-color: var(--craft); }
.place .kind { display: flex; align-items: center; gap: 6px; margin: 0; font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .1em; color: var(--muted); }
.place .kind svg { width: 18px; height: 18px; }
.kind-musee .kind { color: var(--museum); }
.kind-balade .kind { color: var(--walk); }
.kind-loisir .kind { color: var(--fun); }
.kind-atelier .kind { color: var(--craft); }
.place h3 { margin: 0; font-size: 26px; }
.place h3 a { color: inherit; text-decoration: none; }
/* Toute la carte mène au site officiel (lien étendu) */
.place h3 a::after { content: ""; position: absolute; inset: 0; border-radius: var(--radius); }
.place:hover { box-shadow: 0 2px 4px rgba(59, 22, 48, .08), 0 10px 28px rgba(59, 22, 48, .12); transform: translateY(-2px); }
.place:hover h3 a { color: var(--accent); text-decoration: underline; }
.place:has(h3 a:focus-visible) { outline: 3px solid var(--focus); outline-offset: 2px; }
.place h3 a:focus-visible { outline: none; }
.where { margin: 0; color: var(--muted); font-size: 15px; }
.summary { margin: 4px 0 6px; font-size: 16px; }
.warn { margin: 0 0 6px; padding: 8px 12px; border-radius: 12px; background: var(--warn-bg); color: var(--warn); font-size: 14px; font-weight: 600; }
.tags { display: flex; flex-wrap: wrap; gap: 6px; margin: auto 0 0; padding: 6px 0 0; list-style: none; }
.tag { padding: 2px 10px; border-radius: 999px; background: var(--grid); color: var(--muted); font-size: 13px; font-weight: 700; }
.tag.in { background: var(--museum-bg); color: var(--museum); }
.tag.out { background: var(--walk-bg); color: var(--walk); }
.tag.free { background: var(--free-bg); color: var(--free); }
.checked { margin: 6px 0 0; color: var(--muted); font-size: 14px; }

/* Agenda */
.events { display: grid; gap: 14px; padding: 0; margin: 0; list-style: none; }
.event { display: grid; grid-template-columns: 80px 1fr; gap: 16px; padding: 16px 18px; border-radius: var(--radius); background: var(--card); box-shadow: var(--shadow); border-left: 5px solid var(--gold); }
.event .date { margin: 0; text-align: center; padding: 8px 4px; border-radius: 12px; background: var(--accent-soft); color: var(--accent); }
.event .date .day { display: block; font: 400 38px/1 var(--font-display); }
.event .date .month { font-size: 13px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; }
.event h3 { margin: 0 0 4px; font-size: 26px; }
.event h3 a { color: inherit; }
.event p { margin: 0 0 6px; }
.event .meta { color: var(--muted); font-size: 15px; }

/* Régions, thèmes et sites voisins */
.region-links { display: flex; flex-wrap: wrap; gap: 8px; padding: 0; margin: 0; list-style: none; }
.region-links a {
  display: inline-flex; align-items: center; min-height: 44px; padding: 0 16px; border: 1.5px solid var(--line); border-radius: 999px;
  background: var(--card); color: var(--text); text-decoration: none; font-weight: 700; transition: border-color var(--ease), color var(--ease);
}
.region-links a:hover { border-color: var(--accent); color: var(--accent); }
.themes { display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr)); padding: 0; margin: 0; list-style: none; }
.theme { display: block; height: 100%; padding: 18px 20px; border-radius: var(--radius); background: var(--card); box-shadow: var(--shadow); color: var(--text); text-decoration: none; border-top: 5px solid var(--line); transition: transform var(--ease); }
.theme:hover { transform: translateY(-2px); }
.theme h3 { margin: 0 0 6px; font-size: 28px; }
.theme p { margin: 0; color: var(--muted); }
.theme .more { display: inline-block; margin-top: 10px; color: var(--accent); font-weight: 700; }
.theme.t-snow { border-top-color: #4f8fc6; }
.theme.t-winter { border-top-color: #a3241c; }
.theme.t-lakes { border-top-color: #1f8a9a; }
.theme.t-mushroom { border-top-color: #8a5a2b; }
.info { padding: 18px 20px; border-radius: var(--radius); background: var(--card); box-shadow: var(--shadow); border-left: 4px solid var(--accent); }
.info h2 { margin: 0 0 6px; font-size: 28px; }
.info p { margin: 0 0 12px; max-width: 75ch; }

/* Formulaire */
.form { max-width: 760px; }
.form fieldset { margin: 0 0 18px; padding: 18px 20px 4px; border: 0; border-radius: var(--radius); background: var(--card); box-shadow: var(--shadow); }
.form legend { float: left; width: 100%; margin: 0 0 12px; padding: 0; font: 400 28px/1 var(--font-display); letter-spacing: .02em; }
.form legend + * { clear: both; }
.field { margin-bottom: 16px; }
.field label { display: block; font-weight: 700; margin-bottom: 4px; }
.field .hint, .form .hint { margin: 0 0 6px; font-size: 14px; }
.field input:not([type="checkbox"]), .field select, .field textarea {
  width: 100%; min-height: 46px; padding: 10px 14px; border: 1.5px solid var(--line); border-radius: 12px;
  background: var(--bg); color: var(--text); font: 17px var(--font-body); transition: border-color var(--ease);
}
.field input:hover, .field select:hover, .field textarea:hover { border-color: var(--accent); }
.field textarea { min-height: 120px; resize: vertical; }
.field [aria-invalid="true"] { border-color: var(--error); }
.field .error { display: block; margin-top: 4px; color: var(--error); font-size: 15px; font-weight: 700; }
.row { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 0 16px; }
.consent { display: flex; gap: 10px; align-items: flex-start; font-weight: 400 !important; cursor: pointer; }
.consent input { width: 22px; height: 22px; margin-top: 2px; flex: none; accent-color: var(--accent); }
.req { color: var(--fun); font-weight: 700; }
.trap { position: absolute; left: -5000px; width: 1px; height: 1px; overflow: hidden; }
.notice { margin: 0 0 18px; padding: 14px 18px; border-radius: 14px; background: var(--walk-bg); color: var(--text); font-weight: 600; }
.notice.bad { background: var(--fun-bg); }
.notice:empty { display: none; }

/* Texte courant */
.prose { max-width: 75ch; }
.prose h2 { margin: 28px 0 8px; font-size: 30px; }

footer { color: var(--muted); font-size: 14px; margin-top: 32px; padding-top: 18px; border-top: 1px solid var(--grid); }
footer p { margin: 0 0 6px; }
footer nav { display: flex; flex-wrap: wrap; gap: 0 16px; }
footer nav a { display: inline-flex; align-items: center; min-height: 44px; }

@media (max-width: 640px) {
  .event { grid-template-columns: 64px 1fr; gap: 12px; }
  .event .date .day { font-size: 32px; }
  .filter { flex: 1 1 140px; }
  .filter select { width: 100%; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; }
}
