/* CSS: Mastering Digital Networking - Obsidian Grid / Seafoam Theme */

/* Tokens */
:root {
  --bg: #0b0f14;
  --bg-2: #0a1118;
  --text: #eafff6;
  --muted: #b7d3c2;
  --accent: #2bdabf;
  --accent-2: #1bd4a7;
  --panel: rgba(9, 18, 22, 0.38);
  --panel-border: rgba(46, 255, 230, 0.45);
  --shadow: 0 6px 18px rgba(0,0,0,.35);
  --radius: 14px;
  --focus: 2px solid #2bdabf;
}

html, body {
  height: 100%;
}

* { box-sizing: border-box; }

html {
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, Inter, Arial, "Noto Sans", "Liberation Sans", sans-serif;
  font-synthesis: none;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  color: var(--text);
  background: 
    linear-gradient(135deg, #0b0f14 0%, #0a1320 60%, #0b0f14 100%),
    repeating-linear-gradient(to bottom, rgba(255,255,255,.04) 0 1px, transparent 1px 2px);
  line-height: 1.5;
}

body {
  margin: 0;
  min-height: 100%;
  background-attachment: fixed;
  color: var(--text);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  -ms-overflow-style: scrollbar;
  scroll-behavior: smooth;
  background-blend-mode: overlay;
  padding: 0;
}

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

/* Layout container + utilities */
.container {
  max-width: clamp(320px, 90vw, 1100px);
  margin-inline: auto;
  padding-inline: 1rem;
}

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

.card {
  background: rgba(10, 25, 30, 0.28);
  border: 1px solid rgba(140, 255, 230, 0.35);
  border-radius: 12px;
  padding: .75rem;
  box-shadow: var(--shadow);
}

.tag {
  display: inline-block;
  padding: .25rem .6rem;
  font-size: .75rem;
  border-radius: 999px;
  background: rgba(43, 218, 191, 0.25);
  border: 1px solid rgba(43, 218, 191, 0.6);
  color: #04271b;
}

/* Glass panels (fallback + backdrop-filter) */
.panel, header, main, article, footer, aside {
  background: rgba(10, 25, 30, 0.28);
  border: 1px solid rgba(46, 255, 230, 0.28);
  border-radius: 12px;
  padding: 1rem;
  box-shadow: 0 6px 20px rgba(0,0,0,.25);
  backdrop-filter: saturate(1.1) blur(10px);
  -webkit-backdrop-filter: saturate(1.1) blur(10px);
}
@supports not(backdrop-filter: blur(10px)) {
  .panel, header, main, article, footer, aside {
    background: rgba(10, 25, 30, 0.75);
    border-color: rgba(46, 255, 230, 0.7);
  }
}

/* Image frame styling */
.image-frame {
  aspect-ratio: 16/9;
  width: 100%;
  overflow: hidden;
  border-radius: 12px;
  border: 1px solid rgba(255,255,255,0.25);
  box-shadow: 0 6px 18px rgba(0,0,0,.25), inset 0 0 12px rgba(0,0,0,.15);
  display: block;
}
.image-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform .4s ease;
}
.image-frame:hover img { transform: scale(1.02); }

/* Typography */
h1, h2, h3 {
  margin: .25rem 0 0.5rem;
  line-height: 1.15;
}
h1 { font-size: clamp(1.6rem, 2.6vw + 1rem, 2.8rem); letter-spacing: .2px; }
h2 { font-size: clamp(1.25rem, 1.6vw + 1rem, 1.75rem); }
h3 { font-size: clamp(1.05rem, 1vw + .9rem, 1.25rem); }

p { margin: .5rem 0 1rem; color: var(--muted); }

/* Links & CTAs */
a, button, .btn, .cta {
  font-family: inherit;
  font-size: clamp(0.92rem, 0.9rem + 0.2vw, 1rem);
  text-decoration: none;
  color: var(--text);
  cursor: pointer;
  transition: transform .15s ease, background .2s ease, color .2s ease;
}
a { color: var(--accent-2); text-decoration: none; }
a:hover, a:focus { text-decoration: underline; outline: none; }
a:focus-visible, button:focus-visible, .btn:focus-visible, .cta:focus-visible {
  outline: var(--focus);
  outline-offset: 2px;
}

/* Buttons (variants) */
.btn {
  display: inline-block;
  padding: .65rem 1rem;
  border-radius: 999px;
  border: 1px solid rgba(43, 218, 191, 0.75);
  background: rgba(43, 218, 191, 0.25);
  color: var(--text);
  line-height: 1;
}
.btn:hover { transform: translateY(-1px); background: rgba(43, 218, 191, 0.38); }
.btn.primary {
  background: rgba(43, 218, 191, 0.92);
  color: #041b13;
  border-color: rgba(43, 218, 191, 0.95);
}
.btn.secondary {
  background: transparent;
  border-color: rgba(43, 218, 191, 0.65);
  color: var(--text);
}
.cta {
  background: transparent;
  border: 1px solid rgba(43, 218, 191, 0.75);
  color: var(--accent);
}
.cta:hover { background: rgba(43, 218, 191, 0.15); }

/* Lists */
ul { margin: .5rem 0 1rem 1.25rem; padding: 0; }
li { margin: .25rem 0; color: var(--muted); }

/* Content helper (for potential use) */
.content { color: var(--text); font-size: clamp(1rem, 0.9vw + 0.2rem, 1.05rem); line-height: 1.6; }

/* Page structure styling */
header {
  padding: 1rem;
  margin: 0 auto 1rem;
}
header h1 { color: var(--text); font-size: clamp(1.4rem, 2vw + 1rem, 2.2rem); margin-bottom: .25rem; }
header .meta { color: var(--muted); font-size: .9rem; margin-bottom: .5rem; }

/* Main / Article layout */
main { padding: 0; }
article { display: grid; gap: 1rem; }

/* Featured image block within article */
.featured-image { margin: .5rem 0 0; }

/* Footer / Ad sections */
.product-ad, .sponsored-page { text-align: center; padding: .75rem; }
footer { padding: 1rem; margin-top: 1rem; }

/* Print styles (basic readability) */
@media print {
  body { background: white; color: #000; }
  header, main, article, footer { background: transparent; border: none; box-shadow: none; }
  a { color: #000; text-decoration: underline; }
}

/* Responsive adjustments */
@media (min-width: 640px) {
  .container { padding-inline: 1.25rem; }
}
@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !Important; }
}