:root {
  --bg-primary: #0C0E12;
  --bg-secondary: #141820;
  --bg-card: #1A1F2B;
  --bg-card-hover: #222938;
  --text-main: #F3F4F6;
  --text-muted: #9CA3AF;
  --text-subtle: #6B7280;
  --accent-emerald: #10B981;
  --accent-emerald-light: #34D399;
  --accent-emerald-glow: rgba(16, 185, 129, 0.18);
  --accent-amber: #F59E0B;
  --accent-red: #EF4444;
  --border-color: #2D3748;
  --border-light: rgba(255, 255, 255, 0.08);
  --font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;
  --radius-full: 9999px;
  --transition-fast: 0.2s ease;
  --transition-smooth: 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  --max-w: 1200px;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-family: var(--font-family);
  background-color: var(--bg-primary);
  color: var(--text-main);
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

a {
  color: inherit;
  text-decoration: none;
  transition: color var(--transition-fast);
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

.container {
  width: 100%;
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 24px;
}

/* SLIM UNSTUCK HEADER */
.site-header {
  position: relative; /* Not sticky, scrolls off page naturally */
  width: 100%;
  background: var(--bg-primary);
  border-bottom: 1px solid var(--border-light);
  z-index: 100;
}

.nav-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px; /* Slim height */
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 20px;
}

.brand-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 1.15rem;
  letter-spacing: -0.02em;
  color: #FFFFFF;
}

.brand-icon {
  width: 32px;
  height: 32px;
  background: linear-gradient(135deg, #10B981, #047857);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #FFFFFF;
  box-shadow: 0 2px 10px rgba(16, 185, 129, 0.3);
}

.brand-icon svg {
  width: 18px;
  height: 18px;
  fill: currentColor;
}

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

.nav-link {
  font-size: 0.92rem;
  font-weight: 500;
  color: var(--text-muted);
  transition: color var(--transition-fast);
  padding: 6px 0;
}

.nav-link:hover,
.nav-link.active {
  color: var(--accent-emerald-light);
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 16px;
}

.btn-cta-slim {
  background: var(--accent-emerald);
  color: #042517;
  font-weight: 600;
  font-size: 0.88rem;
  padding: 8px 18px;
  border-radius: var(--radius-full);
  transition: all var(--transition-fast);
  border: 1px solid rgba(255,255,255,0.1);
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.btn-cta-slim:hover {
  background: var(--accent-emerald-light);
  transform: translateY(-1px);
  box-shadow: 0 4px 14px var(--accent-emerald-glow);
}

.hamburger-btn {
  display: none;
  background: transparent;
  border: none;
  color: var(--text-main);
  cursor: pointer;
  padding: 6px;
  border-radius: var(--radius-sm);
}

.hamburger-btn svg {
  width: 24px;
  height: 24px;
}

/* Mobile Navigation Drawer */
.mobile-nav {
  display: none;
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border-color);
  padding: 18px 24px 24px;
}

.mobile-nav.open {
  display: block;
}

.mobile-nav-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-bottom: 20px;
}

.mobile-nav-link {
  font-size: 1rem;
  color: var(--text-muted);
  font-weight: 500;
}

.mobile-nav-link:hover {
  color: var(--accent-emerald-light);
}

/* BUTTONS */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-weight: 600;
  font-size: 0.95rem;
  padding: 12px 24px;
  border-radius: var(--radius-md);
  transition: all var(--transition-fast);
  cursor: pointer;
  border: none;
}

.btn-primary {
  background: var(--accent-emerald);
  color: #062419;
}

.btn-primary:hover {
  background: var(--accent-emerald-light);
  box-shadow: 0 8px 24px rgba(16, 185, 129, 0.25);
  transform: translateY(-1px);
}

.btn-secondary {
  background: var(--bg-card);
  color: var(--text-main);
  border: 1px solid var(--border-color);
}

.btn-secondary:hover {
  background: var(--bg-card-hover);
  border-color: var(--text-subtle);
}

.btn-outline {
  background: transparent;
  color: var(--accent-emerald-light);
  border: 1px solid var(--accent-emerald);
}

.btn-outline:hover {
  background: var(--accent-emerald-glow);
}

/* HERO SECTION */
.hero {
  padding: 72px 0 60px;
  position: relative;
  overflow: hidden;
  background: radial-gradient(circle at 50% 0%, #15241E 0%, var(--bg-primary) 70%);
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 48px;
  align-items: center;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(16, 185, 129, 0.12);
  color: var(--accent-emerald-light);
  padding: 5px 12px;
  border-radius: var(--radius-full);
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 20px;
  border: 1px solid rgba(16, 185, 129, 0.25);
}

.hero-title {
  font-size: 2.85rem;
  line-height: 1.18;
  font-weight: 800;
  letter-spacing: -0.03em;
  margin-bottom: 20px;
}

.hero-title span {
  color: var(--accent-emerald-light);
}

.hero-description {
  font-size: 1.12rem;
  color: var(--text-muted);
  line-height: 1.65;
  margin-bottom: 32px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}

.hero-metric-panel {
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 28px;
  box-shadow: 0 20px 40px rgba(0,0,0,0.4);
}

.metric-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 16px;
  margin-bottom: 20px;
}

.metric-status {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.82rem;
  color: var(--accent-emerald-light);
}

.pulse-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent-emerald);
  box-shadow: 0 0 10px var(--accent-emerald);
}

.broker-feed-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 14px;
  background: var(--bg-card);
  border-radius: var(--radius-sm);
  margin-bottom: 10px;
  font-size: 0.88rem;
}

.broker-name {
  font-weight: 600;
  color: var(--text-main);
}

.broker-time {
  font-size: 0.78rem;
  color: var(--text-subtle);
}

.tag-status {
  padding: 3px 8px;
  font-size: 0.75rem;
  border-radius: 4px;
  font-weight: 600;
}

.tag-purged {
  background: rgba(16, 185, 129, 0.15);
  color: var(--accent-emerald-light);
}

.tag-queued {
  background: rgba(245, 158, 11, 0.15);
  color: var(--accent-amber);
}

/* SECTION COMMONS */
.section-padding {
  padding: 72px 0;
}

.section-head {
  text-align: center;
  max-width: 680px;
  margin: 0 auto 52px;
}

.section-subhead {
  color: var(--accent-emerald);
  text-transform: uppercase;
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  margin-bottom: 10px;
}

.section-title {
  font-size: 2.2rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 14px;
}

.section-intro {
  color: var(--text-muted);
  font-size: 1.05rem;
}

/* CARDS GRID */
.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
}

.grid-2 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 32px;
}

.card {
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform var(--transition-fast), border-color var(--transition-fast), box-shadow var(--transition-fast);
}

.card:hover {
  transform: translateY(-4px);
  border-color: rgba(16, 185, 129, 0.5);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.35);
}

.card-img-box {
  width: 100%;
  height: 200px;
  overflow: hidden;
  position: relative;
  background-color: var(--bg-card);
}

.card-img-box img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--transition-smooth);
}

.card:hover .card-img-box img {
  transform: scale(1.05);
}

.card-badge-top {
  position: absolute;
  top: 14px;
  left: 14px;
  background: rgba(12, 14, 18, 0.88);
  border: 1px solid var(--border-light);
  color: var(--accent-emerald-light);
  font-size: 0.75rem;
  padding: 4px 10px;
  border-radius: var(--radius-sm);
  font-weight: 600;
  backdrop-filter: blur(4px);
}

.card-body {
  padding: 24px;
  flex-grow: 1;
  display: flex;
  flex-direction: column;
}

.card-body h3 {
  font-size: 1.25rem;
  font-weight: 700;
  line-height: 1.35;
  margin-bottom: 12px;
  color: #FFFFFF;
}

.card-body p {
  color: var(--text-muted);
  font-size: 0.92rem;
  line-height: 1.6;
  margin-bottom: 20px;
  flex-grow: 1;
}

.card-footer {
  padding: 0 24px 24px;
}

.btn-card {
  width: 100%;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  color: #FFFFFF;
  padding: 10px 16px;
  border-radius: var(--radius-sm);
  font-size: 0.88rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: all var(--transition-fast);
}

.btn-card:hover {
  background: var(--accent-emerald);
  color: #052a1a;
  border-color: var(--accent-emerald);
}

/* DATA LOOKUP SIMULATOR WIDGET */
.scanner-box {
  background: linear-gradient(180deg, #18221D 0%, var(--bg-secondary) 100%);
  border: 1px solid rgba(16, 185, 129, 0.3);
  border-radius: var(--radius-lg);
  padding: 36px;
  margin-bottom: 60px;
}

.scanner-form {
  display: flex;
  gap: 12px;
  margin-top: 24px;
}

.scanner-input {
  flex-grow: 1;
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  color: #FFFFFF;
  padding: 14px 18px;
  border-radius: var(--radius-md);
  font-size: 1rem;
}

.scanner-input:focus {
  outline: none;
  border-color: var(--accent-emerald);
}

.scanner-results {
  margin-top: 24px;
  background: var(--bg-primary);
  border-radius: var(--radius-md);
  padding: 20px;
  display: none;
  border: 1px solid var(--border-color);
}

/* STATS BAR */
.stats-strip {
  background: var(--bg-secondary);
  border-top: 1px solid var(--border-color);
  border-bottom: 1px solid var(--border-color);
  padding: 40px 0;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  text-align: center;
}

.stat-item h4 {
  font-size: 2.2rem;
  font-weight: 800;
  color: var(--accent-emerald-light);
  margin-bottom: 4px;
}

.stat-item p {
  color: var(--text-muted);
  font-size: 0.88rem;
}

/* ARTICLE DETAIL / SINGLE PAGE */
.detail-hero {
  padding: 56px 0 36px;
  border-bottom: 1px solid var(--border-color);
  background: linear-gradient(180deg, rgba(16, 185, 129, 0.05) 0%, transparent 100%);
}

.breadcrumb {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.85rem;
  color: var(--text-subtle);
  margin-bottom: 16px;
}

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

.breadcrumb a:hover {
  color: var(--accent-emerald-light);
}

.detail-content {
  max-width: 840px;
  margin: 0 auto;
  padding: 48px 24px;
}

.detail-content h1 {
  font-size: 2.5rem;
  line-height: 1.25;
  margin-bottom: 18px;
  font-weight: 800;
}

.detail-content h2 {
  font-size: 1.8rem;
  margin: 40px 0 16px;
  color: #FFFFFF;
}

.detail-content h3 {
  font-size: 1.35rem;
  margin: 28px 0 12px;
  color: var(--accent-emerald-light);
}

.detail-content p {
  font-size: 1.05rem;
  line-height: 1.75;
  color: #D1D5DB;
  margin-bottom: 22px;
}

.detail-content ul,
.detail-content ol {
  margin-bottom: 24px;
  padding-left: 24px;
  color: #D1D5DB;
}

.detail-content li {
  margin-bottom: 10px;
  line-height: 1.65;
}

.callout-box {
  background: var(--bg-secondary);
  border-left: 4px solid var(--accent-emerald);
  padding: 22px 26px;
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
  margin: 32px 0;
}

.callout-box h4 {
  font-size: 1.1rem;
  color: #FFFFFF;
  margin-bottom: 8px;
}

.callout-box p {
  margin-bottom: 0;
  font-size: 0.95rem;
  color: var(--text-muted);
}

.spec-table-box {
  overflow-x: auto;
  margin: 32px 0;
}

.spec-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
}

.spec-table th,
.spec-table td {
  padding: 14px 18px;
  border-bottom: 1px solid var(--border-color);
  font-size: 0.92rem;
}

.spec-table th {
  background: var(--bg-secondary);
  color: var(--accent-emerald-light);
  font-weight: 600;
}

.spec-table tr:hover td {
  background: rgba(255, 255, 255, 0.02);
}

/* CONTACT PAGE */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 48px;
  padding: 48px 0;
}

.form-group {
  margin-bottom: 20px;
}

.form-group label {
  display: block;
  font-size: 0.88rem;
  font-weight: 600;
  margin-bottom: 8px;
  color: var(--text-main);
}

.form-input,
.form-textarea,
.form-select {
  width: 100%;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  color: #FFFFFF;
  padding: 12px 16px;
  border-radius: var(--radius-sm);
  font-size: 0.95rem;
  font-family: inherit;
}

.form-input:focus,
.form-textarea:focus,
.form-select:focus {
  outline: none;
  border-color: var(--accent-emerald);
}

.form-textarea {
  min-height: 140px;
  resize: vertical;
}

/* FOOTER (MANDATORY & UNIFIED ACROSS ALL PAGES) */
.site-footer {
  margin-top: auto;
  background: #090B0E;
  border-top: 1px solid var(--border-color);
  padding: 56px 0 32px;
  color: var(--text-muted);
}

.footer-top {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 40px;
  margin-bottom: 48px;
}

.footer-brand-title {
  color: #FFFFFF;
  font-size: 1.2rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 14px;
}

.footer-desc {
  font-size: 0.9rem;
  line-height: 1.6;
  max-width: 320px;
  margin-bottom: 16px;
}

.footer-address {
  font-style: normal;
  font-size: 0.85rem;
  color: var(--text-subtle);
  line-height: 1.5;
}

.footer-col-title {
  color: #FFFFFF;
  font-size: 0.95rem;
  font-weight: 600;
  margin-bottom: 16px;
}

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

.footer-links a {
  font-size: 0.88rem;
  color: var(--text-muted);
}

.footer-links a:hover {
  color: var(--accent-emerald-light);
}

.footer-bottom {
  border-top: 1px solid var(--border-light);
  padding-top: 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
  font-size: 0.82rem;
  color: var(--text-subtle);
}

/* COOKIE CONSENT BANNER */
.cookie-banner {
  position: fixed;
  bottom: 20px;
  left: 20px;
  right: 20px;
  max-width: 580px;
  margin: 0 auto;
  background: #151A22;
  border: 1px solid var(--border-color);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.6);
  border-radius: var(--radius-md);
  padding: 20px;
  z-index: 9999;
  display: none;
  flex-direction: column;
  gap: 16px;
}

.cookie-content {
  font-size: 0.88rem;
  color: var(--text-muted);
  line-height: 1.5;
}

.cookie-content a {
  color: var(--accent-emerald-light);
  text-decoration: underline;
}

.cookie-actions {
  display: flex;
  gap: 10px;
  justify-content: flex-end;
}

.btn-cookie-accept {
  background: var(--accent-emerald);
  color: #042417;
  font-size: 0.82rem;
  font-weight: 700;
  padding: 8px 16px;
  border-radius: var(--radius-sm);
  border: none;
  cursor: pointer;
}

.btn-cookie-prefs {
  background: transparent;
  color: var(--text-muted);
  border: 1px solid var(--border-color);
  font-size: 0.82rem;
  font-weight: 600;
  padding: 8px 14px;
  border-radius: var(--radius-sm);
  cursor: pointer;
}

.btn-cookie-accept:hover {
  background: var(--accent-emerald-light);
}

.btn-cookie-prefs:hover {
  color: #FFFFFF;
  border-color: var(--text-subtle);
}

/* RESPONSIVE DESIGN */
@media (max-width: 1024px) {
  .hero-grid {
    grid-template-columns: 1fr;
  }
  .grid-3 {
    grid-template-columns: repeat(2, 1fr);
  }
  .footer-top {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 768px) {
  .nav-menu,
  .nav-actions .btn-cta-slim {
    display: none;
  }
  .hamburger-btn {
    display: block;
  }
  .grid-3,
  .grid-2 {
    grid-template-columns: 1fr;
  }
  .contact-grid {
    grid-template-columns: 1fr;
  }
  .hero-title {
    font-size: 2.1rem;
  }
  .stats-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 28px;
  }
  .scanner-form {
    flex-direction: column;
  }
  .footer-top {
    grid-template-columns: 1fr;
  }
  .footer-bottom {
    flex-direction: column;
    text-align: center;
  }
}

@media (max-width: 480px) {
  .hero-title {
    font-size: 1.85rem;
  }
  .section-title {
    font-size: 1.7rem;
  }
  .cookie-actions {
    flex-direction: column;
  }
  .cookie-actions button {
    width: 100%;
  }
}