/* =====================================================================
   Home page (index.php). Loaded with $extra_css = ['p-home.css'].
   Hero: copy + the booking card on one side, the brand photograph on the
   other; the map opens in its own full-width row below. Then four sizes of
   vehicle, one dashed road through the four steps, the provider numbers on a
   black board, the merchant benefits, and the coverage.
   ===================================================================== */

/* ---------- hero ---------- */
.hx { position: relative; isolation: isolate; overflow: hidden; }
.hx::before { content: ""; position: absolute; z-index: -1; inset-inline-end: -16%; top: -34%; width: min(70vw, 1000px); aspect-ratio: 1; background: radial-gradient(closest-side, rgba(var(--green-rgb), .14), transparent 70%); }
.hx::after { content: ""; position: absolute; z-index: -1; inset-inline-start: -14%; bottom: -30%; width: min(55vw, 800px); aspect-ratio: 1; background: radial-gradient(closest-side, rgba(var(--accent-rgb), .06), transparent 70%); }
.hx-grid { display: grid; grid-template-columns: minmax(0, 1.04fr) minmax(0, .96fr); gap: clamp(28px, 4vw, 72px); align-items: center; padding-block: clamp(20px, 3vw, 44px) clamp(24px, 3vw, 36px); }
.hx h1 { font-size: clamp(46px, 6.4vw, 96px); line-height: 1.2; margin: 1rem 0 .7rem; }
.hx h1 .l1 { display: block; }
.hx h1 .l2 { display: block; color: var(--brand-ink); }
.hx-lede { max-width: 52ch; margin: 0 0 1.6rem; color: var(--muted); font-size: clamp(18px, 1.5vw, 21px); }
.hx-sub { margin: .9rem 0 0; color: var(--muted); font-weight: 600; }
.hx-links { margin-top: .2rem; }

/* the booking card */
.hx-find { display: grid; gap: 12px; padding: 14px; border-radius: 26px; background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow-lg); }
.hx-find-top { display: grid; gap: 8px; }
.hx-find-label { display: flex; align-items: center; gap: .5rem; padding-inline: 6px; color: var(--muted); font-weight: 800; font-size: 15px; }
.find-map-toggle { display: flex; align-items: center; gap: .75rem; width: 100%; min-height: 62px; padding: 0 18px; border: 1.5px solid var(--line); border-radius: 16px; background: var(--surface-2); color: var(--ink); font: 700 17px var(--font); text-align: start; cursor: pointer; transition: border-color var(--ease), background var(--ease); }
.find-map-toggle:hover { border-color: #b8c1b8; }
.find-map-toggle > i:first-child { color: var(--brand); font-size: 1.35rem; }
.find-map-toggle > span { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.find-map-toggle .bi-chevron-down { color: var(--muted); transition: transform var(--ease); }
.find-map-toggle[aria-expanded="true"] .bi-chevron-down { transform: rotate(180deg); }
.find-map-toggle.has-value { border-color: rgba(var(--brand-rgb), .5); background: rgba(var(--brand-rgb), .06); color: var(--brand-ink); }
.hx-find-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 10px; align-items: stretch; }
.hx-find-row .fm-input, .hx-find-row .cx-btn { min-height: 56px; }
.hx-find-row .btx { white-space: nowrap; }

/* the photograph: one big curved corner, the four vehicle classes pinned on it */
.hx-art { position: relative; }
.hx-photo { position: relative; aspect-ratio: 5 / 4; overflow: hidden; border-radius: 30px; border-start-start-radius: 150px; box-shadow: var(--shadow-lg); background: var(--surface-2); }
.hx-photo picture { display: block; height: 100%; }
.hx-photo img { width: 100%; height: 100%; object-fit: cover; object-position: 62% 50%; }
.hx-cats { position: absolute; z-index: 2; inset-inline: 64px 16px; top: 22px; display: flex; flex-wrap: wrap; gap: 8px; margin: 0; padding: 0; list-style: none; }   /* no panel behind the chips: each pill sits straight on the photo */
.hx-cats li { box-shadow: 0 6px 16px rgba(10, 30, 15, .22); display: inline-flex; align-items: center; gap: .45rem; min-height: 44px; padding: 0 .9rem; border-radius: 999px; background: var(--surface); border: 1px solid var(--line); font-weight: 800; font-size: 15px; }
.hx-cats i { color: var(--brand-ink); font-size: 1.1rem; }

/* map row (opened by the toggle) */
.hx-map { margin-bottom: 8px; padding: clamp(12px, 1.6vw, 20px); border-radius: 28px; background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow); }
.hx-map[hidden] { display: none; }
.hx-steps { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-bottom: 12px; }
.hx-step { flex: 1 1 250px; max-width: 440px; display: flex; align-items: center; gap: .8rem; min-height: 66px; padding: 8px 16px; border: 1.5px solid var(--line); border-radius: 18px; background: var(--surface); color: var(--ink); font-family: var(--font); text-align: start; cursor: pointer; transition: border-color var(--ease), box-shadow var(--ease), background var(--ease); }
.hx-step .n { width: 36px; height: 36px; flex: 0 0 auto; display: grid; place-items: center; border-radius: 50%; background: var(--surface-2); border: 2px solid var(--line); font-weight: 800; }
.hx-step .t { display: grid; min-width: 0; flex: 1; }
.hx-step .t b { font-size: 16px; }
.hx-step .t small { color: var(--muted); font-size: 15px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hx-step .tick { color: var(--brand); font-size: 1.35rem; }
.hx-step.is-on { border-color: var(--brand); box-shadow: 0 0 0 4px rgba(var(--green-rgb), .14); }
.hx-step.is-on .n { background: var(--brand); border-color: var(--brand); color: #fff; }
.hx-step.is-done .n { background: rgba(var(--brand-rgb), .1); border-color: var(--brand); color: var(--brand-ink); }
.hx-step:focus-visible { outline: 3px solid rgba(var(--brand-rgb), .55); outline-offset: 2px; }
.hx-step-sep { color: var(--muted); }
.hx-locate { margin-inline-start: auto; }
.hx-hint { margin: .8rem 0 0; color: var(--muted); font-weight: 600; }
.hx-hint.err { color: var(--danger); }
.hx-go { display: flex; justify-content: flex-start; margin-top: 1rem; }
.hx-go[hidden] { display: none; }
@media (max-width: 575.98px) { .hx-go .btx { width: 100%; } }

.hx-trust { list-style: none; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin: 0; padding: 0 0 clamp(24px, 3vw, 44px); }
.hx-trust li { display: flex; align-items: center; gap: .75rem; min-height: 64px; padding: 8px 16px; border-radius: 18px; background: var(--surface-2); font-weight: 700; line-height: 1.5; }
.hx-trust i { color: var(--brand-ink); font-size: 1.4rem; flex: 0 0 auto; }

/* ---------- vehicle sizes ---------- */
.cats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: clamp(14px, 1.6vw, 22px); }
.cat { gap: .5rem; min-height: 300px; align-content: start; text-decoration: none; color: inherit; }
.cat-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: .7rem; }
.cat-ico { width: 68px; height: 68px; display: grid; place-items: center; border-radius: 22px; background: rgba(var(--brand-rgb), .1); color: var(--brand-ink); font-size: 2rem; transition: background var(--ease), color var(--ease), transform var(--ease); }
.cat-ico.is-veh { width: 190px; height: 112px; padding: 10px 14px; border-radius: 22px; background: linear-gradient(180deg, rgba(var(--brand-rgb), .05), rgba(var(--brand-rgb), .14)); }
.cat-ico.is-veh .vside { transition: transform var(--ease); }
.cat:hover .cat-ico.is-veh { background: linear-gradient(180deg, rgba(var(--brand-rgb), .08), rgba(var(--brand-rgb), .22)); color: var(--brand-ink); transform: none; }
.cat:hover .cat-ico.is-veh .vside { transform: translateX(-6px) scale(1.05); }
.cat:hover .cat-ico { background: var(--brand); color: #fff; transform: rotate(-4deg) scale(1.04); }
.cat-size { display: flex; align-items: flex-end; gap: 4px; height: 30px; }
.cat-size i { width: 9px; border-radius: 3px; background: var(--line); }
.cat-size i:nth-child(1) { height: 32%; } .cat-size i:nth-child(2) { height: 54%; } .cat-size i:nth-child(3) { height: 77%; } .cat-size i:nth-child(4) { height: 100%; }
.cat-size i.on { background: var(--green); }
.cat-name { font-size: 22px; font-weight: 800; line-height: 1.4; }
.cat-use { color: var(--muted); }
.cat-subs { display: flex; flex-wrap: wrap; gap: 6px; margin-top: .3rem; }
.cat-go { margin-top: auto; padding-top: 1rem; display: inline-flex; align-items: center; gap: .4rem; color: var(--brand-ink); font-weight: 800; }
.cat-go .bi { transition: transform var(--ease); }
.cat:hover .cat-go .bi { transform: translateX(4px); }
[dir="rtl"] .cat:hover .cat-go .bi { transform: scaleX(-1) translateX(4px); }

/* ---------- how it works: one dashed road, four stops ---------- */
.hw { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: clamp(18px, 2.4vw, 36px); position: relative; }
.hw::before { content: ""; position: absolute; top: 30px; inset-inline-start: 30px; inset-inline-end: calc(25% - 30px); border-top: 4px dashed rgba(255,255,255,.28); }
.hw-step { position: relative; display: grid; gap: .55rem; justify-items: start; align-content: start; }
.hw-n { width: 60px; height: 60px; display: grid; place-items: center; border-radius: 50%; background: var(--green); color: var(--accent); font-size: 26px; font-weight: 800; position: relative; z-index: 1; box-shadow: 0 0 0 9px var(--accent); }
.hw-ico { width: 40px; height: 40px; color: #7be58a; margin-top: .6rem; }
.hw-ico svg { width: 100%; height: 100%; }
.hw-step b { color: #fff; font-size: 20px; line-height: 1.5; }
.hw-step p { margin: 0; color: rgba(255,255,255,.74); }
.hw-more { margin-top: clamp(28px, 3vw, 44px); }

/* ---------- providers ---------- */
.pv, .mc, .cv { display: grid; align-items: center; gap: clamp(24px, 4vw, 72px); }
.pv { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
.pv-copy h2, .mc-copy h2 { font-size: clamp(30px, 3.6vw, 52px); margin: .9rem 0 .6rem; line-height: 1.3; }
.pv-acts { display: flex; flex-wrap: wrap; gap: .7rem; margin-top: 1.5rem; }
.pv-board { display: grid; gap: 10px; padding: clamp(14px, 1.6vw, 22px); border-radius: 30px; background: var(--accent); color: #fff; box-shadow: var(--shadow-lg); }
.pv-row { display: grid; grid-template-columns: 96px minmax(0, 1fr) auto auto; gap: .9rem; align-items: center; padding: 12px 16px; border-radius: 20px; background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.1); }
.pv-ico.is-veh { display: flex; width: 96px; height: 58px; padding: 6px 8px; border-radius: 16px; }
.pv-ico.is-veh > .vside { width: 100%; height: 100%; max-width: none; max-height: none; object-fit: contain; }
.pv-ico { width: 54px; height: 54px; display: grid; place-items: center; border-radius: 16px; background: rgba(var(--green-rgb), .22); color: #5fe070; font-size: 1.6rem; }
.pv-name { font-weight: 800; font-size: 18px; }
.pv-fig { display: grid; justify-items: end; min-width: 104px; text-align: end; }
.pv-fig b { font-size: 22px; color: #5fe070; line-height: 1.3; }
.pv-fig small { color: rgba(255,255,255,.7); font-size: 15px; }

/* ---------- merchants ---------- */
.mc { grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); }
.mc-card { display: grid; gap: 1.2rem; align-content: start; padding: clamp(20px, 2.4vw, 32px); border-radius: 30px; background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow); }
.mc-card .pill { justify-self: start; }
.mc-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.mc-list li { display: flex; align-items: center; gap: 1rem; padding: 12px 14px; border-radius: 18px; background: var(--surface-2); }
.mc-list b { font-size: 17px; line-height: 1.5; }

/* ---------- coverage ---------- */
.cv { grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); padding: clamp(24px, 3.4vw, 52px); border-radius: 34px; background: var(--surface-2); border: 1px solid var(--line); }
.cv-stats { display: flex; gap: clamp(28px, 4vw, 64px); margin-top: 1.6rem; }
.cv-stats b { display: block; font-size: clamp(48px, 5.4vw, 80px); line-height: 1.1; color: var(--brand-ink); font-weight: 800; }
.cv-stats span { color: var(--muted); font-weight: 700; }
.cv-grid { display: flex; flex-wrap: wrap; gap: 10px; }
.cv-chip { display: inline-flex; align-items: center; gap: .7rem; min-height: 50px; padding-block: 0; padding-inline: 1.1rem .5rem; border-radius: 999px; background: var(--surface); border: 1px solid var(--line); font-weight: 700; }
.cv-chip b { min-width: 32px; height: 32px; display: grid; place-items: center; border-radius: 50%; background: rgba(var(--brand-rgb), .1); color: var(--brand-ink); font-size: 15px; }

/* ---------- responsive ---------- */
@media (max-width: 1099.98px) {
  .hx-grid { grid-template-columns: minmax(0, 1fr); }
  .hx-art { order: -1; }   /* the picture leads on a phone, the booking card follows */
  .hx-photo { aspect-ratio: 16 / 10; border-start-start-radius: 90px; }
  .cats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .hw { grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: 40px; }
  .hw::before { display: none; }
  .pv, .mc, .cv { grid-template-columns: minmax(0, 1fr); }
  .hx-trust { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 575.98px) {
  .hx-find-row { grid-template-columns: minmax(0, 1fr); }
  .hx-find-row .btx { width: 100%; }
  .hx-photo { aspect-ratio: 4 / 3; border-start-start-radius: 64px; }
  .hx-cats { position: static; margin-top: 10px; background: none; border: 0; padding: 0; backdrop-filter: none; }
  .cats { grid-template-columns: minmax(0, 1fr); }
  .cat { min-height: 0; }
  .hw { grid-template-columns: minmax(0, 1fr); position: relative; row-gap: 28px; }
  .hw::before { display: block; top: 30px; bottom: 30px; inset-inline: auto; inset-inline-start: 28px; border-top: 0; border-inline-start: 4px dashed rgba(255,255,255,.28); }
  .hw-step { grid-template-columns: 60px minmax(0, 1fr); column-gap: 1rem; justify-items: start; }
  .hw-n { grid-row: 1 / span 3; }
  .hw-ico { display: none; }
  .hx-trust { grid-template-columns: minmax(0, 1fr); }
  .pv-row { grid-template-columns: 72px minmax(0, 1fr) auto; }
  .pv-ico { width: 46px; height: 46px; font-size: 1.3rem; }
  .pv-ico.is-veh { width: 72px; height: 48px; }
  .pv-fig:last-child { grid-column: 2 / -1; justify-items: start; text-align: start; }
  .hx-step-sep { display: none; }
  .hx-locate { margin-inline-start: 0; width: 100%; }
}
@media (prefers-reduced-motion: reduce) { .cat:hover .cat-ico { transform: none; } }

.hx-form, .hx-copy, .cv-copy { min-width: 0; }
.hw-sec { overflow: hidden; }

.hx-near { display: flex; align-items: center; gap: .5rem; margin: .6rem 0 0; padding: 8px 14px; border-radius: 12px; background: rgba(var(--brand-rgb), .07); color: var(--brand-ink); font-weight: 700; line-height: 1.5; }
.hx-near[hidden] { display: none; }
