/* Section: Tokens & Base */
:root{
  --bg: #2a0f2f;
  --bg-2: #1b0b1e;
  --text: #e8eaff;
  --muted: #c9c3dd;
  --accent: #5bd3ff;
  --accent-2: #a6f0ff;
  --glass: rgba(255,255,255,.08);
  --glass-strong: rgba(255,255,255,.16);
  --border: rgba(255,255,255,.25);
  --shadow: 0 6px 20px rgba(0,0,0,.35);
  --radius: 14px;
}

/* Section: Global */
html, body { height: 100%; }
* { box-sizing: border-box; }
html { color-scheme: dark; }
body {
  margin: 0;
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial;
  color: var(--text);
  min-height: 100%;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  /* Layered background: deep plum underwater vibe + subtle noise/lines */
  background: 
    radial-gradient(circle at 20% 10%, rgba(120,60,180,.25), transparent 40%),
    radial-gradient(circle at 70% 50%, rgba(40,0,70,.15), transparent 35%),
    linear-gradient(135deg, #2a0f2f 0%, #1b0b1e 60%, #0f0520 100%),
    repeating-linear-gradient(to bottom, rgba(255,255,255,.04) 0 1px, transparent 1px 2px);
  background-blend-mode: overlay, overlay, normal, overlay;
  background-attachment: fixed;
  position: relative;
  overflow-x: hidden;
}

/* Section: Layout helpers */
.container { width: 100%; max-width: clamp(320px, 90vw, 1100px); margin: 0 auto; padding: 0 1rem; }

/* Section: Typography helpers */
h1, h2, h3, h4 { margin: 0 0 .5rem; font-weight: 600; }
p { margin: 0 0 1rem; color: var(--muted); line-height: 1.5; }
a { color: var(--accent); text-decoration: none; }
a:hover, a:focus-visible { text-decoration: underline; outline: none; }

/* Section: Focus visibility */
:focus-visible { outline: 3px solid var(--accent-2); outline-offset: 2px; }

/* Section: Utilities */
.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: .75rem; }

/* Section: Section components */
header { position: sticky; top: 0; z-index: 10; backdrop-filter: saturate(1.2) blur(6px); background: rgba(10,6,12,.6); border-bottom: 1px solid rgba(255,255,255,.15); }
header .inner { display: flex; align-items: center; justify-content: space-between; padding: .75rem 0; width: 100%; }
header h1 { font-size: clamp(1.25rem, 2.5vw, 1.75rem); margin: 0; letter-spacing: .2px; }

nav { display: flex; gap: .5rem; align-items: center; }
nav a { color: var(--text); text-decoration: none; padding: .25rem .5rem; border-radius: 6px; border: 1px solid transparent; }
nav a:hover { text-decoration: underline; }
nav a:focus-visible { outline: 3px solid var(--accent-2); outline-offset: 2px; }

/* Section: Main content styling */
main { padding: 1.25rem 0 2rem; }
.article { display: grid; place-items: center; padding: 1rem 0; }

/* Section: Image frame */
.image-frame { width: 100%; max-width: 720px; aspect-ratio: 16 / 9; overflow: hidden; border-radius: 16px; border: 1px solid rgba(255,255,255,.25); background: #0b0b0b; box-shadow: 0 10px 28px rgba(0,0,0,.5); transform: translateZ(0); }
.image-frame img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* Subtle glow/border on image frame for chrome vibe */
.image-frame { box-shadow: inset 0 0 0 1px rgba(255,255,255,.15), 0 6px 22px rgba(0,0,0,.4); }

/* Section: Glass panel helpers (fallbacks included) */
.content {
  padding: 1rem;
  border-radius: 12px;
  background: rgba(255,255,255,.08);
  border: 1px solid rgba(255,255,255,.25);
  backdrop-filter: blur(8px);
}
@supports not (backdrop-filter: blur(8px)) {
  .content { background: rgba(255,255,255,.12); }
}
@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; }
}

/* Section: Product ad & sponsor sections (footer) */
.product-ad, .sponsored-page {
  display: block;
  width: 100%;
  text-align: center;
  padding: .75rem;
  border-radius: 12px;
  background: rgba(255,255,255,.08);
  border: 1px solid rgba(255,255,255,.25);
  transition: transform .2s ease;
}
.product-ad a, .sponsored-page a { color: var(--text); text-decoration: none; display: block; padding: .25rem; }
.product-ad:hover, .sponsored-page:hover { transform: translateY(-2px); }

/* Section: Footer */
footer { padding: 1rem 0; border-top: 1px solid rgba(255,255,255,.15); background: rgba(0,0,0,.25); display: grid; gap: .75rem; justify-items: center; }
footer p { margin: 0; font-size: .8rem; color: var(--muted); }

/* Section: Form elements (if present) */
button, .btn, .cta {
  font-family: inherit;
  font-size: 1rem;
  cursor: pointer;
  border-radius: 8px;
  border: 1px solid rgba(255,255,255,.4);
  background: rgba(90,170,255,.28);
  color: var(--text);
  padding: .55rem .9rem;
  text-decoration: none;
  display: inline-block;
  transition: transform .2s ease, background .2s ease, border-color .2s ease;
}
button:hover, .btn:hover, .cta:hover { transform: translateY(-1px); background: rgba(90,170,255,.40); }
button:focus-visible, .btn:focus-visible, .cta:focus-visible { outline: 3px solid var(--accent-2); outline-offset: 2px; }
.btn--outline { background: rgba(0,0,0,.0); border-color: rgba(255,255,255,.6); color: var(--text); }
.btn--solid { background: rgba(120,190,255,.6); border-color: rgba(120,190,255,.8); }

/* Section: Lists (ul, li) */
ul { margin: 0 0 1rem 1.25rem; padding: 0; list-style: disc; color: var(--muted); }
li { margin: .25rem 0; }

/* Section: Print styles (basic readability) */
@media print {
  body { background: white; color: black; }
  header, nav, footer { display: block; }
  a { text-decoration: underline; color: black; }
}
