/* Workflow pages: quiet docs layout in Kira's colours (one type family, pink accent). */
@font-face { font-family: "Brico"; src: url("BricolageGrotesque-Variable.ttf") format("truetype"); font-weight: 200 800; font-stretch: 75% 100%; font-display: swap; }
:root {
  --pink: #E8418A; --pink-soft: #FFE3EF; --bg: #ffffff; --fg: #17141a; --mute: #6d6672; --line: #ece7ee; --card: #f8f5f9;
  --code-bg: #f6f1f4; --code-fg: #2a2530; --shadow: 0 1px 2px rgba(0,0,0,.04);
}
@media (prefers-color-scheme: dark) {
  :root { --pink: #FF6FAE; --pink-soft: #3a1a2a; --bg: #0d0b0e; --fg: #f1edf3; --mute: #a39ba8; --line: #26222a; --card: #17141a;
    --code-bg: #1c191f; --code-fg: #efeaf2; --shadow: none; }
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 64px; }
body { margin: 0; background: var(--bg); color: var(--fg); font: 17px/1.6 "Brico", system-ui, sans-serif; font-variation-settings: "opsz" 14; }
a { color: var(--pink); }
main, .top, footer { max-width: 760px; margin: 0 auto; padding: 0 20px; }
.top { display: flex; justify-content: space-between; align-items: center; height: 56px; font-size: 15px; font-weight: 600; }
.brand { color: var(--fg); text-decoration: none; } .brand span { color: var(--pink); }
.top .kw { font-size: 13px; padding: 4px 10px; border-radius: 999px; background: var(--pink-soft); color: var(--pink); }

.hero { padding: 28px 0 8px; }
.eyebrow { margin: 0 0 8px; font-size: 13px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--pink); }
h1 { margin: 0; font-size: clamp(34px, 8vw, 54px); line-height: 1.02; letter-spacing: -.03em; font-weight: 700; font-variation-settings: "opsz" 96; }
.lede { margin: 14px 0 22px; font-size: 19px; color: var(--mute); }
h2 { margin: 0 0 18px; font-size: 28px; letter-spacing: -.02em; line-height: 1.15; font-variation-settings: "opsz" 72; }
h3 { margin: 0 0 6px; font-size: 19px; letter-spacing: -.01em; line-height: 1.3; }
p { margin: 0 0 14px; }
code { font: .9em ui-monospace, SFMono-Regular, Menlo, monospace; background: var(--code-bg); padding: 1px 5px; border-radius: 5px; }
section { padding: 36px 0 12px; border-top: 1px solid var(--line); }

/* before/after slider (range input drives --pos; works with touch) */
.ba { position: relative; aspect-ratio: 4 / 5; max-height: 72vh; margin: 0 auto 22px; border-radius: 22px; overflow: hidden; background: var(--card); touch-action: pan-y; }
.ba img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; }
.ba-before { position: absolute; inset: 0; clip-path: inset(0 calc(100% - var(--pos)) 0 0); }
.ba-handle { position: absolute; top: 0; bottom: 0; left: var(--pos); width: 3px; margin-left: -1.5px; background: #fff; box-shadow: 0 0 0 1px rgba(0,0,0,.08); pointer-events: none; }
.ba-handle::after { content: "↔"; position: absolute; top: 50%; left: 50%; width: 44px; height: 44px; margin: -22px 0 0 -22px; border-radius: 50%;
  background: #fff; color: #17141a; display: grid; place-items: center; font-size: 20px; box-shadow: 0 4px 14px rgba(0,0,0,.2); }
.ba-range { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; cursor: ew-resize; }
.ba-tag { position: absolute; top: 14px; padding: 4px 10px; border-radius: 999px; font-size: 13px; font-weight: 700; background: rgba(0,0,0,.55); color: #fff; pointer-events: none; }
.ba-tag.l { left: 14px; } .ba-tag.r { right: 14px; background: var(--pink); }

/* section links */
.toc { position: sticky; top: 0; z-index: 5; display: flex; gap: 6px; overflow-x: auto; padding: 10px 0; margin: 8px 0 0; background: var(--bg);
  scrollbar-width: none; border-bottom: 1px solid var(--line); }
.toc::-webkit-scrollbar { display: none; }
.toc a { flex: none; padding: 6px 12px; border-radius: 999px; font-size: 14px; font-weight: 600; color: var(--fg); text-decoration: none; background: var(--card); }
.toc a:hover { color: var(--pink); }

/* steps */
.steps { list-style: none; margin: 0; padding: 0; }
.step { display: grid; grid-template-columns: 36px 1fr; gap: 14px; padding-bottom: 26px; }
.step-n { width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; background: var(--pink); color: #fff; font-weight: 700; font-size: 15px; }
.step-b { min-width: 0; }
.shot { margin: 12px 0 0; }
.zoom { display: block; width: 100%; padding: 0; border: 0; background: none; cursor: zoom-in; }
.shot img { display: block; width: 100%; height: auto; border-radius: 14px; border: 1px solid var(--line); box-shadow: var(--shadow); }

/* prompts */
.prompt { margin: 0 0 16px; border-radius: 16px; background: var(--code-bg); overflow: hidden; }
.prompt-h { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 14px 0 18px; }
.prompt h3 { margin: 0; font-size: 16px; }
.prompt pre { margin: 0; padding: 10px 18px 18px; white-space: pre-wrap; word-break: break-word; color: var(--code-fg);
  font: 14.5px/1.55 ui-monospace, SFMono-Regular, Menlo, monospace; }
.prompt mark { background: var(--pink-soft); color: var(--pink); border-radius: 4px; padding: 0 2px; font-weight: 700; }
.copy { flex: none; padding: 7px 14px; border-radius: 999px; border: 0; background: var(--pink); color: #fff; font: 600 14px "Brico", sans-serif; cursor: pointer; }
.copy.done { background: #2f9e6b; }

/* example gallery: before big, 4 afters */
.gallery { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 16px; }
.gallery figure { margin: 0; }
.gallery .g-before { grid-column: span 2; }
.gallery img { display: block; width: 100%; height: auto; aspect-ratio: 4 / 5; object-fit: cover; border-radius: 14px; }
.gallery .g-before img { aspect-ratio: 16 / 11; }
.gallery figcaption { margin-top: 6px; font-size: 14px; color: var(--mute); }
@media (min-width: 720px) {
  .gallery { grid-template-columns: 1.3fr 1fr 1fr; }
  .gallery .g-before { grid-column: auto; grid-row: span 2; }
  .gallery .g-before img { aspect-ratio: auto; height: calc(100% - 28px); }
}

ul { padding-left: 20px; margin: 0 0 14px; } li { margin-bottom: 8px; }
details { border-bottom: 1px solid var(--line); padding: 12px 0; }
details summary { cursor: pointer; font-weight: 700; list-style: none; display: flex; justify-content: space-between; gap: 12px; }
details summary::after { content: "+"; color: var(--pink); font-weight: 700; }
details[open] summary::after { content: "–"; }
details p { margin: 8px 0 0; color: var(--mute); }

footer { padding: 36px 20px 48px; font-size: 14px; color: var(--mute); border-top: 1px solid var(--line); margin-top: 24px; }
footer span { font-size: 13px; }

.lightbox { padding: 0; border: 0; max-width: 100vw; max-height: 100vh; width: 100vw; height: 100vh; background: rgba(0,0,0,.92); }
.lightbox::backdrop { background: rgba(0,0,0,.6); }
.lightbox img { width: 100%; height: 100%; object-fit: contain; }
.lightbox .close { position: fixed; top: 12px; right: 12px; width: 44px; height: 44px; border-radius: 50%; border: 0; background: #fff; color: #000; font-size: 26px; cursor: pointer; }
