/* Base palette & layered background */
:root{
  --bg: #1b0f20;
  --bg-2: #250a24;
  --text: #f6eaff;
  --muted: #c9b5d9;
  --accent: #ff1744;
  --accent-2: #e60028;
  --card: rgba(18, 8, 28, 0.72);
  --card-border: rgba(255, 255, 255, 0.28);
  --glass: rgba(255, 255, 255, 0.08);
  --glow: 0 8px 24px rgba(0,0,0,.35);
  --shadow-soft: 0 6px 18px rgba(0,0,0,.25);
  --radius: 14px;
}
html, body { height: 100%; }
html { font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", "Liberation Sans", sans-serif; font-size: 16px; }
body {
  margin:0;
  color: var(--text);
  background:
    linear-gradient(135deg, rgba(18,0,28,.95) 0%, rgba(28,0,45,.92) 60%, rgba(7,0,14,.98) 100%),
    repeating-linear-gradient(to bottom, rgba(255,255,255,.04) 0 2px, transparent 2px 4px);
  background-attachment: fixed;
  background-blend-mode: overlay;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  line-height: 1.5;
  overflow-x: hidden;
}
@media (max-width: 800px){
  body { background-attachment: scroll; }
}
@supports not (backdrop-filter: blur(12px)) {
  .glass { background: rgba(12,0,28,.52); }
}

/* Section: Layout primitives */
.container { width: min(100%, 1120px); margin-inline: auto; padding: 0 1rem; }
.grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 1rem; }
.card { background: var(--card); border: 1px solid var(--card-border); border-radius: var(--radius); padding: 1rem; box-shadow: var(--shadow-soft); }

/* Section: Typography & helpers */
.content { color: var(--text); font-size: clamp(1rem, 0.9vw + 0.8rem, 1.125rem); line-height: 1.6; }
h1, h2, h3 { color: var(--text); margin: .5rem 0; font-weight: 700; }
h1 { font-size: clamp(2rem, 4vw + 1rem, 4rem); line-height: 1.08; letter-spacing: .5px; }
h2 { font-size: clamp(1.5rem, 2vw + 1rem, 2.5rem); }
h3 { font-size: clamp(1.1rem, 1vw + .8rem, 1.6rem); }

/* Section: Glass panels & backdrop */
.glass {
  background: rgba(13,0,28,.22);
  border: 1px solid rgba(255,255,255,.28);
  border-radius: 12px;
  padding: 1rem;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  box-shadow: var(--glow);
}
@supports not (backdrop-filter: blur(12px)) {
  .glass { background: rgba(13,0,28,.40); }
}

/* Section: Image frame styling */
.image-frame, .featured-image {
  width: 100%; border-radius: 12px; overflow: hidden;
  border: 1px solid rgba(255,255,255,.28);
  box-shadow: 0 6px 20px rgba(0,0,0,.4);
}
.image-frame { aspect-ratio: 16 / 9; }
.image-frame img, .featured-image img { width: 100%; height: 100%; object-fit: cover; display: block; }
.featured-image { display: block; }

/* Section: Content wrappers & utilities */
a, button, .btn, .cta {
  color: var(--text);
  text-decoration: none;
  cursor: pointer;
  font-weight: 600;
}
a:hover, a:focus-visible { text-decoration: underline; outline: none; }
.btn, .cta { display: inline-block; padding: .65em 1em; border-radius: 999px; border: 0; }
.btn { background: var(--accent); color: #fff; transition: transform .15s ease, background .2s ease; }
.btn:hover { transform: translateY(-1px); background: #ff2b60; }
.btn:active { transform: translateY(0); }
.btn--outline {
  background: transparent; border: 1px solid rgba(255,255,255,.45); color: var(--text);
}
.cta { background: var(--accent-2); border: 0; color: #fff; padding: .6em .9em; }

/* Focus ring for accessibility */
a:focus-visible, button:focus-visible, [tabindex]:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
  border-radius: 6px;
}

/* Section: Page structure selectors (Targeted) */
header, nav, main, article, aside, footer {
  display: block;
}
header { padding: clamp(1rem, 3vw, 2rem) 1rem; text-align: center; }
header h1 { margin: 0 0 .25rem; }
header .meta { font-size: 0.92rem; color: var(--muted); }

/* Nav styling (in header) */
header nav { margin-top: .5rem; }
header nav a { padding: .4rem 0.6rem; border-radius: 999px; background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.25); }

/* Main content area */
main { padding: 1rem; }
article { max-width: 860px; margin: 0 auto; padding: 0 0.5rem; }
article p { margin: 0 0 1rem; }

/* Lists & items */
ul { padding-left: 1.25rem; margin: .75rem 0; }
li { margin: .25rem 0; }

/* Product/ad sections in footer (glass-style cards) */
footer { padding: 1rem; text-align: center; color: var(--muted); }
.product-ad, .sponsored-page { display: inline-block; margin: .25rem; padding: .6rem 0.8rem; border-radius: 12px; background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.25); min-width: 140px; }
.product-ad a, .sponsored-page a { display: block; color: var(--text); }

/* Print styles (basic readability) */
@media print {
  body { background: white; color: black; }
  a { text-decoration: underline; color: black; }
}
 
/* Motion preferences */
@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; }
}
