:root {
  /* Tokenized palette (derived from white + coral) */
  --bg: #ffffff;
  --bg-2: #f6f6f6;
  --text: #0a0a0a;
  --muted: #555d66;

  --accent: #ff6f61;       /* coral */
  --accent-2: #ff8a6a;     /* lighter coral */

  --card: rgba(255, 255, 255, 0.88);
  --card-2: rgba(255, 255, 255, 0.72);
  --backdrop: rgba(255, 255, 255, 0.14);
  --border: rgba(0, 0, 0, 0.18);
  --shadow: 0 6px 18px rgba(0, 0, 0, 0.08);
  --radius: 14px;
  --focus: 3px solid var(--accent);
  --gap: 1rem;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0a0f14;
    --bg-2: #0b1116;
    --text: #e8f0f4;
    --muted: #a6b3c0;

    --accent: #ff7f66;
    --accent-2: #ff9b82;

    --card: rgba(8, 8, 8, 0.60);
    --card-2: rgba(8, 8, 8, 0.40);
    --backdrop: rgba(0, 0, 0, 0.56);
    --border: rgba(255, 255, 255, 0.22);
    --shadow: 0 6px 20px rgba(0, 0, 0, 0.50);
  }
}

html, body {
  height: 100%;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial;
  line-height: 1.5;
  position: relative;
  min-height: 100%;
  overflow-x: hidden;
  z-index: 0;
  /* Layered background: gradient + subtle scanlines/noise (CSS only) */
}
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  /* subtle diagonal gradient veil for cyber vibe */
  background: linear-gradient(135deg, rgba(255, 112, 97, 0.04), rgba(0, 0, 0, 0.04) 60%, rgba(255, 124, 76, 0.04)),
              radial-gradient(circle at 25% 20%, rgba(255, 255, 255, 0.6), transparent 40%);
  pointer-events: none;
  mix-blend-mode: overlay;
}
body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  /* fine scanlines for depth */
  background: repeating-linear-gradient(
                0deg,
                rgba(0,0,0,.04) 0px,
                rgba(0,0,0,.04) 1px,
                transparent 1px,
                transparent 2px
              );
  opacity: 0.25;
  pointer-events: none;
  mix-blend-mode: overlay;
}

/* Layout helpers */
.container {
  width: 100%;
  max-width: clamp(320px, 92vw, 1120px);
  margin-inline: auto;
  padding: 0 1rem;
}
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: var(--gap);
}
.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1rem;
  box-shadow: var(--shadow);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}
@supports not (backdrop-filter: blur(8px)) {
  .card { background: rgba(255,255,255,0.92); }
}
.image-frame {
  width: min(100%, 720px);
  aspect-ratio: 16 / 9;
  border-radius: 12px;
  overflow: hidden;
  margin: 0 auto;
  background: rgba(255,255,255,.6);
  border: 1px solid rgba(0,0,0,.15);
  box-shadow: 0 6px 18px rgba(0,0,0,.15);
}
.image-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  /* subtle glow on image for cyber aesthetic */
  filter: saturate(1.05);
}
header, main, footer, aside {
  position: relative;
  z-index: 1;
}
header {
  padding: clamp(1.75rem, 4vw, 3rem) 1rem 1rem;
  text-align: center;
}
header h1 {
  margin: 0;
  font-size: clamp(1.75rem, 4vw + 1rem, 3.5rem);
  line-height: 1.04;
  font-weight: 800;
  letter-spacing: .2px;
}
header .subtitle {
  margin-top: .5rem;
  font-size: clamp(1rem, 0.6vw + 0.9rem, 1.125rem);
  color: var(--muted);
}
main { padding: 1rem 0 2rem; }
.content { padding: 0 0; }

footer {
  padding: 1.25rem 1rem 2rem;
  display: grid;
  gap: 1rem;
  align-items: center;
}
.product-ad, .sponsored-page {
  display: block;
  text-align: center;
  text-decoration: none;
  color: inherit;
  padding: .75rem;
  border-radius: 12px;
  background: var(--card);
  border: 1px solid var(--border);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  box-shadow: var(--shadow);
}
.product-ad a, .sponsored-page a { color: inherit; text-decoration: none; display: block; }
.product-ad p, .sponsored-page p { margin: 0; font-weight: 600; }

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

/* Typography helpers for WCAG-friendly text on glass */
h2, h3, h4 { color: var(--text); }

/* Links and buttons */
a, button, .btn, .cta {
  -webkit-tap-highlight-color: transparent;
}
a {
  color: var(--accent);
  text-decoration: none;
}
a:hover, a:focus-visible {
  text-decoration: underline;
  outline: none;
}
a:focus-visible {
  outline: var(--focus);
  outline-offset: 3px;
}
.btn, .cta {
  display: inline-block;
  padding: 0.85em 1.25em;
  border-radius: 999px;
  border: 1px solid rgba(0,0,0,.2);
  background: var(--accent);
  color: #fff;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  transition: transform .15s ease, background .2s ease, box-shadow .2s ease;
}
.btn:hover, .cta:hover {
  transform: translateY(-1px);
  background: var(--accent-2);
  box-shadow: 0 6px 14px rgba(0,0,0,.18);
}
.btn:focus-visible {
  outline: var(--focus);
  outline-offset: 2px;
}
.btn.outline {
  background: transparent;
  color: var(--text);
  border: 1px solid var(--accent);
}
.btn.outline:hover {
  background: rgba(255, 111, 97, 0.08);
}
.tag {
  display: inline-block;
  padding: .15em .5em;
  font-size: .75rem;
  border-radius: 999px;
  background: rgba(255, 111, 97, 0.15);
  color: var(--accent);
  border: 1px solid rgba(255, 111, 97, 0.35);
}

/* Lists (if used) */
ul { margin: 0; padding-left: 1.25rem; }
li { margin: .25rem 0; }

/* Layout helpers (utility) */
 .container { width: 100%; max-width: clamp(320px, 92vw, 1100px); margin: 0 auto; padding: 0 1rem; }
 .grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 1rem; }

/* Hero pattern emphasis for hierarchy */
.hero {
  display: grid;
  gap: .75rem;
  justify-items: center;
  padding: 1rem;
}
.hero h1 { margin: 0; }

/* Print styles (basic readability) */
@media print {
  body { background: #fff; color: #000; }
  .glass, .product-ad, .sponsored-page { background: #fff; border: 1px solid #ccc; }
}
