/* ─── DS KONGEN — Sections & Categories ─── */

.section { padding: 80px 60px; max-width: 1400px; margin: 0 auto; }
.section-header { display: flex; align-items: flex-end; justify-content: space-between; margin-bottom: 40px; flex-wrap: wrap; gap: 16px; }

.section-title {
  font-family: var(--pixel); font-size: 20px; color: var(--gold);
  line-height: 1.6; text-shadow: 2px 2px 0 #4a3600, 0 0 20px rgba(255,215,0,0.2);
  letter-spacing: 1px; margin: 0;
}
.section-title span {
  display: block; font-family: var(--body); font-size: 14px;
  font-weight: 600; color: var(--text-dim); letter-spacing: 2px;
  text-transform: uppercase; margin-bottom: 8px; text-shadow: none;
}

.section-link {
  font-family: var(--pixel); font-size: 9px; color: var(--teal-light);
  text-decoration: none; border-bottom: 1px solid currentColor; padding-bottom: 2px;
  transition: color 0.2s;
}
.section-link:hover { color: var(--gold); }

.pixel-divider { display: flex; margin: 0 60px; height: 4px; }
.pixel-divider-inner {
  height: 4px;
  background: repeating-linear-gradient(90deg, var(--gold) 0, var(--gold) 8px, transparent 8px, transparent 16px);
  flex: 1; opacity: 0.3;
}

/* ─── Category grid ─── */
.categories-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(208px, 1fr)); gap: 16px; }

.cat-card {
  background: var(--navy-card); border: 1px solid rgba(255,215,0,0.12);
  padding: 24px 16px; text-align: center; text-decoration: none;
  color: var(--text); transition: border-color 0.2s, transform 0.2s, background 0.2s, box-shadow 0.2s;
  position: relative; display: block; border-radius: 14px;
  cursor: pointer;
}
.cat-card::before,
.cat-card::after {
  content: ""; position: absolute; width: 2px; height: 2px;
  border-radius: 50%; top: 0; left: 0;
  opacity: 0; transition: opacity 0.4s;
  pointer-events: none;
}
.cat-card::before {
  animation: twinkle 2.8s ease-in-out infinite;
  box-shadow:
    12px 18px 0 rgba(255,215,0,.7), 38px 8px 0 rgba(255,215,0,.5),
    67px 25px 0 rgba(255,215,0,.7), 95px 12px 0 rgba(255,215,0,.4),
    130px 20px 0 rgba(255,215,0,.6), 158px 8px 0 rgba(255,215,0,.5),
    175px 30px 0 rgba(255,215,0,.3), 25px 50px 0 rgba(255,215,0,.6),
    85px 60px 0 rgba(255,215,0,.4), 145px 48px 0 rgba(255,215,0,.7),
    50px 90px 0 rgba(255,215,0,.5), 115px 80px 0 rgba(255,215,0,.3),
    8px 35px 0 rgba(255,215,0,.6);
}
.cat-card::after {
  animation: twinkle 1.8s ease-in-out infinite 0.7s;
  box-shadow:
    22px 32px 0 rgba(14,169,143,.8), 75px 15px 0 rgba(14,169,143,.6),
    120px 35px 0 rgba(14,169,143,.8), 45px 65px 0 rgba(14,169,143,.7),
    160px 25px 0 rgba(14,169,143,.6), 95px 95px 0 rgba(14,169,143,.5),
    185px 45px 0 rgba(14,169,143,.7), 10px 55px 0 rgba(14,169,143,.4);
}
.cat-card:hover {
  border-color: rgba(255,215,0,0.6); transform: translateY(-6px);
  background: #141f38; box-shadow: 0 12px 32px rgba(0,0,0,0.4), 0 0 24px rgba(255,215,0,0.08);
}
.cat-card:hover::before, .cat-card:hover::after { opacity: 1; }

@keyframes twinkle {
  0%, 100% { opacity: 1; }
  50%      { opacity: 0.4; }
}

.cat-icon { display: block; margin-bottom: 12px; color: var(--gold); filter: drop-shadow(0 0 8px rgba(255,215,0,0.3)); }
.cat-icon svg { width: 36px; height: 36px; }
.cat-name {
  font-family: var(--body); font-weight: 800; font-size: 16px;
  letter-spacing: 1px; text-transform: uppercase; color: var(--text); margin-bottom: 4px;
}
.cat-count { font-family: var(--pixel); font-size: 9px; color: var(--teal-light); line-height: 1.8; }

.cat-card.featured-cat {
  grid-column: span 2;
  background: linear-gradient(135deg, #0d1d35 0%, #0e2a20 100%);
  border-color: rgba(255,215,0,0.25); padding: 32px 24px;
}

/* Category photo cards — real console artwork instead of the SVG icon.
   Needs an explicit min-height: once every card in a grid row has a
   photo (no SVG icon padding out the content anymore), the row's height
   collapses to fit just the name/count text — background-size:cover
   then crushes the artwork down to a sliver a few pixels tall. Added
   2026-08-04.

   All photo cards share one uniform size (2026-08-05) — the "featured"
   double-width/taller treatment was designed for the icon-only cards and
   made photo cards inconsistent, so it's dropped here for any card that
   also carries .has-cat-image. Selector order matters: this must come
   after the plain .featured-cat rule above so grid-column/padding get
   reset back to the standard card values. */
.cat-card.has-cat-image {
  background-size: cover; background-position: center;
  justify-content: flex-end; display: flex; flex-direction: column;
  height: 260px;
  grid-column: auto !important;
}
.cat-card.has-cat-image.featured-cat {
  grid-column: auto !important;
  padding: 24px 16px !important;
  height: 260px !important;
  background-size: cover; background-position: center;
}
.cat-card.has-cat-image .cat-name { text-shadow: 0 2px 10px rgba(0,0,0,0.95), 0 0 24px rgba(0,0,0,0.7); }
.cat-card.has-cat-image .cat-count { text-shadow: 0 1px 6px rgba(0,0,0,0.95); }
.cat-card.featured-cat .cat-icon svg { width: 48px; height: 48px; }
