/* The home page only. Warm paper and charcoal colors, set here so the studio keeps its own look.
   Fonts are served from this site (assets/fonts, SIL Open Font License). */
@font-face { font-family: "Inter"; font-weight: 400; font-display: swap; src: url("../assets/fonts/inter-latin-400-normal.woff2") format("woff2"); }
@font-face { font-family: "Inter"; font-weight: 500; font-display: swap; src: url("../assets/fonts/inter-latin-500-normal.woff2") format("woff2"); }
@font-face { font-family: "Inter"; font-weight: 600; font-display: swap; src: url("../assets/fonts/inter-latin-600-normal.woff2") format("woff2"); }
@font-face { font-family: "Inter"; font-weight: 700; font-display: swap; src: url("../assets/fonts/inter-latin-700-normal.woff2") format("woff2"); }
@font-face { font-family: "Fraunces"; font-weight: 600; font-style: normal; font-display: swap; src: url("../assets/fonts/fraunces-latin-600-normal.woff2") format("woff2"); }
@font-face { font-family: "Fraunces"; font-weight: 600; font-style: italic; font-display: swap; src: url("../assets/fonts/fraunces-latin-600-italic.woff2") format("woff2"); }

/* Palette. Light: paper and ink. Dark: warm charcoal. Accent: vermilion. Support: deep teal and mustard. All text pairs pass WCAG AA. */
body.h2 {
  --bg: #f4eee2; --bg2: #ebe2d0; --panel: #fffaf1; --line: #e0d4bf; --line2: #cdbfa6;
  --fg: #241d17; --mute: #5f5246; --faint: #6b5d50;
  --acc: #b23510; --acc-fg: #fff8ee; --acc-soft: #f6dccd; --link: #1d6660;
  --teal: #1d6660; --mustard: #d99a1e; --good: #1d6660;
  --shadow: 0 1px 2px rgba(60, 40, 20, .08), 0 10px 30px rgba(60, 40, 20, .08);
  --display: "Fraunces", Georgia, "Times New Roman", serif;
  --film: #171310; --film-fg: #efe6d6;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) body.h2 {
    --bg: #1c1814; --bg2: #231e19; --panel: #2a241e; --line: #3a322a; --line2: #4b4137;
    --fg: #f2eadc; --mute: #c4b6a3; --faint: #a39481;
    --acc: #f26a43; --acc-fg: #1c1814; --acc-soft: #3a2419; --link: #7cc4b9;
    --teal: #6dbdb1; --mustard: #e7b347; --good: #6dbdb1;
    --shadow: 0 1px 2px rgba(0, 0, 0, .35), 0 10px 30px rgba(0, 0, 0, .3);
  }
}
:root[data-theme="dark"] body.h2 {
  --bg: #1c1814; --bg2: #231e19; --panel: #2a241e; --line: #3a322a; --line2: #4b4137;
  --fg: #f2eadc; --mute: #c4b6a3; --faint: #a39481;
  --acc: #f26a43; --acc-fg: #1c1814; --acc-soft: #3a2419; --link: #7cc4b9;
  --teal: #6dbdb1; --mustard: #e7b347; --good: #6dbdb1;
  --shadow: 0 1px 2px rgba(0, 0, 0, .35), 0 10px 30px rgba(0, 0, 0, .3);
}

body.h2 { background: var(--bg); color: var(--fg); margin: 0; }
.h2 main { overflow-x: clip; }
.h2 a { color: var(--link); }
.h2 .btn { color: var(--acc-fg); background: var(--acc); border-color: var(--acc); }
.h2 h1, .h2 h2, .h2 h3 { font-family: var(--display); font-weight: 600; letter-spacing: -.015em; }
.h2 .brand { font-family: var(--display); font-weight: 600; color: var(--fg); }
.h2 [hidden] { display: none !important; }
.h2 .brand .dot { background: conic-gradient(from 200deg, var(--acc), var(--mustard), var(--teal), var(--acc)); border-radius: 50%; }
.h2 .pill.acc { background: var(--acc-soft); color: var(--fg); border-color: transparent; }
.h2 :focus-visible { outline: 2px solid var(--acc); outline-offset: 2px; }

/* Top bar */
.h2-top { position: sticky; top: 0; z-index: 20; display: flex; align-items: center; gap: 20px; padding: 12px clamp(16px, 4vw, 40px);
  background: color-mix(in srgb, var(--bg) 88%, transparent); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
.h2-nav { display: flex; gap: 18px; margin-left: 8px; }
.h2-nav a, .h2-link { color: var(--mute); text-decoration: none; font-size: 14px; font-weight: 500; }
.h2-nav a:hover, .h2-link:hover { color: var(--fg); }
.h2-actions { margin-left: auto; display: flex; align-items: center; gap: 14px; }
@media (max-width: 860px) { .h2-nav { display: none; } }
@media (max-width: 420px) { .h2-actions .h2-link { display: none; } }

/* Film grain: a light paper texture over the whole page, drawn in the page itself (no image request) */
body.h2 { 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='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 .35 0 0 0 0 .25 0 0 0 0 .15 0 0 0 .09 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E"); }

/* Hero: words and prompt box on the left, the still-to-moving print on the right */
.h2-hero { position: relative; display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); gap: clamp(28px, 4vw, 56px); align-items: center;
  max-width: 1240px; margin: 0 auto; padding: clamp(40px, 7vw, 88px) clamp(16px, 4vw, 40px) 48px; }
@media (max-width: 980px) { .h2-hero { grid-template-columns: 1fr; } }
.h2-hero h1 { font-size: clamp(42px, 6.4vw, 80px); line-height: 1.02; margin: 18px 0 14px; }
.h2-hero h1 b { font-style: italic; color: var(--acc); font-weight: 600; display: inline-block; padding: 0 .04em .08em;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 200 16' preserveAspectRatio='none'%3E%3Cpath d='M3 11 C 40 3, 70 14, 105 8 S 170 4, 197 9' fill='none' stroke='%23d99a1e' stroke-width='5' stroke-linecap='round'/%3E%3C/svg%3E") no-repeat 0 100% / 100% .22em; }
.h2-lead { font-size: clamp(16px, 2vw, 19px); color: var(--mute); max-width: 560px; margin: 0 0 24px; line-height: 1.5; }
.h2-box { background: var(--panel); border: 1.5px solid var(--line2); border-radius: 20px; padding: 16px 16px 12px; box-shadow: var(--shadow); transition: border-color .2s, box-shadow .2s; }
.h2-box:focus-within { border-color: var(--acc); box-shadow: 0 0 0 4px color-mix(in srgb, var(--acc) 16%, transparent), var(--shadow); }
.h2-box textarea { width: 100%; border: 0; outline: 0; resize: none; background: transparent; color: var(--fg); font: 400 17px/1.5 var(--font); min-height: 56px; }
.h2-box textarea::placeholder { color: var(--faint); }
.h2-box-row { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-top: 6px; }
.h2-add { display: inline-flex; align-items: center; gap: 6px; background: var(--bg2); color: var(--fg); border: 1px solid var(--line2); border-radius: 99px; padding: 8px 14px; font-weight: 500; }
.h2-add:hover { border-color: var(--acc); }
.h2-chip { display: inline-flex; align-items: center; gap: 5px; font-size: 12.5px; color: var(--mute); border: 1px solid var(--line); border-radius: 99px; padding: 6px 11px; }
.h2-chip-safe { color: var(--teal); border-color: color-mix(in srgb, var(--teal) 45%, transparent); }
.h2-run { margin-left: auto; border-radius: 99px; padding: 10px 20px; }
.h2-nudge { margin: 10px 2px 2px; font-size: 13px; color: var(--acc); }
.h2-ideas { display: flex; flex-wrap: wrap; gap: 8px; margin: 16px 0 6px; }
.h2-idea { background: transparent; color: var(--mute); border: 1px dashed var(--line2); border-radius: 99px; padding: 7px 14px; font-weight: 500; font-size: 13.5px; }
.h2-idea:hover { color: var(--fg); border-style: solid; border-color: var(--fg); }
.h2-idea-sp { color: var(--acc); border-style: solid; border-color: color-mix(in srgb, var(--acc) 50%, transparent); }
.h2-runnote { font-size: 13px; color: var(--faint); margin: 10px 0 0; }
.h2-trust { list-style: none; padding: 0; margin: 18px 0 0; display: flex; flex-wrap: wrap; gap: 8px 20px; font-size: 13.5px; color: var(--mute); }
.h2-trust li::before { content: ""; display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: var(--teal); margin-right: 8px; vertical-align: 1px; }

/* The print: a photo with a line you drag. Left of the line is the still picture, right of it the real clip. */
.h2-print { margin: 0; background: var(--panel); border: 1px solid var(--line); border-radius: 10px; padding: 12px 12px 14px; box-shadow: var(--shadow); transform: rotate(.8deg); }
@media (max-width: 980px) { .h2-print { transform: none; } }
.h2-compare { position: relative; aspect-ratio: 16 / 9; border-radius: 6px; overflow: hidden; background: var(--bg2); touch-action: pan-y; user-select: none; }
.h2-compare video, .h2-compare img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; }
.h2-compare img { clip-path: inset(0 calc(100% - var(--x)) 0 0); }
.h2-handle { position: absolute; top: 0; bottom: 0; left: var(--x); width: 0; pointer-events: none; }
.h2-handle::before { content: ""; position: absolute; top: 0; bottom: 0; left: -1.5px; width: 3px; background: #fff8ee; box-shadow: 0 0 0 1px rgba(0, 0, 0, .15); }
.h2-handle span { position: absolute; top: 50%; left: -19px; width: 38px; height: 38px; margin-top: -19px; border-radius: 50%; background: #fff8ee; box-shadow: 0 2px 8px rgba(0, 0, 0, .3);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M9 7l-5 5 5 5M15 7l5 5-5 5' fill='none' stroke='%23b23510' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-size: 22px; background-position: center; background-repeat: no-repeat; }
.h2-compare input[type=range] { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; cursor: ew-resize; touch-action: pan-y; }
.h2-compare input[type=range]:focus-visible ~ .h2-handle span, .h2-compare:focus-within .h2-handle span { outline: 3px solid var(--acc); outline-offset: 2px; }
.h2-tag { position: absolute; top: 10px; font-size: 12px; font-weight: 600; letter-spacing: .02em; color: #fff8ee; background: rgba(23, 19, 16, .72); padding: 4px 9px; border-radius: 99px; transition: opacity .25s; pointer-events: none; }
.h2-tag-still { left: 10px; }
.h2-tag-move { right: 10px; background: var(--acc); color: #fff8ee; }
.h2-compare.at-still .h2-tag-move, .h2-compare.at-move .h2-tag-still { opacity: 0; }
.h2-play { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); z-index: 2; border-radius: 99px; padding: 10px 18px; background: var(--acc); color: var(--acc-fg); font-weight: 600; box-shadow: var(--shadow); }
.h2-print figcaption { padding: 12px 4px 0; }
.h2-hint { font-size: 13px; color: var(--faint); margin: 0 0 6px; }
.h2-cmp-prompt { font-family: var(--display); font-style: italic; font-size: 17px; line-height: 1.4; margin: 0 0 10px; color: var(--fg); }
.h2-cmp-prompt b { font-family: var(--font); font-style: normal; font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: var(--acc); margin-right: 4px; }
.h2-picks { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; font-size: 13px; color: var(--mute); }
.h2-picks span { margin-right: 4px; }
.h2-picks button { background: transparent; border: 1px solid var(--line2); color: var(--fg); border-radius: 99px; padding: 5px 12px; font-size: 13px; font-weight: 500; }
.h2-picks button[aria-pressed="true"] { background: var(--fg); color: var(--bg); border-color: var(--fg); }

/* Film strip of real frames */
.h2-film { position: relative; padding: 36px 0 44px; }
.h2-film-head { position: relative; z-index: 1; text-align: center; padding: 0 16px 20px; }
.h2-film-head h2 { font-size: clamp(26px, 3.6vw, 38px); margin: 6px 0 6px; }
.h2-film-head p { color: var(--mute); margin: 0; }
.h2-reel { position: relative; z-index: 1; background: var(--film); padding: 22px 0; overflow: hidden; transform: rotate(-1deg); margin: 0 -20px; }
.h2-reel::before, .h2-reel::after { content: ""; position: absolute; left: 0; right: 0; height: 10px;
  background: radial-gradient(circle at 50% 50%, var(--bg) 0 3.2px, transparent 3.8px) 0 0 / 22px 10px repeat-x; }
.h2-reel::before { top: 6px; } .h2-reel::after { bottom: 6px; }
.h2-reel-track { display: flex; gap: 8px; width: max-content; padding: 0 8px; }
.h2-reel figure { margin: 0; width: clamp(150px, 20vw, 230px); flex: 0 0 auto; }
.h2-reel img { width: 100%; height: auto; aspect-ratio: 16 / 9; display: block; border-radius: 3px; background: #2a231d; }
.h2-reel figure::after { content: attr(data-t) " s"; display: block; margin-top: 6px; font: 600 11px/1 ui-monospace, "SF Mono", Menlo, monospace; color: #e7b347; letter-spacing: .04em; }
@media (prefers-reduced-motion: reduce) { .h2-reel { overflow-x: auto; transform: none; margin: 0; } }

/* Gallery row */
.h2-gallery { padding: 16px 0 0; }
.h2-head { display: flex; align-items: baseline; gap: 16px; flex-wrap: wrap; padding: 0 clamp(16px, 4vw, 40px); max-width: 1240px; margin: 0 auto; }
.h2-head h2 { margin: 0; font-size: 28px; }
.h2-head .note { color: var(--mute); margin: 0; }
.h2-strip { display: flex; align-items: flex-start; gap: 14px; overflow-x: auto; scroll-snap-type: x mandatory; scroll-padding-inline: clamp(16px, 4vw, 40px); padding: 16px clamp(16px, 4vw, 40px) 18px; scrollbar-width: thin; }
.h2-strip figure { flex: 0 0 auto; width: min(78vw, 340px); margin: 0; scroll-snap-align: start; }
.h2-strip figure.tall { width: min(40vw, 160px); }
.h2-strip video { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; border-radius: 8px; background: var(--bg2); display: block; border: 1px solid var(--line); transition: transform .3s ease, box-shadow .3s ease; }
.h2-strip figure.tall video { aspect-ratio: 9 / 16; }
.h2-strip figure:hover video { transform: translateY(-3px) rotate(-.4deg); box-shadow: var(--shadow); }
.h2-strip figcaption { font-size: 13px; color: var(--mute); margin-top: 8px; line-height: 1.4; }

/* Sections */
.h2-sec { max-width: 1080px; margin: 0 auto; padding: clamp(48px, 7vw, 84px) clamp(16px, 4vw, 40px); }
.h2-band { max-width: none; background: var(--bg2); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.h2-sec.h2-band > * { max-width: calc(1080px - 2 * clamp(16px, 4vw, 40px)); margin-left: auto; margin-right: auto; }
.h2-sec h2 { font-size: clamp(30px, 4.4vw, 46px); margin: 6px 0 12px; line-height: 1.08; }
.h2-kicker { display: block; font-size: 12.5px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--acc); }
.h2-sub { color: var(--mute); font-size: 17px; max-width: 700px; line-height: 1.55; margin-bottom: 28px; }
.h2-card { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; }
.h2-card b { display: block; font-size: 16px; margin-bottom: 6px; }
.h2-card p { margin: 0; color: var(--mute); line-height: 1.5; font-size: 14.5px; }
.h2-grid4 { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 14px; }
.h2-grid3 { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 14px; }
.h2-grid2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 14px; }
.h2-ico { width: 38px; height: 38px; border-radius: 10px; display: grid; place-items: center; background: var(--acc-soft); color: var(--acc); margin-bottom: 12px; }
.h2-ico svg { width: 20px; height: 20px; }
.h2-honest { margin-top: 22px; font-size: 14px; color: var(--mute); border-left: 3px solid var(--mustard); padding: 4px 0 4px 14px; max-width: 760px; }

/* Steps */
.h2-steps { list-style: none; padding: 0; margin: 20px 0 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 14px; }
.h2-steps li { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; }
.h2-steps .n { display: inline-grid; place-items: center; width: 32px; height: 32px; border-radius: 50%; background: var(--mustard); color: #241d17; font: 600 16px/1 var(--display); margin-bottom: 10px; }
.h2-steps b { display: block; margin-bottom: 4px; }
.h2-steps p { margin: 0; color: var(--mute); font-size: 14.5px; line-height: 1.5; }

/* Safety levels */
.h2-level-head { display: flex; flex-direction: column; gap: 2px; margin-bottom: 10px; }
.h2-level-head span { font-size: 13px; color: var(--mute); }
.h2-level ul { margin: 0; padding-left: 18px; color: var(--fg); line-height: 1.6; font-size: 14.5px; }
.h2-level.basic { border-top: 4px solid var(--teal); }
.h2-level.adv { border-top: 4px solid var(--acc); }
.h2-note { color: var(--mute); font-size: 14.5px; margin-top: 18px; max-width: 760px; line-height: 1.55; }

/* Developers */
.h2-dev { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 16px; align-items: start; }
@media (max-width: 820px) { .h2-dev { grid-template-columns: 1fr; } }
.h2-code { background: var(--film); border: 1px solid #2e2620; border-radius: var(--radius); overflow: hidden; }
.h2-tabs { display: flex; gap: 4px; padding: 8px; border-bottom: 1px solid #2e2620; }
.h2-tabs button { background: transparent; color: #b9ab97; border-radius: 8px; padding: 6px 12px; font-weight: 500; }
.h2-tabs button[aria-selected="true"] { background: #2c2520; color: var(--film-fg); }
.h2-tabs .h2-copy { margin-left: auto; color: #e7b347; }
.h2-code pre { margin: 0; padding: 16px; color: var(--film-fg); background: transparent; border: 0; overflow-x: auto; white-space: pre; word-break: normal; font-size: 13px; line-height: 1.6; }
.h2-tools { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; }
.h2-tools ul { padding-left: 18px; line-height: 1.7; font-size: 14.5px; }
.h2-tools .note { color: var(--mute); font-size: 13.5px; }

/* Credit packs (filled from the API) */
.h2-packs { margin-top: 28px; }
.h2-packs h3 { font-size: 22px; margin: 0 0 12px; }
.h2-pack { display: flex; flex-direction: column; gap: 4px; }
.h2-pack.best { border-color: var(--acc); box-shadow: 0 0 0 1px var(--acc) inset; }
.h2-pack .h2-amount { margin-top: 2px; }
.h2-pack .h2-best { align-self: flex-start; font-size: 11.5px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: var(--acc); }
.h2-pack .btn { margin-top: 10px; text-align: center; }

/* Tips, pricing, questions, end */
.h2-tips ul { columns: 2 280px; gap: 28px; padding-left: 18px; line-height: 1.7; color: var(--mute); }
.h2-price .h2-amount { margin-top: 14px; font-size: 15px; color: var(--mute); }
.h2-price .h2-amount strong, .h2-price .h2-amount b { display: inline; font-size: 30px; color: var(--fg); margin-right: 4px; font-family: var(--display); font-weight: 600; }
.h2-faq details { border-bottom: 1px solid var(--line); padding: 14px 0; max-width: 760px; }
.h2-faq summary { cursor: pointer; font-weight: 600; }
.h2-faq details p { color: var(--mute); margin: 8px 0 0; line-height: 1.55; }
.h2-end { text-align: center; padding: 80px 16px; }
.h2-end h2 { font-size: clamp(32px, 5vw, 52px); margin: 0 0 8px; }
.h2-end p { color: var(--mute); margin: 0 0 22px; }
.h2-foot { border-top: 1px solid var(--line); padding: 24px clamp(16px, 4vw, 40px) 40px; color: var(--faint); font-size: 13px; }
.h2-foot p { max-width: 1080px; margin: 6px auto; }

/* Sign-up box */
.h2-modal { position: fixed; inset: 0; z-index: 50; display: grid; place-items: center; background: rgba(28, 24, 20, .55); padding: 16px; }
.h2-modal[hidden] { display: none; }
.h2-modal-card { background: var(--panel); border: 1px solid var(--line2); border-radius: 18px; padding: 24px; max-width: 420px; width: 100%; box-shadow: var(--shadow); }
.h2-modal-card h3 { margin: 0 0 8px; font-size: 24px; }
.h2-modal-card p { color: var(--mute); line-height: 1.5; margin: 0 0 18px; }
.h2-modal-row { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.h2-modal-x { margin-top: 14px; background: transparent; color: var(--faint); padding: 4px 0; font-weight: 500; }

/* Gentle motion, all of it off for people who ask for less */
@media (prefers-reduced-motion: no-preference) {
  .h2-hero h1 b { animation: h2-sway 5s ease-in-out 1.2s infinite; background-size: 0% .22em; transition: background-size .9s ease .3s; }
  .h2-ready .h2-hero h1 b { background-size: 100% .22em; }
  .h2-reel-track { animation: h2-roll 70s linear infinite; }
  .h2-reel:hover .h2-reel-track { animation-play-state: paused; }
  .h2-fade { opacity: 0; transform: translateY(14px); transition: opacity .7s ease, transform .7s ease; }
  .h2-fade.in { opacity: 1; transform: none; }
}
@keyframes h2-sway { 0%, 100% { transform: rotate(0) translateY(0); } 50% { transform: rotate(-2deg) translateY(-2px); } }
@keyframes h2-roll { from { transform: translateX(0); } to { transform: translateX(-50%); } }
