@font-face {
  font-family: "Bai Jamjuree";
  src: url("/fonts/bai-jamjuree-medium.woff2") format("woff2");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Bai Jamjuree";
  src: url("/fonts/bai-jamjuree-semibold.woff2") format("woff2");
  font-weight: 600 700;
  font-style: normal;
  font-display: swap;
}

:root {
  --bg: #d1d1d1;
  --text: #2c2c2c;
  --font-body: "Bai Jamjuree", sans-serif;
  --pad-x: max(16px, env(safe-area-inset-left, 0px), env(safe-area-inset-right, 0px));
  --pad-bottom: max(24px, env(safe-area-inset-bottom, 0px));
  --tap: 44px;
  --radius-lg: 25px;
  --green-from: #2ff65a;
  --green-to: #b6ffc6;
  --green-border: #9dffb2;
  --btn-from: #eeeeee;
  --btn-border: #f5f5f5;
  --discord-to: #ecf0ff;
  --kick-to: #d9ffef;
}

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

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  overflow-x: clip;
  background: var(--bg);
}

body {
  margin: 0;
  min-height: 100vh;
  min-height: 100dvh;
  font-family: var(--font-body);
  font-weight: 500;
  font-size: 1rem;
  line-height: 1.2;
  color: var(--text);
  background: var(--bg);
  overflow-x: clip;
}

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

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

/* —— Mobile art (top banner) —— */
.art {
  position: relative;
  z-index: 0;
  width: 100%;
  height: clamp(280px, 102vw, 411px);
  overflow: hidden;
  pointer-events: none;
}

.art-img {
  position: absolute;
  left: 0;
  width: 100%;
  height: 130.3%;
  top: -8.25%;
  max-width: none;
  object-fit: cover;
  object-position: 55% 0%;
}

.art::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(
      120% 80% at 50% 18%,
      rgba(209, 209, 209, 0) 0%,
      rgba(209, 209, 209, 0) 47.5%,
      var(--bg) 100%
    ),
    linear-gradient(to bottom, rgba(209, 209, 209, 0) 42%, var(--bg) 100%);
}

.page {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 26.5rem;
  margin: -7.5rem auto 0;
  padding: 0 var(--pad-x) var(--pad-bottom);
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.logo {
  width: min(327px, 86%);
  height: auto;
  margin: 0 auto 22px;
}

.lede {
  margin: 0 0 32px;
  max-width: 21.5rem;
  font-size: 16px;
  font-weight: 500;
  line-height: 1.2;
  color: var(--text);
  text-wrap: pretty;
}

.lede strong {
  font-weight: 600;
}

.links {
  display: flex;
  flex-direction: column;
  gap: 12px;
  width: 100%;
}

.btn {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  min-height: var(--tap);
  font-family: var(--font-body);
  font-weight: 600;
  color: var(--text);
  border-style: solid;
  -webkit-tap-highlight-color: rgba(47, 246, 90, 0.25);
}

.btn span {
  min-width: 0;
  text-align: left;
}

.btn-steam {
  width: 100%;
  min-height: 68px;
  padding: 6px 8px 6px 16px;
  color: #000;
  font-size: 22px;
  line-height: 1.2;
  background: linear-gradient(to bottom, var(--green-from), var(--green-to));
  border: 2.5px solid var(--green-border);
  border-radius: var(--radius-lg);
  box-shadow: 0 0 0 3px #000;
}

.icon-steam {
  flex: 0 0 auto;
  width: 47.39px;
  height: 47.39px;
  max-width: none;
}

.btn-row {
  display: flex;
  gap: 8px;
  width: 100%;
}

.btn-discord,
.btn-kickstarter {
  flex: 1 1 0;
  min-width: 0;
  min-height: 63px;
  padding: 8px 10px 8px 14px;
  font-size: 16px;
  line-height: 1;
  border-width: 2px;
  border-color: var(--btn-border);
  border-radius: var(--radius-lg);
  background: linear-gradient(to bottom, var(--btn-from), var(--discord-to));
}

.btn-kickstarter {
  background: linear-gradient(to bottom, var(--btn-from), var(--kick-to));
}

.icon-discord {
  flex: 0 0 auto;
  width: 39.4917px;
  height: 39.4917px;
  max-width: none;
}

.icon-kickstarter {
  flex: 0 0 auto;
  width: 23.5896px;
  height: 26.6324px;
  max-width: none;
}

.btn:focus-visible {
  outline: 2px solid var(--text);
  outline-offset: 3px;
}

.social {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 10px 16px;
  margin: 40px 0 0;
  padding: 0;
  list-style: none;
}

.social a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: var(--tap);
  height: var(--tap);
  -webkit-tap-highlight-color: rgba(44, 44, 44, 0.15);
}

.social a:focus-visible {
  outline: 2px solid var(--text);
  outline-offset: 3px;
}

.social img {
  width: 29.125px;
  height: auto;
  max-width: none;
  flex: 0 0 auto;
}

.social li:nth-child(1) img {
  width: 29.6187px;
}

.social li:nth-child(2) img {
  width: 28.6315px;
}

.social li:nth-child(3) img {
  width: 28.1378px;
}

.social li:nth-child(4) img {
  width: 29.1251px;
}

@media (hover: hover) and (pointer: fine) {
  .btn-steam:hover {
    filter: brightness(1.03);
  }

  .btn-discord:hover,
  .btn-kickstarter:hover {
    filter: brightness(0.98);
  }

  .social a:hover {
    opacity: 0.7;
  }
}

@media (prefers-reduced-motion: reduce) {
  .btn,
  .social a {
    transition: none;
  }
}

/* —— Desktop (Figma 1728 × 1117) —— */
@media (min-width: 1024px) {
  .art {
    position: fixed;
    top: 0;
    right: 0;
    width: calc(100% - min(35.4375rem, 44vw));
    height: 100%;
    height: 100dvh;
    -webkit-mask-image: linear-gradient(
      to right,
      transparent 0%,
      rgba(0, 0, 0, 0.14) 8.5%,
      #000 32.5%,
      #000 100%
    );
    mask-image: linear-gradient(
      to right,
      transparent 0%,
      rgba(0, 0, 0, 0.14) 8.5%,
      #000 32.5%,
      #000 100%
    );
    -webkit-mask-size: 100% 100%;
    mask-size: 100% 100%;
    -webkit-mask-repeat: no-repeat;
    mask-repeat: no-repeat;
  }

  .art::after {
    display: none;
  }

  .art-img {
    position: absolute;
    left: 0;
    top: -4.1%;
    width: 100%;
    height: 124.8%;
    object-fit: cover;
    object-position: 62% 8%;
  }

  .page {
    width: min(35.4375rem, 44vw);
    max-width: none;
    min-height: 100dvh;
    margin: 0;
    padding:
      clamp(32px, 14.7vh, 165px)
      2rem
      max(32px, env(safe-area-inset-bottom, 0px))
      clamp(40px, 4.68vw, 81px);
    align-items: flex-start;
    text-align: left;
    justify-content: flex-start;
  }

  .logo {
    width: min(470.74px, 48vh, 100%);
    margin: 0 0 clamp(24px, 6.9vh, 77px);
  }

  .lede {
    margin: 0 0 clamp(24px, 7vh, 78px);
    max-width: 28.99rem;
    font-size: 18px;
    text-align: left;
  }

  .links {
    width: min(454.29px, 100%);
    gap: clamp(10px, 1.7vh, 19px);
  }

  .btn-steam {
    min-height: 85.17px;
    padding: 0 12px 0 21px;
    font-size: 28px;
    border-width: 3.052px;
    border-radius: 30.91px;
    white-space: nowrap;
    box-shadow: 0 0 0 4px #000;
  }

  .btn-steam span {
    white-space: nowrap;
  }

  .icon-steam {
    width: 58.5933px;
    height: 58.5933px;
  }

  .btn-row {
    gap: 6px;
  }

  .btn-discord,
  .btn-kickstarter {
    min-height: 77.94px;
    padding: 8px 12px 8px 20px;
    font-size: 18px;
    border-radius: 30.91px;
  }

  .icon-discord {
    width: 48.8277px;
    height: 48.8277px;
  }

  .icon-kickstarter {
    width: 29.1664px;
    height: 32.9284px;
  }

  .social {
    margin-top: auto;
    padding-top: clamp(16px, 4vh, 48px);
    justify-content: center;
    align-self: stretch;
    width: min(454.29px, 100%);
    gap: 22px;
  }

  .social li:nth-child(1) img,
  .social li:nth-child(2) img,
  .social li:nth-child(3) img,
  .social li:nth-child(4) img {
    width: auto;
  }

  .social li:nth-child(1) img {
    width: 37.9505px;
    height: 37.9505px;
  }

  .social li:nth-child(2) img {
    width: 36.6855px;
    height: 36.053px;
  }

  .social li:nth-child(3) img {
    width: 36.053px;
    height: 36.053px;
  }

  .social li:nth-child(4) img {
    width: 37.318px;
    height: 37.318px;
  }
}
