/* Base & tokens */
:root {
  --bg: #060b14;
  --bg-2: #0b1d3a;
  --bg-3: #0a0f1b;
  --text: #eaf6ff;
  --muted: rgba(234,246,255,.72);
  --accent: #4ea8ff;      /* cobalt glow */
  --accent-2: #2b1f0b;     /* espresso depth  */
  --glass: rgba(14,20,40,.22);
  --glass-strong: rgba(14,20,40,.32);
  --border: rgba(255,255,255,.28);
  --shadow: 0 10px 28px rgba(0,0,0,.4);
  --radius: 14px;
  --radius-sm: 10px;
  --focus: 3px solid #a6e3ff;
  --focus-offset: 2px;
}

/* Base + grid helpers */
* { 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);
  line-height: 1.5;
  min-height: 100%;
  background:
    linear-gradient(135deg, rgba(3,8,25,.95), rgba(6,26,54,.95) 60%, rgba(3,8,25,.95)),
    radial-gradient(circle at 20% 0%, rgba(0,170,255,.15), transparent 40%),
    radial-gradient(circle at 80% 20%, rgba(40,60,170,.25), transparent 40%);
  background-blend-mode: screen, overlay, overlay;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  /* Subtle scanline / noise-like overlay (pure CSS) */
  background-image:
    linear-gradient(rgba(255,255,255,.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.03) 1px, transparent 1px);
  background-size: 10px 10px;
  mix-blend-mode: overlay;
  opacity: .6;
}

/* Layout primitives */
.container {
  width: 100%;
  max-width: clamp(640px, 92vw, 1100px);
  margin-inline: auto;
  padding-inline: 1rem;
}
.grid { display: grid; gap: 1rem; }

/* Glass panel (frosted glass) with fallback */
.card {
  background: rgba(8,12,28,.18);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1rem;
  box-shadow: var(--shadow);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}
@supports not (backdrop-filter: blur(12px)) {
  .card { backdrop-filter: none; background: rgba(8,12,28,.32); }
}
.tag {
  display: inline-block;
  padding: .15em .6em;
  font-size: .75rem;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,.28);
  background: rgba(255,255,255,.04);
  color: var(--text);
}

/* Typography scale (fluid) */
h1, h2 { margin: 0 0 .25rem; font-weight: 700; }
h1 { font-size: clamp(1.6rem, 2vw + 1rem, 2.9rem); line-height: 1.04; letter-spacing: .5px; }
h2 { font-size: clamp(1.25rem, 1vw + .75rem, 1.75rem); line-height: 1.2; }

p { margin: .5rem 0 1rem; color: var(--text); }

/* Image framing */
.image-frame {
  aspect-ratio: 16 / 9;
  width: 100%;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid rgba(255,255,255,.28);
  background: #000;
  box-shadow: 0 8px 26px rgba(0,0,0,.4);
}
.image-frame img {
  width: 100%; height: 100%; object-fit: cover; display: block;
}

/* Core sections */
header {
  text-align: center;
  padding: 1.25rem 1rem 0.75rem;
  position: relative;
  z-index: 1;
}
header h1 { color: var(--text); }
header .meta { color: var(--muted); font-size: clamp(.75rem, 0.8vw + .5rem, .95rem); display:block; margin-top:.25rem; }

nav { margin: .5rem auto 0; padding-bottom: .25rem; }
nav a {
  color: var(--text);
  text-decoration: none;
  padding: .32rem .6rem;
  border-radius: 6px;
  border: 1px solid rgba(255,255,255,.28);
  background: rgba(0,0,0,.25);
}
nav a:hover { background: rgba(0,0,0,.38); transform: translateY(-1px); }
@media (prefers-reduced-motion: reduce) { nav a { transition: none; } }

main { padding: 1rem; }
article { display: block; }

/* Content wrapper (for text blocks) */
.content { color: var(--text); font-size: clamp(1rem, .2vw + 1rem, 1.125rem); line-height: 1.6; }
.content ul { padding-left: 1.25rem; margin: .5rem 0; }
.content li { margin: .25rem 0; }

/* Media-ad sections in footer */
.product-ad {
  display: block;
  margin: .6rem 0;
  padding: .8rem;
  border-radius: 12px;
  text-align: center;
  background: rgba(8,12,28,.28);
  border: 1px solid rgba(255,255,255,.32);
}
.product-ad a { color: var(--text); text-decoration: none; display: inline-block; padding: .25rem .5rem; }
.product-ad a:hover { text-decoration: underline; }

/* Lists styling (ul, li) already covered above; ensure accessible contrast */
ul { margin: .5rem 0; padding-left: 1.25rem; }
li { margin: .25rem 0; }

/* Links & controls */
a, button, .btn, .cta {
  color: var(--text);
  text-decoration: none;
  cursor: pointer;
}
a { transition: color .2s, text-decoration .2s, transform .2s; }
a:hover { color: var(--accent); text-decoration: underline; }
button, .btn, .cta {
  padding: .6rem 1rem;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,.28);
  background: rgba(0,0,0,.25);
  color: var(--text);
  display: inline-block;
}
button:hover, .btn:hover, .cta:hover { background: rgba(0,0,0,.34); transform: translateY(-1px); }

button:focus-visible, a:focus-visible {
  outline: 3px solid #a6e3ff;
  outline-offset: 2px;
  border-radius: 6px;
}
.btn.primary {
  background: linear-gradient(135deg, var(--accent), #0a5aff);
  border: none;
  color: #061b2f;
  font-weight: 600;
  text-shadow: none;
}
.btn.primary:hover { filter: brightness(1.05); }

/* Layout helpers for responsive content areas */
.content-area { display: block; }

/* Header, main, aside, footer layout tweaks for accessibility */
aside { display: none; }

/* Print styles */
@media print {
  body { background: #fff; color: #000; }
  a { text-decoration: underline; color: #000; }
  .card { background: #fff; border: 1px solid #000; }
}

/* Motion preferences */
@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; }
}

/* Typography rhythm helpers (compact baseline) */
:where(h2) { letter-spacing: .2px; }
@media (min-width: 700px) {
  .container { padding-inline: 1.25rem; }
  main { padding-inline: 1.25rem; }
}
footer {
  padding: 1rem;
  border-top: 1px solid rgba(255,255,255,.15);
  display: grid;
  gap: .75rem;
  justify-items: center;
  text-align: center;
}
@media (min-width: 700px) {
  footer { grid-template-columns: 1fr 1fr; align-items: start; }
}