:root {
  --paper: #f3eee3;
  --paper-2: #ebe4d5;
  --ink: #17150f;
  --ink-2: #4a463d;
  --muted: #7a7466;
  --rule: #d6cdb9;
  --accent: #e5482a;
  --signal: #e5482a;
  --card: #fbf8f1;
  --shadow: 0 1px 0 rgba(23, 21, 15, .06), 0 24px 48px -24px rgba(23, 21, 15, .35);

  --serif: "Fraunces", Georgia, serif;
  --sans: "Instrument Sans", system-ui, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, monospace;

  --gutter: clamp(16px, 4vw, 48px);
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root {
    --paper: #13120f;
    --paper-2: #1b1a16;
    --ink: #efe9dc;
    --ink-2: #c4bdac;
    --muted: #8d8676;
    --rule: #2e2b25;
    --signal: #ff6a45;
    --card: #1b1a16;
    --shadow: 0 1px 0 rgba(0, 0, 0, .3), 0 24px 48px -24px rgba(0, 0, 0, .8);
    color-scheme: dark;
  }
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 80px; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
/* paper grain */
body::before {
  content: "";
  position: fixed; inset: 0;
  pointer-events: none; z-index: 100;
  opacity: .35;
  mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 .09 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}
@media (prefers-color-scheme: dark) { body::before { mix-blend-mode: screen; opacity: .25; } }

img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
em { font-style: italic; }

.wrap { width: 100%; max-width: 1200px; margin: 0 auto; padding: 0 var(--gutter); }

.eyebrow {
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--muted);
  margin: 0 0 18px;
}

h1, h2, h3 {
  font-family: var(--serif);
  font-weight: 400;
  font-variation-settings: "opsz" 144, "SOFT" 50, "WONK" 0;
  letter-spacing: -.02em;
  line-height: 1;
  margin: 0;
}
h1 em, h2 em {
  font-variation-settings: "opsz" 144, "SOFT" 100, "WONK" 1;
  color: var(--signal);
}

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 14px 22px;
  border-radius: 999px;
  font-weight: 600; font-size: 15px;
  text-decoration: none;
  transition: transform .2s ease, background .2s ease, color .2s ease, box-shadow .2s ease;
}
.btn:hover { transform: translateY(-2px); }
.btn-ink { background: var(--ink); color: var(--paper); }
.btn-ink:hover { background: var(--signal); color: #fff; }
.btn-line { border: 1.5px solid var(--ink); }
.btn-line:hover { background: var(--ink); color: var(--paper); }

/* ---------- header ---------- */
.top {
  position: sticky; top: 0; z-index: 50;
  background: color-mix(in srgb, var(--paper) 82%, transparent);
  backdrop-filter: blur(12px) saturate(1.4);
  -webkit-backdrop-filter: blur(12px) saturate(1.4);
  border-bottom: 1px solid transparent;
  transition: border-color .3s;
}
.top-inner { display: flex; align-items: center; justify-content: space-between; height: 68px; }
.mark { text-decoration: none; display: flex; align-items: baseline; font-family: var(--serif); font-size: 24px; letter-spacing: -.02em; }
.mark-c {
  display: inline-grid; place-items: center;
  width: 34px; height: 34px; margin-right: 2px;
  background: var(--signal); color: #fff;
  border-radius: 9px;
  font-variation-settings: "opsz" 144, "SOFT" 100, "WONK" 1;
  font-weight: 600; font-style: italic;
  transform: rotate(-6deg) translateY(4px);
}
.mark-apps {
  margin-left: 7px;
  font-family: var(--mono); font-size: 12px;
  letter-spacing: .14em; text-transform: uppercase;
  color: var(--muted);
}
nav { display: flex; gap: 28px; align-items: center; }
nav a { text-decoration: none; font-size: 15px; font-weight: 500; color: var(--ink-2); }
nav a:hover { color: var(--ink); }
.nav-cta { background: var(--ink); color: var(--paper) !important; padding: 8px 16px; border-radius: 999px; }

/* ---------- hero ---------- */
.hero { padding: clamp(48px, 9vw, 120px) 0 clamp(56px, 8vw, 100px); }
.hero-grid { display: grid; grid-template-columns: 1.25fr 1fr; gap: 40px; align-items: center; }
.hero h1 {
  font-size: clamp(56px, 9.5vw, 132px);
  font-weight: 350;
  line-height: .92;
  margin-bottom: 28px;
}
.lede { font-size: clamp(18px, 1.8vw, 21px); color: var(--ink-2); max-width: 30ch; margin: 0 0 28px; }

.refusals {
  list-style: none; padding: 0; margin: 0 0 36px;
  display: flex; flex-wrap: wrap; gap: 8px;
}
.refusals li {
  font-family: var(--mono); font-size: 13px;
  padding: 6px 12px;
  border: 1px dashed var(--rule);
  border-radius: 6px;
  color: var(--muted);
  text-decoration: line-through;
  text-decoration-color: var(--signal);
  text-decoration-thickness: 2px;
}
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; }

.hero-icons { position: relative; aspect-ratio: 1; max-width: 480px; justify-self: end; width: 100%; }
.hi {
  position: absolute; width: 44%;
  border-radius: 22.5%;
  box-shadow: var(--shadow);
  opacity: 0;
  animation: drop .9s cubic-bezier(.2, .9, .25, 1.15) forwards, bob 7s ease-in-out infinite;
  transition: transform .4s ease;
}
.hi-1 { left: 4%;  top: 6%;  --r: -9deg; animation-delay: .35s, 1.3s; }
.hi-2 { right: 2%; top: 0;   --r: 7deg;  animation-delay: .5s, 2.1s; }
.hi-3 { left: 14%; bottom: 2%; --r: 5deg; animation-delay: .65s, 1.7s; }
.hi-4 { right: 6%; bottom: 10%; --r: -4deg; animation-delay: .8s, 2.6s; }
@keyframes drop {
  from { opacity: 0; transform: translateY(-40px) rotate(calc(var(--r) * 3)) scale(.9); }
  to   { opacity: 1; transform: translateY(0) rotate(var(--r)) scale(1); }
}
@keyframes bob {
  0%, 100% { translate: 0 0; }
  50% { translate: 0 -8px; }
}
.stamp {
  position: absolute; left: 50%; top: 50%;
  width: 128px; height: 128px;
  display: grid; place-items: center; text-align: center;
  border: 2px solid var(--signal); border-radius: 50%;
  color: var(--signal);
  font-family: var(--serif); font-style: italic; font-size: 19px; line-height: 1;
  font-variation-settings: "opsz" 144, "SOFT" 100, "WONK" 1;
  background: var(--paper);
  opacity: 0;
  animation: stamp .5s cubic-bezier(.3, 1.6, .5, 1) 1.15s forwards;
  z-index: 2;
}
.stamp small { font-family: var(--mono); font-style: normal; font-size: 9px; letter-spacing: .15em; text-transform: uppercase; }
@keyframes stamp {
  from { opacity: 0; transform: translate(-50%, -50%) rotate(-30deg) scale(2.2); }
  to   { opacity: 1; transform: translate(-50%, -50%) rotate(-12deg) scale(1); }
}

/* staggered load */
.load { opacity: 0; transform: translateY(18px); animation: rise .8s cubic-bezier(.2, .8, .2, 1) forwards; animation-delay: calc(var(--d) * 110ms + 80ms); }
@keyframes rise { to { opacity: 1; transform: none; } }

/* ---------- ticker ---------- */
.ticker {
  border-block: 1px solid var(--ink);
  background: var(--ink); color: var(--paper);
  overflow: hidden; white-space: nowrap;
  padding: 14px 0;
}
.ticker-track { display: inline-flex; gap: 28px; animation: tick 38s linear infinite; font-family: var(--serif); font-size: 26px; font-style: italic; font-variation-settings: "opsz" 144, "SOFT" 100, "WONK" 1; }
.ticker i { font-style: normal; color: var(--signal); }
@keyframes tick { to { transform: translateX(-50%); } }

/* ---------- section heads ---------- */
.section-head { margin-bottom: clamp(40px, 6vw, 72px); }
.section-head h2 { font-size: clamp(40px, 6vw, 76px); }

/* ---------- apps ---------- */
.apps { padding: clamp(72px, 10vw, 140px) 0 40px; }
.app {
  display: grid; grid-template-columns: 1.1fr 1fr;
  gap: clamp(32px, 6vw, 88px);
  align-items: center;
  padding: clamp(40px, 6vw, 72px) 0;
  border-top: 1px solid var(--rule);
}
.app-flip .app-copy { order: 2; }
.app-index { font-family: var(--mono); font-size: 12px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); margin: 0 0 22px; display: flex; align-items: center; gap: 12px; }
.app-index span { color: var(--accent); font-weight: 500; font-size: 13px; }
.pill { background: var(--accent); color: #fff; font-weight: 500; padding: 2px 8px; border-radius: 999px; font-size: 10px; }
.app-title { display: flex; gap: 20px; align-items: center; margin-bottom: 22px; }
.app-icon { width: 72px; height: 72px; border-radius: 22.5%; box-shadow: var(--shadow); flex: none; }
.app h3 { font-size: clamp(34px, 4vw, 52px); }
.tagline { font-family: var(--serif); font-style: italic; font-size: 19px; color: var(--ink-2); margin: 6px 0 0; line-height: 1.3; font-variation-settings: "opsz" 24, "SOFT" 100; }
.app-desc { color: var(--ink-2); max-width: 52ch; margin: 0 0 22px; }

.features {
  list-style: none; padding: 0; margin: 0 0 30px;
  display: grid; grid-template-columns: 1fr 1fr; gap: 8px 24px;
  font-size: 15px;
}
.features li { position: relative; padding-left: 20px; line-height: 1.45; }
.features li::before { content: "→"; position: absolute; left: 0; color: var(--accent); font-family: var(--mono); font-size: 13px; top: 1px; }

.app-foot { display: flex; align-items: center; justify-content: space-between; gap: 20px; flex-wrap: wrap; padding-top: 22px; border-top: 1px dashed var(--rule); }
.price { display: flex; flex-direction: column; line-height: 1.15; }
.price strong { font-family: var(--serif); font-weight: 500; font-size: 30px; }
.price span { font-family: var(--mono); font-size: 12px; color: var(--muted); }
.btn-store { background: var(--ink); color: var(--paper); }
.btn-store svg { width: 18px; height: 18px; fill: currentColor; margin-top: -2px; }
.btn-store:hover { background: var(--accent); color: #fff; box-shadow: 0 10px 30px -10px var(--accent); }

.app-shots { position: relative; display: flex; justify-content: center; min-height: 520px; }
.app-shots::before {
  content: ""; position: absolute; inset: 8% 6%;
  background: radial-gradient(closest-side, color-mix(in srgb, var(--accent) 28%, transparent), transparent);
  filter: blur(20px);
}
.shot {
  position: relative;
  width: min(250px, 44%);
  border-radius: 22px;
  box-shadow: var(--shadow);
  transition: transform .6s cubic-bezier(.2, .8, .2, 1);
}
.shot-a { transform: rotate(-4deg) translateX(14%); z-index: 2; }
.shot-b { transform: rotate(5deg) translate(-14%, 36px); }
.app:hover .shot-a { transform: rotate(-6deg) translateX(6%) translateY(-6px); }
.app:hover .shot-b { transform: rotate(7deg) translate(-6%, 30px); }

/* S.P.E.E.D gets a dark slab */
.app-dark .app-shots-single { align-items: center; flex-direction: column; gap: 0; }
.app-dark .app-shots-single .shot { width: min(240px, 60%); transform: rotate(3deg); border: 1px solid #2a2a2a; }
.app-dark:hover .app-shots-single .shot { transform: rotate(0); }

/* ---------- about ---------- */
.about { padding: clamp(72px, 10vw, 140px) 0; }
.about-grid { display: grid; grid-template-columns: 1.3fr 1fr; gap: clamp(40px, 6vw, 96px); align-items: end; }
.about h2 { font-size: clamp(36px, 5vw, 64px); margin-bottom: 28px; }
.about-copy p:not(.eyebrow) { color: var(--ink-2); font-size: 18px; max-width: 56ch; }
.stats { margin: 0; display: grid; grid-template-columns: 1fr 1fr; border-top: 1px solid var(--ink); }
.stats div { padding: 22px 0; border-bottom: 1px solid var(--rule); }
.stats div:nth-child(odd) { padding-right: 16px; border-right: 1px solid var(--rule); }
.stats div:nth-child(even) { padding-left: 20px; }
.stats dt { font-family: var(--mono); font-size: 11px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.stats dd { margin: 6px 0 0; font-family: var(--serif); font-size: clamp(44px, 5vw, 64px); line-height: 1; font-variation-settings: "opsz" 144, "SOFT" 50; }
.stats div:last-child dd { color: var(--signal); }

/* ---------- contact ---------- */
.contact { background: var(--signal); color: #fff; padding: clamp(72px, 10vw, 130px) 0; position: relative; overflow: hidden; }
.contact .eyebrow { color: rgba(255, 255, 255, .75); }
.contact h2 { font-size: clamp(40px, 6.5vw, 88px); margin-bottom: 40px; }
.contact h2 em { color: inherit; opacity: .85; }
.mail {
  display: inline-flex; gap: 12px; align-items: center;
  font-family: var(--mono); font-size: clamp(15px, 2vw, 22px);
  text-decoration: none; color: #fff;
  padding: 16px 26px; border: 2px solid #fff; border-radius: 999px;
  transition: background .2s, color .2s;
  overflow-wrap: anywhere;
}
.mail:hover { background: #fff; color: var(--signal); }

/* ---------- footer ---------- */
.foot { padding: 32px 0; font-size: 14px; color: var(--muted); }
.foot-inner { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 16px; }
.foot p { margin: 0; }
.foot ul { list-style: none; display: flex; gap: 24px; flex-wrap: wrap; margin: 0; padding: 0; }
.foot a { text-decoration: none; }
.foot a:hover { color: var(--ink); }

/* ---------- reveal ---------- */
.reveal { opacity: 0; transform: translateY(32px); transition: opacity .9s ease, transform .9s cubic-bezier(.2, .8, .2, 1); }
.reveal.in { opacity: 1; transform: none; }

/* ---------- responsive ---------- */
@media (max-width: 900px) {
  .hero-grid, .about-grid { grid-template-columns: 1fr; }
  .hero-icons { max-width: 340px; justify-self: center; }
  .app { grid-template-columns: 1fr; }
  .app-flip .app-copy { order: 0; }
  .app-shots { min-height: 0; padding-bottom: 40px; }
}
@media (max-width: 640px) {
  nav a:not(.nav-cta) { display: none; }
  .features { grid-template-columns: 1fr; }
  .shot { width: 46%; }
  .stats dd { font-size: 40px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-delay: 0s !important; animation-iteration-count: 1 !important; transition: none !important; }
  .reveal, .load { opacity: 1; transform: none; }
  html { scroll-behavior: auto; }
}
