/* Section: Tokens & Base */
:root{
  --bg: #0b1e3a;
  --bg-2: #0a2a6a;
  --text: #eaf4ff;
  --muted: #b6c5e6;
  --accent: #ff7a1a;
  --accent-2: #1fb6ff;
  --panel: rgba(255,255,255,.08);
  --panel-border: rgba(255,255,255,.25);
  --glass-shadow: 0 8px 28px rgba(0,0,0,.25);
}
*,
*::before,
*::after{ box-sizing: border-box; }
html, body { height: 100%; }
html { -webkit-font-smoothing: antialiased; }
body{
  margin: 0;
  color: var(--text);
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, Arial, "Noto Sans", sans-serif;
  line-height: 1.5;
  min-height: 100vh;
  /* Layered background: blue gradient + subtle scanlines + glow */
  background:
    linear-gradient(135deg, rgba(0,0,0,.25) 0%, rgba(0,0,0,.0) 60%),
    repeating-linear-gradient(to bottom, rgba(255,255,255,.04) 0 1px, rgba(255,255,255,0) 1px 2px),
    linear-gradient(#0b1e3a 0%, #0a2a6a 60%, #0b1e3a 100%);
  background-blend-mode: normal, overlay, normal;
  background-attachment: fixed;
}
a{ color: var(--accent-2); text-decoration: none; }

/* Section: Layout Helpers */
:focus-visible{ outline: 3px solid #fff; outline-offset: 2px; border-radius: 4px; }
* { -webkit-tap-highlight-color: transparent; }

.container{ width: 100%; max-width: clamp(320px, 92vw, 1100px); margin-inline: auto; padding-inline: 1rem; }

/* Section: Structural Elements */
html, body, header, nav, main, article, aside, footer { display: block; }

/* Section: Grid & Cards (utilities) */
.grid{ display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
.card{ background: var(--panel); border: 1px solid var(--panel-border); border-radius: 12px; padding: 1rem; box-shadow: var(--glass-shadow); }

/* Section: Typography & Containers */
.content{ /* wrapper for textual blocks if used */ }
.tag{ display:inline-block; padding:.25em .5em; font-size:.75rem; border-radius:999px; background: rgba(255,255,255,.15); color:#fff; }

/* Section: Image framing (selector required by spec) */
.image-frame{ aspect-ratio: 16/9; border-radius: 12px; overflow: hidden; border: 1px solid rgba(255,255,255,.25); box-shadow: 0 6px 20px rgba(0,0,0,.25); background:#111; }
.image-frame img{ width:100%; height:100%; object-fit: cover; display:block; }

/* Section: Glass panels (with fallback) */
.backdrop{ background: var(--panel); border: 1px solid var(--panel-border); border-radius: 12px; padding: .75rem; }
@supports ((backdrop-filter: blur(8px)) or (-webkit-backdrop-filter: blur(8px))){
  .backdrop{ backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); }
  /* optional glow in support-enabled browsers */
  .backdrop{ background: rgba(255,255,255,.08); }
}
.faux-glass{ background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.25); border-radius: 12px; box-shadow: var(--glass-shadow); padding: .75rem; }

/* Section: Header / Hero */
header{ text-align: center; padding: 2rem 1rem; }
header h1{ font-size: clamp(1.75rem, 4vw + 0.5rem, 3.25rem); line-height: 1.04; margin: .25rem 0 .5rem; font-weight: 800; letter-spacing:.2px; color: var(--text); }
header .meta{ color: var(--muted); font-size: clamp(0.9rem, 0.5vw + 0.8rem, 1rem); }

/* Section: Navigation */
nav{ display: inline-block; margin-top: .5rem; }
nav a{ display: inline-block; padding: .5rem .8rem; border-radius: 6px; border: 1px solid rgba(255,255,255,.25); background: rgba(0,0,0,.18); color: #fff; }

/* Section: Main content */
main{ padding: 1rem; }

/* Section: Article content styles */
article{ max-width: 900px; margin: 0 auto; padding: 0 0 1rem; }
.featured-image{ width: 100%; border-radius: 12px; overflow:hidden; border: 1px solid rgba(255,255,255,.25); box-shadow: 0 6px 20px rgba(0,0,0,.25); margin-bottom: .75rem; }
.featured-image img{ width: 100%; height: auto; display: block; }

h2{ font-size: clamp(1.4rem, 1vw + 1.4rem, 2rem); margin: .8rem 0 .25rem; color: #eaf4ff; }
h3{ font-size: clamp(1.1rem, 0.9vw + .9rem, 1.6rem); margin: .6rem 0 .25rem; color: #eaf4ff; }
p{ color: var(--muted); margin: .25rem 0 1rem; }
blockquote{ border-left: 4px solid var(--accent-2); padding-left: .75rem; color: #d8e6ff; background: rgba(255,255,255,.05); border-radius: 6px; margin: .5rem 0 1rem; }

/* Lists */
ul, ol{ padding-left: 1.25rem; margin: .25rem 0 1rem; }
li{ margin: .15rem 0; }

/* Section: Footer / Ad blocks (glass panels) */
footer{ padding: 1rem; display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 1rem; align-items: stretch; }
.product-ad, .sponsored-page{ background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.25); border-radius: 12px; padding: 1rem; text-align: center; }
.product-ad a, .sponsored-page a{ display: block; color: #fff; text-decoration: none; padding: .6rem; border-radius: 8px; background: rgba(0,0,0,.25); border: 1px solid rgba(255,255,255,.25); }
.product-ad a:hover, .sponsored-page a:hover{ text-decoration: underline; }

/* Section: Print (basic readability) */
@media print{
  body{ background: #fff; color: #000; }
  a{ color: #000; text-decoration: underline; }
}
@media (prefers-reduced-motion: reduce){
  *{ animation: none !important; transition: none !important; }
}
