/* ============================================================================
   features.css — Localite Features page.
   Loaded AFTER css/style.css, which provides Tailwind Preflight, the design
   tokens, theming, and the shared lp-* / ds-* components. Everything here is
   prefixed `fp-` and reuses the same theme variables — no new colors.
   Ported 1:1 from the imported design's features.css.
   ============================================================================ */

/* Editorial accent used by the DS reply block (not needed by the home page). */
:root { --accent-moss: #3C8262; }
:root[data-theme="dark"] { --accent-moss: #5AA888; }

/* DS MessageBubble reply-quote block (used in the chat close-up vignette). */
.ds-bubble__reply {
  background: rgba(0,0,0,0.06);
  border-left: 3px solid var(--accent-moss);
  border-radius: 6px 6px 0 0;
  padding: var(--space-sm) var(--space-md);
  margin: -2px -4px var(--space-xs);
}
:root[data-theme="dark"] .ds-bubble__reply { background: rgba(255,255,255,0.06); }
.ds-bubble__reply-sender { color: var(--accent-moss); font-size: var(--fs-callout-bold); font-weight: var(--weight-semibold); margin-bottom: 2px; }
.ds-bubble__reply-text { color: var(--text-primary); font-size: var(--fs-footnote); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* ---- HERO ---------------------------------------------------------------- */
.fp-hero { position: relative; padding-top: clamp(36px, 5vw, 64px); padding-bottom: clamp(48px, 6vw, 96px); overflow: hidden; }
.fp-hero-grid {
  display: grid; grid-template-columns: minmax(0, 1.02fr) minmax(0, 0.98fr);
  gap: clamp(32px, 5vw, 72px); align-items: center;
}
.fp-hero-copy { max-width: 40ch; }
.fp-hero h1 {
  font-size: var(--t-display); line-height: 1.02; font-weight: 700;
  letter-spacing: -0.032em; margin: 18px 0 0; text-wrap: balance;
}
.fp-hero h1 .lp-accent { color: var(--brand); }
.fp-hero .lp-lead { margin-top: 20px; max-width: 44ch; }
.fp-hero-visual { position: relative; min-height: clamp(420px, 44vw, 540px); display: flex; align-items: center; justify-content: center; }

/* category jump links */
.fp-jump { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 28px; }
.fp-jump a {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 9px 15px; border-radius: 999px;
  border: 1px solid var(--line); background: var(--card);
  font-size: 14px; font-weight: 600; color: var(--ink);
  transition: border-color .2s ease, background-color .2s ease, transform .2s ease;
}
.fp-jump a:hover { border-color: color-mix(in srgb, var(--brand) 42%, var(--line)); transform: translateY(-1px); }
.fp-jump a .mdi { font-size: 18px; color: var(--brand-ink); }

/* ---- FEATURE ROW (alternating) ------------------------------------------ */
.fp-row { padding-block: clamp(52px, 7.5vw, 104px); position: relative; }
.fp-row + .fp-row { border-top: 1px solid var(--line-soft); }
.fp-row-grid {
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(36px, 6vw, 88px); align-items: center;
}
.fp-row-copy { max-width: 44ch; }
.fp-row--flip .fp-row-copy { order: 2; }
.fp-row-copy h2 {
  font-size: var(--t-h2); line-height: 1.08; font-weight: 700;
  letter-spacing: -0.02em; margin: 16px 0 0; text-wrap: balance;
}
.fp-row-copy .lp-lead { margin-top: 18px; }
.fp-row-visual { position: relative; display: flex; align-items: center; justify-content: center; min-height: clamp(380px, 42vw, 520px); }

/* feature chips under the copy */
.fp-chips { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 28px; }
.fp-chip {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 9px 14px; border-radius: 999px;
  background: var(--card-sunk); border: 1px solid var(--line);
  font-size: 13.5px; font-weight: 600; color: var(--ink);
}
.fp-chip .mdi { font-size: 17px; color: var(--brand-ink); }

/* gentle float when motion is on (reuses lp-float keyframes from style.css) */
:root[data-motion="on"] .fp-float { animation: lp-float 7.5s ease-in-out infinite; }
@media (prefers-reduced-motion: reduce) { .fp-float { animation: none !important; } }

/* ---- CHAT CLOSE-UP (chat row visual) ------------------------------------ */
.fp-chat-closeup {
  position: relative; width: min(420px, 100%);
  background: var(--chat-canvas); border: 1px solid var(--line);
  border-radius: 26px; padding: 22px 18px;
  box-shadow: var(--shadow-float);
  display: flex; flex-direction: column; gap: 10px;
}
.fp-cl-row { display: flex; }
.fp-cl-day {
  align-self: center; background: color-mix(in srgb, var(--page-alt) 92%, transparent);
  border-radius: 8px; padding: 3px 12px; font-size: 12px; font-weight: 500;
  color: var(--ink-soft); margin-bottom: 2px;
}

/* ---- ORDER STATES (orders row visual) ----------------------------------- */
.fp-order-stage { position: relative; width: min(380px, 100%); padding: 8px; }
.fp-bill-hero {
  background: var(--card); border: 1px solid var(--line);
  border-radius: 20px; padding: 20px 20px; box-shadow: var(--shadow-float);
}
.fp-pill {
  position: absolute; z-index: 4; display: inline-flex; align-items: center; gap: 7px;
  background: var(--card); border: 1px solid var(--line); border-radius: 11px;
  padding: 8px 12px; box-shadow: var(--shadow-float);
  font-size: 13px; font-weight: 600; color: var(--ink); white-space: nowrap;
}
.fp-pill .mdi { font-size: 16px; }
.fp-pill-a { top: -14px; left: -10px; }
.fp-pill-b { bottom: -16px; right: -8px; }
.fp-diff-chip {
  position: absolute; z-index: 4; right: -22px; top: 48%;
  background: var(--brand-ink); color: #fff; border-radius: 10px;
  padding: 7px 11px; font-size: 12.5px; font-weight: 600; white-space: nowrap;
  box-shadow: var(--shadow-float);
}
:root[data-theme="dark"] .fp-diff-chip { color: #04130b; }

/* ---- PAYMENTS (payments row visual) ------------------------------------- */
.fp-pay-wrap { position: relative; width: min(420px, 100%); display: flex; flex-direction: column; gap: 16px; }
.fp-pay-sheet {
  background: var(--card); border: 1px solid var(--line);
  border-radius: 22px; padding: 20px; box-shadow: var(--shadow-float);
}
.fp-pay-head {
  display: flex; align-items: center; justify-content: space-between;
  padding-bottom: 16px; margin-bottom: 16px; border-bottom: 1px solid var(--line);
}
.fp-pay-head span { font-size: 15px; font-weight: 600; color: var(--ink); }
.fp-pay-head b { font-size: 22px; font-weight: 700; color: var(--ink); letter-spacing: -0.01em; }
.fp-pay-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; }
.fp-pay-tile {
  display: flex; flex-direction: column; align-items: center; gap: 7px;
  padding: 12px 6px 10px; border-radius: 14px;
  background: var(--card-sunk); border: 1px solid var(--line-soft);
}
.fp-pay-logo {
  width: 38px; height: 38px; border-radius: 11px; background: #fff;
  display: grid; place-items: center; overflow: hidden;
  border: 1px solid rgba(0,0,0,.06);
  font-size: 16px; font-weight: 800; line-height: 1; letter-spacing: -0.02em;
}
.fp-pay-logo img { width: 30px; height: 30px; object-fit: contain; }
.fp-pay-tile span { font-size: 11px; font-weight: 600; color: var(--ink-soft); text-align: center; line-height: 1.15; }
.fp-pay-more { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; }
.fp-pay-more .fp-pay-logo { background: var(--brand-soft); border-color: transparent; color: var(--brand-ink); font-weight: 700; font-size: 14px; }

.fp-khata-card {
  align-self: flex-end; width: 82%;
  background: var(--shops-bg); color: var(--shops-ink);
  border: 1px solid var(--shops-line); border-radius: 18px;
  padding: 18px 20px; box-shadow: var(--shadow-float);
}
.fp-khata-top { display: flex; align-items: center; gap: 9px; font-size: 13px; font-weight: 600; color: var(--shops-soft); }
.fp-khata-top .mdi { font-size: 18px; color: var(--brand-ink); }
.fp-khata-bal { display: flex; align-items: baseline; gap: 9px; margin-top: 8px; }
.fp-khata-bal b { font-size: 30px; font-weight: 700; letter-spacing: -0.02em; color: var(--shops-ink); }
.fp-khata-bal small { font-size: 13px; color: var(--shops-soft); font-weight: 500; }
.fp-khata-foot { margin-top: 12px; display: flex; align-items: center; gap: 7px; font-size: 13px; color: var(--shops-soft); }
.fp-khata-foot .mdi { font-size: 15px; color: var(--brand-ink); }

/* ---- IN-PHONE SCREENS (join + lists) ------------------------------------ */
.fp-screen { flex: 1; min-height: 0; background: var(--page-alt); display: flex; flex-direction: column; overflow: hidden; }
.fp-screen-pad { padding: 8px 16px 14px; display: flex; flex-direction: column; min-height: 0; flex: 1; }
.fp-screen-title { display: flex; align-items: center; justify-content: space-between; font-size: 24px; font-weight: 700; letter-spacing: -0.02em; color: var(--ink); margin: 6px 0 12px; }
.fp-screen-title .mdi { font-size: 22px; color: var(--brand); }

.fp-seg { display: flex; gap: 8px; margin-bottom: 12px; }
.fp-seg span { padding: 7px 14px; border-radius: 999px; font-size: 13px; font-weight: 600; background: var(--card-sunk); color: var(--ink-soft); }
.fp-seg span.on { background: var(--brand); color: #fff; }

/* shopping list */
.fp-list-meta { font-size: 12.5px; color: var(--ink-faint); margin-bottom: 12px; }
.fp-check-group { margin-bottom: 6px; }
.fp-check-head { font-size: 11px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--ink-faint); margin: 10px 0 6px; }
.fp-check-row { display: flex; align-items: center; gap: 11px; padding: 8px 0; }
.fp-check-row .mdi.ck { font-size: 21px; color: var(--brand); }
.fp-check-row .mdi.un { font-size: 21px; color: var(--ink-faint); }
.fp-check-row .it { flex: 1; font-size: 14px; color: var(--ink); }
.fp-check-row.done .it { color: var(--ink-faint); text-decoration: line-through; }
.fp-qty { font-size: 12px; font-weight: 600; color: var(--ink-soft); background: var(--card-sunk); border-radius: 7px; padding: 3px 9px; }
.fp-list-cta { margin-top: auto; display: flex; align-items: center; justify-content: center; gap: 9px; background: var(--brand); color: #fff; border-radius: 13px; padding: 13px; font-size: 15px; font-weight: 600; }
.fp-list-cta .mdi { font-size: 19px; }

/* ---- BUILT FOR INDIA band ----------------------------------------------- */
.fp-band { background: var(--shops-bg); color: var(--shops-ink); }
.fp-band .lp-eyebrow { color: var(--brand-ink); }
.fp-band h2 { font-size: var(--t-h2); line-height: 1.06; font-weight: 700; letter-spacing: -0.022em; margin: 16px auto 0; color: var(--shops-ink); max-width: 22ch; text-wrap: balance; }
.fp-band .fp-band-lead { margin: 18px auto 0; color: var(--shops-soft); font-size: var(--t-lead); max-width: 50ch; }
.fp-band-head { text-align: center; }
.fp-langs { display: flex; flex-wrap: wrap; justify-content: center; gap: 9px; margin: 30px auto 0; max-width: 720px; }
.fp-lang { padding: 8px 15px; border-radius: 999px; border: 1px solid var(--shops-line); background: var(--shops-card); color: var(--shops-ink); font-size: 15px; font-weight: 500; }
.fp-pillars { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px; margin-top: clamp(40px, 5vw, 60px); background: var(--shops-line); border: 1px solid var(--shops-line); border-radius: 18px; overflow: hidden; }
.fp-pillar { background: var(--shops-card); padding: 28px 24px; display: flex; flex-direction: column; gap: 12px; }
.fp-pillar-ic { width: 46px; height: 46px; border-radius: 12px; display: grid; place-items: center; background: rgba(31,162,84,.16); color: var(--brand-ink); }
.fp-pillar-ic .mdi { font-size: 24px; }
.fp-pillar h3 { font-size: 18px; font-weight: 600; margin: 0; color: var(--shops-ink); }
.fp-pillar p { margin: 0; font-size: 14.5px; line-height: 1.55; color: var(--shops-soft); }

/* ---- EVEN MORE grid ----------------------------------------------------- */
.fp-more-head { max-width: 46ch; }
.fp-more-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1px; margin-top: clamp(40px, 5vw, 60px); background: var(--line); border: 1px solid var(--line); border-radius: 18px; overflow: hidden; }
.fp-more-item { background: var(--card); padding: 26px 22px; display: flex; flex-direction: column; gap: 12px; transition: background-color .25s ease; }
.fp-more-item:hover { background: var(--card-sunk); }
.fp-more-ic { width: 42px; height: 42px; border-radius: 12px; display: grid; place-items: center; background: var(--brand-soft); color: var(--brand-ink); }
.fp-more-ic .mdi { font-size: 22px; }
.fp-more-item h3 { font-size: 15.5px; font-weight: 600; margin: 0; color: var(--ink); }
.fp-more-item p { font-size: 13.5px; line-height: 1.5; color: var(--ink-soft); margin: 0; }

/* ---- RESPONSIVE --------------------------------------------------------- */
@media (max-width: 980px) {
  .fp-hero-grid { grid-template-columns: 1fr; gap: 10px; }
  .fp-hero-copy { max-width: 100%; }
  .fp-hero-visual { min-height: 460px; margin-top: 12px; }
  .fp-row-grid { grid-template-columns: 1fr; gap: 36px; }
  .fp-row-copy { max-width: 100%; order: 0 !important; }
  .fp-row--flip .fp-row-copy { order: 0; }
  .fp-row-visual { order: 2; min-height: 0; }
  .fp-more-grid { grid-template-columns: repeat(2, 1fr); }
  .fp-pillars { grid-template-columns: 1fr; }
}
@media (max-width: 560px) {
  .fp-more-grid { grid-template-columns: 1fr; }
  .fp-diff-chip { display: none; }
  .fp-khata-card { width: 100%; align-self: stretch; }
  .fp-pay-grid { grid-template-columns: repeat(4, 1fr); }
}

/* ============================================================================
   MOTION — scroll parallax, staggered reveals, hero cascade, join visual.
   Gated on data-motion="on" so print / export / reduced-motion show the
   finished state. [data-parallax] transforms are driven by GSAP (features.js /
   main.js) instead of the original --py variable, but the reduced-motion resets
   are kept so the finished state always shows.
   ============================================================================ */
.fp-pv { display: flex; align-items: center; justify-content: center; }
:root[data-motion="off"] [data-parallax] { transform: none !important; }
@media (prefers-reduced-motion: reduce) { [data-parallax] { transform: none !important; } }

/* staggered "pop" of a vignette's inner parts when its row scrolls in */
.fp-pop {
  transition: opacity .55s cubic-bezier(.22,.61,.36,1), transform .55s cubic-bezier(.22,.61,.36,1);
  transition-delay: calc(var(--i, 0) * 85ms);
}
:root[data-motion="on"] .fp-row-visual:not([data-in]) .fp-pop { opacity: 0; transform: translateY(16px) scale(.975); }
@media (prefers-reduced-motion: reduce) {
  .fp-pop { transition: none !important; opacity: 1 !important; transform: none !important; }
}

/* ---- joining-a-shop (invite) visual ------------------------------------- */
.fp-join-title { font-size: 23px; font-weight: 700; letter-spacing: -0.02em; color: var(--ink); margin: 8px 0 12px; }
.fp-join-hint { font-size: 12.5px; color: var(--ink-soft); margin: 2px 0 14px; line-height: 1.45; }
.fp-code { display: flex; gap: 6px; justify-content: space-between; margin: 2px 0 16px; }
.fp-code-cell {
  flex: 1; aspect-ratio: 3 / 4; border-radius: 9px;
  border: 1.5px solid var(--line); background: var(--card-sunk);
  display: grid; place-items: center; font-size: 18px; font-weight: 700; color: var(--ink);
  font-variant-numeric: tabular-nums; transition: border-color .2s ease, background-color .2s ease, transform .2s ease;
}
.fp-code-cell.on { border-color: var(--brand); background: var(--card); transform: translateY(-1px); }
.fp-join-or { text-align: center; font-size: 12px; color: var(--ink-faint); margin: 2px 0 4px; }
.fp-join-opt {
  display: flex; align-items: center; gap: 12px;
  padding: 12px 14px; border-radius: 12px; border: 1px solid var(--line);
  background: var(--card); margin-top: 10px; font-size: 13.5px; font-weight: 600; color: var(--ink);
}
.fp-join-opt .mdi { font-size: 20px; color: var(--brand-ink); }
.fp-join-opt.wa .mdi { color: #25D366; }
.fp-join-opt .ar { margin-left: auto; color: var(--ink-faint); font-size: 18px; }
.fp-join-cta {
  margin-top: 16px; text-align: center; padding: 13px; border-radius: 13px;
  background: var(--card-sunk); color: var(--ink-faint); font-size: 15px; font-weight: 600;
  transition: background-color .35s ease, color .35s ease;
}
.fp-join-cta.on { background: var(--brand); color: #fff; }

/* shopping-list "Add all to cart" — a single celebratory pulse once ticked */
.fp-list-cta.go { animation: fp-cta-pulse .7s cubic-bezier(.34,1.56,.64,1); }
@keyframes fp-cta-pulse { 0% { transform: scale(1); } 40% { transform: scale(1.035); } 100% { transform: scale(1); } }
:root[data-motion="off"] .fp-list-cta.go { animation: none; }
@media (prefers-reduced-motion: reduce) { .fp-list-cta.go { animation: none; } }

/* ============================================================================
   HERO FEATURE CASCADE — a diagonal cascade of real feature cards. Slots carry
   parallax (GSAP-driven transform); cards carry rotation + a cascade-in
   entrance (separate elements so the two transforms never collide).
   ============================================================================ */
.fp-hcas { position: relative; width: min(480px, 100%); height: clamp(450px, 46vw, 538px); margin: 0 auto; }
.fp-hcas-slot { position: absolute; will-change: transform; }
.fp-hcas-card { transform: rotate(var(--rot, 0deg)); border-radius: 18px; }
:root[data-motion="on"] .fp-hcas-card {
  animation: fp-cascade-in .8s cubic-bezier(.22,.9,.3,1) both;
  animation-delay: calc(var(--i, 0) * 130ms);
}
@keyframes fp-cascade-in {
  from { opacity: 0; transform: translateY(28px) scale(.94) rotate(var(--rot, 0deg)); }
  to   { opacity: 1; transform: translateY(0) scale(1) rotate(var(--rot, 0deg)); }
}
:root[data-motion="off"] .fp-hcas-card { animation: none; }
@media (prefers-reduced-motion: reduce) { .fp-hcas-card { animation: none !important; } }

/* positions (diagonal cascade: chat → bill → pay, with satellites) */
.fp-hcas-chat  { top: 0;    left: 0;    z-index: 2; width: 230px; }
.fp-hcas-bill  { top: 25%;  left: 22%;  z-index: 3; width: 278px; }
.fp-hcas-pay   { top: 61%;  left: 31%;  z-index: 4; width: 240px; }
.fp-hcas-khata { top: 47%;  left: -2%;  z-index: 5; }
.fp-hcas-pill  { top: 9%;   right: -1%; z-index: 5; }

/* card surfaces */
.fp-hcas-chatcard {
  background: var(--chat-canvas); border: 1px solid var(--line); box-shadow: var(--shadow-float);
  padding: 14px 12px; display: flex; flex-direction: column; gap: 8px;
}
.fp-hcas-chatrow { display: flex; }
.fp-hcas-billcard { background: var(--card); border: 1px solid var(--line); box-shadow: var(--shadow-float); padding: 18px; }
.fp-hcas-paycard { background: var(--card); border: 1px solid var(--line); box-shadow: var(--shadow-float); padding: 16px; }
.fp-hcas-payhead { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.fp-hcas-payhead span { font-size: 13px; font-weight: 600; color: var(--ink-soft); }
.fp-hcas-payhead b { font-size: 18px; font-weight: 700; color: var(--ink); letter-spacing: -0.01em; }
.fp-hcas-paylogos { display: flex; gap: 8px; }
.fp-hcas-logo { width: 40px; height: 40px; border-radius: 11px; background: #fff; border: 1px solid rgba(0,0,0,.06); display: grid; place-items: center; overflow: hidden; font-size: 16px; font-weight: 800; line-height: 1; letter-spacing: -0.02em; }
.fp-hcas-logo img { width: 30px; height: 30px; object-fit: contain; }
.fp-hcas-khatachip {
  background: var(--shops-bg); color: var(--shops-ink); border: 1px solid var(--shops-line);
  box-shadow: var(--shadow-float); padding: 12px 16px; display: flex; align-items: center; gap: 11px;
}
.fp-hcas-khatachip .mdi { color: var(--brand-ink); font-size: 21px; }
.fp-hcas-khatachip span { display: flex; flex-direction: column; font-size: 11px; color: var(--shops-soft); line-height: 1.15; }
.fp-hcas-khatachip b { font-size: 17px; color: var(--shops-ink); font-weight: 700; }
.fp-hcas-pillchip {
  background: var(--card); border: 1px solid var(--line); box-shadow: var(--shadow-float);
  padding: 9px 13px; display: inline-flex; align-items: center; gap: 7px;
  font-size: 13px; font-weight: 600; color: var(--ink); white-space: nowrap;
}
.fp-hcas-pillchip .mdi { font-size: 16px; }

@media (max-width: 980px) { .fp-hcas { transform: scale(.94); } }
@media (max-width: 560px) { .fp-hcas { transform: scale(.78); height: 470px; } }
@media (max-width: 400px) { .fp-hcas { transform: scale(.66); } }
@media (max-width: 420px) { .fp-hero-chip { display: none; } }
