/* BuildWithNik Lab — iridescent poster lab */
:root {
  --ink: #101214; --muted: #596375; --focus: #2a35d8; --accent: #101214;
  --sans: "Inter Tight", "Helvetica Neue", Arial, sans-serif; --mono: "DM Mono", ui-monospace, Menlo, monospace;
  --base: #d4d2de; --g1: #bfeadc; --g2: #f4c4dc; --g3: #aeb0f6; --g4: #9fe8cb; --g5: #f5b9d4; --paper: #ebe9f1;
  --gut: clamp(16px, 2.2vw, 32px); --ease: cubic-bezier(.22, .61, .36, 1);
}
html[data-theme="RED"] { --accent: #e8261c; --base: #e3d4d8; --g1: #ffd9c8; --g2: #ffb4c0; --g3: #ff9ca8; --g4: #ffc29b; --g5: #ff9fbe; }
html[data-theme="GREEN"] { --accent: #169a63; --base: #d3dcd6; --g1: #cdf5d3; --g2: #e9f6b9; --g3: #9be8c4; --g4: #8fe0a8; --g5: #c6f0b0; }
html[data-theme="YELLOW"] { --accent: #b58b00; --base: #e1dccb; --g1: #fff1b8; --g2: #ffd9b0; --g3: #ffe27a; --g4: #ffc98a; --g5: #ffe9a0; }
html[data-theme="BLUE"] { --accent: #2330c8; --base: #d0d4e6; --g1: #bfe3ff; --g2: #d3c4ff; --g3: #8c98ff; --g4: #8fd0ff; --g5: #b5a5ff; }

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body { background: var(--base); color: var(--ink); font: 400 16px/1.5 var(--sans); overflow-x: hidden; transition: background-color .6s; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; text-align: inherit; }
ul, ol { list-style: none; }
img { display: block; max-width: 100%; }
:focus-visible { outline: 2px solid var(--focus); outline-offset: 3px; border-radius: 2px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: fixed; left: 12px; top: -60px; z-index: 100; background: var(--ink); color: #fff; padding: 12px 16px; font: 400 12px var(--mono); transition: top .15s; }
.skip:focus { top: 12px; }
.mono, .label { font: 400 11px/1.5 var(--mono); letter-spacing: .02em; text-transform: uppercase; }

/* ---------- iridescent backdrop ---------- */
.bg { position: fixed; inset: 0; z-index: -1; overflow: hidden; background: var(--base); transition: background-color .6s; }
.bg i { position: absolute; inset: -8%; will-change: transform; animation: drift 26s ease-in-out infinite alternate;
  background:
    radial-gradient(46% 42% at 2% 2%, var(--g1), transparent 72%),
    radial-gradient(42% 40% at 98% 4%, var(--g2), transparent 72%),
    radial-gradient(52% 30% at 12% 106%, var(--g5), transparent 74%),
    radial-gradient(56% 34% at 72% 106%, var(--g4), transparent 74%),
    radial-gradient(70% 38% at 50% 102%, var(--g3), transparent 72%); }
@keyframes drift { from { transform: translate3d(-2.5%, -1.5%, 0) scale(1.04); } to { transform: translate3d(2.5%, 1.5%, 0) scale(1.08); } }

/* ---------- hero ---------- */
.hero { position: relative; height: 100vh; height: 100svh; min-height: 580px; overflow: hidden; font: 400 11px/1 var(--mono); letter-spacing: .02em; text-transform: uppercase; }
#gl { position: absolute; inset: 0; width: 100%; height: 100%; display: block; pointer-events: none; }
.hit { position: absolute; left: 0; right: 0; top: 14%; height: 56%; z-index: 3; touch-action: pan-y; cursor: grab; }
.hit.drag { cursor: grabbing; } .hit.over { cursor: pointer; }
.nav { position: absolute; inset: 0 0 auto 0; height: 70px; z-index: 6; }
.nav .n, .nav .logo { position: absolute; }
.nav .n::after, .hfoot > *::after, .ctl button::after { content: ""; position: absolute; inset: -14px -12px; }
.n1 { left: 31.2%; top: 11px; } .n2 { left: 37.5%; top: 35px; } .n4 { left: 61.5%; top: 35px; } .n5 { left: 66%; top: 11px; }
.n2 button { position: relative; padding: 0; } .n2 button::after { content: ""; position: absolute; inset: -14px -6px; }
.nav .n2::after { display: none; }
.n2 > span { margin: 0 3px; opacity: .6; }
.nav a:hover, .nav button:hover, .hfoot a:hover { color: var(--accent); }
.logo { left: 50%; top: 5px; transform: translateX(-50%); text-align: center; display: flex; flex-direction: column; align-items: center; gap: 3px; font-size: 10px; padding: 2px 10px; }
.logo svg { display: block; } .logo::after { content: ""; position: absolute; inset: -4px -8px -8px; }
.labels { position: absolute; inset: 0; z-index: 4; pointer-events: none; }
.lb { position: absolute; left: 0; top: 0; font: 400 10px/1 var(--mono); white-space: nowrap; will-change: transform; opacity: .85; transition: opacity .2s; }
.lb.hot { opacity: 1; color: var(--accent); }
#cross { position: absolute; left: 50%; top: 77.5%; width: 190px; height: 190px; transform: translate(-50%, -50%); z-index: 2; pointer-events: none; }
.code { position: absolute; left: 20.5%; top: 84.2%; z-index: 4; font: 300 clamp(34px, 3.9vw, 58px)/1 var(--mono); letter-spacing: .01em; text-transform: uppercase; font-variant-numeric: tabular-nums; pointer-events: none; white-space: pre; }
.code .main { position: relative; display: block; min-width: 7ch; }
.code .ghost { position: absolute; left: 0; top: 0; opacity: .32; transform: translate(4px, 1px); filter: blur(.3px); }
.prog { position: absolute; left: 57%; width: 14%; top: 90%; z-index: 4; }
.prog .cnt { position: absolute; right: 0; bottom: 10px; font-size: 10px; }
.prog .line { display: block; height: 1px; background: var(--ink); position: relative; }
.prog .line i { position: absolute; left: 0; top: -4px; width: 1px; height: 9px; background: var(--ink); will-change: transform; }
.ctl { position: absolute; left: 57%; top: 92.5%; z-index: 6; display: flex; align-items: center; margin-left: -10px; }
.ctl button { position: relative; min-width: 28px; height: 28px; padding: 0 8px; text-align: center; font: 400 11px/28px var(--mono); letter-spacing: .02em; }
.ctl button:hover { color: var(--accent); } .ctl button::after { inset: -8px -2px; }
.themes { position: absolute; right: 24px; bottom: 16px; z-index: 6; text-align: right; line-height: 1.5; }
.themes button { position: relative; padding: 0 0 0 18px; text-transform: uppercase; opacity: .7; transition: opacity .15s; }
.themes button::after { content: ""; position: absolute; inset: -2px -12px; }
.themes button:hover { opacity: 1; }
.themes button[aria-pressed="true"] { opacity: 1; }
.themes button[aria-pressed="true"]::before { content: "→"; position: absolute; left: 0; }
.hfoot { position: absolute; left: 0; right: 0; bottom: 0; height: 48px; z-index: 6; }
.hfoot > * { position: absolute; bottom: 12px; display: block; padding: 0; }
.hfoot > a, .hfoot > button { }
.hfoot .snd { left: 22px; font: inherit; text-transform: uppercase; } .snd::before { content: "◖"; margin-right: 8px; }
.hfoot .snd::after { inset: -14px -10px; }
.f1 { left: 29%; } .f2 { left: 50%; transform: translateX(-50%); text-align: center; } .f3 { left: 66%; }
.f2 i { position: absolute; left: 50%; bottom: 16px; font-style: normal; transform: translateX(-50%); font-size: 9px; animation: nudge 1.8s ease-in-out infinite; }
@keyframes nudge { 50% { transform: translate(-50%, 4px); } }

/* ---------- sections ---------- */
.wrap { width: min(1340px, 100% - var(--gut) * 2); margin-inline: auto; }
.sec { position: relative; padding: clamp(72px, 11vw, 168px) 0 clamp(24px, 4vw, 56px); }
.sec-head { max-width: 1100px; margin-bottom: clamp(28px, 4vw, 56px); }
.label { color: var(--ink); margin-bottom: 18px; display: block; }
h2 { font: 500 clamp(40px, 7.4vw, 118px)/.92 var(--sans); letter-spacing: -.05em; text-wrap: balance; }
.lede { margin-top: 22px; max-width: 520px; font-size: 17px; color: #2b303a; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin-bottom: 20px; }
.chips button { font: 400 11px/1 var(--mono); letter-spacing: .02em; padding: 0 14px; min-height: 44px; border: 1px solid rgba(16,18,20,.35); border-radius: 99px; background: rgba(255,255,255,.28); transition: background-color .18s var(--ease), color .18s, border-color .18s; }
.chips button:hover { border-color: var(--ink); }
.chips button[aria-pressed="true"] { background: var(--ink); color: #fff; border-color: var(--ink); }
.chips .count { margin-left: auto; font: 400 11px var(--mono); color: var(--muted); }
.grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.grid li[hidden] { display: none; }
.gcard { display: block; width: 100%; position: relative; }
.gcard .im { position: relative; aspect-ratio: 2/3; border-radius: 10px; overflow: hidden; background: rgba(255,255,255,.3); transition: transform .2s var(--ease), box-shadow .2s var(--ease); }
.gcard img { width: 100%; height: 100%; object-fit: cover; }
.gcard:hover .im, .gcard:focus-visible .im { transform: translateY(-6px); box-shadow: 0 18px 30px -18px rgba(16,18,20,.55); }
.gcard .tg { position: absolute; left: 10px; bottom: 10px; display: flex; gap: 4px; opacity: 0; transform: translateY(6px); transition: opacity .18s var(--ease), transform .18s var(--ease); }
.gcard .tg b { font: 400 9px/1 var(--mono); background: #fff; color: var(--ink); padding: 5px 7px; border-radius: 99px; }
.gcard:hover .tg, .gcard:focus-visible .tg { opacity: 1; transform: none; }
.gcard .cp { display: flex; justify-content: space-between; gap: 10px; padding: 10px 2px 0; font: 400 11px/1.3 var(--mono); text-transform: uppercase; letter-spacing: .02em; }
.gcard .cp span:last-child { color: var(--muted); }

.about { display: grid; grid-template-columns: 1fr 3fr; gap: var(--gut); }
.big { font-size: clamp(32px, 4.6vw, 72px); line-height: 1; letter-spacing: -.045em; max-width: 1000px; }
.cols { display: grid; grid-template-columns: 1fr 1fr; gap: var(--gut); margin-top: clamp(28px, 4vw, 56px); max-width: 880px; font-size: 17px; line-height: 1.5; }
.cols .mono { font-size: 12px; line-height: 1.8; }
.facts { display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--gut); margin-top: clamp(40px, 6vw, 96px); }
.facts div { border-top: 1px solid var(--ink); padding-top: 10px; }
.facts dt { font: 400 11px var(--mono); text-transform: uppercase; letter-spacing: .02em; }
.facts dd { font: 500 clamp(44px, 6vw, 96px)/1 var(--sans); letter-spacing: -.05em; margin-top: 18px; font-variant-numeric: tabular-nums; }
.notes { border-bottom: 1px solid rgba(16,18,20,.35); }
.notes a { display: grid; grid-template-columns: 120px 1fr 150px 32px; align-items: baseline; gap: 16px; padding: 24px 0; border-top: 1px solid rgba(16,18,20,.35); transition: padding-left .2s var(--ease), color .18s, background-color .2s; min-height: 44px; }
.notes a:hover, .notes a:focus-visible { padding-left: 18px; color: var(--accent); background: rgba(255,255,255,.28); }
.notes .d, .notes .g { font: 400 11px var(--mono); text-transform: uppercase; letter-spacing: .02em; }
.notes .t { font: 500 clamp(20px, 2.6vw, 38px)/1.08 var(--sans); letter-spacing: -.03em; }
.notes .a { text-align: right; }
.talk { padding-bottom: 0; }
.mega { font-size: clamp(56px, 17vw, 270px); line-height: .84; letter-spacing: -.065em; margin: 0 0 clamp(28px, 4vw, 56px) -.04em; }
.mega a { display: inline-block; transition: color .2s var(--ease); } .mega a:hover { color: var(--accent); }
.pfoot { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px 24px; padding: 28px 0 28px; margin-top: clamp(56px, 8vw, 120px); border-top: 1px solid rgba(16,18,20,.35); }
.pfoot a { display: inline-block; padding: 12px 0; } .pfoot a:hover { color: var(--accent); }

/* ---------- cookie card ---------- */
.cookie { position: fixed; right: 20px; bottom: 104px; width: min(300px, 100% - 40px); z-index: 30; padding: 18px; border-radius: 16px; background: rgba(247,245,250,.72); backdrop-filter: blur(18px) saturate(1.2); -webkit-backdrop-filter: blur(18px) saturate(1.2); box-shadow: 0 10px 40px -14px rgba(30,30,60,.35); animation: rise .35s var(--ease) both; }
.cookie[hidden] { display: none; }
.cookie h2 { font: 500 18px/1.2 var(--sans); letter-spacing: -.01em; margin-bottom: 8px; }
.cookie p { font: 400 12.5px/1.45 var(--sans); color: var(--muted); margin-bottom: 8px; }
.cookie .link { font: 400 12.5px var(--sans); text-decoration: underline; padding: 8px 0; margin-bottom: 4px; min-height: 36px; }
.ck-opts[hidden] { display: none; }
.ck-opts { display: flex; gap: 16px; font: 400 12px var(--sans); margin: 6px 0 4px; } .ck-opts label { display: flex; gap: 6px; align-items: center; min-height: 32px; }
.ck-btns { display: grid; grid-template-columns: 1.3fr 1fr; gap: 8px; }
.ck-btns button { min-height: 44px; border-radius: 10px; font: 500 13px var(--sans); text-align: center; background: #b9b7c4; color: var(--ink); transition: background-color .15s, color .15s; }
.ck-btns button:hover { background: var(--ink); color: #fff; }
.ck-btns #ck-reject { background: transparent; box-shadow: inset 0 0 0 1px rgba(16,18,20,.4); }
.ck-btns #ck-reject:hover { background: var(--ink); }
@keyframes rise { from { opacity: 0; transform: translateY(14px); } }

/* ---------- dialogs ---------- */
dialog { color: var(--ink); }
dialog::backdrop { background: rgba(16,18,20,.5); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); }
dialog[open] { animation: pop .2s var(--ease) both; }
@keyframes pop { from { opacity: 0; transform: translateY(10px) scale(.985); } }
.detail { border: 0; padding: 0; margin: auto; width: min(1080px, 94vw); max-height: 94vh; overflow: auto; border-radius: 16px; background: var(--paper); }
.d-inner { position: relative; display: grid; grid-template-columns: auto 1fr; gap: clamp(20px, 3.5vw, 56px); padding: clamp(18px, 2.4vw, 32px); align-items: stretch; }
.d-art { height: min(78vh, 760px); aspect-ratio: 2/3; border-radius: 10px; overflow: hidden; background: #ccc; }
.d-art img { width: 100%; height: 100%; object-fit: cover; }
.d-info { display: flex; flex-direction: column; gap: 16px; padding-top: 44px; min-width: 0; }
.d-code { color: var(--muted); }
.d-info h2 { font-size: clamp(44px, 6vw, 88px); line-height: .9; }
.d-note { font-size: 17px; max-width: 440px; color: #2b303a; }
.d-tags { display: flex; gap: 6px; flex-wrap: wrap; } .d-tags li { font: 400 10px/1 var(--mono); border: 1px solid rgba(16,18,20,.4); padding: 7px 10px; border-radius: 99px; }
.d-spec { display: grid; grid-template-columns: 110px 1fr; gap: 8px 12px; font: 400 12px/1.4 var(--mono); border-top: 1px solid rgba(16,18,20,.3); padding-top: 14px; max-width: 440px; text-transform: uppercase; }
.d-spec dt { color: var(--muted); }
.d-nav { margin-top: auto; display: flex; align-items: center; justify-content: space-between; gap: 12px; max-width: 440px; }
.d-nav button, .d-close, .i-head button { min-height: 44px; padding: 0 16px; border-radius: 99px; font: 400 11px var(--mono); letter-spacing: .02em; box-shadow: inset 0 0 0 1px rgba(16,18,20,.4); transition: background-color .18s var(--ease), color .18s; }
.d-nav button:hover, .d-close:hover, .i-head button:hover { background: var(--ink); color: #fff; }
.d-close { position: absolute; right: clamp(18px, 2.4vw, 32px); top: clamp(18px, 2.4vw, 32px); background: var(--paper); }
.indexd { border: 0; margin: 0; padding: 0; width: 100vw; max-width: none; height: 100vh; height: 100dvh; max-height: none; background: rgba(228,226,238,.9); backdrop-filter: blur(22px); -webkit-backdrop-filter: blur(22px); overflow: auto; }
.i-head { position: sticky; top: 0; z-index: 2; display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 12px var(--gut); background: rgba(228,226,238,.85); backdrop-filter: blur(10px); }
.i-head .mono button { box-shadow: none; padding: 0 8px; min-height: 44px; border-radius: 4px; } .i-head .mono button[aria-pressed="true"] { text-decoration: underline; text-underline-offset: 5px; }
.i-body { padding: 0 var(--gut) 40px; }
.i-body.list a { display: grid; grid-template-columns: 70px 150px 1fr 150px 70px; gap: 12px; align-items: baseline; padding: 14px 0; min-height: 44px; border-top: 1px solid rgba(16,18,20,.28); font: 400 11px var(--mono); text-transform: uppercase; transition: padding-left .18s var(--ease), color .18s; }
.i-body.list a:hover, .i-body.list a:focus-visible { padding-left: 14px; color: var(--accent); }
.i-body.list b { font: 500 clamp(22px, 3.2vw, 44px)/1 var(--sans); letter-spacing: -.035em; text-transform: none; }
.i-body.grid { display: grid; grid-template-columns: repeat(6, 1fr); gap: 12px; padding-top: 8px; }
.i-body.grid a { display: block; font: 400 10px var(--mono); text-transform: uppercase; } .i-body.grid img { border-radius: 8px; aspect-ratio: 2/3; width: 100%; object-fit: cover; transition: transform .2s var(--ease); } .i-body.grid a:hover img, .i-body.grid a:focus-visible img { transform: translateY(-4px); }
.i-body.grid span { display: flex; justify-content: space-between; padding-top: 6px; } .i-body.grid b, .i-body.grid .y, .i-body.list .gimg { display: none; } .i-body.list img { display: none; }
.i-body.list .meta-y { text-align: right; }

/* ---------- responsive ---------- */
@media (max-width: 900px) {
  .grid { grid-template-columns: repeat(3, 1fr); } .i-body.grid { grid-template-columns: repeat(4, 1fr); }
  .about { grid-template-columns: 1fr; }
  .n1 { left: 24%; } .n2 { left: 31%; } .n4 { left: 63%; } .n5 { left: 68%; }
}
@media (max-width: 720px) {
  .hero { min-height: 640px; }
  .n1 { left: 16px; top: 13px; } .n5 { left: auto; right: 16px; top: 13px; } .n2 { left: 16px; top: 50px; } .n4 { left: auto; right: 16px; top: 50px; }
  .nav .n::after { inset: -12px -12px; }
  .hit { top: 15%; height: 54%; }
  #cross { top: 71%; width: 140px; height: 140px; }
  .code { left: 16px; top: 78.5%; font-size: 36px; }
  .prog { left: 16px; right: 16px; width: auto; top: 87%; } .prog .cnt { bottom: 8px; }
  .ctl { left: auto; right: 6px; top: 77.2%; margin: 0; } .ctl button { min-width: 44px; height: 44px; line-height: 44px; } .ctl button::after { inset: 0; }
  .themes { left: 16px; right: 16px; bottom: 56px; display: flex; justify-content: space-between; } .themes button { padding: 0; min-height: 44px; display: block; font-size: 10px; } .themes button::after { inset: 0 -4px; } .themes button[aria-pressed="true"]::before { display: none; } .themes button[aria-pressed="true"] { text-decoration: underline; text-underline-offset: 4px; }
  .hfoot .snd { left: 16px; } .f1 { display: none; } .f2 { left: 50%; } .f3 { left: auto; right: 16px; } .f2 i { display: none; }
  .hfoot > *::after { inset: -16px -12px; }
  .cookie { right: 10px; left: 10px; width: auto; bottom: 10px; padding: 14px; } .cookie p { font-size: 12px; margin-bottom: 2px; } .cookie h2 { margin-bottom: 4px; }
  .grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
  .cols { grid-template-columns: 1fr; } .facts { grid-template-columns: repeat(2, 1fr); }
  .notes a { grid-template-columns: 1fr 28px; gap: 4px 12px; } .notes .d { grid-column: 1; } .notes .t { grid-column: 1; } .notes .g { grid-column: 1; grid-row: 3; } .notes .a { grid-column: 2; grid-row: 1 / span 3; align-self: center; }
  .d-inner { grid-template-columns: 1fr; } .d-art { height: auto; width: min(100%, 58vh * .667); margin-inline: auto; } .d-info { padding-top: 0; } .detail { width: 100vw; max-height: 100dvh; border-radius: 0; }
  .d-close { position: sticky; top: 8px; justify-self: end; right: auto; margin-bottom: -8px; z-index: 3; }
  .i-body.list a { grid-template-columns: 56px 1fr 40px; } .i-body.list a .m-name { grid-column: 2; } .i-body.list a .m-tags { display: none; } .i-body.list .m-code { display: none; }
  .i-body.grid { grid-template-columns: repeat(3, 1fr); }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
