/* ==========================================================================
   EasyPaste — landing page. "Forest" identity: deep green on cream.
   Tokens live on :root (light) with dark overrides; every text pairing passes WCAG AA
   (table in brand/README.md). Inter 800 headings at about -0.032em, accent words in
   brand green, cream nav bar, surface cards with a hairline border, brass as decoration only.
   ========================================================================== */

:root {
  /* Forest identity. Light tokens; dark overrides follow. Contrast table: brand/README.md. */
  --ep-brand: #1E5E3F;        /* brand + action: buttons, links, accent text (6.8:1 on cream) */
  --ep-action: #1E5E3F;
  --ep-action-hover: #174C33;
  --ep-on-action: #FFFFFF;    /* 7.7:1 on brand */
  --ep-select: #DCEBDD;
  --ep-card: #ECE6D8;
  --ep-bg: #F4F1E8;
  --ep-line: #D9D1BF;
  --ep-muted: #5A6158;
  --ep-ink: #14241B;
  --ep-brass: #B08A4A;        /* decorative only — rules, small details. Never text. */
  --ep-win: #FBF9F3;
  --ep-win-dark: #18231C;
  --ep-brand-deep: #14402B;
  --ep-raised: #FBF9F3;       /* cards that sit above the page: pricing, keycaps, dialog */
  --ep-brand-soft: #9DB39A;

  --ep-max: 1120px;
  --ep-radius: 30px;

  --ep-sans: "Inter", "Inter Fallback", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
    "Helvetica Neue", Arial, sans-serif;
  color-scheme: light dark;
}

@media (prefers-color-scheme: dark) {
  :root {
    --ep-brand: #6FCF97;
    --ep-action: #6FCF97;
    --ep-action-hover: #8ADBAB;
    --ep-on-action: #0E2418;   /* never white on mint (1.9:1) */
    --ep-select: #1E3B2B;
    --ep-card: #18231C;
    --ep-bg: #101813;
    --ep-line: #2A3A30;
    --ep-muted: #9DB0A3;
    --ep-ink: #E8F0EA;
    --ep-raised: #1C2921;
  }
}

/* Fonts are self-hosted (Latin subset, from Google Fonts' own files): no third-party request on
   page load, and nothing on this page tells another company who's visiting. Paths are relative to
   this stylesheet, so they work from the blog's nested pages too. */
@font-face {
  font-family: "Inter";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url("assets/fonts/inter-var-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* A local font resized to Inter's metrics, so text laid out before Inter arrives takes the same
   space and nothing shifts when it swaps in. */
@font-face {
  font-family: "Inter Fallback";
  src: local("Arial");
  size-adjust: 107.12%;
  ascent-override: 90.44%;
  descent-override: 22.52%;
  line-gap-override: 0%;
}

/* Arabic (the /ar/ page and anywhere Arabic renders): IBM Plex Sans Arabic, self-hosted, Arabic
   subset only, so Latin text keeps Inter and the English page never downloads it. Plex has no
   800, so Arabic headings use its 700. */
@font-face {
  font-family: "IBM Plex Sans Arabic";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("assets/fonts/ibm-plex-sans-arabic-400.woff2") format("woff2");
  unicode-range: U+0600-06FF, U+0750-077F, U+0870-088E, U+0890-0891, U+0897-08E1, U+08E3-08FF, U+200C-200E, U+2010-2011, U+204F, U+2E41, U+FB50-FDFF, U+FE70-FE74, U+FE76-FEFC;
}

@font-face {
  font-family: "IBM Plex Sans Arabic";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("assets/fonts/ibm-plex-sans-arabic-500.woff2") format("woff2");
  unicode-range: U+0600-06FF, U+0750-077F, U+0870-088E, U+0890-0891, U+0897-08E1, U+08E3-08FF, U+200C-200E, U+2010-2011, U+204F, U+2E41, U+FB50-FDFF, U+FE70-FE74, U+FE76-FEFC;
}

@font-face {
  font-family: "IBM Plex Sans Arabic";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("assets/fonts/ibm-plex-sans-arabic-600.woff2") format("woff2");
  unicode-range: U+0600-06FF, U+0750-077F, U+0870-088E, U+0890-0891, U+0897-08E1, U+08E3-08FF, U+200C-200E, U+2010-2011, U+204F, U+2E41, U+FB50-FDFF, U+FE70-FE74, U+FE76-FEFC;
}

@font-face {
  font-family: "IBM Plex Sans Arabic";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("assets/fonts/ibm-plex-sans-arabic-700.woff2") format("woff2");
  unicode-range: U+0600-06FF, U+0750-077F, U+0870-088E, U+0890-0891, U+0897-08E1, U+08E3-08FF, U+200C-200E, U+2010-2011, U+204F, U+2E41, U+FB50-FDFF, U+FE70-FE74, U+FE76-FEFC;
}

/* Local Arabic fallback resized to Plex's metrics (size-adjust from the average advance of the
   Arabic letters; ascent/descent from Plex's hhea), so text laid out before Plex arrives takes the
   same space and nothing shifts when it swaps in. Arial carries Arabic on macOS and Windows. */
@font-face {
  font-family: "Plex Arabic Fallback";
  src: local("Arial");
  size-adjust: 117.52%;
  ascent-override: 92.32%;
  descent-override: 35.31%;
  line-gap-override: 0%;
  unicode-range: U+0600-06FF, U+0750-077F, U+0870-088E, U+0890-0891, U+0897-08E1, U+08E3-08FF, U+FB50-FDFF, U+FE70-FE74, U+FE76-FEFC;
}

:root:lang(ar) {
  --ep-sans: "Inter", "IBM Plex Sans Arabic", "Plex Arabic Fallback", "Inter Fallback", -apple-system, BlinkMacSystemFont, "Segoe UI", Tahoma, sans-serif;
}

/* Negative tracking pulls joined Arabic letters apart, and the Latin line-height clips its
   ascenders and dots. */
:lang(ar) h1, :lang(ar) h2, :lang(ar) h3, :lang(ar) h4, :lang(ar) .h-hero, :lang(ar) .h-2, :lang(ar) .h-3,
:lang(ar) .h-4, :lang(ar) .eyebrow, :lang(ar) .price, :lang(ar) .nav-brand { letter-spacing: 0; }
:lang(ar) h1, :lang(ar) h2, :lang(ar) h3, :lang(ar) h4 { line-height: 1.3; }
:lang(ar) .lede, :lang(ar) .faq p, :lang(ar) .audience p { line-height: 1.8; }

/* The app mockups picture the app's light appearance, so they keep the light tokens even when
   the page itself is dark — otherwise dark-mode ink would land on the light mock windows. */
.mk {
  --ep-brand: #1E5E3F; --ep-action: #1E5E3F; --ep-on-action: #FFFFFF; --ep-select: #DCEBDD;
  --ep-card: #ECE6D8; --ep-bg: #F4F1E8; --ep-line: #D9D1BF; --ep-muted: #5A6158; --ep-ink: #14241B;
  color-scheme: light;
}

/* The app mockups keep their macOS window layout in every language; each line of text inside
   still takes its own direction, so Arabic lines read and align right-to-left. */
[dir="rtl"] .mk { direction: ltr; }
[dir="rtl"] .mk :is(p, span, div, b, em, i, strong) { unicode-bidi: plaintext; }

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--ep-bg);
  color: var(--ep-ink);
  font-family: var(--ep-sans);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

img, svg { max-width: 100%; }

a { color: inherit; text-decoration: none; }

/* ---------- Type ---------- */

h1, h2, h3, h4 {
  margin: 0;
  font-weight: 800;
  line-height: 1.04;
  letter-spacing: -0.032em;
}

.h-hero   { font-size: clamp(44px, 7.2vw, 80px); letter-spacing: -0.035em; }
.hero-line { display: block; }
/* Accent words take the brand green (6.8:1 on cream; mint 9.5:1 on the dark background). */
.h-accent { color: var(--ep-brand); }
.h-2      { font-size: clamp(34px, 5.4vw, 60px); }
.h-3      { font-size: clamp(30px, 4.5vw, 50px); }
.h-4      { font-size: clamp(22px, 2.6vw, 30px); letter-spacing: -0.025em; }

.lede {
  margin: 18px auto 0;
  max-width: 640px;
  color: var(--ep-muted);
  font-size: clamp(15px, 1.35vw, 17px);
  line-height: 1.6;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 20px;
  font-weight: 600;
  letter-spacing: -0.02em;
}

/* ---------- Layout ---------- */

.wrap { width: min(100% - 40px, var(--ep-max)); margin-inline: auto; }

.section { padding: 84px 0; }

/* The nav is fixed, so an anchor jump would otherwise park the heading underneath it. */
[id] { scroll-margin-top: 76px; }

.card {
  background: var(--ep-card);
  border: 1px solid var(--ep-line);
  border-radius: var(--ep-radius);
  padding: clamp(28px, 4vw, 64px) clamp(20px, 3vw, 48px);
  text-align: center;
}

.card + .card { margin-top: 20px; }

.card .lede { max-width: 820px; }

.mock-slot {
  margin-top: clamp(28px, 4vw, 52px);
  display: flex;
  justify-content: center;
}

.mock-slot > * { width: 100%; max-width: 1000px; }

/* Cards centre their copy, but app chrome inside a mockup should read left-aligned
   like the real thing. Any mockup that wants centring sets it on its own elements. */
.mock-slot .mk { text-align: start; }

/* A small factual note under a card's mockup (requirements, caveats). */
.card-note { max-width: 640px; margin: 22px auto 0; line-height: 1.55; }

/* Two smaller cards side by side (Custom Categories / Find by App or Type) */
.card-duo {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin-top: 20px;
}

.card-duo .card { text-align: start; padding: clamp(24px, 3vw, 40px); }
.card-duo + .card { margin-top: 20px; }
.card-duo .card + .card { margin-top: 0; } /* side by side, so no stacking gap */
.card-duo .lede { margin-inline: 0; }

@media (max-width: 900px) {
  .card-duo { grid-template-columns: 1fr; }
}

/* ---------- Nav ---------- */

.nav {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 100;
  display: flex;
  align-items: center;
  gap: 22px;
  height: 60px;
  padding: 0 max(20px, calc((100% - var(--ep-max)) / 2));
  background: color-mix(in srgb, var(--ep-bg) 88%, transparent);
  -webkit-backdrop-filter: saturate(1.2) blur(14px);
  backdrop-filter: saturate(1.2) blur(14px);
  border-bottom: 1px solid var(--ep-line);
  color: var(--ep-ink);
}

.nav-brand {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-inline-end: auto;
  font-weight: 800;
  font-size: 17px;
  letter-spacing: -0.025em;
}

/* The app icon in miniature: a green tile with a cream clipboard. Fixed colours in both
   modes, like the icon itself. */
.nav-mark {
  width: 26px;
  height: 26px;
  border-radius: 7px;
  background: #1E5E3F;
  color: #F4F1E8;
  display: grid;
  place-items: center;
  box-shadow: inset 0 -1px 0 rgba(4, 24, 14, 0.3), 0 1px 2px rgba(4, 24, 14, 0.2);
}

.nav-links { display: flex; gap: 20px; font-size: 14px; font-weight: 500; }
.nav-links a { color: var(--ep-muted); transition: color 0.18s; white-space: nowrap; }
.nav-links a:hover { color: var(--ep-ink); }

.nav-cta {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 38px;
  padding: 0 16px;
  background: var(--ep-action);
  color: var(--ep-on-action);
  border-radius: 10px;
  font-size: 13.5px;
  font-weight: 600;
  white-space: nowrap;
}

/* Language switcher: in the nav and the footer colophon. */
.lang { display: flex; gap: 2px; font-size: 12.5px; font-weight: 600; }
.lang a { padding: 5px 8px; border-radius: 8px; color: var(--ep-muted); transition: color 0.18s, background 0.18s; }
.lang a:hover { color: var(--ep-ink); }
.lang a[aria-current="page"] { color: var(--ep-ink); background: var(--ep-card); }
.lang-foot a { font-size: 12.5px; }

@media (max-width: 860px) {
  .nav { gap: 12px; padding-inline: 12px 8px; }
  .nav-links { display: none; }
}

/* Phones: the nav switcher lists only the other languages (the footer one lists all three). */
@media (max-width: 480px) {
  .nav { gap: 6px; }
  .nav .lang a[aria-current="page"] { display: none; }
  .nav-cta svg { display: none; }
  .lang a { padding: 5px 6px; }
}

/* ---------- Hero + scroll stage ---------- */
/* The hero is a tall scroll track with a sticky stage inside it. `--p` (0→1) is
   written by app.js from the scroll position and drives every transform below,
   so the whole sequence is one timeline rather than a pile of listeners. */

.hero {
  position: relative;
  height: 320vh;
  --p: 0;
}

.stage {
  position: sticky;
  top: 0;
  height: 100vh;
  overflow: hidden;
  background: var(--ep-bg);
}

/* Hero backdrop: warm paper with a faint grain, and the terracotta hills along the bottom. */
.sky {
  position: absolute;
  inset: 0;
  background:
    url("assets/wallpaper.svg") center bottom / max(100%, 1200px) auto no-repeat,
    var(--ep-grain);
  background-color: var(--ep-bg);
  --ep-grain: 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='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 .2 0 0 0 0 .28 0 0 0 0 .22 0 0 0 .07 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

@media (prefers-color-scheme: dark) {
  .sky { background-image: url("assets/wallpaper-dark.svg"), var(--ep-grain); }
}

.hero-copy {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 0 20px;
  text-align: center;
  color: var(--ep-ink);
  /* Lifts and fades away over the first fifth of the scroll, clearing out before
     the film on the screen behind it is fully in. */
  opacity: calc(1 - var(--p) * 4.6);
  transform: translateY(calc(var(--p) * -120px));
  will-change: opacity, transform;
}

.hero-copy .lede { color: var(--ep-muted); }
.hero-copy .eyebrow { color: var(--ep-action); font-size: 15px; font-weight: 700; letter-spacing: 0; }

.hero-cta {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  margin-top: 30px;
  height: 52px;
  padding: 0 26px;
  background: var(--ep-action);
  color: var(--ep-on-action);
  border-radius: 14px;
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.16) inset, 0 8px 22px -10px rgba(10, 40, 25, 0.55);
  font-size: 15px;
  font-weight: 600;
  transition: transform 0.2s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.hero-cta:hover { transform: translateY(-2px); }

.hero-meta {
  margin-top: 20px;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px 26px;
  font-size: 13px;
  font-weight: 500;
  color: var(--ep-muted);
}

/* Thanks page: the same hills as the hero. */
.thanks-page { background: url("assets/wallpaper.svg") center bottom / max(100%, 1200px) auto no-repeat, var(--ep-bg); }
@media (prefers-color-scheme: dark) { .thanks-page { background-image: url("assets/wallpaper-dark.svg"); } }

/* Product Hunt "featured" badge, Product Hunt's own embed. */
.ph-badge { display: inline-block; margin-top: 22px; line-height: 0; }
.ph-badge img { width: 250px; height: 54px; }
/* On short viewports the badge reaches down to where the scroll hint sits; the hint is the
   one to give up. */
@media (max-height: 780px) { .scroll-hint { display: none; } }

/* The display: starts full-bleed and shrinks into a framed Mac screen.
   `.display` is the bezel, `.screen` is the glass — separating them means the
   menu bar and notch sit *inside* the frame instead of being clipped by it. */
.display {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 1000px;
  max-width: 96vw;
  /* 16:10 like a real MacBook, at every width — a fixed height went portrait on phones. */
  aspect-ratio: 16 / 10;
  padding: calc(var(--p) * 6px);
  transform: translate(-50%, -50%)
    scale(calc(1 + (1 - var(--p)) * 1.15));
  border-radius: calc(6px + var(--p) * 26px);
  background: #0d0d0f;
  box-shadow: 0 40px 90px rgba(6, 24, 14, calc(var(--p) * 0.34));
  opacity: clamp(0, calc(var(--p) * 5), 1);
  will-change: transform, border-radius;
}

.screen {
  position: relative;
  width: 100%;
  height: 100%;
  border-radius: calc(4px + var(--p) * 21px);
  overflow: hidden;
  background: #DCEBDD;
}

/* The film is 16:9 on a 16:10 screen; `cover` trims a sliver off each side, and every
   caption and card in the film sits well inside that margin. */
.film-video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; background: #F4F1E8; }

.notch {
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 170px;
  height: 26px;
  background: #000;
  border-radius: 0 0 11px 11px;
  z-index: 5;
  opacity: clamp(0, calc((var(--p) - 0.5) * 4), 1);
}

/* Scroll hint */
.scroll-hint {
  position: absolute;
  left: 50%;
  bottom: 28px;
  transform: translateX(-50%);
  display: grid;
  place-items: center;
  gap: 6px;
  color: rgba(255, 255, 255, 0.9);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-shadow: 0 1px 3px rgba(4, 24, 14, 0.4);
  opacity: calc(1 - var(--p) * 6);
}

.scroll-hint span {
  width: 20px;
  height: 32px;
  border: 1.5px solid currentColor;
  border-radius: 999px;
  position: relative;
}

.scroll-hint span::after {
  content: "";
  position: absolute;
  top: 6px;
  left: 50%;
  width: 3px;
  height: 6px;
  margin-left: -1.5px;
  border-radius: 2px;
  background: currentColor;
  animation: ep-scroll 1.8s ease-in-out infinite;
}

@keyframes ep-scroll {
  0%, 100% { transform: translateY(0); opacity: 1; }
  60% { transform: translateY(11px); opacity: 0.2; }
}

/* ---------- Film controls on the hero's screen ---------- */
/* Hidden while the display is still zooming (they'd be scaled 2× and half off-screen);
   app.js adds .is-framed once it has settled into the Mac frame. */

.film-toggle, .film-sound {
  opacity: 0;
  pointer-events: none;
  z-index: 6;
}

.hero.is-framed .film-toggle,
.hero.is-framed .film-sound {
  opacity: 1;
  pointer-events: auto;
  transition: opacity 0.3s, background 0.18s, transform 0.18s;
}

/* The faded-out hero copy still covers the stage; let clicks through to the screen. */
.hero.is-zoomed .hero-copy { pointer-events: none; }

.film-toggle {
  position: absolute;
  right: 18px;
  bottom: 18px;
  width: 46px;
  height: 46px;
  display: grid;
  place-items: center;
  border: 0;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.55);
  color: #fff;
  cursor: pointer;
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  transition: background 0.18s, transform 0.18s;
}

.film-toggle:hover { background: rgba(0, 0, 0, 0.75); transform: scale(1.05); }
.film-toggle svg { width: 20px; height: 20px; }
.film-toggle .i-pause { display: none; }
.film-toggle[data-state="playing"] .i-play { display: none; }
.film-toggle[data-state="playing"] .i-pause { display: block; }

.film-sound {
  position: absolute;
  left: 18px;
  bottom: 18px;
  height: 46px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 0 16px 0 13px;
  border: 0;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.55);
  color: #fff;
  font: inherit;
  font-size: 13.5px;
  font-weight: 600;
  cursor: pointer;
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  transition: background 0.18s;
}

.film-sound:hover { background: rgba(0, 0, 0, 0.75); }
.film-sound svg { width: 20px; height: 20px; }
.film-sound .i-sound { display: none; }
.film-sound[aria-pressed="true"] .i-muted { display: none; }
.film-sound[aria-pressed="true"] .i-sound { display: block; }

@media (max-width: 640px) {
  .film-toggle { right: 10px; bottom: 10px; width: 38px; height: 38px; }
  .film-sound { left: 10px; bottom: 10px; width: 38px; height: 38px; padding: 0; justify-content: center; }
  .film-sound span { display: none; }
}

/* ---------- Feature pill row ---------- */

.pills {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  margin-top: 26px;
}

.pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 29px;
  padding: 0 13px;
  background: var(--ep-card);
  border-radius: 30px;
  font-size: 12px;
  color: var(--ep-ink);
  border: 1px solid var(--ep-line);
  white-space: nowrap;
}

.pill svg { width: 14px; height: 14px; flex: none; color: var(--ep-brand); }
/* The one pill the page wants you to notice: images are clips too. */
.pill-hi { background: var(--ep-action); border-color: var(--ep-action); color: var(--ep-on-action); font-weight: 600; }
.pill-hi svg { color: var(--ep-on-action); }

/* ---------- Audience grid ---------- */

.audience {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-top: 44px;
}

.audience .card { text-align: start; padding: 34px 30px; }
.audience h3 { margin-bottom: 10px; }
.audience p { margin: 0; color: var(--ep-muted); font-size: 14.5px; }

@media (max-width: 980px) { .audience { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 640px) { .audience { grid-template-columns: 1fr; } }

/* ---------- Pricing ---------- */

.pricing {
  max-width: 520px;
  margin: 44px auto 0;
  background: var(--ep-raised);
  border: 1px solid var(--ep-line);
  border-top: 3px solid var(--ep-brass);   /* the brass rule: one decorative detail */
  border-radius: var(--ep-radius);
  padding: 34px;
  box-shadow: 0 24px 60px rgba(10, 30, 20, 0.08);
  text-align: start;
}

.price-row { display: flex; align-items: baseline; gap: 12px; margin: 22px 0 4px; }
.price { font-size: 52px; font-weight: 800; letter-spacing: -0.035em; }
.price-note { color: var(--ep-muted); font-size: 13.5px; }

.perks { list-style: none; margin: 22px 0 0; padding: 0; display: grid; gap: 11px; }
.perks li { display: flex; gap: 10px; align-items: flex-start; font-size: 14.5px; }
.perks svg { flex: none; width: 17px; height: 17px; margin-top: 2px; color: var(--ep-brand); }

.buy {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  width: 100%;
  height: 52px;
  margin-top: 24px;
  background: var(--ep-action);
  color: var(--ep-on-action);
  border-radius: 14px;
  font-size: 15px;
  font-weight: 600;
  transition: transform 0.2s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.buy:hover { transform: translateY(-2px); background: var(--ep-action-hover); }

.fineprint { margin-top: 14px; color: var(--ep-muted); font-size: 11.5px; text-align: center; }

/* ---------- Waitlist (replaces the buy flow while the App Store version is in review) ---------- */

.soon-badge {
  display: inline-block;
  margin: 0 0 16px;
  padding: 6px 14px;
  border: 1px solid var(--ep-line);
  border-radius: 999px;
  background: var(--ep-raised);
  color: var(--ep-brand);
  font-size: 13px;
  font-weight: 700;
}

.waitlist { margin: 0; }
.wl-label { display: block; margin-bottom: 8px; font-size: 14px; font-weight: 600; }
.wl-row { display: flex; gap: 10px; }
.wl-input {
  flex: 1;
  min-width: 0;
  height: 52px;
  padding: 0 16px;
  border: 1px solid var(--ep-line);
  border-radius: 14px;
  background: var(--ep-bg);
  color: var(--ep-ink);
  font: inherit;
  font-size: 15px;
}
.wl-input::placeholder { color: var(--ep-muted); opacity: 0.8; }
.wl-input:focus-visible { outline: 3px solid var(--ep-brand); outline-offset: 1px; }
.wl-input[aria-invalid="true"] { border-color: #A04A3A; }
.wl-btn { width: auto; flex: none; margin-top: 0; padding: 0 22px; border: 0; cursor: pointer; font: inherit; font-weight: 600; }
.wl-btn[disabled] { opacity: 0.7; cursor: progress; }
.wl-trap { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.wl-msg { min-height: 0; margin: 10px 0 0; font-size: 14px; font-weight: 600; color: var(--ep-brand); }
.wl-msg:empty { display: none; }
.wl-msg.is-error { color: #A04A3A; }
.wl-fine { text-align: start; }
.waitlist.is-done .wl-row, .waitlist.is-done .wl-label { display: none; }

.plan-row { flex-wrap: wrap; gap: 10px 22px; margin-top: 26px; padding-top: 22px; border-top: 1px solid var(--ep-line); }
.plan { color: var(--ep-muted); font-size: 15px; }
.plan strong { color: var(--ep-ink); font-size: 26px; font-weight: 800; letter-spacing: -0.03em; margin-inline-end: 4px; }

@media (max-width: 520px) {
  .wl-row { flex-direction: column; }
  .wl-input { flex: none; }
  .wl-btn { width: 100%; }
}

/* Keyboard focus, visible everywhere it matters */
a:focus-visible, button:focus-visible, summary:focus-visible {
  outline: 3px solid var(--ep-brand);
  outline-offset: 3px;
  border-radius: 8px;
}

/* ---------- FAQ ---------- */

.faq { max-width: 780px; margin: 44px auto 0; }

.faq details {
  border-bottom: 1px solid var(--ep-line);
  padding: 20px 4px;
}

.faq summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  cursor: pointer;
  list-style: none;
  font-size: 17px;
  font-weight: 600;
  letter-spacing: -0.02em;
}

.faq summary::-webkit-details-marker { display: none; }

.faq summary::after {
  content: "";
  flex: none;
  width: 11px;
  height: 11px;
  border-right: 2px solid var(--ep-muted);
  border-bottom: 2px solid var(--ep-muted);
  transform: rotate(45deg) translate(-3px, -3px);
  transition: transform 0.22s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.faq details[open] summary::after { transform: rotate(-135deg) translate(-3px, -3px); }

.faq p { margin: 12px 0 0; color: var(--ep-muted); font-size: 15px; max-width: 68ch; }
.faq p a { color: var(--ep-action); text-decoration: underline; text-underline-offset: 2px; }

/* ---------- Footer ---------- */

.footer { border-top: 1px solid var(--ep-line); padding: 54px 0 60px; }

.footer-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 40px;
  justify-content: space-between;
}

.footer-label { margin: 0 0 12px; font-size: 12px; text-transform: uppercase; letter-spacing: 0.09em; color: var(--ep-muted); font-weight: 600; }
.footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 9px; }
.footer a { color: var(--ep-muted); font-size: 14px; }
.footer a:hover { color: var(--ep-ink); }

.footer-brand { max-width: 280px; }
.footer-brand p { color: var(--ep-muted); font-size: 14px; margin: 12px 0 0; }

.colophon {
  margin-top: 44px;
  padding-top: 22px;
  border-top: 1px solid var(--ep-line);
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: space-between;
  color: var(--ep-muted);
  font-size: 12.5px;
}

/* ---------- Inline code / keycaps in copy ---------- */

code {
  font-family: ui-monospace, SFMono-Regular, "SF Mono", Menlo, monospace;
  font-size: 0.9em;
  background: var(--ep-card);
  padding: 0.14em 0.42em;
  border-radius: 5px;
}

kbd {
  font-family: inherit;
  font-size: 0.86em;
  font-weight: 600;
  background: var(--ep-raised);
  border: 1px solid var(--ep-line);
  border-bottom-width: 2px;
  border-radius: 6px;
  padding: 0.1em 0.42em;
  color: var(--ep-ink);
}

/* ---------- ⌃⌘0–9 keycap demo ---------- */

.keycaps { width: 100%; max-width: 760px; }

.keycap-row {
  display: grid;
  grid-template-columns: repeat(10, 1fr);
  gap: 8px;
}

.keycap {
  display: grid;
  place-items: center;
  gap: 1px;
  aspect-ratio: 1 / 1;
  background: var(--ep-raised);
  border: 1px solid var(--ep-line);
  border-bottom-width: 3px;
  border-radius: 11px;
  transition: transform 0.14s cubic-bezier(0.2, 0.8, 0.2, 1),
              background 0.14s, border-color 0.14s, box-shadow 0.14s;
}

.keycap em { font-style: normal; font-size: 10px; color: var(--ep-muted); }
.keycap b { font-size: 17px; font-weight: 700; letter-spacing: -0.03em; }

.keycap.on {
  background: var(--ep-action);
  border-color: var(--ep-action);
  border-bottom-width: 1px;
  color: var(--ep-on-action);
  transform: translateY(2px);
  box-shadow: 0 6px 18px rgba(20, 70, 45, 0.35);
}

.keycap.on em { color: var(--ep-on-action); opacity: 0.8; }

.keycap-out {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 16px;
  padding: 14px 16px;
  background: var(--ep-raised);
  border: 1px solid var(--ep-line);
  border-radius: 12px;
  text-align: start;
  font-size: 14px;
  box-shadow: 0 8px 24px rgba(10, 30, 20, 0.06);
}

.keycap-dot {
  flex: none;
  width: 10px;
  height: 10px;
  border-radius: 3px;
  background: var(--ep-line);
}

.keycap-out[data-type="link"] .keycap-dot { background: var(--ep-brand); }
.keycap-out[data-type="code"] .keycap-dot { background: #6A4C8C; }
.keycap-out[data-type="file"] .keycap-dot { background: #45597A; }
.keycap-out[data-type="text"] .keycap-dot { background: var(--ep-muted); }

.keycap-out[data-type="code"] .keycap-text {
  font-family: ui-monospace, SFMono-Regular, "SF Mono", Menlo, monospace;
  font-size: 13px;
}

.keycap-text { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.keycap-out.pop { animation: ep-pop 0.34s cubic-bezier(0.2, 0.8, 0.2, 1); }

@keyframes ep-pop {
  0% { transform: translateY(6px) scale(0.99); opacity: 0.4; }
  100% { transform: none; opacity: 1; }
}

@media (max-width: 620px) {
  .keycap-row { grid-template-columns: repeat(5, 1fr); }
}

/* ---------- Reveal on scroll ---------- */

.reveal {
  opacity: 0;
  transform: translateY(26px);
  transition: opacity 0.7s cubic-bezier(0.2, 0.8, 0.2, 1),
              transform 0.7s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.reveal.in { opacity: 1; transform: none; }

/* ---------- Reduced motion ---------- */

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .hero { height: 100vh; --p: 1 !important; }
  .stage { position: relative; }
  .hero-copy { position: relative; opacity: 1; transform: none; height: 100vh; }
  /* No zoom: the framed Mac sits under the copy, film paused until the viewer presses play. */
  .hero { height: auto; }
  .stage { height: auto; overflow: visible; padding-bottom: 80px; }
  .hero-copy { height: auto; padding: 150px 20px 56px; }
  .display { position: relative; top: auto; left: auto; transform: none; margin: 0 auto; }
  .hero .film-toggle, .hero .film-sound { opacity: 1; pointer-events: auto; }
  .scroll-hint { display: none; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .scroll-hint span::after { animation: none; }
}
