/* Hexgrid Games — shared styles
   Brand colours come from the studio logo (Hexo TD splash, Tools/artgen/artgen.py):
   cyan #00E5FF, blue #2679FF on #0D1318, wordmark grey #5E6B7A.
   Text colours follow the Neon Sort creatives: #E8F4FF and #9ABBE8. */
:root {
  --bg: #0d1318;
  --bg-2: #111a21;
  --card: #15202a;
  --line: rgba(0, 229, 255, 0.12);
  --text: #e8f4ff;
  --muted: #9abbe8;
  --dim: #5e6b7a;
  --cyan: #00e5ff;
  --blue: #2679ff;
  --radius: 16px;
  --max: 1080px;
}

* { box-sizing: border-box; min-width: 0; }

html { scroll-behavior: smooth; scroll-padding-top: 72px; }

body {
  margin: 0;
  font-family: "Nunito", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  overflow-x: clip;
}

/* Faint flat-top hex grid behind the page, like the logo's backdrop */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  opacity: 0.5;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='54' height='63' viewBox='0 0 54 63'%3E%3Cg fill='none' stroke='%231c4a52' stroke-width='1'%3E%3Cpath d='M9 0h18l9 15.75L27 31.5H9L0 15.75zM36 15.75h18M9 31.5 0 47.25 9 63M27 31.5l9 15.75L27 63M36 47.25h18'/%3E%3C/g%3E%3C/svg%3E");
  background-size: 54px 63px;
  -webkit-mask-image: radial-gradient(ellipse at 50% 20%, #000 0%, transparent 75%);
  mask-image: radial-gradient(ellipse at 50% 20%, #000 0%, transparent 75%);
}

a { color: var(--cyan); }

.wrap { max-width: var(--max); margin: 0 auto; padding: 0 20px; }

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: rgba(13, 19, 24, 0.88);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}
.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  height: 64px;
}
.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--text);
  text-decoration: none;
  font-weight: 800;
  letter-spacing: 0.18em;
  font-size: 0.95rem;
  white-space: nowrap;
}
.logo img { height: 30px; width: auto; }
.logo .c { color: var(--cyan); }
.logo .b { color: var(--blue); }
.nav { display: flex; align-items: center; gap: 22px; }
.nav a {
  color: var(--muted);
  text-decoration: none;
  font-weight: 700;
}
.nav a:hover, .nav a[aria-current="page"] { color: var(--text); }
.nav .ig { display: inline-flex; }
.nav .ig svg { width: 22px; height: 22px; }

/* Hero */
.hero { padding: 56px 0 40px; text-align: center; }
.hero-logo {
  width: min(260px, 60vw);
  height: auto;
  display: block;
  margin: 0 auto 20px;
}
.hero h1 {
  font-size: clamp(1.8rem, 5vw, 2.8rem);
  line-height: 1.1;
  margin: 0 0 12px;
  text-wrap: balance;
}
.hero p {
  color: var(--muted);
  font-size: 1.1rem;
  max-width: 560px;
  margin: 0 auto 28px;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 48px;
  padding: 12px 26px;
  border-radius: 999px;
  font-weight: 800;
  text-decoration: none;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.btn:hover { transform: translateY(-2px); }
.btn-primary {
  background: linear-gradient(90deg, var(--cyan), var(--blue));
  color: #06121a;
  box-shadow: 0 0 24px rgba(0, 229, 255, 0.35);
}
.btn-ghost {
  border: 2px solid rgba(0, 229, 255, 0.35);
  color: var(--text);
}
.btn svg { width: 20px; height: 20px; flex: none; }

/* Sections */
section { padding: 48px 0; }
.section-title { font-size: 1.8rem; margin: 0 0 6px; }
.section-sub { color: var(--muted); margin: 0 0 28px; }
.eyebrow {
  display: inline-block;
  color: var(--cyan);
  font-weight: 800;
  font-size: 0.9rem;
  margin-bottom: 8px;
}

/* Featured game */
.featured {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr);
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
}
.featured img.art {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  aspect-ratio: 1024 / 500;
}
.featured .body { padding: 28px; display: flex; flex-direction: column; gap: 12px; justify-content: center; }
.featured h3 { margin: 0; font-size: 1.6rem; line-height: 1.15; }
.featured p { margin: 0; color: var(--muted); }
.featured ul { margin: 0; padding-left: 1.1em; color: var(--muted); }
.featured .btn { align-self: flex-start; margin-top: 6px; }

/* Game cards */
.games {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 280px), 1fr));
  gap: 24px;
}
.game-card {
  background: var(--card);
  border-radius: var(--radius);
  border: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 0 0 24px;
  overflow: hidden;
}
.game-card > :not(.shot) { margin-inline: 24px; }
.game-card .shot {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  object-position: top;
  display: block;
  border-bottom: 1px solid var(--line);
}
.game-head { display: flex; align-items: center; gap: 14px; }
.game-card .icon {
  width: 64px;
  height: 64px;
  flex: none;
  border-radius: 16px;
  margin-top: -40px;
  border: 3px solid var(--card);
  background: var(--card);
}
.game-card h3 { margin: 0; font-size: 1.15rem; line-height: 1.25; }
.tag { color: var(--cyan); font-size: 0.85rem; font-weight: 700; }
.game-card p { margin: 0; color: var(--muted); flex: 1; }
.game-card .btn { align-self: flex-start; }

/* About / contact page */
.page-head { padding: 64px 0 16px; }
.page-head h1 { font-size: clamp(2rem, 5vw, 3rem); margin: 0 0 12px; }
.page-head p { color: var(--muted); font-size: 1.1rem; max-width: 640px; margin: 0; }

.panels {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr));
  gap: 24px;
}
.panel {
  background: var(--card);
  border-radius: var(--radius);
  padding: 28px;
  border: 1px solid var(--line);
}
.panel h2 { margin-top: 0; font-size: 1.3rem; }
.panel p { color: var(--muted); }
.panel .btn { margin: 4px 8px 4px 0; }
.panel .logo-panel { width: 200px; height: auto; display: block; margin: 8px 0 0; }

/* Footer */
.site-footer {
  border-top: 1px solid var(--line);
  padding: 28px 0;
  color: var(--dim);
  font-size: 0.9rem;
  margin-top: 24px;
}
.site-footer .wrap {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}
.site-footer a { color: var(--muted); margin-left: 16px; }

@media (max-width: 760px) {
  .featured { grid-template-columns: 1fr; }
}

@media (max-width: 560px) {
  .logo span.word { display: none; }
  .nav { gap: 16px; }
  .nav a { font-size: 0.95rem; }
  .hero { padding: 40px 0 24px; }
  .featured .body { padding: 22px; }
  .site-footer a { margin: 0 16px 0 0; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .btn { transition: none; }
  .btn:hover { transform: none; }
}
