/* =========================================================
   SCOOT GOLF — Motion layer
   Micro-interactions sobres : apparition au scroll + feedback
   au survol/à l'appui. Un seul langage d'easing/durée sur tout
   le site. Respecte prefers-reduced-motion.
   ========================================================= */

/* --- Langage de mouvement commun --- */
:root {
    --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
    --dur-fast: 160ms;
    --dur-base: 220ms;
    --dur-reveal: 600ms;
}

/* --- Apparition au scroll (posée dynamiquement par motion.js) --- */
.reveal {
    opacity: 0;
    transform: translateY(16px);
    transition: opacity var(--dur-reveal) var(--ease-out),
                transform var(--dur-reveal) var(--ease-out);
    will-change: opacity, transform;
}
.reveal.is-visible {
    opacity: 1;
    transform: translateY(0);
}

/* --- Cartes produits / vidéos / info : lift au survol --- */
.model-card,
.video-card,
.info-box {
    transition: transform var(--dur-base) var(--ease-out),
                box-shadow var(--dur-base) var(--ease-out),
                border-color var(--dur-base) var(--ease-out);
}
.video-card:hover,
.info-box:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 24px rgba(0,0,0,0.08);
}
.video-card img,
.model-img {
    transition: transform var(--dur-base) var(--ease-out);
}
.video-card:hover img {
    transform: scale(1.03);
}

/* --- Boutons : lift + pression, sans jamais bloquer la lecture --- */
.btn-buy,
.btn-send,
.btn-submit,
.btn-nav-action {
    transition: background var(--dur-base) var(--ease-out),
                transform var(--dur-fast) var(--ease-out),
                box-shadow var(--dur-base) var(--ease-out);
}
.btn-buy:hover,
.btn-send:hover,
.btn-submit:hover,
.btn-nav-action:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 16px rgba(0,0,0,0.12);
}
.btn-buy:active,
.btn-send:active,
.btn-submit:active,
.btn-nav-action:active {
    transform: translateY(0) scale(0.97);
    box-shadow: 0 2px 6px rgba(0,0,0,0.1);
}

/* --- Liens de nav : petit soulignement animé plutôt qu'un simple changement de couleur --- */
.nav-links a:not(.btn-nav-action),
.back-link {
    position: relative;
}
.nav-links a:not(.btn-nav-action)::after,
.back-link::after {
    content: "";
    position: absolute;
    left: 0; bottom: -4px;
    width: 100%; height: 1px;
    background: currentColor;
    transform: scaleX(0);
    transform-origin: left;
    transition: transform var(--dur-base) var(--ease-out);
}
.nav-links a:not(.btn-nav-action):hover::after,
.back-link:hover::after {
    transform: scaleX(1);
}

/* --- Hero split screen : contenu qui respire légèrement au survol --- */
.hero-content {
    transition: transform var(--dur-base) var(--ease-out);
}
.hero-side:hover .hero-content {
    transform: translateY(-4px);
}

/* --- Champs de formulaire : focus doux --- */
input, select, textarea {
    transition: border-color var(--dur-base) var(--ease-out),
                box-shadow var(--dur-base) var(--ease-out);
}
input:focus, select:focus, textarea:focus {
    box-shadow: 0 0 0 3px rgba(197, 160, 89, 0.25);
    outline: none;
}

/* --- Prix qui se met à jour (page commande) : petit pulse d'état --- */
.price-pulse {
    animation: pricePulse var(--dur-reveal) var(--ease-out);
}
@keyframes pricePulse {
    0%   { transform: scale(1); }
    30%  { transform: scale(1.08); color: var(--gold-accent, #C5A059); }
    100% { transform: scale(1); }
}
#displayPrice, .total-price span {
    display: inline-block;
}

/* --- Entrée douce du hero au chargement (non scroll-linked) --- */
.hero-content,
.page-header h1,
.page-header p {
    animation: heroEnter var(--dur-reveal) var(--ease-out) both;
}
.page-header p { animation-delay: 80ms; }
@keyframes heroEnter {
    from { opacity: 0; transform: translateY(14px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* --- Sélecteur de langue --- */
.lang-switch {
    margin-left: 1.25rem;
    font-size: 0.75rem;
    letter-spacing: 0.5px;
    white-space: nowrap;
}
.lang-switch a {
    opacity: 0.55;
    transition: opacity var(--dur-base) var(--ease-out);
}
.lang-switch a:hover {
    opacity: 1;
}
.lang-switch .lang-current {
    font-weight: 700;
    opacity: 1;
    color: var(--gold-accent, #C5A059);
}
.lang-switch .lang-sep {
    opacity: 0.35;
    margin: 0 3px;
}
/* Sur la page commande (pas de nav), le switcher est repositionné en haut à droite du bloc */
.container > .lang-switch {
    display: block;
    text-align: right;
    margin: 0 0 1rem 0;
}
@media (max-width: 900px) {
    .lang-switch { margin-left: 0.5rem; }
}
@media (max-width: 768px) {
    nav { position: relative; }
    .lang-switch { order: 3; margin: 8px 0 0 0; }
}

/* --- Accessibilité : on respecte le choix de l'utilisateur --- */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.001ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.001ms !important;
        scroll-behavior: auto !important;
    }
    .reveal {
        opacity: 1 !important;
        transform: none !important;
    }
}
