:root {
    --bg: #0b0d10;
    --panel: #14171c;
    --soft: #1d222a;
    --text: #f5f7fa;
    --muted: #a8b0bc;
    --red: #ef4444;
    --line: #2b313b;
    --max: 1180px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    background: var(--bg);
    color: var(--text);
    font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
    line-height: 1.6;
}

a {
    color: inherit;
    text-decoration: none;
}

img {
    display: block;
    max-width: 100%;
}

/* =========================================================
   BARRE DE NAVIGATION
========================================================= */

.topbar {
    position: sticky;
    top: 0;
    z-index: 50;
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 78px;
    padding: 0 max(24px, calc((100% - var(--max)) / 2));
    background: rgba(11, 13, 16, 0.92);
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    backdrop-filter: blur(18px);
}

/* Nouveau logo AMA Style */

.brand {
    display: flex;
    align-items: center;
    flex-shrink: 0;
    color: inherit;
    text-decoration: none;
}

.brand-logo-link {
    display: flex;
    align-items: center;
    width: 205px;
    height: 72px;
    overflow: hidden;
}

.brand-logo-image {
    position: static;
    display: block;
    width: 195px;
    height: 68px;
    max-width: 100%;
    object-fit: contain;
    object-position: center;
    transform: none;
    transition:
        transform 0.25s ease,
        filter 0.25s ease;
}

.brand-logo-link:hover .brand-logo-image {
    transform: scale(1.03);
    filter: brightness(1.1);
}

/* Ancien logo masqué au cas où il reste dans une page */

.brand-mark {
    display: none;
}

.topbar nav {
    display: flex;
    align-items: center;
    gap: 26px;
}

.topbar nav > a:not(.btn) {
    position: relative;
    color: #d5dae1;
    font-size: 14px;
    transition: color 0.2s ease;
}

.topbar nav > a:not(.btn):hover {
    color: #ffffff;
}

.topbar nav > a:not(.btn)::after {
    content: "";
    position: absolute;
    right: 0;
    bottom: -8px;
    left: 0;
    height: 2px;
    border-radius: 2px;
    background: var(--red);
    transform: scaleX(0);
    transition: transform 0.2s ease;
}

.topbar nav > a:not(.btn):hover::after {
    transform: scaleX(1);
}

.nav-toggle {
    display: none;
    padding: 5px;
    border: 0;
    background: none;
    color: white;
    font-size: 28px;
    cursor: pointer;
}

/* =========================================================
   BOUTONS
========================================================= */

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 50px;
    padding: 0 24px;
    border: 0;
    border-radius: 12px;
    background: var(--red);
    box-shadow: 0 12px 30px rgba(239, 68, 68, 0.18);
    color: white;
    font-weight: 800;
    cursor: pointer;
    transition:
        transform 0.2s ease,
        background 0.2s ease,
        box-shadow 0.2s ease;
}

.btn:hover {
    background: #f05252;
    box-shadow: 0 16px 36px rgba(239, 68, 68, 0.26);
    transform: translateY(-2px);
}

.btn.small {
    min-height: 42px;
    padding: 0 18px;
}

.btn.ghost {
    border: 1px solid var(--line);
    background: transparent;
    box-shadow: none;
}

.btn.ghost:hover {
    border-color: #515a67;
    background: rgba(255, 255, 255, 0.04);
}

/* =========================================================
   PAGE D’ACCUEIL
========================================================= */

.hero {
    position: relative;
    display: flex;
    align-items: center;
    min-height: 720px;
    overflow: hidden;
    background:
        radial-gradient(
            circle at 74% 30%,
            rgba(239, 68, 68, 0.25),
            transparent 28%
        ),
        linear-gradient(135deg, #0b0d10 25%, #1a1e25 100%);
}

.hero::after {
    content: "";
    position: absolute;
    right: -5%;
    bottom: -15%;
    width: 62%;
    height: 72%;
    border-radius: 50% 50% 10% 10%;
    background: linear-gradient(145deg, #303640, #0d0f13);
    box-shadow:
        inset 0 0 0 2px rgba(255, 255, 255, 0.05),
        0 50px 100px rgba(0, 0, 0, 0.5);
    transform: skewX(-10deg);
}

.hero-overlay {
    position: absolute;
    z-index: 1;
    inset: 0;
    background:
        linear-gradient(
            90deg,
            var(--bg) 0%,
            rgba(11, 13, 16, 0.82) 45%,
            rgba(11, 13, 16, 0.12) 100%
        );
}

.hero-content {
    position: relative;
    z-index: 2;
    width: min(var(--max), calc(100% - 48px));
    margin: auto;
}

.eyebrow,
.section-head span {
    display: inline-block;
    color: #ff7777;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 0.16em;
    text-transform: uppercase;
}

.hero h1,
.page-hero h1 {
    max-width: 850px;
    margin: 18px 0 24px;
    font-size: clamp(48px, 7vw, 92px);
    line-height: 1.02;
    letter-spacing: -0.045em;
}

.hero h1 em {
    color: #9199a5;
    font-style: normal;
}

.hero p {
    max-width: 650px;
    color: #c5cbd3;
    font-size: 19px;
}

.actions,
.row {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    margin-top: 28px;
}

/* =========================================================
   SECTIONS
========================================================= */

.section {
    width: min(var(--max), calc(100% - 48px));
    margin: auto;
    padding: 100px 0;
}

.section.dark {
    width: 100%;
    max-width: none;
    padding-right: max(24px, calc((100% - var(--max)) / 2));
    padding-left: max(24px, calc((100% - var(--max)) / 2));
    background: #101318;
}

.section-head {
    margin-bottom: 40px;
}

.section h2,
.page-hero h1 {
    letter-spacing: -0.035em;
}

.section h2 {
    margin: 10px 0;
    font-size: clamp(34px, 4vw, 56px);
    line-height: 1.08;
}

/* =========================================================
   CARTES
========================================================= */

.cards {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

.cards article,
.panel,
.booking-card {
    padding: 30px;
    border: 1px solid var(--line);
    border-radius: 22px;
    background: linear-gradient(180deg, var(--panel), #101318);
}

.cards article {
    min-height: 280px;
    transition:
        transform 0.25s ease,
        border-color 0.25s ease;
}

.cards article:hover {
    border-color: #474f5b;
    transform: translateY(-5px);
}

.cards h3 {
    font-size: 24px;
}

.cards p {
    color: var(--muted);
}

.icon {
    font-size: 34px;
}

/* =========================================================
   SECTION RÉSERVATION
========================================================= */

.split {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    align-items: center;
    gap: 70px;
}

.mock-phone {
    width: min(360px, 100%);
    margin: auto;
    padding: 30px;
    border: 10px solid #2c313a;
    border-radius: 38px;
    background: #090a0d;
    box-shadow: 0 40px 100px rgba(0, 0, 0, 0.45);
}

.phone-top {
    width: 90px;
    height: 7px;
    margin: -12px auto 26px;
    border-radius: 5px;
    background: #353b45;
}

.mini-event {
    margin-top: 12px;
    padding: 16px;
    border-left: 4px solid var(--red);
    border-radius: 12px;
    background: #171b21;
}

/* =========================================================
   STATISTIQUES
========================================================= */

.stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

.stats div {
    padding: 34px;
    border-top: 1px solid var(--line);
}

.stats b {
    display: block;
    font-size: 44px;
}

.stats span {
    color: var(--muted);
}

/* =========================================================
   EN-TÊTE DES PAGES
========================================================= */

.page-hero {
    padding:
        110px
        max(24px, calc((100% - var(--max)) / 2))
        80px;
    background:
        radial-gradient(
            circle at 80% 0,
            rgba(239, 68, 68, 0.16),
            transparent 30%
        ),
        #101318;
}

.page-hero.compact {
    padding-bottom: 55px;
}

.page-hero p {
    max-width: 680px;
    color: var(--muted);
}

/* =========================================================
   SERVICES
========================================================= */

.service-cards article {
    min-height: 350px;
}

.service-cards h2 {
    font-size: 34px;
}

.service-cards a {
    color: #ff7777;
    font-weight: 800;
}

/* =========================================================
   GALERIE
========================================================= */

.gallery {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 18px;
}

.gallery figure {
    margin: 0;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 18px;
    background: var(--panel);
}

.gallery img {
    width: 100%;
    aspect-ratio: 4 / 3;
    object-fit: cover;
}

.gallery figcaption {
    padding: 16px;
    font-weight: 700;
}

.empty {
    grid-column: 1 / -1;
    padding: 70px;
    border: 1px dashed var(--line);
    border-radius: 20px;
    color: var(--muted);
    text-align: center;
}

/* =========================================================
   CONTACT ET FORMULAIRES
========================================================= */

.contact-grid {
    display: grid;
    grid-template-columns: 0.8fr 1.2fr;
    gap: 60px;
}

label {
    display: grid;
    gap: 8px;
    margin-bottom: 16px;
    color: #d7dce4;
    font-weight: 700;
}

input,
select,
textarea {
    width: 100%;
    padding: 14px 15px;
    border: 1px solid #343b46;
    border-radius: 10px;
    outline: none;
    background: #0d1014;
    color: white;
    font: inherit;
}

input:focus,
select:focus,
textarea:focus {
    border-color: var(--red);
}

textarea {
    min-height: 130px;
    resize: vertical;
}

.success {
    margin-bottom: 18px;
    padding: 14px;
    border: 1px solid #23734f;
    border-radius: 10px;
    background: #123c2a;
}

/* =========================================================
   PORTAIL DE RÉSERVATION
========================================================= */

.booking-wrap {
    width: min(1000px, calc(100% - 30px));
    margin: 45px auto 100px;
}

.booking-card {
    padding: 34px;
}

.steps {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
    margin-bottom: 36px;
}

.steps span {
    padding: 10px;
    border-bottom: 3px solid #272d36;
    color: #77808d;
    font-size: 13px;
    font-weight: 800;
    text-align: center;
}

.steps span.active {
    border-color: var(--red);
    color: white;
}

.step {
    display: none;
}

.step.active {
    display: block;
}

.step h2 {
    font-size: 34px;
}

.vehicle-types {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
    margin: 24px 0;
}

.vehicle-types label {
    margin: 0;
}

.vehicle-types input {
    display: none;
}

.vehicle-types span {
    display: block;
    padding: 16px 10px;
    border: 1px solid #333a45;
    border-radius: 12px;
    background: #0d1014;
    text-align: center;
    cursor: pointer;
}

.vehicle-types input:checked + span {
    border-color: var(--red);
    background: rgba(239, 68, 68, 0.12);
}

.form-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
}

.vehicle-selector {
    margin: 20px 0;
    padding: 20px;
    border-radius: 20px;
    background: #090b0e;
}

.car-svg {
    width: 100%;
    max-height: 350px;
}

.car-body {
    fill: #2a3039;
    stroke: #59616d;
    stroke-width: 3;
}

.car-svg circle {
    fill: #08090b;
    stroke: #48505b;
    stroke-width: 20;
}

.window {
    fill: #26384b;
    stroke: #9ca7b4;
    stroke-width: 3;
    cursor: pointer;
    transition: 0.2s;
}

.window:hover,
.window.selected {
    fill: #ef4444;
    stroke: #ffb0b0;
}

.hint {
    color: var(--muted);
    text-align: center;
}

.service-choice {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

.check {
    display: flex;
    grid-column: 1 / -1;
    align-items: center;
    gap: 10px;
}

.check input {
    width: auto;
}

.estimate {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin: 25px 0;
}

.estimate > div {
    padding: 20px;
    border: 1px solid var(--line);
    border-radius: 14px;
    background: #0d1014;
}

.estimate small {
    display: block;
    color: var(--muted);
}

.estimate strong {
    font-size: 28px;
}

.slots {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    min-height: 60px;
    margin: 20px 0;
}

.slots button {
    padding: 12px 16px;
    border: 1px solid #3a424e;
    border-radius: 10px;
    background: #11151a;
    color: white;
    cursor: pointer;
}

.slots button.active {
    border-color: var(--red);
    background: var(--red);
}

.error-box {
    margin: 10px 0;
    color: #ff8e8e;
}

/* =========================================================
   CONFIRMATION
========================================================= */

.confirmation {
    min-height: 600px;
    text-align: center;
}

.success-icon {
    display: grid;
    place-items: center;
    width: 80px;
    height: 80px;
    margin: auto;
    border-radius: 50%;
    background: #1f7a50;
    font-size: 42px;
}

.summary {
    width: min(550px, 100%);
    margin: 30px auto;
    padding: 25px;
    border-radius: 18px;
    background: var(--panel);
    text-align: left;
}

/* =========================================================
   PIED DE PAGE
========================================================= */

footer {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 30px;
    padding:
        50px
        max(24px, calc((100% - var(--max)) / 2));
    border-top: 1px solid var(--line);
    color: var(--muted);
}

/* =========================================================
   BOUTON WHATSAPP FLOTTANT
========================================================= */

.whatsapp {
    position: fixed;
    right: 22px;
    bottom: 22px;
    z-index: 40;
    display: grid;
    place-items: center;
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: #25d366;
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.35);
    color: white;
    font-weight: 900;
}

/* =========================================================
   TABLETTES ET TÉLÉPHONES
========================================================= */

@media (max-width: 820px) {
    .topbar {
        height: 68px;
        padding-right: 18px;
        padding-left: 18px;
    }

    .brand-logo-link {
        width: 155px;
        height: 62px;
    }

    .brand-logo-image {
        position: static;
        width: 150px;
        height: 58px;
        max-width: 100%;
        object-fit: contain;
        transform: none;
    }

    .brand-logo-link:hover .brand-logo-image {
        transform: scale(1.02);
    }

    .nav-toggle {
        display: block;
    }

    .topbar nav {
        position: absolute;
        top: 68px;
        right: 0;
        left: 0;
        display: none;
        flex-direction: column;
        align-items: stretch;
        gap: 8px;
        padding: 20px;
        border-bottom: 1px solid var(--line);
        background: #0b0d10;
    }

    .topbar nav.open {
        display: flex;
    }

    .topbar nav > a {
        width: 100%;
        padding: 12px 14px;
        border-radius: 10px;
        text-align: center;
    }

    .topbar nav > a:not(.btn):hover {
        background: rgba(255, 255, 255, 0.04);
    }

    .topbar nav > a:not(.btn)::after {
        display: none;
    }

    .topbar nav .btn {
        margin-top: 6px;
    }

    .hero {
        min-height: 650px;
    }

    .hero::after {
        width: 90%;
        opacity: 0.5;
    }

    .hero h1 {
        font-size: 50px;
    }

    .cards,
    .stats,
    .gallery {
        grid-template-columns: 1fr;
    }

    .split,
    .contact-grid {
        grid-template-columns: 1fr;
    }

    .section {
        padding: 70px 0;
    }

    .vehicle-types {
        grid-template-columns: repeat(2, 1fr);
    }

    .form-grid,
    .service-choice,
    .estimate {
        grid-template-columns: 1fr;
    }

    .steps {
        overflow-x: auto;
    }

    .steps span {
        min-width: 120px;
    }

    footer {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .booking-card {
        padding: 22px;
    }
}

/* =========================================================
   PETITS TÉLÉPHONES
========================================================= */

@media (max-width: 480px) {
    .topbar {
        padding-right: 14px;
        padding-left: 14px;
    }

    .brand-logo-link {
        width: 135px;
        height: 58px;
    }

    .brand-logo-image {
        width: 130px;
        height: 54px;
    }

    .hero-content {
        width: calc(100% - 32px);
    }

    .hero h1 {
        font-size: 42px;
    }

    .hero p {
        font-size: 17px;
    }

    .section {
        width: calc(100% - 32px);
    }

    .actions .btn {
        width: 100%;
    }

    .page-hero {
        padding-right: 16px;
        padding-left: 16px;
    }

    .vehicle-types {
        grid-template-columns: 1fr 1fr;
    }

    .mock-phone {
        padding: 22px;
        border-width: 7px;
        border-radius: 30px;
    }

    .whatsapp {
        right: 16px;
        bottom: 16px;
        width: 52px;
        height: 52px;
    }
}
