/* Base tokens */
:root {
  --bg: #02140c;
  --bg-2: #04140f;
  --text: #eafff2;
  --muted: #a8f7d0;
  --accent: #39ff14;
  --accent-2: #ff2b52;
  --panel: rgba(255, 255, 255, 0.08);
  --panel-strong: rgba(255, 255, 255, 0.14);
  --border: rgba(255, 255, 255, 0.28);
  --shadow: 0 8px 20px rgba(0, 0, 0, 0.25);
  --focus: rgba(57, 255, 20, 0.65);
}

/* 1) Base & Layout */
* { box-sizing: border-box; }
html, body { height: 100%; }
html { background: #000; }
body {
  margin: 0;
  color: var(--text);
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial;
  font-size: 16px;
  line-height: 1.6;
  background: linear-gradient(to bottom, rgba(2,22,12,0) 0%, rgba(2,22,12,0.25) 60%, rgba(2,22,12,0.45) 100%), 
              linear-gradient(135deg, rgba(0,255,112,0.12), rgba(255,0,64,0.12) 60%, rgba(0,255,0,0.12) 100%), 
              var(--bg);
  background-blend-mode: normal, overlay, normal;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  min-height: 100%;
  overflow-x: hidden;
  position: relative;
}
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  /* subtle neon glow + scanlines (pure CSS) */
  background-image:
    radial-gradient(circle at 15% -5%, rgba(60,255,140,0.20), transparent 40%),
    repeating-linear-gradient(to bottom, rgba(0,0,0,0.04) 0 1px, transparent 1px 2px);
  opacity: 0.6;
  mix-blend-mode: overlay;
  z-index: 0;
}
.container, .grid, .card, .tag { position: relative; z-index: 1; }

/* 2) Glass panels & emphasis */
.card, .content, .product-ad {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1rem;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  box-shadow: var(--shadow);
}
@supports not (backdrop-filter: blur(8px)) {
  .card, .content, .product-ad { background: rgba(255,255,255,0.12); border-color: rgba(255,255,255,0.35); }
}

/* 3) Typography scale (fluid) */
h1, h2, h3, h4 { line-height: 1.15; font-weight: 700; margin: 0 0 0.5rem; }
p { margin: 0 0 1rem; }
blockquote { margin: .75rem 0; padding: .5rem 1rem; border-left: 4px solid var(--accent); background: rgba(0,0,0,0.15); border-radius: 6px; }

/* 4) Core layout primitives */
.header, header, nav, main, footer, aside { display: block; }
.header, header { margin: 1rem auto; padding: 1.25rem; border-radius: 12px; background: rgba(255,255,255,0.08); border: 1px solid rgba(255,255,255,0.25); max-width: clamp(320px, 92vw, 1100px); }

/* 5) Header / hero specifics */
header h1 { margin: 0 0 .25rem; font-size: clamp(1.75rem, 4vw, 3rem); color: #eafff0; text-shadow: 0 0 12px rgba(57,255,20,0.75); }
header .meta { font-size: .875rem; color: rgba(234, 255, 245, 0.85); }

/* 6) Nav */
nav { margin-top: .5rem; }
nav a { color: var(--accent); text-decoration: none; padding: .25rem .6rem; border-radius: 6px; border: 1px solid rgba(57,255,20,0.25); }
nav a:hover, nav a:focus { text-decoration: underline; }

/* 7) Main content structure */
main { padding: 0; }
article { padding: 1rem; max-width: clamp(320px, 92vw, 1100px); margin: 0 auto; }
.image-frame { width: 100%; aspect-ratio: 16/9; border-radius: 12px; overflow: hidden; border: 1px solid rgba(255,255,255,0.3); box-shadow: 0 6px 20px rgba(0,0,0,0.25); margin: 0 auto 1rem; background: #000; }
.image-frame img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* 8) Content helpers */
.content { padding: 0; }
.content h2 { font-size: clamp(1.25rem, 3vw, 1.75rem); color: #d8ffec; margin: .75rem 0; }
.content h3 { font-size: clamp(1.05rem, 2.5vw, 1.25rem); color: var(--accent-2); margin-top: .75rem; }
.content h4 { font-size: 1rem; margin: .5rem 0; color: var(--text); }
.content p { color: rgba(234,255,245,0.95); }

/* 9) Lists & blocks */
ul { margin: .5rem 0 1rem; padding-left: 1.25rem; }
li { margin: .25rem 0; }

/* 10) Special sections like ads / promos */
.product-ad { display: block; padding: .9rem; border-radius: 12px; text-align: center; background: rgba(255,255,255,0.08); border: 1px solid rgba(255,255,255,0.25); margin: .5rem auto; max-width: 420px; }
.product-ad a { color: var(--text); text-decoration: none; display: inline-block; padding: .25rem .75rem; border-radius: 6px; border: 1px solid rgba(255,255,255,0.25); }

/* 11) Utility classes (required) */
.container { width: 100%; max-width: clamp(320px, 92vw, 1100px); margin-inline: auto; padding-inline: 1rem; }
.grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 1rem; }
.card { background: var(--panel); border: 1px solid var(--border); border-radius: 12px; padding: 1rem; backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); box-shadow: var(--shadow); }
.tag { display: inline-block; padding: 0.15em 0.6em; font-size: 0.75rem; border-radius: 999px; background: rgba(0,0,0,0.25); color: #eafff0; border: 1px solid rgba(255,255,255,0.25); }

/* 12) Interactive controls (buttons & links) */
a, button, .btn, .cta {
  color: var(--text);
  text-decoration: none;
  border-radius: 8px;
  border: 1px solid transparent;
  background: rgba(0,0,0,0.25);
  padding: 0.5rem 0.9rem;
  display: inline-block;
  cursor: pointer;
  transition: transform 0.18s ease, background 0.2s ease;
}
a:hover, button:hover, .btn:hover, .cta:hover { transform: translateY(-1px); }
a:focus-visible, button:focus-visible, .btn:focus-visible, .cta:focus-visible {
  outline: 2px solid var(--focus);
  outline-offset: 2px;
  box-shadow: 0 0 0 4px rgba(57,255,20,0.15);
}
.btn { background: rgba(0,0,0,0.4); border-color: rgba(255,255,255,0.25); }
.btn--outline {
  background: transparent;
  border-color: rgba(57,255,20,0.6);
  color: var(--text);
}
.btn:active, .cta:active { transform: translateY(0.5px) scale(0.99); }

/* 13) Print styles (basic readability) */
@media print {
  body {
    background: #fff;
    color: #000;
  }
  header, nav, main, footer { background: transparent; border: none; }
}

/* 14) Reduced motion preference */
@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; }
  body::before { display: none; }
}