/* Base tokens */
:root {
  --bg: #0b0f14;
  --bg-2: #14161e;
  --text: #e9e6ff;
  --muted: #b6a8c9;
  --accent: #8a5cff;
  --accent-2: #b086ff;
  --card: rgba(20,22,28,.32);
  --card-border: rgba(138, 92, 255, .45);
}
html, body {
  height: 100%;
}
html, body { margin: 0; padding: 0; }

/* Layered background: gradient + subtle scanlines + glow */
html, body {
  background:
    radial-gradient(circle at 25% 15%, rgba(138,92,255,.25), transparent 40%),
    radial-gradient(circle at 75% 60%, rgba(60,0,90,.25), transparent 40%),
    linear-gradient(135deg, #0b0f14 0%, #141824 60%, #0b0f14 100%),
    repeating-linear-gradient(to bottom, rgba(255,255,255,.04) 0 1px, transparent 1px 2px);
  color: var(--text);
  font-family: ui-system, system-ui, -apple-system, "Segoe UI", Roboto, Inter, Arial;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  min-height: 100%;
  overflow-x: hidden;
}
@media (prefers-color-scheme: light) {
  :root {
    --bg: #f6f4fb;
    --bg-2: #ffffff;
    --text: #1b1b1f;
    --muted: #55536a;
    --accent: #6a4dff;
    --accent-2: #4d39d2;
    --card: rgba(255,255,255,.75);
    --card-border: rgba(106,77,255,.4);
  }
  html, body {
    background:
      linear-gradient(135deg, #f6f3fb 0%, #f3f2fb 60%, #f6f3fb 100%),
      radial-gradient(circle at 60% -10%, rgba(106,77,255,.15), transparent 40%),
      repeating-linear-gradient(to bottom, rgba(0,0,0,.03) 0 1px, transparent 1px 2px);
  }
}

/* Layout containers */
.container {
  width: 100%;
  max-width: clamp(320px, 88vw, 1100px);
  margin-inline: auto;
  padding: 0 1rem;
}
.grid {
  display: grid;
  gap: 1rem;
}
.card {
  background: var(--card);
  border: 1px solid var(--card-border);
  border-radius: 14px;
  padding: 0.75rem;
  box-shadow: 0 6px 20px rgba(0,0,0,.25);
  backdrop-filter: saturate(1.2) blur(8px);
  -webkit-backdrop-filter: saturate(1.2) blur(8px);
}
@supports not (backdrop-filter: blur(8px)) {
  .card { background: rgba(20,22,28,.5); }
}
.image-frame {
  aspect-ratio: 16 / 9;
  width: 100%;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid rgba(138, 92, 255, .35);
  box-shadow: 0 8px 22px rgba(0,0,0,.35), inset 0 0 0 1px rgba(255,255,255,.04);
}
.image-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transform: translateZ(0);
}
.content { /* glass panel placeholder for potential content sections */
  background: rgba(15, 18, 25, 0.24);
  border: 1px solid rgba(138, 92, 255, .4);
  border-radius: 12px;
  padding: 1rem;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}
@supports not (backdrop-filter: blur(8px)) {
  .content { background: rgba(15,18,25,.38); }
}
.product-ad, .sponsored-page {
  background: rgba(20,22,28,.28);
  border: 1px solid rgba(138, 92, 255, .4);
  border-radius: 12px;
  padding: 0.75rem;
  text-align: center;
}
.product-ad a, .sponsored-page a { color: var(--text); text-decoration: none; display: block; }
.product-ad p, .sponsored-page p { margin: 0; }

/* Typography & headings (hero focus) */
header, main, footer { display: block; }

/* Base typography with fluid sizing */
h1 {
  font-size: clamp(1.6rem, 2.6vw, 2.4rem);
  line-height: 1.15;
  margin: 0 0 .5rem;
  letter-spacing: .2px;
}
p { color: var(--muted); margin: 0.25rem 0 0; }

/* Links & CTAs */
a { color: var(--accent); text-decoration: none; }
a:hover, a:focus { text-decoration: underline; outline: none; }
a:focus-visible, button:focus-visible, .btn:focus-visible, .cta:focus-visible {
  outline: 2px solid var(--accent-2);
  outline-offset: 2px;
}
.btn, .cta, a.btn, button.btn {
  display: inline-block;
  padding: 0.55em 1em;
  border-radius: 8px;
  border: 1px solid rgba(138, 92, 255, .6);
  background: rgba(138, 92, 255, .25);
  color: var(--text);
  cursor: pointer;
  text-align: center;
  text-decoration: none;
  transition: transform .2s ease, background .2s ease, border-color .2s ease;
}
.btn:hover, .cta:hover {
  transform: translateY(-1px);
  background: rgba(138, 92, 255, .38);
}
.btn:active, .cta:active {
  transform: scale(.98);
}
.outline {
  background: transparent;
  border: 1px solid rgba(138, 92, 255, .6);
}
.solid {
  background: rgba(138, 92, 255, .7);
  color: white;
  border: 1px solid rgba(138, 92, 255, .9);
}
.tag {
  display: inline-block;
  padding: .25em .6em;
  font-size: .75rem;
  border-radius: 999px;
  background: rgba(138, 92, 255, .25);
  color: var(--text);
  border: 1px solid rgba(138, 92, 255, .5);
}

/* Layout scaffolding: header, main, footer regions */
header {
  display: grid;
  place-items: center;
  padding: 1.75rem 1rem;
  text-align: center;
  margin: 1rem auto;
  width: min(100%, 1100px);
  border-radius: 14px;
  background: rgba(20,22,28,.28);
  border: 1px solid rgba(138, 92, 255, .42);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}
header h1 { margin: 0; }

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

/* Footer layout */
footer {
  padding: 1rem;
  margin-top: 1rem;
  display: grid;
  gap: 0.75rem;
}
@media (min-width: 640px) {
  footer {
    grid-template-columns: 1fr 1fr;
  }
}
footer p {
  text-align: center;
  color: var(--muted);
  margin: 0;
}

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

/* Print styles (basic readability) */
@media print {
  html, body { background: white; color: #000; }
  a, a:visited { color: #000; text-decoration: underline; }
}
