/* Global & Tokens */
:root{
  --bg: #0b0f14;
  --bg-2: #171a1f;
  --text: #eaf7ff;
  --muted: #a8bdce;
  --accent: #ff8a3d;       /* orange sand dune */
  --accent-2: #2fe3c0;      /* seafoam */
  --glass: rgba(255,255,255,0.12);
  --glass-strong: rgba(255,255,255,0.22);
  --border: rgba(255,255,255,0.28);
  --shadow: 0 6px 18px rgba(0,0,0,.28);
  --radius: 14px;
}
*, *::before, *::after { box-sizing: border-box; }
html, body { height: 100%; }
html { font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif; }
body {
  margin: 0;
  color: var(--text);
  background: 
    linear-gradient(135deg, rgba(255,140,60,0.15), rgba(0,0,0,0) 40%),
    radial-gradient(circle at 70% 0%, rgba(47,227,192,0.12), transparent 40%),
    linear-gradient(#0b0f14 0%, #0b0f14 100%),
    repeating-linear-gradient(to bottom, rgba(255,255,255,0.04) 0 2px, rgba(0,0,0,0) 2px 4px);
  min-height: 100%;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  line-height: 1.5;
  -webkit-tap-highlight-color: transparent;
}
img { max-width: 100%; display: block; }

/* Layout primitives */

header, nav, main, article, aside, footer { display: block; }

/* Container helpers */
.container { max-width: clamp(320px, 88vw, 1100px); margin-inline: auto; padding-inline: 1rem; }

/* Grid utilities */
.grid { display: grid; gap: 1rem; }
.grid.minmax { grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }

/* Cards / panels (glassmorphism with graceful fallback) */
.card {
  background: var(--glass);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1rem;
  box-shadow: var(--shadow);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  color: var(--text);
}
@supports not (backdrop-filter: blur(10px)) {
  .card { background: rgba(255,255,255,0.22); border-color: rgba(255,255,255,0.35); }
}
.block { display: block; }

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

/* Typography & headings (mobile-first with fluid scaling) */
h1, h2, h3 { color: var(--text); margin: 0.5rem 0 0.25rem; line-height: 1.15; }
h1 { font-size: clamp(1.6rem, 2.3vw + 1rem, 3.2rem); letter-spacing: .2px; }
h2 { font-size: clamp(1.25rem, 1.4vw + .5rem, 2rem); margin-top: .9rem; }
h3 { font-size: clamp(1.1rem, .8vw + .4rem, 1.4rem); }

/* Paragraphs + lists */
p { margin: .65rem 0; color: rgba(234,247,255,.92); }
ul { margin: .5rem 0 1rem 1.1rem; padding: 0; }
li { margin: .25rem 0; }

/* Content block styling */
.content { font-size: clamp(0.95rem, 0.9vw + 0.3rem, 1.05rem); color: rgba(234,247,255,.92); }

/* Links & interactive elements (high-contrast focus) */
a, button, .btn, .cta { color: var(--text); text-decoration: none; background: transparent; border: none; padding: .65em 1rem; border-radius: 999px; cursor: pointer; display: inline-block; font-weight: 600; transition: transform .15s ease, background .3s ease, color .3s ease, border-color .3s; }
a { outline: none; }
a:hover { text-decoration: underline; text-underline-offset: .2em; }
.btn, .cta { background: var(--accent); color: #1a1a1a; border: 1px solid rgba(0,0,0,.1); }
.btn.secondary { background: transparent; color: var(--text); border: 1px solid rgba(255,255,255,.28); }
.btn:hover { transform: translateY(-1px); background: color-mix(in oklab, var(--accent) 90%, white 10%); }
.btn:active { transform: translateY(0); }
.btn:focus-visible, .cta:focus-visible, a:focus-visible {
  outline: 2px solid color-mix(in oklab, var(--accent) 60%, white 40%);
  outline-offset: 2px;
}
a:focus-visible { outline: 2px solid var(--accent-2); outline-offset: 2px; }

/* Navigation styling (in header) */
header { padding: 1rem; text-align: center; }
header nav { margin-top: .5rem; }
header nav a {
  padding: .5rem 0.9rem;
  border-radius: 999px;
  background: rgba(0,0,0,.25);
  border: 1px solid rgba(255,255,255,.25);
  color: var(--text);
}
header nav a:focus-visible { outline: 2px solid var(--accent-2); outline-offset: 2px; }

/* Main content layout */
main { padding: 1rem; }
article { display: block; }

/* Footer / sections (glass panels as compact cards) */
footer { padding: 1rem; border-top: 1px solid rgba(255,255,255,.08); margin-top: 1rem; }
footer .product-ad, footer .sponsored-page { text-align: center; padding: .75rem; border-radius: 12px; }
footer .product-ad { background: rgba(0,0,0,.2); border: 1px solid rgba(255,255,255,.25); }
footer .sponsored-page { background: rgba(0,0,0,.2); border: 1px solid rgba(255,255,255,.25); }

/* Footer layout: side-by-side on larger screens */
@media (min-width: 640px) {
  footer { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; align-items: center; }
  footer p { justify-self: end; grid-column: 1 / -1; text-align: center; }
  footer .product-ad, footer .sponsored-page { justify-self: stretch; }
  .image-frame { margin: 0 auto; }
}
@media (min-width: 980px) {
  main { padding: 1.5rem 0; }
  header { padding: 1.5rem 0; }
}

/* Print styles (basic readability) */
@media print {
  body { background: #fff; color: #000; }
  a, a:visited { color: #1a1a1a; text-decoration: underline; }
  .card { background: none; border: 1px solid #ccc; box-shadow: none; }
}

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