:root {
  --bg: #0b0c0e;
  --bg-0: #08090b;
  --pane: #121419;
  --fg: #f2f4f7;
  --hub-fg-0: #f2f4f7;
  --hub-fg-1: #d7dbe0;
  --hub-fg-4: #9aa3ad;
  --hub-fg-5: #6f7881;
  --hub-fg-6: rgba(154,163,173,.55);
  --hub-fg-7: rgba(154,163,173,.32);
  --hub-fg-9: rgba(255,203,5,.14);
  --hub-gold: #ffcb05;
  --hub-gold-40: rgba(255,203,5,.4);
  --hub-card-bg: #121419;
  --hub-card-hover: #181b21;
  --hub-font-sans: 'DM Sans', system-ui, sans-serif;
  --hub-font-mono: 'DM Mono', ui-monospace, monospace;
  --hub-font-display: 'Anton', sans-serif;
}
* { box-sizing: border-box; }
html, body {
  margin: 0; padding: 0;
  background: var(--bg); color: var(--hub-fg-1);
  font-family: var(--hub-font-sans);
  -webkit-font-smoothing: antialiased;
  scrollbar-width: none; -ms-overflow-style: none;
}
html::-webkit-scrollbar, body::-webkit-scrollbar { display: none; }
a { color: inherit; text-decoration: none; }

.atmosphere { position: fixed; inset: 0; z-index: 0; pointer-events: none; }
.atmosphere::before {
  content: ''; position: absolute; inset: 0;
  background: radial-gradient(ellipse 70% 50% at 80% 0%, rgba(255,203,5,.08) 0%, transparent 55%);
}
.grid-bg {
  position: fixed; inset: 0; z-index: 0; pointer-events: none;
  background-image: radial-gradient(rgba(255,203,5,.07) 1px, transparent 1px);
  background-size: 28px 28px;
}
.wrap { position: relative; z-index: 2; max-width: 1400px; margin: 0 auto; padding: 0 40px; }

header.hub-head {
  padding: 36px 0 30px;
  border-bottom: 1px solid var(--hub-fg-9);
}
.head-row { display: flex; align-items: baseline; gap: 16px; flex-wrap: wrap; }
h1.hub-title {
  margin: 0;
  font-family: var(--hub-font-display);
  font-size: 30px; font-weight: 400;
  letter-spacing: .02em; text-transform: uppercase; line-height: 1;
}
h1.hub-title .slash { color: var(--hub-fg-5); margin: 0 8px; font-weight: 400; }
h1.hub-title .accent { color: var(--hub-gold); }
h1.hub-title .mark { color: var(--fg); }
h1.hub-title a.mark:hover { color: var(--hub-gold); }
h1.hub-title .up {
  margin-left: 12px;
  font-family: var(--hub-font-mono); font-weight: 600; font-size: .7em;
  color: var(--hub-gold); letter-spacing: 0;
  transition: transform .15s, opacity .15s;
}
h1.hub-title .up:hover { opacity: .7; transform: translateX(-3px); }
.head-meta { margin-left: auto; }
.head-meta .z3-home {
  font-family: var(--hub-font-sans);
  font-weight: 300; font-size: 28px; letter-spacing: -.04em;
  text-transform: lowercase;
}
.head-meta .z3-home b { color: var(--hub-gold); font-style: italic; font-weight: 400; }

.section { padding: 56px 0 24px; }
.section-label {
  display: flex; align-items: baseline; gap: 20px;
  margin: 0 0 28px;
  font-family: var(--hub-font-mono);
  font-size: 11px; letter-spacing: .2em; text-transform: uppercase;
  color: var(--hub-fg-5);
}
.section-label .tag { color: var(--hub-gold); font-weight: 700; }
.section-label .rule { flex: 1; height: 1px; background: var(--hub-fg-9); }
.section-label .note { color: var(--hub-fg-6); }
.section-label .count { color: var(--hub-fg-5); }

.cards {
  display: grid; gap: 1px;
  background: var(--hub-fg-9);
  border: 1px solid var(--hub-fg-9);
  overflow: hidden;
}
.cards.two { grid-template-columns: repeat(2, 1fr); }
.cards.three { grid-template-columns: repeat(3, 1fr); }
@media (max-width: 900px) {
  .cards.two, .cards.three { grid-template-columns: 1fr; }
}

.card {
  background: var(--hub-card-bg);
  display: flex; flex-direction: column;
  min-height: 0;
  transition: background .25s;
}
.card:hover { background: var(--hub-card-hover); }
.card:hover .card-arrow { color: var(--hub-gold); transform: translateX(4px); }
.card:hover .preview-frame { border-color: var(--hub-gold-40); }

.card-preview {
  position: relative;
  aspect-ratio: 16 / 10;
  background: var(--bg-0);
  overflow: hidden;
  border-bottom: 1px solid var(--hub-fg-9);
}
.preview-frame {
  position: absolute; inset: 0;
  border: 1px solid transparent;
  pointer-events: none;
  transition: border-color .25s;
}
.preview-scale {
  position: absolute; top: 0; left: 0;
  transform-origin: top left;
  pointer-events: none;
}
.preview-scale iframe { border: 0; display: block; background: var(--bg-0); }

.bundle-teaser {
  position: absolute; inset: 0;
  display: flex; flex-direction: column;
  gap: 8px; padding: 8px;
  background: var(--bg-0);
}
.bt-cell {
  position: relative;
  flex: 1 1 0; min-height: 0;
  overflow: hidden;
  border: 1px solid var(--hub-fg-9);
}
.bundle-teaser .preview-scale { position: absolute; top: 0; left: 0; transform-origin: top left; }
.bundle-teaser .preview-scale iframe { pointer-events: none; border: 0; display: block; }

.card-meta {
  display: flex; justify-content: space-between; align-items: center;
  padding: 14px 18px 6px;
  font-family: var(--hub-font-mono);
  font-size: 10px; letter-spacing: .18em; text-transform: uppercase;
  color: var(--hub-fg-6);
}
.card-meta .idx { color: var(--hub-fg-5); }
.card-meta .kind { color: var(--hub-gold); }
.card-body { padding: 4px 18px 14px; flex: 1 1 auto; }
.card-title {
  font-size: 19px; font-weight: 600; letter-spacing: -.015em;
  color: var(--hub-fg-0); margin: 0 0 8px;
}
.card-desc { font-size: 13px; line-height: 1.5; color: var(--hub-fg-4); margin: 0 0 4px; }
.card-tags {
  display: flex; gap: 14px; flex-wrap: wrap;
  font-family: var(--hub-font-mono);
  font-size: 10px; color: var(--hub-fg-5); letter-spacing: .06em; margin-top: 10px;
}
.card-tags span::before { content: '·'; color: var(--hub-fg-7); margin-right: 6px; }
.card-tags span:first-child::before { display: none; }
.card-foot {
  display: flex; justify-content: space-between; align-items: center;
  padding: 10px 18px 14px;
  border-top: 1px solid var(--hub-fg-9);
  font-family: var(--hub-font-mono);
  font-size: 10px; letter-spacing: .15em; text-transform: uppercase;
  color: var(--hub-fg-5);
}
.card-path { color: var(--hub-fg-4); }
.card-arrow { color: var(--hub-fg-5); font-size: 14px; transition: color .25s, transform .25s; }

.hub-foot {
  padding: 80px 0 60px;
  border-top: 1px solid var(--hub-fg-9);
  margin-top: 56px;
  font-family: var(--hub-font-mono);
  font-size: 11px; letter-spacing: .15em; text-transform: uppercase;
  color: var(--hub-fg-5);
  display: flex; justify-content: space-between; flex-wrap: wrap; gap: 20px;
}
.hub-foot a:hover { color: var(--hub-gold); }

@media (max-width: 760px) {
  .wrap { padding: 0 16px; }
  header.hub-head { padding: 18px 0 14px; }
  h1.hub-title { font-size: 24px !important; }
  .head-meta .z3-home { font-size: 22px; }
  .hub-foot { flex-direction: column; align-items: flex-start; padding: 32px 0 30px; }
}
