/* AppStudio7 home: "the 7 machine", aurora palette */
@font-face { font-family: "Onest"; font-weight: 100 900; src: url("fonts/onest.woff2") format("woff2"); font-display: swap; }

:root {
  --bg: #04060a; --ink: #eef4f6; --ink2: #b6c2c8; --mute: #87969e;
  --l1: #3ddc97; --l1-rgb: 61 220 151; --l2: #b46bff; --l2-rgb: 180 107 255;
  --on-l1: #04120c; --pale: #e6fff3; --rim-rgb: 240 250 255;
  --k0: #ffb020; --k1: #3ddc97; --k2: #4da3ff; --k3: #b46bff;   /* games, apps, web apps, AI tools */
  --hdr: 64px;
  --gut: clamp(16px, 4.4vw, 64px);
  --sans: "Onest", system-ui, sans-serif;
  --mono: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  --ease: cubic-bezier(.2,.8,.16,1);
}
/* each kind of work carries its colour */
.k0, .mod:nth-child(1), .wires g[data-m="0"] { --kc: var(--k0); }
.k1, .mod:nth-child(2), .wires g[data-m="1"] { --kc: var(--k1); }
.k2, .mod:nth-child(3), .wires g[data-m="2"] { --kc: var(--k2); }
.k3, .mod:nth-child(4), .wires g[data-m="3"] { --kc: var(--k3); }
.part {
  --g0: color-mix(in srgb, var(--kc) 30%, #fff); --g1: color-mix(in srgb, var(--kc) 70%, #fff); --g2: var(--kc);
  --g3: color-mix(in srgb, var(--kc) 70%, #0a1030); --g4: color-mix(in srgb, var(--kc) 42%, #0a0616);
  --s1: var(--kc); --s0: color-mix(in srgb, var(--kc) 22%, #000); --s9: color-mix(in srgb, var(--kc) 12%, #04060a);
  --rim2: var(--kc); --back: color-mix(in srgb, var(--kc) 16%, #04060a);
}

*, *::before, *::after { box-sizing: border-box; }
html { background: var(--bg); -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 400 17px/1.55 var(--sans); -webkit-font-smoothing: antialiased; overflow-x: clip; }
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }
a { color: inherit; }
img { display: block; }
:focus-visible { outline: 2px solid var(--l1); outline-offset: 3px; border-radius: 6px; }
.defs { position: absolute; }
.wrap { width: min(100% - 2 * var(--gut), 1312px); margin-inline: auto; }
.ico { width: 1em; height: 1em; flex: none; }
h1, h2, h3 { margin: 0; font-weight: 700; text-wrap: balance; }
h2 { font-size: clamp(38px, 5vw, 72px); line-height: 1; letter-spacing: -.04em; }
.tag { font: 500 15px/1.2 var(--sans); color: var(--ink2); }
section[id] { scroll-margin-top: var(--hdr); }

/* svg paint that used to be inline */
.stop-l1 { stop-color: var(--l1); }
.mk-bg { fill: var(--l1); }
.mk-7 { fill: var(--on-l1); }
.sg0 { stop-color: var(--g0); } .sg1 { stop-color: var(--g1); } .sg2 { stop-color: var(--g2); }
.sg3 { stop-color: var(--g3); } .sg4 { stop-color: var(--g4); }
.sgw { stop-color: #fff; } .sgr { stop-color: var(--rim2); }

/* ---------- header ---------- */
.top { position: fixed; inset: 0 0 auto 0; z-index: 50; height: var(--hdr); background: color-mix(in srgb, var(--bg) 74%, transparent); -webkit-backdrop-filter: blur(14px) saturate(1.3); backdrop-filter: blur(14px) saturate(1.3); box-shadow: 0 1px 0 color-mix(in srgb, var(--ink) 7%, transparent); }
.top-in { height: 100%; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.brand { display: inline-flex; align-items: center; gap: 11px; font-weight: 700; font-size: 18px; letter-spacing: -.02em; text-decoration: none; }
.mark { width: 30px; height: 30px; filter: drop-shadow(0 0 12px rgb(var(--l1-rgb) / .45)); }
.top nav { display: flex; gap: 2px; }
.top nav a { padding: 8px 14px; border-radius: 999px; font-size: 15px; color: var(--ink2); text-decoration: none; transition: color .2s, background-color .2s; }
.top nav a:hover { color: var(--ink); background: color-mix(in srgb, var(--ink) 6%, transparent); }

/* ---------- buttons ---------- */
.btn { display: inline-flex; align-items: center; gap: 10px; min-height: 52px; padding: 0 24px; border-radius: 999px; font: 650 16px/1 var(--sans); text-decoration: none; transition: transform .25s var(--ease), box-shadow .3s, background-color .25s; }
.btn .ico { width: 18px; height: 18px; transition: transform .25s var(--ease); }
.btn:hover .ico { transform: translateY(2px); }
.btn:active { transform: scale(.97); }
.btn-main { color: var(--on-l1); background: var(--l1); box-shadow: inset 0 1px 0 rgba(255,255,255,.55), 0 0 0 1px rgb(var(--l1-rgb) / .4), 0 10px 40px -8px rgb(var(--l1-rgb) / .65); }
.btn-main:hover { box-shadow: inset 0 1px 0 rgba(255,255,255,.55), 0 0 0 1px rgb(var(--l1-rgb) / .6), 0 12px 56px -6px rgb(var(--l1-rgb) / .85); }
.btn-ghost { color: var(--ink); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--ink) 22%, transparent); }
.btn-ghost:hover { background: color-mix(in srgb, var(--ink) 6%, transparent); }

/* ---------- the track: first screen + the machine (base = still diagram) ---------- */
.track { position: relative; }
.hero { position: relative; z-index: 3; }
.hero-in { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); align-items: center; gap: 24px; min-height: min(100svh, 900px); padding-top: var(--hdr); }
h1 { font-size: clamp(40px, 5.3vw, 80px); line-height: .98; letter-spacing: -.038em; font-weight: 750; }
h1 span { display: block; white-space: nowrap; background: linear-gradient(180deg, #fff 35%, color-mix(in srgb, var(--l1) 32%, #fff)); -webkit-background-clip: text; background-clip: text; color: transparent; padding-bottom: .05em; }
.lead { margin: 30px 0 0; max-width: 35ch; font-size: clamp(18px, 1.45vw, 21px); line-height: 1.5; color: var(--ink2); }
.acts { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 40px; }
.hero-7 { position: relative; height: 560px; perspective: 1600px; }
.hero-7 .rig { left: 50%; top: 50%; transform: rotateX(9deg) rotateY(-27deg); }
.hero-7 .aura, .hero-7 .pool { left: 50%; top: 50%; }

.stage { position: relative; overflow: clip; isolation: isolate; }
.fx { position: absolute; inset: 0; z-index: -1; pointer-events: none; }
.floor { position: absolute; left: 50%; bottom: -60px; width: 1500px; height: 420px; translate: -50% 0; transform: perspective(520px) rotateX(70deg); transform-origin: 50% 100%;
  background-image: linear-gradient(rgb(var(--l1-rgb) / .3) 1px, transparent 1px), linear-gradient(90deg, rgb(var(--l1-rgb) / .3) 1px, transparent 1px); background-size: 60px 60px; background-position: center bottom;
  -webkit-mask: radial-gradient(50% 90% at 50% 100%, #000 15%, transparent 70%); mask: radial-gradient(50% 90% at 50% 100%, #000 15%, transparent 70%); }
.fx::before { content: ""; position: absolute; inset: 0; background: radial-gradient(60% 45% at 50% 100%, rgb(var(--l2-rgb) / .16), transparent 70%); }

.anchor { position: absolute; left: 0; top: 0; width: 0; height: 0; perspective: 1700px; perspective-origin: 0 0; }
.aura { position: absolute; width: 900px; height: 900px; margin: -450px 0 0 -450px; border-radius: 50%; pointer-events: none;
  background: conic-gradient(from 210deg, rgb(255 176 32 / .3), rgb(61 220 151 / .28), rgb(77 163 255 / .28), rgb(180 107 255 / .32), rgb(255 176 32 / .3));
  -webkit-mask: radial-gradient(closest-side, #000 10%, rgb(0 0 0 / .45) 45%, transparent); mask: radial-gradient(closest-side, #000 10%, rgb(0 0 0 / .45) 45%, transparent); }
.pool { position: absolute; width: 520px; height: 90px; margin: 250px 0 0 -260px; border-radius: 50%; background: radial-gradient(closest-side, rgb(var(--l1-rgb) / .55), rgb(var(--l2-rgb) / .2) 60%, transparent); pointer-events: none; }
.rings { position: absolute; width: 720px; height: 720px; margin: -360px 0 0 -360px; overflow: visible; pointer-events: none;
  -webkit-mask: radial-gradient(closest-side, #000 62%, transparent); mask: radial-gradient(closest-side, #000 62%, transparent); }
.rings circle { fill: none; }
.rings .r-ink7 { stroke: color-mix(in srgb, var(--ink) 7%, transparent); }
.rings .r-ink6 { stroke: color-mix(in srgb, var(--ink) 6%, transparent); }
.rings .r-pale { stroke: var(--pale); }
.rings .r-l2 { stroke: var(--l2); }
.rings .r-dot { fill: var(--pale); }
.spin { transform-origin: 0 0; animation: turn 70s linear infinite; }
.spin.rev { animation-duration: 110s; animation-direction: reverse; }
.spin.s24 { animation-duration: 24s; }
@keyframes turn { to { transform: rotate(360deg); } }

/* the 7, built from four extruded parts (faces made in script) */
.rig { position: absolute; left: 0; top: 0; width: 0; height: 0; transform-style: preserve-3d; }
.sway, .seven, .part { position: absolute; left: 0; top: 0; transform-style: preserve-3d; }
.part { width: 0; height: 0; }
.fc { position: absolute; overflow: visible; opacity: var(--o, 1); }
.fc.back path { fill: var(--back); stroke: rgb(var(--l1-rgb) / .3); stroke-width: .08; }
.fc .rim { fill: none; stroke-width: .13; stroke-linejoin: round; }
.part.on .fc .rim { stroke: #fff; stroke-width: .2; }
.sheen { animation: sheen 7s ease-in-out infinite alternate; }
@keyframes sheen { from { transform: translateX(-12px); } to { transform: translateX(12px); } }
.sd { position: absolute; left: 0; top: 0; transform-origin: 0 0; opacity: calc(var(--o, 1) * .93);
  background: linear-gradient(180deg, rgb(var(--rim-rgb) / calc(.3 + .65 * var(--s))) 0 2px, color-mix(in srgb, var(--s1) calc(var(--s) * 100%), var(--s0)) 3px, color-mix(in srgb, var(--s1) calc(var(--s) * 28%), var(--s9))); }
.part.on .sd { filter: brightness(1.35); }
.inlight { position: absolute; border-radius: 50%; pointer-events: none; background: radial-gradient(closest-side, rgb(var(--rim-rgb) / .95), rgb(var(--l1-rgb) / .6) 35%, transparent); }

.wires { position: absolute; left: 0; top: 0; width: 1px; height: 1px; overflow: visible; pointer-events: none; }
.wires .wl { fill: none; stroke: color-mix(in srgb, var(--kc) 34%, transparent); stroke-width: 1.4; stroke-dasharray: 3 5; }
.wires .ld { fill: none; stroke: color-mix(in srgb, var(--ink) 26%, transparent); stroke-width: 1.2; stroke-dasharray: 2 5; }
.wires .pad { fill: var(--bg); stroke: color-mix(in srgb, var(--kc) 60%, transparent); stroke-width: 1.4; }
.wires .run { stroke-width: 5; --t: 2.4s; }
.wires g.on .wl { stroke: var(--kc); stroke-dasharray: none; filter: drop-shadow(0 0 4px var(--kc)); }
.wires g.on .pad { fill: var(--kc); }
.core { position: absolute; width: 170px; height: 170px; margin: -85px 0 0 -85px; pointer-events: none; }
.core svg { width: 100%; height: 100%; overflow: visible; }
.core circle { fill: none; }
.core .c-out { stroke: rgb(var(--l1-rgb) / .12); }
.core .c-dash { stroke: rgb(var(--l1-rgb) / .6); }
.core .c-disc { fill: color-mix(in srgb, var(--l1) 7%, var(--bg)); stroke: var(--l1); }
.core .c-in { stroke: rgb(var(--l1-rgb) / .22); }
.core .c-7 { fill: var(--l1); }
.hint { position: absolute; z-index: 2; left: 50%; bottom: 26px; translate: -50% 0; margin: 0; display: none; align-items: center; gap: 12px; }
.hint i { width: 1px; height: 34px; background: linear-gradient(var(--l1), transparent); animation: drip 2.2s var(--ease) infinite; transform-origin: top; }
@keyframes drip { 0% { transform: scaleY(0); } 60% { transform: scaleY(1); opacity: 1; } 100% { transform: scaleY(1); opacity: 0; } }

.stage-in { position: relative; z-index: 2; padding-block: clamp(96px, 10vw, 150px); }
.stage-head { display: flex; align-items: end; justify-content: space-between; gap: 16px 48px; flex-wrap: wrap; margin-bottom: clamp(24px, 3vh, 40px); }
.own { margin: 0; max-width: 30ch; font-size: clamp(17px, 1.4vw, 21px); line-height: 1.4; color: var(--ink2); }
.own strong { color: var(--ink); font-weight: 650; }
.mods { position: relative; display: grid; grid-template-columns: minmax(0, 1fr) 170px minmax(0, 1fr); grid-template-rows: auto auto; gap: 22px 0; max-width: 1000px; margin-inline: auto; }
.mod:nth-child(1) { grid-area: 1 / 1; --fx: 170px; --fy: 110px; }
.mod:nth-child(2) { grid-area: 1 / 3; --fx: -170px; --fy: 110px; }
.mod:nth-child(3) { grid-area: 2 / 1; --fx: 170px; --fy: -110px; }
.mod:nth-child(4) { grid-area: 2 / 3; --fx: -170px; --fy: -110px; }
.mod { --m: 1; position: relative; display: flex; flex-direction: column; gap: 8px; min-width: 0; padding: 16px 22px 20px; border-radius: 20px;
  background: linear-gradient(180deg, color-mix(in srgb, var(--ink) 5%, var(--bg)), color-mix(in srgb, var(--ink) 2%, var(--bg)));
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--ink) 13%, transparent), inset 0 1px 0 color-mix(in srgb, var(--ink) 6%, transparent), 0 30px 60px -30px #000;
  opacity: var(--m); transform: translate3d(calc((1 - var(--m)) * var(--fx, 0px)), calc((1 - var(--m)) * var(--fy, 0px)), 0) scale(calc(.7 + .3 * var(--m)));
  transition: box-shadow .45s var(--ease); }
.mod.on { box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--kc) 72%, transparent), inset 0 1px 0 color-mix(in srgb, var(--ink) 10%, transparent), 0 0 70px -14px color-mix(in srgb, var(--kc) 50%, transparent), 0 30px 60px -30px #000; }
.mod-top { display: flex; justify-content: flex-end; }
.mod .led { width: 7px; height: 7px; border-radius: 50%; background: color-mix(in srgb, var(--ink) 25%, transparent); transition: background-color .3s, box-shadow .3s; }
.mod.on .led { background: var(--kc); box-shadow: 0 0 10px 2px color-mix(in srgb, var(--kc) 50%, transparent); }
.mod h3 { font-size: clamp(20px, 1.7vw, 25px); line-height: 1.15; letter-spacing: -.02em; }
.mod p { margin: 0; color: var(--ink2); font-size: 16px; line-height: 1.45; text-wrap: pretty; }
.mod-btn { font: inherit; color: inherit; letter-spacing: inherit; background: none; border: 0; padding: 0; text-align: left; cursor: pointer; }
.mod-btn::after { content: ""; position: absolute; inset: 0; border-radius: 20px; }
.mod-btn:focus-visible { outline: none; }
.mod-btn:focus-visible::after { outline: 2px solid var(--kc); outline-offset: 4px; }

/* schematics: line art in the module's colour; --fs keeps labels at 11px or more on screen (script) */
.sch { display: block; width: 100%; height: 150px; overflow: visible; }
.sch * { transform-box: fill-box; }
.sch text { font: 500 var(--fs, 11px) var(--mono); letter-spacing: .1em; text-transform: uppercase; fill: var(--mute); }
.sch text.k { fill: var(--kc); }
.sch.tight text { display: none; }
.w { fill: none; stroke: color-mix(in srgb, color-mix(in srgb, var(--kc) 30%, var(--ink)) 36%, transparent); stroke-width: 1.3; }
.h { fill: none; stroke: var(--kc); stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.hf { fill: color-mix(in srgb, var(--kc) 9%, var(--bg)); stroke: var(--kc); stroke-width: 1.6; }
.hf.thin { stroke-width: 1; }
.dk { fill: color-mix(in srgb, var(--kc) 5%, var(--bg)); }
.dsh { fill: none; stroke: color-mix(in srgb, color-mix(in srgb, var(--kc) 30%, var(--ink)) 42%, transparent); stroke-width: 1.3; stroke-dasharray: 3 4; }
.lt { fill: var(--kc); opacity: 0; }
.kf { fill: var(--kc); }
.bar { fill: color-mix(in srgb, var(--ink) 42%, transparent); }
.bar.dim { opacity: .6; }
.spark { fill: color-mix(in srgb, var(--kc) 25%, #fff); }
.run { fill: none; stroke: color-mix(in srgb, var(--kc) 22%, #fff); stroke-width: 5.5; stroke-linecap: round; stroke-dasharray: .1 300; animation: run var(--t, 4s) linear infinite; animation-delay: var(--dl, 0s); }
@keyframes run { from { stroke-dashoffset: 0; } to { stroke-dashoffset: -100; } }
@keyframes d0_45 { 0% { stroke-dashoffset: 0; opacity: 1; } 45% { stroke-dashoffset: -100; opacity: 1; } 46%, 100% { stroke-dashoffset: -100; opacity: 0; } }
@keyframes d50_80 { 0%, 49% { stroke-dashoffset: 0; opacity: 0; } 50% { opacity: 1; } 80% { stroke-dashoffset: -100; opacity: 1; } 81%, 100% { stroke-dashoffset: -100; opacity: 0; } }
@keyframes d0_30 { 0% { stroke-dashoffset: 0; opacity: 1; } 30% { stroke-dashoffset: -100; opacity: 1; } 31%, 100% { stroke-dashoffset: -100; opacity: 0; } }
@keyframes d42_70 { 0%, 41% { stroke-dashoffset: 0; opacity: 0; } 42% { opacity: 1; } 70% { stroke-dashoffset: -100; opacity: 1; } 71%, 100% { stroke-dashoffset: -100; opacity: 0; } }
@keyframes d40_66 { 0%, 39% { stroke-dashoffset: 0; opacity: 0; } 40% { opacity: 1; } 66% { stroke-dashoffset: -100; opacity: 1; } 67%, 100% { stroke-dashoffset: -100; opacity: 0; } }
@keyframes l45 { 0%, 44% { opacity: 0; } 48%, 92% { opacity: .5; } 100% { opacity: 0; } }
@keyframes l80 { 0%, 79% { opacity: 0; } 83%, 96% { opacity: .5; } 100% { opacity: 0; } }
@keyframes l30 { 0%, 29% { opacity: 0; } 33% { opacity: .55; } 46%, 100% { opacity: 0; } }
@keyframes l66 { 0%, 64% { opacity: 0; } 70%, 94% { opacity: .5; } 100% { opacity: 0; } }
@keyframes fill70 { 0%, 70% { transform: scaleX(0); } 80%, 97% { transform: scaleX(1); } 100% { transform: scaleX(0); } }
.run.d0_45 { animation: d0_45 5s linear infinite; }
.run.d50_80 { animation: d50_80 5s linear infinite; }
.run.d0_30 { animation: d0_30 5s linear infinite; }
.run.d42_70 { animation: d42_70 5s linear infinite; }
.run.d40_66 { animation: d40_66 5s linear infinite; }
.lt.l45 { animation: l45 5s infinite; }
.lt.l80 { animation: l80 5s infinite; }
.lt.l30 { animation: l30 5s infinite; }
.lt.l66 { animation: l66 5s infinite; }
.fill70 { transform-origin: left; animation: fill70 5s infinite; }
.run.dl12 { animation-delay: .12s; } .run.dl24 { animation-delay: .24s; }
.lt.dl15 { animation-delay: .15s; } .lt.dl30 { animation-delay: .3s; }
@keyframes wob { from { transform: rotate(var(--r0)) translateX(-2px); } to { transform: rotate(var(--r1)) translateX(2px); } }
.wob { transform-origin: center; animation: wob 1.6s ease-in-out infinite alternate; animation-delay: var(--dl, 0s); }
.wb1 { --r0: -7deg; --r1: -3deg; }
.wb2 { --r0: 5deg; --r1: 8deg; --dl: -.5s; }
.wb3 { --r0: -3deg; --r1: -6deg; --dl: -1s; }
.wb4 { --r0: 8deg; --r1: 4deg; --dl: -.3s; }
.wb5 { --r0: -9deg; --r1: -5deg; --dl: -.8s; }
.wb6 { --r0: 3deg; --r1: 6deg; --dl: -1.2s; }

/* games: a level map on a phone; a day is a sun pass and a moon pass, one level fills each day */
.sch .dial { transform-box: view-box; transform-origin: 180px 170px; animation: dial 3s linear infinite; }
@keyframes dial { from { transform: rotate(-90deg); } to { transform: rotate(270deg); } }
.moon { fill: var(--ink2); }
.night { fill: var(--bg); opacity: 0; animation: night 3s ease-in-out infinite; }
@keyframes night { 0%, 46% { opacity: 0; } 56%, 92% { opacity: .55; } 100% { opacity: 0; } }
.road { fill: none; stroke: color-mix(in srgb, var(--kc) 26%, transparent); stroke-width: 3; stroke-linecap: round; }
.trail { fill: none; stroke: var(--kc); stroke-width: 3; stroke-linecap: round; stroke-dasharray: 100 100; stroke-dashoffset: 60; animation: trail 18s step-end infinite; }
@keyframes trail { 0% { stroke-dashoffset: 100; } 20.83% { stroke-dashoffset: 80; } 37.5% { stroke-dashoffset: 60; } 54.17% { stroke-dashoffset: 40; } 70.83% { stroke-dashoffset: 20; } 87.5% { stroke-dashoffset: 0; } 100% { stroke-dashoffset: 100; } }
.lv { --off: color-mix(in srgb, var(--kc) 9%, var(--bg)); fill: var(--off); stroke: var(--kc); stroke-width: 1.5; animation: 18s step-end infinite; }
.lv.n1, .lv.n2, .lv.n3 { fill: var(--kc); }
.lv.n1 { animation-name: lv1; } .lv.n2 { animation-name: lv2; } .lv.n3 { animation-name: lv3; }
.lv.n4 { animation-name: lv4; } .lv.n5 { animation-name: lv5; } .lv.n6 { animation-name: lv6; }
@keyframes lv1 { 0% { fill: var(--off); } 4.17% { fill: var(--kc); } 100% { fill: var(--off); } }
@keyframes lv2 { 0% { fill: var(--off); } 20.83% { fill: var(--kc); } 100% { fill: var(--off); } }
@keyframes lv3 { 0% { fill: var(--off); } 37.5% { fill: var(--kc); } 100% { fill: var(--off); } }
@keyframes lv4 { 0% { fill: var(--off); } 54.17% { fill: var(--kc); } 100% { fill: var(--off); } }
@keyframes lv5 { 0% { fill: var(--off); } 70.83% { fill: var(--kc); } 100% { fill: var(--off); } }
@keyframes lv6 { 0% { fill: var(--off); } 87.5% { fill: var(--kc); } 100% { fill: var(--off); } }

/* ---------- pinned stage (script on, motion allowed) ---------- */
.pinned .track { height: 300svh; }
.pinned .hero { position: absolute; inset: 0 0 auto 0; height: 100svh; pointer-events: none; }
.pinned .hero-in { min-height: 100%; }
.pinned .hero a { pointer-events: auto; }
.pinned .hero-7 .rig, .pinned .hero-7 .aura, .pinned .hero-7 .pool { display: none; }
/* the stage fills the screen even when a phone browser hides its address bar (lvh); its content stays in the part that is always visible (svh) */
.pinned .stage { position: sticky; top: 0; height: 100lvh; }
/* pin.js pins the page before the first paint; until home.js runs ('ran') and places the cards and the 7, the stage stays unseen (in place, so nothing moves) */
.pinned:not(.ran) .stage { visibility: hidden; }
.pinned .stage-in { height: 100svh; display: flex; flex-direction: column; padding-block: calc(var(--hdr) + clamp(16px, 3vh, 32px)) clamp(18px, 3vh, 32px); }
.pinned .stage-head { opacity: var(--hd, 0); transform: translateY(calc((1 - var(--hd, 0)) * 26px)); }
.pinned .mods { flex: 1; min-height: 0; width: 100%; grid-template-rows: minmax(0, 1fr) minmax(0, 1fr); }
.pinned .mods:not(.live) .mod { pointer-events: none; }
.pinned .mod .sch { flex: 1 1 0; height: auto; min-height: 48px; }
.pinned .hint { display: flex; }

/* ---------- sections ---------- */
.sec { position: relative; padding-block: clamp(110px, 12vw, 180px); }
.js .rv { opacity: 0; transform: translateY(26px); transition: opacity .9s var(--ease), transform .9s var(--ease); transition-delay: var(--d, 0s); }
.js .rv.in { opacity: 1; transform: none; }

/* projects */
.projects { overflow: clip; }
.rows { list-style: none; margin: clamp(36px, 4vw, 60px) 0 0; padding: 0; display: grid; gap: 14px; }
.prow { --x: 20%; --y: 50%; --kc: var(--l1); position: relative; display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr) auto; align-items: center; gap: 48px; padding: 20px 40px 20px 20px; border-radius: 26px; isolation: isolate;
  background: radial-gradient(420px circle at var(--x) var(--y), color-mix(in srgb, var(--kc) 8%, transparent), transparent 70%), linear-gradient(90deg, color-mix(in srgb, var(--kc) 6%, transparent), color-mix(in srgb, var(--ink) 1.5%, transparent) 45%);
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--ink) 12%, transparent), inset 0 1px 0 color-mix(in srgb, var(--ink) 5%, transparent); transition: box-shadow .4s; }
.prow:nth-child(1) { --kc: var(--k0); --link: var(--k0); }
.prow:nth-child(2) { --kc: var(--k1); --link: var(--k1); --d: .08s; }
.prow:hover, .prow:focus-within { box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--kc) 50%, transparent), inset 0 1px 0 color-mix(in srgb, var(--ink) 8%, transparent), 0 0 60px -24px color-mix(in srgb, var(--kc) 60%, transparent); }
/* the project's own art, large: the first thing the section shows */
.pshot { display: block; width: 100%; height: auto; aspect-ratio: 1024 / 500; object-fit: cover; border-radius: 16px; }
.prow h3 { font-size: clamp(30px, 3vw, 44px); line-height: 1.05; letter-spacing: -.03em; }
.prow .what p { margin: 12px 0 0; max-width: 34ch; font-size: 18px; line-height: 1.5; color: var(--ink2); }
/* the whole row is the link to the project's site; the store badges sit above it */
.plink { color: inherit; text-decoration: none; }
.plink::after { content: ""; position: absolute; inset: 0; z-index: 1; border-radius: 26px; }
.plink:focus-visible { outline: none; }
.plink:focus-visible::after { outline: 2px solid var(--l1); outline-offset: 3px; }
.pgo { display: grid; place-items: center; width: 52px; height: 52px; border-radius: 50%; color: var(--link, var(--l1)); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--ink) 18%, transparent); transition: background-color .3s, color .3s, box-shadow .3s; }
.pgo .ico { width: 20px; height: 20px; transform: rotate(-45deg); }
.prow:hover .pgo, .prow:has(.plink:focus-visible) .pgo { background: var(--kc); color: var(--bg); box-shadow: none; }
/* the Google Play picture has a clear margin of 41 of its 646px; the negative margin trims it so the black badge is the box */
.stores { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-top: 18px; }
.stores a { position: relative; z-index: 2; display: block; border-radius: 7px; }
.stores img { display: block; width: 180px; height: auto; margin: -11.4px; }
.soon { display: inline-flex; align-items: center; gap: 7px; min-height: 47px; padding: 8px 16px 8px 10px; border-radius: 7px; background: #000; box-shadow: inset 0 0 0 1px #a6a6a6; color: #fff; }
.soon-ico { width: 26px; height: 26px; flex: none; }
.soon b { display: block; font-size: 17px; font-weight: 600; line-height: 1; letter-spacing: -.01em; }
.soon small { display: block; margin-top: 1px; font-size: 11px; font-weight: 500; line-height: 1.1; letter-spacing: .04em; text-transform: uppercase; color: #d4d4d4; }

/* contact */
.contact { text-align: center; overflow: clip; }
.contact .lead { margin: 30px auto 0; max-width: 44ch; text-wrap: balance; }
/* the address is the core; the four kinds of work run in to it as wires */
.board { position: relative; height: 260px; margin-top: clamp(40px, 4vw, 56px); }
.cwires { position: absolute; left: 50%; top: 0; height: 100%; translate: -50% 0; overflow: visible; pointer-events: none; }
.cwires.wide-only { width: 1200px; }
.cwires.phone-only { display: none; width: 360px; }
.cwires .wl { fill: none; stroke: color-mix(in srgb, var(--kc) 65%, transparent); stroke-width: 1.4; stroke-dasharray: 3 5; }
.cwires .pad { fill: var(--kc); }
.cwires .run { --t: 3.2s; stroke-width: 5; }
.cwires .r1 { --dl: -.8s; } .cwires .r2 { --dl: -1.6s; } .cwires .r3 { --dl: -2.4s; }
.mail { position: absolute; left: 50%; top: 50%; translate: -50% -50%; display: grid; place-items: center; width: 560px; max-width: calc(100% - 32px); height: 96px; padding: 12px 28px; border-radius: 999px;
  font-size: clamp(22px, 3vw, 38px); font-weight: 700; letter-spacing: -.03em; color: #fff; text-decoration: none; white-space: nowrap;
  background: radial-gradient(120% 140% at 50% 0%, rgb(var(--l1-rgb) / .14), transparent 60%), color-mix(in srgb, var(--ink) 4%, var(--bg));
  box-shadow: inset 0 0 0 1.5px rgb(var(--l1-rgb) / .7), 0 0 0 8px rgb(var(--l1-rgb) / .06), 0 0 70px -10px rgb(var(--l1-rgb) / .5); transition: box-shadow .35s; }
.mail:hover { box-shadow: inset 0 0 0 1.5px var(--l1), 0 0 0 8px rgb(var(--l1-rgb) / .1), 0 0 90px -6px rgb(var(--l1-rgb) / .7); }

/* footer */
.foot { overflow: clip; padding-top: 36px; }
.foot-row { display: flex; align-items: center; justify-content: space-between; gap: 16px 28px; flex-wrap: wrap; padding-bottom: 28px; font-size: 15px; color: var(--mute); }
.foot-row ul { display: flex; flex-wrap: wrap; gap: 8px 28px; list-style: none; margin: 0; padding: 0; }
.foot-row a { color: var(--ink2); text-decoration: none; }
.foot-row a:hover { color: var(--ink); }
.foot-row .brand { color: var(--ink); font-size: 16px; }
.foot-row .mark { width: 26px; height: 26px; }
/* the giant name in the footer: a white line drawing, its 7 in studio green, green lights travelling the outline */
.giant { display: block; width: 100%; height: auto; margin-top: 8px; user-select: none; -webkit-mask: linear-gradient(#000 35%, transparent 98%); mask: linear-gradient(#000 35%, transparent 98%); }
.giant text { font: 800 200px/1 var(--sans); letter-spacing: -11px; fill: none; }
.giant .off { stroke: none; }
/* the line keeps its screen width at any size, so the name still reads on a phone */
.giant .name, .giant .seven { vector-effect: non-scaling-stroke; }
.giant .name { stroke: color-mix(in srgb, var(--ink) 50%, transparent); stroke-width: 1.4px; }
.giant .seven { stroke: var(--l1); stroke-width: 2.2px; filter: drop-shadow(0 0 4px rgb(var(--l1-rgb) / .8)) drop-shadow(0 0 14px rgb(var(--l1-rgb) / .5)); }
.giant .trace { display: none; }
@media (prefers-reduced-motion: no-preference) {
  .giant .trace { display: inline; stroke: var(--l1); stroke-width: 2.2; stroke-dasharray: 60 2400; filter: drop-shadow(0 0 6px var(--l1)); animation: trace 9s linear infinite; }
}
@keyframes trace { to { stroke-dashoffset: -2460; } }

/* ---------- phone ---------- */
@media (max-width: 759px) {
  .hero-in { grid-template-columns: 1fr; align-content: start; gap: 0; padding-top: calc(var(--hdr) + 28px); }
  h1 { font-size: 10vw; }
  .lead { margin-top: 20px; font-size: 17px; }
  .acts { margin-top: 26px; }
  .btn { min-height: 48px; padding: 0 20px; font-size: 15px; }
  .hero-7 { height: 330px; }
  .aura { width: 560px; height: 560px; margin: -280px 0 0 -280px; }
  .pool { width: 300px; height: 60px; margin: 130px 0 0 -150px; }
  .rings { width: 440px; height: 440px; margin: -220px 0 0 -220px; }
  .floor { width: 900px; height: 260px; }
  .stage-head { flex-direction: column; align-items: start; gap: 8px; margin-bottom: 16px; }
  .own { font-size: 15px; }
  .mods { grid-template-columns: 1fr 1fr; gap: 10px; }
  .mod:nth-child(2) { grid-area: 1 / 2; } .mod:nth-child(4) { grid-area: 2 / 2; }
  .mod { padding: 12px 12px 14px; border-radius: 16px; gap: 6px; }
  .mod-btn::after { border-radius: 16px; }
  .mod h3 { font-size: 17px; }
  .mod p { font-size: 14px; line-height: 1.3; }
  .sch { flex: none; height: 84px; }
  /* the opened 7's parts land 46px above and 52px below the cards (home.js), so the cards keep that room clear */
  .mods { padding-block: 54px 68px; }
  /* pinned to one screen: the stage starts right under the header and runs to the screen's edge, and the drawings give a little on shorter phones; below 60px the stage is a still diagram instead (home.js) */
  .pinned .stage-in { padding-block: calc(var(--hdr) + 8px) 0; }
  .pinned .stage-head { margin-bottom: 8px; }
  .pinned .mods { grid-template-rows: auto auto; align-content: center; }
  .pinned .mod .sch { flex: none; height: clamp(60px, calc(50svh - 290px), 84px); min-height: 0; }
  .sch text { display: none; }
  .core, .wires { display: none; }
  /* phone: the art across the top, then the name, the line and the store buttons; the arrow beside the name */
  .prow { grid-template-columns: minmax(0, 1fr); gap: 18px; padding: 12px 12px 18px; }
  .what { padding-inline: 6px; }
  .prow h3 { font-size: 28px; }
  .prow .what p { font-size: 16px; }
  .stores { gap: 8px; margin-top: 16px; }
  .pgo { position: absolute; top: 22px; right: 22px; width: 40px; height: 40px; background: var(--bg); }
  .pgo .ico { width: 18px; height: 18px; }
  .board { height: 360px; }
  .cwires.wide-only { display: none; }
  .cwires.phone-only { display: block; }
  .mail { height: 76px; padding: 12px 20px; font-size: 22px; }
  .foot-row { flex-direction: column; align-items: flex-start; }
}
@media (max-width: 420px) {
  .top nav a { padding: 8px 10px; font-size: 14px; }
  .brand { font-size: 16px; gap: 8px; }
  .mark { width: 27px; height: 27px; }
}

/* ---------- reduced motion: the opened machine as a still diagram ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .js .rv { opacity: 1; transform: none; }
}
