/*
    Dynasty 8 — site web : feuille PROPRE AU SITE (le reste vient de luis_housing à l'identique : base.css, kit.css,
    explorateur.css, carte.css). Même DA : bleu nuit Hoffen en bandeau, filet or, fonds ivoire, vert Dynasty 8 en accent.

    - Page : base.css est écrit pour la NUI du jeu (fond transparent, pas de défilement, pas de sélection) → fond ivoire,
      défilement sur les pages de texte, sélection permise.
    - Vitrine : la coque de tablette est remplacée par un écran plein cadre sous le bandeau du site (js/coque.js) ; le
      bandeau de la tablette est masqué ; Itinéraire et « Ma position » masqués (pas de GPS hors du jeu).
    - Petits écrans : les filtres deviennent un panneau ouvert par le bouton « Filtres », fiche et logements sur une colonne.
*/

html, body { height: 100%; }
body {
    background: var(--h-fond);
    user-select: text;
    -webkit-user-select: text;
}
body.page-vitrine { display: flex; flex-direction: column; overflow: hidden; }
body.page-defile { height: auto; min-height: 100%; overflow: auto; }

/* ========================================================================== bandeau du site */

.site-bandeau {
    position: relative;
    z-index: 10;
    display: flex;
    flex: none;
    align-items: center;
    gap: 18px;
    min-height: 60px;
    padding: 0 22px;
    font-size: 15px;
    color: var(--hf-texte);
    background: var(--h-nuit);
    border-bottom: 1px solid var(--h-or);
}
.site-marque { display: flex; align-items: center; gap: 14px; color: inherit; text-decoration: none; }
.site-logo {
    height: 34px;
    color: var(--hf-texte);
    -webkit-mask-image: url('../img/logo/dynasty8_mono.svg');
    mask-image: url('../img/logo/dynasty8_mono.svg');
    mask-repeat: no-repeat;
    mask-position: center;
    mask-size: contain;
}
.site-filet { width: 1px; height: 26px; background: var(--hf-filet); }
.site-nom { font-weight: 600; letter-spacing: .16em; white-space: nowrap; }
.site-nav { display: flex; gap: 4px; margin-left: 6px; }
.site-nav a {
    padding: 8px 12px;
    font-weight: 500;
    color: var(--hf-texte-2);
    text-decoration: none;
    border-radius: var(--h-r2);
    white-space: nowrap;
}
.site-nav a:hover { color: var(--hf-texte); background: var(--hf-survol); }
.site-nav a:focus-visible { outline: 2px solid var(--h-or); outline-offset: 2px; }
.site-nav a[aria-current="page"] { color: var(--hf-texte); box-shadow: inset 0 -2px 0 var(--h-or); border-radius: 0; }
.site-espace { flex: 1; }
.site-maj { font-size: 12.5px; color: var(--hf-texte-3); white-space: nowrap; }

/* ========================================================================== vitrine (écran plein cadre) */

.site-vitrine { position: relative; flex: 1; min-height: 0; }
.site-chargement, .site-etat {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 15px;
    color: var(--h-texte-2);
}
.coque-site { position: absolute; inset: 0; }
.coque-site .coque-ecran {
    position: absolute;
    inset: 0;
    overflow: hidden;
    font-family: var(--h-f-texte);
    font-size: clamp(13px, calc(.45vw + 8px), 16px);
    line-height: 1.4;
    color: var(--h-texte);
    background: var(--h-fond);
}
.coque-site .vt { grid-template-rows: minmax(0, 1fr); }
.coque-site .vt-bandeau { display: none; }
.coque-site .vt-barre { flex-wrap: wrap; }

/* Pas de GPS hors du jeu : Itinéraire (fiche, immeuble) et « Ma position » (carte). */
.coque-site .btn:has(use[href="#i-itineraire"]),
.coque-site .vt-plan-outils .btn:has(use[href="#i-cible"]) { display: none; }

/* Modales du kit (formulaire « Être recontacté ») : au-dessus de la vitrine. */
.coque-site .k-voile { z-index: 1200; }
.site-contact { display: flex; flex-direction: column; gap: .8em; margin-top: .4em; }
.site-zone { height: auto; min-height: 5.5em; padding: .6em .8em; line-height: 1.4; resize: vertical; }
.site-contact-erreur { font-size: max(.86em, 9px); font-weight: 600; color: var(--h-erreur); }

.site-btn-filtres, .site-filtres-fermer { display: none; }

/* ========================================================================== pages de texte (Licences) */

.site-page { max-width: 940px; margin: 0 auto; padding: 44px 24px 72px; font-size: 16px; line-height: 1.45; }
.site-titre { margin: .25em 0 .3em; font-weight: 600; font-size: 2.2em; line-height: 1.15; color: var(--h-texte); }
.site-intro { max-width: 40em; margin: 0 0 1.8em; color: var(--h-texte-2); }
.site-licences { border-top: 2px solid var(--h-or); }
.site-licences .tableau td { padding-top: .95em; padding-bottom: .95em; }
.site-licences .montant { text-align: right; white-space: nowrap; }
.site-licences td.prix { font-family: var(--h-f-titre); font-weight: 600; font-size: 1.12em; font-variant-numeric: lining-nums tabular-nums; }
.site-licences td.caution { color: var(--h-texte-2); }
.site-licences td.absent { color: var(--h-texte-3); }
.site-licences tbody tr:hover td { background: var(--h-survol); }

/* ========================================================================== petits écrans */

@media (max-width: 860px) {
    .site-bandeau { flex-wrap: wrap; gap: 6px 14px; padding: 10px 14px; }
    .site-logo { height: 28px; }
    .site-nav { margin-left: 0; }
    .site-nav a { padding: 6px 9px; }
    .site-maj { display: none; }

    .coque-site .vt-corps { grid-template-columns: minmax(0, 1fr); }
    .coque-site .vt-filtres { display: none; position: absolute; inset: 0; z-index: 60; border-right: 0; }
    body.filtres-ouverts .coque-site .vt-filtres { display: flex; }
    .site-btn-filtres { display: inline-flex; margin-left: auto; }
    .site-filtres-fermer { display: inline-flex; flex: none; width: 100%; }

    .coque-site .vt-fiche-corps { grid-template-columns: minmax(0, 1fr); gap: 1.1em; padding: 1em; }
    /* Photos, puis nom et prix, puis les informations (et non les informations avant le prix). */
    .coque-site .vt-fiche-gauche { display: contents; }
    .coque-site .vt-fiche-gauche > .vt-galerie { order: 1; }
    .coque-site .vt-fiche-infos { order: 2; }
    .coque-site .vt-fiche-gauche > .vt-bloc { order: 3; }
    .coque-site .vt-immeuble-corps { padding: 1em; }
    .coque-site .vt-immeuble-tete { grid-template-columns: minmax(0, 1fr); }
    .coque-site .vt-unite { grid-template-columns: 4.2em minmax(0, 1fr) auto 1.2em; }
    .coque-site .vt-unite .vt-unite-photo,
    .coque-site .vt-unite .vt-pastille,
    .coque-site .vt-unite .vt-unite-aire,
    .coque-site .vt-unite .vt-unite-sans-photo { display: none; }
    .coque-site .vt-unite.occupee { grid-template-columns: 4.2em minmax(0, 1fr) auto; }

    .site-page { padding: 28px 14px 48px; font-size: 15px; }
    .site-licences .tableau th, .site-licences .tableau td { padding-left: .8em; padding-right: .8em; }
}
