:root {
  /* Brighter dark-gray palette inspired by isthereanydeal.com */
  --bg: #111827;
  /* base background: dark gray (brighter than near-black) */
  --card: #1f2937;
  /* cards and panels */
  --muted: #9aa4b2;
  /* lighter muted text for better readability */
  --accent: #7c3aed;
  /* preserved purple accent */
  --glass: rgba(255, 255, 255, 0.06);
  --surface: #0f1724;
  /* input surface */
  --white: #ffffff;
}

/* Base reset */
* {
  box-sizing: border-box
}

html,
body {
  height: 100%;
  margin: 0
}

ul {
  list-style: none;
  padding: 0;
  margin: 0
}

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



.container {
  margin: 0 auto;
  padding-top: 20px;
  display: grid;
  grid-template-columns: 1fr 400px;
  grid-template-rows: 50px auto;
  grid-template-areas: 
    "title sidebar"
    "deals sidebar";
}

.header {
  padding: 20px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.header-inner {
  display: flex;
  align-items: center;
  gap: 40px;
  justify-content: space-between;
}

.home-icon {
  font-weight: 700;
  font-size: 20px;
  color: var(--white);
}

.hero {
  padding: 48px 0 28px;
  text-align: center;
}

.hero-title {
  font-weight: 700;
  font-size: 28px;
  margin: 0 0 8px;
}

.hero-sub {
  color: var(--muted);
  margin: 0 0 18px;
}

.search-box {
  display: inline-block;
  width: 100%;
  max-width: 480px;
}

.search-container {
  position: relative;
}

.search-input {
  display: flex;
  gap: 8px;
  align-items: center;
}

.search-input input {
  flex: 1;
  padding: 12px 14px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: var(--surface);
  color: var(--white);
  outline: none;
  box-shadow: 0 6px 18px rgba(2, 6, 23, 0.6) inset;
}



.search-hints {
  position: absolute;
  left: 0;
  right: 0;
  top: 56px;
  /* Use a darker semi-opaque background and blur to match the new card tone */
  background: rgba(31, 41, 55, 0.92);
  backdrop-filter: blur(6px);
  border-radius: 8px;
  box-shadow: 0 8px 30px rgba(2, 6, 23, 0.6);
  padding: 8px;
  max-height: 260px;
  overflow: auto;
  z-index: 100;
}

.search-hints li {
  padding: 8px;
  border-radius: 6px;
  color: var(--white)
}

.search-hints li:hover {
  background: rgba(255, 255, 255, 0.03)
}

/* Wrapper where deals render */
.wrapper {
  font-family: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, 'Helvetica Neue', Arial;
  background: linear-gradient(180deg, #0f1724 0%, var(--bg) 60%);
  color: var(--white);
  -webkit-font-smoothing: antialiased;
  line-height: 1.4;
  min-height: 100vh;
  padding: 0 10%;
}

.deal {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 18px;
  margin-bottom: 12px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.04), rgba(255, 255, 255, 0.02));
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  box-shadow: 0 8px 24px rgba(2, 6, 23, 0.55);
}

.deal h2 {
  font-size: 16px;
  margin: 0 0 6px
}

.deal p {
  margin: 0;
  color: var(--muted);
  font-size: 13px
}

.deal a {
  margin-left: 12px;
  color: var(--accent);
  font-weight: 600
}

.deals-container {
  grid-area: deals;
  width: 100%
}

.game-list_header {
  display: grid;
  grid-template-columns: 1fr 120px 90px;
  gap: 8px;
  padding: 10px 14px;
  border-radius: 8px;
  color: var(--muted)
}

.game-list_link {
  display: grid;
  grid-template-columns: 1fr 120px 90px;
  gap: 8px;
  padding: 10px 14px;
  border-radius: 8px
}

.game-list_link:hover {
  background: rgba(255, 255, 255, 0.03)
}

.title {
  font-size: 20px;
  grid-area: title;
}

.footer {
  padding: 20px 0;
  color: var(--muted);
  text-align: center;
  border-top: 1px solid rgba(255, 255, 255, 0.06)
}

.footer a {
  color: var(--muted)
}

/* Small screens */
@media (max-width:720px) {
  .hero-title {
    font-size: 20px
  }

  .game-list_header,
  .game-list_link {
    grid-template-columns: 1fr 100px 80px
  }

  .search-input {
    flex-direction: row
  }

  .search-input input {
    padding: 10px
  }

  .deal {
    flex-direction: column;
    align-items: flex-start
  }
}

/* Auth UI */
.auth-area {
  display: flex;
  gap: 8px;
  align-items: center
}

.user-status {
  color: var(--muted);
  font-size: 14px
}

.btn {
  padding: 8px 12px;
  border-radius: 8px;
  border: none;
  background: linear-gradient(90deg, var(--accent), #5b21b6);
  color: white;
  cursor: pointer
}

.btn.small {
  padding: 6px 10px;
  font-size: 13px
}

.btn.ghost {
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.06)
}

.hidden {
  display: none !important
}

.auth-modal {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.5);
  z-index: 300
}

.auth-modal_inner {
  width: 360px;
  background: var(--card);
  padding: 20px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.04)
}

.auth-modal input {
  width: 100%;
  padding: 10px;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  margin: 8px 0;
  background: var(--surface);
  color: var(--white)
}

.auth-actions {
  display: flex;
  gap: 8px;
  justify-content: flex-end;
  margin-top: 8px
}

.auth-toggle {
  color: var(--muted);
  font-size: 13px;
  margin-top: 8px
}

.auth-message {
  color: var(--muted);
  margin-top: 8px;
  font-size: 13px
}


.logged-in-section {
  gap: 20px;
}




















.app-container {
  inset: 0;
  display: flex;
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  flex-direction: column;
  justify-content: center;
  align-items: center;
  min-height: 100vh;
  width: 100%;
  padding: 1rem;
}

.loading-state,
.error-state {
  padding: 10px 16px;
  border-radius: 10px;
  background-color: #2d313c;
  text-align: center;
}

.loading-text {
  font-weight: 600;
  color: #a0aec0;
  animation: pulse 1.5s infinite ease-in-out;
}

.error-state {
  background-color: #c53030;
  color: #fff;
}

.error-title {
  font-size: 2.8rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
}

.error-message {
  font-size: 1.3rem;
  margin-bottom: 0.5rem;
}

.error-sub-message {
  font-size: 1rem;
  opacity: 0.8;
}


.auth0-logo {
  width: 160px;
  margin-bottom: 1.5rem;
  opacity: 0;
  animation: slideInDown 1s ease-out forwards 0.2s;
}


.action-card {}

.action-text {
  font-size: 1.25rem;
  color: #cbd5e0;
  text-align: center;
  line-height: 1.6;
  font-weight: 400;
}

.button {
  padding: 10px 16px;
  font-weight: 600;
  border-radius: 10px;
  border: none;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.4);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  outline: none;
}

.button:focus {
  box-shadow: 0 0 0 4px rgba(99, 179, 237, 0.5);
}

.button.login {
  background-color: #63b3ed;
  color: #1a1e27;
}

.button.login:hover {
  background-color: #4299e1;
  transform: translateY(-5px) scale(1.03);
  box-shadow: 0 12px 25px rgba(0, 0, 0, 0.5);
}

.button.logout {
  background-color: #fc8181;
  color: #1a1e27;
}

.button.logout:hover {
  background-color: #e53e3e;
}






/* Animations */
@keyframes fadeIn {
  from {
    opacity: 0;
  }

  to {
    opacity: 1;
  }
}

@keyframes fadeInScale {
  from {
    opacity: 0;
    transform: scale(0.95);
  }

  to {
    opacity: 1;
    transform: scale(1);
  }
}

@keyframes slideInDown {
  from {
    opacity: 0;
    transform: translateY(-70px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes slideInUp {
  from {
    opacity: 0;
    transform: translateY(50px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes pulse {

  0%,
  100% {
    opacity: 1;
  }

  50% {
    opacity: 0.6;
  }
}

@keyframes scaleIn {
  from {
    opacity: 0;
    transform: scale(0.8);
  }

  to {
    opacity: 1;
    transform: scale(1);
  }
}

/* Responsive Design */
@media (max-width: 600px) {

  .auth0-logo {
    width: 120px;
  }

  .action-card {
    padding: 2rem;
  }
}

.profile-picture {
  width: 40px;
  height: 40px;
  border-radius: 50%;
}




.game-sidebar {
  max-width: 400px;
  grid-area: sidebar;
}

.game-sidebar_banner {}

.game-sidebar_block {}

.game-sidebar_tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.game-sidebar_tag {
  padding: 2px 8px;
  background-color: red;
  border-radius: 50%;
}

.game-sidebar_description {
  margin: 20px 0;
  max-height: 250px;
  height: 250px;
  overflow-y: auto;
  overflow-x: hidden;
  line-height: 120%;
}

.game-sidebar_metacritic {
  display: flex;
  justify-content: flex-end;
  gap: 4px;
}

.game-sidebar_metacritic a {
  display: inline;
  color: var(--accent);
  text-decoration: underline;
}

.game-sidebar_metacritic a:after {
  content: "↗";
  margin-left: 4px;
  font-size: 0.8rem;
}