/* Homepage triptych. Product footage owns the image; copy sits on opaque surfaces. */
.studio-splash { padding: 0 var(--page-inset); border-bottom: 1px solid #30303b; }
.studio-splash .topbar { padding: 1.4rem 0 1rem; align-items: center; }
.studio-splash .social-links { gap: 1.1rem; }
.studio-splash .social-links a { display: flex; gap: .4rem; align-items: center; color: var(--text); text-decoration: none; font-size: .8rem; font-weight: 700; min-height: 44px; }
.studio-splash .social-links svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.7; }
.studio-splash .social-links a:hover { color: var(--cyan); }
.splash-intro { display: flex; align-items: end; justify-content: space-between; gap: 2rem; padding: 1.2rem 0 1.65rem; }
.splash-kicker { color: var(--cyan); font-size: .7rem; letter-spacing: .2em; font-weight: 900; margin-bottom: .6rem; }
.splash-intro h1 { font-size: clamp(1.8rem, 3.2vw, 3.6rem); line-height: 1.12; font-weight: 900; letter-spacing: -.04em; }
.splash-intro h1 em { color: var(--accent); font-style: normal; }
.splash-intro > p { color: var(--text-muted); font-size: .9rem; line-height: 1.5; flex: 0 0 auto; }
.showcase-triptych { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 1.1rem; }
.showcase-panel { min-width: 0; background: var(--bg2); border: 1px solid #32323f; border-radius: 5px; overflow: visible; position: relative; transition: border-color .35s, box-shadow .35s; }
.showcase-panel.is-playing { border-color: var(--cyan); box-shadow: 0 0 24px #4ecdc416; }
.showcase-panel:nth-child(2).is-playing { border-color: var(--accent); box-shadow: 0 0 24px #d2b06a20; }
.showcase-panel:nth-child(3).is-playing { border-color: #dba8f5; box-shadow: 0 0 24px #c44dff20; }
.showcase-screen { display: block; position: relative; width: 100%; height: clamp(15rem, 35svh, 30rem); overflow: hidden; border: 0; border-radius: 4px 4px 0 0; background: #050510; color: var(--text); cursor: pointer; padding: 0; }
.showcase-screen > img, .showcase-screen > video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: opacity .7s; }
.showcase-screen .showcase-pure, .showcase-screen .showcase-ui { opacity: 0; pointer-events: none; }
.showcase-screen .showcase-ui { object-fit: contain; background: #050510; }
.is-playing .showcase-pure.ready { opacity: 1; }
.is-ui .showcase-ui.ready { opacity: 1; }
.is-ui .showcase-pure { opacity: 0; }
.screen-control { position: absolute; z-index: 2; bottom: .75rem; left: .75rem; display: inline-flex; align-items: center; gap: .4rem; background: #050510; color: var(--text); border: 1px solid #686876; border-radius: 2rem; padding: .35rem .7rem; font: 700 .7rem var(--font); }
.play-icon { width: 14px; height: 14px; fill: currentColor; }
.screen-caption { position: absolute; top: .75rem; left: .75rem; opacity: 0; background: #050510; color: var(--text); padding: .25rem .5rem; border-radius: 3px; font: 700 .65rem var(--font); pointer-events: none; }
.is-ui .screen-caption { opacity: 1; }
.showcase-info { padding: .85rem 1.05rem 1.1rem; }
.showcase-heading { display: flex; align-items: center; justify-content: space-between; gap: .4rem; }
.showcase-heading h2 { font-size: 1.7rem; letter-spacing: -.035em; line-height: 1.2; }
.showcase-heading h2 a { color: var(--text); text-decoration: none; }
.showcase-heading h2 a:hover { color: var(--cyan); }
.showcase-info > p { color: #bebed0; font-size: .9rem; margin: .1rem 0 1rem; }
.essay-glyph { position: relative; display: grid; place-items: center; flex: 0 0 44px; width: 44px; height: 44px; color: var(--text-muted); border-radius: 50%; }
.essay-glyph:hover, .essay-glyph:focus-visible { color: var(--cyan); background: #151526; }
.essay-glyph svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.5; }
.essay-glyph::after { content: attr(data-tooltip); position: absolute; right: 0; bottom: 100%; white-space: nowrap; background: #050510; color: var(--text); padding: .5rem .7rem; border: 1px solid #686876; border-radius: 4px; font-size: .75rem; opacity: 0; pointer-events: none; z-index: 4; }
.essay-glyph:hover::after, .essay-glyph:focus-visible::after { opacity: 1; }
.install-row { display: flex; align-items: center; gap: .85rem; }
.install-button { display: inline-flex; align-items: center; gap: .6rem; padding: .45rem .85rem; border: 1px solid #e8e8f0; border-radius: 7px; background: #e8e8f0; color: #050510; text-decoration: none; white-space: nowrap; font: 700 1.13rem/1.05 -apple-system, BlinkMacSystemFont, sans-serif; min-height: 49px; }
.install-button:hover { background: var(--cyan); border-color: var(--cyan); }
.install-button svg { width: 23px; height: 27px; }
.install-button small { display: block; font-size: .58rem; line-height: 1.3; font-weight: 500; }
.install-platforms { color: #bebed0; font-size: .67rem; line-height: 1.5; max-width: 9rem; }
.splash-footer { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: 1.05rem 0 1.1rem; color: var(--text-muted); font-size: .85rem; }
.splash-footer a { color: var(--text); text-underline-offset: 4px; text-decoration-color: #686876; }
.splash-footer a:hover { color: var(--cyan); }
a:focus-visible, button:focus-visible { outline: 3px solid var(--cyan); outline-offset: 4px; }
.showcase-screen:focus-visible { outline-offset: -4px; }
.card-links .view-primary { order: -1; color: var(--text); border-color: var(--cyan); }
.filter-btn.active[data-filter="science"], .filter-btn.active[data-filter="code"] { color: var(--cyan); border-color: var(--cyan); background: #102120; }
.product-card[hidden] { display: none !important; }
@media (max-width: 1100px) { .splash-intro { align-items: start; } .splash-intro h1 em { display: block; } .install-row { flex-wrap: wrap; gap: .4rem; } .install-platforms { max-width: none; } }
@media (max-width: 700px) {
  .studio-splash .topbar { padding: 1rem 0 .4rem; gap: .5rem; }
  .studio-splash .social-links { gap: .4rem; }
  .studio-splash .social-links a { width: 38px; justify-content: center; }
  .studio-splash .social-links span { display: none; }
  .splash-intro { display: block; padding: 1rem 0 1.4rem; }
  .splash-intro h1 { font-size: 2.1rem; }
  .splash-intro > p { margin-top: .65rem; }
  .splash-intro > p br { display: none; }
  .showcase-triptych { grid-template-columns: 1fr; gap: 1.2rem; }
  .showcase-screen { height: clamp(17rem, 80vw, 25rem); }
  .install-row { flex-wrap: nowrap; gap: 1rem; }
  .splash-footer { align-items: start; }
  .splash-footer p { max-width: 16rem; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .showcase-panel, .showcase-screen > img, .showcase-screen > video { transition: none; }
}

/* A lightly fanned deck. Each card is a stacking context; focus brings it forward. */
.stack { isolation: isolate; overflow: clip; }
.stack .topbar { padding-bottom: .25rem; }
.stack .splash-intro { padding: 1.15rem 0 1.6rem; position: relative; z-index: 2; }
.stack .splash-kicker { font-size: .8rem; margin-bottom: .6rem; }
.stack .splash-intro h1 { font-size: clamp(2.8rem, 5.4vw, 5.5rem); line-height: .98; letter-spacing: -.055em; }
.stack .splash-thesis { color: var(--text); font-size: 1.1rem; font-weight: 700; margin-top: .65rem; }
.stack .showcase-triptych { display: flex; align-items: center; gap: 0; perspective: 1400px; padding: .8rem 0 2.2rem; }
.stack .showcase-panel { flex: 0 0 40%; border-radius: 14px; border-color: #454553; background: #0c0c1a; box-shadow: 0 18px 45px #0009; transform-origin: center; transition: transform .4s ease, border-color .35s, box-shadow .35s; }
.stack .showcase-panel + .showcase-panel { margin-left: -6%; }
.stack [data-app="psychodeli"] { flex-basis: 34%; z-index: 1; transform: translateY(1.1rem) rotateY(7deg) rotateZ(-3deg) scale(.94); }
.stack [data-app="protoplasm"] { z-index: 3; transform: translateY(-.4rem) rotateX(2deg); }
.stack [data-app="spinodal"] { flex-basis: 38%; z-index: 2; transform: translateY(.8rem) rotateY(-7deg) rotateZ(2.5deg); }
.stack .showcase-panel:focus-within { z-index: 5; transform: translateY(-.8rem); box-shadow: 0 24px 55px #000b; }
@media (hover: hover) {
  .stack .showcase-panel:hover { z-index: 6; transform: translateY(-.8rem); box-shadow: 0 24px 55px #000b; }
}
.stack .showcase-screen { height: clamp(18rem, 38svh, 28rem); border-radius: 13px 13px 0 0; }
/* Fill the resting frame with the lamp; the UI footage retains its full controls. */
.stack [data-app="spinodal"] :is(.showcase-poster, .showcase-pure) { object-fit: cover; transform: scale(1.05); object-position: 50% 50%; }
.stack .showcase-info { padding: .8rem clamp(1.25rem, 2.5vw, 3rem) 1.3rem; }
.stack [data-app="spinodal"] .showcase-info { padding-left: calc(6vw + 1rem); }
.stack .showcase-heading { justify-content: start; gap: .4rem; }
.stack .showcase-heading h2 { font-size: clamp(1.5rem, 2.2vw, 2.1rem); }
.stack .showcase-info > p { color: var(--text); font-weight: 700; font-size: .95rem; min-height: 2.8rem; margin-bottom: .65rem; }
.stack .install-row { flex-wrap: wrap; gap: .55rem; }
.stack .install-platforms { color: var(--text); font-size: .75rem; }
.stack .screen-control { opacity: 0; transition: opacity .2s; font-size: .8rem; padding: .45rem .75rem; }
.stack .showcase-screen:focus-visible .screen-control, .stack .showcase-screen:hover .screen-control, .stack .showcase-screen[aria-pressed="true"] .screen-control { opacity: 1; }
.stack .screen-caption { font-size: .8rem; }
.stack .splash-footer { padding: .6rem 0 1.3rem; font-size: 1rem; color: var(--text); }
@media (max-width: 1000px) and (min-width: 761px) {
  .stack .showcase-info { padding: .8rem 1.1rem 1.2rem; }
  .stack .showcase-heading { gap: 0; }
  .stack .showcase-heading h2 { font-size: 1.4rem; }
  .stack .essay-glyph { flex-basis: 36px; width: 36px; }
  .stack .install-platforms { flex-basis: 100%; }
}
@media (max-width: 760px) {
  .stack .splash-intro h1 { font-size: clamp(2.6rem, 10vw, 4rem); }
  .stack .splash-thesis { font-size: 1rem; }
  .stack .showcase-triptych { display: flex; flex-direction: column; padding: .4rem .5rem 1.5rem; }
  .stack .showcase-panel { flex: none; width: 100%; }
  .stack .showcase-panel + .showcase-panel { margin-left: 0; margin-top: -.7rem; }
  .stack [data-app="psychodeli"] { width: 95%; transform: rotate(-2deg); }
  .stack [data-app="protoplasm"] { transform: rotate(1deg); }
  .stack [data-app="spinodal"] { transform: rotate(-1.5deg); }
  .stack .showcase-panel.is-scroll-active { z-index: 4; transform: translateY(-.5rem) scale(1.025); box-shadow: 0 24px 55px #000b; }
  .stack .showcase-panel:focus-within { transform: none; }
  .stack .showcase-screen { height: clamp(17rem, 75vw, 27rem); }
  .stack .showcase-info { padding: .8rem 1.1rem 2rem; }
  .stack [data-app="spinodal"] .showcase-info { padding-left: 1.1rem; }
  .stack .showcase-heading { justify-content: space-between; }
  .stack .showcase-heading h2 { font-size: 1.8rem; }
  .stack .showcase-info > p { min-height: 0; }
  .stack .screen-control { opacity: 1; }
  .stack .splash-footer p { max-width: none; }
}
@media (hover: none) { .stack .screen-control { opacity: 1; } }
@media (prefers-reduced-motion: reduce) { .stack .showcase-panel, .stack .screen-control { transition: none; } }
@media (max-width: 380px) {
  .studio-splash .social-links { gap: 0; }
  .studio-splash .social-links a { width: 40px; }
}

/* Keep the invitation beside the headline and the social corner icon-led. */
.stack .splash-intro { align-items: end; }
.stack .splash-aside { padding-bottom: .15rem; flex: 0 1 auto; }
.stack .splash-aside .splash-thesis { margin-top: 0; }
.stack .splash-aside .splash-footer { padding: .5rem 0 0; font-size: .9rem; }
.stack .social-links { gap: .65rem; padding: .45rem; border: 1px solid #363647; border-radius: 2rem; background: linear-gradient(110deg,#4ecdc414,#d2b06a10,#c44dff14); box-shadow: 0 0 28px #4ecdc40b; }
.stack .social-links a { margin: 0; filter: none; display: grid; place-items: center; width: 44px; height: 44px; min-height: 44px; border-radius: 50%; color: var(--text); background: #131322; transition: background .2s, transform .2s; }
.stack .social-links svg { width: 24px; height: 24px; }
.stack .social-links a:hover { background: #253b3c; transform: translateY(-2px); color: #a7fff5; }
.stack .social-links .social-yt:hover { background: #3c3021; color: #ffdea1; }
.stack .social-links .social-ig:hover { background: #35213e; color: #efc0ff; }
@media (max-width: 1100px) {
  .stack .splash-intro { gap: 1rem; }
  .stack .splash-aside { max-width: 18rem; }
  .stack .splash-aside .splash-thesis { font-size: 1rem; }
}
@media (max-width: 760px) {
  .stack .splash-intro { display: block; }
  .stack .splash-aside { max-width: none; margin-top: 1rem; }
  .stack .topbar { flex-wrap: wrap; }
  .stack .social-links { gap: 0; padding: .2rem; margin-left: auto; }
  .stack .social-links a { width: 44px; }
}
@media (max-width: 380px) {
  .stack .topbar { flex-wrap: wrap; }
  .stack .social-links { margin-left: auto; }
}
@media (prefers-reduced-motion: reduce) { .stack .social-links a { transition: none; } }

.stack .screen-control { display: grid; place-items: center; width: 44px; height: 44px; padding: 0; }
.stack .screen-control .play-icon { width: 18px; height: 18px; }
