/* =========================================================
   SCÈNE — CARTE DU MONDE MÉDIÉVAL
   ========================================================= */
html, body {
    width: 100%;
    height: 100%;
    margin: 0;
    padding: 0;
    overflow: hidden;
}

/* ================= CONTENEUR DE SCÈNE ================= */

.scene-carte {
    height: 100vh;
    background: radial-gradient(circle at center, #1a120c, #050302);
    overflow: hidden;

    font-family: "Uncial Antiqua", serif;
    color: #e6dcc8;
}

.scene-carte .scene {
    position: relative;
    width: 100%;
    height: 100%;
}

/* ================= CADRE À RATIO FIXE =================
   L'image carte-medievale.png fait 1536x1024 (ratio 3:2). Sa largeur et
   sa hauteur sont calculées en JavaScript (voir Carte.cshtml) pour
   toujours conserver ce ratio, quelle que soit la taille de l'écran :
   l'image et les zones cliquables (positionnées en pourcentage à
   l'intérieur) restent donc alignées sur mobile comme sur desktop. */
.carte-cadre {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

/* ================= FOND DE CARTE ================= */

.carte-fond {
    position: absolute;
    inset: 0;

    background: url("/images/scene/carte-medievale.png") center center no-repeat;
    background-size: cover;

    filter:
        sepia(0.45)
        contrast(1.05);

    z-index: 1;
}

/* ================= ZONES CLIQUABLES ================= */

.carte-hotspot {
    position: absolute;
    border-radius: 50%;

    cursor: pointer;
    z-index: 5;

    /* DEBUG — À UTILISER POUR LE PLACEMENT */
    /*background: rgba(255, 0, 0, 0.25);*/
}

/* ================= HALO AU SURVOL ================= */

.carte-hotspot::before {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: 50%;

    background: radial-gradient(
        circle,
        rgba(255,220,160,0.35),
        transparent 70%
    );

    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
}

.carte-hotspot:hover::before {
    opacity: 1;
}

.carte-hotspot.admin::before {
    background: radial-gradient(
        circle,
        rgba(180,140,90,0.25),
        transparent 70%
    );
}


/* ================= LABELS DES LIEUX ================= */

.carte-label {
    position: absolute;
    bottom: -2.6rem;
    left: 50%;
    transform: translateX(-50%);

    padding: 0.35rem 0.7rem;

    background: linear-gradient(#1a120c, #0f0b08);
    border: 1px solid #6e4b2a;

    font-size: 0.8rem;
    letter-spacing: 1px;
    white-space: nowrap;
    color: #f2e6cf;

    box-shadow:
        0 0 12px rgba(0,0,0,0.9),
        inset 0 0 6px rgba(0,0,0,0.6);

    opacity: 0;
    transition: opacity 0.25s ease;
    pointer-events: none;
}

.carte-hotspot:hover .carte-label {
    opacity: 1;
}

/* ================= POSITIONS DES LIEUX =================
   Coordonnées en pourcentage du cadre (donc de l'image elle-même),
   calibrées visuellement sur carte-medievale.png — restent justes à
   toute taille d'écran grâce au cadre à ratio fixe ci-dessus. */

.carte-hotspot.monastere {
    top: 15.1%;
    left: 11.4%;
    width: 20.8%;
    height: 17.1%;
}

.carte-hotspot.monastere .carte-label {
    bottom: -2rem;
}

.carte-hotspot.bibliotheque {
    top: 32.7%;
    left: 35.2%;
    width: 12.4%;
    height: 14.2%;
}
.carte-hotspot.bibliotheque .carte-label {
    bottom: -2rem;
}

.carte-hotspot.copistes {
    top: 53.7%;
    left: 15.3%;
    width: 12.4%;
    height: 9.8%;
}
.carte-hotspot.copistes .carte-label{
    bottom: -2rem;
}

.carte-hotspot.chroniques {
    top: 68.8%;
    left: 19.5%;
    width: 17.6%;
    height: 12.2%;
}
.carte-hotspot.chroniques .carte-label{
    bottom: -2rem;

}

.carte-hotspot.chateau {
    top: 14.6%;
    left: 66.1%;
    width: 19.2%;
    height: 18.6%;
}
.carte-hotspot.chateau .carte-label{
    bottom: -2rem;

}

.carte-hotspot.combats {
    top: 53.2%;
    left: 57.0%;
    width: 13.7%;
    height: 11.2%;
}
.carte-hotspot.combats .carte-label{
    bottom: -2rem;
}

.carte-hotspot.jeux {
    top: 68.4%;
    left: 58.3%;
    width: 12.7%;
    height: 12.7%;
}
.carte-hotspot.jeux .carte-label{
    bottom: -2rem;

}
.carte-hotspot.curiosites {
    top: 44.9%;
    left: 77.8%;
    width: 12.7%;
    height: 10.3%;
}
.carte-hotspot.curiosites .carte-label{
    bottom: -2rem;
}
.carte-hotspot.admin {
    top: 8.0%;
    left: 45.0%;
    width: 8.0%;
    height: 8.0%;
}


/* ================= LÉGENDE (OPTIONNEL) ================= */

.carte-legende {
    position: absolute;
    bottom: 3%;
    width: 100%;
    text-align: center;

    font-size: 0.75rem;
    letter-spacing: 2px;
    opacity: 0.7;

    z-index: 6;
}
/* ================= TRANSITION SORTIE ================= */
/* ================= TRANSITION SORTIE — DOUCE ================= */

.scene-carte {
    opacity: 1;
    transform: scale(1);

    transition:
        opacity 1.2s ease-in-out,
        transform 1.5s cubic-bezier(0.22, 0.61, 0.36, 1);

    transform-origin: center center;
}

.scene-carte.transition-out {
    opacity: 0;
    transform: scale(1.035);
}



