/* Inter (SIL Open Font License, see assets/fonts/OFL-Inter.txt), variable weight 100-900 */
@font-face {
  font-family: "Inter";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url("../assets/fonts/inter-latin-wght-normal.woff2") format("woff2");
}

:root {
  --bg: #faf9f6;
  --surface: #ffffff;
  --ink: #1b1b1b;
  --muted: #6b6b6b;
  --line: #e4e1db;
  --field: #f1efea;

  --red: #c8102e;
  --red-dark: #a10c25;
  --red-soft: #fbe8eb;

  --win: #2f9e5b;
  --near: #f2c14e;
  --far: #ec7a70;

  --radius: 10px;
  --shadow: 0 4px 18px rgba(27, 27, 27, 0.08);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

*:focus {
  outline: none;
}

body {
  font-family: "Inter", "Helvetica Neue", Arial, sans-serif;
  font-size: 18px;

  color: var(--ink);
  background-color: var(--bg);
}

body::-webkit-scrollbar {
  display: none;
}

a {
  color: var(--red);
}

h3 {
  font-size: 18px;
  font-weight: 600;

  margin-bottom: 6px;
}

ul {
  margin-left: 1rem;
}

img {
  -webkit-user-drag: none;
  -khtml-user-drag: none;
  -moz-user-drag: none;
  -o-user-drag: none;

  -webkit-user-select: none;
  -khtml-user-select: none;
  -moz-user-select: none;
  -o-user-select: none;
  user-select: none;
}

.brand-ink {
  color: var(--ink);
}

.brand-red {
  color: var(--red);
}

.hide {
  display: none;
}

.transparent-background {
  background-color: transparent;
  box-shadow: none;
}

#main-page {
  display: flex;
  flex-direction: column;

  width: 100wh;
  height: 100vh;
}

#site-header {
  display: flex;
  align-items: center;
  justify-content: center;

  background-color: var(--bg);
}

#header-container {
  /* Equal outer columns keep the title centered on the red line, whatever the icon widths */
  display: grid;
  align-items: center;
  grid-template-columns: 1fr auto 1fr;

  width: 372px;
  /* Shrinks on very narrow phones instead of scrolling sideways */
  max-width: calc(100vw - 16px);

  border-bottom: 3px solid var(--red);
}

.title {
  font-size: 31px;
  font-weight: 800;
  letter-spacing: -0.5px;
}

.info-title {
  font-size: 26px;
}

#info-button {
  font-family: inherit;
  font-size: 30px;
  font-weight: 600;

  justify-self: start;

  width: 24px;
  height: 60px;
  padding: 0;

  cursor: pointer;
  text-align: center;

  color: var(--ink);
  border: none;
  background: none;
}

#header-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  justify-self: end;
  gap: 8px;
}

#archive-button {
  width: 24px;
  height: 60px;
  padding: 17px 0;

  cursor: pointer;

  border: none;
  background: none;
}

#info-button:hover {
  color: var(--red);
}

#stat-button {
  font-size: 30px;

  width: 26px;
  height: 60px;
  padding: 16px 0;

  cursor: pointer;

  border: none;
  background: none;
}

#site-footer {
  font-size: 14px;

  display: flex;
  align-items: center;
  justify-content: space-between;

  padding: 10px 0;

  color: var(--muted);
  border-top: 1px solid var(--line);
  background-color: var(--bg);
}

#footer-tagline {
  margin-left: 16px;
}

#dev-name {
  margin-right: 16px;
}

::-webkit-scrollbar {
  width: 4px;
}

::-webkit-scrollbar-track {
  background-color: transparent;
}

::-webkit-scrollbar-thumb {
  background-color: rgba(0, 0, 0, 0.3);
}

::-webkit-scrollbar-thumb:hover {
  background-color: var(--red);
}

@media screen and (max-width: 360px) {
  .title {
    font-size: 23px;
  }
}

@media screen and (max-height: 900px) {
  #image-container {
    width: 275px;
    height: 275px;
  }

  #product-info {
    width: 275px;
  }
}

@media screen and (max-height: 850px) {
  #image-container {
    width: 250px;
    height: 250px;
  }

  #product-info {
    width: 250px;
  }
}

@media screen and (max-height: 825px) {
  #image-container {
    width: 225px;
    height: 225px;
  }

  #product-info {
    width: 225px;
  }

  #site-footer {
    font-size: 13px;
  }

  #game-stats {
    font-size: 16px;
  }
}

@media screen and (max-height: 785px) {
  #image-container {
    width: 200px;
    height: 200px;
  }

  #product-info {
    width: 200px;
  }
}

@media screen and (max-height: 760px) {
  #image-container {
    height: 175px;
  }

  #product-image {
    height: 175;
  }

  #product-info {
    font-size: 15px;
  }
}

@media screen and (max-height: 725px) {
  #image-container {
    height: 150px;
  }
}

@media screen and (max-height: 700px) {
  #image-container {
    height: 125px;
  }
}

@media screen and (max-height: 675px) {
  #info-card {
    margin-top: 20px;
  }
}
