/* Shiling landing page.
   The app's own palette: lime and ink over a paper-grey field, Plus Jakarta Sans.
   Radius rule: buttons and chips are pills, everything else is 28px (16px small). */

@font-face {
  font-family: 'Plus Jakarta Sans';
  src: url('/fonts/jakarta-latin.woff2') format('woff2');
  font-weight: 200 800;
  font-display: swap;
}

:root {
  --bg: #eceeed;
  --surface: #f6f7f6;
  --ink: #101012;
  --ink-2: #55555b;
  --line: rgb(16 16 18 / 0.09);
  --lime: #d6f24f;
  --on-lime: #101012;
  --block: #101012;
  --on-block: #f2f2f2;
  --on-block-2: #a3a3a9;
  --link: #101012;
  --shadow: 0 1px 2px rgb(40 44 42 / 0.05), 0 24px 60px -20px rgb(40 44 42 / 0.28);

  --coin-face: #d6f24f;
  --coin-rim: #b5cf35;
  --coin-ink: #101012;

  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
  --ease-drawer: cubic-bezier(0.32, 0.72, 0, 1);
  --radius: 28px;
  --radius-sm: 16px;
  --gutter: clamp(16px, 5vw, 64px);
  --max: 1200px;

  color-scheme: light dark;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0f0f10;
    --surface: #18181b;
    --ink: #f2f2f2;
    --ink-2: #a3a3a9;
    --line: rgb(255 255 255 / 0.09);
    --block: #18181b;
    --link: #d6f24f;
    --shadow: 0 1px 2px rgb(0 0 0 / 0.3), 0 30px 70px -24px rgb(0 0 0 / 0.7);
  }
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: 'Plus Jakarta Sans', ui-sans-serif, system-ui, sans-serif;
  font-size: 17px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: clip;
}

img, video, svg { display: block; max-width: 100%; }
h1, h2, h3, p, figure, ol { margin: 0; }
.defs { position: absolute; }
.num { font-variant-numeric: tabular-nums; font-feature-settings: 'tnum' 1; }
::selection { background: var(--lime); color: var(--on-lime); }

:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; border-radius: 6px; }
.access :focus-visible { outline-color: var(--lime); }

/* Type */
.display {
  font-size: clamp(48px, 8.4vw, 112px);
  font-weight: 700;
  letter-spacing: -0.05em;
  line-height: 0.98;
  text-wrap: balance;
}
.h2 {
  font-size: clamp(32px, 4.6vw, 56px);
  font-weight: 680;
  letter-spacing: -0.04em;
  line-height: 1.04;
  text-wrap: balance;
}
.h3 { font-size: 21px; font-weight: 650; letter-spacing: -0.025em; line-height: 1.2; }
/* splitText clips each word; give descenders room inside the clip. */
.display > span:not([style*="absolute"]) { display: inline-block; padding-bottom: 0.14em; margin-bottom: -0.14em; }
.lede { font-size: clamp(18px, 1.6vw, 21px); color: var(--ink-2); max-width: 30ch; text-wrap: pretty; }
.body { color: var(--ink-2); max-width: 46ch; text-wrap: pretty; }

/* Buttons. Press feedback on every one; hover only where a pointer can hover. */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  height: 52px; padding: 0 26px; border-radius: 999px; border: 0;
  font: inherit; font-size: 16px; font-weight: 650; letter-spacing: -0.01em;
  text-decoration: none; white-space: nowrap; cursor: pointer;
  transition: transform 160ms var(--ease-out), background-color 200ms ease, box-shadow 200ms ease;
}
.btn:active { transform: scale(0.97); }
.btn-sm { height: 40px; padding: 0 18px; font-size: 14.5px; }
.btn-ink { background: var(--ink); color: var(--bg); }
.btn-lime { background: var(--lime); color: var(--on-lime); }
.btn-ghost { background: transparent; color: var(--ink); box-shadow: inset 0 0 0 1.5px var(--line); }
@media (hover: hover) and (pointer: fine) {
  .btn-ghost:hover { box-shadow: inset 0 0 0 1.5px var(--ink); }
  .btn-ink:hover, .btn-lime:hover { box-shadow: 0 10px 24px -10px rgb(16 16 18 / 0.5); }
  .link:hover { text-decoration-color: currentColor; }
}
.icon { width: 18px; height: 18px; fill: currentColor; flex: none; }
.icon-lg { width: 28px; height: 28px; }
.link {
  color: var(--link); font-weight: 600; text-decoration: underline;
  text-decoration-color: transparent; text-underline-offset: 4px; transition: text-decoration-color 200ms ease;
}

/* The 3D coin. One fixed canvas between the section backgrounds and their
   content: it passes behind text and cards, and in front of the ink block. */
/* Placed in the document, not fixed: at rest it scrolls with the page on the
   compositor, and JS only moves it while it travels. Hidden until placed. */
.coin-wrap { position: absolute; top: 0; left: 0; z-index: 1; pointer-events: none; will-change: transform; visibility: hidden; }
.coin-wrap.is-on { visibility: visible; }
/* The resting breath, on the GPU: no redraw, no script. */
.coin3d { display: block; width: 100%; height: 100%; animation: coin-breathe 4.6s ease-in-out infinite; }
@keyframes coin-breathe { 50% { transform: translateY(-6px) rotate(1.2deg); } }
main section > * { position: relative; z-index: 2; }
/* The phone sits under the coin, so the coin can pass in front of it. */
.hero > .hero-shot, .taps > .taps-shot { z-index: 0; }
main section { position: relative; }

/* Stops on the coin's route. Each is a point (or, in flow, a reserved box)
   the coin centres on while its section is on screen. A stop that is hidden
   at a width is skipped at that width. */
.spot { position: absolute; width: 1px; height: 1px; pointer-events: none; }
.spot-flow { position: relative; width: 100%; height: 280px; }
.spot-hero { left: 8%; top: 74%; }
/* Narrow screens: the coin gets its own room, centred above the wordmark. */
.spot-name { position: relative; width: 100%; height: clamp(160px, 44vw, 260px); }
.spot-taps-m { right: 18%; top: 86%; }
.spot-ledger, .spot-taps, .spot-weeks, .spot-bento, .spot-faq { display: none; }
@media (min-width: 900px) {
  .spot-hero { left: -14%; top: 66%; }
  .spot-ledger, .spot-taps, .spot-bento { display: block; }
  .spot-taps-m { display: none; }
  .spot-bento { right: 11vw; top: calc(clamp(64px, 9vw, 120px) + 4px); }
  /* Wide screens: beside the wordmark, out of the flow. */
  .spot-name { position: absolute; width: 1px; height: 1px; left: calc(50% + 370px); top: calc(clamp(64px, 9vw, 120px) + 130px); }
}
@media (min-width: 1200px) {
  .spot-weeks, .spot-faq { display: block; }
  .spot-weeks { right: 12vw; top: calc(clamp(64px, 9vw, 120px) + 40px); }
  .spot-faq { right: 12vw; top: 58%; }
}

/* Layout */
section { padding: clamp(64px, 9vw, 120px) var(--gutter); }
section > * { max-width: var(--max); margin-inline: auto; }

.nav {
  position: sticky; top: 0; z-index: 10;
  display: flex; align-items: center; justify-content: space-between;
  height: 68px; padding: 0 var(--gutter);
  background: color-mix(in srgb, var(--bg) 78%, transparent);
  backdrop-filter: blur(16px) saturate(160%);
  -webkit-backdrop-filter: blur(16px) saturate(160%);
}
.brand { display: flex; align-items: center; gap: 10px; color: var(--ink); text-decoration: none; font-weight: 700; font-size: 19px; letter-spacing: -0.03em; }
.brand img { border-radius: 9px; }
.nav-links { display: flex; align-items: center; gap: clamp(14px, 3vw, 28px); font-size: 15px; white-space: nowrap; }
@media (max-width: 400px) { .brand span { display: none; } }

/* Hero: copy left, the real home screen right. Stacks under 900px. */
.hero {
  display: grid; gap: 48px; align-items: center;
  min-height: calc(100dvh - 68px);
  padding-top: clamp(24px, 6vw, 80px); padding-bottom: clamp(48px, 8vw, 96px);
  max-width: calc(var(--max) + 2 * var(--gutter)); margin-inline: auto;
}
.hero > * { max-width: none; margin: 0; }
.hero-copy { display: grid; gap: 28px; }
.cta-row { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 8px; }
.hero-shot { justify-self: center; width: min(68vw, 360px); }
.hero-shot img, .taps-shot img { width: 100%; height: auto; filter: drop-shadow(0 40px 50px rgb(16 16 18 / 0.22)); }
@media (min-width: 900px) {
  .hero { grid-template-columns: 1.15fr 0.85fr; }
  .hero-shot { justify-self: end; margin-right: 4%; }
}

/* Ledger: the payday arithmetic, set like a receipt. */
.ledger { display: grid; gap: 48px; align-items: center; max-width: calc(var(--max) + 2 * var(--gutter)); margin-inline: auto; }
.ledger > * { max-width: none; margin: 0; }
.ledger-head { display: grid; gap: 20px; }
.ledger-sheet {
  background: var(--surface); border-radius: var(--radius); box-shadow: var(--shadow);
  padding: clamp(20px, 3vw, 36px); display: grid; gap: 4px;
}
.ledger-row { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; padding: 14px 4px; font-size: 18px; font-weight: 550; }
.ledger-row b { font-weight: 500; }
.ledger-row.bill { color: var(--ink-2); }
.ledger-salary b { font-size: clamp(26px, 3vw, 34px); font-weight: 300; letter-spacing: -0.04em; color: var(--ink); }
.ledger-left { margin-top: 10px; padding-top: 22px; border-top: 1px solid var(--line); }
.ledger-left b { font-size: clamp(40px, 5vw, 60px); font-weight: 300; letter-spacing: -0.05em; line-height: 1; }
.ledger-left small { font-size: 16px; font-weight: 600; letter-spacing: 0; color: var(--ink-2); }
@media (min-width: 900px) { .ledger { grid-template-columns: 1fr 1fr; gap: 80px; } }

/* Weeks: four tall columns, the current one in lime. */
.weeks { display: grid; gap: 20px; }
.weeks .h2, .weeks .body { margin-inline: auto; text-align: center; }
.week-strip {
  list-style: none; padding: 0; margin-top: 40px;
  display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; width: 100%;
}
.week {
  position: relative; overflow: hidden; isolation: isolate;
  min-height: 200px; padding: 20px; border-radius: var(--radius);
  background: var(--surface); display: flex; flex-direction: column; justify-content: space-between;
}
.week-v { display: grid; gap: 2px; }
.week small { font-size: 14px; font-weight: 550; color: var(--ink-2); }
.week.done { opacity: 0.55; }
.week.now { background: var(--lime); color: var(--on-lime); }
.week.now small { color: rgb(16 16 18 / 0.66); }
/* What is spent of this week, filling up from the bottom. */
.week i { position: absolute; inset: 0; z-index: -1; background: rgb(16 16 18 / 0.08); transform-origin: bottom; transform: scaleY(var(--fill)); }
.week-n { font-size: 14px; font-weight: 650; }
.week b { font-size: clamp(24px, 2.6vw, 32px); font-weight: 300; letter-spacing: -0.04em; }
@media (min-width: 720px) { .week-strip { grid-template-columns: repeat(4, 1fr); } .week { min-height: 280px; } }

/* Taps: the purchase sheet left, copy right. */
.taps { display: grid; gap: 48px; align-items: center; max-width: calc(var(--max) + 2 * var(--gutter)); margin-inline: auto; }
.taps > * { max-width: none; margin: 0; }
.taps-shot { width: min(68vw, 340px); justify-self: center; }
.taps-copy { display: grid; gap: 20px; }
@media (min-width: 900px) { .taps { grid-template-columns: 0.9fr 1.1fr; gap: 96px; } }

/* Bento: a wide payday cell, two squares, a wide report cell. */
.bento .h2 { margin-bottom: 40px; }
.bento-grid { display: grid; gap: 12px; }
.cell {
  display: grid; align-content: start; gap: 12px;
  padding: clamp(24px, 3vw, 36px); border-radius: var(--radius); background: var(--surface);
  min-height: 220px;
}
.cell p { color: var(--ink-2); max-width: 38ch; }
.cell .icon-lg { margin-bottom: 20px; }
.cell-lime { background: var(--lime); color: var(--on-lime); }
.cell-lime p { color: rgb(16 16 18 / 0.72); }
.cell-ink { background: var(--block); color: var(--on-block); }
.cell-ink p { color: var(--on-block-2); }
.cell-ink .icon-lg { fill: var(--lime); }
@media (prefers-color-scheme: dark) { .cell-ink { box-shadow: inset 0 0 0 1px var(--line); } }
@media (min-width: 900px) {
  .bento-grid { grid-template-columns: repeat(3, 1fr); grid-auto-rows: minmax(240px, auto); }
  .cell-lime { grid-column: span 2; }
  .cell-wide { grid-column: span 2; }
}

/* Name: the wordmark drawn as you arrive. */
.name { text-align: center; display: grid; gap: 20px; justify-items: center; }
.name .body { margin-inline: auto; }
.name-mark { width: min(78vw, 420px); color: var(--ink); margin-bottom: 12px; }
.name-mark svg { overflow: visible; }
[lang="ar"] { font-family: system-ui, sans-serif; }

/* FAQ */
.faq { display: grid; gap: 32px; }
.faq .h2 { max-width: 760px; }
.faq-list { display: grid; gap: 8px; max-width: 760px; width: 100%; }
.faq details { background: var(--surface); border-radius: var(--radius-sm); interpolate-size: allow-keywords; }
.faq details::details-content { block-size: 0; overflow: clip; transition: block-size 260ms var(--ease-drawer), content-visibility 260ms allow-discrete; }
.faq details[open]::details-content { block-size: auto; }
.faq summary {
  list-style: none; cursor: pointer; padding: 20px 22px; font-weight: 620; letter-spacing: -0.015em;
  display: flex; justify-content: space-between; align-items: center; gap: 16px; border-radius: var(--radius-sm);
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: ''; width: 14px; height: 14px; flex: none;
  background: linear-gradient(currentColor 0 0) center / 14px 2px no-repeat, linear-gradient(currentColor 0 0) center / 2px 14px no-repeat;
  transition: transform 260ms var(--ease-drawer);
}
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { padding: 0 22px 22px; color: var(--ink-2); max-width: 60ch; }

/* Access: the one ink block, where the coins land. */
.access {
  position: relative; overflow: hidden;
  background: var(--block); color: var(--on-block);
  padding-bottom: 0;
}
@media (prefers-color-scheme: dark) { .access { box-shadow: inset 0 1px 0 var(--line); } }
.access .body { color: var(--on-block-2); }
.access-inner { display: grid; gap: 20px; padding-bottom: clamp(48px, 8vw, 120px); }
/* Where the coin lands. Its shadow fades in as the coin comes down. */
.landing.spot { width: 100%; height: 240px; position: relative; z-index: 0; }
.landing::after {
  content: ''; position: absolute; left: 50%; top: calc(50% + var(--shadow-y, 60px)); width: var(--shadow-w, 200px); height: 26px; translate: -50% -50%;
  /* On ink a dark shadow vanishes; light bouncing off the coin reads instead. */
  background: radial-gradient(closest-side, rgb(214 242 79 / 0.22), transparent); opacity: var(--land, 0);
}
@media (min-width: 900px) {
  .landing.spot { position: absolute; right: 0; top: 50%; translate: 0 -50%; width: 340px; height: 340px; }
}

.form { display: grid; gap: 18px; margin-top: 20px; max-width: 640px; }
.field { display: grid; gap: 8px; }
.field label { font-size: 14.5px; font-weight: 600; color: var(--on-block); }
.opt { font-weight: 500; color: var(--on-block-2); margin-left: 6px; }
.field input, .field textarea {
  font: inherit; font-size: 16px; color: var(--on-block);
  background: rgb(255 255 255 / 0.06); border: 0; border-radius: var(--radius-sm);
  box-shadow: inset 0 0 0 1px rgb(255 255 255 / 0.14);
  padding: 14px 16px; width: 100%; resize: vertical;
  transition: box-shadow 160ms ease;
}
.field input:focus, .field textarea:focus { outline: none; box-shadow: inset 0 0 0 2px var(--lime); }
.field input[aria-invalid='true'] { box-shadow: inset 0 0 0 2px #ff8a7a; }
.field-err { font-size: 14px; color: #ff9d90; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.form-foot { display: flex; flex-wrap: wrap; align-items: center; gap: 16px; }
.form-status { font-size: 15px; color: var(--on-block-2); }
.form-status[data-state='ok'] { color: var(--lime); }
@media (min-width: 720px) { .form { grid-template-columns: 1fr 1fr; } .field-full, .form-foot { grid-column: 1 / -1; } }

.foot { display: flex; justify-content: space-between; gap: 16px;
  padding: 24px 0 calc(24px + env(safe-area-inset-bottom)); font-size: 14px; color: var(--on-block-2);
  border-top: 1px solid rgb(255 255 255 / 0.1);
}
.foot .link { color: var(--lime); white-space: nowrap; }


/* Entrance states. Only once main.js has claimed them, and never under reduced motion. */
@media (prefers-reduced-motion: no-preference) {
  .js .hero-copy > *, .js .hero-shot { opacity: 0; }
}
