/* ==========================================================================
   Vroom GPS — pages « porte » (DA 2026) : /go, /crew/invite/*, /ride/invite/*.
   Chargée APRÈS home.css (tokens, polices, boutons store).
   ========================================================================== */

html, body { min-height: 100%; }

body.gate {
    position: relative; isolation: isolate;
    min-height: 100vh; min-height: 100dvh;
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    padding: 24px var(--gutter) 32px;
    color: var(--ink);
    background-color: var(--violet-deep);
    background-image: url('../images/home/panorama-1280.webp');
    background-size: cover; background-position: 50% 70%;
}
@media (min-width: 901px) { body.gate { background-image: url('../images/home/panorama-2560.webp'); } }
body.gate::before {
    content: ''; position: absolute; inset: 0; z-index: -1;
    background: linear-gradient(180deg, rgba(74, 20, 140, 0.92) 0%, rgba(74, 20, 140, 0.78) 50%, rgba(22, 11, 46, 0.9) 100%);
}

.gate-brand { display: flex; justify-content: center; margin-bottom: 18px; }
.gate-brand img { width: 160px; height: auto; filter: drop-shadow(0 6px 16px rgba(0, 0, 0, 0.35)); }
.gate-brand small { display: block; text-align: center; color: var(--lavender); font-size: 12px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; margin-top: 6px; }

.gate-card {
    width: min(100%, 520px);
    background: var(--white);
    border-radius: var(--radius-lg);
    padding: 28px 24px 24px;
    box-shadow: 0 50px 100px -40px rgba(22, 11, 46, 0.9), 0 18px 36px -18px rgba(22, 11, 46, 0.6);
    text-align: center;
}
@media (min-width: 600px) { .gate-card { padding: 36px 36px 28px; } }

/* Partenaire (page /go) : logo + « proposé par » */
.gate-partner { display: none; align-items: center; justify-content: center; gap: 12px; margin-bottom: 18px; }
.gate-partner.show { display: flex; }
.gate-partner img { width: 56px; height: 56px; object-fit: contain; border-radius: 14px; background: var(--paper); padding: 4px; }
.gate-partner span { font-size: 14px; font-weight: 600; color: var(--ink-soft); text-align: left; }

.gate-kind { display: inline-block; margin-bottom: 10px; padding: 4px 12px; border-radius: 999px; background: var(--lavender-soft); color: var(--violet-deep); font-size: 12px; font-weight: 800; letter-spacing: 0.06em; text-transform: uppercase; }
.gate-kind:empty { display: none; }

.gate-card h1 { font-family: var(--font-display); font-weight: 400; font-size: clamp(24px, 6vw, 32px); line-height: 1.08; color: var(--violet-ink); margin-bottom: 10px; overflow-wrap: anywhere; }
.gate-card .gate-sub { color: var(--ink-soft); font-size: 15.5px; line-height: 1.55; margin-bottom: 20px; }

/* Aperçu carte (page /go) */
.gate-map { display: none; position: relative; height: 220px; border-radius: 20px; overflow: hidden; margin-bottom: 14px; background: var(--lavender-soft); border: 1px solid #E7DEF6; }
.gate-map.show { display: block; }
.gate-map .maplibregl-ctrl-attrib { font-size: 10px; }
.gate-facts { display: none; justify-content: center; gap: 10px; flex-wrap: wrap; margin-bottom: 18px; }
.gate-facts.show { display: flex; }
.gate-facts span { padding: 6px 12px; border-radius: 999px; background: var(--paper); border: 1px solid #E7DEF6; font-size: 13.5px; font-weight: 700; color: var(--violet-ink); }

/* Statut (ouverture, erreur) */
.status { display: none; align-items: center; justify-content: center; gap: 10px; padding: 12px 16px; border-radius: 14px; margin-bottom: 16px; font-size: 14px; font-weight: 600; line-height: 1.45; text-align: left; }
.status.show { display: flex; }
.status.info { background: var(--lavender-soft); color: var(--violet-deep); }
.status.success { background: #E8F5E9; color: #2E7D32; }
.status.error { background: #FDE8E8; color: #B42318; }
.spinner { flex-shrink: 0; width: 18px; height: 18px; border: 3px solid rgba(74, 20, 140, 0.15); border-top-color: var(--violet); border-radius: 50%; animation: gate-spin 0.9s linear infinite; }
@keyframes gate-spin { to { transform: rotate(360deg); } }

/* Boutons */
.buttons { display: flex; flex-direction: column; gap: 10px; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; height: 56px; padding: 0 22px; border-radius: 14px; border: 0; cursor: pointer; font-family: var(--font-body); font-size: 16px; font-weight: 800; text-decoration: none; transition: transform .15s ease, box-shadow .15s ease, background .15s ease; }
.btn-primary { background: var(--violet); color: var(--white); box-shadow: 0 14px 30px -14px rgba(103, 58, 183, 0.9); }
.btn-primary:hover { background: var(--violet-deep); transform: translateY(-1px); }
.btn-secondary { background: var(--paper); color: var(--violet-ink); border: 1px solid #E7DEF6; }
.btn-secondary:hover { background: var(--lavender-soft); }
.btn:disabled, .btn.disabled { opacity: 0.5; cursor: not-allowed; pointer-events: none; }

/* Astuce navigateur intégré (Messenger, Instagram…) */
.hint { display: none; margin-top: 16px; padding: 14px 16px; border-radius: 14px; background: #FFF4E5; color: #7A4B00; font-size: 14px; line-height: 1.5; text-align: left; }
.hint.show { display: block; }
.hint strong { display: block; margin-bottom: 4px; color: #5C3A00; }

/* Stores */
.gate-stores { margin-top: 22px; padding-top: 20px; border-top: 1px solid #EEE7F8; }
.gate-stores p { font-size: 13.5px; color: var(--ink-soft); margin-bottom: 12px; }
.gate-stores .stores { justify-content: center; }
.gate-stores .store-btn { height: 50px; }

.gate-disclaimer { margin-top: 16px; font-size: 12px; color: #9C94AD; line-height: 1.5; }
.gate-disclaimer:empty { display: none; }

.gate-footer { margin-top: 22px; text-align: center; color: rgba(255, 255, 255, 0.72); font-size: 12px; line-height: 1.6; }
.gate-footer a { color: rgba(255, 255, 255, 0.9); text-decoration: none; }
.gate-footer a:hover { text-decoration: underline; }
.gate-footer .gate-legal { color: rgba(255, 255, 255, 0.55); font-size: 11px; margin-top: 4px; }

/* Ordinateur : la carte prend plus de place */
@media (min-width: 900px) {
    .gate-card { width: min(100%, 640px); }
    .gate-map { height: 320px; }
}
