/* SuperForge case page: one monochrome workspace. Everything is scoped under .sfo */
.sfo { --ink: #0A0A0A; --sf: #0F0F0F; --pp: #fff; --mono: "Geist Mono", ui-monospace, Menlo, monospace; --g: clamp(16px, 2.4vw, 40px); background: var(--ink); color: var(--pp); overflow: hidden; }
.sfo .sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.sfo button { font: inherit; color: inherit; cursor: pointer; }
.sfo button:focus-visible, .sfo input:focus-visible, .sfo a:focus-visible { outline: 2px solid #fff; outline-offset: 3px; }
.sfo-k { font: 500 12px/1.2 var(--mono); letter-spacing: .04em; text-transform: uppercase; color: rgb(255 255 255 / .55); }

/* hero: the patchwork and the merge slider */
.sfo-hero { padding: calc(var(--hdr, 72px) + 2vh) var(--g) clamp(32px, 5vw, 64px); background: radial-gradient(120% 80% at 50% 0, #1a1a1a 0, var(--ink) 60%); }
.sfo-bar { display: flex; justify-content: space-between; gap: 16px; font: 500 12px/1.2 var(--mono); text-transform: uppercase; color: rgb(255 255 255 / .6); }
.sfo-bar a { color: inherit; }
.sfo-hero-in { display: grid; justify-items: start; gap: 22px; padding: clamp(40px, 7vw, 100px) 0 clamp(28px, 4vw, 56px); }
.sfo-word { margin: 0; width: min(640px, 80vw); } .sfo-word img { display: block; width: 100%; height: auto; }
.sfo-lede { margin: 0; max-width: 34ch; font-size: clamp(22px, 3vw, 44px); line-height: 1.08; letter-spacing: -.03em; font-weight: 500; }
.sfo-merge { display: grid; gap: 18px; }
.sfo-stage { position: relative; height: clamp(420px, 46vw, 640px); border: 1px solid rgb(255 255 255 / .12); border-radius: 14px; background: #0b0b0b; overflow: hidden; }
.sfo-win { position: absolute; left: 22%; right: 2%; top: 8%; bottom: 8%; border: 1px solid rgb(255 255 255 / .18); border-radius: 10px; background: var(--sf); overflow: hidden; opacity: calc(var(--t) * var(--t) * 1.2 - .1); transform: translateY(calc((1 - var(--t)) * 24px)) scale(calc(.94 + var(--t) * .06)); }
.sfo-win-top { display: flex; align-items: center; gap: 6px; height: 28px; padding: 0 12px; border-bottom: 1px solid rgb(255 255 255 / .1); font: 500 11px/1 var(--mono); color: rgb(255 255 255 / .55); }
.sfo-win-top i, .sfo-app-top i { width: 9px; height: 9px; border-radius: 50%; background: rgb(255 255 255 / .22); } .sfo-win-top span { margin: 0 auto; }
.sfo-win img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: left top; }
.sfo-chip { position: absolute; left: calc(var(--sx) * (1 - var(--t)) * 1% + 1.4% * var(--t)); top: calc(var(--sy) * (1 - var(--t)) * 1% + (10 + var(--i) * 13.5) * var(--t) * 1%); transform: rotate(calc(var(--sr) * (1 - var(--t)))); padding: 11px 18px; border-radius: 999px; border: 1px solid rgb(255 255 255 / .35); background: rgb(255 255 255 / calc(.06 + var(--t) * .08)); font-size: clamp(13px, 1.1vw, 16px); font-weight: 500; white-space: nowrap; backdrop-filter: blur(6px); }
.sfo-ctl { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; gap: 10px 24px; align-items: center; }
.sfo-ctl label { grid-column: 1 / -1; display: flex; justify-content: space-between; font: 500 11px/1 var(--mono); text-transform: uppercase; color: rgb(255 255 255 / .6); }
.sfo-ctl input { grid-column: 1; width: 100%; height: 36px; accent-color: #fff; background: transparent; }
.sfo-read { margin: 0; display: grid; gap: 2px; font: 500 12px/1.2 var(--mono); text-transform: uppercase; } .sfo-read span { color: rgb(255 255 255 / .55); }
.sfo-ctl > button { padding: 12px 18px; border-radius: 999px; border: 1px solid #fff; background: #fff; color: #000; font-weight: 600; font-size: 14px; }
.sfo-ctl > button:hover { background: transparent; color: #fff; }

/* facts */
.sfo-facts { display: flex; justify-content: space-between; align-items: end; gap: 20px; flex-wrap: wrap; padding: 22px var(--g); background: #fff; color: #000; }
.sfo-facts > div { display: flex; flex-wrap: wrap; gap: 14px clamp(20px, 3.4vw, 56px); } .sfo-facts div div { display: grid; gap: 6px; }
.sfo-facts span { font: 500 11px/1 var(--mono); text-transform: uppercase; opacity: .55; } .sfo-facts b { font-size: 15px; font-weight: 600; }
.sfo-live { color: #000; font: 500 13px/1 var(--mono); text-transform: uppercase; border-bottom: 1px solid #000; padding-bottom: 4px; }

/* challenge */
.sfo-say { padding: clamp(80px, 12vw, 190px) var(--g); background: #fff; color: #000; }
.sfo-say .sfo-k { color: rgb(0 0 0 / .5); }
.sfo-big { margin: 22px 0 0; max-width: 24em; font-size: clamp(26px, 4.4vw, 72px); line-height: 1; letter-spacing: -.045em; font-weight: 500; }

/* shared section head */
.sfo-head { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 18px clamp(24px, 5vw, 90px); align-items: end; margin-bottom: clamp(32px, 5vw, 70px); }
.sfo-head .sfo-k { grid-column: 1 / -1; }
.sfo-head h2 { margin: 0; font-size: clamp(38px, 6vw, 104px); font-weight: 500; line-height: .92; letter-spacing: -.055em; }
.sfo-head p { margin: 0; max-width: 46ch; font-size: 16px; line-height: 1.55; color: rgb(255 255 255 / .7); }

/* the workspace: a window with a tab rail and a command search */
.sfo-ws { position: relative; padding: clamp(80px, 10vw, 160px) var(--g); }
.sfo-app { border: 1px solid rgb(255 255 255 / .16); border-radius: 14px; background: var(--sf); overflow: hidden; }
.sfo-app-top { display: flex; align-items: center; gap: 7px; height: 44px; padding: 0 16px; border-bottom: 1px solid rgb(255 255 255 / .1); font: 500 12px/1 var(--mono); color: rgb(255 255 255 / .6); }
.sfo-app-top span { margin-left: 10px; }
.sfo-pal-open { margin-left: auto; display: inline-flex; gap: 10px; align-items: center; padding: 8px 12px; border-radius: 8px; border: 1px solid rgb(255 255 255 / .2); background: transparent; font: 500 12px/1 var(--mono); color: rgb(255 255 255 / .75); }
.sfo-pal-open:hover { background: rgb(255 255 255 / .08); } .sfo kbd { font: inherit; padding: 2px 6px; border-radius: 5px; background: rgb(255 255 255 / .12); }
.sfo-app-body { display: grid; grid-template-columns: 220px minmax(0, 1fr); min-height: clamp(380px, 46vw, 680px); }
.sfo-tabs { display: grid; align-content: start; gap: 4px; padding: 14px; border-right: 1px solid rgb(255 255 255 / .1); }
.sfo-tabs button { display: flex; align-items: center; gap: 12px; text-align: left; padding: 11px 12px; border: 0; border-radius: 8px; background: transparent; font-size: 15px; color: rgb(255 255 255 / .65); }
.sfo-tabs button i { font: 500 11px/1 var(--mono); font-style: normal; color: rgb(255 255 255 / .4); }
.sfo-tabs button:hover { background: rgb(255 255 255 / .06); color: #fff; }
.sfo-tabs button[aria-selected="true"] { background: #fff; color: #000; } .sfo-tabs button[aria-selected="true"] i { color: rgb(0 0 0 / .5); }
.sfo-panes { position: relative; background: #070707; }
.sfo-pane { margin: 0; position: absolute; inset: 0; animation: sfo-in .5s cubic-bezier(.2, .8, .2, 1); } .sfo-pane[hidden] { display: none; }
@keyframes sfo-in { from { opacity: 0; transform: scale(1.015); } }
.sfo-pane img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.sfo-pane[data-k="workspace"] img { object-fit: contain; object-position: left top; }
.sfo-pane figcaption { position: absolute; left: 16px; right: 16px; bottom: 14px; padding: 10px 14px; border-radius: 8px; background: rgb(0 0 0 / .72); backdrop-filter: blur(8px); font-size: 14px; line-height: 1.4; max-width: 46ch; }
.sfo-pane figcaption span { display: block; margin-bottom: 4px; font: 500 11px/1 var(--mono); text-transform: uppercase; color: rgb(255 255 255 / .55); }
.sfo-dlg { position: fixed; inset: 0; z-index: 90; display: grid; place-items: start center; padding: 16vh 16px 0; background: rgb(0 0 0 / .6); backdrop-filter: blur(6px); } .sfo-dlg[hidden] { display: none; }
.sfo-dlg-in { width: min(560px, 100%); border: 1px solid rgb(255 255 255 / .22); border-radius: 14px; background: #121212; color: #fff; overflow: hidden; }
.sfo-dlg input { width: 100%; padding: 18px 20px; border: 0; border-bottom: 1px solid rgb(255 255 255 / .12); background: transparent; color: #fff; font-size: 17px; }
.sfo-dlg ul { list-style: none; margin: 0; padding: 8px; max-height: 40vh; overflow: auto; } .sfo-dlg li[hidden] { display: none; }
.sfo-dlg li button { width: 100%; text-align: left; padding: 11px 12px; border: 0; border-radius: 8px; background: transparent; font-size: 15px; }
.sfo-dlg li button:hover, .sfo-dlg li button.on { background: #fff; color: #000; }
.sfo-dlg p { margin: 0; padding: 10px 20px; border-top: 1px solid rgb(255 255 255 / .1); font: 500 11px/1 var(--mono); text-transform: uppercase; color: rgb(255 255 255 / .5); }

/* identity */
.sfo-id { padding: clamp(80px, 10vw, 160px) var(--g); background: #fff; color: #000; }
.sfo-id .sfo-k { color: rgb(0 0 0 / .5); } .sfo-id .sfo-head p { color: rgb(0 0 0 / .65); }
.sfo-id-grid { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); gap: clamp(10px, 1.4vw, 20px); }
.sfo-spec { border-radius: 14px; overflow: hidden; border: 1px solid rgb(0 0 0 / .14); }
.sfo-spec-stage { display: grid; place-items: center; min-height: clamp(280px, 30vw, 440px); background: #0A0A0A; transition: background .4s; }
.sfo-spec-stage img { width: 62%; height: auto; transition: filter .4s; }
.sfo-spec[data-v="paper"] .sfo-spec-stage { background: #fff; } .sfo-spec[data-v="paper"] .sfo-spec-stage img { filter: brightness(0); }
.sfo-spec-ctl { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; padding: 14px 16px; border-top: 1px solid rgb(0 0 0 / .14); background: #fff; }
.sfo-seg { display: inline-flex; border: 1px solid #000; border-radius: 999px; overflow: hidden; } .sfo-seg button { padding: 9px 16px; border: 0; background: transparent; font-size: 14px; color: #000; } .sfo-seg button[aria-pressed="true"] { background: #000; color: #fff; }
.sfo-spec-r { margin: 0; font: 500 12px/1 var(--mono); text-transform: uppercase; } .sfo-spec-r span { margin-left: 8px; padding: 3px 7px; border-radius: 5px; background: #000; color: #fff; }
.sfo-pal { margin: 0; display: grid; gap: 10px; } .sfo-pal ul { list-style: none; margin: 0; padding: 0; display: grid; grid-template-rows: 2fr 1fr 1fr; min-height: 300px; border-radius: 14px; overflow: hidden; border: 1px solid rgb(0 0 0 / .14); }
.sfo-pal li { background: var(--c); color: #fff; display: flex; justify-content: space-between; align-items: end; padding: 14px 16px; font: 500 12px/1 var(--mono); text-transform: uppercase; } .sfo-pal li:last-child { color: #000; }
.sfo-pal figcaption { font: 500 11px/1.4 var(--mono); text-transform: uppercase; color: rgb(0 0 0 / .55); }

/* numbers */
.sfo-out { padding: clamp(80px, 10vw, 160px) var(--g); }
.sfo-st { display: flex; flex-wrap: wrap; gap: 24px 60px; margin: 24px 0; } .sfo-st div { display: grid; gap: 10px; max-width: 30ch; }
.sfo-st b { font-size: clamp(80px, 14vw, 240px); line-height: .8; letter-spacing: -.06em; font-weight: 500; } .sfo-st span { font-size: 15px; line-height: 1.4; color: rgb(255 255 255 / .7); }
.sfo-lede2 { margin: 0; max-width: 56ch; font-size: clamp(18px, 1.8vw, 26px); line-height: 1.35; letter-spacing: -.02em; }

@media (max-width: 899px) {
  .sfo-head { grid-template-columns: 1fr; }
  .sfo-stage { height: 480px; }
  .sfo-win { left: 2%; top: 30%; bottom: 3%; }
  .sfo-chip { padding: 8px 13px; left: calc(var(--sx) * (1 - var(--t)) * .6% + (3 + var(--col) * 32) * var(--t) * 1%); top: calc(var(--sy) * (1 - var(--t)) * .9% + (4 + var(--row) * 9) * var(--t) * 1%); }
  .sfo-app-body { grid-template-columns: 1fr; } .sfo-tabs { grid-auto-flow: column; grid-auto-columns: max-content; overflow-x: auto; border-right: 0; border-bottom: 1px solid rgb(255 255 255 / .1); } .sfo-tabs button { white-space: nowrap; }
  .sfo-panes { min-height: 420px; }
  .sfo-id-grid { grid-template-columns: 1fr; }
  .sfo-ctl { grid-template-columns: 1fr 1fr; } .sfo-ctl input { grid-column: 1 / -1; }
}
@media (prefers-reduced-motion: reduce) { .sfo-pane { animation: none; } .sfo-win, .sfo-chip { transition: none; } }
