/* ==============================================================================
   DiyTomi.com - Cyber Workshop / Dark Modern Maker Theme
   Aesthetic: Deep Obsidian, Neon Cyan (#00f0ff), Neon Amber (#f59e0b), Matrix Green
   Zero-dependency, high-performance, mobile-first responsive architecture
   ============================================================================== */

:root {
  --bg-abyss: #070a12;
  --bg-surface: #0c1322;
  --bg-surface-elevated: #111b30;
  --bg-card: rgba(16, 26, 46, 0.75);
  --bg-card-hover: rgba(22, 36, 64, 0.9);
  --bg-terminal: #05080e;

  --border-subtle: rgba(0, 240, 255, 0.12);
  --border-hover: rgba(0, 240, 255, 0.4);
  --border-amber: rgba(245, 158, 11, 0.35);

  --cyan-primary: #00f0ff;
  --cyan-dim: #06b6d4;
  --cyan-glow: rgba(0, 240, 255, 0.22);

  --amber-primary: #f59e0b;
  --amber-glow: rgba(245, 158, 11, 0.25);

  --green-safe: #10b981;
  --green-glow: rgba(16, 185, 129, 0.25);

  --red-danger: #ef4444;
  --red-glow: rgba(239, 68, 68, 0.25);

  --text-main: #f8fafc;
  --text-muted: #cbd5e1;
  --text-dim: #94a3b8;

  --font-sans: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-mono: 'JetBrains Mono', 'Fira Code', Menlo, Monaco, Consolas, monospace;

  --container-max: 1240px;
  --radius-sm: 6px;
  --radius-md: 12px;
  --radius-lg: 18px;
}

/* CSS Reset & Base */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-family: var(--font-sans);
  background-color: var(--bg-abyss);
  color: var(--text-main);
  line-height: 1.6;
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
}

body {
  min-height: 100vh;
  position: relative;
  overflow-x: hidden;
  background: 
    radial-gradient(circle at 15% 10%, rgba(0, 240, 255, 0.04) 0%, transparent 40%),
    radial-gradient(circle at 85% 60%, rgba(245, 158, 11, 0.03) 0%, transparent 40%),
    linear-gradient(to bottom, #070a12, #0a0f1a);
}

/* Subtle PCB grid overlay */
body::before {
  content: "";
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  background-image: 
    linear-gradient(to right, rgba(0, 240, 255, 0.02) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(0, 240, 255, 0.02) 1px, transparent 1px);
  background-size: 40px 40px;
  z-index: 0;
}

a {
  color: var(--cyan-primary);
  text-decoration: none;
  transition: all 0.2s ease;
}

a:hover {
  color: #fff;
  text-shadow: 0 0 8px var(--cyan-primary);
}

/* Container */
.container {
  width: 100%;
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 1.5rem;
  position: relative;
  z-index: 1;
}

/* Header & Navigation */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(7, 10, 18, 0.88);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border-subtle);
  padding: 0.85rem 0;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
}

.brand-link {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.brand-logo {
  height: 44px;
  width: auto;
  object-fit: contain;
  filter: drop-shadow(0 0 10px rgba(0, 240, 255, 0.35));
  transition: transform 0.2s ease;
}

.brand-logo:hover {
  transform: scale(1.02);
}

.footer-logo {
  height: 38px;
  width: auto;
  object-fit: contain;
  filter: drop-shadow(0 0 8px var(--cyan-glow));
}

.nav-menu {
  display: flex;
  list-style: none;
  align-items: center;
  gap: 1.5rem;
}

.nav-link {
  font-size: 0.92rem;
  font-weight: 500;
  color: var(--text-muted);
  padding: 0.4rem 0.75rem;
  border-radius: var(--radius-sm);
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.nav-link:hover, .nav-link.active {
  color: var(--cyan-primary);
  background: rgba(0, 240, 255, 0.08);
}

.header-status {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  background: rgba(16, 185, 129, 0.1);
  border: 1px solid rgba(16, 185, 129, 0.25);
  color: var(--green-safe);
  font-family: var(--font-mono);
  font-size: 0.78rem;
  padding: 0.35rem 0.75rem;
  border-radius: 999px;
  letter-spacing: 0.5px;
}

.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--green-safe);
  box-shadow: 0 0 8px var(--green-safe);
  animation: pulse-dot 2s infinite ease-in-out;
}

@keyframes pulse-dot {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.4; transform: scale(0.85); }
}

/* Mobile Nav Toggle */
.mobile-toggle {
  display: none;
  background: transparent;
  border: 1px solid var(--border-subtle);
  color: var(--cyan-primary);
  font-size: 1.35rem;
  padding: 0.35rem 0.6rem;
  border-radius: var(--radius-sm);
  cursor: pointer;
}

/* Hero Section */
.hero {
  padding: 4.5rem 0 3.5rem;
  position: relative;
  text-align: center;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.35rem 0.9rem;
  border-radius: 999px;
  background: rgba(0, 240, 255, 0.08);
  border: 1px solid var(--cyan-dim);
  color: var(--cyan-primary);
  font-family: var(--font-mono);
  font-size: 0.82rem;
  margin-bottom: 1.5rem;
  box-shadow: 0 0 15px var(--cyan-glow);
}

.hero-title {
  font-size: clamp(2.2rem, 5vw, 3.8rem);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -1px;
  margin-bottom: 1.25rem;
  color: #fff;
}

.hero-title .gradient-text {
  background: linear-gradient(135deg, #00f0ff 0%, #38bdf8 50%, #f59e0b 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-desc {
  max-width: 720px;
  margin: 0 auto 2.2rem;
  font-size: 1.15rem;
  color: var(--text-muted);
  line-height: 1.7;
}

.hero-pills {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.85rem;
  margin-bottom: 2.5rem;
}

.hero-pill {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  padding: 0.4rem 0.85rem;
  border-radius: var(--radius-sm);
  font-size: 0.85rem;
  color: var(--text-muted);
}

.hero-pill svg {
  color: var(--amber-primary);
}

/* Section Header */
.section-header {
  margin-bottom: 2rem;
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1rem;
  border-bottom: 1px solid var(--border-subtle);
  padding-bottom: 1rem;
}

.section-title {
  font-size: 1.85rem;
  font-weight: 700;
  color: #fff;
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.section-title .section-icon {
  color: var(--cyan-primary);
}

.section-subtitle {
  color: var(--text-muted);
  font-size: 0.95rem;
  margin-top: 0.25rem;
}

/* Live Feed Aggregator Section */
.feed-controls {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  align-items: center;
  margin-bottom: 1.75rem;
}

.feed-filter-btn {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  color: var(--text-muted);
  padding: 0.5rem 1rem;
  border-radius: var(--radius-sm);
  font-size: 0.85rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.feed-filter-btn:hover {
  border-color: var(--cyan-primary);
  color: #fff;
}

.feed-filter-btn.active {
  background: rgba(0, 240, 255, 0.12);
  border-color: var(--cyan-primary);
  color: var(--cyan-primary);
  box-shadow: 0 0 12px var(--cyan-glow);
}

.feed-filter-badge {
  background: rgba(255, 255, 255, 0.08);
  font-size: 0.75rem;
  padding: 0.1rem 0.45rem;
  border-radius: 999px;
  font-family: var(--font-mono);
}

.feed-search-wrap {
  margin-left: auto;
  position: relative;
  min-width: 260px;
}

.feed-search-input {
  width: 100%;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  color: #fff;
  padding: 0.5rem 1rem 0.5rem 2.2rem;
  border-radius: var(--radius-sm);
  font-size: 0.85rem;
  outline: none;
  transition: border-color 0.2s ease;
}

.feed-search-input:focus {
  border-color: var(--cyan-primary);
  box-shadow: 0 0 10px var(--cyan-glow);
}

.feed-search-icon {
  position: absolute;
  left: 0.75rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-dim);
  font-size: 0.9rem;
}

/* Feed Cards Grid */
.feed-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
  gap: 1.25rem;
  margin-bottom: 2.5rem;
}

.feed-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 1.35rem;
  display: flex;
  flex-direction: column;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  position: relative;
  backdrop-filter: blur(8px);
}

.feed-card:hover {
  transform: translateY(-3px);
  border-color: var(--border-hover);
  background: var(--bg-card-hover);
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.5), 0 0 15px var(--cyan-glow);
}

.feed-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  margin-bottom: 0.75rem;
}

.feed-source-pill {
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  padding: 0.25rem 0.6rem;
  border-radius: var(--radius-sm);
  font-family: var(--font-mono);
}

.source-homeassistant {
  background: rgba(3, 169, 244, 0.15);
  border: 1px solid rgba(3, 169, 244, 0.35);
  color: #38bdf8;
}

.source-openhab {
  background: rgba(245, 158, 11, 0.15);
  border: 1px solid rgba(245, 158, 11, 0.35);
  color: #fbbf24;
}

.source-esp32 {
  background: rgba(239, 68, 68, 0.15);
  border: 1px solid rgba(239, 68, 68, 0.35);
  color: #f87171;
}

.source-esphome {
  background: rgba(16, 185, 129, 0.15);
  border: 1px solid rgba(16, 185, 129, 0.35);
  color: #34d399;
}

.feed-date {
  font-size: 0.78rem;
  color: var(--text-dim);
  font-family: var(--font-mono);
}

.feed-title {
  font-size: 1.12rem;
  font-weight: 600;
  line-height: 1.4;
  margin-bottom: 0.6rem;
  color: #fff;
}

.feed-title a {
  color: #fff;
}

.feed-title a:hover {
  color: var(--cyan-primary);
}

.feed-summary {
  font-size: 0.88rem;
  color: var(--text-muted);
  line-height: 1.55;
  margin-bottom: 1.25rem;
  flex-grow: 1;
}

.feed-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  padding-top: 0.75rem;
  font-size: 0.82rem;
}

.feed-link {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-weight: 600;
  color: var(--cyan-primary);
  font-size: 0.84rem;
}

.feed-link:hover {
  gap: 0.55rem;
}

/* Articles Section */
.articles-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(360px, 1fr));
  gap: 1.75rem;
  margin-bottom: 3.5rem;
}

.article-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  position: relative;
}

.article-card:hover {
  border-color: var(--cyan-primary);
  transform: translateY(-4px);
  box-shadow: 0 15px 30px -10px rgba(0, 0, 0, 0.7), 0 0 20px var(--cyan-glow);
}

.article-tag-bar {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 0.85rem;
}

.article-tag {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  padding: 0.2rem 0.55rem;
  border-radius: var(--radius-sm);
  background: rgba(0, 240, 255, 0.1);
  color: var(--cyan-primary);
  border: 1px solid rgba(0, 240, 255, 0.2);
}

.article-card-body {
  padding: 1.75rem;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.article-card-title {
  font-size: 1.35rem;
  font-weight: 700;
  line-height: 1.35;
  margin-bottom: 0.85rem;
  color: #fff;
}

.article-card-desc {
  color: var(--text-muted);
  font-size: 0.92rem;
  line-height: 1.6;
  margin-bottom: 1.5rem;
  flex-grow: 1;
}

.article-specs {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.6rem;
  background: rgba(0, 0, 0, 0.3);
  padding: 0.85rem;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(255, 255, 255, 0.05);
  margin-bottom: 1.25rem;
  font-family: var(--font-mono);
  font-size: 0.78rem;
}

.article-spec-item {
  color: var(--text-dim);
}

.article-spec-item strong {
  color: #e2e8f0;
}

.article-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  background: linear-gradient(135deg, rgba(0, 240, 255, 0.15), rgba(6, 182, 212, 0.25));
  border: 1px solid var(--cyan-primary);
  color: #fff;
  padding: 0.65rem 1.2rem;
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: 0.9rem;
  cursor: pointer;
  transition: all 0.2s ease;
}

.article-btn:hover {
  background: var(--cyan-primary);
  color: #000;
  box-shadow: 0 0 15px var(--cyan-primary);
  text-shadow: none;
}

/* Interactive Workshop Tools Section */
.tools-section {
  padding: 3.5rem 0;
}

.tool-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 2rem;
  margin-bottom: 2.5rem;
  position: relative;
}

.tool-header {
  margin-bottom: 1.5rem;
}

.tool-title {
  font-size: 1.5rem;
  font-weight: 700;
  color: #fff;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.35rem;
}

.tool-desc {
  color: var(--text-muted);
  font-size: 0.95rem;
}

/* Pinout Matrix Tool */
.pinout-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 1.25rem;
}

.pin-filter-btn {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: var(--text-muted);
  padding: 0.35rem 0.85rem;
  border-radius: var(--radius-sm);
  font-size: 0.8rem;
  cursor: pointer;
  transition: all 0.15s ease;
}

.pin-filter-btn:hover, .pin-filter-btn.active {
  background: rgba(0, 240, 255, 0.15);
  border-color: var(--cyan-primary);
  color: var(--cyan-primary);
}

.pinout-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(135px, 1fr));
  gap: 0.65rem;
  margin-bottom: 1.5rem;
}

.pin-cell {
  background: rgba(16, 26, 46, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-sm);
  padding: 0.65rem;
  cursor: pointer;
  transition: all 0.2s ease;
  font-family: var(--font-mono);
  position: relative;
}

.pin-cell:hover, .pin-cell.selected {
  transform: translateY(-2px);
  border-color: var(--cyan-primary);
  box-shadow: 0 0 10px var(--cyan-glow);
}

.pin-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.3rem;
}

.pin-num {
  font-weight: 700;
  font-size: 0.85rem;
  color: #fff;
}

.pin-badge {
  font-size: 0.65rem;
  padding: 0.1rem 0.35rem;
  border-radius: 3px;
  font-weight: 600;
}

.badge-safe {
  background: rgba(16, 185, 129, 0.2);
  color: var(--green-safe);
  border: 1px solid rgba(16, 185, 129, 0.4);
}

.badge-caution {
  background: rgba(245, 158, 11, 0.2);
  color: var(--amber-primary);
  border: 1px solid rgba(245, 158, 11, 0.4);
}

.badge-danger {
  background: rgba(239, 68, 68, 0.2);
  color: var(--red-danger);
  border: 1px solid rgba(239, 68, 68, 0.4);
}

.pin-function {
  font-size: 0.72rem;
  color: var(--text-dim);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.pin-inspector {
  background: var(--bg-terminal);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 1.25rem;
  margin-top: 1rem;
  font-family: var(--font-mono);
  font-size: 0.88rem;
  position: relative;
}

.pin-inspector-title {
  color: var(--cyan-primary);
  font-weight: 700;
  font-size: 1rem;
  margin-bottom: 0.5rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.pin-inspector-details {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 0.75rem;
  margin-top: 0.75rem;
  color: var(--text-muted);
}

.pin-inspector-alert {
  margin-top: 0.75rem;
  padding: 0.75rem 1rem;
  border-radius: var(--radius-sm);
  font-size: 0.84rem;
  display: flex;
  gap: 0.5rem;
  align-items: flex-start;
}

.alert-danger {
  background: rgba(239, 68, 68, 0.12);
  border: 1px solid rgba(239, 68, 68, 0.3);
  color: #fca5a5;
}

.alert-caution {
  background: rgba(245, 158, 11, 0.12);
  border: 1px solid rgba(245, 158, 11, 0.3);
  color: #fde68a;
}

.alert-safe {
  background: rgba(16, 185, 129, 0.12);
  border: 1px solid rgba(16, 185, 129, 0.3);
  color: #a7f3d0;
}

/* Battery Calculator */
.calc-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
}

.calc-inputs {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.calc-group {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.calc-label {
  display: flex;
  justify-content: space-between;
  font-size: 0.88rem;
  color: var(--text-muted);
}

.calc-value-display {
  font-family: var(--font-mono);
  color: var(--cyan-primary);
  font-weight: 600;
}

.calc-range {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 6px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 3px;
  outline: none;
  cursor: pointer;
}

.calc-range::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--cyan-primary);
  box-shadow: 0 0 10px var(--cyan-primary);
  cursor: pointer;
  transition: transform 0.1s ease;
}

.calc-range::-webkit-slider-thumb:hover {
  transform: scale(1.15);
}

.calc-results {
  background: var(--bg-terminal);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
  text-align: center;
  position: relative;
}

.result-metric {
  margin-bottom: 1.5rem;
}

.result-number {
  font-size: 3.2rem;
  font-weight: 800;
  font-family: var(--font-mono);
  color: var(--cyan-primary);
  text-shadow: 0 0 20px var(--cyan-glow);
  line-height: 1;
  margin-bottom: 0.25rem;
}

.result-unit {
  font-size: 1.1rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 1px;
}

.result-breakdown {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.75rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: 1rem;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--text-dim);
}

.breakdown-val {
  color: #fff;
  font-weight: 600;
}

/* Fact-Check Callout Badge */
.fact-verified-box {
  background: rgba(16, 185, 129, 0.08);
  border: 1px solid rgba(16, 185, 129, 0.3);
  border-radius: var(--radius-md);
  padding: 1.25rem 1.5rem;
  margin: 2rem 0;
  display: flex;
  gap: 1rem;
  align-items: flex-start;
}

.fact-verified-icon {
  color: var(--green-safe);
  font-size: 1.6rem;
  flex-shrink: 0;
}

.fact-verified-text h4 {
  color: #fff;
  font-size: 1.05rem;
  margin-bottom: 0.25rem;
}

.fact-verified-text p {
  color: var(--text-muted);
  font-size: 0.88rem;
  line-height: 1.5;
}

.fact-sources-list {
  margin-top: 0.6rem;
  font-size: 0.82rem;
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.fact-sources-list li {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  color: var(--text-dim);
}

.fact-sources-list li::before {
  content: "✓";
  color: var(--green-safe);
  font-weight: bold;
}

/* Terminal & Code snippet style */
.terminal-block {
  background: var(--bg-terminal);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  margin: 1.5rem 0;
  overflow: hidden;
  font-family: var(--font-mono);
}

.terminal-header {
  background: rgba(255, 255, 255, 0.03);
  border-bottom: 1px solid var(--border-subtle);
  padding: 0.5rem 1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.78rem;
  color: var(--text-dim);
}

.terminal-dots {
  display: flex;
  gap: 6px;
}

.terminal-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}
.dot-red { background: #ef4444; }
.dot-yellow { background: #f59e0b; }
.dot-green { background: #10b981; }

.terminal-content {
  padding: 1.25rem;
  font-size: 0.85rem;
  line-height: 1.6;
  color: #e2e8f0;
  overflow-x: auto;
}

/* Article view specific */
.article-header {
  padding: 3rem 0 2rem;
  border-bottom: 1px solid var(--border-subtle);
  margin-bottom: 2.5rem;
}

.article-breadcrumbs {
  font-family: var(--font-mono);
  font-size: 0.82rem;
  color: var(--text-dim);
  margin-bottom: 1rem;
}

.article-content {
  max-width: 860px;
  margin: 0 auto;
  font-size: 1.05rem;
  line-height: 1.8;
  color: #cbd5e1;
}

.article-content h2 {
  font-size: 1.7rem;
  color: #fff;
  margin: 2.5rem 0 1rem;
  border-left: 3px solid var(--cyan-primary);
  padding-left: 0.75rem;
}

.article-content h3 {
  font-size: 1.3rem;
  color: #fff;
  margin: 1.75rem 0 0.75rem;
}

.article-content p {
  margin-bottom: 1.25rem;
}

.article-content ul, .article-content ol {
  margin: 1rem 0 1.5rem 1.75rem;
  color: #cbd5e1;
}

.article-content li {
  margin-bottom: 0.5rem;
}

.article-table {
  width: 100%;
  border-collapse: collapse;
  margin: 1.75rem 0;
  font-size: 0.9rem;
}

.article-table th, .article-table td {
  padding: 0.75rem 1rem;
  border: 1px solid var(--border-subtle);
  text-align: left;
}

.article-table th {
  background: var(--bg-surface-elevated);
  color: var(--cyan-primary);
  font-family: var(--font-mono);
}

.article-table tr:nth-child(even) {
  background: rgba(255, 255, 255, 0.02);
}

/* Footer */
.site-footer {
  background: var(--bg-abyss);
  border-top: 1px solid var(--border-subtle);
  padding: 3.5rem 0 2rem;
  margin-top: 5rem;
  color: var(--text-dim);
  font-size: 0.88rem;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 2.5rem;
  margin-bottom: 2.5rem;
}

.footer-brand p {
  margin-top: 0.75rem;
  max-width: 380px;
  line-height: 1.6;
}

.footer-col h4 {
  color: #fff;
  font-size: 0.95rem;
  margin-bottom: 1rem;
  font-family: var(--font-mono);
  letter-spacing: 0.5px;
}

.footer-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.footer-links a {
  color: var(--text-muted);
}

.footer-links a:hover {
  color: var(--cyan-primary);
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  padding-top: 1.5rem;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  font-size: 0.82rem;
}

/* Media Queries */
@media (max-width: 900px) {
  .calc-grid {
    grid-template-columns: 1fr;
  }
  .footer-grid {
    grid-template-columns: 1fr;
  }
  .feed-search-wrap {
    width: 100%;
    margin-left: 0;
  }
}

@media (max-width: 768px) {
  .nav-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--bg-surface);
    border-bottom: 1px solid var(--border-subtle);
    flex-direction: column;
    padding: 1rem;
    gap: 0.75rem;
  }

  .nav-menu.open {
    display: flex;
  }

  .mobile-toggle {
    display: block;
  }

  .header-status {
    display: none;
  }

  .feed-grid {
    grid-template-columns: 1fr;
  }
}

