/* Liquid Glass: translucent, refracting, specular, springy. Loaded last so it wins. */
:root {
  --glass-bg: rgba(255, 255, 255, 0.07);
  --glass-shadow: 0 14px 44px -14px rgba(0, 0, 0, 0.65), 0 2px 10px rgba(0, 0, 0, 0.25);
  --spring: cubic-bezier(.34, 1.56, .64, 1);
}
[data-theme="light"] {
  --glass-bg: rgba(255, 255, 255, 0.5);
  --glass-shadow: 0 14px 44px -16px rgba(130, 70, 15, 0.45), 0 2px 8px rgba(130, 70, 15, 0.12);
}

/* ambient light behind the whole page: glass needs something to bend */
main::before { content: ""; position: fixed; inset: -10%; z-index: -1; pointer-events: none;
  background:
    radial-gradient(38% 34% at 14% 22%, rgba(255, 122, 26, .26), transparent 70%),
    radial-gradient(34% 30% at 88% 34%, rgba(127, 169, 191, .22), transparent 70%),
    radial-gradient(46% 34% at 52% 104%, rgba(255, 217, 160, .18), transparent 70%);
  animation: ambient 40s ease-in-out infinite alternate; }
@keyframes ambient { to { transform: translate(4%, -3%) scale(1.12) rotate(6deg); } }

/* ---------- the glass material ---------- */
.btn, .tbtn, .panel { position: relative; }
.tbtn { transition: color .15s, background .15s; }
.lg {
  background: var(--glass-bg);
  -webkit-backdrop-filter: blur(18px) saturate(190%) brightness(1.08);
  backdrop-filter: blur(18px) saturate(190%) brightness(1.08);
  border: 0;
  box-shadow: var(--glass-shadow), inset 0 1px 1px rgba(255, 255, 255, .5), inset 0 -1px 1px rgba(255, 255, 255, .1), inset 0 0 24px rgba(255, 255, 255, .05);
}
/* specular rim: a 1px bright edge that is strongest on the top-left and bottom-right */
.lg::before { content: ""; position: absolute; inset: 0; border-radius: inherit; padding: 1.2px; pointer-events: none;
  background: linear-gradient(135deg, rgba(255,255,255,.8), rgba(255,255,255,.08) 38%, rgba(255,255,255,.04) 62%, rgba(255,255,255,.55));
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0); -webkit-mask-composite: xor;
  mask: linear-gradient(#000 0 0) content-box exclude, linear-gradient(#000 0 0); }
/* a highlight that follows the cursor across the surface */
.lg::after { content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none; opacity: 0; transition: opacity .3s;
  background: radial-gradient(150px circle at var(--lx, 50%) var(--ly, 0%), rgba(255,255,255,.3), transparent 65%); }
.lg:hover::after { opacity: 1; }

/* ---------- springy buttons ---------- */
.btn.lg { border-radius: 99px; transition: transform .55s var(--spring), box-shadow .3s; }
.btn.lg:hover { transform: translateY(-2px) scale(1.05); }
.btn.lg:active { transform: scale(.93, 1.07); transition-duration: .12s; }
.btn-primary.lg { background: linear-gradient(135deg, rgba(255, 190, 120, .92), rgba(255, 122, 26, .86)); color: #1a0d04;
  box-shadow: 0 14px 44px -10px rgba(255, 122, 26, .75), inset 0 1px 1px rgba(255,255,255,.8), inset 0 -2px 6px rgba(255, 90, 0, .35); }
.btn-primary.lg:hover { background: linear-gradient(135deg, rgba(255, 205, 150, .95), rgba(255, 138, 46, .9)); }
.ticket .stub .btn.lg { background: rgba(255, 255, 255, .92); color: #1a0d04; }
.cta-box .btn-primary.lg { background: rgba(255, 255, 255, .88); color: #1a0d04; box-shadow: 0 18px 50px -12px rgba(90, 30, 0, .6), inset 0 1px 1px #fff; }

/* ---------- surfaces ---------- */
.rail.lg { padding: 16px 11px; border-radius: 99px; right: 14px; }
.window.lg { border-radius: 28px; overflow: hidden; }
.window.lg .titlebar { background: rgba(255, 255, 255, .04); }
.panel.lg { border-radius: 30px; }
.tag-s { padding: 7px 15px; border-radius: 99px; background: var(--glass-bg); -webkit-backdrop-filter: blur(14px) saturate(180%); backdrop-filter: blur(14px) saturate(180%); box-shadow: inset 0 1px 1px rgba(255,255,255,.4), 0 8px 24px -10px rgba(0,0,0,.5); }
.ticket .main { background: var(--glass-bg); -webkit-backdrop-filter: blur(20px) saturate(180%); backdrop-filter: blur(20px) saturate(180%); }
.card, .feat { background: color-mix(in srgb, var(--bg-2) 52%, transparent); -webkit-backdrop-filter: blur(18px) saturate(160%); backdrop-filter: blur(18px) saturate(160%); }
.chip, .tag { background: var(--glass-bg); }
.gt::after { background: var(--glass-bg); -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px); box-shadow: inset 0 1px 1px rgba(255,255,255,.4); }
details { padding: 0 4px; }

/* ---------- glossy app icons ---------- */
.gi, .tile { position: relative; overflow: hidden; }
.gi::before, .tile::before { content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none; z-index: 2;
  box-shadow: inset 0 0 0 1.2px rgba(255, 255, 255, .5), inset 0 -12px 20px rgba(255, 255, 255, .14), inset 0 10px 18px rgba(255, 255, 255, .1); }
.gi::after, .tile::after { content: ""; position: absolute; left: 7%; right: 7%; top: 3%; height: 46%; border-radius: 50% 50% 55% 55% / 75% 75% 35% 35%; pointer-events: none; z-index: 2;
  background: linear-gradient(180deg, rgba(255, 255, 255, .75), rgba(255, 255, 255, 0)); opacity: .75; }
.gi svg, .tile svg { position: relative; z-index: 1; }

@media (max-width: 960px) { .rail.lg { display: none; } }
@media (prefers-reduced-motion: reduce) { main::before { animation: none; } }

/* ---------- brand text beside the square: "studio" over "nine" ---------- */
.nav .logo { flex-direction: column; justify-content: center; align-items: flex-start; gap: 0; font: 700 18px/0.92 var(--sans); letter-spacing: -0.03em; padding-left: 2px; }
.nav .logo span, .lbar .stk span { display: block; }
.lbar b.stk { display: flex; flex-direction: column; justify-content: center; font: 700 14px/0.95 var(--sans); letter-spacing: -0.02em; margin-left: 10px; }

/* ---------- end of page: giant faded wordmark with the logo square on top ---------- */
footer { padding-bottom: 0; overflow: hidden; }
.mega { position: relative; margin-top: 34px; height: clamp(220px, 30vw, 420px); display: grid; place-items: start center; pointer-events: none; user-select: none; }
.mega-t { display: block; white-space: nowrap; font: 700 clamp(110px, 20.5vw, 330px)/0.9 var(--sans); letter-spacing: -0.055em; color: rgba(247, 239, 227, .09);
  -webkit-mask-image: linear-gradient(180deg, #000 35%, transparent 96%); mask-image: linear-gradient(180deg, #000 35%, transparent 96%); }
.mega-mark { position: absolute; top: 14%; left: 50%; width: clamp(130px, 17vw, 250px); height: auto; translate: -50% 0; opacity: .94;
  filter: drop-shadow(0 30px 60px rgba(255, 122, 26, .45)); animation: megafloat 7s ease-in-out infinite; }
@keyframes megafloat { 50% { transform: translateY(-10px) scale(1.03); } }
[data-theme="light"] .mega-t { color: rgba(26, 18, 11, .07); }
@media (prefers-reduced-motion: reduce) { .mega-mark { animation: none; } }

/* end of page: giant wordmark only, copyright row underneath as the very last line */
.mega { height: clamp(110px, 15.5vw, 250px); margin-top: 28px; }
.legal-end .legal { margin-top: 0; border-top: 1px solid var(--line); padding: 18px 0 26px; }

/* ---------- app artwork: each icon is its own picture, so tiles just frame it ---------- */
img.ic { display: block; width: 100%; height: 100%; object-fit: contain; pointer-events: none; user-select: none; }
.gi:has(img.ic), .tile:has(img.ic), .b9-th:has(img.ic) { background: none !important; padding: 0; border: 0; overflow: visible; }
.gi:has(img.ic)::before, .gi:has(img.ic)::after, .tile:has(img.ic)::before, .tile:has(img.ic)::after { display: none; }
.gi:has(img.ic) { box-shadow: 0 30px 60px -20px var(--c2); border-radius: 22%; }
.tile:has(img.ic) { box-shadow: 0 12px 26px -10px var(--c2); border-radius: 22%; }
.b9-t:has(img.ic) { background: none; box-shadow: 0 18px 40px -14px var(--c2); overflow: visible; }
.b9-t:has(img.ic) .ic { position: absolute; inset: 0; border-radius: 22%; }
.b9-th:has(img.ic) { box-shadow: 0 6px 14px -6px var(--c2); border-radius: 22%; }
