/* Doneloop website
   Layout: one column of bands; hero = text left, the live "loop" on the right (stacked on phones).
   The loop is the brand: coral = sent / on its way, green = done / back with you. */
:root {
  --bg: #FBF9F5;          /* bone, same as the app */
  --surface: #FFFFFF;
  --surface-2: #F3EFEA;
  --line: #E6E0D6;
  --ink: #1C1917;
  --ink-2: #57534E;
  --ink-3: #78716C;
  --coral: #E05A47;       /* sent */
  --coral-ink: #B83D2B;   /* coral text on light ground */
  --coral-soft: #FBE3DE;
  --done: #1E7A57;        /* done */
  --done-soft: #DCEFE6;
  --logo-loop: var(--coral);
  --logo-tick: var(--done);
  --shadow: 0 1px 2px rgba(28,25,23,.06), 0 12px 32px -12px rgba(28,25,23,.18);

  --font-display: "Outfit", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-body: "DM Sans", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace;

  --step--1: clamp(.82rem, .8rem + .1vw, .88rem);
  --step-0: clamp(1rem, .96rem + .2vw, 1.0625rem);
  --step-1: clamp(1.15rem, 1.08rem + .35vw, 1.3rem);
  --step-2: clamp(1.4rem, 1.25rem + .75vw, 1.85rem);
  --step-3: clamp(1.9rem, 1.55rem + 1.7vw, 2.9rem);
  --step-4: clamp(2.5rem, 1.9rem + 3vw, 4.4rem);
  --radius: 18px;
  --wrap: 1120px;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0F1418; --surface: #182026; --surface-2: #202B33; --line: #2C3A47;
    --ink: #F5F5F4; --ink-2: #B4AEA9; --ink-3: #8C8580;
    --coral: #FF6B57; --coral-ink: #FF8A79; --coral-soft: #3A2320;
    --done: #4CC38A; --done-soft: #17332A;
    --shadow: 0 1px 2px rgba(0,0,0,.3), 0 16px 40px -16px rgba(0,0,0,.6);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #0F1418; --surface: #182026; --surface-2: #202B33; --line: #2C3A47;
  --ink: #F5F5F4; --ink-2: #B4AEA9; --ink-3: #8C8580;
  --coral: #FF6B57; --coral-ink: #FF8A79; --coral-soft: #3A2320;
  --done: #4CC38A; --done-soft: #17332A;
  --shadow: 0 1px 2px rgba(0,0,0,.3), 0 16px 40px -16px rgba(0,0,0,.6);
  color-scheme: dark;
}
:lang(hi) {
  --font-display: "Noto Sans Devanagari", "Outfit", ui-sans-serif, system-ui, sans-serif;
  --font-body: "Noto Sans Devanagari", "DM Sans", ui-sans-serif, system-ui, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font: 400 var(--step-0)/1.6 var(--font-body);
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
}
img, svg { max-width: 100%; }
a { color: inherit; }
:focus-visible { outline: 3px solid var(--coral); outline-offset: 3px; border-radius: 6px; }
h1, h2, h3 { font-family: var(--font-display); line-height: 1.08; letter-spacing: -.02em; margin: 0; text-wrap: balance; }
:lang(hi) h1, :lang(hi) h2, :lang(hi) h3 { line-height: 1.3; letter-spacing: 0; }
p { margin: 0; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: 12px; top: -60px; background: var(--ink); color: var(--bg); padding: 10px 14px; border-radius: 10px; z-index: 20; }
.skip:focus { top: 12px; }

.wrap {
  max-width: var(--wrap); margin-inline: auto;
  padding-left: max(20px, env(safe-area-inset-left, 0px));
  padding-right: max(20px, env(safe-area-inset-right, 0px));
}
.band { padding-block: clamp(56px, 8vw, 112px); }
.band + .band { border-top: 1px solid var(--line); }
.eyebrow {
  font: 500 var(--step--1)/1.2 var(--font-mono); text-transform: uppercase; letter-spacing: .12em; color: var(--coral-ink);
}
:lang(hi) .eyebrow { font-family: var(--font-body); font-weight: 600; letter-spacing: .02em; }
.lead { color: var(--ink-2); font-size: var(--step-1); max-width: 34em; }
.section-head { display: grid; gap: 14px; margin-bottom: clamp(32px, 5vw, 56px); max-width: 40em; }
.section-head h2 { font-size: var(--step-3); font-weight: 700; }

/* ---------- header ---------- */
.site-header { padding-block: 18px; }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; }
.brand svg { width: 34px; height: 34px; flex: none; }
.brand-word { font: 800 1.45rem/1 "Outfit", ui-sans-serif, system-ui, sans-serif; letter-spacing: -.03em; }
.brand-word b { color: var(--done); font-weight: 800; }
.langs { display: flex; gap: 2px; padding: 4px; border: 1px solid var(--line); border-radius: 999px; background: var(--surface); }
.langs a {
  display: inline-grid; place-items: center; min-width: 44px; min-height: 36px; padding: 0 10px; border-radius: 999px;
  font: 500 .8rem/1 var(--font-mono); text-decoration: none; color: var(--ink-2);
}
.langs a:hover { color: var(--ink); background: var(--surface-2); }
.langs a[aria-current="true"] { background: var(--ink); color: var(--bg); }
.langs a[lang="hi"] { font-family: "Noto Sans Devanagari", var(--font-body); font-size: .85rem; }

/* ---------- hero ---------- */
.hero { padding-block: clamp(24px, 5vw, 64px) clamp(56px, 8vw, 104px); }
.hero .wrap { display: grid; gap: clamp(40px, 6vw, 72px); align-items: center; }
@media (min-width: 920px) { .hero .wrap { grid-template-columns: 1.05fr 1fr; } }
.hero-copy { display: grid; gap: 22px; min-width: 0; }
.hero h1 { font-size: var(--step-4); font-weight: 800; letter-spacing: -.035em; }
:lang(hi) .hero h1 { font-weight: 700; letter-spacing: 0; }
.hero h1 .back { color: var(--done); }
.hero h1 .out { color: var(--coral); }
.cta-row { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 22px; margin-top: 6px; }
.play { display: inline-flex; flex-direction: column; gap: 6px; text-decoration: none; }
.play img { height: 58px; width: auto; display: block; }
.play .soon {
  display: none; font: 500 .75rem/1.2 var(--font-mono); letter-spacing: .06em; text-transform: uppercase; color: var(--ink-3);
}
:lang(hi) .play .soon { font-family: var(--font-body); letter-spacing: 0; text-transform: none; }
.play-soon .play { pointer-events: none; cursor: default; }
.play-soon .play img { opacity: .72; }
.play-soon .play .soon { display: block; }
.weblink {
  display: inline-flex; align-items: center; gap: 8px; min-height: 48px; font-weight: 600; text-decoration: none;
  border-bottom: 2px solid var(--line); padding-top: 2px;
}
.weblink:hover { border-color: var(--coral); }
.hero-note { color: var(--ink-3); font-size: var(--step--1); display: flex; flex-wrap: wrap; gap: 6px 14px; }
.hero-note span { display: inline-flex; align-items: center; gap: 6px; }
.hero-note span::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--done); }

/* ---------- the loop stage ---------- */
.stage {
  position: relative; width: 100%; max-width: 520px; aspect-ratio: 1 / 1; margin-inline: auto; container-type: inline-size;
}
.stage .loop { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; }
.loop .track { fill: none; stroke: var(--line); stroke-width: 2; stroke-dasharray: 2 7; stroke-linecap: round; }
.loop .leg { fill: none; stroke-width: 4; stroke-linecap: round; stroke-dasharray: 100; stroke-dashoffset: 100; }
.loop .leg-out { stroke: var(--coral); animation: leg-out 8s linear infinite; }
.loop .leg-back { stroke: var(--done); animation: leg-back 8s linear infinite; }
.loop .dot { fill: var(--coral); animation: dot 8s linear infinite; }
.loop .dot-halo { fill: var(--coral); opacity: .18; animation: dot 8s linear infinite; }

.card {
  position: absolute; width: 57%; background: var(--surface); border: 1px solid var(--line); border-radius: 5cqw;
  box-shadow: var(--shadow); padding: 4.2cqw 4.6cqw; display: grid; gap: 2.2cqw; font-size: 3.5cqw; line-height: 1.35;
}
.card-sender { left: 0; top: 4%; }
.card-recipient { right: 0; bottom: 4%; animation: arrive 8s ease-out infinite; }
.card .who { display: flex; align-items: center; gap: 2.2cqw; color: var(--ink-3); font-size: 3cqw; }
.avatar { width: 6.6cqw; height: 6.6cqw; border-radius: 50%; display: grid; place-items: center; font-weight: 700; font-size: 3cqw; color: #fff; flex: none; }
.avatar.a { background: var(--coral); }
.avatar.b { background: var(--done); }
.card .text { font-weight: 700; font-size: 4.2cqw; color: var(--ink); }
.card .meta { color: var(--ink-3); font-size: 3cqw; font-family: var(--font-mono); }
:lang(hi) .card .meta { font-family: var(--font-body); }
.chips { position: relative; height: 6.6cqw; }
.chip {
  position: absolute; left: 0; top: 0; display: inline-flex; align-items: center; gap: 1.2cqw; height: 6.6cqw; padding: 0 2.8cqw; border-radius: 999px;
  font: 600 2.8cqw/1 var(--font-mono); letter-spacing: .04em; text-transform: uppercase; white-space: nowrap;
}
:lang(hi) .chip { font-family: var(--font-body); text-transform: none; letter-spacing: 0; font-size: 3cqw; }
.chip.sent { background: var(--coral-soft); color: var(--coral-ink); animation: chip-sent 8s linear infinite; }
.chip.done { background: var(--done-soft); color: var(--done); opacity: 0; animation: chip-done 8s linear infinite; }
.task { display: flex; align-items: center; gap: 3cqw; }
.box {
  width: 9cqw; height: 9cqw; flex: none; border-radius: 2.4cqw; border: .55cqw solid var(--ink-3); display: grid; place-items: center;
  animation: box 8s linear infinite;
}
.box svg { width: 62%; height: 62%; stroke: #fff; stroke-width: 3.4; fill: none; stroke-linecap: round; stroke-linejoin: round;
  stroke-dasharray: 30; stroke-dashoffset: 30; animation: tick 8s linear infinite; }
.task .text { transition: none; animation: strike 8s linear infinite; text-decoration-thickness: .5cqw; }
.actions { display: flex; gap: 2cqw; flex-wrap: wrap; }
.actions span { font-size: 2.7cqw; color: var(--ink-3); border: 1px solid var(--line); border-radius: 999px; padding: .8cqw 2.4cqw; }

/* timeline (8s): 0–6% sent; 6–38% travelling out; 38–50% arrives + tick; 50–85% back; 85–100% done */
@keyframes dot     { 0%, 49% { fill: var(--coral); } 50%, 100% { fill: var(--done); } }
@keyframes leg-out { 0%, 6% { stroke-dashoffset: 100; opacity: 1; } 38% { stroke-dashoffset: 0; } 96% { stroke-dashoffset: 0; opacity: 1; } 100% { stroke-dashoffset: 0; opacity: 0; } }
@keyframes leg-back{ 0%, 50% { stroke-dashoffset: 100; opacity: 1; } 85% { stroke-dashoffset: 0; } 96% { stroke-dashoffset: 0; opacity: 1; } 100% { stroke-dashoffset: 0; opacity: 0; } }
@keyframes arrive  { 0%, 36% { transform: none; } 40% { transform: translateY(-1.2cqw) scale(1.02); } 46%, 100% { transform: none; } }
@keyframes box     { 0%, 44% { background: transparent; border-color: var(--ink-3); } 46%, 97% { background: var(--done); border-color: var(--done); } 100% { background: transparent; border-color: var(--ink-3); } }
@keyframes tick    { 0%, 44% { stroke-dashoffset: 30; } 48%, 97% { stroke-dashoffset: 0; } 100% { stroke-dashoffset: 30; } }
@keyframes strike  { 0%, 46% { text-decoration: none; color: var(--ink); } 48%, 97% { text-decoration: line-through; color: var(--ink-3); } 100% { text-decoration: none; color: var(--ink); } }
@keyframes chip-sent { 0%, 84% { opacity: 1; } 86%, 97% { opacity: 0; } 100% { opacity: 1; } }
@keyframes chip-done { 0%, 84% { opacity: 0; transform: scale(.9); } 87% { opacity: 1; transform: scale(1.06); } 89%, 97% { opacity: 1; transform: none; } 100% { opacity: 0; } }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .loop .leg, .loop .dot, .loop .dot-halo, .card-recipient, .box, .box svg, .task .text, .chip { animation: none !important; }
  .loop .leg { stroke-dashoffset: 0; }
  .loop .dot, .loop .dot-halo { display: none; }
  .box { background: var(--done); border-color: var(--done); }
  .box svg { stroke-dashoffset: 0; }
  .task .text { text-decoration: line-through; color: var(--ink-3); }
  .chip.sent { opacity: 0; }
  .chip.done { opacity: 1; }
}

/* ---------- how it works ---------- */
.steps { list-style: none; margin: 0; padding: 0; display: grid; gap: 28px; counter-reset: step; }
@media (min-width: 820px) { .steps { grid-template-columns: repeat(3, 1fr); gap: 36px; } }
.steps li { display: grid; gap: 12px; align-content: start; min-width: 0; padding-top: 22px; border-top: 2px solid var(--ink); counter-increment: step; }
.steps li::before { content: counter(step, decimal-leading-zero); font: 500 var(--step--1)/1 var(--font-mono); color: var(--coral-ink); }
.steps h3 { font-size: var(--step-2); font-weight: 700; }
.steps p { color: var(--ink-2); }
.code {
  display: inline-block; font: 600 .95em/1 var(--font-mono); letter-spacing: .12em; padding: .25em .5em; border-radius: 8px;
  background: var(--surface-2); color: var(--ink); white-space: nowrap;
}

/* ---------- what people send ---------- */
.sends { display: flex; flex-wrap: wrap; gap: 12px; }
.send {
  display: inline-flex; align-items: center; gap: 12px; padding: 12px 18px 12px 12px; border-radius: 16px;
  background: var(--surface); border: 1px solid var(--line); font-weight: 600; max-width: 100%;
}
.send .mini { width: 24px; height: 24px; border-radius: 7px; border: 2px solid var(--ink-3); flex: none; display: grid; place-items: center; }
.send.is-done .mini { background: var(--done); border-color: var(--done); }
.send.is-done .mini::after { content: ""; width: 10px; height: 5px; border: solid #fff; border-width: 0 0 2.5px 2.5px; transform: translateY(-1px) rotate(-45deg); }
.send.is-done .t { color: var(--ink-3); text-decoration: line-through; }
.send .by { font: 500 .75rem/1 var(--font-mono); color: var(--ink-3); margin-left: 4px; white-space: nowrap; }
:lang(hi) .send .by { font-family: var(--font-body); }

/* ---------- features ---------- */
.features { display: grid; gap: 0 48px; }
@media (min-width: 720px) { .features { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1040px) { .features { grid-template-columns: repeat(3, 1fr); } }
.feature { display: grid; grid-template-columns: 44px 1fr; gap: 6px 16px; padding-block: 26px; border-top: 1px solid var(--line); min-width: 0; }
.feature .ic { grid-row: span 2; width: 44px; height: 44px; border-radius: 12px; background: var(--surface-2); display: grid; place-items: center; color: var(--coral-ink); }
.feature .ic svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; }
.feature h3 { font-size: var(--step-1); font-weight: 700; letter-spacing: -.01em; align-self: center; }
.feature p { color: var(--ink-2); min-width: 0; }

/* ---------- honest status ---------- */
.status-band { background: var(--surface); }
.status-grid { display: grid; gap: 36px; align-items: center; }
@media (min-width: 900px) { .status-grid { grid-template-columns: 1fr 1.1fr; } }
.flow { display: grid; gap: 14px; }
.flow-row { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.flow .arrow { color: var(--ink-3); font-family: var(--font-mono); }
.st {
  display: inline-flex; align-items: center; height: 38px; padding: 0 16px; border-radius: 999px; white-space: nowrap;
  font: 600 .8rem/1 var(--font-mono); letter-spacing: .05em; text-transform: uppercase; border: 1px solid var(--line); color: var(--ink-2); background: var(--bg);
}
:lang(hi) .st { font-family: var(--font-body); text-transform: none; letter-spacing: 0; font-size: .9rem; }
.st.sent { background: var(--coral-soft); color: var(--coral-ink); border-color: transparent; }
.st.done { background: var(--done-soft); color: var(--done); border-color: transparent; }
.st.no { text-decoration: line-through; color: var(--ink-3); background: transparent; border-style: dashed; }
.flow-note { color: var(--ink-3); font-size: var(--step--1); }

/* ---------- privacy ---------- */
.privacy-grid { display: grid; gap: 32px; }
@media (min-width: 900px) { .privacy-grid { grid-template-columns: 1fr 1.2fr; gap: 64px; } }
.checks { list-style: none; margin: 0; padding: 0; display: grid; gap: 0; }
.checks li { display: grid; grid-template-columns: 28px 1fr; gap: 14px; padding-block: 16px; border-top: 1px solid var(--line); }
.checks li:last-child { border-bottom: 1px solid var(--line); }
.checks svg { width: 24px; height: 24px; margin-top: 2px; fill: none; stroke: var(--done); stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }

/* ---------- FAQ ---------- */
.faq { display: grid; max-width: 820px; }
.faq details { border-top: 1px solid var(--line); }
.faq details:last-child { border-bottom: 1px solid var(--line); }
.faq summary {
  list-style: none; cursor: pointer; display: flex; justify-content: space-between; align-items: center; gap: 16px;
  padding-block: 20px; font: 600 var(--step-1)/1.35 var(--font-display);
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font: 400 1.6rem/1 var(--font-mono); color: var(--coral-ink); flex: none; transition: transform .2s; }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq .a { padding-bottom: 22px; color: var(--ink-2); max-width: 46em; }

/* ---------- final CTA ---------- */
.final { text-align: left; }
.final .wrap { display: grid; gap: 24px; justify-items: start; }
.final h2 { font-size: var(--step-4); font-weight: 800; letter-spacing: -.035em; max-width: 14em; }
:lang(hi) .final h2 { font-weight: 700; letter-spacing: 0; }
.final .mark-big { width: clamp(56px, 8vw, 84px); height: auto; }

/* ---------- footer ---------- */
.site-footer { border-top: 1px solid var(--line); padding-block: 40px 48px; color: var(--ink-3); font-size: var(--step--1); }
.site-footer .wrap { display: grid; gap: 22px; }
.foot-top { display: flex; flex-wrap: wrap; gap: 16px 28px; align-items: center; justify-content: space-between; }
.foot-links { display: flex; flex-wrap: wrap; gap: 4px 22px; }
.foot-links a { text-decoration: none; min-height: 40px; display: inline-flex; align-items: center; }
.foot-links a:hover { color: var(--ink); text-decoration: underline; }
.imprint { line-height: 1.7; max-width: 60em; }
.imprint strong { color: var(--ink-2); font-weight: 600; }
.foot-brand { display: inline-flex; align-items: center; gap: 8px; color: var(--ink-2); }
.foot-brand svg { width: 22px; height: 22px; }
.section-head.flush { margin-bottom: 0; }
/* 404 */
.notfound { min-height: 60vh; display: grid; align-content: center; gap: 18px; }
.notfound h1 { font-size: var(--step-4); font-weight: 800; letter-spacing: -.035em; }
