/* mygen.co.uk — "workshop at night": warm charcoal, the mascot's plaid red and
   amber for the brand, and every project lit in its own colour (--accent). */

:root {
  --bg: #0f0d0c;
  --bg-2: #141110;
  --surface: #1a1614;
  --surface-2: #221d1a;
  --surface-3: #2b2521;
  --line: rgba(255, 236, 214, 0.08);
  --line-2: rgba(255, 236, 214, 0.15);
  --text: #f6eee6;
  --muted: #b1a497;
  --dim: #7f746a;
  --brand: #ff5a36;
  --brand-2: #ffb547;
  --brand-grad: linear-gradient(100deg, #ff4f36 0%, #ff7a2f 45%, #ffb547 100%);
  --accent: #ff6a3d;
  --radius: 18px;
  --radius-sm: 12px;
  --wrap: 1200px;
  --header-h: 68px;
  --display: 'Bricolage Grotesque', ui-sans-serif, system-ui, sans-serif;
  --sans: 'Geist', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', sans-serif;
  --mono: 'Geist Mono', ui-monospace, 'SFMono-Regular', Consolas, monospace;
  --ease: cubic-bezier(.2, .7, .2, 1);
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 64px); -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 400 16px/1.6 var(--sans);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; padding: 0; }
h1, h2, h3, h4 { font-family: var(--display); line-height: 1.08; letter-spacing: -0.02em; margin: 0; font-weight: 700; }
p { margin: 0; }
::selection { background: color-mix(in srgb, var(--brand) 55%, transparent); }
:focus-visible { outline: 2px solid var(--brand-2); outline-offset: 3px; border-radius: 6px; }

.wrap { width: min(var(--wrap), 100% - 32px); margin-inline: auto; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.mono { font-family: var(--mono); font-size: 0.92em; letter-spacing: -0.01em; }
.center { text-align: center; }
.icon { width: 18px; height: 18px; flex: none; }
.skip { position: absolute; left: -999px; top: 8px; z-index: 100; background: var(--text); color: var(--bg); padding: 8px 14px; border-radius: 8px; }
.skip:focus { left: 8px; }

/* Cursor spotlight + film grain feel */
.spotlight {
  position: fixed; inset: 0; pointer-events: none; z-index: 0;
  background: radial-gradient(600px circle at var(--mx, 70%) var(--my, 10%), rgba(255, 122, 47, 0.07), transparent 60%);
  transition: background 0.2s;
}
main, .site-header, .site-footer { position: relative; z-index: 1; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50; height: var(--header-h);
  background: color-mix(in srgb, var(--bg) 72%, transparent);
  backdrop-filter: blur(14px) saturate(140%);
  -webkit-backdrop-filter: blur(14px) saturate(140%);
  border-bottom: 1px solid transparent;
  transition: border-color .3s, background .3s;
}
.site-header.is-scrolled { border-bottom-color: var(--line); background: color-mix(in srgb, var(--bg) 88%, transparent); }
.header-inner { height: 100%; display: flex; align-items: center; gap: 28px; }
.brand { display: inline-flex; align-items: center; gap: 10px; font: 700 21px/1 var(--display); letter-spacing: -0.03em; }
.brand img { width: 36px; height: 36px; border-radius: 10px; background: var(--surface-2); object-fit: cover; object-position: top; }
.brand b { background: var(--brand-grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.nav { display: flex; gap: 4px; margin-left: 8px; }
.nav a { padding: 8px 12px; border-radius: 10px; color: var(--muted); font-size: 15px; font-weight: 500; transition: color .2s, background .2s; }
.nav a:hover { color: var(--text); background: var(--surface); }
.header-actions { margin-left: auto; display: flex; gap: 8px; }

/* ---------- Buttons & chips ---------- */
.btn {
  --btn-bg: var(--surface-2);
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 44px; padding: 0 18px; border-radius: 12px;
  font: 600 15px/1 var(--sans); white-space: nowrap;
  background: var(--btn-bg); border: 1px solid var(--line-2);
  transition: transform .25s var(--ease), box-shadow .25s, background .2s, border-color .2s, filter .2s;
}
.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(0); }
.btn .icon { transition: transform .25s var(--ease); }
.btn:hover .icon:last-child { transform: translateX(2px); }
.btn-sm { height: 36px; padding: 0 13px; font-size: 14px; border-radius: 10px; }
.btn-sm .icon { width: 16px; height: 16px; }
.btn-lg { height: 52px; padding: 0 22px; font-size: 16px; border-radius: 14px; }
.btn-brand { background: var(--brand-grad); color: #1a0d07; border-color: transparent; box-shadow: 0 8px 30px -10px rgba(255, 90, 54, 0.7), inset 0 1px 0 rgba(255,255,255,.35); }
.btn-brand:hover { box-shadow: 0 14px 40px -12px rgba(255, 110, 54, 0.9), inset 0 1px 0 rgba(255,255,255,.35); filter: brightness(1.05); }
.btn-accent { background: var(--accent); color: #0f0d0c; border-color: transparent; box-shadow: 0 10px 34px -12px color-mix(in srgb, var(--accent) 80%, transparent), inset 0 1px 0 rgba(255,255,255,.35); }
.btn-accent:hover { filter: brightness(1.08); }
.btn-ghost { background: rgba(255, 240, 225, 0.04); }
.btn-ghost:hover { background: rgba(255, 240, 225, 0.08); border-color: rgba(255, 236, 214, 0.25); }
.btn-row { display: flex; flex-wrap: wrap; gap: 10px; }
.icon-btn { display: inline-grid; place-items: center; width: 40px; height: 40px; border-radius: 12px; border: 1px solid var(--line-2); background: var(--surface); transition: background .2s, transform .2s; }
.icon-btn:hover { background: var(--surface-2); transform: translateY(-1px); }

.chip {
  display: inline-flex; align-items: center; gap: 6px; height: 26px; padding: 0 10px; border-radius: 999px;
  background: rgba(255, 240, 225, 0.06); border: 1px solid var(--line); color: var(--muted); font-size: 12.5px; font-weight: 500;
}
.chip-accent { color: var(--accent); background: color-mix(in srgb, var(--accent) 12%, transparent); border-color: color-mix(in srgb, var(--accent) 30%, transparent); }
.kind {
  display: inline-flex; align-items: center; gap: 6px; height: 26px; padding: 0 10px 0 8px; border-radius: 999px;
  font-size: 12.5px; font-weight: 600; color: var(--accent);
  background: color-mix(in srgb, var(--accent) 13%, rgba(15, 13, 12, .72));
  border: 1px solid color-mix(in srgb, var(--accent) 32%, transparent);
  backdrop-filter: blur(8px);
}
.kind .icon { width: 14px; height: 14px; }
.kind-muted { color: var(--muted); background: rgba(15, 13, 12, .72); border-color: var(--line-2); }

.eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font: 600 12.5px/1 var(--mono); letter-spacing: .12em; text-transform: uppercase; color: var(--brand-2);
}
.project .eyebrow { color: var(--accent); }
.pulse { width: 8px; height: 8px; border-radius: 50%; background: #4ade80; box-shadow: 0 0 0 0 rgba(74, 222, 128, .6); animation: pulse 2s infinite; }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(74,222,128,.55); } 70% { box-shadow: 0 0 0 10px rgba(74,222,128,0); } 100% { box-shadow: 0 0 0 0 rgba(74,222,128,0); } }
.grad { background: var(--brand-grad); -webkit-background-clip: text; background-clip: text; color: transparent; }

/* ---------- Covers (any image shape) ---------- */
.cover { position: relative; overflow: hidden; background: color-mix(in srgb, var(--accent) 12%, var(--surface)); }
.cover-bg { position: absolute; inset: -20%; width: 140%; height: 140%; object-fit: cover; filter: blur(28px) saturate(1.3) brightness(.55); transform: scale(1.1); }
.cover-img { position: relative; width: 100%; height: 100%; object-fit: contain; padding: 6%; filter: drop-shadow(0 12px 24px rgba(0,0,0,.45)); }
.cover-empty { background: radial-gradient(circle at 30% 20%, color-mix(in srgb, var(--accent) 35%, transparent), transparent 60%), var(--surface); }

.logo { width: 44px; height: 44px; border-radius: 12px; object-fit: cover; background: var(--surface-2); flex: none; box-shadow: 0 0 0 1px var(--line-2); }
.logo-sm { width: 34px; height: 34px; border-radius: 10px; }
.logo-lg { width: 76px; height: 76px; border-radius: 20px; box-shadow: 0 0 0 1px var(--line-2), 0 18px 40px -16px color-mix(in srgb, var(--accent) 70%, transparent); }
.logo-letter { display: grid; place-items: center; font: 800 1.1em/1 var(--display); color: var(--accent); background: color-mix(in srgb, var(--accent) 16%, var(--surface-2)); }
.logo-lg.logo-letter { font-size: 34px; }

/* ---------- Hero ---------- */
.hero { position: relative; padding: 64px 0 40px; overflow: hidden; }
.hero-grid {
  position: absolute; inset: 0; pointer-events: none;
  background-image:
    linear-gradient(rgba(255, 236, 214, 0.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 236, 214, 0.045) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: radial-gradient(ellipse 70% 60% at 65% 35%, #000 20%, transparent 75%);
  -webkit-mask-image: radial-gradient(ellipse 70% 60% at 65% 35%, #000 20%, transparent 75%);
}
.hero-inner { position: relative; display: grid; grid-template-columns: 1.05fr 0.95fr; gap: 40px; align-items: center; min-height: min(640px, calc(100vh - var(--header-h) - 80px)); }
.hero h1 { font-size: clamp(40px, 5.4vw, 72px); font-weight: 800; letter-spacing: -0.035em; margin: 18px 0 22px; }
.hero h1 .grad { display: inline; }
.hero-lead { font-size: clamp(17px, 1.6vw, 19.5px); color: var(--muted); max-width: 560px; margin-bottom: 30px; }
.stats { display: grid; grid-template-columns: repeat(4, auto); justify-content: start; gap: 12px 34px; margin: 40px 0 0; }
.stats div { position: relative; padding-left: 14px; }
.stats div::before { content: ''; position: absolute; left: 0; top: 6px; bottom: 6px; width: 2px; border-radius: 2px; background: var(--brand-grad); }
.stats dt { order: 2; font-size: 13px; color: var(--dim); }
.stats dd { margin: 0; font: 800 32px/1.1 var(--display); letter-spacing: -0.03em; font-variant-numeric: tabular-nums; }
.stats div { display: flex; flex-direction: column-reverse; }

.hero-art { position: relative; height: 560px; display: grid; place-items: center; }
.hero-glow { position: absolute; width: 70%; aspect-ratio: 1; border-radius: 50%; background: radial-gradient(circle, rgba(255, 90, 54, 0.38), rgba(255, 181, 71, 0.12) 45%, transparent 70%); filter: blur(30px); animation: breathe 7s ease-in-out infinite; }
@keyframes breathe { 50% { transform: scale(1.08); opacity: .85; } }
.mascot { position: relative; width: min(440px, 80%); height: auto; filter: drop-shadow(0 30px 50px rgba(0,0,0,.55)); animation: bob 6s ease-in-out infinite; transform: translate3d(var(--px, 0), var(--py, 0), 0); }
@keyframes bob { 50% { translate: 0 -10px; } }
.hero-tile {
  position: absolute; z-index: 2; display: flex; align-items: center; gap: 10px; padding: 8px 14px 8px 8px;
  background: color-mix(in srgb, var(--surface) 82%, transparent); border: 1px solid color-mix(in srgb, var(--accent) 35%, var(--line));
  border-radius: 16px; font: 600 14px/1 var(--sans); white-space: nowrap;
  box-shadow: 0 16px 40px -14px rgba(0,0,0,.7), 0 0 30px -12px var(--accent);
  backdrop-filter: blur(10px);
  animation: float 7s ease-in-out infinite;
  transform: translate3d(calc(var(--px, 0px) * -1.6), calc(var(--py, 0px) * -1.6), 0);
  transition: border-color .2s, box-shadow .2s, scale .25s var(--ease);
}
.hero-tile:hover { scale: 1.06; border-color: var(--accent); box-shadow: 0 16px 40px -14px rgba(0,0,0,.7), 0 0 40px -6px var(--accent); }
.tile-logo { width: 34px; height: 34px; border-radius: 10px; object-fit: cover; background: var(--surface-2); }
.tile-logo.logo-letter { font-size: 17px; }
.t1 { top: 6%; left: 2%; animation-delay: -1s; }
.t2 { top: 14%; right: 0; animation-delay: -3s; }
.t3 { top: 46%; left: -4%; animation-delay: -5s; }
.t4 { top: 54%; right: -3%; animation-delay: -2s; }
.t5 { bottom: 8%; left: 8%; animation-delay: -4s; }
.t6 { bottom: 2%; right: 10%; animation-delay: -6s; }
@keyframes float { 50% { translate: 0 -12px; } }

/* ---------- Marquee ---------- */
.marquee { position: relative; padding: 18px 0 8px; display: grid; gap: 14px; overflow: hidden;
  mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent); }
.mq-row { overflow: hidden; }
.mq-track { display: flex; gap: 14px; width: max-content; animation: scroll 70s linear infinite; }
.mq-reverse .mq-track { animation-direction: reverse; animation-duration: 80s; }
.marquee:hover .mq-track { animation-play-state: paused; }
.mq-item { width: 260px; flex: none; border-radius: 14px; overflow: hidden; border: 1px solid var(--line); transition: border-color .3s, transform .3s var(--ease); }
.mq-item .cover { aspect-ratio: 16 / 8; }
.mq-item { position: relative; }
.mq-item:hover { border-color: color-mix(in srgb, var(--accent) 60%, transparent); transform: translateY(-3px); }
.mq-label {
  position: absolute; inset: auto 0 0 0; display: flex; align-items: baseline; justify-content: space-between; gap: 10px;
  padding: 28px 14px 11px;
  background: linear-gradient(180deg, transparent, rgba(10, 9, 8, .82) 45%, rgba(10, 9, 8, .94));
  opacity: 0; transform: translateY(8px); transition: opacity .25s, transform .3s var(--ease);
  pointer-events: none;
}
.mq-label strong { font: 700 15px/1.2 var(--display); letter-spacing: -0.01em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mq-label span { flex: none; font-size: 11.5px; font-weight: 600; color: var(--accent); text-transform: uppercase; letter-spacing: .08em; }
.mq-item:hover .mq-label, .mq-item:focus-visible .mq-label { opacity: 1; transform: none; }
@keyframes scroll { to { transform: translateX(calc(-50% - 7px)); } }

/* ---------- Sections ---------- */
.section { position: relative; padding: 110px 0; }
.section-alt { background: linear-gradient(180deg, transparent, var(--bg-2) 12%, var(--bg-2) 88%, transparent); }
.section-head { max-width: 680px; margin-bottom: 48px; }
.section-head h2 { font-size: clamp(34px, 4.4vw, 54px); margin: 14px 0 14px; letter-spacing: -0.03em; }
.section-head p.muted { font-size: 17.5px; }
.section-head .btn-row { margin-top: 22px; }

/* ---------- Showcases ---------- */
.showcases { display: grid; gap: 110px; }
.showcase { display: grid; grid-template-columns: 1.15fr 0.85fr; gap: 64px; align-items: center; }
.showcase.flip .showcase-art { order: 2; }
.showcase-art { position: relative; display: block; }
.showcase-art::before { content: ''; position: absolute; inset: 10% 6%; background: var(--accent); filter: blur(80px); opacity: .22; border-radius: 50%; transition: opacity .4s; }
.showcase-art:hover::before { opacity: .36; }
.frame { position: relative; border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line-2); box-shadow: 0 40px 80px -40px rgba(0,0,0,.9), 0 0 0 1px rgba(0,0,0,.4); transition: transform .6s var(--ease); }
.frame .cover { aspect-ratio: 16 / 10; }
.showcase-art .frame:first-child { transform: perspective(1400px) rotateY(var(--ry, -6deg)) rotateX(2deg); }
.showcase.flip .showcase-art .frame:first-child { --ry: 6deg; }
.showcase-art:hover .frame:first-child { transform: perspective(1400px) rotateY(0) rotateX(0); }
.showcase-kicker { display: flex; gap: 8px; margin-bottom: 18px; }
.showcase-text h3 { font-size: clamp(32px, 3.6vw, 46px); letter-spacing: -0.03em; }
.showcase-text h3 a { transition: color .2s; }
.showcase-text h3 a:hover { color: var(--accent); }
.showcase-text .lead { font-size: 19px; color: var(--text); margin: 14px 0 12px; }
.showcase-points { list-style: none; padding: 0; margin: 22px 0 28px; display: grid; gap: 10px; }
.showcase-points li { display: flex; gap: 10px; color: var(--muted); font-size: 15px; }
.showcase-points .icon { color: var(--accent); margin-top: 3px; }

/* ---------- Toolbar + grid ---------- */
.toolbar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 14px; margin-bottom: 28px; }
.filters { display: flex; flex-wrap: wrap; gap: 6px; padding: 5px; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; }
.filter { height: 36px; padding: 0 14px; border-radius: 10px; color: var(--muted); font-size: 14px; font-weight: 600; transition: background .2s, color .2s; }
.filter span { margin-left: 4px; font: 500 12px var(--mono); color: var(--dim); }
.filter:hover { color: var(--text); }
.filter.is-on { background: var(--surface-3); color: var(--text); box-shadow: inset 0 1px 0 rgba(255,255,255,.06); }
.filter.is-on span { color: var(--brand-2); }
.toolbar-right { display: flex; gap: 8px; flex-wrap: wrap; }
.search { display: flex; align-items: center; gap: 8px; height: 46px; padding: 0 14px; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; color: var(--dim); transition: border-color .2s; }
.search:focus-within { border-color: var(--line-2); color: var(--muted); }
.search input { background: none; border: 0; outline: 0; color: var(--text); font: inherit; font-size: 15px; width: 190px; }
.sort { height: 46px; padding: 0 36px 0 14px; background: var(--surface) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23b1a497' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E") no-repeat right 12px center / 16px; border: 1px solid var(--line); border-radius: 14px; color: var(--text); font: inherit; font-size: 14.5px; appearance: none; cursor: pointer; }

.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(330px, 1fr)); gap: 22px; }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.card {
  position: relative; display: flex; flex-direction: column; border-radius: var(--radius); overflow: hidden;
  background: linear-gradient(180deg, var(--surface), color-mix(in srgb, var(--surface) 70%, var(--bg)));
  border: 1px solid var(--line);
  transform: perspective(900px) rotateX(var(--tx, 0deg)) rotateY(var(--ty, 0deg));
  transition: border-color .3s, box-shadow .4s, transform .5s var(--ease);
  isolation: isolate;
}
.card::after {
  content: ''; position: absolute; inset: 0; z-index: -1; pointer-events: none; opacity: 0; transition: opacity .3s;
  background: radial-gradient(420px circle at var(--cx, 50%) var(--cy, 0%), color-mix(in srgb, var(--accent) 16%, transparent), transparent 55%);
}
.card:hover { border-color: color-mix(in srgb, var(--accent) 45%, transparent); box-shadow: 0 30px 60px -30px rgba(0,0,0,.9), 0 0 50px -24px var(--accent); }
.card:hover::after { opacity: 1; }
.card-media { position: relative; }
.card-media .cover { aspect-ratio: 16 / 8.5; }
.card-media .cover-img { transition: transform .6s var(--ease); }
.card:hover .card-media .cover-img { transform: scale(1.05); }
.card-badges { position: absolute; left: 12px; top: 12px; display: flex; gap: 6px; }
.card-body { display: flex; flex-direction: column; gap: 10px; padding: 18px 20px 20px; flex: 1; }
.card-title-row { display: flex; align-items: center; gap: 12px; }
.card h3 { font-size: 21px; letter-spacing: -0.02em; }
.card-tagline { color: var(--muted); font-size: 15px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.card-meta { display: flex; align-items: center; gap: 12px; margin-top: auto; padding-top: 6px; font-size: 13.5px; }
.card-dl { display: inline-flex; align-items: center; gap: 4px; }
.card-dl .icon { width: 14px; height: 14px; }
.card-arrow { position: absolute; right: 16px; bottom: 18px; color: var(--accent); opacity: 0; transform: translateX(-6px); transition: opacity .3s, transform .3s var(--ease); }
.card:hover .card-arrow { opacity: 1; transform: none; }
.card.is-hidden { display: none; }
.empty { text-align: center; color: var(--muted); padding: 40px 0; }

/* ---------- Timeline ---------- */
.releases-wrap { display: grid; grid-template-columns: 0.8fr 1.2fr; gap: 60px; align-items: start; }
.releases-wrap .section-head { position: sticky; top: calc(var(--header-h) + 40px); }
.timeline { list-style: none; margin: 0; padding: 0 0 0 26px; position: relative; display: grid; gap: 14px; }
.timeline::before { content: ''; position: absolute; left: 7px; top: 12px; bottom: 12px; width: 2px; background: linear-gradient(var(--line-2), transparent); }
.rel { position: relative; }
.rel-dot { position: absolute; left: -26px; top: 26px; width: 16px; height: 16px; border-radius: 50%; background: var(--bg); border: 3px solid var(--accent); box-shadow: 0 0 16px var(--accent); }
.rel-card { display: grid; grid-template-columns: auto 1fr auto; gap: 14px; align-items: start; padding: 16px 18px; background: var(--surface); border: 1px solid var(--line); border-radius: 16px; transition: border-color .25s, transform .3s var(--ease), background .25s; }
.rel-card:hover { border-color: color-mix(in srgb, var(--accent) 45%, transparent); transform: translateX(4px); background: color-mix(in srgb, var(--accent) 4%, var(--surface)); }
.rel-head { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-bottom: 4px; }
.rel-head strong { font: 700 17px/1.2 var(--display); }
.rel-title { font-size: 15px; margin-bottom: 2px; }
.rel-body .muted { font-size: 14.5px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.rel-card time { font-size: 13px; color: var(--dim); white-space: nowrap; padding-top: 3px; }

/* ---------- About ---------- */
.about { display: grid; grid-template-columns: 0.8fr 1.2fr; gap: 70px; align-items: center; }
.about-art { position: relative; display: grid; place-items: center; }
.about-art img { position: relative; width: min(360px, 80%); filter: drop-shadow(0 30px 50px rgba(0,0,0,.5)); animation: bob 7s ease-in-out infinite; }
.about-text h2 { font-size: clamp(34px, 4.2vw, 52px); margin: 14px 0 18px; }
.about-text .lead { font-size: 19px; margin-bottom: 14px; }
.values { list-style: none; padding: 0; margin: 30px 0 32px; display: grid; gap: 14px; }
.values li { display: flex; gap: 14px; align-items: flex-start; }
.values .icon { width: 40px; height: 40px; padding: 10px; border-radius: 12px; background: color-mix(in srgb, var(--brand) 14%, var(--surface)); color: var(--brand-2); border: 1px solid color-mix(in srgb, var(--brand) 25%, transparent); }
.values strong { display: block; font-size: 16px; }
.values span { color: var(--muted); font-size: 15px; }

/* ---------- Footer ---------- */
.site-footer { border-top: 1px solid var(--line); padding: 50px 0 30px; margin-top: 40px; background: var(--bg-2); }
.footer-inner { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 30px; }
.footer-brand p { color: var(--muted); margin-top: 12px; max-width: 360px; font-size: 15px; }
.footer-links { display: flex; flex-wrap: wrap; gap: 6px 22px; align-items: center; }
.footer-links a { color: var(--muted); font-size: 15px; display: inline-flex; align-items: center; gap: 6px; }
.footer-links a:hover { color: var(--text); }
.footer-links .icon { width: 15px; height: 15px; }
.footer-small { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px; margin-top: 36px; padding-top: 20px; border-top: 1px solid var(--line); color: var(--dim); font-size: 13px; }

/* ---------- Project page ---------- */
.p-hero { position: relative; padding: 40px 0 70px; overflow: hidden; border-bottom: 1px solid var(--line); }
.p-hero-bg { position: absolute; inset: 0; z-index: -1; }
.p-hero-bg img { width: 100%; height: 100%; object-fit: cover; filter: blur(60px) saturate(1.4) brightness(.35); transform: scale(1.3); opacity: .9; }
.p-hero-bg::after { content: ''; position: absolute; inset: 0; background:
  radial-gradient(ellipse 60% 80% at 80% 30%, color-mix(in srgb, var(--accent) 20%, transparent), transparent 70%),
  linear-gradient(180deg, color-mix(in srgb, var(--bg) 40%, transparent), var(--bg)); }
.p-hero-inner { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: center; }
.crumbs { display: flex; flex-wrap: wrap; gap: 8px; font-size: 14px; color: var(--dim); margin-bottom: 28px; }
.crumbs a { color: var(--muted); }
.crumbs a:hover { color: var(--text); }
.p-title { display: flex; align-items: center; gap: 20px; }
.p-badges { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 10px; }
.p-hero-inner > *, .p-title > div { min-width: 0; }
.p-title h1 { font-size: clamp(30px, 5vw, 64px); font-weight: 800; letter-spacing: -0.035em; overflow-wrap: anywhere; }
/* Long single-word names (BedrockAdvancements) shrink rather than break mid-word. */
.p-title h1.p-title-long { font-size: clamp(24px, 2.9vw, 40px); }
.p-tagline { font-size: clamp(18px, 1.8vw, 22px); color: var(--text); opacity: .9; margin: 22px 0 30px; max-width: 580px; }
.p-meta { list-style: none; padding: 0; margin: 26px 0 0; display: flex; flex-wrap: wrap; gap: 8px 22px; color: var(--muted); font-size: 14.5px; }
.p-meta li { display: inline-flex; align-items: center; gap: 7px; }
.p-meta .icon { width: 16px; height: 16px; color: var(--accent); }
.p-hero-art { position: relative; }
.p-hero-art::before { content: ''; position: absolute; inset: 8%; background: var(--accent); filter: blur(90px); opacity: .28; border-radius: 50%; }
.frame-hero { transform: perspective(1400px) rotateY(-7deg) rotateX(3deg) translate3d(var(--px, 0), var(--py, 0), 0); }
.frame-hero .cover { aspect-ratio: 16 / 10; }
.p-hero-slim { padding: 40px 0 46px; }

.subnav { position: sticky; top: var(--header-h); z-index: 40; background: color-mix(in srgb, var(--bg) 85%, transparent); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); border-bottom: 1px solid var(--line); }
.subnav-inner { display: flex; align-items: center; gap: 4px; height: 56px; overflow-x: auto; scrollbar-width: none; }
.subnav-inner::-webkit-scrollbar { display: none; }
.subnav a:not(.btn) { padding: 8px 12px; border-radius: 10px; color: var(--muted); font-size: 14.5px; font-weight: 500; white-space: nowrap; transition: color .2s, background .2s; }
.subnav a:not(.btn):hover, .subnav a.is-active { color: var(--text); background: var(--surface); }
.subnav a.is-active { box-shadow: inset 0 -2px 0 var(--accent); border-radius: 10px 10px 4px 4px; }
.subnav-cta { margin-left: auto; opacity: 0; pointer-events: none; transform: translateY(6px); transition: opacity .3s, transform .3s var(--ease); }
.subnav.is-stuck .subnav-cta { opacity: 1; pointer-events: auto; transform: none; }

.p-body { padding: 56px 0 40px; }
.p-columns { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 56px; align-items: start; }
.block { margin-bottom: 64px; }
.block > h2, .block-head h2 { font-size: 30px; margin-bottom: 22px; letter-spacing: -0.025em; }
.block-head { display: flex; justify-content: space-between; align-items: center; }
.block-head h2 { margin: 0; }
.carousel-nav { display: flex; gap: 8px; }

.carousel { display: flex; gap: 16px; overflow-x: auto; scroll-snap-type: x mandatory; padding: 22px 0 10px; scrollbar-width: thin; scrollbar-color: var(--surface-3) transparent; }
.shot { position: relative; flex: 0 0 min(560px, 82%); scroll-snap-align: start; border-radius: 16px; overflow: hidden; border: 1px solid var(--line-2); background: var(--surface); transition: border-color .3s, transform .3s var(--ease); }
.shot img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; transition: transform .6s var(--ease); }
.shot:hover { border-color: color-mix(in srgb, var(--accent) 55%, transparent); }
.shot:hover img { transform: scale(1.03); }
.shot-caption { position: absolute; left: 12px; bottom: 12px; padding: 6px 10px; border-radius: 8px; background: rgba(10,9,8,.75); font-size: 13px; backdrop-filter: blur(6px); }

.prose { color: #e3d9cf; font-size: 16.5px; line-height: 1.75; }
.prose > * + * { margin-top: 1.05em; }
.prose-lead > p:first-child { font-size: 19px; color: var(--text); }
.prose h1, .prose h2, .prose h3, .prose h4 { color: var(--text); margin-top: 1.8em; letter-spacing: -0.02em; }
.prose h1 { font-size: 34px; }
.prose h2 { font-size: 28px; }
.prose h3 { font-size: 22px; }
.prose h4 { font-size: 18px; }
.prose h5, .prose h6 { font-size: 15px; font-family: var(--sans); text-transform: uppercase; letter-spacing: .08em; color: var(--accent); margin: 1.6em 0 0; }
.prose a { color: var(--accent); text-decoration: underline; text-decoration-color: color-mix(in srgb, var(--accent) 40%, transparent); text-underline-offset: 3px; }
.prose a:hover { text-decoration-color: var(--accent); }
.prose ul, .prose ol { padding-left: 1.3em; }
.prose li + li { margin-top: .35em; }
.prose li::marker { color: var(--accent); }
.prose strong { color: var(--text); }
.prose code { font-family: var(--mono); font-size: .88em; padding: 2px 6px; border-radius: 6px; background: var(--surface-2); border: 1px solid var(--line); color: var(--text); }
.prose pre { background: #0b0a09; border: 1px solid var(--line); border-radius: 12px; padding: 16px 18px; overflow-x: auto; }
.prose pre code { background: none; border: 0; padding: 0; font-size: 14px; line-height: 1.6; }
.prose blockquote { margin-left: 0; padding: 12px 18px; border-left: 3px solid var(--accent); background: color-mix(in srgb, var(--accent) 6%, var(--surface)); border-radius: 0 12px 12px 0; }
.prose hr { border: 0; border-top: 1px solid var(--line-2); margin: 2em 0; }
.prose img { border-radius: 12px; border: 1px solid var(--line); }
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: 12px; }
.prose table { width: 100%; border-collapse: collapse; font-size: 14.5px; }
.prose th, .prose td { text-align: left; padding: 10px 14px; border-bottom: 1px solid var(--line); vertical-align: top; }
.prose th { background: var(--surface); color: var(--text); font-weight: 600; }
.prose tr:last-child td { border-bottom: 0; }
.cl-section { font: 600 12.5px/1 var(--mono) !important; letter-spacing: .1em; text-transform: uppercase; color: var(--accent) !important; margin-top: 1.6em !important; }
.prose .cl-section:first-child { margin-top: 0 !important; }

.features { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
.features li { display: flex; gap: 12px; padding: 16px 18px; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; font-size: 15.5px; color: #e3d9cf; transition: border-color .25s, transform .3s var(--ease); }
.features li:hover { border-color: color-mix(in srgb, var(--accent) 40%, transparent); transform: translateY(-2px); }
.features .icon { color: var(--accent); width: 20px; height: 20px; padding: 2px; margin-top: 2px; border-radius: 6px; background: color-mix(in srgb, var(--accent) 14%, transparent); }

.steps { list-style: none; counter-reset: step; padding: 0; margin: 0; display: grid; gap: 12px; }
.steps li { counter-increment: step; display: flex; gap: 16px; align-items: flex-start; padding: 14px 18px; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; color: #e3d9cf; }
.steps li::before { content: counter(step); flex: none; display: grid; place-items: center; width: 30px; height: 30px; border-radius: 9px; background: color-mix(in srgb, var(--accent) 16%, var(--surface-2)); color: var(--accent); font: 700 14px/1 var(--mono); }
.steps li span { padding-top: 3px; }
.steps code { font-family: var(--mono); font-size: .88em; padding: 2px 6px; border-radius: 6px; background: var(--surface-2); }

/* Trailer player: poster + play until clicked, then the real <video>/<iframe>. */
.player { position: relative; display: block; width: 100%; aspect-ratio: 16 / 9; overflow: hidden; background: #000; cursor: pointer; }
.player > img, .player > .cover { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform .8s var(--ease), filter .4s; }
.player:hover > img { transform: scale(1.03); filter: brightness(1.08); }
.player::after { content: ''; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 55%, rgba(0,0,0,.55)); pointer-events: none; }
.player-play { position: absolute; z-index: 1; inset: 0; margin: auto; width: 82px; height: 82px; display: grid; place-items: center; border-radius: 50%; background: var(--accent); color: #0f0d0c; box-shadow: 0 0 0 0 color-mix(in srgb, var(--accent) 50%, transparent), 0 20px 50px -10px rgba(0,0,0,.7); animation: ring 2.6s infinite; transition: transform .35s var(--ease); }
.player-play .icon { width: 32px; height: 32px; fill: currentColor; margin-left: 4px; }
.player:hover .player-play { transform: scale(1.1); }
@keyframes ring { 0% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--accent) 50%, transparent), 0 20px 50px -10px rgba(0,0,0,.7); } 75%, 100% { box-shadow: 0 0 0 22px transparent, 0 20px 50px -10px rgba(0,0,0,.7); } }
.player-label { position: absolute; z-index: 1; left: 16px; bottom: 14px; display: inline-flex; align-items: center; gap: 6px; padding: 7px 12px 7px 10px; border-radius: 999px; background: rgba(12, 10, 9, .72); backdrop-filter: blur(8px); font-size: 13.5px; font-weight: 600; border: 1px solid rgba(255,255,255,.12); }
.player-label .icon { width: 13px; height: 13px; fill: currentColor; color: var(--accent); }
.player video, .player iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; background: #000; }
.player.is-playing { cursor: default; }
.player.is-playing::after { display: none; }
.frame-video, .showcase-art .frame.frame-video:first-child { transform: none !important; }
.frame-video:has(.is-playing) { box-shadow: 0 40px 90px -30px color-mix(in srgb, var(--accent) 45%, #000); }

.guide-card { display: flex; align-items: center; gap: 18px; padding: 22px 24px; margin-bottom: 64px; border-radius: 18px; border: 1px solid color-mix(in srgb, var(--accent) 35%, var(--line)); background: linear-gradient(120deg, color-mix(in srgb, var(--accent) 12%, var(--surface)), var(--surface)); transition: transform .3s var(--ease), border-color .3s; }
.guide-card:hover { transform: translateY(-3px); border-color: var(--accent); }
.guide-card div { flex: 1; }
.guide-card strong { display: block; font: 700 19px/1.2 var(--display); }
.guide-card span { color: var(--muted); font-size: 15px; }
.guide-icon { width: 46px; height: 46px; padding: 11px; border-radius: 14px; background: color-mix(in srgb, var(--accent) 18%, transparent); color: var(--accent); }

.changes { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.change details { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; overflow: hidden; transition: border-color .25s; }
.change details[open] { border-color: var(--line-2); }
.change summary { display: flex; align-items: center; gap: 12px; padding: 16px 20px; cursor: pointer; list-style: none; }
.change summary::-webkit-details-marker { display: none; }
.change summary:hover { background: rgba(255, 240, 225, 0.02); }
.change-version { font-weight: 600; font-size: 15px; color: var(--text); }
.change-title { color: var(--muted); font-size: 15px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.change-spacer { margin-left: auto; }
.change summary time { margin-left: auto; color: var(--dim); font-size: 13.5px; white-space: nowrap; }
.change-chev { color: var(--dim); transition: transform .3s var(--ease); }
.change details[open] .change-chev { transform: rotate(180deg); }
.change-body { padding: 4px 22px 22px; border-top: 1px solid var(--line); padding-top: 18px; font-size: 15.5px; }
.change-img { margin-bottom: 14px; }

.facts { position: sticky; top: calc(var(--header-h) + 80px); padding: 22px; border-radius: 20px; background: linear-gradient(180deg, color-mix(in srgb, var(--accent) 6%, var(--surface)), var(--surface)); border: 1px solid var(--line-2); }
.facts-title { font-size: 19px; margin-bottom: 14px; }
.facts dl { margin: 0; display: grid; }
.facts dl div { display: grid; grid-template-columns: 112px 1fr; gap: 10px; padding: 11px 0; border-top: 1px solid var(--line); font-size: 14.5px; }
.facts dt { color: var(--dim); }
.facts dd { margin: 0; min-width: 0; overflow-wrap: anywhere; }
.facts dd a { color: var(--accent); }
.facts-links { display: grid; gap: 4px; margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--line); }
.facts-links a { display: flex; align-items: center; gap: 10px; padding: 9px 10px; border-radius: 10px; color: var(--text); font-size: 14.5px; transition: background .2s; }
.facts-links a:hover { background: rgba(255, 240, 225, 0.05); }
.facts-links .icon { color: var(--accent); width: 17px; height: 17px; }
.facts-help { display: flex; gap: 12px; align-items: flex-start; margin-top: 14px; padding: 14px; border-radius: 14px; background: rgba(88, 101, 242, 0.1); border: 1px solid rgba(88, 101, 242, 0.25); font-size: 14px; color: var(--muted); transition: background .2s; }
.facts-help:hover { background: rgba(88, 101, 242, 0.16); }
.facts-help .icon { color: #8b97ff; width: 22px; height: 22px; }
.facts-help strong { color: var(--text); display: block; }

/* Docs */
.docs-layout { display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: 56px; padding: 50px 0; align-items: start; }
.docs-layout:not(:has(.toc)) { grid-template-columns: minmax(0, 820px); justify-content: center; }
.toc { position: sticky; top: calc(var(--header-h) + 24px); display: grid; gap: 2px; max-height: calc(100vh - var(--header-h) - 48px); overflow-y: auto; padding-right: 8px; }
.toc-title { font: 600 12px/1 var(--mono); letter-spacing: .12em; text-transform: uppercase; color: var(--dim); margin-bottom: 10px; }
.toc a { padding: 6px 10px; border-radius: 8px; font-size: 14px; color: var(--muted); border-left: 2px solid transparent; }
.toc a:hover { color: var(--text); background: var(--surface); }
.toc a.is-active { color: var(--text); border-left-color: var(--accent); background: var(--surface); }
.toc-3 { padding-left: 22px !important; font-size: 13.5px !important; }
.docs-body { max-width: 820px; }
.docs-body > h1:first-child, .docs-body > h2:first-child { margin-top: 0; }
.docs-back { padding-bottom: 40px; }

/* Lightbox */
.lightbox { position: fixed; inset: 0; z-index: 100; display: grid; place-items: center; background: rgba(8, 7, 6, .92); backdrop-filter: blur(10px); opacity: 0; transition: opacity .25s; padding: 24px; }
.lightbox.is-open { opacity: 1; }
.lightbox figure { margin: 0; display: grid; gap: 12px; justify-items: center; max-width: min(1400px, 100%); }
.lightbox img { max-height: calc(100vh - 140px); width: auto; border-radius: 14px; box-shadow: 0 40px 100px rgba(0,0,0,.8); }
.lightbox figcaption { color: var(--muted); font-size: 14px; }
.lightbox .icon-btn { position: absolute; background: rgba(30, 26, 23, .8); }
.lb-close { top: 18px; right: 18px; }
.lb-prev { left: 18px; top: 50%; translate: 0 -50%; }
.lb-next { right: 18px; top: 50%; translate: 0 -50%; }
.lb-count { position: absolute; top: 26px; left: 50%; translate: -50% 0; font: 500 13px var(--mono); color: var(--dim); }

/* 404 */
.notfound { padding-top: 70px; }
.nf-art { margin: 0 auto 20px; animation: bob 6s ease-in-out infinite; }
.notfound h1 { font-size: clamp(40px, 6vw, 68px); margin: 14px 0; }
.nf-grid { margin: 40px 0; text-align: left; }

/* Reveal on scroll */
.js .reveal { opacity: 0; transform: translateY(22px); transition: opacity .8s var(--ease), transform .8s var(--ease); }
.js .reveal.is-in { opacity: 1; transform: none; }
.js .card.reveal.is-in { transform: perspective(900px) rotateX(var(--tx, 0deg)) rotateY(var(--ty, 0deg)); }

/* ---------- Responsive ---------- */
@media (max-width: 1080px) {
  .hero-inner { grid-template-columns: 1fr; min-height: 0; }
  .hero-art { height: 460px; order: -1; width: min(640px, 100%); margin-inline: auto; }
  .stats { grid-template-columns: repeat(2, auto); }
  .showcase, .showcase.flip { grid-template-columns: 1fr; gap: 36px; }
  .showcase.flip .showcase-art { order: 0; }
  .releases-wrap, .about { grid-template-columns: 1fr; gap: 36px; }
  .releases-wrap .section-head { position: static; }
  .p-hero-inner { grid-template-columns: 1fr; gap: 40px; }
  .p-columns { grid-template-columns: 1fr; }
  .facts { position: static; }
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
  .docs-layout { grid-template-columns: 1fr; }
  .toc { position: static; max-height: none; padding: 16px; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; }
}
@media (max-width: 760px) {
  :root { --header-h: 60px; }
  .nav { display: none; }
  .header-actions .btn span { display: none; }
  .header-actions .btn { width: 40px; padding: 0; }
  .hero { padding-top: 24px; }
  .hero-art { height: 360px; }
  .mascot { width: 62%; }
  .hero-tile > span:not(.tile-logo) { display: none; }
  .hero-tile { padding: 6px; border-radius: 14px; }
  .t3 { left: 0; } .t4 { right: 0; }
  .stats dd { font-size: 26px; }
  .section { padding: 76px 0; }
  .showcases { gap: 76px; }
  .grid, .grid-3 { grid-template-columns: 1fr; }
  .features { grid-template-columns: 1fr; }
  .toolbar { flex-direction: column; align-items: stretch; }
  .filters { overflow-x: auto; flex-wrap: nowrap; scrollbar-width: none; }
  .filters::-webkit-scrollbar { display: none; }
  .filter { flex: none; }
  .toolbar-right { flex-wrap: nowrap; }
  .search { flex: 1; }
  .search input { width: 100%; }
  .rel-card { grid-template-columns: auto 1fr; }
  .rel-card time { grid-column: 2; padding: 0; }
  .p-title { gap: 14px; }
  .logo-lg { width: 60px; height: 60px; border-radius: 16px; }
  .frame-hero { transform: none; }
  .btn-lg { height: 48px; padding: 0 18px; font-size: 15px; }
  .change summary { flex-wrap: wrap; gap: 6px 10px; }
  .change-title { order: 5; flex-basis: 100%; white-space: normal; }
  .facts dl div { grid-template-columns: 100px 1fr; }
  .lb-prev, .lb-next { top: auto; bottom: 18px; translate: none; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
  .js .reveal { opacity: 1; transform: none; }
}
