:root {
  --bg: #0b0b0f;
  --bg-2: #141418;
  --text: #e6e6e6;
  --muted: #b5b5b5;
  --accent: #ff8a1f;
  --accent-2: #c9c9c9;
  --card: rgba(255, 255, 255, 0.08);
  --card-strong: rgba(255, 255, 255, 0.14);
  --border: rgba(255, 255, 255, 0.25);
  --shadow: 0 8px 28px rgba(0, 0, 0, 0.5);
  --radius: 14px;
  --radius-sm: 10px;
  --focus: 0 0 0 3px rgba(255, 196, 0, 0.75);
}

@media (prefers-color-scheme: light) {
  :root {
    --bg: #f7f7f7;
    --bg-2: #ffffff;
    --text: #111;
    --muted: #555;
    --accent: #d35400;
    --accent-2: #333;
    --card: rgba(255, 255, 255, 0.95);
    --card-strong: rgba(255, 255, 255, 0.9);
    --border: rgba(0, 0, 0, 0.15);
  }
  body { background: linear-gradient(#f8f8f8, #f0f0f0); }
  header { border-color: rgba(0,0,0,0.15); }
}

html, body { height: 100%; }
* { box-sizing: border-box; }

html { font-family: system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif; }

body {
  margin: 0;
  color: var(--text);
  background:
    radial-gradient(circle at 15% -5%, rgba(255, 140, 0, 0.14), transparent 40%),
    radial-gradient(circle at 85% 5%, rgba(200, 200, 200, 0.12), transparent 40%),
    linear-gradient(#0b0b0f 0%, #0a0a0f 40%, #141414 100%),
    repeating-linear-gradient(to bottom, rgba(255,255,255,0.04) 0 1px, transparent 1px 2px);
  background-blend-mode: screen, screen, normal, overlay;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  min-height: 100%;
  text-rendering: optimizeLegibility;
  line-height: 1.5;
  display: flex;
  flex-direction: column;
}

header, nav, main, article, aside, footer {
  width: 100%;
}

header {
  display: grid;
  place-items: center;
  padding: 1.25rem;
  margin: 0.5rem auto;
  max-width: clamp(320px, 90vw, 1100px);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.25);
  box-shadow: var(--shadow);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
}

header h1 {
  margin: 0;
  font-size: clamp(1.4rem, 1.2rem + 2vw, 2.2rem);
  letter-spacing: .2px;
  text-align: center;
  color: var(--text);
}

main { padding: 1rem 0; display: flex; justify-content: center; width: 100%; }

article { width: 100%; max-width: clamp(320px, 92vw, 1100px); padding: 0 1rem; }

/* Image frame styling */
.image-frame {
  width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: 14px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.28);
  box-shadow: inset 0 0 0 1px rgba(0,0,0,0.15), 0 12px 28px rgba(0,0,0,0.45);
  background: #111;
}
.image-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  filter: saturate(1.05);
}

/* Glass panels helper classes (fallback-friendly) */
.glass {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: var(--radius);
  padding: 1rem;
  box-shadow: var(--shadow);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
}

@supports not (backdrop-filter: blur(12px)) {
  .glass {
    background: rgba(255, 255, 255, 0.12);
  }
}

footer {
  padding: 1rem;
  margin-top: auto;
  display: grid;
  gap: 0.75rem;
  justify-items: center;
  text-align: center;
  color: var(--muted);
}

.product-ad, .sponsored-page {
  display: inline-block;
  margin: .25rem 0;
}
.product-ad a, .sponsored-page a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.6rem 1rem;
  border-radius: 999px;
  text-decoration: none;
  font-weight: 600;
  color: var(--text);
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.28);
  transition: transform 0.2s ease, background 0.2s ease;
}
.product-ad a:hover, .sponsored-page a:hover { transform: translateY(-1px); background: rgba(255, 255, 255, 0.18); }
.product-ad a:focus-visible, .sponsored-page a:focus-visible { outline: none; box-shadow: var(--focus); }

footer p { margin: 0.25rem 0 0; font-size: 0.9rem; color: var(--muted); }

a, button, .btn, .cta {
  outline: none;
  color: var(--text);
  text-decoration: none;
  -webkit-tap-highlight-color: transparent;
}
a:focus-visible, button:focus-visible { outline: none; box-shadow: var(--focus); outline-offset: 0; border-radius: 6px; }

a:hover { text-decoration: underline; }

/* Utility layout helpers */
.container {
  width: 100%;
  max-width: clamp(320px, 90vw, 1200px);
  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(--border);
  border-radius: var(--radius);
  padding: 1rem;
  box-shadow: var(--shadow);
}
.tag {
  display: inline-block;
  padding: .25rem .6rem;
  font-size: .75rem;
  border-radius: 999px;
  background: rgba(255,255,255,0.15);
  color: var(--text);
  border: 1px solid rgba(255,255,255,0.25);
}

/* Form elements (if present) match theme */
input, select, textarea {
  background: rgba(255,255,255,0.08);
  color: var(--text);
  border: 1px solid rgba(255,255,255,0.25);
  border-radius: 8px;
  padding: 0.5em 0.75em;
  outline: none;
}
input:focus-visible, textarea:focus-visible, select:focus-visible {
  box-shadow: var(--focus);
  border-color: rgba(255,255,255,0.5);
}
button, .btn, .cta {
  cursor: pointer;
  user-select: none;
}
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.75rem 1.25rem;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,0.28);
  background: var(--accent);
  color: #111;
  font-weight: 700;
  text-transform: none;
  transition: transform 0.2s ease, background 0.2s ease;
}
.btn:hover { transform: translateY(-1px); background: #ff9c2a; }
.btn:active { transform: translateY(0); opacity: .95; }
.btn:focus-visible { outline: none; box-shadow: var(--focus); }

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

@media print {
  body { color: #000; background: #fff; }
  header, main, footer { background: transparent; box-shadow: none; }
}