/* Section: Palette & Layout */
:root {
  --bg: #040b1a;
  --bg-2: #0a1220;
  --text: #eaf6ff;
  --muted: #a9d9ff;
  --accent: #39ff14;       /* neon green */
  --accent-2: #00e5ff;     /* electric blue */
  --surface: rgba(255, 255, 255, 0.10);
  --glass: rgba(10, 12, 40, 0.20);
  --glass-2: rgba(255, 255, 255, 0.08);
  --border: rgba(125, 255, 205, 0.40);
  --focus: #7af2ff;
  --shadow: 0 10px 28px rgba(0, 0, 0, 0.35);
  --radius: 14px;
}
* { box-sizing: border-box; }
html, body { height: 100%; }
html { font-family: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial; }
body {
  margin: 0;
  color: var(--text);
  background: 
    radial-gradient(circle at 20% -10%, rgba(0, 180, 255, 0.25), transparent 25%),
    radial-gradient(circle at 90% 0%, rgba(57, 255, 114, 0.15), transparent 20%),
    linear-gradient(135deg, #03061a 0%, #040a1a 40%, #041028 100%);
  min-height: 100%;
  position: relative;
  overflow-x: hidden;
  /* Subtle glow on edges for cyberpunk vibe */
  text-shadow: 0 0 1px rgba(0,0,0,.15);
}
body::before {
  content: "";
  position: fixed; inset: 0;
  background-image: repeating-linear-gradient(
    180deg,
    rgba(255,255,255,0.04) 0 2px,
    transparent 2px 4px
  );
  mix-blend-mode: overlay;
  opacity: 0.6;
  pointer-events: none;
  z-index: 0;
  animation: scan 12s linear infinite;
}
@keyframes scan {
  0% { transform: translateY(0); }
  100% { transform: translateY(-2px); }
}

/* Section: Typography & hero sizing */
h1, h2 { margin: 0 0 .5rem; }
p { margin: 0 0 1rem; }
ul { padding-left: 1.25rem; margin: .5rem 0 1rem; }
li { margin: .25rem 0; }

/* Section: Layout primitives */
.container { width: 100%; max-width: clamp(320px, 92vw, 1120px); margin-inline: auto; padding-inline: 1rem; }
.grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 1rem; }

/* Section: Glass panels (fallback + backdrop-filter) */
header, main, footer, article, aside, .product-ad, .sponsored-page {
  background: var(--glass);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1rem;
  box-shadow: var(--shadow);
  backdrop-filter: blur(10px) saturate(1.05);
  -webkit-backdrop-filter: blur(10px) saturate(1.05);
}
@supports not ((backdrop-filter: blur(10px)) or (-webkit-backdrop-filter: blur(10px))) {
  header, main, footer, article, aside, .product-ad, .sponsored-page {
    background: rgba(10,12,40,0.65);
  }
}

/* Section: Image frame styling */
.image-frame { border-radius: 12px; overflow: hidden; border: 1px solid rgba(0, 214, 255, 0.45); box-shadow: 0 6px 18px rgba(0,0,0,.25); aspect-ratio: 16 / 9; }
.image-frame img { width: 100%; height: 100%; object-fit: cover; display: block; }

.featured-image { width: 100%; display: block; border-radius: 12px; overflow: hidden; }

/* Section: Content area styling */
.content { padding: 0.75rem 0; }

/* Section: Product Ad & Sponsored sections */
.product-ad, .sponsored-page { text-align: center; }
.product-ad a, .sponsored-page a {
  display: inline-block;
  padding: .6rem 0.9rem;
  border-radius: 999px;
  text-decoration: none;
  color: var(--text);
  background: rgba(0,0,0,0.18);
  border: 1px solid rgba(255,255,255,0.28);
  transition: transform .15s ease;
}
.product-ad a:hover, .sponsored-page a:hover { transform: translateY(-2px); }
.product-ad a:focus-visible, .sponsored-page a:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 2px;
}
footer p { margin: .5rem 0 0; }

/* Section: Link & button treatments (WCAG AA focus) */
a, button, .btn, .cta {
  color: inherit;
  text-decoration: none;
}
a { color: var(--accent-2); }
a:hover { text-decoration: underline; text-underline-offset: 3px; }
a:focus-visible { outline: 2px solid var(--focus); outline-offset: 3px; border-radius: 6px; }

/* Button variants */
.btn {
  display: inline-block;
  padding: .75rem 1.1rem;
  border-radius: 999px;
  border: 1px solid rgba(57,255,20,0.8);
  background: linear-gradient(135deg, rgba(57,255,20,.85), rgba(0,255,140,.65));
  color: #041f0a;
  font-weight: 600;
  font-size: 1rem;
  cursor: pointer;
  transition: transform .15s ease, box-shadow .2s ease;
}
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: translateY(0); }
.btn:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }
.btn.outline {
  background: transparent;
  color: var(--accent-2);
  border: 1px solid rgba(57,255,20,0.9);
}
.btn.block { display: block; width: 100%; text-align: center; }

/* Section: Card & tag utilities */
.card {
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.25);
  border-radius: 12px;
  padding: 1rem;
}
.tag {
  display: inline-block;
  padding: .2em .6em;
  border-radius: 999px;
  font-size: .75rem;
  color: #041f0a;
  background: rgba(57,255,20,0.25);
  border: 1px solid rgba(57,255,20,0.5);
}

/* Section: Typography scale (responsive) */
h1 { font-size: clamp(1.75rem, 2.5vw + 1rem, 3.5rem); line-height: 1.05; letter-spacing: .2px; text-shadow: 0 0 12px rgba(0, 255, 255, 0.5); }
h2 { font-size: clamp(1.25rem, 1.6vw + .8rem, 2rem); }

/* Section: Accessibility & motion preferences */
@media (prefers-reduced-motion: reduce) {
  body::before { animation: none; }
  * { transition: none !important; }
}

/* Section: Print styles (basic readability) */
@media print {
  body { background: #fff; color: #000; }
  header, main, footer { background: #fff !important; border: none !important; box-shadow: none !important; }
  a, a:visited { text-decoration: underline; color: #000; }
}
 
/* Section: Minor utility helpers (non-intrusive) */
 ul ul { margin-top: .25rem; }
 .container + .container { margin-top: .5rem; }

/* Section: Basic element resets for consistency across sections */
header h1 { margin-top: .25rem; }
main { padding: 1rem 1rem 2rem; }
footer { padding: 1rem; }

/* Section: Global sizing tweaks for fluid typography */
html { font-size: 16px; }
@media (min-width: 640px) {
  html { font-size: 16.5px; }
}
@media (min-width: 980px) {
  html { font-size: 17px; }
}