/* Crowned: Future Cyberpunk Landing - Drones Guide (Production CSS) */

/* Tokens */
:root {
  --bg: #0b0210;
  --bg-2: #1a0b25;
  --text: #f6eaff;
  --muted: #c8b3d8;
  --accent: #9b5cff;
  --accent-2: #4fe4ff;
  --surface: rgba(11, 2, 16, 0.28);
  --surface-strong: rgba(11, 2, 16, 0.42);
  --border: rgba(160, 100, 255, 0.38);
  --shadow: 0 8px 20px rgba(0,0,0,.25);
  --radius: 14px;
  --radius-sm: 10px;
  --focus: 0 0 0 3px rgba(149, 93, 255, 0.65);
  --bg-gradient: 
    radial-gradient(circle at 15% -10%, rgba(161, 71, 255, 0.25), transparent 40%),
    linear-gradient(135deg, #120216 0%, #0b0210 60%);
}

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

html, body { height: 100%; }

/* Global typography - mobile-first with fluid sizing */
html {
  font-size: 100%;
}
body {
  margin: 0;
  color: var(--text);
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif;
  line-height: 1.5;
  background: var(--bg-gradient);
  background-attachment: fixed;
  background-size: cover;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  color-scheme: dark;
  overflow-y: auto;
  padding: 0;
}
@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; animation: none !important; }
}

/* Layered noise/scanlines (pure CSS) */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background-image:
    linear-gradient(to bottom, rgba(255,255,255,.04) 0 1px, transparent 1px 2px),
    linear-gradient(to right, rgba(255,255,255,.03) 0 1px, transparent 1px 2px);
  background-size: 100% 2px, 2px 100%;
  mix-blend-mode: overlay;
  opacity: 0.6;
}

/* Layout primitives (mobile-first) */
html, body, header, nav, main, article, aside, footer {
  /* Allow logical spacing when used as blocks */
}
.container {
  width: 100%;
  max-width: clamp(320px, 92vw, 1100px);
  margin-inline: auto;
  padding-inline: 1rem;
}
.grid {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}
.card {
  background: rgba(8,0,20,0.28);
  border: 1px solid rgba(255,255,255,.18);
  border-radius: var(--radius);
  padding: 0.75rem;
  box-shadow: var(--shadow);
}
.tag {
  display: inline-block;
  padding: .15em .6em;
  border-radius: 999px;
  font-size: .75rem;
  color: #f7f3ff;
  background: rgba(156, 0, 255, 0.25);
  border: 1px solid rgba(156,0,255,.6);
}

/* Glass panels (with backdrop-filter) */
header, main, footer {
  background: rgba(8,0,20,0.28);
  border: 1px solid rgba(255,255,255,.16);
  border-radius: var(--radius);
  padding: 1rem;
  box-shadow: 0 8px 22px rgba(0,0,0,.25);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}
@supports not ((backdrop-filter) or (-webkit-backdrop-filter)) {
  header, main, footer {
    background: rgba(8,0,20,0.55);
  }
}

header {
  text-align: center;
  padding-top: 1.25rem;
  padding-bottom: 0.75rem;
}
header h1 {
  font-size: clamp(1.6rem, 2.6vw + 1rem, 3.25rem);
  line-height: 1.08;
  margin: 0.25rem 0 0.5rem;
  letter-spacing: .2px;
}
header .meta {
  font-size: clamp(0.9rem, 0.4vw + 0.8rem, 1.05rem);
  color: var(--muted);
  margin-bottom: 0.75rem;
}
nav {
  display: inline-block;
  margin-top: 0.25rem;
}
nav a {
  color: var(--text);
  text-decoration: none;
  padding: .45rem 0.75rem;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,.25);
  background: rgba(9,0,20,.28);
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  transition: transform .15s ease;
}
nav a:hover { transform: translateY(-1px); }
nav a:focus-visible { outline: none; box-shadow: var(--focus); }

main {
  padding: 1rem 0 2rem;
}
.featured-image {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border-radius: 12px;
  border: 1px solid rgba(255,255,255,.18);
  margin: 1rem 0 1.25rem;
  box-shadow: 0 6px 18px rgba(0,0,0,.28);
}
.image-frame {
  width: 100%;
  height: 100%;
  display: block;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid rgba(255,255,255,.18);
  box-shadow: 0 6px 16px rgba(0,0,0,.25);
}
.image-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  filter: saturate(1.05);
}
article {
  padding: 0.5rem 0 0;
}
article h1 {
  font-size: clamp(1.6rem, 2.6vw + 0.8rem, 2.75rem);
  margin: .25rem 0 0.5rem;
}
article h2 {
  font-size: clamp(1.25rem, 2vw + .6rem, 1.75rem);
  margin-top: 1.25rem;
}
p { margin: .75rem 0; color: var(--text); opacity: 0.95; }
ul, ol { margin: .6rem 0 1rem 1.05rem; }
li { margin: .25rem 0; }

/* Content helper (for potential .content usage) */
.content { padding: .25rem 0; }

/* Lists and emphasis accessibility */
a, button, .btn, .cta {
  transition: background .2s ease, color .2s ease, border-color .2s ease;
}
a { color: var(--accent-2); text-decoration: none; }
a:hover, a:focus-visible { text-decoration: underline; text-underline-offset: 3px; outline: none; }
button, .btn, .cta {
  border: none;
  background: var(--accent);
  color: #fff;
  padding: .75rem 1.05rem;
  border-radius: 999px;
  cursor: pointer;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.btn {
  background: var(--accent);
  border: 1px solid rgba(153, 102, 255, 0.55);
}
.btn:hover { background: #7a4dff; transform: translateY(-1px); }
.btn:focus-visible { outline: none; box-shadow: var(--focus); }
.btn.secondary {
  background: transparent;
  color: var(--text);
  border: 1px solid rgba(156, 0, 255, 0.6);
}
.btn.secondary:hover { background: rgba(156,0,255,0.15); }
.cta {
  padding: .85rem 1.15rem;
  border-radius: 999px;
  background: linear-gradient(135deg, rgba(124,58,237,.95), rgba(0,0,0,.0));
  border: 1px solid rgba(124,58,237,.65);
  color: #fff;
}
.cta:hover { background: linear-gradient(135deg, rgba(124,58,237,.85), rgba(0,0,0,.1)); }
.cta:focus-visible { outline: none; box-shadow: var(--focus); }

/* Form elements (basic styling) */
input, textarea, select {
  font: inherit;
  color: var(--text);
  background: rgba(0,0,0,.25);
  border: 1px solid rgba(255,255,255,.25);
  border-radius: 8px;
  padding: .6rem .75rem;
  outline: none;
}
input:focus-visible, textarea:focus-visible, select:focus-visible {
  box-shadow: var(--focus);
}
label { display: block; margin-bottom: .25rem; color: var(--muted); }

/* Utility: print-friendly */
@media print {
  body { background: white; color: black; }
  a { text-decoration: underline; color: black; }
  header, main, footer { background: transparent; border: none; box-shadow: none; }
}
@media (min-width: 720px) {
  main { padding: 1.25rem 0 2rem; }
  .container { padding-inline: 1.25rem; }
}

/* Footer content blocks (product ad / sponsored) */
footer {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1rem;
  align-items: stretch;
  padding: 1rem;
}
.product-ad, .sponsored-page {
  display: grid;
  place-items: center;
  text-align: center;
  padding: .75rem;
  min-height: 72px;
}
.product-ad a, .sponsored-page a { color: var(--text); text-decoration: none; }
.product-ad p, .sponsored-page p { margin: 0; }

/* Ensure long text remains readable on glass panels */
@media (prefers-color-scheme: light) {
  :root { color-scheme: light; }
}
