@import url("https://fonts.googleapis.com/css2?family=Inter:ital,opsz,wght@0,14..32,100..900;1,14..32,100..900&family=Metamorphous&display=swap");

:root {
  --text-colour-primary: #E6E6E6;
  --text-colour-secondary: #BEBEBE;
  --text-colour-gold: #d4af37;
  --text-stat-label: #8a7560;
  --text-muted: #a0a0a0;
  --font-primary: Inter, sans-serif;
  --font-secondary: Metamorphous, serif;
  --bg-main: #111111;
  --bg-card: #1e1e1e;
  --bg-stat: #2c2c2c;
  --badge-bg: #5E548E;
  --genre-tag-bg: #2A241D;
}

body {
  background-color: var(--bg-main);
  color: var(--text-colour-primary);
  font-family: var(--font-primary);
}

.secondary-font {
  font-family: var(--font-secondary);
}

.card .signup-link {
  color: var(--text-colour-gold)
}

.modal .modal-content {
  background-color: transparent;
}

/* Nav Styling */
.nav-background-colour {
  background-color: var(--bg-main);
}

.navbar-toggler-icon {
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='%23c7c7c7' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
}

.navbar-toggler:focus {
  box-shadow: 0 0 0 0.2rem var(--text-colour-primary);
}

nav a,
.card a {
  color: var(--text-colour-primary);
  transition: color 0.3s ease;
  text-decoration: none;
}

nav a:hover,
.card a:hover {
  color: var(--text-colour-gold);
}

.navbar a.active {
  color: var(--text-colour-gold);
}

#title-span {
  font-family: "Metamorphous", serif;
}

.nav-span {
  font-family: "Inter", sans-serif;
  margin: auto 0.5rem;
}

/* Hero Section */
#hero {
  position: relative;
}

#hero-image {
  width: 100%;
  object-fit: cover;
  object-position: center;
  max-height: 25rem;
  z-index: 0;
}

.hero-image-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to top,
    rgba(10, 6, 2, 0.92) 0%,
    rgba(10, 6, 2, 0.55) 45%,
    rgba(10, 6, 2, 0.15) 100%
  );
  z-index: 1;
}

.hero-contents {
  z-index: 2;
  position: absolute;
  bottom: 2.5rem;
  left: 2rem;
  text-shadow:
    #000000 0.25rem 0.25rem 0.5rem,
    #000000 0rem 0rem 0.125rem;
  color: var(--text-colour-primary);
}

#hero-title {
  font-size: 4.25rem;
  margin-bottom: 1rem;
  font-weight: 800;
  font-family: var(--font-secondary);
}

@media screen and (max-width: 500px) {
  #hero-title {
    font-size: 2.5rem;
  }

  .hero-contents {
    bottom: 1rem;
  }

  .hero-strapline {
    font-size: 0.9rem;
  }
}

/* Search */
.search-form {
  display: flex;
  gap: 1.5rem;
  align-items: end;
}

#div_id_status {
  margin-bottom: 0rem;
}

/* Grid */
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(12.5rem, 1fr));
  gap: 1rem;
  padding: 1rem 0;
}

/* Card */
.card {
  background: var(--bg-card);
  border-radius: 0.75rem;
  display: flex;
  flex-direction: column;
}

.clickable {
  cursor: pointer;
  transition: all 0.15s ease;
}

.clickable:hover {
  transform: translateY(-1px);
  border: 1px solid var(--text-colour-gold);
  box-shadow: 0 2px 4px var(--text-colour-gold);
}

.sticky-stats {
  position: sticky;
  top: 3.65rem;
}

/* Card Image */
.card-img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border-radius: 0.55rem 0.55rem 0  0;
}

/* Card Body */
.card-body {
  display: flex;
  flex-direction: column;
  gap: 0.625rem;
  flex: 1;
}

/* Card Title */
.card-title {
  color: var(--text-colour-primary);
  font-family: var(--font-secondary);
}

/* Stats grid */
.stats-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.35rem;
}

.stat {
  background: var(--bg-stat);
  border-radius: 0.5rem;
  padding: 0.4375rem 0.5rem;
}

.stat-label {
  font-size: 0.625rem;
  color: var(--text-stat-label);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  display: block;
  margin-bottom: 0.125rem;
}

.stat-value {
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--text-colour-secondary);
}

/* Genre Pill Tag */
.genre-tag {
  background-color: var(--genre-tag-bg);
  color: var(--text-colour-primary);
  padding: 0.125rem 0.5rem;
  border-radius: 9999px;
  font-size: 0.8rem;
}

/* Star Bar */
.star-bar {
  position: relative;
  display: inline-block;
  font-size: 1.2rem;
  color: var(--text-colour-primary);
  letter-spacing: 0.125rem;
}

.star-bar::before {
  content: "★★★★★";
  color: var(--text-colour-primary); /* empty stars */
}

.star-fill {
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  overflow: hidden;
  white-space: nowrap;
  color: var(--text-colour-gold);
}

.star-fill::before {
  content: "★★★★★";
  display: block;
  width: var(--fill-width);
  overflow: hidden;
}

/* Button Styling  */
.btn-gold {
  background-color: var(--text-colour-gold);
  border: none;
  color: var(--bg-main);
}

.btn-gold:hover {
  background-color: var(--text-colour-gold);
}

.btn-outline-gold {
  background-color: transparent;
  border: 1px solid var(--text-colour-gold);
  color: var(--text-colour-gold);
}

.btn-outline-gold:hover {
  background: var(--text-colour-gold);
  color: var(--bg-main);
}

/* Badge styling  */
.badge-owned-bg {
  background-color: var(--badge-bg);
}

.badge-wishlist-bg {
  background-color: transparent;
  border: 1px solid var(--badge-bg);
  color: var(--badge-bg);
}

/* Game Detail Page Styling  */
.game-title {
  font-size: 2.5rem;
}

/* Reviews and Comments Section */
.reviews-title {
  margin: 3.5rem 0 1.25rem 0.25rem;
}

.left-border {
  border-left: 2px solid var(--bg-stat);
}

/* Game Session Detail Styling */
.sessions-title {
  margin: 3.5rem 0 1.25rem 0.25rem;
}

.session-duration {
  background: var(--bg-stat);
  color: var(--text-colour-secondary);
  border-radius: 9999px;
  font-size: 0.85rem;
  text-transform: uppercase;
  padding: 0.18rem 0.5rem;
  letter-spacing: 0.05rem;
}

/* Account Actions */
.account-card { 
  max-width: 35rem;
}

.my-close {
  color: var(--text-colour-gold) !important;
  background: transparent;
  border: none;
}

/* Game Forms */
.game-form-card {
  max-width: 47.3rem;
  margin: auto;
}

/* Utility Styling */
.muted {
  color: var(--text-muted);
}
.faded {
  opacity: 0.5;
}

.approval {
  font-size: 0.625rem;
  color: #DCBD5A;
  font-style: italic;
}

/* Forms Styling */

#div_id_genre_id > fieldset > div {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.5rem;
}

footer a {
  color: var(--text-colour-primary);
  text-decoration: none;
  transition: color 0.3s ease;
}

footer a:hover {
  color: var(--text-colour-gold);

}