/* Site public meetwandr.com, kit de marque « Window seat » (BRAND.md).
   Mêmes jetons que l'app : AppColors, PassColors, CornerRadius.
   Bricolage Grotesque : licence OFL 1.1, voir fonts/OFL.txt. */

@font-face {
  font-family: "Bricolage Grotesque";
  src: url("fonts/bricolage-grotesque-text.woff2") format("woff2");
  font-weight: 400 700;
  font-display: swap;
}

@font-face {
  font-family: "Bricolage Grotesque";
  src: url("fonts/bricolage-grotesque-extrabold.woff2") format("woff2");
  font-weight: 800;
  font-display: swap;
}

:root {
  color-scheme: light dark;

  /* Kit */
  --violet: #6B4EFF;
  --deep: #3B2A8F;
  --night: #2A1E66;
  --ground-on-deep: #1B1347;
  --ink: #14121F;
  --cream: #FBF9F5;
  --pink: #D9467A;
  --orange: #FF6A4D;
  --sun: #FFC24B;
  --gold: #FFE1A3;

  /* App, mode clair */
  --bg: var(--cream);
  --surface: #FFF;
  --text: var(--ink);
  --text-secondary: rgba(20, 18, 31, .66);
  --brand-text: #5B3FE8;
  --brand-soft: rgba(107, 78, 255, .10);
  --hairline: rgba(0, 0, 0, .06);
  --perforation: rgba(0, 0, 0, .18);
  --shadow: 0 6px 14px rgba(28, 22, 64, .07);
  --sky: var(--deep);
  --window-sky: var(--night);
  --window-ground: var(--ground-on-deep);
  --mark-footer: url("brand/wandr-mark-on-light.svg");
  --mark-sky: url("brand/wandr-mark-on-deep.svg");
  --phone-edge: var(--ink);
  --focus: var(--violet);
  --shield: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='%235B3FE8' fill-rule='evenodd' d='M12 2 4 5v6c0 5.2 3.4 9.5 8 11 4.6-1.5 8-5.8 8-11V5l-8-3Zm-1 13.6-3.6-3.6L8.8 10.6l2.2 2.2 4.2-4.2 1.4 1.4-5.6 5.6Z'/%3E%3C/svg%3E");

  --page: 72rem;
  --column: 46rem;
  --gutter: clamp(16px, 4vw, 32px);
  --radius-card: 24px;
  --cheatline: 18px;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0E0D14;
    --surface: #1B1A24;
    --text: #FFF;
    --text-secondary: rgba(255, 255, 255, .68);
    --brand-text: #A996FF;
    --brand-soft: rgba(139, 115, 255, .18);
    --hairline: rgba(255, 255, 255, .08);
    --perforation: rgba(255, 255, 255, .22);
    --shadow: 0 0 transparent;
    --sky: var(--night);
    --window-sky: var(--deep);
    --window-ground: var(--night);
    --mark-footer: url("brand/wandr-mark.svg");
    --mark-sky: url("brand/wandr-mark.svg");
    --phone-edge: #3A3947;
    --focus: #A996FF;
    --shield: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='%23A996FF' fill-rule='evenodd' d='M12 2 4 5v6c0 5.2 3.4 9.5 8 11 4.6-1.5 8-5.8 8-11V5l-8-3Zm-1 13.6-3.6-3.6L8.8 10.6l2.2 2.2 4.2-4.2 1.4 1.4-5.6 5.6Z'/%3E%3C/svg%3E");
  }
}

*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  color: var(--text);
  background: var(--bg);
  font: 400 1.0625rem/1.6 "Bricolage Grotesque", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  overflow-wrap: break-word;
}

h1, h2 {
  margin: 0;
  font-weight: 800;
  text-wrap: balance;
}

h1 {
  font-size: clamp(2.75rem, 7vw + 1rem, 4.5rem);
  line-height: 1;
  letter-spacing: -.03em;
}

h2 {
  margin-bottom: .6rem;
  font-size: 1.5rem;
  line-height: 1.15;
  letter-spacing: -.012em;
}

p, ul, ol { margin: 0 0 1em; }
p:last-child, ul:last-child, ol:last-child { margin-bottom: 0; }
strong { font-weight: 700; }

a {
  color: var(--brand-text);
  font-weight: 600;
  text-decoration-thickness: .08em;
  text-underline-offset: .18em;
}

a:hover { text-decoration-thickness: .14em; }

:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 3px;
  border-radius: 6px;
}

/* Bandeau du haut : même fond que l'accueil de l'app (PassColors.night) */

.sky {
  --focus: var(--sun);
  position: relative;
  overflow: hidden;
  padding: clamp(20px, 3vw, 32px) var(--gutter) calc(var(--cheatline) + 4.5rem);
  color: #FFF;
  background-color: var(--sky);
  background-image:
    radial-gradient(2px 2px at 54% 6%, #FFF 99%, transparent),
    radial-gradient(1.5px 1.5px at 68% 3%, rgba(255, 255, 255, .7) 99%, transparent),
    radial-gradient(2px 2px at 92% 7%, rgba(255, 255, 255, .85) 99%, transparent);
}

/* Les bandes du coucher de soleil, comme le liseré d'une carlingue */
.sky::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: var(--cheatline);
  background: linear-gradient(var(--violet) 33.33%, var(--pink) 33.33% 66.66%, var(--orange) 66.66%);
}

/* Le soleil sur l'horizon, pages sans grand hublot */
.doc .sky::before {
  content: "";
  position: absolute;
  z-index: 1;
  right: max(var(--gutter), calc((100% - var(--column)) / 2 - 11rem));
  bottom: 0;
  width: 7rem;
  height: 3.5rem;
  border-radius: 7rem 7rem 0 0;
  background: var(--sun);
}

.sky-inner {
  max-width: var(--column);
  margin-inline: auto;
}

.lockup {
  display: block;
  width: fit-content;
}

.lockup picture { display: block; }

.lockup img {
  display: block;
  width: auto;
  height: 44px;
}

.eyebrow {
  margin: clamp(32px, 5vw, 56px) 0 .75rem;
  color: var(--gold);
  font-size: .8125rem;
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: .14em;
  text-transform: uppercase;
}

.meta {
  max-width: 34em;
  margin: 1rem 0 0;
  color: rgba(255, 255, 255, .86);
  font-size: 1.125rem;
  line-height: 1.5;
}

nav {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 1.5rem;
}

nav a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 18px;
  border: 1px solid transparent;
  border-radius: 999px;
  color: #FFF;
  background: rgba(255, 255, 255, .14);
  font-size: 1rem;
  text-decoration: none;
}

nav a:hover { background: rgba(255, 255, 255, .24); }
nav a:focus-visible { border-radius: 999px; }

/* Contenu : cartes blanches sur crème, comme wandrCard */

main {
  width: 100%;
  max-width: calc(var(--column) + 2 * var(--gutter));
  margin: clamp(20px, 3vw, 32px) auto 0;
  padding-inline: var(--gutter);
  display: grid;
  gap: 16px;
}

section {
  min-width: 0;
  padding: clamp(20px, 3.5vw, 32px);
  border: 1px solid var(--hairline);
  border-radius: var(--radius-card);
  background: var(--surface);
  box-shadow: var(--shadow);
}

ul { padding-left: 1.25em; }
li + li { margin-top: .75em; }
li::marker { color: var(--brand-text); }

ol {
  padding: 0;
  list-style: none;
  counter-reset: step;
}

ol li {
  position: relative;
  min-height: 2rem;
  padding: .15rem 0 0 2.75rem;
  counter-increment: step;
}

ol li::before {
  content: counter(step);
  position: absolute;
  left: 0;
  top: 0;
  width: 2rem;
  height: 2rem;
  border-radius: 50%;
  color: var(--brand-text);
  background: var(--brand-soft);
  font-weight: 700;
  line-height: 2rem;
  text-align: center;
}

/* 80 px en bas : le cadre de la pastille « Powered by Netlify » (fixe, 64 px de haut)
   ne doit pas recouvrir les derniers liens, déjà au plus haut en fin de page. */
footer {
  width: 100%;
  max-width: calc(var(--column) + 2 * var(--gutter));
  margin: auto auto 0;
  padding: clamp(28px, 4vw, 40px) var(--gutter) 80px;
  color: var(--text-secondary);
  font-size: .9375rem;
}

footer::before {
  content: "";
  display: block;
  width: 26px;
  height: 40px;
  margin-bottom: .75rem;
  background: var(--mark-footer) center / contain no-repeat;
}

footer a {
  display: inline-block;
  padding-block: .25em;
}

/* Accueil */

.home .sky { padding-bottom: calc(var(--cheatline) + clamp(32px, 5vw, 56px)); }

.home .sky-inner {
  max-width: var(--page);
  display: grid;
  grid-template-areas:
    "lockup"
    "window"
    "copy";
}

.home .lockup { grid-area: lockup; }
.hero-copy { grid-area: copy; }
.home .eyebrow { margin-top: 0; }

.window {
  grid-area: window;
  justify-self: center;
  display: block;
  width: auto;
  height: clamp(220px, 62vw, 300px);
  margin-block: clamp(24px, 6vw, 40px);
}

.window-sky { fill: var(--window-sky); }
.window-ground { fill: var(--window-ground); }

.home main,
.home footer { max-width: calc(var(--page) + 2 * var(--gutter)); }

.home h1 { font-size: clamp(3.25rem, 9vw + 1rem, 6.75rem); line-height: .96; }
.home h2 { font-size: clamp(1.625rem, 1.2rem + 1vw, 2rem); }

.feature {
  display: flex;
  flex-direction: column;
  padding-bottom: 0;
  overflow: hidden;
  border: 0;
  box-shadow: inset 0 0 0 1px var(--hairline), var(--shadow);
}

.feature p { margin-bottom: 0; }

.shot {
  display: block;
  align-self: center;
  width: min(100%, 300px);
  margin-top: auto;
  padding-top: 24px;
}

.shot img {
  display: block;
  width: 100%;
  height: auto;
  border: 7px solid var(--phone-edge);
  border-bottom: 0;
  border-radius: 40px 40px 0 0;
}

.feature-brand {
  --phone-edge: var(--ink);
  box-shadow: var(--shadow);
  color: #FFF;
  background: var(--violet);
}

.availability {
  --focus: var(--sun);
  --stub: 8.5rem;
  position: relative;
  padding-bottom: calc(var(--stub) + 20px);
  border: 0;
  box-shadow: none;
  color: #FFF;
  background: var(--sky);
  -webkit-mask:
    radial-gradient(circle at 0 calc(100% - var(--stub)), transparent 11px, #000 11.5px) left / 51% 100% no-repeat,
    radial-gradient(circle at 100% calc(100% - var(--stub)), transparent 11px, #000 11.5px) right / 51% 100% no-repeat;
  mask:
    radial-gradient(circle at 0 calc(100% - var(--stub)), transparent 11px, #000 11.5px) left / 51% 100% no-repeat,
    radial-gradient(circle at 100% calc(100% - var(--stub)), transparent 11px, #000 11.5px) right / 51% 100% no-repeat;
}

.availability a { color: #FFF; }

.availability::before {
  content: "";
  position: absolute;
  inset: auto 18px var(--stub);
  border-top: 2px dashed rgba(255, 255, 255, .4);
}

.availability::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: var(--stub);
  background: var(--mark-sky) center / auto 68% no-repeat;
}

.safety h2::before {
  content: "";
  display: block;
  width: 3rem;
  height: 3rem;
  margin-bottom: .875rem;
  border-radius: 50%;
  background: var(--shield) center / 1.625rem no-repeat, var(--brand-soft);
}

/* Lien partagé : la carte d'embarquement de l'app (BoardingPassTicket) */

.invite .sky { padding-bottom: calc(var(--cheatline) + clamp(32px, 6vw, 64px)); }
.invite .sky-inner { max-width: var(--page); }

.pass {
  --focus: var(--brand-text);
  --pass-padding: clamp(20px, 4vw, 32px);
  max-width: 34rem;
  margin-top: clamp(24px, 4vw, 40px);
  padding: var(--pass-padding);
  border-radius: var(--radius-card);
  color: var(--text);
  background: var(--surface);
}

.pass .eyebrow {
  margin-top: 0;
  color: var(--brand-text);
}

.pass h1 { font-size: clamp(2.25rem, 4vw + 1.25rem, 3.25rem); }

.pass .meta { color: var(--text-secondary); }

.actions {
  position: relative;
  margin: 1.5rem calc(-1 * var(--pass-padding)) 0;
  padding: 1.5rem var(--pass-padding) 0;
  border-top: 2px dashed var(--perforation);
}

.actions::before,
.actions::after {
  content: "";
  position: absolute;
  top: -12px;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--sky);
}

.actions::before { left: -11px; }
.actions::after { right: -11px; }

.button {
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 56px;
  padding: 0 22px;
  border-radius: 18px;
  color: #FFF;
  background: var(--violet);
  font-size: 1.0625rem;
  font-weight: 700;
  text-decoration: none;
}

.button:hover { background: #5B3FE8; }
.button:focus-visible { border-radius: 18px; }

.hidden,
[hidden] { display: none !important; }

/* Bouton secondaire de la page d'un lien partagé */
.button-quiet {
  margin-top: 10px;
  color: var(--brand-text);
  background: var(--brand-soft);
}

.button-quiet:hover { background: var(--brand-soft); }

.nothing {
  margin: 12px 0 0;
  color: var(--text-secondary);
  font-size: .9375rem;
}

/* Accueil : le bouton du bandeau et la partie « Get Wandr » */
.hero-button {
  display: inline-flex;
  margin-top: 1.25rem;
  color: var(--violet);
  background: #FFF;
}

.hero-button:hover { background: #F5F4FA; }

.store-soon {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  margin: 0;
  padding: 0 18px;
  border-radius: 999px;
  color: var(--sun);
  background: rgba(255, 255, 255, .14);
  font-weight: 700;
}

.store-button {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  min-height: 56px;
  padding: 0 22px;
  border-radius: 18px;
  color: var(--sky);
  background: #FFF;
  font-size: 1.0625rem;
  font-weight: 700;
  text-decoration: none;
}

.availability a.store-button { color: #2A1E66; }

.invite main,
.invite footer { max-width: calc(var(--page) + 2 * var(--gutter)); }

/* Grands écrans */

@media (min-width: 640px) {
  .availability {
    --stub: clamp(8rem, 16vw, 11rem);
    padding-right: calc(var(--stub) + clamp(20px, 3.5vw, 32px));
    padding-bottom: clamp(20px, 3.5vw, 32px);
    -webkit-mask:
      radial-gradient(circle at calc(100% - var(--stub)) 0, transparent 11px, #000 11.5px) top / 100% 51% no-repeat,
      radial-gradient(circle at calc(100% - var(--stub)) 100%, transparent 11px, #000 11.5px) bottom / 100% 51% no-repeat;
    mask:
      radial-gradient(circle at calc(100% - var(--stub)) 0, transparent 11px, #000 11.5px) top / 100% 51% no-repeat,
      radial-gradient(circle at calc(100% - var(--stub)) 100%, transparent 11px, #000 11.5px) bottom / 100% 51% no-repeat;
  }

  .availability::before {
    inset: 18px var(--stub) 18px auto;
    border-top: 0;
    border-left: 2px dashed rgba(255, 255, 255, .4);
  }

  .availability::after {
    inset: 0 0 0 auto;
    width: var(--stub);
    height: auto;
    background-size: auto min(68%, 7.5rem);
  }

  .feature {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(220px, 280px);
    grid-template-rows: 1fr auto auto 1fr;
    column-gap: clamp(24px, 4vw, 48px);
  }

  .feature h2 { grid-column: 1; grid-row: 2; }
  .feature p { grid-column: 1; grid-row: 3; }

  .shot {
    grid-column: 2;
    grid-row: 1 / -1;
    width: 100%;
    margin-top: 0;
    padding-top: 0;
  }
}

@media (min-width: 900px) {
  :root { --cheatline: 21px; }

  .sky {
    background-image:
      radial-gradient(2px 2px at 3.5% 8%, #FFF 99%, transparent),
      radial-gradient(1.5px 1.5px at 33% 5%, rgba(255, 255, 255, .7) 99%, transparent),
      radial-gradient(2px 2px at 54% 6%, #FFF 99%, transparent),
      radial-gradient(1.5px 1.5px at 62% 34%, rgba(255, 255, 255, .6) 99%, transparent),
      radial-gradient(1.5px 1.5px at 68% 3%, rgba(255, 255, 255, .7) 99%, transparent),
      radial-gradient(2px 2px at 92% 7%, rgba(255, 255, 255, .85) 99%, transparent),
      radial-gradient(1.5px 1.5px at 96% 46%, rgba(255, 255, 255, .6) 99%, transparent);
  }

  .home .sky-inner {
    grid-template-columns: minmax(0, 1fr) auto;
    grid-template-rows: auto 1fr;
    grid-template-areas:
      "lockup window"
      "copy window";
    column-gap: clamp(32px, 5vw, 80px);
  }

  .home .eyebrow { margin-top: clamp(48px, 6vw, 72px); }

  .window {
    align-self: center;
    height: clamp(380px, 38vw, 520px);
    margin-block: 0;
  }

  .doc .sky { padding-bottom: calc(var(--cheatline) + 3.5rem); }

  .invite .sky-inner {
    display: grid;
    grid-template-columns: minmax(0, 34rem) 1fr;
    grid-template-rows: auto 1fr;
    column-gap: clamp(32px, 5vw, 80px);
  }

  .invite .lockup,
  .invite .pass { grid-column: 1; }

  .invite .pass { align-self: start; }

  .invite .sky-inner::after {
    content: "";
    grid-column: 2;
    grid-row: 1 / span 2;
    align-self: center;
    justify-self: center;
    width: 100%;
    max-width: 18.5rem;
    aspect-ratio: 52 / 80;
    background: var(--mark-sky) center / contain no-repeat;
  }

  .invite main { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (min-width: 1024px) {
  .home main { grid-template-columns: repeat(12, minmax(0, 1fr)); }

  .feature {
    grid-column: span 4;
    display: flex;
  }

  .shot {
    width: min(100%, 300px);
    margin-top: auto;
    padding-top: 28px;
  }

  .home .safety { grid-column: span 5; }
  .home .availability { grid-column: span 7; }
}

/* Animations : uniquement si la personne n'a pas demandé à les réduire */

@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }

  nav a, a.button { transition: background-color .15s ease; }
  .button:active { transform: scale(.98); }

  .window-frame {
    transform-box: fill-box;
    transform-origin: center;
    animation: window-frame .35s cubic-bezier(.22, 1, .36, 1) both;
  }

  .window-blind { animation: window-blind .65s cubic-bezier(.65, 0, .35, 1) .3s both; }
  .window-sun { animation: window-sun .75s cubic-bezier(.22, 1, .36, 1) .6s both; }
  .window-stars { animation: window-fade .45s linear .8s both; }
  .window-reflect { animation: window-fade .45s linear 1s both; }
  .window-wing { animation: window-wing .5s cubic-bezier(.22, 1, .36, 1) .9s both; }

  .doc .sky::before { animation: sun-rise .75s cubic-bezier(.22, 1, .36, 1) .1s both; }

  @keyframes window-frame { from { opacity: 0; transform: scale(.94); } to { opacity: 1; transform: scale(1); } }
  @keyframes window-blind { from { transform: translateY(0); } to { transform: translateY(-59px); } }
  @keyframes window-sun { from { opacity: .4; transform: translateY(15px); } to { opacity: 1; transform: translateY(0); } }
  @keyframes window-fade { from { opacity: 0; } to { opacity: 1; } }
  @keyframes window-wing { from { transform: translateX(-18px); } to { transform: translateX(0); } }
  @keyframes sun-rise { from { transform: translateY(100%); } to { transform: translateY(0); } }
}

@media (forced-colors: active) {
  section, .pass { border: 1px solid CanvasText; }
  .availability { -webkit-mask: none; mask: none; }
  .sky::before, .sky::after, .actions::before, .actions::after, .safety h2::before, .availability::before, .availability::after, footer::before { display: none; }
}

@media print {
  :root {
    color-scheme: light;
    --bg: #FFF;
    --surface: #FFF;
    --text: #000;
    --text-secondary: #000;
    --brand-text: #000;
    --hairline: transparent;
    --shadow: 0 0 transparent;
  }

  .sky { padding: 0 0 12pt; color: #000; background: none; }
  .sky::before, .sky::after, .lockup, .window, .invite .sky-inner::after, footer::before, .safety h2::before, .availability::before, .availability::after { display: none; }
  .eyebrow, .meta, nav a { color: #000; }
  nav a { min-height: 0; padding: 0; background: none; }
  section { padding: 0; border: 0; border-radius: 0; box-shadow: none; }
  .availability { padding: 0; color: #000; background: none; -webkit-mask: none; mask: none; }
  .availability a { color: #000; }
}
