:root {
  --bg: #0a1020;
  --bg-2: #0f1b2b;
  --text: #e9e0f0;
  --muted: #a7a0b8;
  --accent: #ff4dce;
  --accent-2: #ff8bd6;
  --card: rgba(10,14,28,0.22);
  --glass: rgba(255,255,255,0.08);
  --border: rgba(255,255,255,0.28);
  --shadow: 0 10px 26px rgba(0,0,0,.45);
  --focus: 2px solid var(--accent-2);
}

/* Base */
*,
*::before,
*::after { box-sizing: border-box; }
html, body { height: 100%; }
html, body { margin: 0; }
body {
  font-family: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial;
  color: var(--text);
  background: var(--bg);
  min-height: 100vh;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  background-image:
    linear-gradient(180deg, rgba(255,255,255,0.04), rgba(255,255,255,0.04)),
    repeating-linear-gradient(0deg, rgba(255,255,255,0.04) 0px, rgba(255,255,255,0.04) 1px, transparent 1px, transparent 2px);
  background-blend-mode: overlay;
  min-width: 320px;
  position: relative;
  overflow-x: hidden;
}

/* Layout primitives (section headers) */
header, nav, main, article, aside, footer { display: block; }

/* Header / Hero */
header {
  text-align: center;
  padding: 2rem 1rem 1.25rem;
}
header h1 {
  font-size: clamp(2rem, 4vw + 1rem, 4rem);
  line-height: 1.04;
  margin: 0 0 .25rem;
  letter-spacing: .5px;
  text-shadow: 0 2px 12px rgba(0,0,0,.55);
}
header .meta {
  color: var(--muted);
  font-size: clamp(0.9rem, 1.2vw, 1.05rem);
}

/* Main content */
main { display: grid; place-items: start center; padding: 0 1rem 2rem; }
article { width: min(1100px, 92%); }

/* Image frame (image-frame + image-frame img) */
.image-frame,
.image-frame img {
  border-radius: 12px;
}
.image-frame {
  width: 100%;
  aspect-ratio: 16 / 9;
  margin: 1rem auto;
  overflow: hidden;
  border: 1px solid var(--border);
  background: rgba(0,0,0,.25);
  box-shadow: inset 0 0 12px rgba(0,0,0,.25), 0 8px 26px rgba(0,0,0,.45);
}
.image-frame img {
  width: 100%; height: 100%; object-fit: cover; display: block;
}

/* Content typography and layout */
.content {
  max-width: 720px;
  padding: 0 1rem;
  margin: 0 auto;
}
h2 { font-size: clamp(1.5rem, 3vw + .5rem, 2.5rem); margin: .75rem 0 .25rem; color: #fff; }
p { color: var(--text); margin: .5rem 0; }
ul { margin: .5rem 0; padding-left: 1.25rem; }
li { margin: .25rem 0; }

/* Block quotes + accents */
blockquote {
  border-left: 3px solid var(--accent);
  padding-left: .75rem;
  color: var(--muted);
  margin: .75rem 0;
}
.tag {
  display:inline-flex; align-items:center; gap:.25em;
  padding:.25em .5em; border-radius:999px;
  font-size:.75rem; color: var(--text);
  background: rgba(255,0,220,0.15);
  border: 1px solid rgba(255,0,220,0.4);
}

/* Footer / Ad sections with glass panels */
footer { padding: 1rem; border-top: 1px solid rgba(255,255,255,0.08); display: grid; gap: 1rem; }
.product-ad,
.sponsored-page {
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  background: rgba(8,12,28,0.22);
  border: 1px solid rgba(255,255,255,0.25);
  border-radius: 12px;
  padding: .75rem;
  text-align: center;
}
.product-ad a,
.sponsored-page a {
  display: block; color: var(--text);
  text-decoration: none; padding: .5rem;
  border-radius: 8px;
}
.product-ad a {
  background: rgba(255, 0, 180, 0.15);
  border: 1px solid rgba(255,0,180,0.4);
}
.sponsored-page a {
  background: rgba(0,0,0,0.15);
  border: 1px solid rgba(255,255,255,0.35);
}
footer p { text-align: center; margin: .5rem 0 0; color: var(--muted); }

/* Utility grid / card components */
.container {
  width: min(1100px, 92%);
  margin-inline: auto;
  padding: 0 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: 12px;
  padding: 1rem;
  box-shadow: var(--shadow);
  backdrop-filter: blur(8px);
}
.card h3 { margin: .25rem 0; }

/* Link and button styles */
a, button, .btn, .cta {
  color: var(--text);
  text-decoration: none;
  outline: none;
}
a:hover { text-decoration: underline; }
a:focus-visible,
button:focus-visible,
.btn:focus-visible,
.cta:focus-visible {
  outline: var(--focus);
  outline-offset: 3px;
  border-radius: 6px;
}
.btn {
  display:inline-flex; align-items:center; justify-content:center;
  padding:.75rem 1.15rem; border-radius:999px;
  border:1px solid rgba(255,255,255,.35);
  background: linear-gradient(135deg, rgba(255,64,180,.95), rgba(255,0,180,.75));
  color:#fff; font-weight:600; cursor:pointer;
  transition: transform .2s ease, box-shadow .2s ease;
}
.btn:hover { transform: translateY(-1px); box-shadow: 0 6px 14px rgba(255,0,180,.3); }
.btn:active { transform: translateY(0); opacity:.95; }
.btn--outline {
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,.36);
  color: var(--text);
}
.cta { padding:.6rem 1rem; border-radius:8px; }

/* Image frame fallback for non-supporting browsers is handled by glass look above */

/* Accessibility: dark mode variant */
@media (prefers-color-scheme: light) {
  :root {
     --bg: #f7f5fb;
     --bg-2: #ffffff;
     --text: #1a1a28;
     --muted: #555066;
     --accent: #e5007a;
     --accent-2: #e86abf;
     --card: rgba(255,255,255,0.85);
     --glass: rgba(255,255,255,0.75);
     --border: rgba(0,0,0,0.15);
     --shadow: 0 6px 16px rgba(0,0,0,.08);
  }
  body { background: var(--bg); color: var(--text); }
  .image-frame { border-color: rgba(0,0,0,.15); background: rgba(255,255,255,0.9); }
  .product-ad, .sponsored-page { background: rgba(255,255,255,0.9); border-color: rgba(0,0,0,0.15); }
  a, .btn { color: #1a1a1a; }
  .btn { background: linear-gradient(135deg, #f06bcb, #ea4bd9); }
}
@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; }
}
@media print {
  body { background: #fff; color: #000; }
  a { color: #000; text-decoration: underline; }
}