/* LayarGenggam — dark gaming theme, no framework */
:root {
  --bg: #0b0f14;
  --surface: #11161d;
  --surface-2: #161d26;
  --border: #1e2630;
  --text: #e6edf3;
  --muted: #8b98a5;
  --accent: #a3e635;
  --accent-dim: #84cc16;
  --accent-ink: #0b0f14;
  --radius: 14px;
  --font-head: "Space Grotesk", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-body: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
}

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

.container { max-width: 1080px; margin: 0 auto; padding: 0 20px; }

/* ---------- header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: rgba(11, 15, 20, 0.92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border);
}
.header-inner {
  display: flex;
  align-items: center;
  gap: 24px;
  min-height: 60px;
  flex-wrap: wrap;
  padding-top: 8px;
  padding-bottom: 8px;
}
.logo {
  font-family: var(--font-head);
  font-size: 22px;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.5px;
  white-space: nowrap;
}
.logo:hover { text-decoration: none; }
.logo-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  margin-right: 8px;
  border-radius: 8px;
  background: var(--accent);
  color: var(--accent-ink);
  font-size: 18px;
  vertical-align: -6px;
}
.logo-accent { color: var(--accent); }
.site-nav { display: flex; gap: 18px; }
.site-nav a { color: var(--muted); font-weight: 500; font-size: 15px; }
.site-nav a:hover, .site-nav a.active { color: var(--text); text-decoration: none; }
.header-search { margin-left: auto; }
.header-search input {
  width: 230px;
  max-width: 100%;
  padding: 8px 12px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface);
  color: var(--text);
  font: inherit;
  font-size: 14px;
  outline: none;
}
.header-search input:focus { border-color: var(--accent); }

/* ---------- hero ---------- */
.hero { margin: 28px 0 8px; }
.hero-link {
  display: block;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--text);
}
.hero-link:hover { text-decoration: none; border-color: var(--accent-dim); }
.hero-cover {
  height: 220px;
  display: flex;
  align-items: flex-end;
  padding: 20px 24px;
  font-family: var(--font-head);
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.92);
}
.hero-body { padding: 20px 24px 24px; }
.hero-body h1 {
  margin: 10px 0 8px;
  font-family: var(--font-head);
  font-size: 28px;
  line-height: 1.25;
  letter-spacing: -0.5px;
}
.hero-body p { margin: 0; color: var(--muted); }
.hero-meta { display: block; margin-top: 14px; font-size: 13px; color: var(--muted); }

.badge {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 999px;
  background: var(--accent);
  color: var(--accent-ink);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.4px;
}

/* ---------- toolbar / chips ---------- */
.toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  margin: 22px 0 18px;
}
.chips { display: flex; gap: 8px; flex-wrap: wrap; }
.chip {
  padding: 7px 14px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface);
  color: var(--muted);
  font: inherit;
  font-size: 14px;
  cursor: pointer;
}
.chip:hover { color: var(--text); border-color: var(--accent-dim); }
.chip.active { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); font-weight: 600; }
.result-count { margin: 0; font-size: 14px; color: var(--muted); }

/* ---------- grid / cards ---------- */
.grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  margin-bottom: 40px;
}
.card {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--text);
}
.card:hover { text-decoration: none; border-color: var(--accent-dim); }
.card-cover {
  height: 132px;
  display: flex;
  align-items: flex-end;
  padding: 12px 16px;
  font-family: var(--font-head);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.92);
}
.card-body { display: flex; flex-direction: column; gap: 8px; padding: 16px 16px 18px; flex: 1; }
.card-body h2, .card-body h3 {
  margin: 0;
  font-family: var(--font-head);
  font-size: 18px;
  line-height: 1.35;
  letter-spacing: -0.3px;
}
.card-body p { margin: 0; color: var(--muted); font-size: 14px; flex: 1; }
.card-meta { font-size: 13px; color: var(--muted); }
.card .badge { align-self: flex-start; }

/* cover gradients, dipilih dari nama game */
.cover-0 { background: linear-gradient(135deg, #166534, #4ade80); }
.cover-1 { background: linear-gradient(135deg, #7c2d12, #f97316); }
.cover-2 { background: linear-gradient(135deg, #1e3a8a, #38bdf8); }
.cover-3 { background: linear-gradient(135deg, #581c87, #e879f9); }
.cover-4 { background: linear-gradient(135deg, #991b1b, #f43f5e); }
.cover-5 { background: linear-gradient(135deg, #134e4a, #2dd4bf); }

.empty-state { color: var(--muted); text-align: center; padding: 40px 0; }

/* ---------- article page ---------- */
.article { max-width: 760px; margin: 0 auto; padding-top: 28px; }
.breadcrumb { font-size: 14px; color: var(--muted); }
.breadcrumb a { color: var(--muted); }
.article-cover {
  height: 200px;
  border-radius: var(--radius);
  display: flex;
  align-items: flex-end;
  padding: 18px 22px;
  font-family: var(--font-head);
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.92);
  margin: 18px 0 0;
}
.article-title {
  font-family: var(--font-head);
  font-size: 34px;
  line-height: 1.2;
  letter-spacing: -0.8px;
  margin: 18px 0 10px;
}
.article-meta { color: var(--muted); font-size: 14px; margin: 0 0 8px; }
.article-body { font-size: 17px; }
.article-body h2 {
  font-family: var(--font-head);
  font-size: 24px;
  margin: 32px 0 10px;
  letter-spacing: -0.4px;
}
.article-body h3 { font-family: var(--font-head); font-size: 19px; margin: 26px 0 8px; }
.article-body p { margin: 0 0 16px; }
.article-body ul, .article-body ol { margin: 0 0 16px; padding-left: 24px; }
.article-body li { margin-bottom: 6px; }
.article-body li::marker { color: var(--accent); }
.article-body blockquote {
  margin: 0 0 16px;
  padding: 12px 18px;
  border-left: 3px solid var(--accent);
  background: var(--surface);
  border-radius: 0 10px 10px 0;
  color: var(--muted);
}
.article-body code {
  padding: 2px 6px;
  border-radius: 6px;
  background: var(--surface-2);
  font-size: 0.9em;
}
.article-body pre {
  padding: 14px 16px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--surface);
  overflow-x: auto;
}
.article-body pre code { padding: 0; background: none; }
.article-body img { max-width: 100%; border-radius: 10px; }
.article-body hr { border: none; border-top: 1px solid var(--border); margin: 28px 0; }
.article-tags { display: flex; gap: 8px; flex-wrap: wrap; margin: 28px 0 8px; }
.tag {
  padding: 4px 12px;
  border: 1px solid var(--border);
  border-radius: 999px;
  font-size: 13px;
  color: var(--muted);
}

.related { margin: 48px 0 40px; }
.related h2 { font-family: var(--font-head); font-size: 22px; margin: 0 0 16px; }

/* ---------- footer ---------- */
.site-footer {
  border-top: 1px solid var(--border);
  padding: 28px 0 36px;
  color: var(--muted);
  font-size: 14px;
}
.footer-inner p { margin: 4px 0; }
.footer-note { font-size: 13px; }

/* ---------- responsive ---------- */
@media (max-width: 860px) {
  .grid { grid-template-columns: repeat(2, 1fr); }
  .header-search { order: 3; width: 100%; }
  .header-search input { width: 100%; }
}
@media (max-width: 560px) {
  .grid { grid-template-columns: 1fr; }
  .hero-body h1 { font-size: 23px; }
  .article-title { font-size: 27px; }
  .hero-cover { height: 160px; }
}

/* ---------- cover foto ---------- */
.card-cover, .hero-cover, .article-cover { position: relative; overflow: hidden; }
.cover-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.cover-label { position: relative; z-index: 1; text-shadow: 0 1px 8px rgba(0, 0, 0, 0.85); }
.has-photo::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 55%;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.6), rgba(0, 0, 0, 0));
  z-index: 0;
}
