* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --color-jti-green: #00bb31;
}

body {
    font-family: sans-serif;
    background-color: #E8EEED;
    overflow: hidden;
}

.view {
    display: none;
    position: absolute;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
}

.view.active {
    display: block;
}

.background-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    position: absolute;
    top: 0;
    left: 0;
    z-index: -1;
}

.map-container {
    position: relative;
    width: 100%;
    height: 100%;
}

/* --- POINTS SUR LA CARTE (DOTS) --- */
.dot {
    position: absolute;
    width: 36px; /* Taille normale (Provinces > 10 points) */
    height: 36px;
    background-color: var(--color-jti-green);
    border: 3px solid #FFFFFF;
    border-radius: 50%;
    color: #FFFFFF;
    font-size: 1rem;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    transform: translate(-50%, -50%);
    box-shadow: 0 4px 6px rgba(0,0,0,0.2);
    transition: transform 0.2s, box-shadow 0.2s;
    z-index: 5;
}

/* Modificateur pour Home Page et Provinces <= 10 points */
.dot-large {
    width: 45px !important;
    height: 45px !important;
    font-size: 1.2rem !important;
}

/* Modificateurs de police (Bold vs Regular & Tailles) */
.dot-home { 
    font-weight: 700 !important; /* Bold sur la home */
    color: #FFFFFF !important; /* Blanc sur la home */
}
.dot-prov { 
    font-weight: 600 !important; /* Un peu plus gras pour bien lire le noir */
    font-size: 0.7rem !important; /* Plus petit et discret ! */
    color: var(--color-jti-green); /* Noir dans les provinces */
}

.dot:hover {
    transform: translate(-50%, -50%) scale(1.1);
}

/* Animation Pulse Aléatoire (Home) */
@keyframes pulse-attention {
    0% { transform: translate(-50%, -50%) scale(1); box-shadow: 0 0 0 0 rgba(0, 187, 49, 0.7); }
    50% { transform: translate(-50%, -50%) scale(1.2); box-shadow: 0 0 20px 10px rgba(0, 187, 49, 0); }
    100% { transform: translate(-50%, -50%) scale(1); box-shadow: 0 0 0 0 rgba(0, 187, 49, 0); }
}

.dot-animating {
    animation: pulse-attention 0.8s cubic-bezier(0.25, 1, 0.5, 1) !important;
    z-index: 100 !important;
}

/* --- BOUTON DE RETOUR INVISIBLE --- */
.invisible-back-btn {
    position: absolute;
    cursor: pointer;
    z-index: 10;
}

/* --- OVERLAY VERT --- */
.detail-overlay {
    position: absolute;
    bottom: 0; 
    height: 68vh; 
    left: -100%; 
    width: 45vw; 
    background-color: var(--color-jti-green);
    border-radius: 0 35px 0 0; 
    box-shadow: 5px 0 15px rgba(0,0,0,0.15);
    z-index: 20;
    transition: left 0.5s ease-in-out; 
    display: flex;
    flex-direction: column;
}

.detail-overlay.overlay-active {
    left: 0;
}

.overlay-content {
    padding: 40px;
    height: 100%;
    overflow-y: auto;
    scrollbar-width: none;
}
.overlay-content::-webkit-scrollbar {
    display: none;
}

/* --- TYPOGRAPHIES SEITU-VARIABLE (CORRIGÉ) --- */
.overlay-header h1 {
    font-family: "seitu-variable", sans-serif !important;
    font-weight: 300 !important; /* Light */
    font-size: 1.1rem;
    color: #FFFFFF;
    letter-spacing: 0.5px;
    margin-bottom: 20px;
}

.detail-text-block {
    color: #FFFFFF;
}

.detail-text-block h3 {
    font-family: "seitu-variable", sans-serif !important;
    font-weight: 700 !important; /* Bold */
    font-size: 1.1rem;
    margin-bottom: 5px; 
    line-height: 1.3;
}

.detail-date {
    font-family: "seitu-variable", sans-serif !important;
    font-weight: 400 !important; /* Regular */
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.8); 
    margin-bottom: 15px;
}

.detail-text-block p:not(.detail-date) {
    font-family: "seitu-variable", sans-serif !important;
    font-weight: 400 !important; /* Regular */
    font-size: 0.95rem;
    margin-bottom: 12px;
    line-height: 1.4;
}

.media-link-btn {
    font-family: "seitu-variable", sans-serif !important;
    font-weight: 700 !important; /* Bold */
    background-color: #FFFFFF;
    color: var(--color-jti-green);
    border: none;
    border-radius: 20px;
    padding: 10px 20px;
    font-size: 0.95rem;
    cursor: pointer;
    margin-top: 10px;
    transition: transform 0.1s;
    align-self: flex-start;
}

.media-link-btn:active {
    transform: scale(0.95);
}

/* --- BOUTON BACK FLOTTANT (CORRIGÉ) --- */
.overlay-back-btn {
    position: absolute;
    right: 0;
    bottom: 50px; 
    transform: translateX(100%); /* Place le bloc juste à la frontière droite de l'overlay */
    display: flex;
    align-items: center;
    cursor: pointer;
    z-index: 25;
}

.back-circle {
    width: 50px;
    height: 50px;
    background-color: #FFFFFF;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    color: var(--color-jti-green); 
    font-size: 1.5rem;
    font-weight: bold;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
    transform: translateX(-25px); /* Coupe le cercle exactement en deux sur la frontière */
}

.back-text {
    font-family: "seitu-variable", sans-serif !important;
    font-weight: 400 !important; /* Regular */
    color: #000000;
    letter-spacing: 1px;
    transform: translateX(-15px); /* Rapproche le texte du cercle */
}

/* --- IMAGES & QR --- */
.detail-image-container {
    width: 100%;
    height: 25vh; 
    background-color: #e0e0e0;
    border-radius: 0 25px 25px 25px; 
    overflow: hidden;
    margin-bottom: 25px;
}

.detail-image-container img {
    width: 100%;
    height: 100%;
    object-fit: cover; 
    display: block;
}

.qr-panel-overlay {
    position: absolute;
    bottom: -300px; 
    right: 60px; 
    width: 130px; 
    background-color: #FFFFFF;
    border-radius: 25px 25px 0 0; 
    box-shadow: 0 -5px 15px rgba(0,0,0,0.15);
    z-index: 30; 
    transition: bottom 0.4s ease-in-out; 
}

.qr-panel-overlay.qr-active {
    bottom: 0; 
}

.qr-panel-content {
    padding: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.qr-image {
    width: 100%;
    height: auto;
    display: block;
}