:root {
  --bg: #080810;
  --panel: #11111f;
  --panel-2: #171726;
  --line: rgba(255, 255, 255, 0.1);
  --text: #f7f2e8;
  --muted: #a8b1c7;
  --gold: #f4c76b;
  --orange: #ff6a2a;
  --cyan: #49e0ff;
  --green: #62ffb1;
  --danger: #ff4f6d;
  --shadow: 0 22px 70px rgba(0, 0, 0, 0.35);
}

* { box-sizing: border-box; }

html { background: var(--bg); }

body {
  margin: 0;
  min-height: 100vh;
  color: var(--text);
  font-family: "Rajdhani", Arial, sans-serif;
  background:
    radial-gradient(circle at 20% 0%, rgba(255, 106, 42, 0.16), transparent 34rem),
    radial-gradient(circle at 80% 10%, rgba(73, 224, 255, 0.12), transparent 28rem),
    linear-gradient(180deg, #080810 0%, #0b0b16 48%, #080810 100%);
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background-image: linear-gradient(rgba(255,255,255,0.035) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,0.035) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: linear-gradient(to bottom, rgba(0,0,0,0.65), transparent 70%);
}

a { color: inherit; text-decoration: none; }

button, input, select, textarea { font: inherit; }

button, select, a { cursor: pointer; }

img { max-width: 100%; display: block; }

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: grid;
  grid-template-columns: auto minmax(240px, 640px) auto;
  gap: 18px;
  align-items: center;
  padding: 14px 24px;
  border-bottom: 1px solid var(--line);
  background: rgba(8, 8, 16, 0.88);
  backdrop-filter: blur(16px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: "Orbitron", sans-serif;
  font-size: 21px;
  font-weight: 800;
}

.brand span {
  width: 13px;
  height: 13px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--orange), var(--cyan));
  box-shadow: 0 0 24px rgba(255, 106, 42, 0.8);
}

.topbar input, .topbar select, .filter-bar input, .filter-bar select, .comments input, .comments textarea {
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--text);
  background: rgba(255, 255, 255, 0.07);
  outline: none;
}
.topbar select, .topbar select option { background: #171726; color: var(--text); }

.topbar input { width: 100%; padding: 12px 18px; }
.topbar select { padding: 10px 14px; }

.shell {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  min-height: calc(100vh - 70px);
}

.shell.no-sidebar { grid-template-columns: 1fr; }

.sidebar {
  position: sticky;
  top: 70px;
  align-self: start;
  height: calc(100vh - 70px);
  padding: 24px 18px;
  border-right: 1px solid var(--line);
  background: rgba(9, 9, 19, 0.72);
  overflow: auto;
}

.main-nav {
  display: grid;
  gap: 8px;
  margin-bottom: 28px;
}

.main-nav a, .category-pill {
  border: 1px solid transparent;
  border-radius: 8px;
  padding: 12px 14px;
  color: var(--muted);
  background: transparent;
  text-align: left;
}

.main-nav a:hover, .main-nav a.active, .category-pill:hover, .category-pill.active {
  color: var(--text);
  border-color: rgba(244, 199, 107, 0.28);
  background: linear-gradient(135deg, rgba(255, 106, 42, 0.18), rgba(73, 224, 255, 0.08));
}

.sidebar h2 {
  margin: 0 0 14px;
  color: var(--orange);
  font-size: 16px;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.quick-links, .category-list { display: grid; gap: 10px; }

.mini-guide {
  display: grid;
  grid-template-columns: 72px 1fr;
  align-items: center;
  gap: 10px;
  border-radius: 8px;
  padding: 8px;
  color: var(--muted);
  border: 1px solid rgba(255, 255, 255, 0.06);
  background: rgba(255, 255, 255, 0.04);
}

.mini-guide:hover, .mini-guide.active { color: var(--text); border-color: rgba(255, 106, 42, 0.55); }
.mini-guide img { height: 42px; width: 72px; object-fit: cover; border-radius: 6px; }

main { min-width: 0; padding: 0 0 48px; }

.hero {
  min-height: 520px;
  display: grid;
  align-content: center;
  padding: 72px clamp(24px, 6vw, 86px);
  border-bottom: 1px solid var(--line);
  background:
    linear-gradient(rgba(8,8,16,0.42), rgba(8,8,16,0.92)),
    url("https://images.unsplash.com/photo-1542751110-97427bbecf20?auto=format&fit=crop&w=1920&q=80") center/cover;
}

.eyebrow {
  margin: 0 0 12px;
  color: var(--cyan);
  font-family: "Orbitron", sans-serif;
  text-transform: uppercase;
  font-size: 12px;
  letter-spacing: 1.5px;
}

h1, h2, h3 { font-family: "Orbitron", sans-serif; line-height: 1.08; }

.hero h1, .stacked-title h1 {
  margin: 0;
  max-width: 780px;
  font-size: clamp(44px, 7vw, 88px);
}

.hero p:not(.eyebrow) {
  max-width: 660px;
  color: var(--muted);
  font-size: 22px;
}

.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; }

.primary-btn, .ghost-btn, .share-row button, .comments button, .pager button, .load-more {
  min-height: 44px;
  border: 1px solid transparent;
  border-radius: 8px;
  padding: 11px 18px;
  color: #120b07;
  font-weight: 800;
  background: linear-gradient(135deg, var(--gold), var(--orange));
  box-shadow: 0 12px 30px rgba(255, 106, 42, 0.22);
}

.ghost-btn, .pager button {
  color: var(--text);
  border-color: rgba(255,255,255,0.14);
  background: rgba(255,255,255,0.08);
  box-shadow: none;
}

.primary-btn:hover, .ghost-btn:hover, button:hover { transform: translateY(-1px); }

.content-band {
  padding: 48px clamp(20px, 5vw, 64px);
  border-bottom: 1px solid var(--line);
}

.section-title {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: end;
  margin-bottom: 24px;
}

.section-title h2, .section-title h1 { margin: 0; }
.section-title a, .text-link { color: var(--orange); font-weight: 800; }
.stacked-title { display: block; }

.horizontal-guides {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(250px, 310px);
  gap: 18px;
  overflow-x: auto;
  padding-bottom: 16px;
  scrollbar-color: var(--orange) rgba(255,255,255,0.08);
}

.guide-grid, .games-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 18px;
}

.guide-card, .game-card {
  min-width: 0;
  overflow: hidden;
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 8px;
  background: linear-gradient(180deg, rgba(255,255,255,0.08), rgba(255,255,255,0.035));
  box-shadow: var(--shadow);
  transition: transform 0.18s ease, border-color 0.18s ease;
}

.guide-card:hover, .game-card:hover { transform: translateY(-4px); border-color: rgba(255,106,42,0.75); }
.guide-card img { width: 100%; height: 140px; object-fit: cover; }
.guide-card-body { padding: 16px; }
.card-meta { display: flex; justify-content: space-between; gap: 8px; color: var(--cyan); font-size: 13px; }
.guide-card h3 { margin: 10px 0 6px; font-size: 22px; }
.guide-card p { margin: 0 0 12px; color: var(--muted); }
.rating { color: var(--gold); font-weight: 800; }

.recommended-list { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 14px; }
.split-band { display: grid; grid-template-columns: minmax(240px, 0.8fr) 1.2fr; gap: 32px; align-items: start; }

.filter-bar { display: flex; gap: 12px; flex-wrap: wrap; margin-bottom: 24px; }
.filter-bar input, .filter-bar select { min-height: 44px; padding: 10px 14px; min-width: 220px; }
.filter-bar input { flex: 1; }

.pager { display: flex; align-items: center; justify-content: center; gap: 16px; margin-top: 26px; }
.pager button:disabled { opacity: 0.45; cursor: not-allowed; }
.hot-fill { margin-top: 34px; padding: 22px; border: 1px solid var(--line); border-radius: 8px; background: rgba(255,255,255,0.045); }
.hot-fill p { color: var(--muted); }

.detail-poster {
  width: 100%;
  max-height: 560px;
  object-fit: cover;
  border-radius: 8px;
  border: 1px solid rgba(255,255,255,0.12);
  box-shadow: var(--shadow);
}

.back-link { display: inline-block; margin-bottom: 18px; color: var(--orange); font-weight: 800; }
.detail-header { padding: 28px 0 12px; }
.detail-header h1 { margin: 0; font-size: clamp(36px, 5vw, 64px); }
.detail-header p:not(.eyebrow) { max-width: 900px; color: var(--muted); font-size: 21px; }
.guide-detail section { margin-top: 34px; }
.guide-detail h2 { margin: 0 0 18px; }

.highlight-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(160px, 1fr));
  gap: 12px;
}
.highlight-grid img { aspect-ratio: 16 / 9; object-fit: cover; border-radius: 8px; border: 1px solid var(--line); }
.tactic-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 16px; }
.tactic-card { display: grid; gap: 12px; border: 1px solid var(--line); border-radius: 8px; overflow: hidden; background: rgba(255,255,255,0.05); }
.tactic-card img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; }
.tactic-card div { padding: 0 16px 16px; }
.tactic-card h3 { margin: 0 0 8px; color: var(--gold); }
.tactic-card p { margin: 0; color: var(--muted); line-height: 1.5; }


.prose { max-width: 1020px; }
.prose p, .prose li, details { color: var(--muted); font-size: 18px; line-height: 1.62; }
.pattern-list, .build-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 14px; }
.pattern-card, .build-grid p, details, .comments, .game-player {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 18px;
  background: rgba(255,255,255,0.05);
}
.pattern-card h3 { margin-top: 0; color: var(--gold); }
details summary { color: var(--text); cursor: pointer; font-weight: 800; }

.share-row { display: flex; gap: 12px; flex-wrap: wrap; }
.comments form { display: grid; gap: 12px; margin-bottom: 16px; }
.comments input, .comments textarea { padding: 12px; }
.comments textarea { min-height: 110px; resize: vertical; }
.comment-list { display: grid; gap: 10px; }
.comment-list p { margin: 0; padding: 12px; border-radius: 8px; background: rgba(255,255,255,0.04); }

.game-player { min-height: 220px; margin-bottom: 24px; display: grid; place-items: center; color: var(--muted); overflow: hidden; }
.game-player iframe { width: 100%; min-height: 520px; border: 0; border-radius: 8px; background: #fff; }
.game-ad-slot { width: 100%; min-height: 54px; display: grid; place-items: center; margin-bottom: 12px; border: 1px dashed rgba(244,199,107,0.35); border-radius: 8px; color: var(--gold); background: rgba(244,199,107,0.06); font-weight: 800; }
.player-header { width: 100%; display: flex; justify-content: space-between; margin-bottom: 12px; color: var(--text); }
.player-header a { color: var(--orange); }
.launch-panel { display: grid; gap: 14px; place-items: start; max-width: 720px; padding: 24px; }
.launch-panel h2 { margin: 0; }
.launch-panel p { margin: 0; color: var(--muted); font-size: 18px; line-height: 1.5; }

.game-card {
  display: grid;
  grid-template-rows: 148px auto auto;
  min-height: 248px;
  width: 100%;
  padding: 0;
  text-align: left;
  color: var(--text);
}
.game-card img { width: 100%; height: 148px; object-fit: cover; }
.game-card span { padding: 12px 14px 2px; font-weight: 800; font-size: 18px; line-height: 1.15; overflow-wrap: anywhere; }
.game-card small { padding: 0 14px 14px; color: var(--muted); align-self: end; }
.load-more { margin: 28px auto 0; display: block; }

@media (max-width: 980px) {
  .topbar { grid-template-columns: 1fr; }
  .shell { grid-template-columns: 1fr; }
  .sidebar { position: static; height: auto; border-right: 0; border-bottom: 1px solid var(--line); }
  .main-nav { grid-template-columns: repeat(3, 1fr); }
  .sidebar { padding: 14px; }
  .category-list { grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); }
  .guide-grid, .games-grid { grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); }
  .game-card { min-height: 220px; }
  .game-card img { height: 124px; }
  .quick-links { grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); }
  .hero { min-height: 440px; }
  .split-band { grid-template-columns: 1fr; }
  .highlight-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 560px) {
  .topbar { padding: 12px; }
  .brand { font-size: 18px; }
  .topbar input, .topbar select { width: 100%; min-width: 0; }
  .shell { display: block; }
  .content-band { padding-top: 28px; }
  .guide-grid, .games-grid { grid-template-columns: 1fr; }
  .share-row button { width: 100%; }
  .game-player iframe { min-height: 360px; }
  .content-band, .hero { padding-left: 16px; padding-right: 16px; }
  .main-nav { grid-template-columns: 1fr; }
  .hero h1, .stacked-title h1 { font-size: 38px; }
  .filter-bar { display: grid; }
  .filter-bar input, .filter-bar select { min-width: 0; width: 100%; }
  .highlight-grid { grid-template-columns: 1fr; }
}
