/* ================================================================
   Genesis Cheats — Site styles (v5.7)
   System fonts only — no Google Fonts, no local files, works everywhere
   ================================================================ */

:root {
  --bg: #0a0b12;
  --bg-2: #12141d;
  --card: #171922;
  --card-hover: #1c1f2a;
  --border: rgba(255, 255, 255, 0.06);
  --border-hover: rgba(255, 255, 255, 0.12);
  --border-strong: rgba(255, 255, 255, 0.2);
  --text: #f0f2f8;
  --text-dim: #a0a5b8;
  --text-mute: #6b6f80;
  --brand-1: #8b5cf6;
  --brand-2: #3b82f6;
  --grad: linear-gradient(135deg, #8b5cf6 0%, #3b82f6 100%);
  --grad-soft: linear-gradient(135deg, rgba(139, 92, 246, 0.12), rgba(59, 130, 246, 0.12));
  --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.4);
  --shadow-lg: 0 20px 60px rgba(0, 0, 0, 0.5);
  --star: #ffb020;
  --header-h: 70px;

  /* System font stacks — works everywhere without downloads */
  --font-sans: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI Variable", "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif, "Apple Color Emoji", "Segoe UI Emoji";
  --font-mono: ui-monospace, "Cascadia Mono", "Segoe UI Mono", "SF Mono", Menlo, Consolas, "Courier New", monospace;
}

[data-theme="light"] {
  --bg: #f7f8fc;
  --bg-2: #ffffff;
  --card: #ffffff;
  --card-hover: #f0f2f8;
  --border: rgba(0, 0, 0, 0.06);
  --border-hover: rgba(0, 0, 0, 0.12);
  --border-strong: rgba(0, 0, 0, 0.2);
  --text: #0e1220;
  --text-dim: #4a5165;
  --text-mute: #8a90a0;
  --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.05);
  --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.08);
  --shadow-lg: 0 20px 60px rgba(0, 0, 0, 0.12);
}

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

html, body {
  font-family: var(--font-sans);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

body {
  overflow-x: clip;
  padding-top: var(--header-h);
}

/* ============ CUSTOM SCROLLBAR ============ */
* { scrollbar-width: thin; scrollbar-color: rgba(139, 92, 246, 0.5) transparent; }

*::-webkit-scrollbar { width: 10px; height: 10px; }
*::-webkit-scrollbar-track { background: transparent; }
*::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, rgba(139, 92, 246, 0.5), rgba(59, 130, 246, 0.5));
  border-radius: 100px;
  border: 2px solid transparent;
  background-clip: padding-box;
  transition: background 0.2s;
}
*::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(180deg, rgba(139, 92, 246, 0.85), rgba(59, 130, 246, 0.85));
  background-clip: padding-box;
  border: 2px solid transparent;
}
*::-webkit-scrollbar-corner { background: transparent; }

.categories-scroll::-webkit-scrollbar,
.stats-subtabs::-webkit-scrollbar { display: none; }

/* ============ BACKGROUND ============ */
.bg-grid {
  position: fixed; inset: 0;
  background-image:
    linear-gradient(var(--border) 1px, transparent 1px),
    linear-gradient(90deg, var(--border) 1px, transparent 1px);
  background-size: 60px 60px;
  opacity: 0.4;
  pointer-events: none;
  z-index: 0;
  mask-image: linear-gradient(to bottom, rgba(0,0,0,1) 0%, rgba(0,0,0,0.3) 60%, rgba(0,0,0,0) 100%);
}
.bg-glow {
  position: fixed;
  border-radius: 50%;
  filter: blur(120px);
  opacity: 0.5;
  pointer-events: none;
  z-index: 0;
}
.bg-glow-1 { top: -200px; left: -200px; width: 500px; height: 500px; background: #8b5cf6; }
.bg-glow-2 { top: 200px; right: -200px; width: 500px; height: 500px; background: #3b82f6; }
[data-theme="light"] .bg-glow { opacity: 0.15; }

.container { max-width: 1240px; margin: 0 auto; padding: 0 24px; position: relative; z-index: 1; }

/* ============ HEADER — FIXED ============ */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  width: 100%;
  z-index: 1000;
  background: rgba(10, 11, 18, 0.9);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
  height: var(--header-h);
  display: flex;
  align-items: center;
}
[data-theme="light"] .header { background: rgba(247, 248, 252, 0.9); }

.header-inner {
  display: flex; align-items: center; justify-content: space-between;
  gap: 20px;
  width: 100%;
}

.logo { display: flex; align-items: center; gap: 12px; text-decoration: none; color: var(--text); }
.logo-img { width: 40px; height: 40px; border-radius: 10px; object-fit: cover; }
.logo-img.logo-light { display: none; }
[data-theme="light"] .logo-img.logo-dark { display: none; }
[data-theme="light"] .logo-img.logo-light { display: block; }
.logo-fallback {
  display: none;
  width: 40px; height: 40px;
  border-radius: 10px;
  background: var(--grad);
  color: white;
  align-items: center; justify-content: center;
  font-weight: 900; font-size: 20px;
}
.logo-fallback.active { display: flex; }
.logo-text { display: flex; flex-direction: column; line-height: 1.1; }
.logo-title { font-weight: 800; font-size: 15px; }
.logo-sub { font-size: 11px; color: var(--text-mute); font-weight: 500; }

.nav { display: flex; gap: 24px; }
.nav-link {
  color: var(--text-dim); text-decoration: none; font-size: 14px; font-weight: 500;
  transition: color 0.2s;
}
.nav-link:hover { color: var(--text); }

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

.theme-toggle {
  width: 40px; height: 40px; border-radius: 10px;
  background: var(--card); border: 1px solid var(--border);
  cursor: pointer; color: var(--text);
  display: flex; align-items: center; justify-content: center;
  transition: all 0.2s;
}
.theme-toggle:hover { border-color: var(--border-hover); background: var(--card-hover); }
.theme-toggle .icon-sun, .theme-toggle .icon-moon { width: 18px; height: 18px; }
.theme-toggle .icon-sun { display: none; }
.theme-toggle .icon-moon { display: block; }
[data-theme="light"] .theme-toggle .icon-sun { display: block; }
[data-theme="light"] .theme-toggle .icon-moon { display: none; }

/* ============ BUTTONS ============ */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 10px 18px;
  border-radius: 10px;
  border: 1px solid transparent;
  cursor: pointer;
  font-family: inherit; font-size: 14px; font-weight: 600;
  text-decoration: none;
  transition: all 0.2s;
  white-space: nowrap;
}
.btn svg { width: 16px; height: 16px; }
.btn-lg { padding: 14px 24px; font-size: 15px; }
.btn-sm { padding: 8px 14px; font-size: 13px; }

.btn-primary {
  background: var(--grad);
  color: white;
  box-shadow: 0 6px 18px rgba(139, 92, 246, 0.35);
}
.btn-primary:hover:not(:disabled) {
  transform: translateY(-1px);
  box-shadow: 0 10px 28px rgba(139, 92, 246, 0.5);
}
.btn-primary:disabled { opacity: 0.5; cursor: not-allowed; box-shadow: none; }

.btn-ghost {
  background: var(--card);
  border-color: var(--border);
  color: var(--text);
}
.btn-ghost:hover { background: var(--card-hover); border-color: var(--border-hover); }

.btn-danger {
  background: linear-gradient(135deg, #ff5c5c, #cc2c2c);
  color: white;
  box-shadow: 0 6px 18px rgba(255, 92, 92, 0.35);
}
.btn-danger:hover { transform: translateY(-1px); box-shadow: 0 10px 28px rgba(255, 92, 92, 0.5); }

/* ============ HERO ============ */
.hero { padding: 60px 0 80px; text-align: center; position: relative; }
.hero-badge {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 8px 16px;
  background: var(--card); border: 1px solid var(--border);
  border-radius: 100px;
  font-size: 13px; color: var(--text-dim);
  margin-bottom: 24px;
}
.hero-badge-dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: #10d876;
  box-shadow: 0 0 12px #10d876;
  animation: pulse 2s ease infinite;
}
@keyframes pulse { 0%,100% { opacity: 1; } 50% { opacity: 0.5; } }

.hero-title {
  font-size: clamp(36px, 6vw, 64px);
  font-weight: 900;
  line-height: 1.1;
  letter-spacing: -0.02em;
  margin-bottom: 20px;
}
.hero-title span { display: inline-block; }
.hero-gradient {
  background: var(--grad);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-desc { font-size: 17px; color: var(--text-dim); max-width: 620px; margin: 0 auto 32px; }
.hero-actions { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; margin-bottom: 60px; }

.hero-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  max-width: 640px;
  margin: 0 auto;
  padding: 24px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 16px;
}
.hero-stat-val {
  font-size: 32px; font-weight: 800; line-height: 1;
  background: var(--grad);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  margin-bottom: 4px;
}
.hero-stat-lbl { font-size: 12px; color: var(--text-mute); text-transform: uppercase; letter-spacing: 0.05em; font-weight: 600; }

/* ============ SECTIONS ============ */
.section { padding: 60px 0; position: relative; scroll-margin-top: calc(var(--header-h) + 20px); }

.section-title-block {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 24px;
}
.section-title-icon {
  width: 52px;
  height: 52px;
  border-radius: 14px;
  background: var(--grad-soft);
  border: 1px solid var(--border-hover);
  color: var(--brand-1);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.section-title-icon svg { width: 22px; height: 22px; }
.section-title-lg {
  font-size: clamp(22px, 3vw, 32px);
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.2;
}
.section-title-sub {
  color: var(--text-mute);
  font-size: 14px;
  margin-top: 2px;
}

/* ============ CATALOG TOOLBAR ============ */
.catalog-toolbar {
  display: flex;
  gap: 12px;
  margin-bottom: 20px;
  align-items: stretch;
}
.search-wrap { position: relative; flex: 1; }
.search-icon {
  position: absolute; left: 16px; top: 50%; transform: translateY(-50%);
  color: var(--text-mute); display: flex;
}
.search-icon svg { width: 16px; height: 16px; }
.search-input {
  width: 100%; padding: 14px 16px 14px 44px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 12px;
  color: var(--text);
  font-family: inherit; font-size: 14px;
  transition: all 0.2s;
}
.search-input:focus {
  outline: none;
  border-color: var(--brand-1);
  box-shadow: 0 0 0 4px rgba(139, 92, 246, 0.15);
}

.type-dropdown { position: relative; flex-shrink: 0; }
.type-dropdown-btn {
  display: flex; align-items: center; gap: 10px;
  padding: 14px 18px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 12px;
  color: var(--text);
  cursor: pointer;
  font-family: inherit;
  font-size: 14px;
  font-weight: 600;
  transition: all 0.2s;
  min-width: 160px;
  justify-content: space-between;
  height: 100%;
}
.type-dropdown-btn:hover { border-color: var(--border-hover); background: var(--card-hover); }
.type-dropdown-btn b { font-weight: 700; color: var(--brand-1); }
.type-dropdown-label { color: var(--text-dim); font-weight: 500; }
.type-dropdown-arrow { display: flex; transition: transform 0.2s; }
.type-dropdown-arrow svg { width: 16px; height: 16px; }
.type-dropdown.open .type-dropdown-arrow { transform: rotate(180deg); }

.type-dropdown-menu {
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  min-width: 200px;
  background: var(--card);
  border: 1px solid var(--border-hover);
  border-radius: 12px;
  padding: 6px;
  box-shadow: var(--shadow-lg);
  opacity: 0;
  transform: translateY(-6px);
  pointer-events: none;
  transition: all 0.2s;
  z-index: 50;
}
.type-dropdown.open .type-dropdown-menu {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}
.type-dropdown-item {
  display: flex; align-items: center; gap: 10px;
  width: 100%;
  padding: 10px 12px;
  background: transparent;
  border: none;
  color: var(--text-dim);
  cursor: pointer;
  font-family: inherit; font-size: 13px; font-weight: 600;
  border-radius: 8px;
  transition: background 0.15s;
  text-align: left;
}
.type-dropdown-item:hover { background: var(--bg); color: var(--text); }
.type-dropdown-item.active { background: var(--grad-soft); color: var(--brand-1); }
.type-dot { width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; }

@media (max-width: 600px) {
  .catalog-toolbar { flex-direction: column; }
  .type-dropdown-btn { width: 100%; }
  .type-dropdown-menu { right: auto; left: 0; width: 100%; }
}

/* ============ CATEGORIES ============ */
.categories-wrap {
  position: relative;
  margin-bottom: 24px;
  display: flex;
  align-items: center;
}
.categories-scroll {
  display: flex; gap: 8px;
  overflow-x: auto;
  scroll-behavior: smooth;
  scrollbar-width: none;
  -ms-overflow-style: none;
  padding: 4px 0;
  flex: 1;
}
.categories-scroll::-webkit-scrollbar { display: none; }

.cat-item {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 10px 16px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 12px;
  color: var(--text-dim);
  cursor: pointer;
  font-family: inherit; font-size: 13px; font-weight: 600;
  transition: all 0.2s;
  white-space: nowrap;
  flex-shrink: 0;
}
.cat-item:hover:not(.active) { color: var(--text); border-color: var(--border-hover); background: var(--card-hover); }
.cat-item.active {
  background: var(--grad);
  color: white;
  border-color: transparent;
  box-shadow: 0 4px 12px rgba(139, 92, 246, 0.3);
}
.cat-item-icon { display: inline-flex; }
.cat-item-icon svg { width: 15px; height: 15px; }
.cat-item-count {
  padding: 2px 8px;
  background: rgba(0, 0, 0, 0.2);
  border-radius: 100px;
  font-size: 11px;
  font-weight: 700;
  font-family: var(--font-mono);
}
[data-theme="light"] .cat-item:not(.active) .cat-item-count { background: rgba(0, 0, 0, 0.06); }
.cat-item.active .cat-item-count { background: rgba(255, 255, 255, 0.25); }

.cat-scroll-btn {
  width: 36px; height: 36px;
  border-radius: 50%;
  background: var(--card);
  border: 1px solid var(--border-hover);
  color: var(--text);
  cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  box-shadow: var(--shadow-sm);
  transition: all 0.2s;
  flex-shrink: 0;
  margin: 0 6px;
  opacity: 1;
}
.cat-scroll-btn:hover:not(.disabled) {
  background: var(--card-hover);
  border-color: var(--brand-1);
  color: var(--brand-1);
  transform: scale(1.05);
}
.cat-scroll-btn.disabled {
  opacity: 0.35;
  cursor: not-allowed;
  color: var(--text-mute);
  border-color: var(--border);
  background: var(--bg-2);
}
.cat-scroll-btn.disabled:hover {
  transform: none;
  background: var(--bg-2);
}
.cat-scroll-btn svg { width: 16px; height: 16px; }

@media (max-width: 700px) {
  .cat-scroll-btn { display: none; }
  .cat-item { padding: 8px 12px; font-size: 12px; }
}

/* ============ PRODUCTS GRID ============ */
.products-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}
@media (max-width: 1100px) { .products-grid { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 800px) { .products-grid { grid-template-columns: repeat(2, 1fr); gap: 14px; } }
@media (max-width: 480px) { .products-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; } }

.product-card {
  display: flex; flex-direction: column;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 16px;
  overflow: hidden;
  text-decoration: none;
  color: var(--text);
  transition: all 0.25s ease;
  position: relative;
}
.product-card:hover {
  transform: translateY(-4px);
  border-color: var(--border-hover);
  box-shadow: var(--shadow-md);
}
.product-card:hover .product-card-media img { transform: scale(1.05); }

.product-card-media {
  position: relative;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: var(--bg-2);
}
.product-card-media img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform 0.35s ease;
}
.product-card-media-placeholder {
  display: flex; align-items: center; justify-content: center;
  width: 100%; height: 100%;
  color: var(--text-mute); opacity: 0.4;
}
.product-card-media-placeholder svg { width: 60px; height: 60px; }

.product-card-badge {
  position: absolute; top: 10px; right: 10px;
  padding: 4px 10px;
  background: rgba(139, 92, 246, 0.85);
  color: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: 100px;
  font-size: 10px; font-weight: 800;
  letter-spacing: 0.05em;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.product-card-body { padding: 14px; display: flex; flex-direction: column; gap: 10px; flex: 1; }

.product-card-info-row {
  display: flex;
  align-items: center;
  gap: 12px;
}
.product-card-logo {
  width: 40px; height: 40px;
  border-radius: 10px;
  object-fit: cover;
  flex-shrink: 0;
  border: 1px solid var(--border);
  background: var(--bg);
}
.product-card-text { flex: 1; min-width: 0; }
.product-card-cat {
  font-size: 11px;
  color: var(--brand-1);
  font-weight: 800;
  letter-spacing: 0.05em;
  margin-bottom: 2px;
}
.product-card-title {
  font-size: 15px;
  font-weight: 700;
  line-height: 1.3;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
}

.product-card-desc {
  font-size: 13px; color: var(--text-dim);
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
  overflow: hidden;
  flex: 1;
  line-height: 1.5;
}

.product-card-meta {
  display: flex; align-items: center; justify-content: space-between;
  gap: 10px;
  padding-top: 10px;
  border-top: 1px solid var(--border);
  font-size: 13px;
}
.product-card-meta-item {
  display: inline-flex; align-items: center; gap: 5px;
  font-weight: 500;
}
.product-card-meta-item svg { width: 14px; height: 14px; }
.meta-downloads { color: var(--text-mute); }
.meta-downloads svg { color: var(--text-mute); }
.meta-rating { color: var(--star); }
.meta-rating svg { color: var(--star); }

.show-more-wrap {
  display: flex; justify-content: center;
  margin-top: 40px;
}
.show-more-btn { min-width: 240px; }
.show-more-count { color: var(--text-mute); font-weight: 500; font-size: 13px; }

@keyframes cardFadeIn {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}
.card-animate-in { animation: cardFadeIn 0.5s ease backwards; }

.empty-state { padding: 60px 20px; text-align: center; color: var(--text-dim); }
.empty-icon-wrap {
  width: 60px; height: 60px; margin: 0 auto 16px;
  background: var(--card); border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  color: var(--text-mute);
}
.empty-icon-wrap svg { width: 28px; height: 28px; }
.empty-state h3 { font-size: 18px; margin-bottom: 6px; color: var(--text); }
.empty-state p { font-size: 14px; }

/* ============ FEATURES BLOCK ============ */
.features-block {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}
@media (max-width: 1000px) { .features-block { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 500px) { .features-block { grid-template-columns: 1fr; } }

.feature-card {
  padding: 24px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 16px;
  transition: all 0.25s;
}
.feature-card:hover {
  border-color: var(--border-hover);
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}
.feature-card-icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: var(--grad);
  color: white;
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 16px;
  box-shadow: 0 6px 16px rgba(139, 92, 246, 0.35);
}
.feature-card-icon svg { width: 22px; height: 22px; }
.feature-card h3 {
  font-size: 17px;
  font-weight: 800;
  margin-bottom: 8px;
  letter-spacing: -0.01em;
}
.feature-card p {
  color: var(--text-dim);
  font-size: 13px;
  line-height: 1.55;
}

/* ============ FOOTER ============ */
.footer {
  padding: 60px 0 30px;
  background: var(--bg-2);
  border-top: 1px solid var(--border);
  margin-top: 40px;
}
.footer-inner {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 40px;
  margin-bottom: 40px;
}
@media (max-width: 700px) { .footer-inner { grid-template-columns: 1fr 1fr; gap: 30px; } }
.footer-brand { max-width: 300px; }
.footer-desc { color: var(--text-dim); font-size: 13px; margin-top: 12px; }
.footer-col h4 { font-size: 13px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.05em; margin-bottom: 14px; }
.footer-col a {
  display: block;
  color: var(--text-dim);
  font-size: 14px;
  text-decoration: none;
  padding: 4px 0;
  transition: color 0.2s;
}
.footer-col a:hover { color: var(--text); }
.footer-bottom {
  padding-top: 24px;
  border-top: 1px solid var(--border);
  display: flex; justify-content: space-between; gap: 20px; flex-wrap: wrap;
  font-size: 13px; color: var(--text-mute);
}

/* ============ PRODUCT PAGE ============ */
.product-page { padding: 40px 0 80px; }
.back-link {
  display: inline-flex; align-items: center; gap: 8px;
  color: var(--text-dim);
  text-decoration: none;
  font-weight: 600; font-size: 14px;
  margin-bottom: 30px;
  transition: color 0.2s;
}
.back-link:hover { color: var(--text); }
.back-link svg { width: 16px; height: 16px; }

.product-hero {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 40px;
  margin-bottom: 40px;
}
@media (max-width: 900px) { .product-hero { grid-template-columns: 1fr; } }

.product-hero-media {
  position: relative;
  aspect-ratio: 16 / 9;
  border-radius: 20px;
  overflow: hidden;
  background: var(--card);
  border: 1px solid var(--border);
}
.product-hero-media img { width: 100%; height: 100%; object-fit: cover; }

.product-badge {
  position: absolute; top: 16px; left: 16px;
  padding: 6px 14px;
  background: rgba(139, 92, 246, 0.85);
  color: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: 100px;
  font-size: 11px; font-weight: 800;
  letter-spacing: 0.05em;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.product-hero-info { display: flex; flex-direction: column; gap: 16px; }
.product-hero-head { display: flex; gap: 14px; align-items: center; }

.product-hero-icon {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  object-fit: cover;
  border: 1px solid var(--border);
  flex-shrink: 0;
}

.product-meta {
  display: flex;
  gap: 8px;
  align-items: center;
  flex-wrap: wrap;
}

.product-category {
  display: inline-flex;
  align-items: center;
  padding: 6px 14px;
  background: rgba(139, 92, 246, 0.15);
  color: var(--brand-1);
  border: 1px solid rgba(139, 92, 246, 0.3);
  border-radius: 100px;
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.product-version {
  display: inline-flex;
  align-items: center;
  padding: 6px 12px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 100px;
  font-family: var(--font-mono);
  color: var(--text-dim);
  font-size: 11px;
  font-weight: 700;
}

.product-status {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 100px;
  color: var(--text);
  font-size: 11px;
  font-weight: 700;
}
.product-status .status-dot {
  width: 6px; height: 6px; border-radius: 50%;
  background: #10d876;
  box-shadow: 0 0 6px #10d876;
}

.status-dot { width: 6px; height: 6px; border-radius: 50%; background: #10d876; box-shadow: 0 0 6px #10d876; }

.product-title {
  font-size: clamp(24px, 3vw, 32px);
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.15;
}
.product-desc { color: var(--text-dim); font-size: 15px; }

.product-stats-row {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  padding: 16px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 14px;
}
.product-stat { text-align: center; }
.product-stat-val {
  font-size: 24px; font-weight: 800; line-height: 1;
  background: var(--grad);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}
.product-stat-lbl { font-size: 11px; color: var(--text-mute); text-transform: uppercase; letter-spacing: 0.05em; font-weight: 600; margin-top: 6px; }

.product-content {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
}
.content-block {
  padding: 24px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 16px;
}
.content-block h2 { font-size: 22px; font-weight: 800; margin-bottom: 12px; }
.content-block p { color: var(--text-dim); }

/* ============ MODAL ============ */
.modal {
  position: fixed; inset: 0;
  z-index: 2000;
  display: none;
}
.modal.active { display: block; }
.modal-backdrop {
  position: absolute; inset: 0;
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(6px);
}
.modal-content {
  position: absolute; top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  width: min(720px, calc(100% - 24px));
  max-height: calc(100vh - 40px);
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: 20px;
  box-shadow: var(--shadow-lg);
  overflow-y: auto;
  animation: modalIn 0.3s ease;
}
@keyframes modalIn {
  from { opacity: 0; transform: translate(-50%, -48%) scale(0.95); }
  to   { opacity: 1; transform: translate(-50%, -50%) scale(1); }
}
.modal-close {
  position: absolute; top: 16px; right: 16px;
  width: 36px; height: 36px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 10px;
  cursor: pointer;
  color: var(--text-dim);
  display: flex; align-items: center; justify-content: center;
  z-index: 2;
  transition: all 0.15s;
}
.modal-close:hover { background: var(--card-hover); color: var(--text); }
.modal-close svg { width: 18px; height: 18px; }

.modal-header { padding: 28px 28px 8px; }
.modal-header h2 { font-size: 22px; font-weight: 800; margin-bottom: 4px; }
.modal-header p { color: var(--text-dim); font-size: 14px; }

.modal-body { padding: 20px 24px 24px; }

.script-box {
  background: #0a0b12;
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
  margin-bottom: 12px;
}
[data-theme="light"] .script-box { background: #1a1c26; }
.script-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 10px 14px;
  background: rgba(255, 255, 255, 0.03);
  border-bottom: 1px solid var(--border);
}
.script-lang { color: var(--text-dim); font-size: 12px; font-weight: 600; display: inline-flex; align-items: center; gap: 6px; }
.script-lang svg { width: 14px; height: 14px; }
.copy-btn {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 6px 12px;
  background: var(--grad);
  border: none;
  border-radius: 8px;
  color: white;
  cursor: pointer;
  font-family: inherit;
  font-size: 12px; font-weight: 600;
  transition: all 0.2s;
}
.copy-btn:hover { opacity: 0.9; }
.copy-btn svg { width: 12px; height: 12px; }
.script-code {
  padding: 16px;
  color: #e0e0e8;
  font-family: var(--font-mono);
  font-size: 13px;
  line-height: 1.6;
  white-space: pre-wrap; word-break: break-all;
}
.script-note {
  display: flex; align-items: center; gap: 6px;
  font-size: 12px; color: var(--text-mute);
  padding: 4px 2px;
}
.script-note svg { width: 14px; height: 14px; flex-shrink: 0; }
