:root {
  color-scheme: dark;
  --color-page: #182b40;
  --color-section: #e8dfca;
  --color-ink: #243b50;
  --color-header: #345777;
  --color-footer: #101d2d;
  --color-card: #345777;
  --color-art: #345877;
  --color-border: #b97960;
  --color-border-soft: #95624f;
  --color-text: #e8dfca;
  --color-muted: #d4c8b2;
  --color-accent: #d7b573;
  --font-body: "Lato", "Segoe UI", sans-serif;
  --font-display: "Merriweather", Georgia, serif;
}

* {
  box-sizing: border-box;
}

html {
  background: var(--color-page);
}

body {
  min-height: 100vh;
  margin: 0;
  overflow-x: clip;
  color: var(--color-text);
  background:
    radial-gradient(ellipse at 50% 0, #395f81 0, transparent 65%),
    #0f1c2b;
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.5;
}

.site-shell {
  --awning-overhang: clamp(1.5rem, 6vw, 3.5rem);
  --post-width: clamp(0.4375rem, 1.25vw, 0.75rem);
  --base-overhang: clamp(0.5rem, 2vw, 1.25rem);
  position: relative;
  display: flex;
  width: min(100% - 2rem, 42.67rem);
  min-height: 100vh;
  flex-direction: column;
  margin-inline: auto;
  background: var(--color-page);
  box-shadow: 0 8px 28px #0004;
}

/* Timber uprights run behind the awning and disappear into the base. */
.site-shell::before,
.site-shell::after {
  position: absolute;
  top: 0;
  bottom: 1.5rem;
  z-index: 1;
  width: var(--post-width);
  border-inline: 1px solid #0006;
  background:
    linear-gradient(90deg, #21170e66, #e4bc7b24 18%, transparent 42%, #21170e55),
    url("rough-wood.svg") center top / 100% 30rem repeat-y,
    #876344;
  box-shadow: 0 0 3px 1px #0004, inset 1px 0 1px #e8c99750;
  content: "";
  pointer-events: none;
}

.site-shell::before {
  left: 0;
}

.site-shell::after {
  right: 0;
  background-position: center, center 11rem;
  transform: scaleX(-1);
}

.site-header {
  position: relative;
  isolation: isolate;
  width: calc(100% + var(--awning-overhang) * 2);
  margin-inline: calc(-1 * var(--awning-overhang));
  min-height: 6rem;
  background: url("awning.svg") center top / 100% 100% no-repeat;
  filter: drop-shadow(0 2px 1px #080f1980) drop-shadow(0 7px 6px #0007);
  z-index: 2;
}

.site-header__inner {
  position: absolute;
  top: 0;
  right: calc(2.25rem + var(--awning-overhang));
  width: 10.5rem;
}

.hanging-sign {
  position: relative;
  margin: 0;
  padding-top: 0.5rem;
  line-height: 0;
}

.hanging-sign__hanger {
  position: absolute;
  z-index: 1;
  top: -2.5rem;
  width: 0.75rem;
  height: 3.5rem;
  border: 1px solid #171b20;
  border-radius: 0 0 2px 2px;
  background: #525b5b;
  box-shadow: 2px 2px 3px #0006;
}

.hanging-sign__hanger--left {
  left: 18%;
}

.hanging-sign__hanger--right {
  right: 18%;
}

.hanging-sign__interaction {
  position: relative;
  z-index: 2;
  display: block;
  width: 100%;
  padding: 0;
  border: 0;
  border-radius: 5px;
  background: transparent;
  color: inherit;
  font: inherit;
  line-height: inherit;
  perspective: 650px;
  cursor: pointer;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
}

.hanging-sign__interaction:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 5px;
}

.hanging-sign__assembly {
  position: relative;
  display: block;
  /* Pivot both straps and the board at the straps' upper attachment points. */
  transform-origin: 50% -2.5rem;
  pointer-events: none;
  user-select: none;
}

.hanging-sign__board {
  position: relative;
  z-index: 2;
  display: block;
  padding: 0.375rem 0.125rem;
  border: 3px solid #876344;
  border-radius: 5px 4px 6px 4px;
  background: #f6efdf;
  box-shadow:
    0 3px 5px #101d2d40,
    0 8px 14px #101d2d59,
    inset 0 0 0 1px #47312240,
    inset 0 0 6px 2px #47312240,
    inset 0 0 2px #47312226;
}

.hanging-sign__board img {
  display: block;
  width: 100%;
  height: auto;
  /* A lit upper edge and lower shadow lift the logo above the recessed panel. */
  filter:
    drop-shadow(0 -0.5px 0 #fffdf599)
    drop-shadow(0 0.5px 0 #873e324d)
    drop-shadow(0 1px 0.75px #643c2a30);
}

.site-main {
  position: relative;
  isolation: isolate;
  color-scheme: light;
  color: var(--color-ink);
  width: 100%;
  flex: 1;
  margin-inline: auto;
  margin-top: -1rem;
  padding: calc(1rem + clamp(0.75rem, 2vw, 1.25rem)) calc(var(--post-width) + 1rem) clamp(2.5rem, 6vw, 4.5rem);
}

/* Confine the textured panel and its inset shading to the timber opening. */
.site-main::before {
  position: absolute;
  z-index: -1;
  inset: 0 var(--post-width);
  background:
    url("diamond-lattice.svg"),
    url("canvas-weave.svg"),
    var(--color-section);
  box-shadow:
    inset 0 28px 36px -14px #17232d80,
    inset 24px 0 30px -16px #28302e73,
    inset -24px 0 30px -16px #28302e73,
    inset 0 -18px 26px -14px #28302e59;
  content: "";
  pointer-events: none;
}

.games__title {
  margin: 0;
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 700;
  line-height: 1.2;
  text-align: left;
  text-shadow: 0 3px 3px #14283c40;
}

.games__flourish {
  display: block;
  width: min(5rem, 85%);
  height: auto;
  margin: -0.125rem 0 0.75rem;
  color: var(--color-border-soft);
  stroke: currentColor;
  stroke-width: 8;
  stroke-linecap: round;
  stroke-linejoin: round;
  filter: drop-shadow(0 2px 1px #14283c30);
}

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

.game-entry {
  min-width: 0;
  padding: 0.4rem 0.4rem 0.6rem;
  border-radius: 5px 4px 6px 4px;
  background: linear-gradient(135deg, #42627e, #2b4863 55%, #365773);
  box-shadow: 0 2px 3px #0c182670, 0 5px 8px #0005, inset 0 1px 2px #c3d3df18;
  color: var(--color-text);
}

.game-card {
  position: relative;
  display: block;
  min-width: 0;
  padding: 0.25rem;
  overflow: hidden;
  border: 3px solid var(--color-border);
  border-radius: 4px 3px 5px 3px;
  background: #14273a;
  box-shadow: 0 2px 4px #0006, inset 0 1px 3px #0008;
  color: inherit;
  text-decoration: none;
  transition: border-color 140ms ease, box-shadow 140ms ease, transform 140ms ease;
}

.game-card:hover {
  transform: translateY(-1px);
  border-color: var(--color-accent);
  box-shadow: 0 3px 6px #0007, inset 0 1px 3px #0006;
}

.game-card:active {
  transform: translateY(1px);
  box-shadow: 0 1px 2px #0004, inset 0 2px 5px #0009;
}

.game-card:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 4px;
}

.game-card__art {
  display: block;
  width: 100%;
  height: auto;
}

.game-card__meta {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  margin: 0.65rem 0.1rem 0;
}

.game-card__title {
  margin: 0;
  color: var(--color-text);
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 400;
  text-align: left;
  text-shadow: 0 2px 1px #0e1d2d;
}

.game-card__title-link {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  color: inherit;
  text-decoration-color: currentColor;
  text-underline-offset: 0.2em;
  white-space: nowrap;
}

.game-card__title-link:hover,
.game-card__title-link:focus-visible {
  color: var(--color-accent);
  text-decoration-color: currentColor;
}

.game-card__steam-icon {
  flex-shrink: 0;
  opacity: 0.6;
}

.game-card__press-kit {
  color: var(--color-muted);
  font-family: var(--font-display);
  font-size: 0.8125rem;
  text-decoration: underline;
  text-underline-offset: 0.2em;
  white-space: nowrap;
}

.game-card__press-kit:hover,
.game-card__press-kit:focus-visible {
  color: var(--color-accent);
}

.game-card__title-link:focus-visible,
.game-card__press-kit:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 3px;
}

.site-footer {
  position: relative;
  z-index: 2;
  display: flex;
  width: calc(100% + var(--base-overhang) * 2);
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 0.5rem 1rem;
  margin-top: auto;
  margin-inline: calc(-1 * var(--base-overhang));
  padding: 0.6rem calc(var(--base-overhang) + var(--post-width) + 1rem);
  border: 1px solid #0c1926;
  border-radius: 3px 3px 5px 5px;
  background:
    url("canvas-weave.svg"),
    linear-gradient(#2b4862, #172c40);
  box-shadow: 0 -3px 7px #0005, 0 8px 12px #0004, inset 0 2px 4px #0004;
  text-align: right;
}

.site-footer__socials {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-right: auto;
}

.site-footer__social {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 1.5rem;
  min-height: 1.5rem;
}

.site-footer__social svg {
  display: block;
  filter: drop-shadow(0 2px 1px #000);
}

.site-footer a {
  color: var(--color-muted);
  font-family: var(--font-display);
  font-size: 0.875rem;
  text-shadow: 0 2px 1px #000;
  text-decoration-color: currentColor;
  text-underline-offset: 0.2em;
  transition: color 140ms ease, text-decoration-color 140ms ease;
}

.site-footer a:hover,
.site-footer a:focus-visible {
  color: var(--color-accent);
  text-decoration-color: currentColor;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  clip-path: inset(50%);
  border: 0;
}

@media (max-width: 42rem) {
  .site-header {
    min-height: 5rem;
  }

  .site-header__inner {
    top: 0;
    width: 9.5rem;
  }

  .game-grid {
    grid-template-columns: minmax(0, 1fr);
    gap: 1rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }
}
