:root {
    --mm-bg: #f7f2e9;
    --mm-bg-soft: #fbf8f2;
    --mm-surface: #ffffff;
    --mm-text: #1f2933;
    --mm-muted: #687385;
    --mm-primary: #123c55;
    --mm-primary-dark: #0b293b;
    --mm-accent: #c7964b;
    --mm-accent-soft: #f0dfc2;
    --mm-green-soft: #edf4e6;
    --mm-border: rgba(18, 60, 85, 0.12);
    --mm-shadow: 0 20px 55px rgba(18, 60, 85, 0.12);
    --mm-shadow-soft: 0 12px 35px rgba(18, 60, 85, 0.09);
    --mm-radius: 1.35rem;
}

html {
    scroll-behavior: smooth;
}

body {
    background:
        radial-gradient(circle at top left, rgba(199, 150, 75, 0.16), transparent 30rem),
        linear-gradient(180deg, var(--mm-bg-soft), var(--mm-bg));
    color: var(--mm-text);
    font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    line-height: 1.7;
}

h1,
h2,
h3,
.navbar-brand {
    letter-spacing: -0.035em;
}

a {
    color: var(--mm-primary);
}

a:hover {
    color: var(--mm-accent);
}

.skip-link {
    position: absolute;
    z-index: 2000;
    left: 1rem;
    top: 1rem;
    padding: 0.75rem 1rem;
    border-radius: 999px;
    background: var(--mm-primary);
    color: #fff;
}

/* Header premium */

.site-header {
    background: rgba(255, 255, 255, 0.86) !important;
    backdrop-filter: blur(18px);
    border-bottom: 1px solid rgba(18, 60, 85, 0.08);
    box-shadow: 0 10px 35px rgba(18, 60, 85, 0.08) !important;
}

.navbar {
    padding-top: 0.85rem;
    padding-bottom: 0.85rem;
}

.site-logo {
    width: min(260px, 58vw);
    height: auto;
}

.navbar .nav-link {
    position: relative;
    color: var(--mm-primary-dark);
    font-weight: 600;
    font-size: 0.95rem;
    padding-inline: 0.75rem !important;
}

.navbar .nav-link::after {
    content: "";
    position: absolute;
    left: 0.75rem;
    right: 0.75rem;
    bottom: 0.25rem;
    height: 2px;
    background: var(--mm-accent);
    transform: scaleX(0);
    transform-origin: center;
    transition: transform 0.22s ease;
}

.navbar .nav-link:hover::after,
.navbar .nav-link.active::after {
    transform: scaleX(1);
}

.navbar .dropdown-toggle::after {
    margin-left: 0.45rem;
}

.dropdown-menu {
    border: 1px solid var(--mm-border);
    border-radius: 1rem;
    box-shadow: var(--mm-shadow-soft);
    padding: 0.6rem;
}

.dropdown-item {
    border-radius: 0.7rem;
    font-weight: 500;
}

.dropdown-item:hover {
    background: var(--mm-bg);
}

/* Bootstrap buttons custom premium */

.btn {
    border-radius: 999px;
    font-weight: 700;
    padding: 0.7rem 1.15rem;
}

.btn-primary {
    background: linear-gradient(135deg, var(--mm-primary), #1b6587);
    border-color: var(--mm-primary);
    box-shadow: 0 12px 25px rgba(18, 60, 85, 0.22);
}

.btn-primary:hover {
    background: linear-gradient(135deg, var(--mm-primary-dark), var(--mm-primary));
    border-color: var(--mm-primary-dark);
    transform: translateY(-1px);
}

.btn-outline-primary {
    color: var(--mm-primary);
    border-color: rgba(18, 60, 85, 0.35);
    background: rgba(255, 255, 255, 0.7);
}

.btn-outline-primary:hover {
    background: var(--mm-primary);
    border-color: var(--mm-primary);
    color: #fff;
}

/* Hero */

.hero-section {
    position: relative;
    overflow: hidden;
    padding-top: clamp(3rem, 6vw, 6rem) !important;
    padding-bottom: clamp(3rem, 6vw, 6rem) !important;
}

.hero-section::before {
    content: "";
    position: absolute;
    inset: 0;
    background:
        linear-gradient(120deg, rgba(247, 242, 233, 0.96), rgba(247, 242, 233, 0.74)),
        url("../../images/location_bareges_65.JPG") center / cover no-repeat;
    z-index: -2;
}

.hero-section::after {
    content: "";
    position: absolute;
    width: 36rem;
    height: 36rem;
    right: -14rem;
    top: -12rem;
    border-radius: 999px;
    background: radial-gradient(circle, rgba(199, 150, 75, 0.26), transparent 65%);
    z-index: -1;
}

.hero-section .text-uppercase {
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    color: var(--mm-accent) !important;
    font-size: 0.78rem;
    letter-spacing: 0.18em;
}

.hero-section .text-uppercase::before,
.hero-section .text-uppercase::after {
    content: "";
    width: 2.4rem;
    height: 1px;
    background: currentColor;
    opacity: 0.55;
}

.hero-section h1 {
    max-width: 900px;
    margin-inline: auto;
    color: var(--mm-primary-dark);
    font-size: clamp(2.15rem, 4vw, 4.35rem);
    line-height: 1.05;
}

.hero-section .lead {
    max-width: 760px;
    margin-inline: auto;
    color: var(--mm-muted) !important;
    font-size: clamp(1.05rem, 1.5vw, 1.25rem);
}

/* Cards locations */

.property-card {
    border-radius: var(--mm-radius);
    background: rgba(255, 255, 255, 0.86);
    backdrop-filter: blur(14px);
    box-shadow: var(--mm-shadow) !important;
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.property-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 28px 70px rgba(18, 60, 85, 0.18) !important;
}

.property-card .card-body {
    padding: 1.75rem;
}

.property-card .card-title {
    color: var(--mm-primary-dark);
    font-weight: 800;
}

.property-card .card-title a {
    color: inherit;
}

.property-img {
    object-fit: cover;
    min-height: 270px;
    filter: saturate(1.04) contrast(1.02);
}

.reservation-note {
    color: var(--mm-accent);
}

/* Sections */

section {
    position: relative;
}

#plus,
#photo {
    background: var(--mm-bg-soft);
}

#plus h2,
#virtuel h2,
#constitution h2,
#photo h2,
#village h2 {
    color: var(--mm-primary-dark);
    font-weight: 850;
    letter-spacing: -0.04em;
}

#plus .rounded-4,
#village .rounded-4 {
    border-radius: var(--mm-radius) !important;
}

#plus img,
#village img {
    box-shadow: var(--mm-shadow-soft) !important;
}

.content-text {
    color: var(--mm-text);
    font-size: 1.05rem;
}

.content-text p:last-child {
    margin-bottom: 0;
}

.bg-texture {
    background:
        linear-gradient(135deg, rgba(255, 255, 255, 0.58), rgba(240, 223, 194, 0.35)),
        var(--mm-bg);
}

#constitution {
    border-block: 1px solid rgba(18, 60, 85, 0.08);
}

#constitution .container,
#village .container {
    max-width: 1120px;
}

.village-section {
    background:
        radial-gradient(circle at 15% 15%, rgba(255, 255, 255, 0.85), transparent 18rem),
        linear-gradient(135deg, #eef5e7, #dfeccd);
}

/* Galerie premium */

.gallery-link {
    display: block;
    position: relative;
    overflow: hidden;
    border-radius: 1rem;
    background: #000;
    box-shadow: var(--mm-shadow-soft);
}

.gallery-link::after {
    content: "Voir";
    position: absolute;
    inset: auto 0 0 0;
    padding: 2rem 1rem 0.8rem;
    color: #fff;
    font-weight: 700;
    font-size: 0.9rem;
    text-align: center;
    background: linear-gradient(180deg, transparent, rgba(0, 0, 0, 0.62));
    opacity: 0;
    transform: translateY(10px);
    transition: opacity 0.22s ease, transform 0.22s ease;
}

.gallery-link:hover::after {
    opacity: 1;
    transform: translateY(0);
}

.gallery-img {
    aspect-ratio: 4 / 3;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.35s ease, opacity 0.35s ease;
}

.gallery-link:hover .gallery-img {
    transform: scale(1.06);
    opacity: 0.88;
}

.gallery-modal-img {
    max-height: 78vh;
    object-fit: contain;
}

/* Footer */

.footer-section {
    background:
        linear-gradient(135deg, var(--mm-primary-dark), #061821) !important;
    border-top: 4px solid var(--mm-accent);
}

.footer-section a {
    text-decoration: none;
}

.footer-section a:hover {
    color: var(--mm-accent-soft) !important;
}

/* Bouton retour haut */

.btn-top {
    position: fixed;
    right: 1rem;
    bottom: 1rem;
    z-index: 1040;
    width: 3rem;
    height: 3rem;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 0;
    box-shadow: 0 14px 35px rgba(18, 60, 85, 0.28);
}

.btn-top.is-visible {
    display: inline-flex;
}

/* Responsive */

@media (max-width: 991.98px) {
    .site-header {
        backdrop-filter: none;
    }

    .navbar .nav-link::after {
        display: none;
    }

    .navbar-nav {
        padding-top: 1rem;
    }

    .navbar .btn {
        width: auto;
        margin-top: 0.5rem;
    }

    .property-card .row {
        display: block;
    }

    .property-img {
        min-height: 240px;
        max-height: 320px;
    }
}

@media (max-width: 575.98px) {
    .hero-section {
        text-align: center;
    }

    .property-card .card-body {
        padding: 1.35rem;
    }

    .content-text {
        font-size: 1rem;
    }
}

/* Correctif header plus compact */

.site-header {
    min-height: auto;
}

.navbar {
    padding-top: 0.35rem;
    padding-bottom: 0.35rem;
}

.site-logo {
    width: min(190px, 52vw);
    max-height: 74px;
    object-fit: contain;
}

.navbar .nav-link {
    padding-top: 0.45rem !important;
    padding-bottom: 0.45rem !important;
    font-size: 0.92rem;
}

.navbar .btn {
    padding: 0.48rem 0.9rem;
    font-size: 0.92rem;
}

/* Bouton mobile bien visible */

.navbar-toggler {
    border: 1px solid rgba(18, 60, 85, 0.28);
    border-radius: 0.85rem;
    padding: 0.45rem 0.6rem;
    background: rgba(255, 255, 255, 0.88);
    box-shadow: 0 8px 22px rgba(18, 60, 85, 0.12);
}

.navbar-toggler:focus {
    box-shadow: 0 0 0 0.2rem rgba(199, 150, 75, 0.25);
}

.navbar-toggler-icon {
    width: 1.35rem;
    height: 1.35rem;
    background-image: none;
    position: relative;
}

.navbar-toggler-icon::before,
.navbar-toggler-icon::after,
.navbar-toggler-icon {
    display: inline-block;
}

.navbar-toggler-icon::before,
.navbar-toggler-icon::after {
    content: "";
    position: absolute;
    left: 0;
    width: 100%;
    height: 2px;
    border-radius: 999px;
    background: var(--mm-primary-dark);
}

.navbar-toggler-icon::before {
    top: 0.35rem;
}

.navbar-toggler-icon::after {
    bottom: 0.35rem;
}

/* Mobile */

@media (max-width: 991.98px) {
    .navbar {
        padding-top: 0.45rem;
        padding-bottom: 0.45rem;
    }

    .site-logo {
        width: min(170px, 56vw);
        max-height: 48px;
    }

    .navbar-nav {
        padding-top: 0.75rem;
        padding-bottom: 0.75rem;
    }

    .navbar .nav-link {
        padding-top: 0.55rem !important;
        padding-bottom: 0.55rem !important;
    }
}

/* Header mobile/desktop plus propre et opaque */

.site-header {
    background: #fffaf2 !important;
    backdrop-filter: none !important;
    border-bottom: 1px solid rgba(18, 60, 85, 0.10);
    box-shadow: 0 8px 26px rgba(18, 60, 85, 0.10) !important;
}

.navbar {
    background: #fffaf2 !important;
    padding-top: 0.45rem;
    padding-bottom: 0.45rem;
}

.navbar > .container {
    background: transparent !important;
}

/* Logo plus visible */

.site-logo {
    width: min(250px, 58vw);
    max-height: 72px;
    object-fit: contain;
}

/* Liens du menu */

.navbar .nav-link {
    color: var(--mm-primary-dark);
    font-weight: 700;
}

.navbar .nav-link.active {
    color: var(--mm-primary);
}

/* Bouton hamburger propre */

.navbar-toggler {
    width: 46px;
    height: 42px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(18, 60, 85, 0.22);
    border-radius: 14px;
    padding: 0;
    background: #ffffff;
    box-shadow: 0 8px 20px rgba(18, 60, 85, 0.14);
}

.navbar-toggler:hover {
    background: #f7f2e9;
}

.navbar-toggler:focus {
    box-shadow: 0 0 0 0.2rem rgba(199, 150, 75, 0.24);
}

/* On remplace totalement l'icône Bootstrap par une icône maison plus nette */

.navbar-toggler-icon {
    position: relative;
    display: block;
    width: 22px;
    height: 2px;
    background: var(--mm-primary-dark);
    border: 0 !important;
    border-radius: 999px;
    background-image: none !important;
}

.navbar-toggler-icon::before,
.navbar-toggler-icon::after {
    content: "";
    position: absolute;
    left: 0;
    width: 22px;
    height: 2px;
    background: var(--mm-primary-dark);
    border-radius: 999px;
}

.navbar-toggler-icon::before {
    top: -7px;
}

.navbar-toggler-icon::after {
    top: 7px;
}

/* Menu déroulé mobile opaque */

.navbar-collapse {
    background: #fffaf2;
}

@media (max-width: 991.98px) {
    .navbar {
        padding-top: 0.45rem;
        padding-bottom: 0.45rem;
    }

    .site-logo {
        width: min(230px, 62vw);
        max-height: 66px;
    }

    .navbar-collapse {
        margin-top: 0.75rem;
        padding: 0.8rem;
        border: 1px solid rgba(18, 60, 85, 0.10);
        border-radius: 1.2rem;
        background: #fffaf2;
        box-shadow: 0 18px 45px rgba(18, 60, 85, 0.12);
    }

    .navbar-nav {
        gap: 0.15rem !important;
        padding-top: 0;
        padding-bottom: 0;
    }

    .navbar .nav-link {
        padding: 0.7rem 0.9rem !important;
        border-radius: 999px;
        color: var(--mm-primary-dark);
    }

    .navbar .nav-link.active {
        background: rgba(199, 150, 75, 0.16);
        color: var(--mm-primary-dark);
    }

    .navbar .btn {
        width: 100%;
        margin-top: 0.4rem;
        justify-content: center;
    }

    .dropdown-menu {
        background: #ffffff;
    }
}
/* Slider galerie dans la modal */

.gallery-modal-content {
    overflow: hidden;
    border: 0;
    border-radius: 1.25rem;
}

.gallery-modal-img {
    max-height: 78vh;
    min-height: 260px;
    object-fit: contain;
}

.gallery-nav {
    position: absolute;
    top: 50%;
    z-index: 5;
    width: 3rem;
    height: 3rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transform: translateY(-50%);
    border: 1px solid rgba(255, 255, 255, 0.28);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.16);
    color: #fff;
    font-size: 2.4rem;
    line-height: 1;
    font-weight: 300;
    backdrop-filter: blur(10px);
    transition: background 0.2s ease, transform 0.2s ease, opacity 0.2s ease;
}

.gallery-nav:hover {
    background: rgba(255, 255, 255, 0.28);
    transform: translateY(-50%) scale(1.06);
}

.gallery-nav-prev {
    left: 1rem;
}

.gallery-nav-next {
    right: 1rem;
}

@media (max-width: 575.98px) {
    .gallery-nav {
        width: 2.55rem;
        height: 2.55rem;
        font-size: 2rem;
    }

    .gallery-nav-prev {
        left: 0.5rem;
    }

    .gallery-nav-next {
        right: 0.5rem;
    }

    .gallery-modal-img {
        max-height: 72vh;
    }
}
/* Correction alignement vertical des flèches galerie */

.gallery-nav {
    line-height: 0.75;
    padding-bottom: 0.30rem;
}

@media (max-width: 575.98px) {
    .gallery-nav {
        padding-bottom: 0.22rem;
    }
}