/* web_store/store.css — Dark Fantasy Storefront Theme */
:root {
  --bg-main: #0a0d14;
  --bg-panel: #111726;
  --bg-card: #162035;
  --bg-card-hover: #1c2a46;
  --gold: #d4af37;
  --gold-bright: #ffd700;
  --gold-glow: rgba(212, 175, 55, 0.35);
  --cyan: #00d2ff;
  --cyan-glow: rgba(0, 210, 255, 0.3);
  --amber: #f59e0b;
  --red: #ef4444;
  --border: #2a3b5c;
  --border-gold: rgba(212, 175, 55, 0.4);
  --text-main: #e2e8f0;
  --text-muted: #94a3b8;
  --font-heading: 'Cinzel', serif;
  --font-body: 'Outfit', sans-serif;
  --font-mono: 'JetBrains Mono', monospace;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  background-color: var(--bg-main);
  color: var(--text-main);
  font-family: var(--font-body);
  line-height: 1.6;
  min-height: 100vh;
  position: relative;
  overflow-x: hidden;
}

/* Atmospheric Starfield / Glow */
.bg-stars {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background-image: radial-gradient(1px 1px at 20px 30px, #ffffff, rgba(0,0,0,0)),
                    radial-gradient(1px 1px at 40px 70px, #ffd700, rgba(0,0,0,0)),
                    radial-gradient(1px 1px at 90px 40px, #ffffff, rgba(0,0,0,0)),
                    radial-gradient(1.5px 1.5px at 160px 120px, #00d2ff, rgba(0,0,0,0));
  background-repeat: repeat;
  background-size: 250px 250px;
  opacity: 0.25;
  pointer-events: none;
  z-index: 0;
}

.bg-glow {
  position: fixed;
  top: -100px;
  left: 50%;
  transform: translateX(-50%);
  width: 900px;
  height: 500px;
  background: radial-gradient(circle, var(--gold-glow) 0%, rgba(10,13,20,0) 70%);
  pointer-events: none;
  z-index: 0;
}

/* Header */
.store-header {
  position: sticky;
  top: 0;
  background: rgba(17, 23, 38, 0.85);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  z-index: 100;
  padding: 16px 24px;
}

.header-container {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
}

.brand-logo {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
}

.brand-icon {
  font-size: 28px;
  filter: drop-shadow(0 0 10px var(--gold));
}

.brand-title {
  display: block;
  font-family: var(--font-heading);
  font-size: 20px;
  font-weight: 700;
  color: var(--gold-bright);
  letter-spacing: 2px;
}

.brand-sub {
  display: block;
  font-size: 10px;
  font-family: var(--font-mono);
  color: var(--cyan);
  letter-spacing: 3px;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

/* Account Binding Pill */
.account-badge {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--bg-card);
  border: 1px solid var(--border-gold);
  border-radius: 9999px;
  padding: 6px 16px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.account-badge:hover {
  background: var(--bg-card-hover);
  border-color: var(--gold-bright);
  box-shadow: 0 0 12px var(--gold-glow);
}

.pill-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--cyan);
  box-shadow: 0 0 8px var(--cyan);
}

.pill-label {
  font-size: 12px;
  color: var(--text-muted);
}

.pill-name {
  font-family: var(--font-mono);
  font-weight: 700;
  color: var(--gold-bright);
  font-size: 13px;
}

.btn-play {
  background: linear-gradient(135deg, #1e3a8a, #0284c7);
  color: #fff;
  text-decoration: none;
  font-family: var(--font-heading);
  font-size: 13px;
  font-weight: 700;
  padding: 8px 18px;
  border-radius: 6px;
  letter-spacing: 1px;
  border: 1px solid rgba(255,255,255,0.2);
  transition: all 0.2s ease;
}

.btn-play:hover {
  box-shadow: 0 0 16px var(--cyan-glow);
  transform: translateY(-1px);
}

/* Hero */
.hero-section {
  position: relative;
  z-index: 1;
  padding: 60px 24px 40px;
  text-align: center;
}

.hero-container {
  max-width: 800px;
  margin: 0 auto;
}

.hero-tag {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--gold);
  letter-spacing: 4px;
  border: 1px solid var(--border-gold);
  background: rgba(212, 175, 55, 0.08);
  padding: 4px 14px;
  border-radius: 4px;
  margin-bottom: 20px;
}

.hero-title {
  font-family: var(--font-heading);
  font-size: 42px;
  font-weight: 900;
  color: #fff;
  letter-spacing: 2px;
  margin-bottom: 16px;
  text-shadow: 0 0 20px rgba(0,0,0,0.8);
}

.hero-desc {
  font-size: 17px;
  color: var(--text-muted);
  margin-bottom: 32px;
}

.hero-desc strong {
  color: var(--gold-bright);
}

.hero-perks {
  display: flex;
  justify-content: center;
  gap: 16px;
  flex-wrap: wrap;
}

.perk-chip {
  background: rgba(22, 32, 53, 0.7);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 8px 16px;
  font-size: 13px;
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--text-main);
}

/* Catalog */
.catalog-section {
  position: relative;
  z-index: 1;
  padding: 20px 24px 80px;
}

.catalog-container {
  max-width: 1200px;
  margin: 0 auto;
}

.catalog-tabs {
  display: flex;
  justify-content: center;
  gap: 12px;
  margin-bottom: 36px;
  flex-wrap: wrap;
}

.tab-btn {
  background: var(--bg-panel);
  border: 1px solid var(--border);
  color: var(--text-muted);
  font-family: var(--font-heading);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 1px;
  padding: 10px 20px;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.tab-btn:hover {
  border-color: var(--gold);
  color: var(--text-main);
}

.tab-btn.active {
  background: rgba(212, 175, 55, 0.15);
  border-color: var(--gold-bright);
  color: var(--gold-bright);
  box-shadow: 0 0 12px var(--gold-glow);
}

/* Product Cards */
.products-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 24px;
}

.product-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 24px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: all 0.25s ease;
  position: relative;
  overflow: hidden;
}

.product-card:hover {
  transform: translateY(-4px);
  border-color: var(--gold);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5), 0 0 16px var(--gold-glow);
}

.card-badge {
  position: absolute;
  top: 14px;
  right: 14px;
  font-size: 10px;
  font-family: var(--font-mono);
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 4px;
  letter-spacing: 1px;
  text-transform: uppercase;
}

.badge-sub {
  background: rgba(0, 210, 255, 0.15);
  color: var(--cyan);
  border: 1px solid rgba(0, 210, 255, 0.4);
}

.badge-token {
  background: rgba(245, 158, 11, 0.15);
  color: var(--amber);
  border: 1px solid rgba(245, 158, 11, 0.4);
}

.badge-bundle {
  background: rgba(212, 175, 55, 0.2);
  color: var(--gold-bright);
  border: 1px solid var(--gold);
}

.product-icon {
  font-size: 38px;
  margin-bottom: 16px;
}

.product-title {
  font-family: var(--font-heading);
  font-size: 19px;
  font-weight: 700;
  color: #fff;
  margin-bottom: 8px;
}

.product-desc {
  font-size: 13px;
  color: var(--text-muted);
  margin-bottom: 20px;
  flex-grow: 1;
}

.product-price-bar {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding-top: 16px;
  margin-bottom: 16px;
}

.price-val {
  font-family: var(--font-heading);
  font-size: 24px;
  font-weight: 900;
  color: var(--gold-bright);
}

.price-term {
  font-size: 12px;
  font-family: var(--font-mono);
  color: var(--text-muted);
}

.btn-buy {
  width: 100%;
  background: linear-gradient(135deg, #d4af37, #b8860b);
  color: #0a0d14;
  border: none;
  font-family: var(--font-heading);
  font-size: 14px;
  font-weight: 800;
  letter-spacing: 1px;
  padding: 12px;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 8px;
}

.btn-buy:hover {
  background: linear-gradient(135deg, #ffd700, #d4af37);
  box-shadow: 0 0 16px var(--gold-glow);
  transform: translateY(-1px);
}

/* Modal */
.modal-overlay {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(8px);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 200;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
}

.modal-overlay.active {
  opacity: 1;
  pointer-events: auto;
}

.modal-card {
  background: var(--bg-panel);
  border: 1px solid var(--border-gold);
  border-radius: 12px;
  width: 90%;
  max-width: 480px;
  padding: 28px;
  box-shadow: 0 16px 40px rgba(0,0,0,0.8), 0 0 24px var(--gold-glow);
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
}

.modal-title {
  font-family: var(--font-heading);
  font-size: 20px;
  color: var(--gold-bright);
}

.modal-close {
  background: transparent;
  border: none;
  font-size: 24px;
  color: var(--text-muted);
  cursor: pointer;
}

.modal-desc {
  font-size: 13px;
  color: var(--text-muted);
  margin-bottom: 20px;
}

.input-group label {
  display: block;
  font-size: 12px;
  font-family: var(--font-mono);
  color: var(--gold);
  margin-bottom: 8px;
}

.input-group input {
  width: 100%;
  background: var(--bg-card);
  border: 1px solid var(--border);
  color: #fff;
  padding: 12px;
  border-radius: 6px;
  font-family: var(--font-mono);
  font-size: 14px;
  outline: none;
}

.input-group input:focus {
  border-color: var(--gold-bright);
  box-shadow: 0 0 10px var(--gold-glow);
}

.modal-footer {
  display: flex;
  justify-content: flex-end;
  gap: 12px;
  margin-top: 24px;
}

.btn-cancel {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text-muted);
  padding: 8px 16px;
  border-radius: 6px;
  cursor: pointer;
}

.btn-save {
  background: var(--gold);
  color: #0a0d14;
  border: none;
  font-family: var(--font-heading);
  font-weight: 700;
  padding: 8px 20px;
  border-radius: 6px;
  cursor: pointer;
}

/* Footer */
.store-footer {
  background: #07090e;
  border-top: 1px solid var(--border);
  padding: 40px 24px 24px;
  font-size: 13px;
  color: var(--text-muted);
}

.footer-container {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 32px;
  margin-bottom: 32px;
}

.footer-col h4 {
  font-family: var(--font-heading);
  font-size: 16px;
  color: var(--gold);
  margin-bottom: 12px;
}

.footer-col ul {
  list-style: none;
}

.footer-col ul li {
  margin-bottom: 8px;
}

.footer-col a {
  color: var(--cyan);
  text-decoration: none;
}

.footer-bottom {
  text-align: center;
  font-size: 11px;
  border-top: 1px solid rgba(255,255,255,0.05);
  padding-top: 20px;
  color: #64748b;
}
