/* ═══════════════════════════════════════════════════════════════════════
   home.css — page-scoped styles for index.html (the gateway page).
   Loaded after style.css. Brand colours only via style.css :root vars.
   One authored motion idea: the hero phone tells both sides of a delivery.
   Everything else is calm; the route strip draws once.
   ═══════════════════════════════════════════════════════════════════════ */

@media (max-width: 599px) {
  .container { padding-inline: 16px; }
}

.home-h2 {
  font-size: clamp(1.6rem, 1.15rem + 2vw, 2.4rem);
  line-height: 1.15;
  letter-spacing: -0.02em;
  color: var(--navy);
  font-weight: 700;
  text-wrap: balance;
}

/* ── Hero ──────────────────────────────────────────────────────────── */
.home-hero {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(60% 50% at 85% 30%, rgba(235,185,95,.22), transparent 70%),
    var(--cream);
  padding: 32px 0 56px;
}
.home-hero__inner {
  display: grid;
  gap: 40px;
  align-items: center;
}
.home-hero__title {
  font-size: clamp(2.05rem, 1.2rem + 4vw, 3.6rem);
  line-height: 1.06;
  letter-spacing: -0.03em;
  font-weight: 700;
  color: var(--navy);
  text-wrap: balance;
  max-width: 15ch;
}
.home-hero__sub {
  margin-top: 16px;
  max-width: 46ch;
  font-size: 1rem;
  line-height: 1.6;
  color: var(--char);
  text-wrap: pretty;
}

/* Two doors: the page's real job is to send people to the right side. */
.doors { display: grid; gap: 12px; margin-top: 28px; max-width: 560px; }
.door {
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr) 22px;
  align-items: center;
  gap: 14px;
  min-height: 84px;
  padding: 16px 18px;
  border-radius: 20px;
  color: var(--navy);
  transition: transform .2s var(--ease-out), box-shadow .25s ease, border-color .2s ease;
}
.door--sender {
  background: linear-gradient(135deg, var(--gold), var(--gold2));
  box-shadow: 0 10px 28px rgba(235,185,95,.38);
}
.door--carrier {
  background: var(--white);
  box-shadow: inset 0 0 0 1.5px rgba(62,73,87,.14), 0 4px 16px rgba(26,35,50,.05);
}
.door__icon {
  width: 48px; height: 48px;
  display: grid; place-items: center;
  border-radius: 14px;
  background: rgba(26,35,50,.09);
}
.door--carrier .door__icon { background: rgba(235,185,95,.2); color: var(--gold-dark); }
.door__icon .brand-icon { width: 26px; height: 26px; color: currentColor; }
.door__body { display: grid; gap: 2px; }
.door__body strong { font-size: 1.06rem; font-weight: 600; line-height: 1.25; text-wrap: balance; }
.door__body span { font-size: .9rem; line-height: 1.4; color: var(--char); }
.door--sender .door__body span { color: var(--navy); opacity: .82; }
.door__arrow { width: 22px; height: 22px; transition: transform .2s var(--ease-out); }
.door:active { transform: scale(.98); }
@media (hover: hover) {
  .door:hover { transform: translateY(-2px); }
  .door--sender:hover { box-shadow: 0 16px 36px rgba(235,185,95,.5); }
  .door--carrier:hover { box-shadow: inset 0 0 0 1.5px var(--gold), 0 10px 24px rgba(26,35,50,.08); }
  .door:hover .door__arrow { transform: translateX(3px); }
}

.home-ask {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  margin-top: 14px;
  padding: 6px 4px;
  font-size: .95rem;
  font-weight: 500;
  color: var(--char);
}
.home-ask .brand-icon { width: 24px; height: 24px; color: var(--gold-dark); flex-shrink: 0; }
.home-ask u { text-decoration-color: rgba(138,94,15,.45); text-underline-offset: 3px; color: var(--navy); font-weight: 600; }
@media (hover: hover) { .home-ask:hover u { text-decoration-color: currentColor; } }

.home-hero__visual { margin: 0; text-align: center; }
.home-hero__visual .phone { max-width: 250px; }
.home-hero__cap { margin-top: 10px; font-size: .85rem; color: var(--muted); }

@media (min-width: 900px) {
  .home-hero { padding: 72px 0 96px; }
  .home-hero__inner { grid-template-columns: minmax(0, 1fr) 300px; gap: clamp(40px, 6vw, 96px); }
  .home-hero__visual .phone { max-width: 290px; }
  .home-hero__sub { font-size: 1.1rem; }
}

/* ── Mini-app atoms specific to the hero phone ─────────────────────── */
.ui-role { display: inline-block; padding: 3px 9px; border-radius: 99px; background: var(--navy); color: var(--gold); font-size: 10.5px; font-weight: 700; }
.ui-role--carrier { background: var(--gold); color: var(--navy); }
.ui-card--gold { position: relative; }
.ui-best { position: absolute; top: -8px; inset-inline-end: 10px; padding: 2px 8px; border-radius: 99px; background: var(--navy); color: var(--gold); font-size: 9.5px; font-weight: 700; }
.ui-sub--on-gold { color: var(--navy); opacity: .75; }
.ui-gap { margin-top: 6px; }
.ui-center { text-align: center; }
.ui-chips { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 8px; }
.ui-notif { box-shadow: 0 0 0 1.5px rgba(235,185,95,.7), 0 6px 18px rgba(235,185,95,.25); }
.ui-icon--on-gold { background: rgba(26,35,50,.12); color: var(--navy); }
.ui-stars { color: var(--gold); letter-spacing: 1px; font-size: 12px; }
.ui-track { height: 5px; margin-top: 9px; border-radius: 99px; background: rgba(62,73,87,.12); overflow: hidden; }
.ui-track i { display: block; height: 100%; width: 22%; border-radius: inherit; background: linear-gradient(90deg, var(--gold), var(--gold2)); transition: width 2.2s var(--ease-out) .4s; }
.screen.is-on .ui-track i { width: 64%; }

/* ── Comment ça marche: one route, three beats ─────────────────────── */
.home-how { padding: 72px 0; background: var(--white); }
.home-how .home-h2 { max-width: 20ch; margin-bottom: 40px; }
.route {
  --node: 40px;
  --gap: 28px;
  position: relative;
  list-style: none;
  display: grid;
  gap: var(--gap);
}
/* Phones: each beat draws its own vertical segment (dashed track + gold fill) */
.route__beat:not(:last-child)::before,
.route__beat:not(:last-child)::after {
  content: '';
  position: absolute;
  inset-inline-start: calc(var(--node) / 2 - 1px);
  top: var(--node);
  height: calc(100% - var(--node) + var(--gap));
  width: 2px;
}
.route__beat:not(:last-child)::before { width: 0; border-inline-start: 2px dashed rgba(62,73,87,.2); }
.route__beat:not(:last-child)::after {
  background: linear-gradient(180deg, var(--gold), var(--gold2));
  transform: scaleY(0);
  transform-origin: top;
  transition: transform .6s var(--ease-in-out);
}
.route.is-drawn .route__beat::after { transform: none; }
.route.is-drawn .route__beat:nth-child(2)::after { transition-delay: .6s; }
.route__beat { position: relative; padding-inline-start: calc(var(--node) + 18px); }
.route__node {
  position: absolute; inset-inline-start: 0; top: 0; z-index: 1;
  width: var(--node); height: var(--node);
  display: grid; place-items: center;
  border-radius: 50%;
  background: var(--navy); color: var(--gold);
  font-weight: 700; font-size: .95rem;
  box-shadow: 0 0 0 6px var(--white);
  transition: background-color .3s ease, color .3s ease;
}
.route.is-drawn .route__node { background-color: var(--gold); color: var(--navy); }
.route.is-drawn .route__beat:nth-child(2) .route__node { transition-delay: .6s; }
.route.is-drawn .route__beat:nth-child(3) .route__node { transition-delay: 1.2s; }
.route__beat h3 { font-size: 1.15rem; line-height: 1.3; color: var(--navy); margin: 7px 0 6px; }
.route__beat p { font-size: .98rem; line-height: 1.6; color: var(--char); max-width: 40ch; }
.route__code { display: inline-flex; gap: 4px; margin-top: 12px; direction: ltr; }
.route__code i {
  font-style: normal; width: 26px; height: 32px; display: grid; place-items: center;
  border-radius: 7px; background: var(--cream); color: var(--navy);
  font-weight: 700; font-size: .95rem; font-variant-numeric: tabular-nums;
  box-shadow: inset 0 0 0 1.5px rgba(235,185,95,.6);
}
.home-how__other {
  margin-top: 40px; padding-top: 24px;
  border-top: 1px solid rgba(62,73,87,.1);
  max-width: 62ch; font-size: .98rem; color: var(--char);
}
.home-how__other a {
  padding-block: 12px;      /* 44px hit area without breaking the line box */
  font-weight: 600; color: var(--navy); white-space: nowrap;
}
.home-how__other a svg { display: inline-block; vertical-align: -3px; margin-inline-start: 4px; width: 18px; height: 18px; color: var(--gold-dark); transition: transform .2s var(--ease-out); }
@media (hover: hover) { .home-how__other a:hover svg { transform: translateX(3px); } }

@media (min-width: 900px) {
  .home-how { padding: 112px 0; }
  .home-how .home-h2 { margin-bottom: 56px; }
  .route { grid-template-columns: repeat(3, minmax(0, 1fr)); --gap: 40px; }
  .route__beat::before, .route__beat::after { content: none !important; }
  .route::before,
  .route::after {
    content: '';
    position: absolute;
    top: calc(var(--node) / 2 - 1px);
    inset-inline-start: calc(var(--node) / 2);
    inset-inline-end: calc((100% - 2 * var(--gap)) / 3 - var(--node) / 2);
    height: 2px;
  }
  .route::before { height: 0; border-top: 2px dashed rgba(62,73,87,.2); }
  .route::after {
    background: linear-gradient(90deg, var(--gold), var(--gold2));
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 1.4s var(--ease-in-out);
  }
  [dir="rtl"] .route::after { transform-origin: right; }
  .route.is-drawn::after { transform: none; }
  .route__beat { padding-inline-start: 0; padding-top: calc(var(--node) + 20px); }
}

/* ── Trust pillars + coverage read as one dark chapter ─────────────── */
.home-coverage { padding: 24px 0 72px; }
.home-coverage__inner { display: grid; gap: 28px; align-items: center; }
.home-coverage .home-h2 { color: var(--white); }
.home-coverage__text p { margin-top: 14px; color: rgba(255,255,255,.72); max-width: 48ch; }
.home-coverage__text .home-coverage__ar { text-align: left; color: var(--gold); font-family: 'Cairo', 'Poppins', sans-serif; font-weight: 600; font-size: 1.1rem; }
.home-coverage .coverage__map { height: 340px; }
@media (min-width: 900px) {
  .home-coverage { padding: 40px 0 112px; }
  .home-coverage__inner { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 64px; }
  .home-coverage .coverage__map { height: 440px; }
}

/* ── Testimonials: compact; a swipe strip on phones ────────────────── */
.home-reviews .section-header,
.home-faq .section-header { margin-bottom: 36px; }
@media (max-width: 767px) {
  .home-reviews, .home-faq { padding: 64px 0; }
  .home-reviews .testimonials__grid {
    grid-template-columns: none;
    grid-auto-flow: column;
    grid-auto-columns: 86%;
    gap: 12px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    overscroll-behavior-x: contain;
    margin-inline: -16px;
    padding: 4px 16px 16px;
    scrollbar-width: none;
  }
  .home-reviews .testimonials__grid::-webkit-scrollbar { display: none; }
  .home-reviews .testimonial-card { scroll-snap-align: center; padding: 22px; }
}

/* ── Final CTA (dock hides here) ───────────────────────────────────── */
.home-final {
  background: var(--navy);
  color: var(--white);
  padding: 72px 0;
}
.home-final__inner { display: grid; gap: 40px; align-items: center; }
.home-final h2 {
  font-size: clamp(1.9rem, 1.2rem + 3vw, 3rem);
  line-height: 1.08; letter-spacing: -0.03em; font-weight: 700;
  color: var(--white); text-wrap: balance;
}
.home-final__text > p { margin-top: 14px; color: rgba(255,255,255,.75); max-width: 44ch; font-size: 1.02rem; }
.home-final__text .home-final__ar { text-align: left; color: var(--gold); font-family: 'Cairo', 'Poppins', sans-serif; font-weight: 700; font-size: 1.15rem; }
.home-final__ctas { display: grid; gap: 12px; margin-top: 28px; }
.home-final__ctas .btn { justify-content: center; }
.home-final .btn--msg { background: linear-gradient(135deg, var(--gold), var(--gold2)); color: var(--navy); }
.home-final .btn--msg .brand-icon { color: var(--navy); }
.home-final__play { background: rgba(255,255,255,.08); color: var(--white); border-color: rgba(255,255,255,.22); }
@media (hover: hover) {
  .home-final .btn--msg:hover { background: linear-gradient(135deg, var(--gold), var(--gold2)); box-shadow: 0 10px 28px rgba(235,185,95,.35); }
  .home-final__play:hover { background: rgba(255,255,255,.14); }
}
.home-final__qr { display: none; }
@media (min-width: 900px) {
  .home-final { padding: 112px 0; }
  .home-final__inner { grid-template-columns: minmax(0, 1fr) auto; gap: 80px; }
  .home-final__ctas { display: flex; flex-wrap: wrap; }
  .home-final__qr {
    display: grid; justify-items: center; gap: 10px;
    padding: 18px; border-radius: var(--radius);
    background: var(--white); color: var(--char);
  }
  .home-final__qr p { font-size: .8rem; font-weight: 500; }
  #qr-canvas { width: 120px; height: 120px; }
}

/* ── Contact (email fallback), compact ─────────────────────────────── */
.home-contact { padding: 64px 0; }
.home-contact__inner { display: grid; gap: 32px; }
.home-contact__intro > p { margin-top: 10px; color: var(--char); }
.home-contact__info { list-style: none; display: grid; gap: 4px; margin-top: 20px; }
.home-contact__info li { display: flex; align-items: center; gap: 10px; min-height: 44px; color: var(--char); }
.home-contact__info .brand-icon { width: 22px; height: 22px; color: var(--gold-dark); }
.home-contact__info a { font-weight: 600; color: var(--navy); }
.home-contact .contact__social { margin-top: 16px; }
.home-contact .social-link { width: 44px; height: 44px; }
.home-contact .contact__form { padding: 24px; }
.home-contact .form-group { margin-bottom: 14px; }
.home-contact input,
.home-contact select,
.home-contact textarea { font-size: 16px; }   /* no iOS zoom-on-focus */
@media (max-width: 599px) {
  .home-contact .form-row { grid-template-columns: 1fr; gap: 0; }
}
@media (min-width: 900px) {
  .home-contact { padding: 96px 0; }
  .home-contact__inner { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 64px; align-items: start; }
  .home-contact .contact__form { padding: 32px; }
}

@media (prefers-reduced-motion: reduce) {
  .route::after, .route__beat::after, .route__node, .ui-track i, .door, .door__arrow { transition: none !important; }
}

/* download is the hero's primary action; the doors route, WhatsApp + film support */
.home-hero__play { width: 100%; justify-content: center; margin-top: 16px; }
.home-ask { margin-top: 16px; }
.home-hero .film-btn { margin-top: 16px; }
@media (min-width: 900px) { .home-hero__play { width: auto; } }
.home-contact__info .wa-icon { color: var(--whatsapp); }
