/* ==========================================================================
   8bitLoft - Shared Stylesheet
   Extracted from delta-template.html + homepage grid + utilities
   ========================================================================== */

/* ==========================================================================
   1. CSS Variables (Design Tokens)
   ========================================================================== */
:root {
  /* Colors - Backgrounds */
  --bg: #0A0E1A;
  --surface: #131827;
  --surface-2: #1A2235;
  --surface-3: #232D45;

  /* Colors - Borders */
  --border: rgba(255, 255, 255, 0.08);
  --border-strong: rgba(255, 255, 255, 0.14);

  /* Colors - Text */
  --text: #E8ECF4;
  --text-muted: #8893B0;
  --text-dim: #5A6585;

  /* Colors - Accents */
  --mint: #00E5A0;
  --mint-glow: rgba(0, 229, 160, 0.25);
  --coral: #FF4D7E;
  --coral-glow: rgba(255, 77, 126, 0.35);
  --amber: #FFB547;
  --purple: #A78BFA;

  /* Category accent colors */
  --cat-games: #00E5A0;
  --cat-saves: #FFB547;
  --cat-hacks: #FF4D7E;
  --cat-guides: #A78BFA;
  --cat-skins: #00B8E5;
  --cat-cheats: #E63946;

  /* Radii */
  --radius: 16px;
  --radius-sm: 10px;
  --radius-lg: 24px;

  /* Shadows */
  --shadow-sm: 0 4px 12px rgba(0, 0, 0, 0.15);
  --shadow-md: 0 10px 30px rgba(0, 0, 0, 0.25);
  --shadow-lg: 0 20px 60px rgba(0, 0, 0, 0.35);

  /* Transitions */
  --t-fast: 0.15s;
  --t-med: 0.25s;
  --t-slow: 0.4s;
}

/* ==========================================================================
   2. Reset
   ========================================================================== */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, system-ui, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.5;
  min-height: 100vh;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  padding-bottom: env(safe-area-inset-bottom);
}

/* Ambient background glow */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  background:
    radial-gradient(ellipse 600px 400px at 80% -10%, rgba(0, 229, 160, 0.12), transparent),
    radial-gradient(ellipse 500px 300px at 0% 30%, rgba(255, 77, 126, 0.08), transparent);
  pointer-events: none;
  z-index: 0;
}

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

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

button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  background: none;
  color: inherit;
}

input,
textarea,
select {
  font-family: inherit;
  color: inherit;
}

/* ==========================================================================
   3. Topbar
   ========================================================================== */
.topbar {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(10, 14, 26, 0.85);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid var(--border);
  padding: env(safe-area-inset-top) 16px 0;
}

.topbar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 56px;
  max-width: 1200px;
  margin: 0 auto;
}

.logo {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: 'Bricolage Grotesque', sans-serif;
  font-weight: 800;
  font-size: 18px;
  letter-spacing: -0.02em;
}

.logo-mark {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  background: linear-gradient(135deg, var(--mint), #00B8E5);
  display: grid;
  place-items: center;
  font-weight: 800;
  color: #001A12;
  font-size: 14px;
  box-shadow: 0 4px 12px var(--mint-glow);
}

.topbar-actions {
  display: flex;
  gap: 8px;
}

.icon-btn {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  background: var(--surface);
  border: 1px solid var(--border);
  display: grid;
  place-items: center;
  transition: all var(--t-med);
}

.icon-btn:hover {
  background: var(--surface-2);
  border-color: var(--border-strong);
}

.icon-btn svg {
  width: 18px;
  height: 18px;
}

/* ==========================================================================
   4. Main / Layout
   ========================================================================== */
main {
  position: relative;
  z-index: 1;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 16px 80px;
}

@media (min-width: 768px) {
  main {
    padding: 0 24px 100px;
  }
}

/* ==========================================================================
   5. Hero (game/save/hack pages)
   ========================================================================== */
.hero {
  padding: 24px 0 32px;
  position: relative;
}

.hero-cover-bg {
  position: absolute;
  inset: 0;
  border-radius: var(--radius-lg);
  opacity: 0.4;
  filter: blur(60px);
  transform: translateY(-20px);
  z-index: -1;
}

.hero-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 20px;
}

.cover {
  width: 180px;
  height: 180px;
  border-radius: 24px;
  display: grid;
  place-items: center;
  position: relative;
  box-shadow:
    var(--shadow-lg),
    0 0 0 1px rgba(255, 255, 255, 0.1) inset,
    0 -2px 0 rgba(0, 0, 0, 0.2) inset;
  overflow: hidden;
  animation: float 6s ease-in-out infinite;
}

.cover::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 30% 20%, rgba(255, 255, 255, 0.3), transparent 50%),
    repeating-linear-gradient(45deg, transparent 0 10px, rgba(0, 0, 0, 0.05) 10px 20px);
}

.cover-label {
  font-family: 'Bricolage Grotesque', sans-serif;
  font-weight: 800;
  font-size: 26px;
  letter-spacing: -0.03em;
  color: #fff;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
  position: relative;
  line-height: 1;
  text-align: center;
  padding: 0 10px;
}

.cover-pokeball {
  position: absolute;
  bottom: 16px;
  right: 16px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: linear-gradient(
    to bottom,
    #fff 0%,
    #fff 45%,
    #1a1a1a 45%,
    #1a1a1a 55%,
    #C1272D 55%,
    #C1272D 100%
  );
  border: 2px solid #1a1a1a;
}

.cover-pokeball::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 10px;
  height: 10px;
  background: #fff;
  border: 2px solid #1a1a1a;
  border-radius: 50%;
  transform: translate(-50%, -50%);
}

.hero-info {
  max-width: 480px;
}

.console-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--surface-2);
  border: 1px solid var(--border-strong);
  color: var(--mint);
  font-family: 'Pixelify Sans', monospace;
  font-weight: 700;
  font-size: 12px;
  padding: 6px 12px;
  border-radius: 999px;
  margin-bottom: 14px;
  letter-spacing: 0.05em;
}

.console-badge::before {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--mint);
  box-shadow: 0 0 8px var(--mint);
}

h1.title {
  font-family: 'Bricolage Grotesque', sans-serif;
  font-weight: 800;
  font-size: 32px;
  line-height: 1.05;
  letter-spacing: -0.03em;
  margin-bottom: 8px;
}

.subtitle {
  color: var(--text-muted);
  font-size: 15px;
  margin-bottom: 16px;
}

.meta-row {
  display: flex;
  justify-content: center;
  gap: 20px;
  flex-wrap: wrap;
  margin-bottom: 24px;
  font-size: 13px;
  color: var(--text-muted);
}

.meta-item {
  display: flex;
  align-items: center;
  gap: 6px;
}

.rating-stars {
  color: var(--amber);
  letter-spacing: 1px;
}

/* ==========================================================================
   6. Buttons / CTAs
   ========================================================================== */
.cta-group {
  display: flex;
  flex-direction: column;
  gap: 10px;
  width: 100%;
  max-width: 380px;
}

.btn-primary {
  background: linear-gradient(135deg, var(--coral), #E03060);
  color: #fff;
  font-weight: 700;
  font-size: 16px;
  padding: 16px 24px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  box-shadow:
    0 10px 30px var(--coral-glow),
    0 0 0 1px rgba(255, 255, 255, 0.1) inset;
  transition: transform var(--t-fast), box-shadow var(--t-fast);
  position: relative;
  overflow: hidden;
}

.btn-primary::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
  transform: translateX(-100%);
  transition: transform 0.6s;
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow:
    0 15px 35px var(--coral-glow),
    0 0 0 1px rgba(255, 255, 255, 0.15) inset;
}

.btn-primary:hover::before {
  transform: translateX(100%);
}

.btn-primary:active {
  transform: translateY(0);
}

.btn-secondary {
  background: var(--surface-2);
  border: 1px solid var(--border-strong);
  color: var(--text);
  font-weight: 600;
  font-size: 14px;
  padding: 12px 20px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: all var(--t-med);
}

.btn-secondary:hover {
  background: var(--surface-3);
}

/* ==========================================================================
   7. Stats Strip
   ========================================================================== */
.stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  margin: 0 0 32px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
}

@media (max-width: 480px) {
  .stats {
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
  }
}

.stat {
  text-align: center;
  border-right: 1px solid var(--border);
  padding: 0 8px;
}

.stat:last-child {
  border-right: none;
}

@media (max-width: 480px) {
  .stat:nth-child(2n) {
    border-right: none;
  }
}

.stat-value {
  font-family: 'Bricolage Grotesque', sans-serif;
  font-weight: 700;
  font-size: 18px;
  color: var(--text);
  margin-bottom: 2px;
}

.stat-label {
  font-size: 11px;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-weight: 600;
}

/* ==========================================================================
   8. Section blocks
   ========================================================================== */
section.block {
  margin-bottom: 32px;
}

.section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}

.section-title {
  font-family: 'Bricolage Grotesque', sans-serif;
  font-weight: 700;
  font-size: 20px;
  letter-spacing: -0.02em;
  display: flex;
  align-items: center;
  gap: 10px;
}

.section-title-icon {
  width: 32px;
  height: 32px;
  border-radius: 10px;
  display: grid;
  place-items: center;
  background: var(--surface-2);
  border: 1px solid var(--border);
}

.section-link {
  font-size: 13px;
  color: var(--mint);
  font-weight: 600;
}

.prose {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  font-size: 15px;
  color: var(--text-muted);
  line-height: 1.6;
}

.prose p + p {
  margin-top: 12px;
}

.prose strong {
  color: var(--text);
}

/* ==========================================================================
   9. Screenshots carousel
   ========================================================================== */
.screenshots {
  display: flex;
  gap: 12px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  padding-bottom: 8px;
  margin: 0 -16px;
  padding-left: 16px;
  padding-right: 16px;
  scrollbar-width: none;
}

.screenshots::-webkit-scrollbar {
  display: none;
}

.screenshot {
  flex: 0 0 auto;
  width: 180px;
  height: 240px;
  border-radius: 14px;
  overflow: hidden;
  scroll-snap-align: start;
  position: relative;
  border: 1px solid var(--border);
}

.screenshot-frame {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  font-family: 'Pixelify Sans', monospace;
  color: rgba(255, 255, 255, 0.4);
  font-size: 11px;
  text-align: center;
  padding: 10px;
}

/* ==========================================================================
   10. Save file cards
   ========================================================================== */
.save-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}

@media (min-width: 600px) {
  .save-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

.save-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
  display: flex;
  gap: 14px;
  align-items: center;
  transition: all var(--t-med);
  position: relative;
  overflow: hidden;
}

.save-card:hover {
  border-color: var(--mint);
  transform: translateY(-2px);
  box-shadow: 0 10px 30px rgba(0, 229, 160, 0.1);
}

.save-card::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 3px;
  background: var(--mint);
  opacity: 0;
  transition: opacity var(--t-med);
}

.save-card:hover::before {
  opacity: 1;
}

.save-icon {
  flex-shrink: 0;
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: var(--surface-2);
  display: grid;
  place-items: center;
  font-size: 22px;
}

.save-icon.gold {
  background: linear-gradient(135deg, #FFD93D, #FFB547);
}

.save-icon.silver {
  background: linear-gradient(135deg, #C0CCE0, #8A9BB8);
}

.save-icon.shiny {
  background: linear-gradient(135deg, #FF6FB5, #A78BFA);
}

.save-icon.complete {
  background: linear-gradient(135deg, var(--mint), #00B8E5);
}

.save-body {
  flex: 1;
  min-width: 0;
}

.save-name {
  font-weight: 700;
  font-size: 14px;
  margin-bottom: 2px;
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.tag {
  font-family: 'Pixelify Sans', monospace;
  font-size: 10px;
  padding: 2px 6px;
  border-radius: 4px;
  background: var(--surface-3);
  color: var(--mint);
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.tag.hot {
  background: rgba(255, 77, 126, 0.15);
  color: var(--coral);
}

.save-meta {
  font-size: 12px;
  color: var(--text-dim);
  display: flex;
  gap: 10px;
}

.save-download {
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: var(--mint);
  color: #001A12;
  display: grid;
  place-items: center;
  transition: all var(--t-med);
}

.save-download:hover {
  background: #00FFB8;
  transform: scale(1.05);
}

.save-download svg {
  width: 18px;
  height: 18px;
}

/* ==========================================================================
   11. Steps (How to install)
   ========================================================================== */
.steps {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}

@media (min-width: 700px) {
  .steps {
    grid-template-columns: repeat(3, 1fr);
  }
}

.step {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  position: relative;
}

.step-num {
  font-family: 'Bricolage Grotesque', sans-serif;
  font-weight: 800;
  font-size: 32px;
  color: var(--mint);
  line-height: 1;
  margin-bottom: 12px;
  opacity: 0.9;
}

.step-title {
  font-weight: 700;
  font-size: 15px;
  margin-bottom: 6px;
}

.step-desc {
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.5;
}

/* ==========================================================================
   12. Cheats
   ========================================================================== */
.cheats {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}

.cheat-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 16px;
  border-bottom: 1px solid var(--border);
}

.cheat-row:last-child {
  border-bottom: none;
}

.cheat-name {
  font-weight: 600;
  font-size: 14px;
  margin-bottom: 2px;
}

.cheat-code {
  font-family: 'Pixelify Sans', monospace;
  font-size: 11px;
  color: var(--text-dim);
  letter-spacing: 0.05em;
}

.cheat-btn {
  font-size: 12px;
  color: var(--mint);
  font-weight: 700;
  padding: 6px 12px;
  border: 1px solid var(--mint);
  border-radius: 8px;
  transition: all var(--t-med);
}

.cheat-btn:hover {
  background: var(--mint);
  color: #001A12;
}

/* ==========================================================================
   13. Related games
   ========================================================================== */
.related {
  display: flex;
  gap: 12px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  padding-bottom: 8px;
  margin: 0 -16px;
  padding-left: 16px;
  padding-right: 16px;
  scrollbar-width: none;
}

.related::-webkit-scrollbar {
  display: none;
}

.related-card {
  flex: 0 0 auto;
  width: 130px;
  scroll-snap-align: start;
}

.related-cover {
  width: 130px;
  height: 130px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  font-family: 'Bricolage Grotesque', sans-serif;
  font-weight: 800;
  color: #fff;
  font-size: 14px;
  text-align: center;
  margin-bottom: 8px;
  text-shadow: 0 2px 6px rgba(0, 0, 0, 0.3);
  padding: 8px;
  line-height: 1.1;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
}

.related-name {
  font-weight: 600;
  font-size: 13px;
  margin-bottom: 2px;
  line-height: 1.2;
}

.related-meta {
  font-size: 11px;
  color: var(--text-dim);
  font-family: 'Pixelify Sans', monospace;
  letter-spacing: 0.05em;
}

/* ==========================================================================
   14. HOMEPAGE — Hero + filters + grid (index.html)
   ========================================================================== */
.home-hero {
  padding: 40px 0 24px;
  text-align: center;
}

.home-hero h1 {
  font-family: 'Bricolage Grotesque', sans-serif;
  font-weight: 800;
  font-size: 40px;
  line-height: 1.05;
  letter-spacing: -0.03em;
  margin-bottom: 12px;
  background: linear-gradient(135deg, var(--text), var(--mint));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

@media (min-width: 768px) {
  .home-hero h1 {
    font-size: 56px;
  }
}

.home-hero p {
  color: var(--text-muted);
  font-size: 16px;
  max-width: 600px;
  margin: 0 auto 24px;
}

.search-box {
  max-width: 500px;
  margin: 0 auto 32px;
  position: relative;
}

.search-box input {
  width: 100%;
  padding: 14px 16px 14px 44px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  color: var(--text);
  font-size: 15px;
  transition: all var(--t-med);
}

.search-box input:focus {
  outline: none;
  border-color: var(--mint);
  box-shadow: 0 0 0 4px var(--mint-glow);
}

.search-box svg {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  width: 20px;
  height: 20px;
  color: var(--text-dim);
}

.filter-chips {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding: 0 16px 12px;
  margin: 0 -16px 24px;
  scrollbar-width: none;
  justify-content: flex-start;
}

@media (min-width: 768px) {
  .filter-chips {
    justify-content: center;
  }
}

.filter-chips::-webkit-scrollbar {
  display: none;
}

.chip {
  flex-shrink: 0;
  padding: 8px 14px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 999px;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-muted);
  transition: all var(--t-med);
  white-space: nowrap;
}

.chip:hover {
  background: var(--surface-2);
  color: var(--text);
}

.chip.active {
  background: var(--mint);
  color: #001A12;
  border-color: var(--mint);
}

.chip .count {
  font-family: 'Pixelify Sans', monospace;
  opacity: 0.6;
  margin-left: 4px;
}

/* Post grid */
.post-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
  margin-bottom: 40px;
}

@media (min-width: 600px) {
  .post-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 900px) {
  .post-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (min-width: 1200px) {
  .post-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

.post-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  transition: all var(--t-med);
  display: flex;
  flex-direction: column;
}

.post-card:hover {
  transform: translateY(-4px);
  border-color: var(--border-strong);
  box-shadow: var(--shadow-md);
}

.post-cover {
  aspect-ratio: 16 / 10;
  display: grid;
  place-items: center;
  font-family: 'Bricolage Grotesque', sans-serif;
  font-weight: 800;
  color: #fff;
  font-size: 20px;
  text-align: center;
  padding: 16px;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
  position: relative;
  overflow: hidden;
}

.post-cover::before {
  content: '';
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(
    45deg,
    transparent 0 10px,
    rgba(0, 0, 0, 0.05) 10px 20px
  );
}

.post-body {
  padding: 14px 16px 16px;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.post-cat-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-family: 'Pixelify Sans', monospace;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 3px 8px;
  border-radius: 4px;
  margin-bottom: 8px;
  width: fit-content;
}

.post-cat-badge.games      { background: rgba(0, 229, 160, 0.15);  color: var(--cat-games); }
.post-cat-badge.saves      { background: rgba(255, 181, 71, 0.15); color: var(--cat-saves); }
.post-cat-badge.rom-hacks  { background: rgba(255, 77, 126, 0.15); color: var(--cat-hacks); }
.post-cat-badge.guides     { background: rgba(167, 139, 250, 0.15);color: var(--cat-guides); }
.post-cat-badge.skins      { background: rgba(0, 184, 229, 0.15);  color: var(--cat-skins); }
.post-cat-badge.cheats     { background: rgba(230, 57, 70, 0.15);  color: var(--cat-cheats); }

.post-title {
  font-family: 'Bricolage Grotesque', sans-serif;
  font-weight: 700;
  font-size: 15px;
  line-height: 1.2;
  letter-spacing: -0.01em;
  margin-bottom: 6px;
  color: var(--text);
}

.post-meta {
  margin-top: auto;
  display: flex;
  gap: 8px;
  align-items: center;
  font-size: 11px;
  color: var(--text-dim);
  font-family: 'Pixelify Sans', monospace;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.post-meta .dot {
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: var(--text-dim);
}

/* Empty state (no posts / no results) */
.empty-state {
  text-align: center;
  padding: 60px 20px;
  color: var(--text-muted);
}

.empty-state h3 {
  font-family: 'Bricolage Grotesque', sans-serif;
  font-size: 22px;
  margin-bottom: 8px;
  color: var(--text);
}

/* ==========================================================================
   15. Footer
   ========================================================================== */
footer {
  margin-top: 60px;
  padding: 24px 16px;
  text-align: center;
  font-size: 12px;
  color: var(--text-dim);
  border-top: 1px solid var(--border);
}

footer a {
  color: var(--text-muted);
}

footer a:hover {
  color: var(--mint);
}

/* ==========================================================================
   16. Utilities
   ========================================================================== */
.hidden { display: none !important; }
.mobile-only { display: initial; }
.desktop-only { display: none; }

@media (min-width: 768px) {
  .mobile-only { display: none; }
  .desktop-only { display: initial; }
}

.text-center { text-align: center; }
.text-muted { color: var(--text-muted); }
.text-dim { color: var(--text-dim); }
.text-mint { color: var(--mint); }
.text-coral { color: var(--coral); }

.mt-0 { margin-top: 0; }
.mt-1 { margin-top: 8px; }
.mt-2 { margin-top: 16px; }
.mt-3 { margin-top: 24px; }
.mt-4 { margin-top: 32px; }

.mb-0 { margin-bottom: 0; }
.mb-1 { margin-bottom: 8px; }
.mb-2 { margin-bottom: 16px; }
.mb-3 { margin-bottom: 24px; }
.mb-4 { margin-bottom: 32px; }

/* ==========================================================================
   17. Animations
   ========================================================================== */
@keyframes float {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-6px); }
}

@keyframes fadeUp {
  from { opacity: 0; transform: translateY(20px); }
  to   { opacity: 1; transform: translateY(0); }
}

@keyframes fadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}

@keyframes pulse-mint {
  0%, 100% { box-shadow: 0 0 0 0 var(--mint-glow); }
  50%      { box-shadow: 0 0 0 8px transparent; }
}

.hero,
.stats,
section.block {
  animation: fadeUp 0.6s ease-out backwards;
}

.stats { animation-delay: 0.1s; }
section.block:nth-of-type(1) { animation-delay: 0.2s; }
section.block:nth-of-type(2) { animation-delay: 0.3s; }
section.block:nth-of-type(3) { animation-delay: 0.4s; }

.post-card {
  animation: fadeUp 0.4s ease-out backwards;
}

/* Reduce motion for accessibility */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }

  .cover {
    animation: none;
  }
}

/* ==========================================================================
   18. Print
   ========================================================================== */
@media print {
  .topbar,
  .cta-group,
  footer,
  .filter-chips,
  .search-box {
    display: none;
  }

  body {
    background: #fff;
    color: #000;
  }

  main {
    max-width: 100%;
  }
}
