/* Tokens */
:root {
  --plum: #4b0f2d;
  --plum-2: #2b0a1a;
  --cyber: #e4d300;
  --cyber-2: #ffd84d;
  --bg: #2a0f28;
  --bg-2: #3a0f37;
  --text: #f8f8ff;
  --muted: #d8cfe8;
  --panel: rgba(20, 0, 40, 0.22);
  --panel-2: rgba(20, 0, 40, 0.28);
  --border: rgba(255, 255, 255, 0.28);
  --shadow: 0 8px 20px rgba(0,0,0,.25);
  --focus: 0 0 0 3px rgba(228, 212, 0, 0.6);
}

/* Base & layout (mobile-first) */
* { box-sizing: border-box; }
html, body { height: 100%; }
html { font-family: ui-system, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", "Liberation Sans", sans-serif; }
body {
  margin: 0;
  color: var(--text);
  background: var(--bg);
  /* Layered background: soft cyber gradient + subtle scanlines */
  background-image:
    linear-gradient(135deg, rgba(60,0,60,0.9) 0%, rgba(20,0,40,0.95) 60%, rgba(12,0,24,0.95) 100%),
    repeating-linear-gradient(0deg, rgba(255,255,255,0.04) 0 1px, transparent 1px 2px),
    repeating-linear-gradient(90deg, rgba(0,0,0,0.04) 0 1px, transparent 1px 2px),
    linear-gradient(transparent, transparent);
  background-blend-mode: normal, overlay, overlay, normal;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  min-height: 100vh;
  padding: 0;
  line-height: 1.5;
  overflow-x: hidden;
}
* { scroll-behavior: smooth; }

/* Structural selectors (styling targets) */
header, nav, main, article, aside, footer { display: block; }

/* Container & grids */
.container {
  width: min(90%, 1100px);
  margin-inline: auto;
  padding: 0 1rem;
}
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1rem;
}

/* Headers & typography */
header {
  padding: 1.75rem 0 1rem;
  text-align: center;
}
header h1 {
  margin: 0;
  font-size: clamp(1.6rem, 1.2rem + 2.4vw, 2.8rem);
  font-weight: 800;
  letter-spacing: .2px;
  color: #f9f8ff;
}
main { padding: 0 0 2rem; }

/* Image frame with aspect-ratio, glow & border */
.image-frame {
  width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: 14px;
  overflow: hidden;
  border: 1px solid rgba(255,255,255,.28);
  box-shadow: 0 10px 28px rgba(0,0,0,.28);
  background: rgba(0,0,0,.25);
  margin: 0 auto;
}
.image-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform .35s ease;
  will-change: transform;
}
.image-frame:hover img {
  transform: scale(1.04);
}

/* Glass panels (frosted glass) */
.content, .card, .product-ad {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1rem;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  box-shadow: var(--shadow);
}
@supports not ((-webkit-backdrop-filter: blur(10px)) or (backdrop-filter: blur(10px))) {
  .content, .card, .product-ad { background: rgba(10,0,20,0.72); border-color: rgba(255,255,255,.40); }
}

/* Product ad & links (interactive) */
.product-ad {
  display: inline-block;
  margin: .5rem 0;
  padding: .6rem 1rem;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,.55);
  background: rgba(24, 0, 40, 0.28);
}
.product-ad a { color: var(--text); text-decoration: none; display: block; }

/* Links, buttons, and utilities */
a, button, .btn, .cta {
  text-decoration: none;
  color: var(--text);
  border: none;
  background: transparent;
  cursor: pointer;
}
.btn {
  display: inline-block;
  padding: .65rem 1.05rem;
  border-radius: 999px;
  font-weight: 700;
  border: 1px solid rgba(0,0,0,.15);
  background: linear-gradient(135deg, rgba(228,212,0,1), rgba(228,212,0,0.92));
  color: #0b0b0b;
  transition: transform .15s ease, box-shadow .2s ease;
}
.btn:hover { transform: translateY(-1px); box-shadow: 0 6px 16px rgba(0,0,0,.25); }
.btn:focus-visible { outline: 0; box-shadow: var(--focus); outline-offset: 2px; }
.btn--outline {
  background: transparent;
  color: var(--text);
  border: 1px solid rgba(255,255,255,.6);
}
.cta {
  padding: .65rem 1rem;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,.6);
  background: rgba(255,255,255,.08);
  color: var(--text);
  font-weight: 700;
}
a:hover, a:focus { text-decoration: underline; text-underline-offset: 2px; }

/* Lists & chips */
ul { padding-inline-start: 1.25rem; }
li { margin: .25rem 0; }

/* Utility components */
.content { margin: 0.75rem 0; }

/* Typography scale (system font with fluid sizes) */
p { font-size: clamp(0.95rem, 0.6vw + 0.9rem, 1.05rem); line-height: 1.6; color: #eef0ff; }

/* Card styles (used by grid items if present) */
.card {
  display: block;
  min-height: 120px;
}
.tag {
  display: inline-block;
  padding: .25em .5em;
  border-radius: 999px;
  font-size: .75rem;
  background: rgba(224,193,0,.22);
  color: #fff4b3;
  border: 1px solid rgba(224,193,0,.55);
}

/* Layout tweaks for smaller viewports */
@media (max-width: 700px) {
  header { padding: 1rem 0; }
  .container { width: 92%; }
  .image-frame { border-radius: 12px; }
}

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

/* Print */
@media print {
  body { background: #fff; color: #000; }
  .image-frame { page-break-inside: avoid; }
  a, button { text-decoration: none; color: inherit; }
}