/* =========================================================
   Monelio — Landing page styles
   Palette respectant un contraste minimum AA (RGAA / WCAG 2.1) :
   - Texte de taille normale >= 4.5:1
   - Texte large / gras >= 3:1
   - Composants d'UI (bordures, focus) >= 3:1
   ========================================================= */

:root {
  /* Couleurs de marque (usage décoratif / grands éléments) */
  --blue: #2F80ED;
  --yellow: #F2C94C;
  --yellow-soft: #FDF4DC;
  --brown: #A65A2E;
  --beige: #F7E9D2;
  --white: #FFFFFF;

  /* Variantes accessibles pour le texte (contraste vérifié) */
  --blue-dark: #1E63C9;      /* texte/boutons bleus : 5.7:1 sur blanc */
  --brown-dark: #8A491F;     /* texte marron : 6.9:1 sur blanc, 5.7:1 sur beige */
  --green-dark: #177A4E;     /* messages de succès : 5.3:1 sur blanc */
  --red-dark: #C23B34;       /* messages d'erreur : contrôlé ci-dessous */
  --blue-light: #EAF2FE;

  --ink: #1F2A3C;
  --ink-soft: #5B6577;       /* texte secondaire : 5.9:1 sur blanc, 4.9:1 sur beige */

  --border-subtle: #E7E1D3;  /* décoratif uniquement, jamais seul porteur d'info */
  --border-strong: #8A93A8;  /* bordures fonctionnelles : >=3:1 sur blanc */
  --focus-color: #14356E;    /* anneau de focus, contraste élevé */

  --radius-sm: 10px;
  --radius-md: 18px;
  --radius-lg: 28px;
  --radius-xl: 40px;
  --shadow-soft: 0 20px 45px -20px rgba(47, 128, 237, 0.35);
  --shadow-card: 0 10px 30px -12px rgba(31, 42, 60, 0.12);
  --font-display: 'Fredoka', 'Poppins', sans-serif;
  --font-body: 'Poppins', sans-serif;
}

* { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
}

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img { max-width: 100%; display: block; }

a { text-decoration: none; color: inherit; }

ul { list-style: none; margin: 0; padding: 0; }

button { font: inherit; }

/* ===== Accessibilité : focus visible partout ===== */

a:focus-visible,
button:focus-visible,
input:focus-visible {
  outline: 3px solid var(--focus-color);
  outline-offset: 3px;
  border-radius: 6px;
}

.site-footer :focus-visible,
.badge-soon:focus-visible {
  outline-color: var(--yellow);
}

/* ===== Lien d'évitement ===== */

.skip-link {
  position: absolute;
  top: -60px;
  left: 16px;
  z-index: 1000;
  background: var(--ink);
  color: var(--white);
  padding: 12px 20px;
  border-radius: 0 0 10px 10px;
  font-weight: 600;
  transition: top 0.2s ease;
}

.skip-link:focus {
  top: 0;
}

.container {
  width: 100%;
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 24px;
}

.sr-only {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap; border: 0;
}

.eyebrow {
  display: inline-block;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 14px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--blue-dark);
  background: var(--blue-light);
  padding: 6px 16px;
  border-radius: 999px;
  margin: 0 0 16px;
}

.eyebrow.on-dark { color: var(--yellow); background: rgba(255,255,255,0.12); }
.eyebrow.on-beige { background: rgba(255,255,255,0.6); }

.eyebrow.center { display: block; width: max-content; margin-left: auto; margin-right: auto; }

.section-title {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(28px, 4vw, 42px);
  line-height: 1.15;
  margin: 0 0 18px;
  color: var(--ink);
}

.section-title.center { text-align: center; max-width: 700px; margin-left: auto; margin-right: auto; }

.section-sub {
  font-size: 17px;
  line-height: 1.7;
  color: var(--ink-soft);
  max-width: 560px;
  margin: 0;
}

.section-sub.center { text-align: center; max-width: 620px; margin-left: auto; margin-right: auto; }

section { padding: 96px 0; position: relative; }

/* Ruban de marque en haut de page */

.brand-ribbon {
  height: 5px;
  width: 100%;
  background: linear-gradient(90deg, var(--blue) 0%, var(--blue) 40%, var(--yellow) 65%, var(--brown) 85%, var(--beige) 100%);
}

/* ===== Buttons ===== */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 16px;
  padding: 15px 28px;
  border-radius: 999px;
  border: none;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
  white-space: nowrap;
}

.btn-primary {
  background: var(--blue-dark);
  color: var(--white);
  box-shadow: var(--shadow-soft);
}

.btn-primary:hover { transform: translateY(-2px); background: #164f9f; }

.btn-ghost {
  background: transparent;
  color: var(--ink);
  border: 2px solid var(--border-strong);
}

.btn-ghost:hover { border-color: var(--blue-dark); color: var(--blue-dark); transform: translateY(-2px); }

.btn-appstore {
  background: var(--ink);
  color: var(--white);
  text-align: left;
  padding: 12px 24px;
}

.btn-appstore:hover { transform: translateY(-2px); background: #0f1826; }

.btn-appstore .apple-logo { width: 26px; height: 26px; flex-shrink: 0; }

.btn-appstore span { display: flex; flex-direction: column; line-height: 1.15; font-size: 17px; }

.btn-appstore small { font-size: 11px; font-weight: 400; opacity: 0.9; }

/* ===== Logo / wordmark ===== */

.acorn-icon {
  width: 0.78em;
  height: 0.78em;
  display: inline-block;
  vertical-align: -0.08em;
}

.wordmark {
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--blue-dark);
  display: inline-flex;
  align-items: baseline;
}

/* ===== Header ===== */

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: saturate(180%) blur(14px);
  -webkit-backdrop-filter: saturate(180%) blur(14px);
  border-bottom: 1px solid rgba(31, 42, 60, 0.08);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 14px;
  padding-bottom: 14px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
}

.brand-icon {
  width: 38px;
  height: 38px;
  border-radius: 11px;
  box-shadow: var(--shadow-card);
}

.brand .wordmark { font-size: 22px; }

.main-nav {
  display: flex;
  gap: 32px;
}

.main-nav a {
  font-size: 15px;
  font-weight: 600;
  color: var(--ink);
  transition: color 0.2s ease;
}

.main-nav a:hover { color: var(--blue-dark); }

.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  background: none;
  border: none;
  cursor: pointer;
}

.nav-toggle span {
  display: block;
  height: 2px;
  width: 22px;
  background: var(--ink);
  margin: 0 auto;
  transition: transform 0.25s ease, opacity 0.25s ease;
}

.nav-toggle.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle.open span:nth-child(2) { opacity: 0; }
.nav-toggle.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ===== Hero ===== */

.hero {
  padding-top: 64px;
  padding-bottom: 48px;
  background:
    radial-gradient(60% 60% at 88% 5%, rgba(242, 201, 76, 0.28), transparent 62%),
    radial-gradient(55% 55% at 2% 25%, rgba(47, 128, 237, 0.16), transparent 62%),
    linear-gradient(180deg, var(--blue-light) 0%, var(--white) 55%);
}

.hero-inner {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  align-items: center;
  gap: 40px;
}

.hero-copy h1 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(36px, 5vw, 56px);
  line-height: 1.08;
  margin: 0 0 22px;
  color: var(--ink);
}

.hero-sub {
  font-size: 18px;
  line-height: 1.7;
  color: var(--ink-soft);
  max-width: 480px;
  margin: 0 0 32px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin-bottom: 18px;
}

.hero-microcopy {
  font-size: 14px;
  color: var(--ink-soft);
  margin: 0;
}

/* ===== Hero visual (illustration de marque, sans aperçu d'interface) ===== */

.hero-visual {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 480px;
}

.hero-blob {
  position: absolute;
  width: 420px;
  height: 420px;
  border-radius: 46% 54% 58% 42% / 48% 44% 56% 52%;
  background: linear-gradient(150deg, var(--blue) 0%, #4c93f2 55%, var(--yellow) 145%);
  box-shadow: var(--shadow-soft);
  animation: blobMove 10s ease-in-out infinite;
}

@keyframes blobMove {
  0%, 100% { border-radius: 46% 54% 58% 42% / 48% 44% 56% 52%; transform: rotate(0deg); }
  50% { border-radius: 58% 42% 46% 54% / 52% 56% 44% 48%; transform: rotate(4deg); }
}

.hero-ring {
  position: absolute;
  width: 330px;
  height: 330px;
  border: 3px dashed rgba(166, 90, 46, 0.35);
  border-radius: 50%;
  animation: spin 40s linear infinite;
}

@keyframes spin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

.hero-mascot-large {
  position: relative;
  z-index: 2;
  width: 300px;
  filter: drop-shadow(0 25px 30px rgba(31,42,60,0.25));
  animation: float 5s ease-in-out infinite;
}

@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-16px); }
}

.hero-acorn {
  position: absolute;
  z-index: 3;
  width: 46px;
  filter: drop-shadow(0 8px 10px rgba(31,42,60,0.2));
}

.hero-acorn--1 { top: 6%; left: 8%; animation: float 4.5s ease-in-out infinite; }
.hero-acorn--2 { bottom: 10%; right: 4%; width: 36px; animation: float 5.5s ease-in-out infinite 0.6s; }
.hero-acorn--3 { top: 14%; right: 16%; width: 28px; animation: float 4s ease-in-out infinite 1.1s; }

.hero-soon-badge {
  position: absolute;
  bottom: 6%;
  left: 2%;
  z-index: 3;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--white);
  color: var(--ink);
  font-size: 13px;
  font-weight: 700;
  padding: 10px 16px;
  border-radius: 999px;
  box-shadow: var(--shadow-card);
}

.hero-soon-badge .dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--green-dark);
  flex-shrink: 0;
}

/* ===== Trust strip ===== */

.trust-strip {
  padding: 28px 0;
  background: var(--beige);
}

.trust-inner {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 40px;
}

.trust-item {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 14.5px;
  color: var(--brown-dark);
}

.trust-icon { font-size: 18px; }

/* ===== Features ===== */

.features {
  background:
    radial-gradient(45% 55% at 95% 0%, rgba(47,128,237,0.08), transparent 60%),
    radial-gradient(40% 45% at 0% 100%, rgba(166,90,46,0.08), transparent 60%),
    var(--white);
}

.feature-grid {
  margin-top: 56px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.feature-card {
  background: var(--white);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 32px 26px;
  box-shadow: var(--shadow-card);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.feature-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 22px 40px -18px rgba(31,42,60,0.2);
}

.feature-icon {
  width: 54px;
  height: 54px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  margin-bottom: 18px;
}

.feature-icon--blue { background: var(--blue-light); }
.feature-icon--yellow { background: var(--yellow-soft); }
.feature-icon--brown { background: var(--beige); }

.feature-card h3 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 19px;
  margin: 0 0 10px;
  color: var(--ink);
}

.feature-card p {
  font-size: 14.5px;
  line-height: 1.7;
  color: var(--ink-soft);
  margin: 0;
}

/* ===== Showcase ===== */

.showcase { background: var(--blue-light); }

.showcase-inner {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  align-items: center;
  gap: 48px;
}

.showcase-list {
  margin-top: 26px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.showcase-list li {
  font-size: 15.5px;
  line-height: 1.6;
  color: var(--ink-soft);
  padding-left: 30px;
  position: relative;
}

.showcase-list .li-icon {
  position: absolute;
  left: 0;
  top: 0;
  font-size: 15px;
}

.showcase-list strong { color: var(--ink); }

.showcase-visual {
  display: flex;
  justify-content: center;
}

.showcase-mascot-wrap {
  background: var(--white);
  border-radius: var(--radius-xl);
  padding: 30px;
  box-shadow: var(--shadow-card);
}

.showcase-mascot {
  width: 230px;
}

/* ===== Steps ===== */

.steps { background: var(--beige); }

.steps-grid {
  margin-top: 56px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
}

.step {
  text-align: center;
  padding: 20px;
  background: var(--white);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
}

.step-number {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--yellow);
  color: var(--ink);
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 20px;
  box-shadow: 0 10px 22px -8px rgba(242,201,76,0.6);
}

.step h3 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 18px;
  margin: 0 0 10px;
  color: var(--ink);
}

.step p {
  font-size: 14.5px;
  color: var(--ink-soft);
  line-height: 1.7;
  margin: 0;
}

/* ===== Security ===== */

.security { background: var(--white); }

.security-inner {
  display: grid;
  grid-template-columns: 0.8fr 1.2fr;
  align-items: center;
  gap: 48px;
}

.security-visual { display: flex; justify-content: center; }

.security-mascot-wrap {
  background: var(--beige);
  border-radius: var(--radius-xl);
  padding: 26px;
}

.security-mascot {
  width: 220px;
}

.security-list {
  margin-top: 24px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.security-list li {
  font-size: 15.5px;
  font-weight: 600;
  color: var(--ink);
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.security-list .li-icon { flex-shrink: 0; }

/* ===== CTA / Waitlist ===== */

.cta {
  text-align: center;
  background: linear-gradient(180deg, var(--blue-light), var(--white) 60%);
}

.cta-inner {
  max-width: 620px;
  position: relative;
}

.cta-mascot {
  width: 130px;
  margin: 0 auto 8px;
}

.waitlist-form {
  margin: 34px auto 0;
  display: flex;
  gap: 12px;
  max-width: 440px;
  justify-content: center;
}

.waitlist-form input {
  flex: 1;
  font-family: var(--font-body);
  font-size: 15px;
  padding: 15px 20px;
  border-radius: 999px;
  border: 2px solid var(--border-strong);
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
  color: var(--ink);
  background: var(--white);
}

.waitlist-form input:focus-visible {
  border-color: var(--focus-color);
  box-shadow: 0 0 0 3px rgba(20, 53, 110, 0.15);
}

.waitlist-form input[aria-invalid="true"] {
  border-color: var(--red-dark);
}

.waitlist-message {
  min-height: 24px;
  margin: 14px 0 0;
  font-size: 14px;
  font-weight: 700;
  color: var(--green-dark);
}

.waitlist-message.error { color: var(--red-dark); }

.waitlist-hint {
  margin: 10px 0 0;
  font-size: 12.5px;
  color: var(--ink-soft);
}

.badge-row { margin-top: 30px; display: flex; justify-content: center; }

.badge-soon {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: var(--ink);
  color: var(--white);
  font-size: 13.5px;
  font-weight: 600;
  padding: 10px 20px;
  border-radius: 999px;
}

.badge-soon .apple-logo { width: 16px; height: 16px; }

/* ===== FAQ ===== */

.faq { background: var(--beige); }

.faq-list {
  margin-top: 48px;
  max-width: 760px;
  margin-left: auto;
  margin-right: auto;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.faq-item {
  background: var(--white);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-card);
  overflow: hidden;
}

.faq-question {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  background: none;
  border: none;
  cursor: pointer;
  text-align: left;
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 16px;
  color: var(--ink);
  padding: 20px 24px;
}

.faq-icon {
  flex-shrink: 0;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--blue-light);
  color: var(--blue-dark);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  font-weight: 400;
  transition: transform 0.25s ease, background 0.25s ease, color 0.25s ease;
}

.faq-item.open .faq-icon {
  transform: rotate(45deg);
  background: var(--blue-dark);
  color: var(--white);
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease;
}

.faq-answer p {
  margin: 0;
  padding: 0 24px 22px;
  font-size: 14.5px;
  line-height: 1.7;
  color: var(--ink-soft);
}

/* ===== Footer ===== */

.site-footer {
  background: var(--ink);
  color: rgba(255,255,255,0.75);
  padding-top: 64px;
}

.footer-inner {
  display: grid;
  grid-template-columns: 1.2fr 2fr;
  gap: 48px;
  padding-bottom: 48px;
  border-bottom: 1px solid rgba(255,255,255,0.14);
}

.footer-brand { display: flex; flex-direction: column; gap: 10px; }

.footer-brand .brand-icon { width: 42px; height: 42px; }

.footer-brand .wordmark {
  color: var(--white);
  font-size: 24px;
  margin-top: 6px;
}

.footer-tagline {
  margin: 4px 0 0;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--yellow);
}

.footer-links {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.footer-col { display: flex; flex-direction: column; gap: 12px; }

.footer-col h4 {
  font-family: var(--font-display);
  font-size: 14px;
  color: var(--white);
  margin: 0 0 4px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.footer-col a {
  font-size: 14.5px;
  color: rgba(255,255,255,0.75);
  transition: color 0.2s ease;
}

.footer-col a:hover,
.footer-col a:focus-visible { color: var(--yellow); }

.footer-bottom {
  padding: 22px 24px;
  text-align: center;
  font-size: 13px;
  color: rgba(255,255,255,0.6);
}

/* ===== Back to top ===== */

.back-to-top {
  position: fixed;
  right: 24px;
  bottom: 24px;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--blue-dark);
  color: var(--white);
  border: none;
  font-size: 18px;
  cursor: pointer;
  box-shadow: var(--shadow-soft);
  opacity: 0;
  transform: translateY(10px);
  transition: opacity 0.25s ease, transform 0.25s ease;
  z-index: 90;
}

.back-to-top[hidden] {
  display: none;
}

.back-to-top.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ===========================================================
   Responsive
   =========================================================== */

@media (max-width: 960px) {
  .hero-inner,
  .showcase-inner,
  .security-inner,
  .footer-inner {
    grid-template-columns: 1fr;
  }

  .hero-copy { text-align: center; order: 2; }
  .hero-sub { margin-left: auto; margin-right: auto; }
  .hero-actions { justify-content: center; }
  .hero-visual { order: 1; min-height: 420px; }

  .showcase-copy { text-align: center; }
  .showcase-list { text-align: left; }
  .showcase-visual { order: -1; }

  .security-visual { order: -1; }
  .security-copy { text-align: center; }
  .security-list { align-items: center; text-align: left; display: inline-flex; }

  .feature-grid { grid-template-columns: repeat(2, 1fr); }
  .steps-grid { grid-template-columns: 1fr; gap: 24px; }

  .footer-links { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 720px) {
  section { padding: 64px 0; }

  .main-nav { display: none; }

  .nav-toggle { display: flex; }

  .main-nav.open {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--white);
    padding: 20px 24px 28px;
    gap: 18px;
    box-shadow: 0 20px 30px -20px rgba(31,42,60,0.25);
    border-bottom: 1px solid var(--border-subtle);
  }

  .header-cta { display: none; }

  .feature-grid { grid-template-columns: 1fr; }

  .hero-blob { width: 300px; height: 300px; }
  .hero-ring { width: 240px; height: 240px; }
  .hero-mascot-large { width: 220px; }

  .waitlist-form { flex-direction: column; }

  .footer-links { grid-template-columns: 1fr; }
}
