:root {
  --bg: #041018;
  --bg-2: #0a1220;
  --text: #eaffff;
  --muted: #a5eaff;
  --accent: #00e5ff;
  --accent-2: #ff3ab8;
  --glass: rgba(255, 255, 255, 0.08);
  --glass-strong: rgba(255, 255, 255, 0.14);
  --border: rgba(255, 255, 255, 0.28);
  --shadow: 0 6px 20px rgba(0, 0, 0, 0.25);
  --radius: 12px;
}

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

html, body { height: 100%; }

html, body {
  margin: 0;
  padding: 0;
  color: var(--text);
  background-color: #05131b;
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", "Liberation Sans", sans-serif;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  background-image:
    linear-gradient(135deg, rgba(0, 255, 255, 0.12), rgba(255, 0, 128, 0.12)),
    repeating-linear-gradient(90deg, rgba(0, 255, 255, 0.08) 0 6px, rgba(0,0,0,0) 6px 12px),
    linear-gradient(to bottom, rgba(0,0,0,0.0), rgba(0,0,0,0.0));
  background-attachment: fixed;
  background-blend-mode: overlay;
  text-rendering: optimizeLegibility;
}

 body {
  /* Keep a compact layout on small devices */
  padding: 0;
  overflow-x: hidden;
 }

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

 .grid {
   display: grid;
   grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
   gap: 1rem;
 }

 .card {
   background: var(--glass);
   border: 1px solid var(--border);
   border-radius: var(--radius);
   padding: 0.75rem;
   box-shadow: var(--shadow);
 }

 .tag {
   display: inline-block;
   padding: .25rem .5rem;
   border-radius: 999px;
   font-size: .75rem;
   background: rgba(0,0,0,.25);
   border: 1px solid rgba(255,255,255,.25);
   color: var(--text);
 }

 /* Global element styling per requirements */
 html, header, nav, main, article, aside, footer {
   display: block;
 }

 header {
   width: min(1100px, 92%);
   margin: 1rem auto;
   padding: 1rem;
   border-radius: 14px;
   background: var(--glass);
   border: 1px solid var(--border);
   box-shadow: var(--shadow);
   -webkit-backdrop-filter: blur(12px);
   backdrop-filter: blur(12px);
   text-align: center;
 }

 header h1 {
   font-size: clamp(1.4rem, 2vw + 1rem, 2.6rem);
   line-height: 1.15;
   margin: 0.25rem 0 0.5rem;
   color: #eaffff;
 }

 nav {
   display: flex;
   justify-content: center;
   gap: 0.5rem;
 }

 nav a {
   color: #eaffff;
   text-decoration: none;
   padding: .5rem .75rem;
   border-radius: 999px;
   border: 1px solid rgba(255,255,255,.28);
   background: rgba(0,0,0,.20);
   transition: transform .2s ease, background .2s ease;
 }

 nav a:hover { text-decoration: underline; background: rgba(0,0,0,.28); transform: translateY(-1px); }
 nav a:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }

 main {
   display: grid;
   justify-items: center;
   padding: 1rem 0 2rem;
 }

 article {
   width: 100%;
 }

 .image-frame {
   width: min(100%, 720px);
   aspect-ratio: 16 / 9;
   border-radius: 14px;
   overflow: hidden;
   border: 1px solid rgba(255,255,255,.28);
   background: rgba(0,0,0,.25);
   box-shadow: 0 10px 28px rgba(0,0,0,.35);
 }

 .image-frame img {
   width: 100%;
   height: 100%;
   object-fit: cover;
   display: block;
   transform: translateZ(0);
 }

 footer {
   padding: 1rem 0 2rem;
   display: grid;
   gap: 0.75rem;
   justify-items: center;
   width: 100%;
 }

 .product-ad,
 .sponsored-page {
   width: min(1100px, 92%);
   text-align: center;
   padding: .75rem;
   border-radius: 12px;
   background: var(--glass);
   border: 1px solid var(--border);
   box-shadow: var(--shadow);
 }

 .product-ad a,
 .sponsored-page a {
   color: var(--text);
   text-decoration: none;
 }

 .product-ad p,
 .sponsored-page p { margin: 0; font-weight: 600; }

 p { margin: 0.25rem 0; color: var(--muted); }

 a:focus-visible,
 button:focus-visible {
   outline: 2px solid var(--accent);
   outline-offset: 3px;
 }

 a:hover { text-decoration: underline; color: var(--accent); }

 .btn,
 .cta {
   display: inline-block;
   padding: .65rem 1rem;
   border-radius: 999px;
   border: 1px solid rgba(255,255,255,.45);
   background: rgba(0,0,0,.25);
   color: var(--text);
   text-decoration: none;
   font-weight: 600;
   cursor: pointer;
   transition: transform .2s ease, background .2s ease, color .2s ease;
 }

 .btn:hover,
 .cta:hover { transform: translateY(-1px); text-decoration: underline; }

 .btn--solid {
   background: linear-gradient(135deg, rgba(0, 230, 255, 0.95), rgba(255, 56, 160, 0.95));
   border: 1px solid rgba(255,255,255,.7);
   color: #04101a;
 }

 .btn--outline {
   background: transparent;
   border: 1px solid rgba(0, 255, 255, 0.9);
   color: var(--text);
 }

 .cta { padding-inline: 1.25rem; }

 ul { margin: 0; padding: 0; list-style: none; }
 li { margin: 0; padding: 0; }

 .content {
   padding-block: 1rem;
   color: var(--text);
 }

 .content h2 {
   font-size: clamp(1.1rem, 1vw + 0.8rem, 1.6rem);
   margin: 0 0 .5rem;
 }

 .content p { color: var(--muted); }

 .tag {
   font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
   padding: .2rem .5rem;
   border-radius: 6px;
   border: 1px solid rgba(255,255,255,.25);
   background: rgba(0,0,0,.25);
   color: var(--text);
   font-size: .75rem;
 }

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

 @media print {
   body { background: #fff; color: #000; }
   header, footer { background: transparent; border: none; box-shadow: none; }
   a { text-decoration: underline; }
 }
 
 /* Backdrop-filter support check (fallback if not available) */
 @supports not (backdrop-filter: blur(8px)) {
   header { backdrop-filter: none; background: rgba(255,255,255,0.12); border-color: rgba(255,255,255,.4); }
   .glass, .product-ad, .sponsored-page { background: rgba(255,255,255,0.14); border-color: rgba(255,255,255,.4); }
 }
