/* VARIABLES */
:root {
    --swiss-red: #D52B1E;
    --black: #111;
    --dark-grey: #333;
    --light-grey: #F4F4F4;
    --border: #DDD;
}

body {
    font-family: 'Roboto', Helvetica, Arial, sans-serif;
    margin: 0; padding: 0;
    color: var(--black);
    background-color: #fff;
    line-height: 1.6;
}

/* HEADER FIX */
header {
    background: white; border-bottom: 4px solid var(--swiss-red);
    position: sticky; top: 0; z-index: 1000; /* Z-index haut pour passer au dessus de la carte */
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

.header-inner {
    max-width: 1200px; margin: 0 auto; padding: 15px 20px;
    display: flex; justify-content: space-between; align-items: center;
}

.logo-container { display: flex; align-items: center; cursor: pointer; }
.logo-square { width: 28px; height: 28px; background: var(--swiss-red); margin-right: 12px; }
.logo-text { font-weight: 900; font-size: 22px; letter-spacing: -0.5px; }

nav { display: flex; align-items: center; }
nav a { text-decoration: none; color: var(--dark-grey); margin-left: 25px; font-size: 14px; font-weight: 700; text-transform: uppercase; transition: color 0.2s; }
nav a:hover { color: var(--swiss-red); }

.lang-switch { margin-left: 30px; padding-left: 20px; border-left: 2px solid #eee; display: flex; }
.lang-btn { cursor: pointer; margin: 0 5px; font-size: 13px; font-weight: bold; color: #999; }
.lang-btn.active { color: var(--swiss-red); text-decoration: underline; }

.btn-auth { background: var(--black); color: white; border: none; padding: 10px 18px; margin-left: 25px; font-weight: bold; cursor: pointer; font-size: 12px; }
.btn-auth:hover { background: var(--swiss-red); }

/* HERO */
.hero { background: var(--light-grey); padding: 60px 0; border-bottom: 1px solid var(--border); }
.hero-content { max-width: 1200px; margin: 0 auto; padding: 0 20px; }
h1 { font-size: 36px; margin: 0 0 10px 0; text-transform: uppercase; letter-spacing: -1px; }
.subtitle { border-left: 4px solid var(--swiss-red); padding-left: 15px; color: #555; font-size: 16px; margin-bottom: 30px;}

.alert-box { background: white; border: 1px solid #ccc; padding: 20px; border-top: 3px solid var(--swiss-red); font-size: 14px; }
.alert-badge { background: var(--swiss-red); color: white; padding: 3px 6px; font-weight: bold; font-size: 11px; margin-right: 10px; }

/* LAYOUT */
.main-wrapper { max-width: 1000px; margin: 0 auto; padding: 40px 20px; }
.content-section { margin-bottom: 80px; scroll-margin-top: 100px; }
h2 { font-size: 24px; text-transform: uppercase; border-bottom: 2px solid #eee; padding-bottom: 10px; margin-bottom: 30px; color: var(--black); }

/* STATS */
.stats-row { display: flex; gap: 20px; margin-bottom: 60px; flex-wrap: wrap; }
.stat-box { background: white; padding: 25px; border: 1px solid var(--border); flex: 1; text-align: center; box-shadow: 0 2px 5px rgba(0,0,0,0.05); }
.stat-box.warning { border-bottom: 4px solid var(--swiss-red); }
.stat-label { display: block; font-size: 11px; text-transform: uppercase; color: #888; margin-bottom: 5px; }
.stat-value { font-size: 28px; font-weight: 900; color: var(--black); }

/* TIMELINE */
.timeline { border-left: 2px solid #ddd; padding-left: 25px; margin-left: 10px; }
.timeline-item { margin-bottom: 30px; }
.timeline-date { font-weight: bold; color: var(--swiss-red); font-size: 13px; display: block; margin-bottom: 5px; }

/* LEGAL */
.legal-box { background: #f9f9f9; padding: 20px; font-family: monospace; border-left: 3px solid #333; margin-bottom: 15px; }
.download-link { color: var(--swiss-red); font-weight: bold; font-size: 12px; text-decoration: none; }

/* MAP REAL LEAFLET */
.map-container-real {
    width: 100%;
    height: 450px; /* IMPORTANT: Leaflet a besoin d'une hauteur */
    background: #e5e5e5;
    border: 1px solid #999;
    z-index: 1;
}
.map-legend { margin-top: 10px; font-size: 12px; }
.dot { display: inline-block; width: 10px; height: 10px; border-radius: 50%; margin-right: 5px; }
.dot.red { background: var(--swiss-red); } .dot.orange { background: orange; }

/* Styles pour les popups de la carte */
.leaflet-popup-content-wrapper { border-radius: 0; padding: 0; }
.leaflet-popup-content { margin: 10px; font-family: 'Roboto', sans-serif; font-size: 12px; }

/* FORM & DARK SECTION */
.bg-dark-section { background: #222; padding: 40px; border-radius: 4px; color: white; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; }
.check-list li { list-style: none; margin-bottom: 10px; padding-left: 20px; border-left: 2px solid var(--swiss-red); color: #ccc; }

.form-group { margin-bottom: 15px; }
label { display: block; font-size: 12px; font-weight: bold; margin-bottom: 5px; color: #aaa; }
input, select, textarea { width: 100%; padding: 12px; border: 1px solid #444; background: #333; color: white; font-family: inherit; box-sizing: border-box; }
.btn-submit { width: 100%; background: var(--swiss-red); color: white; border: none; padding: 12px; font-weight: bold; cursor: pointer; margin-top: 10px;}
.btn-submit:hover { background: #b01b1b; }

/* FOOTER */
footer { background: #f0f0f0; padding: 40px 0; font-size: 12px; color: #666; text-align: center; border-top: 1px solid #ddd; }

/* MODAL */
.modal-overlay { display: none; position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(255,255,255,0.95); z-index: 2000; align-items: center; justify-content: center; }
.modal-content { background: white; border: 2px solid var(--swiss-red); padding: 30px; width: 450px; font-family: monospace; box-shadow: 0 10px 30px rgba(0,0,0,0.1); }
.badge-red { background: var(--swiss-red); color: white; padding: 2px 5px; font-weight: bold; }
.terminal-log { background: #f4f4f4; padding: 15px; margin: 15px 0; font-size: 12px; border-left: 3px solid #333; }
.red-text { color: var(--swiss-red); font-weight: bold; }
.btn-dark { background: #333; color: white; border: none; padding: 10px; cursor: pointer; width: 100%; font-family: sans-serif; }

/* RESPONSIVE */
@media (max-width: 800px) {
    .header-inner { flex-direction: column; gap: 15px; }
    nav { flex-wrap: wrap; justify-content: center; }
    nav a { margin: 5px 10px; }
    .grid-2 { grid-template-columns: 1fr; }
    .btn-auth { margin-left: 0; margin-top: 10px; }
}