/*
  BiteeNextDoor landing site styles. Colours copy brand/theme.json (light): change the theme there first,
  then mirror it here. Light only, like the app (dark theme hidden since 2026-11-07).
  Heading font: Baloo 2 ExtraBold, self-hosted (copied from brand/fonts by site/Makefile, SIL OFL).

  Squircles (Zain 2026-11-24, "so it looks premium"): rounded shapes use `corner-shape: squircle`
  (superellipse corners). Browsers without it fall back to plain border-radius. A squircle needs a
  larger radius than a circle arc to look as round, so the @supports block at the end raises the radii.
*/
@font-face { font-family: "Baloo 2"; src: url("/fonts/Baloo2-ExtraBold.ttf") format("truetype"); font-weight: 800; font-display: swap; }

:root {
  --bg: #ffffff; --surface: #f8f4f0; --surface2: #f0e9e2; --text: #21160f; --muted: #6f6258;
  --border: #eee5dc; --accent: #ff6a00; --accent-dark: #c94f00; --good: #1f8a4c; --bad: #b23a2a;
  --radius: 18px; --r-sm: 12px; --r-phone: 44px; --r-screen: 34px;
  --shadow: 0 10px 30px rgba(33, 22, 15, .08);
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; overflow-x: clip; } /* rotated phones must never cause sideways scroll */
body { margin: 0; background: var(--bg); color: var(--text); font: 17px/1.6 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; overflow-x: hidden; -webkit-font-smoothing: antialiased; }
img { max-width: 100%; display: block; }
a { color: inherit; }
h1, h2, h3 { font-family: "Baloo 2", system-ui, sans-serif; font-weight: 800; line-height: 1.1; margin: 0 0 .5em; }
h1 { font-size: clamp(2.3rem, 6vw, 3.9rem); letter-spacing: -.01em; }
h2 { font-size: clamp(1.7rem, 4vw, 2.5rem); }
h3 { font-size: 1.25rem; }
p { margin: 0 0 1em; }

.wrap { max-width: 1120px; margin: 0 auto; padding: 0 max(16px, env(safe-area-inset-left)); }
.narrow { max-width: 760px; }
.center { text-align: center; }
.accent { color: var(--accent); }

/* Buttons */
.btn { display: inline-block; background: var(--accent); color: #fff; text-decoration: none; font-weight: 700; padding: 14px 26px; border-radius: 16px; box-shadow: 0 6px 18px rgba(255, 106, 0, .3); transition: transform .15s, background .15s; }
.btn:hover { background: var(--accent-dark); transform: translateY(-1px); }
.btn-sm { padding: 9px 18px; font-size: .95rem; box-shadow: none; white-space: nowrap; border-radius: 12px; }
.btn-ghost { background: transparent; color: var(--text); box-shadow: inset 0 0 0 2px var(--border); }
.btn-ghost:hover { background: var(--surface); }
.btn-light { background: #fff; color: var(--accent-dark); box-shadow: none; }
.btn-light:hover { background: var(--surface); }

/* Top bar */
.nav { position: sticky; top: 0; z-index: 10; background: rgba(255, 255, 255, .92); backdrop-filter: blur(8px); border-bottom: 1px solid var(--border); }
.nav-in { display: flex; align-items: center; gap: 24px; height: 64px; }
.brand img { height: 34px; width: auto; }
.nav-links { display: flex; gap: 22px; margin-left: auto; }
.nav-links a { text-decoration: none; color: var(--muted); font-weight: 600; font-size: .95rem; }
.nav-links a:hover { color: var(--text); }

/* Hero */
.hero { background: radial-gradient(circle at 85% 10%, #ffe2cc 0, transparent 45%), linear-gradient(180deg, #fff7f0, #fff); padding: 64px 0 72px; overflow: hidden; }
.hero-in { display: grid; grid-template-columns: 1.1fr .9fr; gap: 40px; align-items: center; }
.kicker { display: inline-block; background: #ffe2cc; color: var(--accent-dark); font-weight: 700; font-size: .85rem; padding: 5px 12px; border-radius: 10px; }
.lead { font-size: 1.2rem; color: var(--muted); max-width: 34em; }
.urdu-mix { font-family: "Baloo 2", system-ui, sans-serif; font-weight: 800; font-size: 1.35rem; color: var(--text); }
.cta-row { display: flex; flex-wrap: wrap; gap: 12px; margin: 8px 0 22px; }
.ticks { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 8px 20px; color: var(--muted); font-size: .95rem; }
.ticks li::before { content: "✓ "; color: var(--good); font-weight: 800; }

/*
  Drawn phones. Everything inside .stage is laid out in fixed px for a 440x640 box; .stage is then
  scaled with --s, and .stage-box reserves the scaled height so the page flows normally.
*/
.stage-box { --s: 1; width: calc(440px * var(--s)); height: calc(640px * var(--s)); justify-self: center; position: relative; }
.stage { position: absolute; top: 0; left: 0; width: 440px; height: 640px; transform: scale(var(--s)); transform-origin: top left; font-size: 12px; line-height: 1.35; }
.stage::before { content: ""; position: absolute; inset: 60px 20px 20px 40px; background: radial-gradient(closest-side, rgba(255, 106, 0, .22), transparent); filter: blur(10px); }

.phone { position: absolute; width: 262px; height: 576px; padding: 9px; border-radius: var(--r-phone); background: linear-gradient(145deg, #3a2c22, #120c08 60%); box-shadow: inset 0 0 0 1.5px #5a4637, 0 40px 70px -20px rgba(33, 22, 15, .45), 0 12px 24px rgba(33, 22, 15, .18); }
.phone::after { content: ""; position: absolute; right: -2px; top: 120px; width: 3px; height: 54px; border-radius: 2px; background: #3a2c22; }
.phone-back { left: 0; top: 40px; transform: rotate(-7deg); opacity: .97; }
.phone-front { right: 0; top: 0; transform: rotate(3deg); z-index: 2; }
.screen { position: relative; height: 100%; overflow: hidden; border-radius: var(--r-screen); background: #fbf8f5; display: flex; flex-direction: column; }
.status { flex: none; display: flex; justify-content: space-between; align-items: center; padding: 6px 20px 0 24px; height: 30px; background: #fff; font-size: 11.5px; position: relative; z-index: 3; }
.status b { font-weight: 700; }
.sys { display: flex; gap: 5px; align-items: center; }
.sig { width: 15px; height: 9px; background: linear-gradient(90deg, currentColor 0 18%, transparent 18% 27%, currentColor 27% 45%, transparent 45% 54%, currentColor 54% 72%, transparent 72% 81%, currentColor 81%); clip-path: polygon(0 100%, 100% 0, 100% 100%); }
.bat { width: 20px; height: 10px; border-radius: 3px; box-shadow: inset 0 0 0 1.2px currentColor; position: relative; }
.bat::before { content: ""; position: absolute; inset: 2px 5px 2px 2px; background: currentColor; border-radius: 1px; }
.island { position: absolute; top: 9px; left: 50%; width: 74px; height: 21px; margin-left: -37px; background: #000; border-radius: 12px; z-index: 4; }

/* Real app screenshot below the drawn status bar (shots are 390x844 phone screens at 2x). */
.screen { background: #fff; }
.shot { width: 100%; height: auto; display: block; }

/* WhatsApp contact (Zain's number; the link pre-fills "BiteeNextDoor website: ..."). */
.btn-wa { background: #1f8a4c; box-shadow: 0 6px 18px rgba(31, 138, 76, .28); display: inline-flex; align-items: center; gap: 8px; }
.btn-wa:hover { background: #17703d; }
.btn-wa svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linejoin: round; }
.ask { margin-top: 28px; padding: 22px; background: var(--surface); border-radius: var(--radius); display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.ask p { margin: 0; font-weight: 700; }
.center-row { justify-content: center; margin-bottom: 0; }

/* Floating notification and chip */
.toast { position: absolute; z-index: 3; top: 0; left: -6px; width: 238px; display: flex; gap: 10px; align-items: center; padding: 10px 12px; background: rgba(255, 255, 255, .96); backdrop-filter: blur(10px); border-radius: 18px; box-shadow: 0 18px 40px -10px rgba(33, 22, 15, .35), 0 0 0 1px rgba(33, 22, 15, .05); transform: rotate(-2deg); }
.toast b { display: block; font-size: 12.5px; }
.toast small { color: var(--muted); font-size: 11px; }
.t-ico { width: 34px; height: 34px; flex: none; display: grid; place-items: center; border-radius: 10px; background: #fff3ea; }
.t-ico img { width: 22px; height: 22px; }
.chip { position: absolute; z-index: 3; right: 30px; bottom: 6px; padding: 9px 14px; background: var(--text); color: #fff; font-weight: 700; font-size: 12px; border-radius: 13px; box-shadow: 0 14px 30px -10px rgba(33, 22, 15, .5); transform: rotate(2deg); }
.chip b { color: #6ee7a0; margin-right: 2px; }

/* Sections */
.section { padding: 80px 0; }
.section.alt { background: var(--surface); }
.sub { color: var(--muted); font-size: 1.1rem; max-width: 40em; margin-bottom: 36px; }
.grid3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.card { background: var(--surface); border-radius: var(--radius); padding: 26px; }
.card p, .feat p { color: var(--muted); margin: 0; }
.icon { width: 52px; height: 52px; display: grid; place-items: center; margin-bottom: 14px; border-radius: 15px; background: #fff; color: var(--accent); box-shadow: 0 4px 14px rgba(33, 22, 15, .06); }
.icon svg { width: 26px; height: 26px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.feat { border: 1px solid var(--border); border-radius: var(--radius); padding: 22px 24px; background: #fff; }
.feat h3 { position: relative; padding-left: 18px; }
.feat h3::before { content: ""; position: absolute; left: 0; top: .35em; width: 9px; height: 9px; border-radius: 3px; background: var(--accent); }

/* Comparison table; on narrow phones each row turns into a card (see the 640px block). */
.table-wrap { background: #fff; border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; }
.compare { width: 100%; border-collapse: collapse; font-size: .98rem; }
.compare th, .compare td { padding: 16px 18px; text-align: left; border-bottom: 1px solid var(--border); }
.compare thead th { font-family: "Baloo 2", sans-serif; font-size: 1.05rem; }
.compare tbody th { font-weight: 600; }
.compare tr:last-child th, .compare tr:last-child td { border-bottom: 0; }
.compare .us { background: #fff3ea; }
.compare thead .us { color: var(--accent-dark); }
.compare .good { color: var(--good); font-weight: 700; }
.compare .bad { color: var(--bad); }

/* Pricing */
.price-grid { display: grid; grid-template-columns: 1.15fr 1fr; gap: 20px; align-items: stretch; }
.price-card { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 30px; box-shadow: var(--shadow); }
.price-rate { margin: 0; font-weight: 700; color: var(--muted); }
.price-rate span { display: block; font-family: "Baloo 2", sans-serif; font-size: clamp(3rem, 9vw, 4.4rem); line-height: 1; color: var(--accent); }
.price-cap { font-size: 1.1rem; margin: 10px 0 18px; }
.price-cap b { color: var(--text); }
.price-eg { list-style: none; margin: 0 0 18px; padding: 0; display: grid; gap: 8px; }
.price-eg li { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 10px; padding: 12px 16px; background: var(--surface); border-radius: 12px; }
.price-eg span { color: var(--muted); }
.price-eg b { margin-left: auto; font-size: 1.1rem; }
.price-eg span { white-space: nowrap; }
.price-eg small { flex-basis: 100%; text-align: right; color: var(--accent-dark); font-weight: 700; font-size: .8rem; }
.price-eg li:last-child { background: #fff3ea; }
.price-small { margin: 0 0 24px; padding: 16px 18px; border-radius: 12px; background: rgba(46, 160, 92, .14); border: 1px solid rgba(46, 160, 92, .45); }
.price-small b { color: #7fdca3; font-size: 1.05rem; }
.price-small p { margin: 6px 0 0; color: #d9cfc6; font-size: .95rem; }
.price-note { margin: 0; color: var(--muted); font-size: .95rem; }
.price-inc { background: #21160f; color: #f4ece5; border-radius: var(--radius); padding: 30px; display: flex; flex-direction: column; }
.price-inc ul { list-style: none; margin: 0 0 20px; padding: 0; display: grid; gap: 14px; }
.price-inc li { position: relative; padding-left: 30px; color: #cfc3b8; }
.price-inc li::before { content: "✓"; position: absolute; left: 0; top: 0; width: 20px; height: 20px; display: grid; place-items: center; background: var(--good); color: #fff; font-size: .75rem; font-weight: 800; border-radius: 7px; }
.price-inc li b { color: #fff; }
.price-inc .btn { margin-top: auto; align-self: flex-start; }

.price-for { margin-top: 20px; background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 26px 30px; }
.price-for h3 { margin: 0; }
.price-for-sub { margin: 4px 0 18px; color: var(--muted); }
.price-for ul { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px 18px; }
.price-for li { display: grid; align-content: start; gap: 4px; padding-left: 14px; border-left: 3px solid var(--accent); }
.price-for li span { color: var(--muted); font-size: .95rem; }
@media (max-width: 980px) { .price-for ul { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .price-for ul { grid-template-columns: 1fr; } .price-for { padding: 22px; } }

/* Ownership band */
.own { background: #21160f; color: #f4ece5; }
.own-in { display: grid; grid-template-columns: 1.3fr 1fr; gap: 48px; align-items: center; }
.own p { color: #cfc3b8; font-size: 1.1rem; }
.own-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 12px; }
.own-list li { background: #2f241b; border-radius: 14px; padding: 16px 18px; }
.own-list b { color: #ff8a2b; }

/* Steps */
.steps { list-style: none; padding: 0; margin: 0 0 36px; display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.steps li { background: var(--surface); border-radius: var(--radius); padding: 26px; }
.steps span { display: inline-grid; place-items: center; width: 40px; height: 40px; border-radius: 13px; background: var(--accent); color: #fff; font-weight: 800; margin-bottom: 12px; }
.steps p { color: var(--muted); margin: 0; }

/* FAQ */
details { border-bottom: 1px solid var(--border); padding: 18px 0; }
summary { cursor: pointer; font-weight: 700; font-size: 1.08rem; list-style: none; display: flex; justify-content: space-between; gap: 16px; }
summary::-webkit-details-marker { display: none; }
summary::after { content: "+"; color: var(--accent); font-size: 1.4rem; line-height: 1; }
details[open] summary::after { content: "−"; }
details p { color: var(--muted); margin: 10px 0 0; }

/* Buyer band and final call */
.buyers { background: var(--accent); color: #fff; padding: 56px 0; }
.buyers-in { display: flex; align-items: center; justify-content: space-between; gap: 24px; flex-wrap: wrap; }
.buyers p { margin: 0; opacity: .92; }
.final { padding: 88px 0; background: linear-gradient(180deg, #fff, #fff7f0); }

/* Footer */
.foot { background: #16100c; color: #a99b8f; padding: 32px 0 max(32px, env(safe-area-inset-bottom)); }
.foot-in { display: flex; align-items: center; gap: 24px; flex-wrap: wrap; }
.foot img { height: 30px; width: auto; }
.foot nav { display: flex; gap: 18px; margin-left: auto; }
.foot a { text-decoration: none; color: #f4ece5; font-size: .95rem; }
.foot small { width: 100%; }

/* Tablets */
@media (max-width: 980px) {
  .stage-box { --s: .86; }
}
@media (max-width: 900px) {
  .hero-in, .own-in, .price-grid { grid-template-columns: 1fr; }
  .grid3, .steps { grid-template-columns: 1fr 1fr; }
  .stage-box { --s: .9; margin-top: 8px; }
}
/* Phones, portrait */
@media (max-width: 760px) {
  .nav-links { display: none; }
  .nav-in { justify-content: space-between; }
  .grid3, .steps { grid-template-columns: 1fr; }
  .hero { padding: 36px 0 48px; }
  .section { padding: 56px 0; }
  .foot nav { margin-left: 0; }
  .stage-box { --s: .8; }
}
@media (max-width: 640px) {
  /* Comparison: one card per row, with the column name next to each answer. */
  .table-wrap { background: none; box-shadow: none; overflow: visible; }
  .compare thead { display: none; }
  .compare, .compare tbody, .compare tr, .compare th, .compare td { display: block; width: 100%; }
  .compare tr { background: #fff; border-radius: var(--radius); box-shadow: var(--shadow); margin-bottom: 14px; overflow: hidden; }
  .compare tbody th { font-family: "Baloo 2", sans-serif; font-weight: 800; font-size: 1.1rem; padding: 14px 16px 6px; border: 0; }
  .compare td { display: flex; justify-content: space-between; gap: 12px; padding: 10px 16px; border-bottom: 1px solid var(--border); }
  .compare td::before { content: attr(data-label); color: var(--muted); font-weight: 500; }
  .compare td.us::before { color: var(--accent-dark); font-weight: 700; }
  .compare tr td:last-child { border-bottom: 0; }
}
@media (max-width: 400px) {
  .brand img { height: 28px; }
  .btn-sm { padding: 8px 14px; }
  .stage-box { --s: .74; }
}
@media (max-width: 340px) {
  .stage-box { --s: .66; }
}

/*
  Phones and small tablets held sideways: short screens. Keep text and phones side by side and
  small enough that the headline and the main button are visible without scrolling.
*/
@media (orientation: landscape) and (max-height: 560px) {
  .nav-in { height: 52px; }
  .nav-links { display: none; }
  .nav-in { justify-content: space-between; }
  .hero { padding: 22px 0 32px; }
  .hero-in { grid-template-columns: 1.25fr .75fr; gap: 20px; }
  .kicker { margin-bottom: 8px; }
  h1 { font-size: clamp(1.8rem, 7.2vh, 2.6rem); margin-bottom: .3em; }
  .lead { font-size: 1rem; margin-bottom: .6em; }
  .urdu-mix, .ticks { display: none; }
  .cta-row { margin: 4px 0 0; }
  .stage-box { --s: .58; margin-top: 0; }
  .grid3, .steps { grid-template-columns: repeat(3, 1fr); gap: 14px; }
  .own-in { grid-template-columns: 1.3fr 1fr; }
  .section { padding: 48px 0; }
  .card, .steps li { padding: 20px; }
}
@media (orientation: landscape) and (max-height: 420px) {
  .stage-box { --s: .5; }
  .grid3.features { grid-template-columns: 1fr 1fr; }
}

@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } .btn { transition: none; } }

/* Squircle corners where the browser supports them; radii go up so the curve reads as soft, not sharp. */
@supports (corner-shape: squircle) {
  :root { --radius: 30px; --r-sm: 20px; --r-phone: 66px; --r-screen: 54px; }
  .btn, .btn-sm, .kicker, .card, .feat, .table-wrap, .compare tr, .own-list li, .steps li, .steps span,
  .icon, .phone, .screen, .island, .ask, .price-small, .price-card, .price-for, .price-eg li, .price-inc, .price-inc li::before, .toast, .t-ico, .chip, .feat h3::before {
    corner-shape: squircle;
  }
  .btn { border-radius: 26px; }
  .btn-sm { border-radius: 20px; }
  .kicker { border-radius: 16px; }
  .icon { border-radius: 26px; }
  .steps span { border-radius: 22px; }
  .own-list li { border-radius: 24px; }
  .island { border-radius: 20px; }
  .toast { border-radius: 30px; }
  .price-eg li, .price-small { border-radius: 20px; }
  .price-inc li::before { border-radius: 11px; }
  .t-ico { border-radius: 17px; }
  .chip { border-radius: 22px; }
}

/* Links from short pricing lines to the FAQ answer that has the details. Chrome opens the closed <details>
   when the link targets an element inside it; elsewhere the question is highlighted so it is easy to tap. */
.price-note a, .price-small a { color: inherit; font-weight: 700; text-decoration: underline; text-underline-offset: 3px; }
.price-small a { color: #7fdca3; }
details:has(:target) summary { color: var(--accent); }
details { scroll-margin-top: 90px; }
#faq-small, #faq-boosts { scroll-margin-top: 140px; }
