/* The landing page. The other pages use site.css, which carries the same palette
   and type. Sides are logical (start/end, inline/block) so the Arabic page,
   dir="rtl", mirrors without its own rules. */
:root {
  color-scheme: light dark;
  --dusk: #4a2c54;
  --dusk-2: #6b3a63;
  --plum: #8f4a63;
  --coral: #ee7d54;
  --peach: #f6b38a;
  --sun: #f7d9a8;

  --bg: #fbf3ec;
  --bg-soft: #ffffff;
  --bg-card: #ffffff;
  --ink: #2a1f2e;
  --ink-soft: #6a5a68;
  --line: #ecdccf;
  --accent: #d5623b;
  --accent-ink: #ffffff;
  --shadow: 30px 60px 120px -40px rgba(74, 44, 84, .35);
  --hero-text: #fff;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #17121d;
    --bg-soft: #1f1826;
    --bg-card: #221a2b;
    --ink: #f4ecf3;
    --ink-soft: #b6a6b8;
    --line: #362a40;
    --accent: #f4966b;
    --accent-ink: #24141a;
    --shadow: 30px 60px 120px -40px rgba(0, 0, 0, .7);
  }
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  background: var(--bg);
  color: var(--ink);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; display: block; }
.wrap { width: 100%; max-width: 1080px; margin: 0 auto; padding: 0 24px; }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  overflow: hidden;
  color: var(--hero-text);
  background:
    radial-gradient(120% 90% at 80% -10%, rgba(247, 217, 168, .55), transparent 55%),
    linear-gradient(160deg, var(--dusk) 0%, var(--dusk-2) 30%, var(--plum) 55%, var(--coral) 100%);
}
.hero::after {
  content: "";
  position: absolute;
  inset-inline-end: -12%;
  top: -18%;
  width: 46vw;
  max-width: 520px;
  aspect-ratio: 1;
  background: radial-gradient(circle, rgba(247, 217, 168, .9), rgba(238, 125, 84, 0) 62%);
  filter: blur(6px);
  pointer-events: none;
}
.nav {
  position: relative;
  z-index: 3; /* above .hero__grid, so the language list opens over the phone */
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 22px 0 8px;
}
.nav__brand { display: flex; align-items: center; gap: 12px; font-weight: 700; font-size: 1.1rem; letter-spacing: -.01em; }
.nav__brand img { width: 40px; height: 40px; border-radius: 11px; box-shadow: 0 4px 14px rgba(0,0,0,.25); }
.nav__spacer { flex: 1; }
.nav__link { color: rgba(255,255,255,.85); font-weight: 600; font-size: .95rem; }
.nav__link:hover { color: #fff; }

/* ---------- Language picker ----------
   locales.py writes it into every page's nav; the same rules are in site.css and
   home.css. No script: a <details> opens and closes the list. */
.langs { position: relative; }
.langs > summary {
  display: flex; align-items: center; gap: 6px; cursor: pointer; list-style: none;
  color: rgba(255,255,255,.85); font-weight: 600; font-size: .95rem;
}
.langs > summary::-webkit-details-marker { display: none; }
.langs > summary:hover, .langs[open] > summary { color: #fff; }
.langs > summary svg { width: 17px; height: 17px; flex: none; }
.langs ul {
  position: absolute; z-index: 10; top: calc(100% + 10px); inset-inline-end: 0;
  display: grid; grid-template-columns: repeat(2, auto); gap: 2px;
  margin: 0; padding: 8px; list-style: none;
  background: var(--bg-card); border: 1px solid var(--line); border-radius: 14px;
  box-shadow: 0 24px 50px -20px rgba(42,31,46,.45);
}
.langs li { margin: 0; }
.langs a { display: block; padding: 7px 12px; border-radius: 9px; color: var(--ink); font-size: .93rem; font-weight: 500; white-space: nowrap; }
.langs a:hover { background: var(--bg); text-decoration: none; }
.langs a[aria-current] { color: var(--accent); font-weight: 700; }

.hero__grid {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: 1.05fr .95fr;
  gap: 32px;
  align-items: center;
  padding: 56px 0 84px;
}
.hero h1 {
  font-size: clamp(2.6rem, 6vw, 4.1rem);
  line-height: 1.03;
  letter-spacing: -.03em;
  margin: 10px 0 18px;
  font-weight: 800;
}
.hero__lead {
  font-size: clamp(1.1rem, 2.2vw, 1.4rem);
  color: rgba(255,255,255,.9);
  max-width: 34ch;
  margin: 0 0 30px;
}
.pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(255,255,255,.16);
  border: 1px solid rgba(255,255,255,.28);
  backdrop-filter: blur(6px);
  color: #fff;
  font-size: .82rem;
  font-weight: 600;
  letter-spacing: .02em;
  padding: 6px 14px;
  border-radius: 999px;
}
.cta-row { display: flex; flex-wrap: wrap; gap: 14px; align-items: center; }
.badge-store {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  background: #000;
  color: #fff;
  padding-block: 12px;
  padding-inline: 18px 20px;
  border-radius: 14px;
  font-weight: 600;
  box-shadow: 0 10px 30px -8px rgba(0,0,0,.5);
  transition: transform .15s ease;
}
.badge-store:hover { text-decoration: none; transform: translateY(-2px); }
.badge-store svg { width: 26px; height: 26px; flex: none; }
.badge-store .small { display: block; font-size: .68rem; font-weight: 500; opacity: .8; line-height: 1; margin-bottom: 3px; }
.badge-store .big { display: block; font-size: 1.18rem; line-height: 1; letter-spacing: -.01em; }
.cta-note { display: flex; flex-direction: column; gap: 3px; color: rgba(255,255,255,.8); font-size: .85rem; line-height: 1.3; }
.cta-note span { white-space: nowrap; }

/* Phone frame in hero */
.phone {
  justify-self: center;
  width: min(280px, 74vw);
  border-radius: 42px;
  padding: 11px;
  background: linear-gradient(160deg, #2b2530, #14101a);
  box-shadow: var(--shadow), 0 0 0 2px rgba(255,255,255,.06) inset;
}
.phone__screen { position: relative; border-radius: 32px; overflow: hidden; background: #000; }
.phone__screen img { display: block; width: 100%; height: auto; }
.phone__notch {
  position: absolute; top: 10px; left: 50%; transform: translateX(-50%);
  width: 34%; height: 22px; background: #0a0710; border-radius: 12px; z-index: 3;
}

/* ---------- Sections ---------- */
section { padding: 84px 0; }
.eyebrow { text-transform: uppercase; letter-spacing: .14em; font-size: .78rem; font-weight: 700; color: var(--accent); margin: 0 0 12px; }
h2 { font-size: clamp(1.8rem, 3.6vw, 2.6rem); letter-spacing: -.02em; line-height: 1.1; margin: 0 0 16px; font-weight: 800; }
.section-lead { font-size: 1.12rem; color: var(--ink-soft); max-width: 60ch; margin: 0 0 8px; }

.features { padding-top: 20px; }
.feature-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
  margin-top: 40px;
}
@media (min-width: 561px) {
  .feature-grid { grid-template-columns: repeat(2, 1fr); }
  /* The odd card out sits centred under the pairs, at the same width. */
  .feature-grid .card:last-child:nth-child(odd) { grid-column: 1 / -1; justify-self: center; width: calc(50% - 10px); }
}
@media (min-width: 1101px) {
  /* One row of five equal cards; wider than .wrap so the text stays readable. */
  .feature-grid {
    grid-template-columns: repeat(5, 1fr);
    margin-inline: calc((100% - min(100vw - 80px, 1200px)) / 2);
  }
  .feature-grid .card:last-child:nth-child(odd) { grid-column: auto; width: auto; }
  .feature-grid .card { padding: 24px 22px; }
  .feature-grid .card h3 { font-size: 1.1rem; }
  .feature-grid .card p { font-size: .94rem; }
}
.card {
  background: var(--bg-card);
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 28px;
  box-shadow: 0 18px 40px -34px rgba(74,44,84,.55);
}
.card__ico {
  width: 46px; height: 46px; border-radius: 13px;
  display: grid; place-items: center; margin-bottom: 18px;
  background: linear-gradient(150deg, var(--coral), var(--plum));
  color: #fff;
}
.card__ico svg { width: 24px; height: 24px; }
.card h3 { margin: 0 0 8px; font-size: 1.22rem; letter-spacing: -.01em; }
.card p { margin: 0; color: var(--ink-soft); font-size: .98rem; }

/* Showcase (alternating screenshots) */
.showcase { background: var(--bg-soft); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.show-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: center;
}
.show-row + .show-row { margin-top: 96px; }
.show-row--flip .show-copy { order: 2; }
.show-copy h2 { font-size: clamp(1.6rem, 3vw, 2.1rem); }
.show-copy p { color: var(--ink-soft); font-size: 1.05rem; }
.show-copy .note {
  margin: 22px 0 0; padding: 16px 18px; font-size: .92rem; line-height: 1.55;
  border-radius: 14px; background: var(--bg-soft); border: 1px solid var(--line);
}
.show-list { list-style: none; padding: 0; margin: 20px 0 0; }
.show-list li { position: relative; padding-inline-start: 30px; margin: 12px 0; color: var(--ink-soft); }
.show-list li::before {
  content: ""; position: absolute; inset-inline-start: 0; top: .5em;
  width: 16px; height: 9px; border-left: 2.5px solid var(--accent); border-bottom: 2.5px solid var(--accent);
  transform: rotate(-45deg);
}
.show-phone {
  justify-self: center;
  width: min(300px, 76vw);
  border-radius: 42px;
  padding: 11px;
  background: linear-gradient(160deg, #2b2530, #14101a);
  box-shadow: var(--shadow);
}
.show-phone .phone__screen { border-radius: 32px; }

/* iPad frame — landscape, so the 4:3 screen carries a 2752x2064 capture
   at its own aspect and the side-by-side editor reads at a glance. */
.ipad-row { text-align: center; }
.tablet {
  margin: 40px auto 0;
  width: min(880px, 92vw);
  border-radius: 26px;
  padding: 13px;
  background: linear-gradient(160deg, #2b2530, #14101a);
  box-shadow: var(--shadow), 0 0 0 2px rgba(255,255,255,.06) inset;
}
.tablet__screen { border-radius: 14px; overflow: hidden; background: #000; }
.tablet__screen img { display: block; width: 100%; height: auto; }

/* Free banner */
.free {
  text-align: center;
  color: #fff;
  background:
    radial-gradient(90% 120% at 50% 0%, rgba(247,217,168,.35), transparent 60%),
    linear-gradient(150deg, var(--dusk-2), var(--plum) 55%, var(--coral));
  border-radius: 28px;
  padding: 64px 28px;
  margin: 0 auto;
}
.free h2 { color: #fff; }
.free p { color: rgba(255,255,255,.9); font-size: 1.15rem; max-width: 46ch; margin: 0 auto 28px; }
.chips { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; margin-top: 26px; }
.chip { background: rgba(255,255,255,.16); border: 1px solid rgba(255,255,255,.26); color: #fff; padding: 8px 16px; border-radius: 999px; font-size: .9rem; font-weight: 600; }

.center { text-align: center; }
.badge-store--light { background: #fff; color: #111; box-shadow: 0 12px 30px -10px rgba(0,0,0,.4); }

/* Footer */
footer { background: var(--bg-soft); border-top: 1px solid var(--line); padding: 56px 0 44px; }
.foot-grid { display: flex; flex-wrap: wrap; gap: 28px 48px; align-items: flex-start; justify-content: space-between; }
.foot-brand { display: flex; align-items: center; gap: 12px; font-weight: 700; }
.foot-brand img { width: 36px; height: 36px; border-radius: 10px; }
.foot-links { display: flex; flex-wrap: wrap; gap: 20px 28px; }
.foot-links a { color: var(--ink-soft); font-weight: 600; }
.foot-links a:hover { color: var(--accent); }
.foot-note { margin-top: 32px; color: var(--ink-soft); font-size: .86rem; }
.foot-note .byline { display: inline-flex; align-items: center; gap: 3px; color: var(--accent); font-weight: 600; }
.foot-note .byline svg { width: 10px; height: 10px; margin-top: 1px; opacity: .8; transition: transform .15s ease; }
.foot-note .byline:hover svg { transform: translate(1px, -1px); }

@media (max-width: 820px) {
  .hero__grid { grid-template-columns: 1fr; gap: 8px; padding: 30px 0 64px; text-align: start; }
  .phone { margin-top: 26px; }
  .nav__link { display: none; }
  .show-row { grid-template-columns: 1fr; gap: 28px; }
  .show-row--flip .show-copy { order: 0; }
  .show-phone { margin-bottom: 4px; }
  .tablet { padding: 8px; border-radius: 18px; }
  section { padding: 60px 0; }
}
