
:root {
  --bg: #08080b;
  --panel: #151318;
  --panel-hover: #1d1920;
  --line: #332b30;
  --gold: #c9a24b;
  --gold2: #f0d58b;
  --text: #eeeae2;
  --mute: #a19ba0;
  --glow: #c9a24b30;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  position: relative;
  background: #08080b;
  color: var(--text);
  font: 1rem/1.75 "Cormorant Garamond", Georgia, serif;
}

/* CINEMATIC BACKGROUND */

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;

  background:
    linear-gradient(
      180deg,
      rgba(5, 5, 8, .42) 0%,
      rgba(5, 5, 8, .58) 40%,
      rgba(5, 5, 8, .82) 100%
    ),
    url("/assets/uploads/talverse_background.jpg");

  background-size: cover;
  background-position: center 25%;
  background-repeat: no-repeat;
}

body > * {
  position: relative;
  z-index: 1;
}

h1, h2, h3, .brand {
  font-family: "Cinzel", "Times New Roman", serif;
  font-weight: 500;
  letter-spacing: .04em;
  line-height: 1.25;
}

a {
  color: var(--gold2);
}

a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 4px;
}

.wrap {
  max-width: 1160px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* HEADER */

header {
  border-bottom: 1px solid #c9a24b25;
  position: sticky;
  top: 0;
  background: rgba(8, 7, 10, .88);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  z-index: 5;
  box-shadow: 0 5px 25px #0005;
}

header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 74px;
}

.brand {
  display: flex;
  align-items: center;
  gap: .7rem;
  color: var(--gold);
  text-decoration: none;
  font-size: 1.35rem;
  transition: .3s ease;
}

.brand:hover {
  color: var(--gold2);
}

.brand svg {
  width: 32px;
  height: 32px;
}

nav {
  display: flex;
  align-items: center;
  gap: 1.8rem;
}

nav a {
  color: var(--mute);
  text-decoration: none;
  margin: 0;
  padding: .45rem 0;
  border-bottom: 1px solid transparent;
  transition: color .25s ease, border-color .25s ease;
}

nav a:hover,
nav a[aria-current] {
  border-color: var(--gold);
  color: var(--gold2);
}

/* HERO */

.hero {
  text-align: center;
  padding: 8rem 0 6rem;
  position: relative;
}

.hero .logo svg {
  width: 104px;
  height: 104px;
  filter: drop-shadow(0 0 25px #c9a24b66);
}

.hero h1 {
  font-size: clamp(2.8rem, 8vw, 5.5rem);
  margin: 1.2rem 0 .4rem;
  color: var(--gold2);
  text-shadow: 0 0 35px #c9a24b30;
}

.tag {
  font-size: 1.45rem;
  font-style: italic;
  color: var(--gold);
}

.intro {
  max-width: 660px;
  margin: 1.5rem auto 2.3rem;
  color: var(--mute);
  font-size: 1.1rem;
}

/* BUTTONS */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: .85rem 1.8rem;
  border: 1px solid #c9a24b80;
  border-radius: 3px;
  color: var(--gold2);
  background: #c9a24b0c;
  text-decoration: none;
  font: 500 .88rem "Cinzel", serif;
  letter-spacing: .09em;
  cursor: pointer;
  transition: all .3s ease;
}

.btn:hover {
  background: var(--gold);
  border-color: var(--gold);
  color: #09090b;
  box-shadow: 0 5px 25px var(--glow);
  transform: translateY(-2px);
}

.btn.solid {
  background: var(--gold);
  color: #09090b;
  border-color: var(--gold);
}

.btn.solid:hover {
  background: var(--gold2);
  border-color: var(--gold2);
}

/* SECTIONS */

section {
  padding: 4.5rem 0;
}

h2 {
  font-size: clamp(1.7rem, 4vw, 2.2rem);
  color: var(--gold2);
  margin: 0 0 2rem;
}

/* GAME GRID */

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr));
  gap: 1.8rem;
  align-items: stretch;
}

/* GAME CARDS */

.card {
  background: rgba(15, 12, 16, .88);
  border: 1px solid var(--line);
  border-radius: 5px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  min-width: 0;
  transition:
    transform .35s ease,
    border-color .35s ease,
    box-shadow .35s ease;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.card:hover {
  transform: translateY(-7px);
  border-color: #c9a24b80;
  box-shadow: 0 18px 45px #0008, 0 0 25px #c9a24b0b;
}

/* GAME ARTWORK */

.card .img {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 10;
  min-height: 0;
  flex: none;
  overflow: hidden;
  display: grid;
  place-items: center;
  background: rgba(8, 7, 10, .85);
}

.card .img img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.card .img svg {
  width: 56px;
  opacity: .5;
}

/* CARD CONTENT */

.card .body {
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: .7rem;
  flex: 1;
}

.card h3 {
  margin: 0;
  font-size: 1.4rem;
  color: var(--text);
}

.card p {
  margin: 0;
  color: var(--mute);
  font-size: 1.05rem;
}

.meta {
  font-size: .9rem;
  color: var(--gold);
  letter-spacing: .03em;
}

.card .btn {
  margin-top: auto;
  align-self: stretch;
  text-align: center;
}

/* FEATURED CARD */

.card.featured {
  grid-column: auto;
  flex-direction: column;
}

.card.featured .img {
  flex: none;
  aspect-ratio: 16 / 10;
  min-height: 0;
}

.card.featured .body {
  flex: 1;
  justify-content: flex-start;
}

.more {
  margin-top: 1.8rem;
  text-align: right;
}

/* CONTACT FORM */

form {
  display: grid;
  gap: 1rem;
  max-width: 620px;
}

label {
  display: grid;
  gap: .4rem;
  color: var(--mute);
}

input,
textarea {
  width: 100%;
  background: rgba(15, 12, 16, .92);
  border: 1px solid var(--line);
  border-radius: 3px;
  color: var(--text);
  padding: .85rem 1rem;
  font: inherit;
  transition: border-color .25s ease, box-shadow .25s ease;
}

input:focus,
textarea:focus {
  border-color: var(--gold);
  box-shadow: 0 0 0 3px #c9a24b15;
  outline: none;
}

textarea {
  min-height: 140px;
  resize: vertical;
}

#status {
  min-height: 1.5rem;
  color: var(--gold2);
}

.hp {
  position: absolute;
  left: -9999px;
}

/* SOCIAL LINKS */

.socials {
  display: flex;
  gap: .9rem;
  flex-wrap: wrap;
  margin: 1.2rem 0;
}

.socials a {
  display: inline-grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border: 1px solid var(--line);
  border-radius: 50%;
  color: var(--gold);
  transition: all .3s ease;
}

.socials a:hover {
  border-color: var(--gold);
  background: #c9a24b18;
  color: var(--gold2);
  transform: translateY(-3px);
  box-shadow: 0 5px 18px var(--glow);
}

.socials svg {
  width: 20px;
  height: 20px;
  fill: currentColor;
}

/* FOOTER */

footer {
  border-top: 1px solid #c9a24b25;
  padding: 3rem 0;
  text-align: center;
  color: var(--mute);
  margin-top: 2rem;
  background: rgba(8, 7, 10, .82);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

/* DIALOG */

dialog {
  max-width: 700px;
  width: 92%;
  background: var(--panel);
  color: var(--text);
  border: 1px solid var(--gold);
  border-radius: 5px;
  padding: 2rem;
  box-shadow: 0 20px 80px #000b;
}

dialog::backdrop {
  background: #000d;
  backdrop-filter: blur(5px);
}

dialog img {
  max-width: 100%;
}

/* MOBILE */

@media (max-width: 720px) {
  body::before {
    background-position: center top;
  }

  header .wrap {
    min-height: 68px;
  }

  nav {
    gap: .9rem;
  }

  nav a {
    font-size: .9rem;
  }

  .hero {
    padding: 5rem 0 4rem;
  }

  section {
    padding: 3.5rem 0;
  }

  .grid {
    grid-template-columns: 1fr;
    gap: 1.3rem;
  }

  .card.featured {
    flex-direction: column;
  }

  .more {
    text-align: center;
  }
}

@media (max-width: 420px) {
  header .wrap {
    flex-direction: column;
    justify-content: center;
    gap: .4rem;
    padding-top: .7rem;
    padding-bottom: .7rem;
  }

  nav {
    gap: 1.2rem;
  }

  .hero h1 {
    font-size: 2.7rem;
  }
}

/* ACCESSIBILITY */

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