:root {
  /* Palette: lime neon + silver accents for cyberpunk vibe */
  --bg: #0b0f12;
  --bg-2: #141a1f;
  --text: #e9f2f0;
  --muted: rgba(233,246,243,.75);
  --surface: rgba(255,255,255,.08);
  --surface-2: rgba(255,255,255,.12);
  --border: rgba(180,190,200,.35);
  --accent: #a6ff00;       /* lime */
  --accent-2: #cbd6e0;     /* silver */
  --card: rgba(255,255,255,.08);
  --shadow: 0 8px 28px rgba(0,0,0,.35);
  --radius: 12px;
  --focus: 2px solid #9fff3a;
  --glass: rgba(255,255,255,.08);
  --glass-strong: rgba(255,255,255,.16);
}

*, *::before, *::after { box-sizing: border-box; }

html, body { height: 100%; }

/* Layered, responsive, future-cyber background (gradient + lime diagonal lines + subtle noise) */
body {
  margin: 0;
  color: var(--text);
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, Inter, "Helvetica Neue", Arial, "Noto Sans", sans-serif;
  font-size: clamp(14px, 1.6vw, 16px);
  line-height: 1.5;
  background:
    /* subtle lime diagonal scanlines (overlay) */
    repeating-linear-gradient(135deg, rgba(166,255,0,.06) 0 2px, transparent 2px 6px),
    /* base dark gradient */
    linear-gradient(to bottom right, var(--bg), var(--bg-2) 60%);
  background-size: auto, cover;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  position: relative;
  isolation: isolate;
}

/* Subtle noise/scan overlay for depth on modern browsers */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background-image: linear-gradient(transparent 0 70%, rgba(255,255,255,.04) 70% 71%, transparent 71% 100%);
  background-size: 100% 2px;
  mix-blend-mode: overlay;
  opacity: .15;
  z-index: 0;
}

@media (prefers-reduced-motion: reduce) {
  body::after { display: none; }
}

/* Dark mode fallback: light mode variants for legibility */
@media (prefers-color-scheme: light) {
  :root {
    --bg: #f6f7f9;
    --bg-2: #e9eef6;
    --text: #111;
    --muted: rgba(17,17,17,.75);
    --surface: rgba(255,255,255,.92);
    --surface-2: rgba(255,255,255,.96);
    --border: rgba(20,25,35,.4);
    --accent: #1a7a00;
    --accent-2: #2e3a4e;
    --card: rgba(255,255,255,.75);
    --shadow: 0 6px 18px rgba(0,0,0,.15);
    --glass: rgba(255,255,255,.8);
    --glass-strong: rgba(255,255,255,.95);
  }
  body {
    background: linear-gradient(to bottom right, var(--bg), var(--bg-2));
  }
  body::after { opacity: .08; }
}

/* Layout scaffolding */
.container {
  width: 100%;
  max-width: clamp(720px, 90vw, 1100px);
  margin-inline: auto;
  padding: 0 1rem;
  position: relative;
  z-index: 1;
}

header, main, footer, aside {
  padding: 1rem 0;
}

/* Header: hero with glassy feel */
header {
  text-align: center;
  padding: 2rem 1rem 1.5rem;
}

header h1 {
  font-size: clamp(1.8rem, 4.5vw, 4rem);
  line-height: 1.05;
  margin: 0 0 .25rem;
  letter-spacing: .5px;
  color: var(--text);
}

header .meta {
  margin: 0;
  font-size: clamp(0.9rem, 1.8vw, 1.05rem);
  color: var(--muted);
}

/* Glass panel utility (fallback-friendly) */
.glass {
  background: var(--glass);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1rem;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  box-shadow: var(--shadow);
}
@supports not (backdrop-filter: blur(12px)) {
  .glass { background: rgba(255,255,255,.16); }
}

/* Featured image area (supports .image-frame pattern as requested) */
.image-frame, .featured-image {
  width: 100%;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid rgba(255,255,255,.25);
  box-shadow: 0 8px 20px rgba(0,0,0,.25);
  background: #000;
}
.image-frame { aspect-ratio: 16 / 9; }
.image-frame img, .featured-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  will-change: transform;
}
.featured-image { aspect-ratio: 16 / 9; }

/* Article content */
main { padding: 0 0 2rem; }
article { display: block; padding: 0; }

/* Typography for hero content inside article */
h2 {
  font-size: clamp(1.4rem, 3.5vw, 2.2rem);
  margin: .75rem 0 0.5rem;
  color: var(--text);
}
p { color: var(--text); margin: .5rem 0 1rem; }
blockquote {
  margin: .75rem 0; padding: .75rem 1rem;
  border-left: 3px solid var(--accent);
  background: rgba(0,0,0,.08);
  border-radius: 6px;
  color: var(--text);
}
ul { padding-left: 1.25em; margin: .5rem 0 1rem; }
li { margin: .25rem 0; }

/* Content helper (optional wrapper style) */
.content {
  margin: 0 0 1rem;
  line-height: 1.5;
  color: var(--text);
}
.content p { margin: .5rem 0; }

/* Product/ad and sponsored blocks in footer (glass panels) */
footer {
  padding: 1rem 0 2rem;
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  align-items: stretch;
}
.product-ad, .sponsored-page {
  display: grid;
  place-items: center;
  text-align: center;
  min-width: 0;
}
.product-ad a, .sponsored-page a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .5rem;
  width: 100%;
  padding: .9rem 1.1rem;
  text-decoration: none;
  color: var(--text);
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,.32);
  background: rgba(0,0,0,.18);
  transition: transform .2s ease, background .2s ease;
}
@media (prefers-color-scheme: light) {
  .product-ad a, .sponsored-page a { background: rgba(0,0,0,.08); border-color: rgba(0,0,0,.15); color: var(--text); }
}
.product-ad a:hover, .sponsored-page a:hover { transform: translateY(-1px); background: rgba(0,0,0,.28); }

/* Page-wide interactive controls (buttons/links) */
a, button, .btn, .cta {
  text-decoration: none;
  color: var(--text);
  outline: none;
}
.btn, .cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .5rem;
  padding: .75rem 1.25rem;
  border-radius: 999px;
  border: 1px solid rgba(166,255,0,.7);
  background: var(--accent);
  color: #002200;
  font-weight: 700;
  cursor: pointer;
  transition: transform .2s ease, background .2s ease, color .2s ease;
}
.btn:hover, .cta:hover { transform: translateY(-1px); background: #8cff3a; }
.btn:active, .cta:active { transform: translateY(0); }
.btn--outline {
  background: transparent;
  color: var(--text);
  border: 1px solid var(--accent);
}
.btn--outline:hover { background: rgba(166,255,0,.15); }

/* Focus visibility for accessibility */
:focus-visible {
  outline: 3px solid var(--accent-2);
  outline-offset: 2px;
  border-radius: 8px;
}

/* Utility classes (compact) */
.container, .grid, .card, .tag {
  /* reserved for composition; minimal defaults below */
}
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1rem;
}
.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: .9rem;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.04);
}
.tag {
  display: inline-block;
  padding: .15em .6em;
  border-radius: 999px;
  font-size: .75rem;
  color: #001000;
  background: rgba(166,255,0,.25);
  border: 1px solid rgba(166,255,0,.5);
}

/* Lists and navigation defaults (kept accessible) */
ul { list-style: disc inside; }
nav { display: none; }

/* Print styles: readable, minimal */
@media print {
  html, body { background: white; color: #000; }
  a { text-decoration: underline; color: inherit; }
  .glass, .image-frame { background: none; border: 1px solid #ccc; }
}
