/* Global Tokens */
:root {
  --bg: #0a1220;
  --bg-2: #0b1a2b;
  --text: #eaf7ff;
  --muted: #a9c6dc;
  --accent: #61d3ff;     /* baby blue highlight */
  --accent-2: #b8773a;   /* copper accent */
  --glass: rgba(14, 26, 60, 0.18);
  --glass-2: rgba(14, 26, 60, 0.28);
  --border: rgba(199, 120, 60, 0.45);
  --shadow: 0 8px 22px rgba(0,0,0,.25);
  --radius: 12px;
  --radius-sm: 10px;
  --focus: 2px solid rgba(97, 211, 255, 0.95);
}

/* Base & Reset */
* { box-sizing: border-box; }
html, body { height: 100%; }
html { font-family: system-ui, -apple-system, "Segoe UI", Roboto, Inter, Arial, sans-serif; }
body {
  margin: 0;
  color: var(--text);
  background: linear-gradient(135deg, #0a0f1a 0%, #0b1b2a 60%, #0a0f1a 100%);
  overflow-x: hidden;
  line-height: 1.5;
}

/* Layered futuristic background (gradient + subtle cube/scanline texture) */
body::before {
  content: "";
  position: fixed; inset: 0;
  z-index: 0;
  background:
    /* isometric cube hint via soft diagonal bands */
    linear-gradient(135deg, rgba(97,211,255,.10) 0 25%, transparent 25% 100%),
    linear-gradient(225deg, rgba(96,186,255,.08) 0 25%, transparent 25% 100%),
    linear-gradient(315deg, rgba(255,255,255,.04) 0 25%, transparent 25% 100%);
  background-size: 60px 60px, 60px 60px, 60px 60px;
  mix-blend-mode: overlay;
  opacity: .25;
  pointer-events: none;
  filter: saturate(110%);
}
body::after {
  content: "";
  position: fixed; inset: 0;
  z-index: 0;
  /* subtle noise/scanlines using CSS-only speckle */
  background-image: radial-gradient(circle at 1px 1px, rgba(255,255,255,.08) 1px, transparent 1px);
  background-size: 3px 3px;
  mix-blend-mode: overlay;
  opacity: .25;
  pointer-events: none;
  filter: saturate(90%);
}

/* Layout helpers (compact) */
.container {
  width: 100%;
  max-width: clamp(720px, 90vw, 1200px);
  padding-inline: 1rem;
  margin-inline: auto;
}
.grid {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}
.card {
  background: var(--glass);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1rem;
  box-shadow: var(--shadow);
}
.tag {
  display: inline-block;
  font-size: .75rem;
  padding: .15rem .5rem;
  border-radius: 999px;
  background: rgba(97,211,255,.25);
  color: var(--text);
  line-height: 1;
}

/* Structural selectors (required) styling */
html, body, header, nav, main, article, footer, aside {
  /* simple baseline to ensure consistent rendering */
}
header, main, footer, aside {
  position: relative;
  z-index: 1;
}
header {
  padding: 1.25rem;
  margin: 1rem auto;
  width: min(100%, 1200px);
  border-radius: var(--radius);
  background: rgba(9,20,45,.42);
  border: 1px solid rgba(255,255,255,.25);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  box-shadow: 0 6px 22px rgba(0,0,0,.25);
}
header h1 {
  font-size: clamp(1.75rem, 4vw, 3rem);
  line-height: 1.05;
  margin: 0 0 .25rem 0;
  font-weight: 700;
  letter-spacing: .2px;
}
header .meta {
  color: var(--muted);
  font-size: clamp(.9rem, 1.5vw, 1.05rem);
  margin: 0 0 .5rem 0;
}
nav {
  display: flex;
  gap: .5rem;
  align-items: center;
}
nav a {
  color: var(--accent);
  text-decoration: none;
  padding: .25rem .5rem;
  border-radius: 6px;
  transition: color .2s ease, background .2s ease;
}
nav a:hover, nav a:focus-visible {
  text-decoration: underline;
  color: var(--accent-2);
  outline: none;
}
main {
  padding: 1rem 0;
}
article {
  padding: 0;
}
.featured-image { margin: 0 0 1rem; }
.image-frame {
  width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid rgba(255,255,255,.25);
  box-shadow: inset 0 0 12px rgba(0,0,0,.25);
}
.image-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transform: translateZ(0); /* GPU hint for smoother rendering */
}
.content {
  padding: 1rem;
  background: rgba(8, 16, 40, 0.20);
  border: 1px solid rgba(255,255,255,.25);
  border-radius: 12px;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  color: var(--text);
}
.product-ad {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: .75rem;
  border-radius: 12px;
  background: rgba(8, 25, 60, .28);
  border: 1px solid rgba(255,255,255,.25);
  box-shadow: 0 6px 18px rgba(0,0,0,.25);
}
.product-ad a { color: var(--text); text-decoration: none; display: block; padding: .25rem; }
.sponsored-page { display: inline-flex; align-items: center; }
footer {
  padding: 1rem;
  margin: 1rem auto 2rem;
}
footer .product-ad { flex: 1 1 auto; min-width: 180px; text-align: center; }
footer p { color: var(--muted); text-align: center; margin: .5rem 0 0; }

/* Typography scaling & helpers */
h2 { font-size: clamp(1.4rem, 2.6vw, 2rem); margin: 1.25rem 0 .5rem; color: #eaf7ff; }
p { color: #d9eaff; margin: 0 0 1rem; }
ul { padding-left: 1.25rem; margin: .25rem 0 1rem; color: #d6eaff; }
li { margin: .25rem 0; }

/* Links & interactive controls */
a, button, .btn, .cta {
  font-family: inherit;
  font-size: 1rem;
}
a { cursor: pointer; text-decoration: none; color: var(--accent); }
a:hover, a:focus-visible { text-decoration: underline; color: var(--accent-2); outline: none; }
.btn, .cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .5rem;
  padding: .6rem 1rem;
  border-radius: 8px;
  border: 0;
  cursor: pointer;
  text-decoration: none;
  transition: transform .15s ease, background .2s ease, color .2s ease;
}
.btn {
  background: linear-gradient(135deg, #4bd1ff 0%, #2b8bd7 100%);
  color: #001018;
  font-weight: 600;
}
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: translateY(0); }
.btn:focus-visible {
  outline: var(--focus);
  outline-offset: 2px;
}
.btn.secondary {
  background: transparent;
  color: var(--text);
  border: 1px solid rgba(97,211,255,.8);
}
.btn.secondary:hover {
  background: rgba(97,211,255,.15);
}
.cta { font-weight: 700; }

/* Forms (presentational baseline) */
input, select, textarea {
  font: inherit;
  color: var(--text);
  background: rgba(255,255,255,.08);
  border: 1px solid rgba(255,255,255,.25);
  border-radius: 8px;
  padding: .5rem .75rem;
  outline: none;
}
input:focus-visible, textarea:focus-visible, select:focus-visible {
  outline: var(--focus);
  outline-offset: 2px;
  border-color: rgba(97,211,255,.95);
}

/* Lists & badges */
ul.inline { padding: 0; display: flex; gap: .75rem; flex-wrap: wrap; list-style: none; }
li { list-style: none; }

/* Responsive helpers */
@media (max-width: 720px) {
  header { padding: 1rem; }
  .product-ad { flex-direction: column; align-items: stretch; text-align: left; }
  .container { padding-inline: .75rem; }
}
@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; transform: none !important; }
}

/* Print styles (basic readability) */
@media print {
  body { background: white; color: black; }
  header, main, footer { background: transparent; box-shadow: none; border: none; border-radius: 0; }
  a { color: black; text-decoration: underline; }
}