@font-face {
  font-family: "Reika";
  src: url("/fonts/reika-regular.woff2") format("woff2");
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: "Chainprinter";
  src: url("/fonts/chainprinter-regular.woff2") format("woff2");
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: "Poppins";
  src: url("/fonts/poppins-400.woff2") format("woff2");
  font-weight: 400;
  font-display: swap;
}

:root {
  --plantes: #4a8a63;
  --plantes-fonce: #2f6245;
  --vent: #fef1ec;
  --pousse: 1.5s cubic-bezier(0.3, 0, 0.2, 1);
}

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

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

body {
  margin: 0;
  background: var(--vent);
  color: var(--plantes-fonce);
  font-family: "Poppins", "Helvetica Neue", Arial, sans-serif;
  font-size: 16px;
  line-height: 1.5;
}

/* Accueil */
.accueil {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  min-height: 100svh;
  padding: 32px max(24px, env(safe-area-inset-right)) 32px max(24px, env(safe-area-inset-left));
  text-align: center;
}

/* Logo */
.logo {
  position: relative;
  display: block;
  width: min(74vw, 70vh, 480px);
  margin: 0;
  aspect-ratio: 1080 / 550;
}

.logo img {
  display: block;
  width: 100%;
  height: auto;
}

.logo-pousse {
  position: absolute;
  top: 0;
  bottom: 0;
  overflow: hidden;
  background: var(--vent);
}

.logo-pousse img {
  position: absolute;
  top: 0.95%;
  max-width: none;
}

.logo-pousse-1 {
  left: 0;
  width: 40.3%;
}
.logo-pousse-1 img {
  left: 0;
  width: 248.14%;
}

.logo-pousse-2 {
  left: 40.3%;
  width: 20.7%;
}
.logo-pousse-2 img {
  left: -194.69%;
  width: 483.09%;
}

.logo-pousse-3 {
  left: 61%;
  width: 39%;
}
.logo-pousse-3 img {
  left: -156.41%;
  width: 256.41%;
}

.logo-fixe {
  aspect-ratio: auto;
}

/* Textes */
.accroche {
  margin: clamp(12px, 3vh, 28px) 0 0;
  color: var(--plantes);
  font-family: "Reika", Georgia, serif;
  font-size: clamp(30px, 5.4vw, 52px);
  font-weight: 400;
  line-height: 1.1;
}

.lieu {
  margin: 14px 0 0;
  color: var(--plantes);
  font-family: "Chainprinter", "Courier New", monospace;
  font-size: clamp(14px, 2vw, 18px);
  letter-spacing: 0.06em;
  line-height: 1.6;
}

/* Formulaire */
.alerte {
  width: 100%;
  max-width: 440px;
  margin: clamp(24px, 5vh, 44px) 0 0;
}

.alerte label {
  display: block;
}

.alerte-ligne {
  display: flex;
  gap: 8px;
  margin-top: 12px;
}

.alerte input[type="email"] {
  flex: 1 1 auto;
  min-width: 0;
  height: 48px;
  padding: 0 16px;
  border: 1.5px solid var(--plantes);
  border-radius: 24px;
  background: #fff;
  color: var(--plantes-fonce);
  font: inherit;
}

.alerte input[type="email"]::placeholder {
  color: #6c8f7b;
}

.alerte button {
  flex: 0 0 auto;
  height: 48px;
  padding: 0 22px;
  border: 0;
  border-radius: 24px;
  background: var(--plantes-fonce);
  color: var(--vent);
  font: inherit;
  cursor: pointer;
}

.alerte button:hover {
  background: #26503a;
}

.alerte button[disabled] {
  opacity: 0.6;
  cursor: default;
}

.alerte input[type="email"]:focus-visible,
.alerte button:focus-visible,
.logo-fixe:focus-visible {
  outline: 3px solid var(--plantes);
  outline-offset: 3px;
}

.alerte-piege {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.alerte-retour {
  min-height: 1.5em;
  margin: 10px 0 0;
}

.alerte-retour:empty {
  min-height: 0;
  margin: 0;
}

.alerte-note {
  margin: 10px 0 0;
  font-size: 13px;
}

/* Les plantes poussent */
@media (prefers-reduced-motion: no-preference) {
  .logo-pousse {
    clip-path: inset(100% 0 0 0);
    animation: pousse var(--pousse) both;
  }
  .logo-pousse-1 {
    animation-delay: 0.7s;
  }
  .logo-pousse-2 {
    animation-delay: 1.3s;
  }
  .logo-pousse-3 {
    animation-delay: 1.9s;
  }
}

@keyframes pousse {
  from { clip-path: inset(100% 0 0 0); }
  to { clip-path: inset(0 0 0 0); }
}

@media (max-width: 420px) {
  .alerte-ligne {
    flex-direction: column;
  }
}
