/* Autour. Road-sign vernacular: commune entry plate, direction chips, enamel street plaque. */
@font-face { font-family: "Barlow Condensed"; font-weight: 600; font-display: swap; src: url("/fonts/barlow-condensed-latin-600-normal.woff2") format("woff2"); }
@font-face { font-family: "Barlow Condensed"; font-weight: 700; font-display: swap; src: url("/fonts/barlow-condensed-latin-700-normal.woff2") format("woff2"); }
@font-face { font-family: "Source Sans 3"; font-weight: 400; font-display: swap; src: url("/fonts/source-sans-3-latin-400-normal.woff2") format("woff2"); }
@font-face { font-family: "Source Sans 3"; font-weight: 700; font-display: swap; src: url("/fonts/source-sans-3-latin-700-normal.woff2") format("woff2"); }

:root {
  --ground: #F2F4EF;
  --surface: #FFFFFF;
  --ink: #15181C;
  --ink-soft: #4E5660;
  --rule: #D5DAD2;
  --sign-white: #FFFFFF;
  --sign-ink: #15181C;
  --sign-red: #C4122F;
  --plaque: #1D3A8A;
  --plaque-ink: #FFFFFF;
  --link: #1D3A8A;
  --yellow: #F2C230;
  --yellow-ink: #2A2204;
  --warn: #8A4B0F;
  --warn-bg: #FBEFD9;
  --ok: #1E6B45;
  --error: #A3162B;
  --field: #FFFFFF;
  --display: "Barlow Condensed", "Arial Narrow", "Helvetica Neue", Arial, sans-serif;
  --body: "Source Sans 3", "Segoe UI", Verdana, sans-serif;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --ground: #11151A; --surface: #1A2027; --ink: #ECEFF1; --ink-soft: #A3ADB8; --rule: #2C353F;
    --plaque: #24479F; --link: #9DB7FF; --warn: #F0C27A; --warn-bg: #3A2C12; --ok: #7FD1A6; --error: #FF8A9A; --field: #11151A;
  }
}
:root[data-theme="dark"] {
  --ground: #11151A; --surface: #1A2027; --ink: #ECEFF1; --ink-soft: #A3ADB8; --rule: #2C353F;
  --plaque: #24479F; --link: #9DB7FF; --warn: #F0C27A; --warn-bg: #3A2C12; --ok: #7FD1A6; --error: #FF8A9A; --field: #11151A;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--ground); color: var(--ink); font-family: var(--body); font-size: 1.125rem; line-height: 1.5; }
a { color: var(--link); text-underline-offset: 0.15em; }
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible, summary:focus-visible { outline: 3px solid var(--yellow); outline-offset: 2px; }
[hidden] { display: none !important; }

.wrap { max-width: 68rem; margin: 0 auto; padding-inline: 1rem; padding-block: 1.25rem 3rem; display: flex; flex-direction: column; gap: 2rem; }

/* Commune entry sign */
.masthead { display: flex; flex-direction: column; gap: 0.9rem; align-items: flex-start; }
.panneau { background: var(--sign-white); color: var(--sign-ink); border: 0.4rem solid var(--sign-red); border-radius: 0.9rem; padding: 0.55rem 1.2rem 0.7rem; box-shadow: 0 0 0 0.18rem var(--sign-white), 0 0.15rem 0.6rem rgba(0,0,0,.18); max-width: 100%; text-decoration: none; display: inline-block; }
.panneau .autour { display: block; font-family: var(--display); font-weight: 600; font-size: 1.05rem; letter-spacing: 0.14em; text-transform: uppercase; color: #4E5660; }
.panneau .ville { display: block; font-family: var(--display); font-weight: 700; font-size: clamp(2rem, 8.5vw, 3.4rem); line-height: 0.98; text-transform: uppercase; letter-spacing: 0.01em; text-wrap: balance; }
.edition { margin: 0; color: var(--ink-soft); max-width: 40rem; }
.edition strong { color: var(--ink); }
.jump { font-weight: 700; }
@media (min-width: 60rem) { .jump { display: none; } }
html { scroll-behavior: smooth; scroll-padding-top: 1rem; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

.layout { display: grid; gap: 2.5rem; grid-template-columns: minmax(0, 1fr); align-items: start; }
@media (min-width: 60rem) { .layout { grid-template-columns: minmax(0, 1fr) 23rem; gap: 3rem; } .aside { position: sticky; top: 1rem; } }
.main, .aside { display: flex; flex-direction: column; gap: 2rem; min-width: 0; }

h2.day { font-family: var(--display); font-weight: 700; font-size: 1.7rem; line-height: 1.05; text-transform: uppercase; letter-spacing: 0.03em; margin: 0; display: flex; align-items: baseline; gap: 0.6rem; flex-wrap: wrap; }
h2.day .date { font-weight: 600; font-size: 1.1rem; color: var(--ink-soft); letter-spacing: 0.06em; }
.day-block { display: flex; flex-direction: column; gap: 0.9rem; }
.day-block > h2 { border-bottom: 0.2rem solid var(--ink); padding-bottom: 0.35rem; }

.events { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; }
.event { display: grid; grid-template-columns: 4.6rem minmax(0, 1fr); gap: 0.25rem 0.9rem; padding-block: 1rem; border-bottom: 1px solid var(--rule); }
.event:last-child { border-bottom: none; }
.event .time { font-family: var(--display); font-weight: 700; font-size: 1.35rem; line-height: 1.15; font-variant-numeric: tabular-nums; }
.event .time small { display: block; font-weight: 600; font-size: 0.95rem; color: var(--ink-soft); }
.event .body { display: flex; flex-direction: column; gap: 0.35rem; min-width: 0; }
.event h3 { margin: 0; font-family: var(--body); font-weight: 700; font-size: 1.15rem; line-height: 1.25; text-wrap: balance; }
.event p { margin: 0; }
.event .where { display: flex; flex-wrap: wrap; gap: 0.4rem 0.6rem; align-items: center; color: var(--ink-soft); font-size: 0.98rem; }
.event .meta { color: var(--ink-soft); font-size: 0.95rem; }

/* Direction-sign chip: white plate, black border */
.fleche { font-family: var(--display); font-weight: 700; font-size: 0.95rem; letter-spacing: 0.04em; text-transform: uppercase; background: var(--sign-white); color: var(--sign-ink); border: 2px solid var(--sign-ink); padding: 0.05rem 0.5rem; border-radius: 0.2rem; white-space: nowrap; }
.fleche.ici { background: var(--yellow); color: var(--yellow-ink); border-color: var(--yellow-ink); }
.pill { font-size: 0.85rem; font-weight: 700; background: var(--warn-bg); color: var(--warn); padding: 0.1rem 0.5rem; border-radius: 99px; align-self: flex-start; }

.soon h2 { font-family: var(--display); font-weight: 700; font-size: 1.35rem; text-transform: uppercase; letter-spacing: 0.05em; margin: 0 0 0.4rem; color: var(--ink-soft); }
.soon .event { grid-template-columns: 4.6rem minmax(0, 1fr); padding-block: 0.75rem; }
.soon .event .time { font-size: 1.1rem; }
.soon .event h3 { font-size: 1.05rem; }

.savoir h2 { font-family: var(--display); font-weight: 700; font-size: 1.7rem; line-height: 1.05; text-transform: uppercase; letter-spacing: 0.03em; margin: 0; border-bottom: 0.2rem solid var(--yellow); padding-bottom: 0.35rem; }
.savoir-intro { margin: 0.6rem 0 0; color: var(--ink-soft); font-size: 0.95rem; }
.notices { list-style: none; margin: 0.4rem 0 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(17rem, 1fr)); gap: 0 1.5rem; }
.notice { padding-block: 0.9rem; border-bottom: 1px solid var(--rule); display: flex; flex-direction: column; gap: 0.3rem; min-width: 0; }
.notice-head { display: flex; flex-wrap: wrap; gap: 0.35rem 0.6rem; align-items: center; }
.notice .fleche { white-space: normal; }
.notice-when { font-family: var(--display); font-weight: 600; font-size: 1rem; letter-spacing: 0.03em; color: var(--ink-soft); }
.notice h3 { margin: 0; font-size: 1.05rem; line-height: 1.25; font-weight: 700; text-wrap: balance; }
.notice p { margin: 0; font-size: 0.98rem; }

.empty-note { background: var(--surface); border: 1px dashed var(--rule); padding: 0.9rem 1rem; color: var(--ink-soft); margin: 0; }

/* Enamel street plaque */
.plaque { background: var(--plaque); color: var(--plaque-ink); border-radius: 0.5rem; padding: 0.35rem; box-shadow: 0 0.15rem 0.6rem rgba(0,0,0,.2); }
.plaque-inner { border: 2px solid rgba(255,255,255,.85); border-radius: 0.3rem; padding: 1.1rem 1.1rem 1.25rem; display: flex; flex-direction: column; gap: 0.8rem; }
.plaque h2 { margin: 0; font-family: var(--display); font-weight: 700; font-size: 1.7rem; line-height: 1.05; text-transform: uppercase; letter-spacing: 0.03em; text-wrap: balance; }
.plaque p { margin: 0; }
.plaque .fine { font-size: 0.9rem; opacity: 0.92; }
.plaque a { color: #FFFFFF; }

form { display: flex; flex-direction: column; gap: 0.75rem; }
label { font-weight: 700; font-size: 0.95rem; display: flex; flex-direction: column; gap: 0.3rem; }
label .opt { font-weight: 400; opacity: 0.8; }
label .lab { display: block; }
input[type="email"], input[type="text"], select, textarea { font: inherit; color: var(--ink); background: var(--field); border: 2px solid var(--ink); border-radius: 0.3rem; padding: 0.6rem 0.7rem; width: 100%; min-height: 2.9rem; }
.plaque input, .plaque select { border-color: #FFFFFF; background: #FFFFFF; color: #15181C; }
textarea { min-height: 5rem; resize: vertical; }
input[type="file"] { font: inherit; max-width: 100%; }
button { font-family: var(--display); font-weight: 700; font-size: 1.2rem; letter-spacing: 0.05em; text-transform: uppercase; cursor: pointer; border: none; border-radius: 0.3rem; padding: 0.7rem 1.1rem; min-height: 3rem; background: var(--ink); color: var(--ground); }
.plaque button { background: var(--yellow); color: var(--yellow-ink); }
button[disabled] { opacity: 0.6; cursor: progress; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.status { margin: 0; font-weight: 700; }
.status.ok { color: var(--ok); } .status.err { color: var(--error); }
.plaque .status.ok, .plaque .status.err { color: #FFFFFF; background: rgba(0,0,0,.25); padding: 0.5rem 0.7rem; border-radius: 0.3rem; }

.card { background: var(--surface); border: 1px solid var(--rule); border-radius: 0.5rem; padding: 1.1rem; display: flex; flex-direction: column; gap: 0.8rem; }
.card h2 { margin: 0; font-family: var(--display); font-weight: 700; font-size: 1.5rem; line-height: 1.05; text-transform: uppercase; letter-spacing: 0.03em; text-wrap: balance; }
.card p { margin: 0; }
.wa { display: inline-flex; align-self: flex-start; font-weight: 700; }

.prose { max-width: 42rem; display: flex; flex-direction: column; gap: 1rem; }
.prose h1 { font-family: var(--display); font-weight: 700; font-size: 2.2rem; line-height: 1.05; text-transform: uppercase; margin: 0; text-wrap: balance; }
.prose h2 { font-family: var(--display); font-weight: 700; font-size: 1.4rem; text-transform: uppercase; letter-spacing: 0.03em; margin: 0.8rem 0 0; }
.prose p, .prose ul { margin: 0; }
.prose li + li { margin-top: 0.35rem; }

footer.site { border-top: 1px solid var(--rule); padding-top: 1.2rem; color: var(--ink-soft); font-size: 0.93rem; display: flex; flex-direction: column; gap: 0.4rem; }
footer.site p { margin: 0; max-width: 46rem; }

@media (max-width: 26rem) { .event { grid-template-columns: 3.9rem minmax(0, 1fr); } .event .time { font-size: 1.2rem; } }
@media (prefers-reduced-motion: no-preference) { button { transition: transform .08s ease; } button:active { transform: translateY(1px); } }
@media print { .aside, footer.site a { display: none; } body { background: #fff; } }
