+ )}
+
+ {/* Vue par région (liste repliable) */}
+ {!error && (
+
-
+ {/* Liste des départements en alerte */}
+ {!error && activeDeptCodes.length > 0 && (
+
+
+
Départements en alerte ({activeDeptCodes.length})
+
+
+
-
- >
- )
- }
+
+
+ Triés par numéro. Un département peut cumuler plusieurs phénomènes (ex : canicule + orages).
+
+
+
+
+ Aucun département ne correspond.
+
+
+
+ )}
- {
- !error && activeDeptCodes.length > 0 && (
-
-
-
- Départements en alerte ({activeDeptCodes.length})
-
-
- Triés par numéro de département. Un département peut cumuler plusieurs phénomènes (ex: canicule + orages).
-
-
- {activeDeptCodes.map((code) => {
- const dept = getDepartement(code);
- if (!dept) return null;
- const alerts = (alertsByDept.get(code) ?? []).slice().sort((a, b) => b.colorId - a.colorId);
- return (
- -
-
-
- );
- })}
-
-
-
- )
- }
+ {/* CTA banner */}
+
+
+
+
Vous connaissez quelqu'un de fragile ?
+
+ Retrouvez les bons gestes par phénomène (canicule, orages, vent…) à imprimer ou à transmettre à un proche.
+
+
+
+ Voir les conseils →
+
+
+
+
+ {/* Outre-mer note */}
+
+
+
+
+
+
+
diff --git a/src/styles/global.css b/src/styles/global.css
index 2c7b90c..bbd8b2f 100644
--- a/src/styles/global.css
+++ b/src/styles/global.css
@@ -2,35 +2,386 @@
@tailwind components;
@tailwind utilities;
+/* ─── Design tokens ───────────────────────────────────────── */
+:root {
+ --paper: #fdfaf2;
+ --paper-2: #ffffff;
+ --paper-elev: #ffffff;
+ --paper-warm: #f8f1e1;
+ --ink: #1b1814;
+ --ink-2: #3a342c;
+ --ink-soft: #6b6457;
+ --ink-mute: #968d7d;
+ --line: #ebe2cb;
+ --line-strong: #d5c9aa;
+
+ --brand: #d97757;
+ --brand-deep: #b45a3a;
+ --brand-soft: #fde2d3;
+ --brand-tint: #fff1e8;
+ --brand-ink: #6b2c11;
+
+ --sun: #f4c97d;
+ --sun-deep: #c98e2a;
+
+ --v-vert: #2f7d3a;
+ --v-vert-bg: #e8f3e6;
+ --v-vert-ink: #1b4a22;
+
+ --v-jaune: #b08a00;
+ --v-jaune-bg: #fff5cf;
+ --v-jaune-ink: #5e4900;
+
+ --v-orange: #c25f00;
+ --v-orange-bg: #ffd9b3;
+ --v-orange-ink: #5a2a00;
+
+ --v-rouge: #c01818;
+ --v-rouge-bg: #ffb3b3;
+ --v-rouge-ink: #5a0a0a;
+
+ /* Vivid map fills — closer to Météo France's signage */
+ --map-vert: #c8e3c4;
+ --map-jaune: #ffdf3d;
+ --map-orange: #ff9024;
+ --map-rouge: #e2231a;
+
+ --font-ui: 'Public Sans', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
+ --font-display: 'Manrope', 'Public Sans', system-ui, sans-serif;
+ --font-mono: 'JetBrains Mono', ui-monospace, monospace;
+
+ --r-md: 10px;
+ --r-lg: 16px;
+ --r-pill: 999px;
+
+ --sh-1: 0 1px 2px rgba(27, 24, 20, 0.04);
+ --sh-2: 0 2px 8px rgba(27, 24, 20, 0.06), 0 1px 2px rgba(27, 24, 20, 0.04);
+ --sh-3: 0 12px 32px rgba(27, 24, 20, 0.10), 0 2px 6px rgba(27, 24, 20, 0.06);
+}
+
+[data-theme='dark'] {
+ --paper: #14110d;
+ --paper-2: #1c1814;
+ --paper-elev: #221d18;
+ --paper-warm: #2a221a;
+ --ink: #f7f1e2;
+ --ink-2: #d8cfba;
+ --ink-soft: #a89e89;
+ --ink-mute: #756e60;
+ --line: #2f2820;
+ --line-strong: #46402f;
+
+ --brand: #ec9272;
+ --brand-deep: #f4b39a;
+ --brand-soft: #3d2317;
+ --brand-tint: #2a1b10;
+ --brand-ink: #ffd4c1;
+
+ --v-vert: #7dd99a;
+ --v-vert-bg: #15301b;
+ --v-vert-ink: #b8e8c5;
+
+ --v-jaune: #f0c860;
+ --v-jaune-bg: #36290c;
+ --v-jaune-ink: #ffe6a3;
+
+ --v-orange: #ffa970;
+ --v-orange-bg: #3a1d0a;
+ --v-orange-ink: #ffd3b3;
+
+ --v-rouge: #ff8a8a;
+ --v-rouge-bg: #381212;
+ --v-rouge-ink: #ffc4c4;
+
+ --map-vert: #2d5a35;
+ --map-jaune: #f0c860;
+ --map-orange: #ff9050;
+ --map-rouge: #e85050;
+
+ --sh-2: 0 2px 8px rgba(0, 0, 0, 0.35), 0 1px 2px rgba(0, 0, 0, 0.25);
+ --sh-3: 0 12px 32px rgba(0, 0, 0, 0.45), 0 2px 6px rgba(0, 0, 0, 0.3);
+}
+
@layer base {
html {
- @apply text-slate-900 antialiased;
+ background: var(--paper);
+ color: var(--ink);
+ font-family: var(--font-ui);
+ font-size: 17px;
+ line-height: 1.55;
+ -webkit-font-smoothing: antialiased;
+ text-rendering: optimizeLegibility;
+ @apply antialiased;
}
body {
- @apply bg-slate-50;
+ background: var(--paper);
+ color: var(--ink);
+ min-height: 100dvh;
+ transition: background-color .25s ease, color .25s ease;
+ }
+ @media (max-width: 720px) {
+ html { font-size: 16px; }
+ }
+ h1, h2, h3, h4 {
+ font-family: var(--font-display);
+ color: var(--ink);
+ letter-spacing: -0.01em;
+ margin: 0;
+ }
+ h1 {
+ font-size: clamp(2rem, 1.4rem + 2.5vw, 3.25rem);
+ line-height: 1.05;
+ font-weight: 800;
+ letter-spacing: -0.025em;
+ }
+ h2 {
+ font-size: clamp(1.5rem, 1.1rem + 1.5vw, 2.25rem);
+ line-height: 1.15;
+ font-weight: 700;
+ letter-spacing: -0.02em;
+ }
+ h3 {
+ font-size: clamp(1.15rem, 1rem + 0.6vw, 1.5rem);
+ line-height: 1.25;
+ font-weight: 700;
}
a {
- @apply underline-offset-2 hover:underline;
+ color: var(--brand-deep);
+ text-decoration: none;
+ border-bottom: 1px solid transparent;
+ transition: border-color .15s;
+ }
+ a:hover { border-bottom-color: currentColor; }
+ *:focus { outline: none; }
+ *:focus-visible {
+ outline: 3px solid var(--brand);
+ outline-offset: 2px;
+ border-radius: 3px;
}
}
@layer components {
.container-tight {
- @apply mx-auto w-full max-w-5xl px-4 sm:px-6;
+ max-width: 1240px;
+ margin-inline: auto;
+ width: 100%;
+ padding-inline: clamp(16px, 4vw, 32px);
}
+
+ .kicker {
+ font-family: var(--font-mono);
+ font-size: 0.75rem;
+ letter-spacing: 0.08em;
+ text-transform: uppercase;
+ color: var(--ink-soft);
+ font-weight: 500;
+ }
+
+ .ic-card {
+ background: var(--paper-elev);
+ border: 1px solid var(--line);
+ border-radius: var(--r-lg);
+ box-shadow: var(--sh-1);
+ padding: 20px;
+ transition: border-color .15s, box-shadow .15s, transform .15s;
+ }
+ .ic-card-soft {
+ background: var(--paper-warm);
+ border: 1px solid var(--line);
+ border-radius: var(--r-lg);
+ padding: 20px;
+ }
+ .ic-card-interactive { cursor: pointer; }
+ .ic-card-interactive:hover {
+ border-color: var(--ink-soft);
+ box-shadow: var(--sh-2);
+ transform: translateY(-2px);
+ }
+
+ /* Buttons */
+ .ic-btn {
+ display: inline-flex;
+ align-items: center;
+ justify-content: center;
+ gap: 8px;
+ min-height: 44px;
+ padding: 0 18px;
+ border-radius: var(--r-pill);
+ border: 1.5px solid transparent;
+ font: 600 0.95rem/1 var(--font-ui);
+ cursor: pointer;
+ transition: transform .08s ease, box-shadow .15s, background-color .15s, border-color .15s, color .15s;
+ white-space: nowrap;
+ background: transparent;
+ color: var(--ink);
+ text-decoration: none;
+ }
+ .ic-btn:hover { transform: translateY(-1px); border-bottom-color: transparent; }
+ .ic-btn:active { transform: translateY(0); }
+ .ic-btn-primary { background: var(--ink); color: var(--paper); border-color: var(--ink); }
+ .ic-btn-primary:hover { background: var(--ink-2); border-color: var(--ink-2); box-shadow: var(--sh-2); }
+ .ic-btn-brand { background: var(--brand); color: #fff; border-color: var(--brand); }
+ .ic-btn-brand:hover { background: var(--brand-deep); border-color: var(--brand-deep); box-shadow: var(--sh-2); }
+ .ic-btn-ghost { background: transparent; color: var(--ink); border-color: var(--line-strong); }
+ .ic-btn-ghost:hover { background: var(--paper-warm); border-color: var(--ink-soft); }
+ .ic-btn-sm { min-height: 36px; padding: 0 14px; font-size: 0.85rem; }
+ .ic-btn-lg { min-height: 52px; padding: 0 24px; font-size: 1rem; }
+
+ /* Vigilance pill (legend + chip) */
.vigilance-chip {
- @apply inline-flex items-center gap-1.5 rounded-full px-3 py-1 text-sm font-medium ring-1 ring-inset;
+ display: inline-flex;
+ align-items: center;
+ gap: 6px;
+ padding: 4px 10px;
+ border-radius: var(--r-pill);
+ border: 1.5px solid;
+ font-size: 0.82rem;
+ font-weight: 600;
+ line-height: 1;
+ font-family: var(--font-ui);
+ background: var(--paper-elev);
}
- .vigilance-chip-1 {
- @apply bg-green-50 text-green-800 ring-green-200;
+ .vigilance-chip .glyph { font-size: 0.75em; line-height: 1; }
+ .vigilance-chip-lg { padding: 8px 16px; font-size: 0.95rem; }
+ .vigilance-chip-lg .glyph { font-size: 0.85em; }
+
+ .vigilance-chip-1 { color: var(--v-vert); background: var(--v-vert-bg); border-color: var(--v-vert); }
+ .vigilance-chip-2 { color: var(--v-jaune); background: var(--v-jaune-bg); border-color: var(--v-jaune); }
+ .vigilance-chip-3 { color: var(--v-orange); background: var(--v-orange-bg); border-color: var(--v-orange); }
+ .vigilance-chip-4 { color: var(--v-rouge); background: var(--v-rouge-bg); border-color: var(--v-rouge); }
+
+ /* Vigilance block (colored card for hero alerts) */
+ .v-block {
+ border-radius: var(--r-lg);
+ border-width: 1.5px;
+ border-style: solid;
+ padding: 20px;
}
- .vigilance-chip-2 {
- @apply bg-yellow-50 text-yellow-900 ring-yellow-300;
+ .v-vert { background-color: var(--v-vert-bg); border-color: var(--v-vert); color: var(--v-vert-ink); }
+ .v-jaune { background-color: var(--v-jaune-bg); border-color: var(--v-jaune); color: var(--v-jaune-ink); }
+ .v-orange { background-color: var(--v-orange-bg); border-color: var(--v-orange); color: var(--v-orange-ink); }
+ .v-rouge { background-color: var(--v-rouge-bg); border-color: var(--v-rouge); color: var(--v-rouge-ink); }
+
+ /* Input */
+ .ic-input {
+ display: flex;
+ align-items: center;
+ gap: 10px;
+ min-height: 44px;
+ width: 100%;
+ padding: 0 16px;
+ border-radius: var(--r-pill);
+ border: 1.5px solid var(--line-strong);
+ background: var(--paper-2);
+ font: 500 1rem var(--font-ui);
+ color: var(--ink);
+ transition: border-color .15s, box-shadow .15s;
}
- .vigilance-chip-3 {
- @apply bg-orange-50 text-orange-900 ring-orange-300;
+ .ic-input:focus-within {
+ border-color: var(--brand);
+ box-shadow: 0 0 0 4px var(--brand-tint);
}
- .vigilance-chip-4 {
- @apply bg-red-50 text-red-900 ring-red-300;
+ .ic-input input {
+ flex: 1;
+ border: none;
+ outline: none;
+ background: transparent;
+ color: inherit;
+ font: inherit;
+ min-width: 0;
+ }
+ .ic-input input::placeholder { color: var(--ink-mute); }
+}
+
+/* Skip link */
+.skip-link {
+ position: absolute;
+ top: -100px;
+ left: 8px;
+ background: var(--ink);
+ color: var(--paper);
+ padding: 10px 16px;
+ border-radius: var(--r-md);
+ font-weight: 600;
+ z-index: 1000;
+ transition: top .15s;
+}
+.skip-link:focus { top: 8px; border-bottom: none; }
+
+/* Dept row hover (homepage list) */
+.dept-row:hover, .dept-row:focus-visible {
+ background-color: var(--paper-warm);
+}
+
+/* Sticky blurred header */
+.site-header {
+ position: sticky;
+ top: 0;
+ z-index: 50;
+ background: color-mix(in srgb, var(--paper) 90%, transparent);
+ backdrop-filter: saturate(140%) blur(12px);
+ border-bottom: 1px solid var(--line);
+}
+
+/* Footer */
+.site-footer {
+ margin-top: 80px;
+ border-top: 1px solid var(--line);
+ background: var(--paper-warm);
+}
+.site-footer h4 {
+ color: var(--ink-soft);
+ font-size: 0.78rem;
+ text-transform: uppercase;
+ letter-spacing: 0.08em;
+ margin-bottom: 12px;
+ font-family: var(--font-mono);
+ font-weight: 500;
+}
+
+/* Map fills (vivid, MF-like) */
+.france-map-dept {
+ transition: filter .15s, stroke-width .15s;
+ cursor: pointer;
+}
+.france-map-dept:hover, .france-map-dept:focus {
+ stroke: var(--ink);
+ stroke-width: 1.2;
+ filter: brightness(1.05);
+ outline: none;
+}
+.france-map-fill-1 { fill: var(--map-vert); }
+.france-map-fill-2 { fill: var(--map-jaune); }
+.france-map-fill-3 { fill: var(--map-orange); }
+.france-map-fill-4 { fill: var(--map-rouge); }
+
+/* Icon button (header toggles) */
+.icon-btn {
+ width: 40px;
+ height: 40px;
+ display: inline-flex;
+ align-items: center;
+ justify-content: center;
+ border-radius: var(--r-pill);
+ background: transparent;
+ border: 1.5px solid var(--line-strong);
+ cursor: pointer;
+ color: var(--ink);
+ transition: background .15s, border-color .15s;
+}
+.icon-btn:hover { background: var(--paper-warm); border-color: var(--ink-soft); }
+
+@media (prefers-reduced-motion: reduce) {
+ *, *::before, *::after {
+ animation-duration: .01ms !important;
+ transition-duration: .01ms !important;
+ animation-iteration-count: 1 !important;
+ scroll-behavior: auto !important;
}
}
+
+@media print {
+ .site-header, .site-footer, .no-print { display: none !important; }
+ body { background: white; color: black; font-size: 12pt; }
+ .v-block, .ic-card { box-shadow: none !important; break-inside: avoid; }
+}
diff --git a/tailwind.config.mjs b/tailwind.config.mjs
index 3073244..fda69c9 100644
--- a/tailwind.config.mjs
+++ b/tailwind.config.mjs
@@ -35,7 +35,9 @@ export default {
},
},
fontFamily: {
- sans: ['system-ui', '-apple-system', 'BlinkMacSystemFont', 'Segoe UI', 'sans-serif'],
+ sans: ['"Public Sans"', 'system-ui', '-apple-system', 'BlinkMacSystemFont', 'Segoe UI', 'sans-serif'],
+ display: ['Manrope', '"Public Sans"', 'system-ui', 'sans-serif'],
+ mono: ['"JetBrains Mono"', 'ui-monospace', 'monospace'],
},
},
},