/* Nabzs website: a calm showcase.
   Open white space, big type, real phones. No boxes, no cards, no chips.
   Shadows are baked into the images, so scrolling only moves layers (transform and opacity). */

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

:root {
  --ground: #FFFFFF;
  --ink: #111214;
  --muted: #6A6E77;
  --faint: #B0B3BA;
  --dark: #0A0F1F; /* night blue, not black */
  --green: #0E2A22;
  --sun: #FFD83D;
  --font: "Jakarta", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  --gutter: clamp(20px, 5vw, 64px);
  --section: clamp(120px, 14vw, 200px);
  --fade: clamp(280px, 46vh, 500px); /* how tall each soft colour change between sections is */
  /* The fades travel through colour, never through flat grey:
     day into night through soft lavender blue, night into green through deep teal, green into day through mint. */
  --dusk: linear-gradient(180deg, #FFFFFF 0%, #F7F8FE 10%, #E9ECFB 21%, #CDD3F5 33%, #A2ABE3 46%, #6E79C0 59%, #414B93 71%, #232B5E 82%, #131A39 91%, #0A0F1F 100%);
  --night-to-green: linear-gradient(180deg, #0A0F1F 0%, #0A1320 25%, #0B1A21 50%, #0C2222 75%, #0E2A22 100%);
  --green-to-day: linear-gradient(180deg, #0E2A22 0%, #133428 12%, #1F4A3C 25%, #356A57 38%, #5B917C 51%, #8DBBA6 63%, #BADBCB 75%, #DDEFE6 86%, #F3FAF6 94%, #FFFFFF 100%);
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--ground);
  color: var(--ink);
  font: 400 17px/1.5 var(--font);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: clip;
}
img { display: block; max-width: 100%; height: auto; }
h1, h2, h3, p, ul { margin: 0; }
a { color: inherit; text-decoration: none; }
:focus-visible { outline: 3px solid #3450F0; outline-offset: 3px; border-radius: 8px; }
.center { text-align: center; }

/* ---------- type ---------- */
.display {
  font-size: clamp(40px, 5.4vw, 80px);
  font-weight: 650;
  letter-spacing: -0.045em;
  line-height: 1;
}
.display .line, .display .line > span { display: block; }
.br-phone { display: none; }
@media (max-width: 560px) { .br-phone { display: inline; } }
.h2 {
  font-size: clamp(38px, 5.6vw, 80px);
  font-weight: 650;
  letter-spacing: -0.045em;
  line-height: 1;
  text-wrap: balance;
}
.h3 { font-size: clamp(32px, 3.6vw, 54px); font-weight: 650; letter-spacing: -0.04em; line-height: 1.02; }
.lead {
  font-size: clamp(17px, 1.45vw, 21px);
  line-height: 1.5;
  color: var(--muted);
  max-width: 34ch;
  text-wrap: pretty;
}
.head { display: grid; justify-items: center; gap: 20px; padding-inline: var(--gutter); }

.cta {
  display: inline-block;
  background: var(--sun);
  color: var(--ink);
  font-size: 16px; font-weight: 650;
  padding: 16px 26px;
  border-radius: 99px;
  margin-top: 8px;
}

.phone { user-select: none; -webkit-user-drag: none; }

/* ---------- nav ---------- */
.nav {
  position: fixed; z-index: 50;
  top: calc(16px + env(safe-area-inset-top, 0px));
  left: 0; right: 0; margin-inline: auto;
  width: max-content; max-width: calc(100% - 24px);
  display: flex; align-items: center; gap: 2px;
  padding: 6px 6px 6px 14px;
  border-radius: 99px;
  background: rgba(255, 255, 255, .9);
  border: 1px solid rgba(17, 18, 20, .06);
  box-shadow: 0 8px 24px rgba(17, 18, 20, .06);
  white-space: nowrap;
}
.brand { display: flex; align-items: center; gap: 9px; font-size: 17px; font-weight: 720; letter-spacing: -0.025em; }
.nav .brand { margin-right: 16px; }
.nav__links a { padding: 9px 14px; font-size: 15px; font-weight: 520; color: var(--muted); border-radius: 99px; transition: color .2s; }
.nav__links a:hover { color: var(--ink); }
.nav__soon { margin-left: 4px; background: var(--ink); color: #fff; font-size: 14px; font-weight: 600; padding: 10px 16px; border-radius: 99px; }

/* ---------- 1 · hero ---------- */
.hero {
  --pw: clamp(300px, 33vw, 480px); /* the phone image, shadow included */
  position: relative; isolation: isolate;
  display: flex; flex-direction: column;
  height: max(100svh, 780px);
  overflow: clip;
}
.hero__sky { position: absolute; inset: 0; z-index: -1; }
.hero__sky img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 70%; }
.hero__sky::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(255, 255, 255, 0) 42%, rgba(255, 255, 255, .75) 76%, #fff 97%); }
.hero__copy { position: relative; z-index: 2; display: grid; justify-items: center; gap: 22px; text-align: center; padding: clamp(120px, 17vh, 176px) 20px 0; }
.hero__stage { position: relative; flex: 1; margin-top: clamp(28px, 5vh, 56px); }
.hero__phone { position: absolute; left: 50%; top: 0; width: var(--pw); translate: -50% 0; will-change: transform; }
.bubble {
  position: absolute; z-index: 3;
  max-width: 250px;
  padding: 13px 18px;
  border-radius: 22px;
  font-size: 16px; font-weight: 550; line-height: 1.35;
  background: #fff;
  box-shadow: 0 12px 30px rgba(17, 18, 20, .10), 0 2px 6px rgba(17, 18, 20, .06);
  will-change: transform;
}
.bubble--out { right: calc(50% + var(--pw) * .36); top: 30px; background: #E5EDFF; border-bottom-right-radius: 6px; }
.bubble--in { left: calc(50% + var(--pw) * .34); top: 128px; border-bottom-left-radius: 6px; }

/* ---------- 2 · languages ---------- */
.langs { text-align: center; padding: clamp(80px, 9vw, 130px) 20px 0; }
.langs__label { font-size: 15px; font-weight: 550; color: var(--muted); }
.langs__row { list-style: none; padding: 0; margin-top: 22px; display: flex; flex-wrap: wrap; justify-content: center; gap: 8px clamp(22px, 4vw, 56px); }
.langs__row li { font-size: clamp(24px, 2.6vw, 36px); font-weight: 650; letter-spacing: -0.02em; line-height: 1.3; color: var(--faint); }
.deva { font-family: "Noto Sans Devanagari", var(--font); letter-spacing: 0 !important; }
.beng { font-family: "Noto Sans Bengali", var(--font); letter-spacing: 0 !important; }
.taml { font-family: "Noto Sans Tamil", var(--font); letter-spacing: 0 !important; }
.telu { font-family: "Noto Sans Telugu", var(--font); letter-spacing: 0 !important; }

/* ---------- 3 · stories ---------- */
.stories { padding-top: var(--section); }
.stories .h2 { max-width: 14ch; margin-inline: auto; padding-inline: 20px; }
.stories__strip { margin-top: clamp(48px, 6vw, 80px); overflow: hidden; }
.stories__track { display: flex; gap: clamp(16px, 2vw, 28px); width: max-content; padding-inline: 6vw; will-change: transform; }
.stories__track img { width: clamp(240px, 23vw, 340px); aspect-ratio: 3 / 4; object-fit: cover; border-radius: 28px; background: #EEF0F3; }

/* ---------- 4 · three phones ---------- */
.trio { padding-top: var(--section); }
/* Three whole phones, crisp, nothing faded or cut. */
.trio__stage {
  --cw: clamp(250px, 25vw, 370px);
  position: relative;
  height: calc(var(--cw) * 1.97);
  margin-top: clamp(48px, 6vw, 80px);
}
.trio__phone { position: absolute; top: 0; translate: -50% 0; will-change: transform; }
.trio__phone--c { left: 50%; width: var(--cw); z-index: 2; }
.trio__phone--l { left: calc(50% - var(--cw) * .96); width: calc(var(--cw) * .86); top: 7%; rotate: -5deg; }
.trio__phone--r { left: calc(50% + var(--cw) * .96); width: calc(var(--cw) * .86); top: 7%; rotate: 5deg; }

/* ---------- 5 · paperwork (dark, pinned) ---------- */
/* White eases into the dark over --fade, then the headline. */
.paper { position: relative; isolation: isolate; background: var(--dark); color: #F3F4F6; margin-top: clamp(60px, 8vw, 120px); padding-top: calc(var(--fade) + clamp(40px, 5vw, 80px)); }
.paper::before { content: ""; position: absolute; z-index: -1; left: 0; right: 0; top: -1px; height: var(--fade); background: var(--dusk); pointer-events: none; }
.paper .lead { color: #9EA2AB; }
.paper__scene { position: relative; height: 100vh; height: 100svh; max-width: 1280px; margin-inline: auto; overflow: hidden; }
.paper__steps { position: absolute; left: var(--gutter); top: 50%; width: 33%; }
.step { position: absolute; left: 0; right: 0; top: 0; translate: 0 -50%; display: grid; gap: 18px; opacity: 0; }
.step.is-on { opacity: 1; }
.step p { font-size: clamp(17px, 1.45vw, 21px); color: #9EA2AB; max-width: 28ch; }
.paper__device {
  --dw: min(30vw, 440px, calc((100svh - 120px) * .508));
  position: absolute; left: 74%; top: 52%;
  width: var(--dw); aspect-ratio: 1100 / 2165;
  translate: -50% -50%;
}
.paper__glow { position: absolute; left: 50%; top: 48%; width: 220%; aspect-ratio: 1; translate: -50% -50%; border-radius: 50%; background: radial-gradient(closest-side, rgba(255, 236, 200, .14), rgba(255, 236, 200, .04) 55%, transparent 72%); pointer-events: none; }
.paper__screen { position: absolute; inset: 0; width: 100%; opacity: 0; }
.paper__screen.is-on { opacity: 1; }
.sheet {
  position: absolute; left: 50%; top: 50%;
  width: clamp(160px, 14vw, 220px);
  translate: -50% -50%;
  border-radius: 4px;
  box-shadow: 0 40px 70px rgba(0, 0, 0, .55);
  opacity: 0;
  will-change: transform, opacity;
}

/* ---------- 6 · privacy ---------- */
/* Dark eases into green at the top; green eases into white at the bottom. */
.vault {
  position: relative; isolation: isolate;
  padding: var(--section) 0 calc(var(--fade) + 20px);
  background: var(--green);
  color: #EEF4F1;
}
.vault::before, .vault::after { content: ""; position: absolute; z-index: -1; left: 0; right: 0; height: var(--fade); pointer-events: none; }
.vault::before { top: -1px; height: calc(var(--fade) * .6); background: var(--night-to-green); }
.vault::after { bottom: -1px; background: var(--green-to-day); }
.vault .lead { color: #AFC4BB; max-width: 40ch; }
.vault__lock { position: relative; width: min(64vw, 640px); margin: clamp(30px, 4vw, 60px) auto 0; }
.vault__lock img { position: relative; width: 100%; will-change: transform; }
.vault__glow { position: absolute; left: 50%; top: 55%; width: 120%; aspect-ratio: 1; translate: -50% -50%; border-radius: 50%; background: radial-gradient(closest-side, rgba(140, 255, 200, .22), transparent 70%); pointer-events: none; }

/* ---------- 7 · final ---------- */
.final { padding-top: var(--section); overflow: clip; }
.final__table { position: relative; height: clamp(560px, 56vw, 820px); max-width: 1440px; margin: clamp(30px, 4vw, 56px) auto 0; }
.final__phone { position: absolute; left: 50%; top: 4%; width: clamp(250px, 24vw, 360px); translate: -50% 0; z-index: 2; will-change: transform; }
.obj { position: absolute; will-change: transform; }
.obj--jasmine { left: 6%; top: 0; width: 10%; rotate: 24deg; }
.obj--blister { left: 15%; top: 22%; width: 17%; rotate: -18deg; }
.obj--tumbler { left: 2%; top: 44%; width: 12.5%; }
.obj--keys { left: 19%; top: 64%; width: 15%; rotate: 14deg; }
.obj--glasses { right: 12%; top: 2%; width: 19.5%; rotate: 8deg; }
.obj--bp { right: 0; top: 28%; width: 22%; rotate: -6deg; }
.obj--glucometer { right: 22%; top: 48%; width: 7.5%; rotate: 16deg; }
.obj--organizer { right: 5%; top: 78%; width: 25%; rotate: -4deg; }

/* ---------- footer ---------- */
.foot {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 28px;
  max-width: 1280px; margin: 0 auto;
  padding: 40px var(--gutter) calc(48px + env(safe-area-inset-bottom, 0px));
  color: var(--muted); font-size: 14px;
}
.foot .brand { color: var(--ink); font-size: 16px; }
.foot__links { display: flex; gap: 20px; }
.foot__links a { color: var(--muted); text-underline-offset: 3px; }

/* ---------- motion start states (html.motion is set only when motion runs) ---------- */
.motion .hero__phone, .motion [data-bubble] { opacity: 0; }
html:not(.motion) [data-bubble] { display: none; }

/* Without motion the paperwork scene is a simple, still layout. */
html:not(.motion) .paper__scene { height: auto; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); align-items: center; gap: 40px; padding: 80px var(--gutter) 120px; }
html:not(.motion) .paper__steps { position: static; width: auto; display: grid; gap: 48px; }
html:not(.motion) .step { position: static; translate: none; opacity: 1; }
html:not(.motion) .paper__device { position: relative; left: auto; top: auto; translate: none; margin-inline: auto; --dw: min(80vw, 400px); }
html:not(.motion) .sheet { display: none; }

/* ---------- small screens ---------- */
@media (max-width: 760px) {
  .nav__links { display: none; }
  .nav .brand { margin-right: 10px; }
  .hero { --pw: min(80vw, 360px); height: max(100svh, 720px); }
  .hero__copy { gap: 18px; padding-top: 116px; }
  .bubble { font-size: 14.5px; max-width: 210px; padding: 11px 14px; }
  .bubble--out { right: auto; left: 4%; top: 22px; }
  .bubble--in { left: auto; right: 4%; top: 104px; }
  .trio__stage { --cw: 58vw; height: calc(var(--cw) * 1.97); }
  .trio__phone--l { left: calc(50% - var(--cw) * .82); }
  .trio__phone--r { left: calc(50% + var(--cw) * .82); }
  .paper__steps { left: var(--gutter); right: var(--gutter); top: 15%; width: auto; text-align: center; }
  .step { justify-items: center; }
  .paper__device { left: 50%; top: 64%; --dw: min(64vw, calc((100svh - 300px) * .508)); }
  .sheet { left: 50%; top: 66%; width: 40vw; }
  html:not(.motion) .paper__scene { grid-template-columns: minmax(0, 1fr); text-align: center; }
  .vault__lock { width: 86vw; }
  .final__table { height: 540px; }
  .final__phone { width: 58vw; top: 6%; }
  .obj--jasmine, .obj--glucometer, .obj--keys { display: none; }
  .obj--blister { left: -2%; top: 16%; width: 34%; }
  .obj--tumbler { left: 0; top: 54%; width: 24%; }
  .obj--glasses { right: -2%; top: 2%; width: 36%; }
  .obj--bp { right: -6%; top: 42%; width: 38%; }
  .obj--organizer { right: 16%; top: 84%; width: 58%; }
}
