/* =========================================================
   Landing pages (/lp/...) – loaded after the site CSS; uses the same tokens.
   Also loaded on /road-accidents/ for the eligibility quiz and the quiz invitation (bottom of this file).
   WP: enqueue on the landing-page template and on the road-accidents page.
   ========================================================= */

/* WhatsApp brand green; dark text/icon on it (white on this green fails contrast) */
:root { --wa-green: #25D366; --wa-green-hover: #3EE07A; --wa-ink: #072B16; }
.btn--wa { gap: 10px; background: var(--wa-green); color: var(--wa-ink); border-color: var(--wa-green); font-weight: 600; }
.btn--wa:hover { background: var(--wa-green-hover); border-color: var(--wa-green-hover); }
.btn--wa .icon { width: 22px; height: 22px; }

/* ---------- Header ---------- */
.lp-header {
  position: sticky; top: env(safe-area-inset-top, 0px); z-index: 50;
  background: var(--navy-950);
  border-bottom: 1px solid var(--line-dark);
}
.lp-header__inner { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 92px; }
.lp-header .logo__img { height: 62px; width: auto; }
.lp-header__actions { display: flex; align-items: center; gap: 10px; }
.lp-header__phone { gap: 8px; font-weight: 600; }
.lp-header__phone .icon { width: 18px; height: 18px; }
.lp-header .header-whatsapp { display: inline-grid; }
.lp-header .logo { flex: 0 1 auto; min-width: 0; }
.lp-header .logo__img { max-width: 100%; object-fit: contain; object-position: right center; }
@media (max-width: 767px) {
  /* WhatsApp is in the bottom action bar on phones */
  .lp-header .header-whatsapp { display: none; }
  .lp-header__inner { min-height: 70px; }
  .lp-header .logo__img { height: 40px; }
}
@media (max-width: 380px) {
  .lp-header__phone { padding-inline: 12px; }
  .lp-header .logo__img { height: 34px; }
}

/* ---------- Hero ---------- */
.lp-hero {
  position: relative;
  background:
    radial-gradient(80% 70% at 15% 0%, rgba(47, 82, 136, 0.55), transparent 70%),
    linear-gradient(180deg, var(--navy-950), var(--navy-900));
  color: rgba(255, 255, 255, 0.85);
  padding-block: clamp(40px, 6vw, 88px) clamp(48px, 7vw, 104px);
}
.lp-hero__grid {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr);
  gap: clamp(32px, 5vw, 72px);
  align-items: center;
}
.lp-hero__badge {
  display: inline-block;
  margin: 0 0 20px;
  padding: 6px 14px;
  border: 1px solid rgba(207, 160, 92, 0.5);
  border-radius: 999px;
  color: var(--gold-300);
  font-size: var(--fs-xs);
  letter-spacing: 0.02em;
}
.lp-hero__title {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(2.1rem, 1.4rem + 3vw, 3.6rem);
  line-height: var(--lh-tight);
  font-weight: 700;
  color: var(--white);
}
.lp-hero__title span { color: var(--gold-500); }
.lp-hero__lead { margin: 20px 0 0; font-size: var(--fs-md); line-height: 1.6; max-width: 46ch; }

.lp-checks { display: grid; gap: 12px; margin: 28px 0 0; padding: 0; list-style: none; }
.lp-checks li { position: relative; padding-inline-start: 34px; font-weight: 500; color: var(--white); }
.lp-checks li::before {
  content: "";
  position: absolute; inset-inline-start: 0; top: 0.2em;
  width: 22px; height: 22px; border-radius: 50%;
  background: var(--gold-500)
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230A1630' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12l4 4 10-10'/%3E%3C/svg%3E") center / 14px no-repeat;
}

/* ---------- Quiz card ---------- */
.lp-card {
  background: var(--white);
  color: var(--ink);
  border-radius: 14px;
  padding: clamp(22px, 3vw, 36px);
  box-shadow: 0 30px 60px -30px rgba(0, 0, 0, 0.6);
  border-top: 4px solid var(--gold-500);
  scroll-margin-top: 96px;
}
.lp-card__title { margin: 0; font-family: var(--font-display); font-size: var(--fs-lg); line-height: var(--lh-snug); color: var(--navy-900); }
.lp-card__sub { margin: 4px 0 20px; color: var(--ink-soft); font-size: var(--fs-sm); }

.lp-quiz { display: block; }
.lp-quiz__progress { height: 6px; border-radius: 999px; background: var(--sky-100); overflow: hidden; }
.lp-quiz__bar { display: block; height: 100%; width: 25%; background: var(--gold-500); border-radius: inherit; transition: width 300ms var(--ease); }
.lp-quiz__count { margin: 8px 0 16px; font-size: var(--fs-xs); color: var(--ink-soft); min-height: 1.4em; }
.lp-quiz:not(.is-stepped) .lp-quiz__progress,
.lp-quiz:not(.is-stepped) .lp-quiz__count { display: none; }

.lp-quiz__step { border: 0; margin: 0 0 20px; padding: 0; min-width: 0; }
.lp-quiz.is-stepped .lp-quiz__step { margin: 0; animation: lp-in 260ms var(--ease); }
.lp-quiz__q { padding: 0; margin-bottom: 14px; font-weight: 700; font-size: var(--fs-md); color: var(--navy-900); }
.lp-quiz__q:focus { outline: none; }
.lp-quiz__q:focus-visible { outline: 2px solid var(--color-focus); outline-offset: 4px; }

.lp-quiz__options { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.lp-opt { position: relative; display: block; cursor: pointer; }
/* An odd number of options: the last one spans the full row instead of sitting alone in half of it */
.lp-quiz__options > .lp-opt:last-child:nth-child(odd) { grid-column: 1 / -1; }
.lp-opt input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.lp-opt span {
  display: flex; align-items: center; justify-content: center; text-align: center;
  min-height: 56px; padding: 10px 12px;
  border: 1.5px solid var(--line);
  border-radius: 10px;
  font-weight: 500; line-height: 1.3;
  transition: border-color var(--dur) var(--ease), background var(--dur) var(--ease), transform var(--dur) var(--ease);
}
.lp-opt:hover span { border-color: var(--navy-600); background: var(--sky-50); }
.lp-opt input:checked + span { border-color: var(--gold-500); background: rgba(207, 160, 92, 0.12); color: var(--navy-950); }
.lp-opt input:focus-visible + span { outline: 2px solid var(--color-focus); outline-offset: 2px; }
.lp-opt input:active + span { transform: scale(0.98); }

.lp-quiz__fields { display: grid; gap: 16px; margin-bottom: 18px; }
.lp-quiz .field__input { border: 1.5px solid var(--line); border-radius: 10px; padding: 12px 14px; background: var(--white); min-height: 52px; }
.lp-quiz .field__input:focus { border-color: var(--gold-500); background: var(--white); }
.lp-quiz .field__input[aria-invalid="true"] { border-color: #E0603A; }
.lp-quiz .field--check { margin-bottom: 10px; color: var(--ink-soft); }
.lp-quiz__privacy { margin: 0 0 16px; font-size: 0.75rem; line-height: 1.5; color: var(--ink-soft); }
.lp-quiz .contact-form__submit { display: grid; gap: 10px; }
.lp-quiz .btn--block { min-height: 56px; font-size: var(--fs-md); font-weight: 700; }

.lp-quiz__nav { min-height: 0; }
.lp-quiz__back {
  margin-top: 14px; padding: 4px 0;
  background: none; border: 0; cursor: pointer;
  color: var(--ink-soft); font: inherit; font-size: var(--fs-sm);
  text-decoration: underline; text-underline-offset: 3px;
}
.lp-quiz__back:hover { color: var(--navy-900); }

/* Desktop: a larger, roomier quiz card so it reads clearly beside the headline */
@media (min-width: 901px) {
  .lp-hero__grid { grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); }
  .lp-card { padding: 44px 44px 40px; border-radius: 18px; }
  .lp-card__title { font-size: clamp(1.75rem, 1.2rem + 1vw, 2.25rem); }
  .lp-card__sub { font-size: var(--fs-base); margin-bottom: 26px; }
  .lp-quiz__progress { height: 8px; }
  .lp-quiz__count { font-size: var(--fs-sm); margin: 10px 0 20px; }
  .lp-quiz__q { font-size: var(--fs-lg); margin-bottom: 18px; }
  .lp-quiz__options { gap: 14px; }
  .lp-opt span { min-height: 72px; font-size: var(--fs-md); border-radius: 12px; }
  .lp-quiz .field__label { font-size: var(--fs-sm); }
  .lp-quiz .field__input { min-height: 58px; font-size: var(--fs-md); }
  .lp-quiz .btn--block { min-height: 62px; font-size: var(--fs-lg); }
}

/* Slide only (no fade): the step stays fully visible even if the browser pauses animations */
@keyframes lp-in { from { transform: translateY(8px); } to { transform: none; } }

/* ---------- Stats / counter band ---------- */
.lp-stats { background: var(--sky-50); border-bottom: 1px solid var(--line); }
.lp-stats__grid {
  display: grid; grid-template-columns: 1.4fr 1fr 1fr;
  gap: 1px; background: var(--line);
  margin-block: 0;
}
.lp-stat { background: var(--sky-50); padding: clamp(28px, 4vw, 48px) clamp(16px, 3vw, 40px); text-align: center; }
.lp-stat__value {
  margin: 0;
  font-family: var(--font-display); font-weight: 700;
  font-size: clamp(2rem, 1.3rem + 2.6vw, 3.25rem);
  line-height: 1.1; color: var(--navy-900);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.lp-stat--main .lp-stat__value { color: var(--gold-700); font-size: clamp(2.3rem, 1.4rem + 3.4vw, 4rem); }
.lp-stat__label { margin: 8px 0 0; color: var(--ink-soft); font-weight: 500; }
.lp-stat__lead { margin: 0 0 8px; color: var(--ink-soft); font-weight: 500; }
.lp-stat__note { margin: 6px auto 0; max-width: 36ch; color: var(--ink-soft); font-size: 0.875rem; line-height: 1.5; }

/* Odometer: each digit is a column whose strip of digits rolls upward to the final value (built by landing.js) */
.odo { display: inline-flex; direction: ltr; vertical-align: top; }
.odo__col { display: inline-block; height: 1.1em; overflow: hidden; }
.odo__strip { display: flex; flex-direction: column; transform: translateY(0); will-change: transform; }
.odo__strip span { display: block; height: 1.1em; line-height: 1.1em; }
.odo__sep { display: inline-block; line-height: 1.1em; }
.odo.is-rolling .odo__strip { transition: transform var(--odo-dur, 2.4s) cubic-bezier(0.16, 1, 0.3, 1); transition-delay: var(--odo-delay, 0s); }

/* ---------- Section heads ---------- */
.lp-section-head { max-width: 760px; margin-bottom: clamp(32px, 4vw, 56px); }
.lp-section-head__lead { margin: 16px 0 0; font-size: var(--fs-md); color: var(--color-text-muted); line-height: 1.6; }
.lp-center { margin-top: 40px; text-align: center; }

/* ---------- Who is entitled ---------- */
.lp-tiles { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin: 0; padding: 0; list-style: none; }
.lp-tile {
  padding: 24px 20px;
  border: 1px solid var(--line); border-radius: 12px;
  border-top: 3px solid var(--gold-500);
  background: var(--white);
}
.lp-tile__title { margin: 0 0 8px; font-family: var(--font-display); font-size: var(--fs-md); color: var(--navy-900); }
.lp-tile p { margin: 0; color: var(--ink-soft); line-height: 1.6; font-size: var(--fs-sm); }

/* ---------- Process ---------- */
.lp-steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(16px, 3vw, 40px); margin: 0; padding: 0; list-style: none; counter-reset: none; }
.lp-step { position: relative; padding: 28px 24px; background: var(--white); border-radius: 12px; box-shadow: var(--shadow-soft); }
.lp-step__num { display: block; font-family: var(--font-display); font-weight: 700; font-size: 2.5rem; line-height: 1; color: var(--gold-500); margin-bottom: 14px; }
.lp-step__title { margin: 0 0 8px; font-size: var(--fs-md); color: var(--navy-900); }
.lp-step p { margin: 0; color: var(--ink-soft); line-height: 1.65; }

/* ---------- About ---------- */
.lp-team { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(20px, 3vw, 40px); margin: 0; padding: 0; list-style: none; }
.lp-person { display: grid; grid-template-columns: minmax(120px, 38%) minmax(0, 1fr); gap: clamp(16px, 2.5vw, 28px); align-items: start; }
.lp-person__photo { width: 100%; max-width: 100%; height: auto; aspect-ratio: 4 / 5; object-fit: cover; border-radius: 12px; }
.lp-person__role { margin: 0; font-size: var(--fs-xs); font-weight: 500; letter-spacing: 0.04em; color: var(--gold-700); }
.lp-person__name { margin: 4px 0 10px; font-family: var(--font-display); font-size: var(--fs-lg); color: var(--navy-900); }
.lp-person__body p:last-child { margin: 0; color: var(--ink-soft); line-height: 1.65; }
.lp-about .lp-quote { margin-top: clamp(32px, 4vw, 48px); }
.lp-quote {
  margin: 24px 0 0; padding: 4px 20px;
  border-inline-start: 3px solid var(--gold-500);
  font-family: var(--font-display); font-size: var(--fs-lg); line-height: var(--lh-snug); color: var(--navy-900);
}
.lp-about__actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 32px; }
.btn--outline-navy { border-color: var(--navy-900); color: var(--navy-900); background: transparent; }
.btn--outline-navy:hover { background: var(--navy-900); color: var(--white); }

/* ---------- Final CTA ---------- */
.lp-final__grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  grid-template-areas: "text card" "reach card";
  grid-template-rows: auto 1fr;
  column-gap: clamp(32px, 5vw, 72px);
  row-gap: 0;
}
.lp-final__text { grid-area: text; align-self: end; }
.lp-final__card { grid-area: card; align-self: center; }
.lp-final__reach { grid-area: reach; }
.lp-final__or { margin: 28px 0 0; color: rgba(255, 255, 255, 0.7); font-size: var(--fs-sm); }
.lp-final__or + .lp-final__wa { margin-top: 12px; }
.lp-final__lead { margin: 16px 0 0; font-size: var(--fs-md); line-height: 1.6; max-width: 44ch; }
.lp-final__wa { margin-top: 28px; gap: 10px; }
.lp-final__wa .icon { width: 22px; height: 22px; color: var(--gold-500); }
.lp-final__contact { display: grid; gap: 12px; margin: 24px 0 0; padding: 0; list-style: none; }
.lp-final__contact a { display: inline-flex; align-items: center; gap: 10px; color: var(--white); font-weight: 600; font-size: var(--fs-md); text-decoration: none; }
.lp-final__contact a:hover { color: var(--gold-300); }
.lp-final__contact .icon { width: 22px; height: 22px; color: var(--gold-500); }
.lp-final .lp-card { color: var(--ink); }

/* ---------- Footer ---------- */
.lp-footer { background: var(--navy-950); color: rgba(255, 255, 255, 0.7); padding-block: 32px; font-size: var(--fs-sm); }
.lp-footer__inner { display: grid; gap: 12px; text-align: center; justify-items: center; }
.lp-footer p { margin: 0; }
.lp-footer a { color: inherit; }
.lp-footer a:hover { color: var(--white); }
.lp-footer__legal { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px 20px; margin: 0; padding: 0; list-style: none; }
.lp-footer__note { max-width: 80ch; font-size: var(--fs-xs); opacity: 0.8; line-height: 1.6; }

/* ---------- Responsive ---------- */
@media (max-width: 1100px) {
  .lp-tiles { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 900px) {
  .lp-hero__grid { grid-template-columns: 1fr; }
  .lp-final__grid { grid-template-columns: 1fr; grid-template-areas: "text" "card" "reach"; grid-template-rows: auto; row-gap: 28px; }
  .lp-final__or { margin-top: 8px; }
  .lp-team { grid-template-columns: 1fr; }
  .lp-hero__lead { font-size: var(--fs-base); }
  .lp-checks { margin-top: 20px; }
  .lp-steps { grid-template-columns: 1fr; }
  .lp-stats__grid { grid-template-columns: 1fr 1fr; }
  .lp-stat--main { grid-column: 1 / -1; }
}
@media (max-width: 600px) {
  .lp-tiles { grid-template-columns: 1fr 1fr; }
  .lp-tile { padding: 18px 16px; }
  .lp-quiz__options { grid-template-columns: 1fr; }
  .lp-opt span { min-height: 52px; justify-content: flex-start; text-align: start; padding-inline: 16px; }
  .lp-about__actions .btn { flex: 1 1 100%; }
}

/* ---------- Quiz inside the eligibility band on /road-accidents/ ---------- */
.eligibility--quiz .eligibility__head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr);
  align-items: center;
  gap: clamp(32px, 5vw, 72px);
}
.eligibility--quiz .eligibility__lead { margin-bottom: 0; }
.eligibility__quiz { scroll-margin-top: 110px; }
.eligibility__stories-title {
  margin: 0 0 24px;
  font-family: var(--font-display); font-size: var(--fs-lg); font-weight: 700;
  color: var(--white);
}
@media (max-width: 900px) {
  .eligibility--quiz .eligibility__head { grid-template-columns: 1fr; }
}

/* ---------- Quiz invitation (closable corner card – not a blocking pop-up) ---------- */
.quiz-nudge {
  position: fixed;
  inset-inline-start: 28px;            /* opposite corner to the floating "השאירו פרטים" button */
  bottom: 28px;
  z-index: 79;
  width: min(320px, calc(100% - 32px));
  padding: 18px 20px 20px;
  background: var(--white);
  color: var(--ink);
  border-radius: 14px;
  border-top: 3px solid var(--gold-500);
  box-shadow: 0 24px 50px -20px rgba(10, 22, 48, 0.55);
  animation: lp-nudge-in 320ms var(--ease);
}
.quiz-nudge[hidden] { display: none; }
.quiz-nudge__close {
  position: absolute; top: 8px; inset-inline-end: 8px;
  display: grid; place-items: center;
  width: 36px; height: 36px; padding: 0;
  background: none; border: 0; border-radius: 50%;
  color: var(--ink-soft); cursor: pointer;
}
.quiz-nudge__close:hover { background: var(--sky-50); color: var(--navy-900); }
.quiz-nudge__close .icon { width: 18px; height: 18px; }
.quiz-nudge__title { margin: 0 0 4px; padding-inline-end: 32px; font-family: var(--font-display); font-weight: 700; font-size: var(--fs-md); color: var(--navy-900); }
.quiz-nudge__text { margin: 0 0 14px; font-size: var(--fs-sm); color: var(--ink-soft); line-height: 1.5; }
.quiz-nudge__btn { width: 100%; justify-content: center; }
@keyframes lp-nudge-in { from { transform: translateY(16px); opacity: 0; } to { transform: none; opacity: 1; } }

@media (max-width: 768px) {
  /* above the bottom action bar, compact */
  .quiz-nudge {
    inset-inline: 12px;
    width: auto;
    bottom: calc(58px + env(safe-area-inset-bottom) + 10px);
    padding: 12px 14px 14px;
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    grid-template-areas: "title title" "text btn";
    align-items: center;
    column-gap: 12px;
  }
  .quiz-nudge[hidden] { display: none; }
  .quiz-nudge__title { grid-area: title; font-size: var(--fs-base); margin-bottom: 2px; }
  .quiz-nudge__text { grid-area: text; margin: 0; font-size: var(--fs-xs); }
  .quiz-nudge__btn { grid-area: btn; width: auto; min-height: 44px; padding-inline: 14px; font-size: var(--fs-sm); }
  .quiz-nudge__close { top: 4px; inset-inline-end: 4px; }
}

@media (prefers-reduced-motion: reduce) {
  .lp-quiz.is-stepped .lp-quiz__step { animation: none; }
  .lp-quiz__bar { transition: none; }
  .quiz-nudge { animation: none; }
}
