/* ===== Boutons ===== */
.gs-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  height: 56px;
  padding: 0 30px;
  /* Rayon modéré par défaut : la pilule complète (999px) reste réservée au
     CTA principal (voir .gs-btn--primary), pour ne pas être le seul rayon
     du site. */
  border-radius: var(--gs-radius-xl);
  font-family: var(--gs-font-display);
  font-weight: 700;
  font-size: 1rem;
  white-space: nowrap;
  transition: transform 0.25s var(--gs-ease-snap), box-shadow 0.25s var(--gs-ease), background 0.25s var(--gs-ease);
  will-change: transform;
}

.gs-btn:hover {
  transform: translateY(-2px) scale(1.02);
}

.gs-btn:active {
  transform: translateY(0) scale(0.98);
}

.gs-btn--primary {
  /* Seul bouton encore en pilule complète : la signature "999px" est
     réservée au CTA principal, pas généralisée à tous les boutons.
     Aplat citron plutôt qu'un dégradé (cohérent avec l'app mobile) :
     texte NOIR, jamais blanc — le contraste sur cette couleur claire
     serait mauvais. */
  border-radius: var(--gs-radius-pill);
  background: var(--gs-primary);
  color: var(--gs-on-primary);
  font-size: 1.19rem;
  box-shadow: var(--gs-shadow-glow);
}

.gs-btn--primary:hover {
  background: var(--gs-primary-light);
}

.gs-btn--ghost {
  background: var(--gs-surface);
  color: var(--gs-text);
  border: 1.5px solid var(--gs-border);
}

.gs-btn--ghost:hover {
  border-color: var(--gs-secondary);
  color: var(--gs-secondary);
}

/* Lien souligné pour les CTA secondaires : casse la symétrie "deux pilules jumelles". */
.gs-btn--link {
  height: auto;
  padding: 0;
  border-radius: 0;
  background: none;
  color: var(--gs-text);
  text-decoration: underline;
  text-underline-offset: 4px;
  text-decoration-thickness: 1.5px;
  font-weight: 700;
}

.gs-btn--link:hover {
  color: var(--gs-secondary);
  transform: none;
}

.gs-btn--sm {
  height: 44px;
  padding: 0 20px;
  font-size: 0.9rem;
}

.gs-btn-icon {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

/* ===== Bouton App Store ===== */
.gs-store-btn {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  height: 58px;
  padding: 0 22px;
  border-radius: var(--gs-radius-lg);
  background: var(--gs-text);
  color: var(--gs-bg);
  box-shadow: var(--gs-shadow-elevated);
  transition: transform 0.25s var(--gs-ease-snap);
}

.gs-store-btn:hover {
  transform: translateY(-3px);
}

.gs-store-btn svg {
  width: 26px;
  height: 26px;
  flex-shrink: 0;
}

.gs-store-btn__text {
  display: flex;
  flex-direction: column;
  line-height: 1.15;
  text-align: left;
}

.gs-store-btn__eyebrow {
  font-size: 0.68rem;
  opacity: 0.75;
}

.gs-store-btn__name {
  font-family: var(--gs-font-display);
  font-weight: 700;
  font-size: 1.05rem;
}

.gs-store-btn[aria-disabled='true'] {
  opacity: 0.55;
  pointer-events: none;
}

/* ===== Navigation ===== */
.gs-nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  padding-top: 10px;
}

/*
 * Capsule flottante : transparente et pleine largeur en haut de page,
 * elle se contracte en pilule opaque au scroll (comportement calqué sur
 * wizzapp.com — même mécanique, mêmes timings, couleurs GoSortir).
 */
.gs-nav__capsule {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--gs-space-3);
  width: calc(100% - (var(--gs-space-3) * 2));
  max-width: var(--gs-container);
  margin-inline: auto;
  padding: 14px 16px 14px 22px;
  border-radius: var(--gs-radius-lg);
  /* Départ en noir totalement transparent (alpha 0) plutôt que le mot-clé
     "transparent" : la couleur interpole ainsi en pur fondu d'opacité,
     sans dérive de teinte au passage, pour un vrai effet de dégradé. */
  background: rgba(25, 26, 31, 0);
  border: 1px solid rgba(255, 255, 255, 0);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0);
  /*
   * Toutes les propriétés partagent la même durée et la même courbe :
   * le fondu du fond noir, l'apparition de l'ombre et le rapprochement
   * des éléments (via max-width) restent parfaitement synchronisés,
   * pour un mouvement perçu comme un seul geste fluide plutôt que
   * plusieurs animations qui se chevauchent.
   */
  transition: max-width 0.7s cubic-bezier(0.22, 1, 0.36, 1), border-radius 0.7s cubic-bezier(0.22, 1, 0.36, 1),
    padding 0.7s cubic-bezier(0.22, 1, 0.36, 1), background-color 0.7s cubic-bezier(0.22, 1, 0.36, 1),
    border-color 0.7s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.7s cubic-bezier(0.22, 1, 0.36, 1);
}

@media (min-width: 768px) {
  .gs-nav__capsule {
    padding-inline: var(--gs-space-4);
  }
}

.gs-nav.is-scrolled .gs-nav__capsule {
  max-width: min(calc(var(--gs-container) * 0.72), calc(100% - (var(--gs-space-3) * 2)));
  border-radius: var(--gs-radius-pill);
  background: rgb(25, 26, 31);
  border-color: rgba(255, 255, 255, 0.1);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
  padding: 10px 10px 10px 20px;
}

.gs-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--gs-font-display);
  font-weight: 700;
  font-size: 1.25rem;
  color: var(--gs-text);
  transition: color 0.7s cubic-bezier(0.22, 1, 0.36, 1);
}

.gs-nav.is-scrolled .gs-logo {
  color: #fff;
}

.gs-logo img {
  width: 36px;
  height: 36px;
}

.gs-nav__links {
  display: none;
  align-items: center;
  gap: var(--gs-space-4);
  font-weight: 600;
  font-size: 0.95rem;
}

.gs-nav__links a {
  position: relative;
  padding: 4px 0;
  color: var(--gs-text);
  transition: color 0.7s cubic-bezier(0.22, 1, 0.36, 1);
}

.gs-nav.is-scrolled .gs-nav__links a {
  color: rgba(255, 255, 255, 0.85);
}

.gs-nav__links a::after {
  content: '';
  position: absolute;
  left: 0;
  right: 100%;
  bottom: -2px;
  height: 2px;
  background: var(--gs-gradient-go);
  transition: right 0.25s var(--gs-ease);
}

.gs-nav__links a:hover::after {
  right: 0;
}

@media (min-width: 900px) {
  .gs-nav__links {
    display: flex;
  }
}

.gs-nav__actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.gs-nav__cta {
  display: none;
}

@media (min-width: 640px) {
  .gs-nav__cta {
    display: inline-flex;
  }
}

.gs-burger {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: var(--gs-radius-md);
  background: var(--gs-surface);
  border: 1.5px solid var(--gs-border);
  transition: background 0.7s cubic-bezier(0.22, 1, 0.36, 1), border-color 0.7s cubic-bezier(0.22, 1, 0.36, 1);
}

.gs-nav.is-scrolled .gs-burger {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.18);
}

/* ===== Bascule de thème ===== */
.gs-theme-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 44px;
  height: 44px;
  border-radius: var(--gs-radius-md);
  background: var(--gs-surface);
  border: 1.5px solid var(--gs-border);
  color: var(--gs-text);
  transition: background 0.7s cubic-bezier(0.22, 1, 0.36, 1), border-color 0.7s cubic-bezier(0.22, 1, 0.36, 1),
    color 0.2s var(--gs-ease);
}

.gs-theme-toggle:hover {
  color: var(--gs-primary);
}

.gs-nav.is-scrolled .gs-theme-toggle {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.18);
  color: #fff;
}

/* Une seule des deux icônes visible à la fois — celle qui décrit l'ACTION
   du bouton (tap le soleil pour aller au clair, la lune pour aller au sombre),
   pas le thème actuel. Cascade identique à celle des couleurs (variables.css) :
   sombre par défaut, clair si le système le dit ou si l'utilisateur l'a choisi. */
.gs-theme-toggle__icon--moon {
  display: none;
}

@media (prefers-color-scheme: light) {
  :root:not([data-theme='dark']) .gs-theme-toggle__icon--sun {
    display: none;
  }
  :root:not([data-theme='dark']) .gs-theme-toggle__icon--moon {
    display: block;
  }
}

:root[data-theme='light'] .gs-theme-toggle__icon--sun {
  display: none;
}

:root[data-theme='light'] .gs-theme-toggle__icon--moon {
  display: block;
}

:root[data-theme='dark'] .gs-theme-toggle__icon--sun {
  display: block;
}

:root[data-theme='dark'] .gs-theme-toggle__icon--moon {
  display: none;
}

.gs-theme-toggle--labelled {
  width: auto;
  height: 52px;
  padding: 0 18px;
  justify-content: flex-start;
  gap: 12px;
  font-family: var(--gs-font-display);
  font-weight: 700;
  font-size: 0.95rem;
}

/*
 * "Réduire les animations" coupe la transition de la capsule (durée à 0.001ms,
 * cf. base.css), ce qui fait passer les 2 états de la nav l'un à l'autre de
 * façon instantanée. On la ré-active volontairement ici : c'est un fondu de
 * couleur/forme sur place, sans déplacement ni parallax, donc sans risque
 * vestibulaire — le reste du site (reveals, tilt du téléphone...) continue
 * lui de respecter la préférence normalement.
 */
@media (prefers-reduced-motion: reduce) {
  .gs-nav__capsule,
  .gs-logo,
  .gs-nav__links a,
  .gs-burger {
    transition-duration: 0.7s !important;
  }
}

@media (min-width: 900px) {
  .gs-burger {
    display: none;
  }
}

.gs-burger__bar,
.gs-burger__bar::before,
.gs-burger__bar::after {
  content: '';
  display: block;
  width: 18px;
  height: 2px;
  background: var(--gs-text);
  border-radius: 2px;
  position: relative;
  transition: transform 0.25s var(--gs-ease), opacity 0.2s var(--gs-ease), background 0.7s cubic-bezier(0.22, 1, 0.36, 1);
}

.gs-nav.is-scrolled .gs-burger__bar,
.gs-nav.is-scrolled .gs-burger__bar::before,
.gs-nav.is-scrolled .gs-burger__bar::after {
  background: #fff;
}

.gs-burger__bar::before {
  position: absolute;
  top: -6px;
}

.gs-burger__bar::after {
  position: absolute;
  top: 6px;
}

.gs-nav.is-open .gs-burger__bar {
  background: transparent;
}

.gs-nav.is-open .gs-burger__bar::before {
  top: 0;
  transform: rotate(45deg);
}

.gs-nav.is-open .gs-burger__bar::after {
  top: 0;
  transform: rotate(-45deg);
}

.gs-mobile-menu {
  position: fixed;
  inset: 0;
  z-index: 90;
  background: var(--gs-bg);
  padding: calc(var(--gs-space-7)) var(--gs-space-3) var(--gs-space-5);
  display: flex;
  flex-direction: column;
  gap: var(--gs-space-2);
  transform: translateY(-100%);
  opacity: 0;
  visibility: hidden;
  transition: transform 0.4s var(--gs-ease), opacity 0.3s var(--gs-ease), visibility 0.4s;
  overflow: hidden;
}

.gs-mobile-menu::before {
  content: '';
  position: absolute;
  top: -25%;
  right: -30%;
  width: 70vw;
  height: 70vw;
  max-width: 480px;
  max-height: 480px;
  background: var(--gs-accent);
  opacity: 0.12;
  filter: blur(90px);
  border-radius: 50%;
  z-index: 0;
}

.gs-mobile-menu__logo {
  position: relative;
  z-index: 1;
  margin-bottom: var(--gs-space-3);
}

.gs-mobile-menu a {
  position: relative;
  z-index: 1;
}

.gs-nav.is-open .gs-mobile-menu {
  transform: translateY(0);
  opacity: 1;
  visibility: visible;
}

.gs-mobile-menu a {
  font-family: var(--gs-font-display);
  font-size: 1.6rem;
  font-weight: 700;
}

.gs-mobile-menu .gs-btn {
  margin-top: var(--gs-space-2);
  align-self: flex-start;
}

/* ===== Cards génériques ===== */
.gs-card {
  background: var(--gs-surface);
  border-radius: var(--gs-radius-xl);
  box-shadow: var(--gs-shadow-card);
}

/* ===== Chip / badge ===== */
.gs-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  border-radius: var(--gs-radius-pill);
  font-size: 0.8rem;
  font-weight: 700;
  background: var(--gs-surface-muted);
  color: var(--gs-text);
}

/* ===== Mockup iPhone ===== */
.gs-phone {
  position: relative;
  width: 280px;
  aspect-ratio: 280 / 570;
  border-radius: 46px;
  background: #0a0a0f;
  padding: 12px;
  box-shadow: var(--gs-shadow-elevated), 0 0 0 2px rgba(255, 255, 255, 0.06) inset;
}

.gs-phone__screen {
  position: relative;
  width: 100%;
  height: 100%;
  border-radius: 34px;
  overflow: hidden;
  background: var(--gs-bg);
}

.gs-phone__screen img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.gs-phone__notch {
  position: absolute;
  top: 12px;
  left: 50%;
  transform: translateX(-50%);
  width: 34%;
  height: 22px;
  border-radius: var(--gs-radius-pill);
  background: #0a0a0f;
  z-index: 2;
}

/* ===== Floating badge (hero) ===== */
.gs-float-card {
  position: absolute;
  background: var(--gs-surface);
  border-radius: var(--gs-radius-lg);
  box-shadow: var(--gs-shadow-elevated);
  padding: 12px 16px;
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.85rem;
  font-weight: 700;
}

.gs-float-card__icon {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.05rem;
  flex-shrink: 0;
}

.gs-avatar {
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--gs-surface);
  background: var(--gs-surface-muted);
}

.gs-avatar-stack {
  display: flex;
}

.gs-avatar-stack .gs-avatar {
  margin-left: -10px;
}

.gs-avatar-stack .gs-avatar:first-child {
  margin-left: 0;
}
