:root {
  /* Core tokens for the light studio catalog theme. */
  --bg: #f7f1ea;
  --panel: #fffaf5;
  --panel-strong: #ffffff;
  --text: #201715;
  --muted: #695451;
  --line: #e1d2cb;
  --accent: #a3362b;
  --accent-strong: #7f251d;
  --shadow: 0 18px 42px rgba(54, 24, 20, 0.08);
  --radius: 24px;
  --container: 1180px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: "Trebuchet MS", "Segoe UI", sans-serif;
  background:
    radial-gradient(circle at top right, rgba(163, 54, 43, 0.08), transparent 28rem),
    linear-gradient(180deg, #fbf7f3 0%, var(--bg) 100%);
  color: var(--text);
  line-height: 1.6;
}

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

a {
  color: var(--accent-strong);
}

a:hover,
a:focus-visible {
  color: var(--accent);
}

:focus-visible {
  outline: 3px solid rgba(163, 54, 43, 0.35);
  outline-offset: 3px;
}

.skip-link {
  position: absolute;
  left: 1rem;
  top: -3rem;
  background: var(--accent-strong);
  color: #fff;
  padding: 0.75rem 1rem;
  border-radius: 999px;
  z-index: 100;
}

.skip-link:focus {
  top: 1rem;
}

.site-header,
.page-shell,
.site-footer {
  width: min(calc(100% - 2rem), var(--container));
  margin: 0 auto;
}

.site-header {
  /* Shared shell for homepage and game detail pages. */
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  padding: 1.5rem 0;
}

.brand-mark {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.3rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-decoration: none;
}

.site-nav ul,
.link-list,
.meta-list,
.feature-list,
.alpha-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.site-nav ul {
  display: flex;
  gap: 1rem;
}

.site-nav a {
  text-decoration: none;
  color: var(--text);
  font-weight: 600;
}

.hero {
  display: grid;
  grid-template-columns: 1.3fr 1fr;
  gap: 2rem;
  align-items: end;
  padding: 2rem 0 3rem;
}

.hero-copy h1,
.page-hero h1 {
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(2.4rem, 6vw, 4.7rem);
  line-height: 0.98;
  margin: 0 0 1rem;
}

.tagline {
  font-size: 1.15rem;
  color: var(--muted);
  max-width: 36rem;
  margin: 0;
}

.hero-panel,
.content-panel,
.game-card,
.link-card,
.info-grid,
.gallery,
.section-banner {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.hero-panel {
  overflow: hidden;
}

.hero-panel img {
  aspect-ratio: 16 / 10;
  object-fit: cover;
}

.hero-panel figcaption,
.shot figcaption {
  padding: 0.8rem 1rem 1rem;
  color: var(--muted);
  font-size: 0.95rem;
}

main section,
.page-content {
  padding: 1.4rem 0 3rem;
}

.section-heading {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  align-items: end;
  margin-bottom: 1.4rem;
}

.section-heading h2,
.page-content h2 {
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(1.8rem, 4vw, 2.6rem);
  margin: 0;
}

.section-heading p,
.lede,
.content-panel p,
.link-card p {
  margin: 0;
  color: var(--muted);
}

.games-grid,
.links-grid,
.gallery-grid,
.info-grid {
  display: grid;
  gap: 1.3rem;
}

.games-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.game-card {
  overflow: hidden;
}

.game-card > img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
}

.card-body,
.content-panel,
.link-card,
.section-banner {
  padding: 1.3rem;
}

.eyebrow,
.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  border-radius: 999px;
  padding: 0.35rem 0.75rem;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.03em;
}

.eyebrow {
  background: rgba(163, 54, 43, 0.1);
  color: var(--accent-strong);
}

.badge {
  background: rgba(32, 23, 21, 0.08);
  color: var(--text);
}

.game-card h3,
.content-panel h2,
.link-card h3 {
  margin: 0.75rem 0 0.6rem;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.5rem;
  line-height: 1.15;
}

.meta-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  margin: 1rem 0;
}

.meta-list li {
  padding: 0.42rem 0.8rem;
  border-radius: 999px;
  background: #f2e7e0;
  color: var(--text);
  font-size: 0.92rem;
}

.card-actions,
.store-links,
.inline-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1.1rem;
}

.button,
.text-link {
  /* Consistent interactive treatment across cards and detail pages. */
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.75rem;
  border-radius: 999px;
  font-weight: 700;
  text-decoration: none;
  padding: 0.7rem 1rem;
}

.button {
  background: var(--accent);
  color: #fff;
}

.button.secondary {
  background: #efe2db;
  color: var(--text);
}

.text-link {
  color: var(--accent-strong);
  padding-inline: 0;
}

.store-badge {
  display: inline-flex;
  align-items: center;
  flex: 0 0 auto;
  line-height: 0;
}

.store-badge img {
  display: block;
  width: 10.5rem;
  max-width: 100%;
  height: auto;
  aspect-ratio: auto;
  object-fit: contain;
}

.content-panel {
  margin-top: 1.3rem;
}

.gallery-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.shot {
  overflow: hidden;
  border-radius: calc(var(--radius) - 8px);
  border: 1px solid var(--line);
  background: var(--panel-strong);
}

.shot img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
}

.info-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  padding: 1.25rem;
}

.info-grid div {
  padding: 0.55rem 0;
  border-bottom: 1px solid var(--line);
}

.info-grid dt {
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
}

.info-grid dd {
  margin: 0.25rem 0 0;
  font-weight: 700;
}

.feature-list li {
  position: relative;
  padding-left: 1.1rem;
  margin-bottom: 0.7rem;
}

.feature-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.7rem;
  width: 0.45rem;
  height: 0.45rem;
  border-radius: 50%;
  background: var(--accent);
}

.links-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.site-footer {
  padding: 1rem 0 2.5rem;
  color: var(--muted);
  font-size: 0.95rem;
}

.page-hero {
  padding: 2rem 0 1rem;
}

.page-hero p {
  max-width: 46rem;
  color: var(--muted);
}

.back-link {
  display: inline-block;
  margin-bottom: 1rem;
  color: var(--accent-strong);
  font-weight: 700;
}

.section-banner {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  align-items: center;
}

@media (max-width: 960px) {
  /* Collapse multi-column layouts into a single reading flow on smaller screens. */
  .hero,
  .games-grid,
  .gallery-grid,
  .links-grid,
  .info-grid {
    grid-template-columns: 1fr;
  }

  .site-header,
  .section-heading,
  .section-banner {
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (max-width: 640px) {
  body {
    font-size: 0.98rem;
  }

  .site-header {
    padding-top: 1rem;
  }

  .site-nav ul {
    gap: 0.75rem;
  }

  .card-actions,
  .store-links,
  .inline-links {
    flex-direction: column;
  }

  .button,
  .text-link,
  .store-badge {
    width: 100%;
  }

  .store-badge img {
    width: min(10.5rem, 100%);
  }
}
