/* Section: Theme tokens */
:root {
  --bg: #0b1020;
  --bg-2: #0a1220;
  --text: #e9f2ff;
  --muted: #a6b8d8;
  --accent: #FF6F61;
  --accent-2: #FF9F63;
  --glass: rgba(255, 255, 255, 0.12);
  --glass-border: rgba(255, 255, 255, 0.25);
  --shadow: 0 8px 28px rgba(0,0,0,.25);
  --radius: 12px;
  --focus: 2px;
}

/* Section: Base & Layout */
html, body { height: 100%; }
*, *::before, *::after { box-sizing: border-box; }

body {
  margin: 0;
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", "Liberation Sans", sans-serif;
  color: var(--text);
  line-height: 1.5;
  background-image:
    linear-gradient(135deg, rgba(0,0,0,.25), rgba(0,0,0,.12) 60%, rgba(0,0,0,0) 100%),
    repeating-linear-gradient(135deg, rgba(255,255,255,.04) 0 2px, rgba(255,255,255,.04) 2px 4px, transparent 4px 8px),
    linear-gradient(to bottom right, var(--bg), var(--bg-2));
  background-attachment: fixed;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

.container { width: 100%; max-width: clamp(320px, 92vw, 1100px); margin-inline: auto; padding-inline: 1rem; }

/* Glass panels (fallback: higher opacity if backdrop-filter unavailable) */
header, main, footer, aside {
  background: var(--glass);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius);
  padding: 1rem;
  box-shadow: var(--shadow);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

@supports not (backdrop-filter: blur(12px)) {
  header, main, footer, aside { background: rgba(255,255,255,.22); border-color: rgba(255,255,255,.4); }
}

a { color: var(--text); text-decoration: none; }
a:hover, a:focus { text-decoration: underline; }
a:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 6px; }

/* Section: Header & Hero */
header { display: block; padding: 1.25rem; margin: 0 auto 1rem; text-align: left; }
header h1 { font-size: clamp(1.6rem, 3.8vw, 2.6rem); line-height: 1.08; margin: 0 0 .4rem; letter-spacing: .2px; }
header .meta { color: var(--muted); font-size: clamp(0.9rem, 1.6vw, 1.05rem); margin: 0 0 .75rem; }

/* Section: Navigation */
nav { margin-top: .25rem; display: inline-block; }
nav a { display: inline-flex; align-items: center; gap: .5ch; padding: .4rem .8rem; border-radius: 999px; background: rgba(0,0,0,.15); border: 1px solid rgba(255,255,255,.25); }

/* Section: Main content & article */
main { padding: 0; }
article { max-width: 72ch; margin: 0 auto; padding: 1rem 0 2rem; }

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

/* Section: Typography & content helpers */
.content { color: var(--text); font-size: clamp(0.95rem, 1.7vw, 1rem); line-height: 1.6; }
h2, h3 { color: var(--text); margin-top: 1.25rem; margin-bottom: .5rem; }
h2 { font-size: clamp(1.4rem, 3vw, 2rem); }
h3 { font-size: clamp(1.15rem, 2.4vw, 1.5rem); }
p { margin: .6rem 0 1rem; }

/* Lists & blocks */
ul, li { margin: .25rem 0; padding-left: 1.25rem; }
li { margin: .25rem 0; color: var(--text); }
blockquote { margin: .75rem 0; padding: .75rem 1rem; border-left: 3px solid var(--accent); background: rgba(255,255,255,.05); border-radius: 6px; }

/* Section: Product ad / footer tiles */
.product-ad { padding: .5rem; text-align: center; }
.product-ad a { display: inline-block; padding: .75rem 1rem; border-radius: 10px; background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.25); color: var(--text); }

/* Section: Utility classes */
.grid { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
.card { padding: 1rem; background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.25); border-radius: 12px; }

/* Tag pills */
.tag { display: inline-block; padding: .25em .6em; font-size: .8rem; border-radius: 999px; background: rgba(255,255,255,.15); border: 1px solid rgba(255,255,255,.25); }

/* Section: Buttons (cta/btn) */
.btn, .cta { display: inline-block; padding: .75rem 1.25rem; border-radius: 999px; border: 1px solid rgba(255,255,255,.4); background: linear-gradient(to bottom right, rgba(255,255,255,.22), rgba(255,255,255,.08)); color: var(--text); cursor: pointer; transition: transform .15s ease, background .15s ease; }
.btn:hover, .cta:hover { transform: translateY(-1px); background: linear-gradient(to bottom right, rgba(255,255,255,.28), rgba(255,255,255,.10)); }
.btn:active, .cta:active { transform: translateY(0); }
.btn.primary, .cta.primary { background: linear-gradient(to bottom right, var(--accent), var(--accent-2)); border-color: rgba(0,0,0,.25); }

/* Focus management */
button:focus-visible, a:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 6px; }

/* Section: Print styles */
@media print {
  body { background: #fff; color: #000; }
  a { color: #00f; text-decoration: underline; }
  header, main, footer { border: none; background: transparent; box-shadow: none; }
}
   
/* Section: Motion preferences */
@media (prefers-reduced-motion: reduce) {
  * { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; }
}