@import url("https://fonts.googleapis.com/css2?family=Barlow+Condensed:ital,wght@1,800&family=Manrope:wght@500;700;800&display=swap");

:root {
  --bg: #060a11;
  --bg-soft: #0b131f;
  --text: #eef4ff;
  --muted: #9cb0cf;
  --accent: #9dff3b;
  --line: rgba(160, 182, 212, 0.24);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: "Manrope", "Segoe UI", sans-serif;
  color: var(--text);
  background:
    radial-gradient(1200px 520px at 50% -20%, rgba(157, 255, 59, 0.08), transparent 70%),
    linear-gradient(180deg, #05080d 0%, #060b12 45%, #0a101a 100%);
}

.page {
  width: 100%;
  margin: 0 0 3rem;
}

.top-nav {
  position: relative;
  height: 64px;
  width: 100%;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 1rem;
  padding: 0 1.2rem;
  background: transparent;
  box-sizing: border-box;
  overflow: hidden;
}

.brand-title {
  justify-self: start;
  display: flex;
  align-items: center;
  min-width: 0;
}

.brand-logo {
  display: block;
  height: 32px;
  min-height: 32px;
  width: auto;
  max-width: min(64vw, 512px);
  filter:
    drop-shadow(0 0 7px rgba(157, 255, 59, 0.65))
    drop-shadow(0 0 16px rgba(157, 255, 59, 0.38));
}

.main-menu {
  display: flex;
  align-items: center;
  gap: 1rem;
  justify-self: center;
  height: 32px;
}

.menu-item {
  color: rgba(237, 242, 250, 0.84);
  text-decoration: none;
  font-family: "Barlow Condensed", "Manrope", "Avenir Next", "Segoe UI", sans-serif;
  font-size: 1.04rem;
  font-style: italic;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  transition: color 140ms ease;
  display: inline-flex;
  align-items: center;
  height: 32px;
}

.menu-item:hover {
  color: #fff;
}

.menu-item.active {
  color: var(--accent);
}

.login-button {
  justify-self: end;
  display: inline-flex;
  align-items: center;
  gap: 0.36rem;
  border: 0;
  border-radius: 999px;
  padding: 0 0.9rem;
  height: 32px;
  line-height: 1;
  font-size: 0.82rem;
  font-weight: 700;
  color: #071008;
  background: var(--accent);
  cursor: pointer;
  max-width: min(40vw, 340px);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.login-button.is-authenticated::before {
  content: "\1F464";
  font-size: 0.82rem;
  line-height: 1;
}

.login-button.is-open {
  box-shadow: 0 0 0 2px rgba(157, 255, 59, 0.35);
}

.account-dropdown {
  position: absolute;
  top: calc(100% - 0.35rem);
  right: 1.2rem;
  z-index: 80;
  display: grid;
  gap: 0.2rem;
  min-width: 180px;
  padding: 0.34rem;
  border-radius: 12px;
  border: 1px solid rgba(157, 255, 59, 0.28);
  background: rgba(10, 15, 23, 0.96);
  box-shadow: 0 16px 32px rgba(0, 0, 0, 0.42);
}

.account-dropdown.hidden {
  display: none;
}

.account-dropdown-item {
  border: 0;
  width: 100%;
  border-radius: 8px;
  padding: 0.52rem 0.62rem;
  text-align: left;
  text-decoration: none;
  background: transparent;
  color: #e4eefc;
  font-family: "Barlow Condensed", "Manrope", "Avenir Next", "Segoe UI", sans-serif;
  font-style: italic;
  font-weight: 800;
  font-size: 0.86rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  cursor: pointer;
}

.account-dropdown-item:hover {
  background: rgba(157, 255, 59, 0.12);
}

.account-dropdown-item.is-danger {
  color: #ffcfcf;
}

.hero {
  margin-top: 0;
  width: 100%;
  padding: 2.5rem clamp(1rem, 3vw, 2.4rem) 2rem;
  background:
    linear-gradient(180deg, rgba(10, 18, 31, 0.55), rgba(8, 14, 24, 0)),
    radial-gradient(circle at 80% 22%, rgba(157, 255, 59, 0.1), transparent 54%);
  border-top: 1px solid rgba(157, 176, 200, 0.2);
  border-bottom: 1px solid rgba(157, 176, 200, 0.2);
}

.hero-kicker {
  margin: 0;
  color: var(--accent);
  font-family: "Barlow Condensed", "Manrope", sans-serif;
  font-style: italic;
  font-size: 0.8rem;
  font-weight: 800;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.hero h1 {
  margin: 0.45rem 0 0;
  font-family: "Barlow Condensed", "Manrope", sans-serif;
  font-style: italic;
  font-size: clamp(2rem, 4.2vw, 3.7rem);
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.hero-copy {
  margin: 0.65rem 0 0;
  color: #bfd0e9;
  max-width: 72ch;
}

.list-section {
  margin-top: 0.9rem;
  width: 100%;
  padding: 1rem clamp(1rem, 3vw, 2.4rem) 1.3rem;
  background: linear-gradient(180deg, rgba(12, 19, 33, 0.42), rgba(10, 16, 28, 0));
  border-top: 1px solid rgba(157, 176, 200, 0.15);
}

.section-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 1rem;
  margin-bottom: 0.8rem;
}

.section-head h2 {
  margin: 0;
  font-family: "Barlow Condensed", "Manrope", sans-serif;
  font-style: italic;
  font-size: 1.2rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.section-head span {
  color: var(--muted);
  font-size: 0.86rem;
}

.item-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 0.72rem;
}

.item-card {
  position: relative;
  border: 1px solid rgba(166, 184, 210, 0.2);
  border-radius: 10px;
  padding: 0.72rem 0.62rem 0.62rem;
  background:
    linear-gradient(160deg, rgba(21, 31, 47, 0.62), rgba(11, 18, 29, 0.46));
  transition: transform 140ms ease, border-color 140ms ease, box-shadow 140ms ease;
}

.item-card:hover {
  transform: translateY(-2px);
  border-color: rgba(188, 214, 247, 0.56);
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.28);
}

.item-card img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: 8px;
  border: 1px solid rgba(174, 194, 219, 0.22);
  background: rgba(11, 18, 30, 0.84);
}

.item-card h3 {
  margin: 0.58rem 0 0.14rem;
  font-family: "Barlow Condensed", "Manrope", sans-serif;
  font-style: italic;
  font-size: 1rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.item-card p {
  margin: 0;
  color: #b8cae4;
  font-size: 0.82rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.rarity-common {
  box-shadow: inset 0 0 0 1px rgba(142, 158, 182, 0.16);
}

.rarity-uncommon {
  box-shadow: inset 0 0 0 1px rgba(142, 212, 152, 0.22);
}

.rarity-rare {
  box-shadow: inset 0 0 0 1px rgba(115, 180, 255, 0.24);
}

.rarity-epic {
  box-shadow: inset 0 0 0 1px rgba(173, 132, 255, 0.24);
}

.rarity-legendary {
  box-shadow: inset 0 0 0 1px rgba(255, 202, 84, 0.24);
}

.item-grid-empty .placeholder {
  display: grid;
  place-items: center;
  min-height: 150px;
  border-style: dashed;
}

@media (max-width: 860px) {
  .top-nav {
    grid-template-columns: auto 1fr auto;
    padding: 0 0.85rem;
  }

  .main-menu {
    gap: 0.65rem;
  }

  .menu-item {
    font-size: 0.74rem;
    letter-spacing: 0.07em;
  }

  .hero {
    padding: 1.3rem 0.85rem 1.1rem;
  }

  .item-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

body.auth-modal-open {
  overflow: hidden;
}

.auth-modal {
  position: fixed;
  inset: 0;
  z-index: 120;
  display: grid;
  place-items: center;
  padding: 1rem;
}

.auth-modal.hidden {
  display: none;
}

.auth-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(2, 6, 10, 0.74);
  backdrop-filter: blur(6px);
}

.auth-modal-dialog {
  position: relative;
  z-index: 1;
  width: min(92vw, 420px);
  border-radius: 18px;
  border: 1px solid rgba(157, 255, 59, 0.35);
  background:
    radial-gradient(circle at top right, rgba(157, 255, 59, 0.13), rgba(157, 255, 59, 0) 52%),
    linear-gradient(180deg, #111824 0%, #0b111a 100%);
  box-shadow:
    0 24px 48px rgba(0, 0, 0, 0.5),
    0 0 24px rgba(157, 255, 59, 0.15);
  padding: 1.2rem 1.2rem 1rem;
}

.auth-modal-close {
  position: absolute;
  top: 0.55rem;
  right: 0.55rem;
  border: 0;
  width: 2rem;
  height: 2rem;
  border-radius: 999px;
  font-size: 1.2rem;
  line-height: 1;
  color: #d7e5f8;
  background: rgba(255, 255, 255, 0.08);
  cursor: pointer;
}

.auth-modal-title {
  margin: 0 0 0.2rem;
  font-family: "Barlow Condensed", "Manrope", "Avenir Next", "Segoe UI", sans-serif;
  font-style: italic;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #f3ffe8;
}

.auth-modal-subtitle {
  margin: 0 0 1rem;
  color: #afc1da;
  font-size: 0.9rem;
}

.auth-modal-label {
  display: block;
  margin: 0.5rem 0 0.34rem;
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #b7c9e2;
}

.auth-modal-input {
  width: 100%;
  border: 1px solid rgba(190, 214, 242, 0.25);
  background: rgba(6, 11, 18, 0.86);
  color: #edf2fa;
  border-radius: 11px;
  padding: 0.62rem 0.7rem;
  font: inherit;
}

.auth-modal-input:focus {
  outline: 1px solid rgba(157, 255, 59, 0.7);
  border-color: rgba(157, 255, 59, 0.65);
}

.auth-modal-feedback {
  min-height: 1.2rem;
  margin: 0.75rem 0 0.65rem;
  font-size: 0.82rem;
  color: #c6d7ee;
}

.auth-modal-feedback.is-error {
  color: #ffd6d6;
}

.auth-modal-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.5rem;
}

.auth-modal-button {
  border: 0;
  border-radius: 10px;
  padding: 0.62rem 0.78rem;
  font-family: "Barlow Condensed", "Manrope", "Avenir Next", "Segoe UI", sans-serif;
  font-style: italic;
  font-weight: 800;
  font-size: 0.95rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  cursor: pointer;
}

.auth-modal-button:disabled {
  opacity: 0.65;
  cursor: default;
}

.auth-modal-button-primary {
  color: #09140d;
  background: var(--accent);
}

.auth-modal-button-secondary {
  color: #dce8f9;
  background: rgba(255, 255, 255, 0.12);
}
