/* Loudstack: shared styles for every page. Game pages add /games/game.css on top. */

:root {
  --bg: #0d0e12;
  --bg-2: #15171d;
  --card: #1a1c23;
  --line: #2a2d36;
  --fg: #eceae4;
  --muted: #9a9aa3;
  --accent: #f2a541;
  --accent-ink: #1a1206;
  --radius: 14px;
  --max: 1120px;
  --font: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --display: "Space Grotesk", var(--font);
}

@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) {
    --bg: #f5f3ee;
    --bg-2: #ebe8e0;
    --card: #ffffff;
    --line: #dcd8ce;
    --fg: #17171b;
    --muted: #5f5f68;
    --accent: #c4750c;
    --accent-ink: #ffffff;
  }
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  background: var(--bg);
  color: var(--fg);
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: inherit; }
.wrap { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 20px; }
.pixel { image-rendering: pixelated; image-rendering: crisp-edges; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; height: 64px; gap: 16px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; font-family: var(--display); font-weight: 700; font-size: 1.25rem; letter-spacing: -0.02em; }
.brand b { color: var(--accent); font-weight: 700; }
.bars { display: inline-flex; gap: 3px; align-items: flex-end; height: 20px; }
.bars i { width: 4px; background: var(--accent); border-radius: 1px; animation: pulse 1.2s ease-in-out infinite; }
.bars i:nth-child(1) { height: 8px; }
.bars i:nth-child(2) { height: 16px; animation-delay: .15s; }
.bars i:nth-child(3) { height: 20px; animation-delay: .3s; }
.bars i:nth-child(4) { height: 12px; animation-delay: .45s; }
@keyframes pulse { 0%, 100% { transform: scaleY(.45); } 50% { transform: scaleY(1); } }
.bars i { transform-origin: bottom; }
.nav { display: flex; gap: 6px; list-style: none; }
.nav a { white-space: nowrap; text-decoration: none; color: var(--muted); font-weight: 500; font-size: .95rem; padding: 8px 12px; border-radius: 8px; }
.nav a:hover, .nav a[aria-current="page"] { color: var(--fg); background: var(--bg-2); }
.nav a.nav-games { color: var(--accent-ink); background: var(--accent); font-weight: 700; }
.nav a.nav-games:hover { filter: brightness(1.08); }

/* ---------- Buttons, chips ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 14px 22px; border-radius: 999px;
  font-weight: 700; font-size: 1rem; text-decoration: none;
  border: 1px solid transparent; cursor: pointer; transition: transform .15s, filter .15s, background .15s;
}
.btn:hover { transform: translateY(-1px); }
.btn-primary { background: var(--accent); color: var(--accent-ink); }
.btn-primary:hover { filter: brightness(1.08); }
.btn-ghost { border-color: var(--line); color: var(--fg); background: transparent; }
.btn-ghost:hover { background: var(--bg-2); }
.btn[aria-disabled="true"] { opacity: .55; cursor: default; transform: none; }
.chip {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: .78rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase;
  padding: 6px 12px; border-radius: 999px; border: 1px solid var(--line); color: var(--muted);
}
.chip .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 10px var(--accent); }
.eyebrow { font-size: .8rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--accent); }

/* ---------- Sections ---------- */
section { padding: 96px 0; }
.section-head { max-width: 680px; margin-bottom: 44px; }
.section-head h2 { font-family: var(--display); font-size: clamp(2rem, 5vw, 3rem); line-height: 1.08; letter-spacing: -0.03em; margin-top: 10px; }
.section-head p { color: var(--muted); margin-top: 14px; font-size: 1.08rem; }

/* ---------- Landing hero ---------- */
.hero { padding: 120px 0 96px; position: relative; overflow: hidden; }
.hero::before {
  content: ""; position: absolute; inset: -40% -10% auto auto; width: 720px; height: 720px;
  background: radial-gradient(circle, color-mix(in srgb, var(--accent) 22%, transparent), transparent 65%);
  pointer-events: none;
}
.hero h1 {
  font-family: var(--display); font-weight: 700;
  font-size: clamp(2.8rem, 9vw, 6.2rem); line-height: .98; letter-spacing: -0.045em;
  max-width: 13ch; margin-top: 18px;
}
.hero h1 em { font-style: normal; color: var(--accent); }
.hero .lede { font-size: clamp(1.1rem, 2.4vw, 1.3rem); color: var(--muted); max-width: 40rem; margin-top: 24px; }
.hero .actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 36px; }

/* ---------- Featured games ---------- */
.featured { background: var(--bg-2); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.featured .section-head h2 { font-size: clamp(2.4rem, 7vw, 4.4rem); }
.game-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 22px; }
.game-card {
  position: relative; display: flex; flex-direction: column; justify-content: flex-end;
  min-height: 460px; border-radius: 20px; overflow: hidden; text-decoration: none; color: #fff;
  border: 1px solid var(--line); isolation: isolate; transition: transform .25s, box-shadow .25s;
}
.game-card:hover { transform: translateY(-4px); box-shadow: 0 24px 60px -24px rgba(0,0,0,.6); }
.game-card .art { position: absolute; inset: 0; z-index: -1; }
.game-card .art::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 30%, rgba(0,0,0,.82)); }
.game-card .body { padding: 28px; }
.game-card .meta { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 14px; }
.game-card .meta span { font-size: .74rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; padding: 5px 10px; border-radius: 999px; background: rgba(255,255,255,.14); backdrop-filter: blur(6px); }
.game-card h3 { font-size: clamp(2.2rem, 5vw, 3rem); line-height: 1; letter-spacing: -0.02em; }
.game-card p { margin-top: 10px; color: rgba(255,255,255,.82); max-width: 32rem; }
.game-card .go { display: inline-flex; gap: 8px; margin-top: 18px; font-weight: 700; }
.game-card:hover .go span { transform: translateX(4px); }
.game-card .go span { transition: transform .2s; }
.featured .more { margin-top: 36px; display: flex; justify-content: center; }

/* Game card art */
.art-renaissance {
  background:
    radial-gradient(ellipse at 25% 20%, rgba(244, 196, 104, .55), transparent 45%),
    radial-gradient(ellipse at 80% 70%, rgba(150, 30, 40, .75), transparent 55%),
    radial-gradient(ellipse at 60% 10%, rgba(255, 236, 200, .25), transparent 40%),
    linear-gradient(160deg, #3b1d14, #1d0f0c 60%, #120a09);
}
.art-renaissance .mono {
  position: absolute; right: -2%; top: -6%; font-family: "Cormorant Garamond", Georgia, serif; font-weight: 600;
  font-size: 30rem; line-height: 1; color: rgba(255, 226, 170, .1); font-style: italic;
}
.game-card h3.t-renaissance { font-family: "Cormorant Garamond", Georgia, serif; font-weight: 600; font-size: clamp(2.6rem, 6vw, 3.6rem); letter-spacing: .01em; }
.art-ulterior { background: radial-gradient(ellipse at 70% 20%, rgba(242, 200, 110, .35), transparent 40%), linear-gradient(180deg, #11261f, #0a1512); }
.art-ulterior .scene { position: absolute; inset: 0; background-size: cover; background-position: center; opacity: .55; image-rendering: pixelated; }
.art-ulterior .sprite { position: absolute; image-rendering: pixelated; }
.game-card h3.t-ulterior { font-family: "Jacquard 24", var(--display); font-weight: 400; font-size: clamp(2.8rem, 7vw, 4rem); letter-spacing: .01em; }

/* ---------- Pillars / about ---------- */
.pillars { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.pillar { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; position: relative; }
.pillar .when { position: absolute; top: 22px; right: 22px; }
.pillar .icon { width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; background: color-mix(in srgb, var(--accent) 16%, transparent); color: var(--accent); margin-bottom: 18px; }
.pillar h3 { font-family: var(--display); font-size: 1.35rem; letter-spacing: -0.01em; }
.pillar p { color: var(--muted); margin-top: 8px; }
.pillar.now { border-color: color-mix(in srgb, var(--accent) 55%, var(--line)); }

.about { display: grid; grid-template-columns: 1.1fr 1fr; gap: 56px; align-items: center; }
.about p + p { margin-top: 16px; }
.about .copy p { color: var(--muted); font-size: 1.06rem; }
.about .copy p strong { color: var(--fg); }
.brothers { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.bro { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; }
.bro .tag { font-size: .75rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--accent); }
.bro h3 { font-family: var(--display); margin-top: 8px; font-size: 1.2rem; }
.bro p { color: var(--muted); font-size: .95rem; margin-top: 6px; }
.bro.span { grid-column: 1 / -1; display: flex; align-items: center; gap: 16px; }
.bro.span .big { font-family: var(--display); font-size: 2.4rem; font-weight: 700; color: var(--accent); line-height: 1; }

.manifesto { text-align: center; }
.manifesto blockquote { font-family: var(--display); font-size: clamp(1.6rem, 4.5vw, 2.8rem); line-height: 1.2; letter-spacing: -0.02em; max-width: 22ch; margin: 0 auto; }
.manifesto blockquote em { font-style: normal; color: var(--accent); }

/* ---------- Games index ---------- */
.page-hero { padding: 96px 0 40px; }
.page-hero h1 { font-family: var(--display); font-size: clamp(3rem, 10vw, 6.5rem); line-height: .95; letter-spacing: -0.045em; margin-top: 14px; }
.page-hero p { color: var(--muted); font-size: 1.15rem; max-width: 38rem; margin-top: 18px; }
.game-list { display: grid; gap: 26px; padding-bottom: 40px; }
.game-row { display: grid; grid-template-columns: 1.15fr 1fr; border: 1px solid var(--line); border-radius: 22px; overflow: hidden; background: var(--card); text-decoration: none; transition: transform .25s, box-shadow .25s; }
.game-row:hover { transform: translateY(-3px); box-shadow: 0 24px 60px -28px rgba(0,0,0,.55); }
.game-row .art { position: relative; min-height: 380px; overflow: hidden; }
.game-row .info { padding: 40px; display: flex; flex-direction: column; justify-content: center; }
.game-row .order { font-family: var(--display); font-weight: 700; color: var(--muted); font-size: .9rem; letter-spacing: .1em; }
.game-row h2 { font-size: clamp(2.4rem, 5vw, 3.4rem); line-height: 1; margin: 12px 0; }
.game-row h2.t-renaissance { font-family: "Cormorant Garamond", Georgia, serif; font-weight: 600; }
.game-row h2.t-ulterior { font-family: "Jacquard 24", var(--display); font-weight: 400; font-size: clamp(2.8rem, 6vw, 4rem); }
.game-row p { color: var(--muted); }
.facts { display: grid; grid-template-columns: repeat(3, auto); justify-content: start; gap: 6px 28px; margin: 22px 0 26px; }
.facts dt { font-size: .72rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.facts dd { font-weight: 600; }
.facts div { display: flex; flex-direction: column-reverse; }

/* ---------- Footer ---------- */
.site-footer { border-top: 1px solid var(--line); padding: 44px 0; color: var(--muted); font-size: .92rem; }
.site-footer .wrap { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 18px; align-items: center; }
.site-footer nav { display: flex; gap: 18px; }
.site-footer a { text-decoration: none; }
.site-footer a:hover { color: var(--fg); }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .game-grid, .pillars, .about, .game-row { grid-template-columns: 1fr; }
  .about { gap: 36px; }
  .game-card { min-height: 400px; }
  .game-row .art { min-height: 260px; }
  .game-row .info { padding: 28px; }
}
@media (max-width: 560px) {
  body { font-size: 16px; }
  .wrap { padding: 0 16px; }
  section { padding: 72px 0; }
  .hero { padding: 80px 0 64px; }
  .nav a:not(.nav-games) { display: none; }
  .brothers { grid-template-columns: 1fr; }
  .facts { grid-template-columns: 1fr 1fr; }
  .game-card .body { padding: 22px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}
