:root {
  /* Theme Tokens - coral + white, dark cyber base */
  --bg: #0a0b0f;
  --bg-2: #141821;
  --surface: rgba(255, 255, 255, 0.12);
  --surface-2: rgba(255, 255, 255, 0.20);
  --text: #f7f9fc;
  --muted: #cbd5e1;
  --accent: #ff6a5e;      /* coral */
  --accent-2: #ffffff;
  --card: rgba(255, 255, 255, 0.08);
  --card-border: rgba(255, 255, 255, 0.25);
  --shadow: 0 6px 20px rgba(0,0,0,.45);
  --radius: 14px;
}

@media (prefers-color-scheme: light) {
  :root {
    --bg: #f7f7fb;
    --bg-2: #ffffff;
    --surface: rgba(0,0,0,0.06);
    --surface-2: rgba(0,0,0,0.10);
    --text: #0a0a0a;
    --muted: #555b67;
    --accent: #e74c3c;
    --accent-2: #1b1b1f;
    --card: rgba(0,0,0,0.04);
    --card-border: rgba(0,0,0,.15);
  }
}

/* Section: Global & Layout */
html, body, header, nav, main, article, footer, aside {
  box-sizing: border-box;
}

html, body {
  height: 100%;
}

body {
  margin: 0;
  color: var(--text);
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", "Liberation Sans", sans-serif;
  font-weight: 400;
  line-height: 1.5;
  background: linear-gradient(135deg, rgba(0,0,0,.60) 0%, rgba(0,0,0,.75) 60%), 
              radial-gradient(circle at 20% 0%, rgba(255,105,92,.08), transparent 40%),
              radial-gradient(circle at 80% 0%, rgba(255,255,255,.04), transparent 40%),
              var(--bg);
  /* Coral checkerboard overlay (future cyberpunk motif) */
}
body::before {
  content: "";
  position: fixed;
  inset: 0;
  background-image:
    linear-gradient(45deg, rgba(255,105,92,.14) 25%, transparent 25%),
    linear-gradient(-45deg, rgba(255,105,92,.14) 25%, transparent 25%);
  background-size: 40px 40px;
  mix-blend-mode: overlay;
  pointer-events: none;
  z-index: 0;
}
@media (prefers-reduced-motion: reduce) {
  body::before { display: none; }
}

/* Subtle scanlines + soft vignette for depth (pure CSS) */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background:
    repeating-linear-gradient(to bottom, rgba(0,0,0,.0) 0 2px, rgba(0,0,0,.04) 2px 4px);
  mix-blend-mode: overlay;
  opacity: 0.25;
  z-index: 0;
}
main { position: relative; z-index: 1; }

/* Section: Layout Helpers */
.container {
  width: 100%;
  max-width: clamp(320px, 92vw, 1100px);
  margin-inline: auto;
  padding: 1rem;
}
.grid {
  display: grid;
  gap: 1rem;
}
@media (min-width: 640px) {
  .grid { grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
}
.card {
  background: var(--card);
  border: 1px solid var(--card-border);
  border-radius: var(--radius);
  padding: 1rem;
  box-shadow: var(--shadow);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}
@supports not (backdrop-filter: blur(8px)) {
  .card { background: rgba(0,0,0,.25); }
}
.tag {
  display: inline-block;
  padding: .25em .6em;
  border-radius: 999px;
  font-size: .75rem;
  letter-spacing:.04em;
  color: var(--accent-2);
  background: rgba(255,106,94,.25);
  border: 1px solid rgba(255,255,255,.32);
}
.image-frame {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border-radius: 12px;
  border: 1px solid rgba(255,255,255,.28);
  background: #000;
  box-shadow: 0 6px 18px rgba(0,0,0,.5);
}
.image-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  filter: saturate(1.05) contrast(1.05);
  transform: scale(1.0);
  transition: transform .5s ease;
}
.image-frame:hover img { transform: scale(1.05); }

/* Section: Glass panels (frosted) */
.frost {
  background: var(--surface);
  border: 1px solid var(--card-border);
  box-shadow: 0 8px 28px rgba(0,0,0,.35);
  border-radius: 14px;
  padding: 1rem;
  backdrop-filter: blur(10px) saturate(1.05);
  -webkit-backdrop-filter: blur(10px) saturate(1.05);
}
@supports not (backdrop-filter: blur(10px)) {
  .frost { background: rgba(255,255,255,.08); opacity: .95; }
}

/* Section: Typography (hero) */
h1, h2, h3 { margin: 0 0 .5rem; font-weight: 700; letter-spacing:.2px; }
h1 { font-size: clamp(1.8rem, 4vw + 1rem, 3.4rem); line-height: 1.04; color: var(--text); }
h2 { font-size: clamp(1.25rem, 2.6vw + .5rem, 2rem); color: #fff; }
p { color: var(--muted); margin: 0 0 1rem; }

.meta { font-size: .85rem; color: var(--muted); text-align: center; margin-top: .25rem; }

/* Section: Hero content alignment */
.header, header {
  display: grid;
  gap: .5rem;
  place-items: center;
  text-align: center;
  padding: 2rem 1rem 1rem;
}
.header {
  padding-top: 2rem;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  padding: .25rem .6rem;
  border-radius: 999px;
  background: rgba(255,255,255,.08);
  border: 1px solid rgba(255,255,255,.25);
  font-weight: 600;
}
.brand .dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 8px var(--accent);
}
header h1 { margin-top: .25rem; }

/* Section: Links & Buttons */
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
button, .btn, .cta {
  font-family: inherit;
  font-weight: 700;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,.5);
  padding: .8rem 1.25rem;
  color: var(--text);
  background: rgba(255,255,255,.08);
  cursor: pointer;
  transition: transform .2s ease, background .2s ease, border-color .2s ease;
  text-align: center;
}
.btn { display: inline-flex; align-items: center; justify-content: center; gap: .5rem; }
.btn--outline {
  background: transparent;
  border: 1px solid rgba(255,255,255,.6);
  color: var(--text);
}
.btn:hover { transform: translateY(-1px); background: rgba(255,255,255,.12); }
.btn:active { transform: translateY(0); }

/* Focus states (WCAG AA) */
a:focus-visible, button:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 2px;
  border-color: rgba(255,255,255,.95);
  border-radius: 6px;
}
:focus:not(:focus-visible) { outline: none; }

/* Section: Content Areas */
.content { display: block; padding: 1rem; border-radius: var(--radius); }

/* Structured content blocks */
.product-ad {
  display: block;
  text-align: center;
  padding: .5rem;
}
.product-ad a {
  display: inline-block;
  padding: .5rem 1rem;
  background: rgba(255,255,255,.08);
  color: #fff;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,.25);
}
.product-ad a:hover { background: rgba(255,255,255,.15); }

/* Section: Lists */
ul { margin: .25rem 0 1rem 1.1rem; padding: 0; }
li { margin: .25rem 0; color: var(--muted); }

/* Section: Media wrappers */
.featured-image { margin: 1rem 0; }

/* Section: Page layout elements */
header, nav, main, article, aside, footer {
  padding: .25rem;
}

/* Footer styles */
footer {
  padding: 1.25rem 1rem;
  display: grid;
  gap: .75rem;
  justify-items: center;
}
.sponsored-page a { display: inline-block; padding: .5rem 1rem; border-radius: 999px; border: 1px solid rgba(255,255,255,.25); background: rgba(0,0,0,.25); }

/* Image frame variants */
.image-frame::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.15);
  pointer-events: none;
  mix-blend-mode: overlay;
}
.image-frame img { image-rendering: crisp-edges; }

/* Accessibility helpers */
.visually-hidden { position: absolute !important; height: 1px; width: 1px; overflow: hidden; clip: rect(1px, 1px, 1px, 1px); white-space: nowrap; }

/* Section: Print (readable) */
@media print {
  body { background: white; color: black; }
  .frost { background: white; border: 1px solid #000; box-shadow: none; }
}
