/* Base tokens */
:root {
  --bg: #0b0b0f;
  --bg-2: #14140e;
  --text: #eaf2ff;
  --muted: #c6d0f0;
  --khaki: #b6a052;
  --khaki-2: #9a8a37;
  --accent: #ff2db6;
  --accent-2: #ff4dcf;
  --panel: rgba(255,255,255,0.14);
  --panel-strong: rgba(255,255,255,0.22);
  --border: rgba(255,255,255,0.28);
  --focus: #00e5ff;
  --shadow: 0 10px 28px rgba(0,0,0,0.45);
  --radius: 12px;
}

/*  Layered background: gradient (khaki tint) + scanline noise */
html, body {
  height: 100%;
}
html, body {
  margin: 0;
  padding: 0;
  color: var(--text);
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif;
  font-size: clamp(14px, 1.6vw, 18px);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  background:
    linear-gradient(135deg, rgba(182,160,82,0.25) 0%, rgba(26,26,26,0.60) 60%, rgba(182,160,82,0.25) 100%),
    repeating-linear-gradient(to bottom, rgba(0,0,0,0.04) 0 1px, transparent 1px 2px);
  background-color: #0b0b0f;
  background-blend-mode: overlay, normal;
  min-height: 100dvh;
  overflow-x: hidden;
  box-sizing: border-box;
  isolation: isolate;
}

/*  Structural layout primitives */
.container {
  width: 100%;
  max-width: clamp(320px, 90vw, 1100px);
  margin-inline: auto;
  padding-inline: 1rem;
}

.image-frame {
  aspect-ratio: 16 / 9;
  width: min(92%, 860px);
  margin: 1.25rem auto;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid rgba(255,255,255,0.28);
  background: rgba(0,0,0,0.25);
  box-shadow: 0 8px 22px rgba(0,0,0,0.45);
  display: grid;
  place-items: center;
}
.image-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Glassy surfaces for structural sections */
header, main, aside, footer {
  background: rgba(12,12,14,0.28);
  border: 1px solid rgba(255,255,255,0.25);
  border-radius: var(--radius);
  padding: 1rem;
  margin: 1rem auto;
  max-width: 1200px;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  box-shadow: var(--shadow);
}
@supports not (backdrop-filter: blur(12px)) {
  header, main, aside, footer {
    background: rgba(12,12,14,0.60);
  }
}
header { text-align: center; padding-top: 1.25rem; padding-bottom: 0.75rem; }
header h1 {
  margin: 0.25rem 0 0.5rem;
  font-size: clamp(1.6rem, 4.5vw, 2.8rem);
  line-height: 1.08;
  letter-spacing: .2px;
}
nav {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
}
nav a {
  color: var(--text);
  text-decoration: none;
  padding: 0.5rem 0.9rem;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,0.28);
  transition: transform 0.2s ease, background 0.2s ease;
}
nav a:hover { background: rgba(255,255,255,0.08); }
nav a:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }

/* Main article content and image block */
main { display: block; }
article { padding: 0.5rem 0; }

/* Content wrapper (text blocks) */
.content {
  padding: 0.75rem 0;
  color: var(--text);
}
.content p { margin: 0.5rem 0; color: var(--muted); }

/* CTA and link treatments */
a, button, .btn, .cta {
  color: var(--text);
  text-decoration: none;
  background: none;
  border: none;
  font: inherit;
  cursor: pointer;
}
a { color: var(--text); }
a:hover { text-decoration: underline; text-underline-offset: 3px; }
a:focus-visible, button:focus-visible, .btn:focus-visible, .cta:focus-visible {
  outline: 2px solid var(--focus);
  outline-offset: 2px;
  border-radius: 6px;
}
.btn {
  display: inline-block;
  padding: 0.72rem 1.28rem;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,0.32);
  background: rgba(255,255,255,0.08);
  color: #fff;
  transition: transform 0.2s ease, background 0.2s ease;
}
.btn:hover { transform: translateY(-1px); background: rgba(255,255,255,0.14); }
.btn.primary {
  background: linear-gradient(135deg, var(--khaki), var(--khaki-2));
  color: #1a190f;
  border: 1px solid rgba(0,0,0,0.15);
}
.btn.secondary {
  background: rgba(0,0,0,0.25);
  border: 1px solid rgba(255,255,255,0.32);
  color: var(--text);
}
.cta { display:inline-flex; align-items:center; gap:0.5rem; }

/* Card and tag utilities */
.card {
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.22);
  border-radius: 10px;
  padding: 0.75rem;
  box-shadow: 0 6px 18px rgba(0,0,0,0.25);
}
.tag {
  display:inline-block;
  padding: .15rem .6rem;
  border-radius: 999px;
  font-size: 12px;
  border: 1px solid rgba(255,255,255,0.25);
  background: rgba(255,255,255,0.08);
  color: var(--muted);
}

/* Lists reset when used as part of layout */
ul, li { margin: 0; padding: 0; list-style: none; }

/* Utilities for responsive grid (if used) */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1rem;
}

/* Image frame glow and fallback border emphasis */
.image-frame { outline: 1px solid rgba(255,255,255,0.2); outline-offset: 0; }

/* Print styles (basic readability) */
@media print {
  html, body { background: #fff; color: #000; }
  header, main, footer { background: #fff; border: none; box-shadow: none; }
}
  
/* Respect reduced motion preferences */
@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; animation: none !important; }
}