/* ==========================================================================
   LucasArts SCUMM Universe Hub Portal Theme
   ========================================================================== */

:root {
  --bg-main: #0a0c12;
  --bg-surface: #121520;
  --bg-card: #181c2b;
  --bg-card-hover: #22283e;
  --border: #252b3d;
  --border-light: #3a435f;
  
  --text-main: #f0f3f8;
  --text-muted: #8b95b5;
  --text-dim: #5c6480;
  
  --accent-purple: #8b5cf6;
  --accent-purple-glow: rgba(139, 92, 246, 0.3);
  --accent-tentacle: #10b981;
  --accent-tentacle-glow: rgba(16, 185, 129, 0.3);
  --accent-gold: #f59e0b;
  --accent-blue: #3b82f6;
  
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  background-color: var(--bg-main);
  color: var(--text-main);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* Header */
header {
  background: var(--bg-surface);
  border-bottom: 1px solid var(--border);
  padding: 1.25rem 2rem;
  box-shadow: 0 4px 25px rgba(0, 0, 0, 0.5);
}

.header-inner {
  max-width: 1400px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  flex-wrap: wrap;
}

.logo-group {
  display: flex;
  align-items: center;
  gap: 1.25rem;
}

.tentacle-icon {
  font-size: 2.2rem;
  background: #1b132e;
  border: 1px solid #4a2f7c;
  border-radius: var(--radius-md);
  padding: 0.4rem 0.6rem;
  box-shadow: 0 0 15px var(--accent-purple-glow);
}

h1 {
  font-size: 1.4rem;
  font-weight: 800;
  letter-spacing: -0.5px;
  color: #fff;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.subtitle {
  color: var(--text-muted);
  font-size: 0.85rem;
  margin-top: 0.2rem;
}

.header-stats {
  display: flex;
  gap: 1.5rem;
}

.stat-box {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
}

.stat-num {
  font-size: 1.4rem;
  font-weight: 800;
  color: #fff;
  line-height: 1.1;
}

.stat-lbl {
  font-size: 0.72rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* Badges */
.badge {
  font-size: 0.7rem;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 4px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  white-space: nowrap;
}

.badge-purple { background: rgba(139, 92, 246, 0.2); color: #c4b5fd; border: 1px solid #6d28d9; }
.badge-tentacle { background: rgba(16, 185, 129, 0.2); color: #6ee7b7; border: 1px solid #059669; }
.badge-engine { background: rgba(59, 130, 246, 0.2); color: #93c5fd; border: 1px solid #2563eb; }
.badge-sso { background: rgba(245, 158, 11, 0.2); color: #fcd34d; border: 1px solid #d97706; }
.badge-next { background: rgba(245, 158, 11, 0.25); color: #fbbf24; border: 1px solid #b45309; }
.badge-queued { background: rgba(100, 116, 139, 0.25); color: #cbd5e1; border: 1px solid #475569; }

/* Category Navigation */
.category-nav {
  background: #0e111a;
  border-bottom: 1px solid var(--border);
  padding: 0.75rem 2rem;
  position: sticky;
  top: 0;
  z-index: 90;
  backdrop-filter: blur(10px);
}

.nav-container {
  max-width: 1400px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  flex-wrap: wrap;
}

.category-tabs {
  display: flex;
  gap: 0.5rem;
  overflow-x: auto;
  padding-bottom: 2px;
}

.cat-tab {
  background: var(--bg-surface);
  color: var(--text-muted);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 0.5rem 0.9rem;
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.2s;
}

.cat-tab:hover {
  background: var(--bg-card);
  color: var(--text-main);
  border-color: var(--border-light);
}

.cat-tab.active {
  background: var(--accent-purple);
  color: #fff;
  border-color: var(--accent-purple);
  box-shadow: 0 2px 10px var(--accent-purple-glow);
}

.search-box input {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  color: var(--text-main);
  padding: 0.5rem 1rem;
  border-radius: var(--radius-sm);
  font-size: 0.85rem;
  width: 280px;
  transition: all 0.2s;
}

.search-box input:focus {
  outline: none;
  border-color: var(--accent-purple);
  box-shadow: 0 0 10px var(--accent-purple-glow);
}

/* Main */
.main-content {
  max-width: 1400px;
  margin: 0 auto;
  padding: 2rem;
  width: 100%;
  flex: 1;
}

/* Hero Spotlight */
.hero-spotlight {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid #4a2f7c;
  margin-bottom: 2.5rem;
  min-height: 380px;
  display: flex;
  align-items: center;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.6);
}

.hero-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center 20%;
  filter: blur(2px) brightness(0.65);
  transform: scale(1.04);
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(10, 12, 18, 0.95) 0%, rgba(10, 12, 18, 0.85) 45%, rgba(10, 12, 18, 0.5) 100%);
}

.hero-content {
  position: relative;
  z-index: 2;
  padding: 2.5rem;
  max-width: 780px;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.hero-badge-row {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.hero-logo {
  max-height: 100px;
  max-width: 380px;
  object-fit: contain;
  filter: drop-shadow(0 4px 15px rgba(0, 0, 0, 0.8));
}

.hero-synopsis {
  color: #cbd5e1;
  font-size: 0.95rem;
  line-height: 1.5;
}

.hero-stats-row {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.hero-stat-pill {
  background: rgba(0, 0, 0, 0.5);
  border: 1px solid rgba(255, 255, 255, 0.1);
  padding: 4px 10px;
  border-radius: 20px;
  font-size: 0.75rem;
  color: #f1f5f9;
}

.hero-actions {
  display: flex;
  gap: 0.75rem;
  margin-top: 0.5rem;
  flex-wrap: wrap;
}

.btn-primary {
  background: var(--accent-purple);
  color: #fff;
  border: none;
  padding: 0.75rem 1.4rem;
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
  font-weight: 700;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  box-shadow: 0 4px 15px var(--accent-purple-glow);
  transition: all 0.2s;
}

.btn-primary:hover {
  filter: brightness(1.15);
  transform: translateY(-1px);
}

.btn-secondary {
  background: var(--bg-surface);
  color: var(--text-main);
  border: 1px solid var(--border-light);
  padding: 0.75rem 1.25rem;
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
  font-weight: 600;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  transition: all 0.2s;
}

.btn-secondary:hover {
  background: var(--bg-card);
  border-color: var(--accent-purple);
}

.btn-toolbar {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  color: var(--text-main);
  border-radius: var(--radius-sm);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  transition: all 0.2s;
}

.btn-toolbar:hover {
  border-color: var(--accent-purple);
  background: var(--bg-card);
}

/* Games Library Grid */
.section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.5rem;
}

.section-header h2 {
  font-size: 1.3rem;
  font-weight: 700;
}

.games-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(360px, 1fr));
  gap: 1.5rem;
}

.game-card {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: all 0.25s ease;
  position: relative;
}

.game-card:hover {
  border-color: var(--border-light);
  transform: translateY(-3px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.4);
}

.game-card.active-card {
  border-color: #5b21b6;
}

.game-card-banner {
  height: 140px;
  position: relative;
  background-size: cover;
  background-position: center 30%;
}

.game-card-banner-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(18, 21, 32, 0.2) 0%, rgba(18, 21, 32, 0.95) 100%);
}

.game-card-logo {
  position: absolute;
  bottom: 12px;
  left: 16px;
  max-height: 52px;
  max-width: 200px;
  object-fit: contain;
  filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.8));
}

.game-card-status-badge {
  position: absolute;
  top: 10px;
  right: 12px;
}

.game-card-body {
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  flex: 1;
}

.game-card-title-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 0.5rem;
}

.game-card-title {
  font-size: 1.05rem;
  font-weight: 700;
  color: #fff;
}

.game-card-meta {
  font-size: 0.75rem;
  color: var(--text-muted);
}

.game-card-synopsis {
  font-size: 0.82rem;
  color: #94a3b8;
  line-height: 1.45;
  flex: 1;
}

.game-card-stats {
  font-size: 0.75rem;
  color: var(--text-muted);
  background: rgba(0, 0, 0, 0.25);
  padding: 6px 10px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
}

.game-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  margin-top: 0.5rem;
  padding-top: 0.75rem;
  border-top: 1px solid var(--border);
}

.btn-card-launch {
  flex: 1;
  text-align: center;
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  color: #fff;
  padding: 0.5rem 0.75rem;
  border-radius: var(--radius-sm);
  font-size: 0.8rem;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.2s;
}

.btn-card-launch:hover {
  background: var(--accent-purple);
  border-color: var(--accent-purple);
}

.btn-card-launch.active-btn {
  background: var(--accent-purple);
  border-color: var(--accent-purple);
}

.btn-card-launch.active-btn:hover {
  filter: brightness(1.15);
}

/* Toast */
.toast-notify {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  background: #1e1b4b;
  color: #c7d2fe;
  border: 1px solid #4338ca;
  padding: 0.75rem 1.25rem;
  border-radius: var(--radius-md);
  font-size: 0.85rem;
  font-weight: 600;
  display: none;
  z-index: 999;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.5);
}

/* Footer */
.hub-footer {
  background: var(--bg-surface);
  border-top: 1px solid var(--border);
  padding: 1.5rem 2rem;
  text-align: center;
  margin-top: auto;
}

.footer-inner {
  max-width: 1400px;
  margin: 0 auto;
}
