/* site.css — the tinyfiles.app landing page: black, a breathing green rim, huge type, scroll-driven scenes
   (CSS scroll timelines only, no scripts). Without scroll-timeline support, or with reduced motion, the page
   simply shows finished. */
:root {
  --bg: #000; --ink: #f5f7fa; --muted: #a1a4ab; --dim: #6e7178; --line: rgba(255, 255, 255, .09);
  --card: rgba(255, 255, 255, .035); --green: #2e8b57; --green-hi: #5cc98d; --green-txt: #7fdcaa;
  --grad: linear-gradient(100deg, #8be8b4 0%, #4cc386 50%, #2e8b57 100%);
  --ease: cubic-bezier(.22, .61, .36, 1);
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0; background: var(--bg); color: var(--ink); overflow-x: clip;
  font-family: Inter, system-ui, -apple-system, "SF Pro Display", "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
}
a { color: var(--green-txt); } a:hover { color: #a6ecc5; }
:focus-visible { outline: 2px solid var(--green-hi); outline-offset: 3px; border-radius: 6px; }
.wrap { width: 100%; max-width: 1080px; margin: 0 auto; padding: 0 22px; }
.glow {
  position: fixed; inset: 0; z-index: 0; pointer-events: none;
  background: radial-gradient(ellipse 80% 75% at 50% 50%, #000 0%, #000 50%, rgba(20, 90, 55, .30) 78%, rgba(76, 195, 134, .45) 100%);
  animation: breathe 8s ease-in-out infinite;
}
@keyframes breathe { 50% { opacity: .7; } }
main, header, footer { position: relative; z-index: 1; }
.grad { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; padding: 0 .04em .16em; margin: 0 -.04em -.16em; }
.kicker { margin: 0; font-size: 13px; font-weight: 600; letter-spacing: .16em; text-transform: uppercase; color: var(--green-txt); }
.kicker .nc { text-transform: none; letter-spacing: .04em; }
h2 { margin: 12px 0 0; font-size: clamp(34px, 5.6vw, 64px); font-weight: 800; line-height: 1.04; letter-spacing: -.035em; }
h2 .dim { color: var(--dim); }
svg { fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

/* ---------- header ---------- */
.top { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; padding-top: 22px; }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: var(--ink); font-size: 19px; font-weight: 700; letter-spacing: -.01em; }
.brand b, .brand-txt b { color: var(--green-hi); font-weight: 700; }
.brand img { border-radius: 8px; }
.top nav { display: flex; align-items: center; gap: 22px; flex-wrap: wrap; font-size: 15px; }
.top nav a:not(.pill-ghost) { color: #b7bac1; text-decoration: none; }
.top nav a:not(.pill-ghost):hover { color: var(--ink); }
.pill-ghost { display: inline-flex; align-items: center; min-height: 40px; padding: 0 16px; border-radius: 999px; border: 1px solid rgba(255, 255, 255, .16); background: transparent; color: var(--ink); text-decoration: none; font: 600 15px inherit; font-family: inherit; cursor: pointer; }
.pill-ghost:hover { color: var(--ink); border-color: rgba(255, 255, 255, .3); }
.pill-ghost.big { min-height: 52px; padding: 0 24px; font-size: 16px; }

/* ---------- hero ---------- */
.hero { padding-top: 120px; padding-bottom: 110px; text-align: center; }
.hero-out { display: flex; flex-direction: column; align-items: center; }
.badge { display: inline-flex; align-items: center; gap: 8px; padding: 7px 14px; border-radius: 999px; border: 1px solid rgba(76, 195, 134, .45); background: rgba(76, 195, 134, .10); font-size: 13px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--green-txt); animation: rise 1.1s .05s var(--ease) both; }
.badge svg { width: 14px; height: 14px; stroke-width: 2.2; }
.hero h1 { margin: 22px 0 0; font-size: clamp(44px, 7.6vw, 96px); font-weight: 800; line-height: 1.02; letter-spacing: -.035em; animation: rise 1.1s .2s var(--ease) both; }
.hero h1 span { display: block; }
.lede { margin: 26px 0 0; max-width: 620px; font-size: clamp(17px, 2vw, 21px); line-height: 1.5; color: var(--muted); animation: rise 1.1s .32s var(--ease) both; }
.ctas { margin-top: 36px; display: flex; gap: 14px; flex-wrap: wrap; justify-content: center; animation: rise 1.1s .45s var(--ease) both; }
.cta { display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 52px; padding: 0 26px; border: 0; border-radius: 999px; background: var(--green); color: #fff; text-decoration: none; font: 600 16px inherit; font-family: inherit; cursor: pointer; box-shadow: 0 10px 34px rgba(76, 195, 134, .35); transition: transform .3s var(--ease), box-shadow .3s var(--ease), background .3s; }
.cta:hover { color: #fff; transform: translateY(-2px); background: #339b61; box-shadow: 0 14px 40px rgba(76, 195, 134, .5); }
.cta svg { width: 18px; height: 18px; }
.cta.block { width: 100%; }
.cta[disabled] { opacity: .6; cursor: default; transform: none; }
.chips { margin-top: 34px; display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; max-width: 680px; animation: rise 1.1s .55s var(--ease) both; }
.chips span { padding: 7px 13px; border-radius: 999px; background: var(--card); border: 1px solid var(--line); font-size: 14px; font-weight: 600; }
.chips .hl { background: rgba(76, 195, 134, .10); border-color: rgba(76, 195, 134, .45); }
@keyframes rise { from { opacity: 0; transform: translateY(24px); } to { opacity: 1; transform: none; } }

/* ---------- the pinned "how it flows" scene ---------- */
.flow { position: relative; height: 280vh; height: 280svh; }
.stage { position: sticky; top: 0; height: 100vh; height: 100svh; display: flex; align-items: center; overflow: clip; }
.flow-head { text-align: center; }
.rail { position: relative; margin-top: 56px; height: 46px; }
.rail-line, .rail-fill { position: absolute; left: 0; right: 0; top: 22px; height: 2px; border-radius: 2px; background: var(--line); }
.rail-fill { background: linear-gradient(90deg, #8be8b4, #2e8b57); box-shadow: 0 0 18px rgba(76, 195, 134, .8); transform-origin: left center; }
.rail-chip { position: absolute; top: 0; left: calc(100% - 250px); width: 250px; height: 46px; display: flex; align-items: center; gap: 10px; padding: 0 16px; border-radius: 999px; background: #0d0f0e; border: 1px solid rgba(76, 195, 134, .55); box-shadow: 0 8px 30px rgba(76, 195, 134, .3); font-size: 14px; font-weight: 600; white-space: nowrap; }
.chip-size { margin-left: auto; padding: 2px 8px; border-radius: 999px; background: rgba(76, 195, 134, .16); color: var(--green-txt); font-size: 12px; }
.rail-chip svg { width: 18px; height: 18px; color: var(--green-hi); }
.steps { margin-top: 40px; display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr)); gap: 16px; }
.step { padding: 24px; border-radius: 24px; background: var(--card); border: 1px solid var(--line); }
.step.hl { background: rgba(76, 195, 134, .08); border-color: rgba(76, 195, 134, .4); }
.step .n { margin: 0; font-size: 13px; font-weight: 700; color: var(--green-txt); }
.step h3 { margin: 8px 0 0; font-size: 22px; font-weight: 700; letter-spacing: -.01em; }
.step p:last-child { margin: 6px 0 0; font-size: 15px; line-height: 1.5; color: var(--muted); }
@media (max-width: 700px) {
  .flow { height: 340vh; height: 340svh; }
  .steps { margin-top: 24px; gap: 10px; }
  .step { padding: 16px 18px; }
  .rail { margin-top: 32px; }
}

/* ---------- moving words ---------- */
.marquee { padding: 30px 0 70px; overflow: clip; }
.marquee div { white-space: nowrap; font-size: clamp(54px, 9vw, 120px); font-weight: 800; letter-spacing: -.04em; line-height: 1.05; }
.m1 { color: #1d2120; }
.m2 { color: transparent; -webkit-text-stroke: 1.5px rgba(76, 195, 134, .55); transform: translateX(-30%); }

/* ---------- blocks ---------- */
.block { padding-top: 60px; padding-bottom: 90px; }
.cards { margin-top: 44px; display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr)); gap: 16px; }
.card { padding: 26px; border-radius: 24px; background: var(--card); border: 1px solid var(--line); transition: border-color .3s, background .3s; }
.card:hover { border-color: rgba(76, 195, 134, .45); background: rgba(76, 195, 134, .06); }
.card svg { width: 28px; height: 28px; color: var(--green-hi); }
.card h3 { margin: 16px 0 0; font-size: 21px; font-weight: 700; letter-spacing: -.01em; }
.card p { margin: 8px 0 0; font-size: 15px; line-height: 1.55; color: var(--muted); }
.split { display: flex; flex-wrap: wrap; gap: 48px; align-items: center; }
.split.top { align-items: flex-start; }
.split > * { flex: 1 1 380px; min-width: 0; }
.body { margin: 20px 0 0; font-size: 18px; line-height: 1.55; color: var(--muted); }
.body .tm { color: var(--ink); font-weight: 700; }
.body.small { margin-top: 14px; font-size: 15px; color: var(--dim); }
.fill { background-image: linear-gradient(90deg, var(--ink) 50%, #34373d 50%); background-size: 200% 100%; background-position: 0 0; -webkit-background-clip: text; background-clip: text; color: transparent; }
.tiles { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.tile { padding: 22px; border-radius: 22px; background: var(--card); border: 1px solid var(--line); display: grid; gap: 6px; }
.tile.hl { background: rgba(76, 195, 134, .10); border-color: rgba(76, 195, 134, .45); }
.tile b { font-size: 18px; }
.tile span { font-size: 14px; color: var(--muted); }

/* ---------- closing ---------- */
.closing { text-align: center; display: flex; flex-direction: column; align-items: center; padding-bottom: 120px; }
.closing .body { max-width: 560px; }
.closing .ctas { animation: none; }

footer { border-top: 1px solid var(--line); }
.foot { padding-top: 28px; padding-bottom: 40px; display: flex; flex-wrap: wrap; gap: 16px; align-items: center; justify-content: space-between; font-size: 14px; color: var(--dim); }
.brand-txt { color: var(--ink); }
.foot .links { display: flex; gap: 20px; flex-wrap: wrap; }
.foot .links a { color: #8a8d94; text-decoration: none; }

/* ---------- Crumbs: a live-looking crumb map (pure CSS) ---------- */
.cmap { padding: 22px; border-radius: 28px; background: #0b0d0c; border: 1px solid rgba(76, 195, 134, .3); box-shadow: 0 30px 80px rgba(46, 139, 87, .18); display: grid; gap: 16px; }
.cmap-head { display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; }
.cmap-head b { font-size: 40px; font-weight: 800; letter-spacing: -.03em; color: var(--green-txt); }
.cmap-head span { color: var(--muted); font-size: 14px; }
.cmap-sky { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 12px; padding: 14px; border-radius: 18px; background: rgba(255, 255, 255, .04); }
.cmap-sky > span { font-size: 11px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--dim); writing-mode: vertical-rl; transform: rotate(180deg); }
.cmap-lanes { display: grid; gap: 9px; }
.cmap-lanes i { position: relative; height: 22px; font-style: normal; background: repeating-linear-gradient(90deg, rgba(255, 255, 255, .14) 0 6px, transparent 6px 12px) center / 100% 2px no-repeat; color: transparent; }
.cmap-lanes i::after { content: ''; position: absolute; top: 0; left: 0; width: 34px; height: 22px; border-radius: 8px 10px 7px 11px; background: linear-gradient(90deg, #4cc386, #2e8b57); box-shadow: 0 4px 14px rgba(76, 195, 134, .45); animation: fly 2.8s var(--d, 0s) linear infinite; }
@keyframes fly { 0% { left: 0; opacity: .5; } 10% { opacity: 1; } 88% { left: calc(100% - 34px); opacity: 1; } 100% { left: calc(100% - 34px); opacity: 0; } }
.cmap-grid { position: relative; }
.cg { display: grid; grid-template-columns: repeat(11, 1fr); gap: 7px; }
.cg i { display: block; aspect-ratio: 1; border-radius: 5px 7px 4px 8px; background: rgba(255, 255, 255, .1); transform: rotate(calc(var(--r, 0) * 4deg - 12deg)) scale(.86); }
.cg-on { position: absolute; inset: 0; clip-path: inset(0 0 38% 0); }
.cg-on i { background: var(--green); transform: rotate(calc(var(--r, 0) * 4deg - 12deg)); box-shadow: 0 0 10px rgba(76, 195, 134, .25); }
.cmap-seal { margin: 0; padding: 10px 14px; border-radius: 14px; background: rgba(76, 195, 134, .12); color: var(--green-txt); font-size: 13px; font-family: ui-monospace, SFMono-Regular, Menlo, monospace; overflow-wrap: anywhere; }
.cmap-seal b { font-family: inherit; }

/* ---------- scroll-driven motion ---------- */
@supports (animation-timeline: view()) {
  @media (prefers-reduced-motion: no-preference) {
    .hero-out { animation: hero-out linear both; animation-timeline: view(); animation-range: exit 0% exit 85%; }
    @keyframes hero-out { to { opacity: 0; transform: scale(.86) translateY(-80px); filter: blur(8px); } }
    .reveal { animation: up linear both; animation-timeline: view(); animation-range: entry 0% entry 75%; }
    @keyframes up { from { opacity: 0; transform: translateY(70px) scale(.95); } }
    .pop { animation: pop linear both; animation-timeline: view(); animation-range: entry 10% cover 35%; }
    @keyframes pop { from { opacity: 0; transform: translateY(40px) rotate(-3deg) scale(.9); } }
    .zoom { animation: zoom linear both; animation-timeline: view(); animation-range: entry 0% cover 45%; }
    @keyframes zoom { from { opacity: 0; transform: scale(.85); } }

    .flow { view-timeline-name: --flow; }
    .s1, .s2, .s3 { animation: light linear both; animation-timeline: --flow; }
    .s1 { animation-range: contain 0% contain 22%; }
    .s2 { animation-range: contain 30% contain 55%; }
    .s3 { animation-range: contain 63% contain 88%; }
    @keyframes light { from { opacity: .18; transform: translateY(26px) scale(.94); filter: saturate(0); } to { opacity: 1; transform: none; filter: none; } }
    .rail-fill { animation: bar linear both; animation-timeline: --flow; animation-range: contain 0% contain 90%; }
    @keyframes bar { from { transform: scaleX(0); } }
    .rail-chip { animation: chip linear both; animation-timeline: --flow; animation-range: contain 0% contain 90%; }
    @keyframes chip { from { left: 0; } to { left: calc(100% - 250px); } }
    .flow-head { animation: head-out linear both; animation-timeline: --flow; animation-range: contain 88% contain 100%; }
    @keyframes head-out { to { opacity: 0; transform: translateY(-40px); } }

    /* the crumb map fills as it scrolls through the screen, then seals */
    .cg-on { animation: crumbs-in linear both; animation-timeline: view(); animation-range: entry 40% cover 60%; }
    @keyframes crumbs-in { from { clip-path: inset(0 0 100% 0); } to { clip-path: inset(0 0 0 0); } }
    .cmap-seal { animation: seal linear both; animation-timeline: view(); animation-range: entry 60% cover 55%; }
    @keyframes seal { 0%, 85% { opacity: 0; transform: translateY(10px); } 100% { opacity: 1; transform: none; } }
    .m1 { animation: m1 linear both; animation-timeline: view(); animation-range: cover 0% cover 100%; }
    .m2 { animation: m2 linear both; animation-timeline: view(); animation-range: cover 0% cover 100%; }
    @keyframes m1 { from { transform: translateX(8%); } to { transform: translateX(-38%); } }
    @keyframes m2 { from { transform: translateX(-38%); } to { transform: translateX(8%); } }
    .fill { background-position: 100% 0; animation: fill linear both; animation-timeline: view(); animation-range: cover 15% cover 50%; }
    @keyframes fill { to { background-position: 0 0; } }
  }
}
@media (prefers-reduced-motion: reduce) {
  .glow, .badge, .hero h1, .lede, .ctas, .chips, .cmap-lanes i::after { animation: none; }
  .cmap-lanes i::after { left: 50%; }
  html { scroll-behavior: auto; }
}
