/* StreamX Ultra Modern High-Converting Dark Theme (Pixel-Perfect) */
:root {
  --bg-primary: #0b0f19;
  --bg-secondary: #111827;
  --bg-card: #1f293d;
  --bg-card-hover: #28354f;
  --text-primary: #f9fafb;
  --text-secondary: #9ca3af;
  --text-muted: #6b7280;
  --accent-primary: #6366f1;
  --accent-secondary: #06b6d4;
  --accent-gradient: linear-gradient(135deg, #6366f1 0%, #a855f7 50%, #06b6d4 100%);
  --accent-hover: #4f46e5;
  --border-color: #374151;
  --border-light: rgba(255, 255, 255, 0.08);
  --success: #10b981;
  --warning: #f59e0b;
  --danger: #ef4444;
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.5);
  --font-main: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
}

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

body {
  background-color: var(--bg-primary);
  color: var(--text-primary);
  font-family: var(--font-main);
  line-height: 1.75;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

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

a:hover {
  color: #38bdf8;
  text-decoration: underline;
}

/* Header & Nav */
header.site-header {
  background-color: rgba(11, 15, 25, 0.92);
  backdrop-filter: blur(14px);
  position: sticky;
  top: 0;
  z-index: 100;
  border-bottom: 1px solid var(--border-light);
}

.header-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 1rem 1.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 1.45rem;
  font-weight: 800;
  color: #fff;
  letter-spacing: -0.5px;
  text-decoration: none !important;
}

.logo-icon {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: var(--accent-gradient);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-weight: 900;
  font-size: 1.1rem;
  box-shadow: 0 0 15px rgba(99, 102, 241, 0.4);
}

.logo span {
  background: var(--accent-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

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

.main-nav a {
  color: var(--text-secondary);
  font-weight: 600;
  font-size: 0.95rem;
}

.main-nav a:hover {
  color: #fff;
  text-decoration: none;
}

.btn-trial, .btn-cta {
  background: var(--accent-gradient);
  color: #fff !important;
  font-weight: 700;
  padding: 0.55rem 1.25rem;
  border-radius: 9999px;
  box-shadow: 0 4px 15px rgba(99, 102, 241, 0.35);
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: transform 0.2s, box-shadow 0.2s;
  text-decoration: none !important;
}

.btn-trial:hover, .btn-cta:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(99, 102, 241, 0.5);
}

/* ===================================================
   SINGLE ARTICLE LAYOUT (Balanced & Centered 860px)
   =================================================== */
.article-container,
main.article-container,
.container.article-wrapper,
.article-wrapper {
  max-width: 860px;
  margin: 0 auto;
  padding: 2.5rem 1.5rem 5rem;
  width: 100%;
}

/* Breadcrumbs */
.breadcrumb {
  display: flex;
  gap: 0.5rem;
  font-size: 0.88rem;
  color: var(--text-muted);
  margin-bottom: 1.5rem;
  align-items: center;
  flex-wrap: wrap;
}

.breadcrumb a {
  color: var(--text-secondary);
  text-decoration: none;
}

.breadcrumb a:hover {
  color: #fff;
}

/* Article Header */
.article-header {
  padding-bottom: 2rem;
  margin-bottom: 2.5rem;
  border-bottom: 1px solid var(--border-light);
}

.article-title,
.article-header h1 {
  font-size: 2.45rem;
  font-weight: 800;
  line-height: 1.25;
  margin-bottom: 1.25rem;
  letter-spacing: -0.5px;
  color: #ffffff;
}

.article-meta-bar {
  display: flex;
  gap: 1.5rem;
  font-size: 0.92rem;
  color: var(--text-secondary);
  align-items: center;
  flex-wrap: wrap;
}

.author-info {
  display: flex;
  align-items: center;
  gap: 10px;
}

.author-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--accent-gradient);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  color: #fff;
  font-size: 0.9rem;
}

/* Featured / Quick Answer Box */
.quick-answer-box {
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.15) 0%, rgba(6, 182, 212, 0.08) 100%);
  border: 1px solid rgba(99, 102, 241, 0.35);
  border-left: 5px solid var(--accent-primary);
  border-radius: var(--radius-md);
  padding: 1.5rem 1.75rem;
  margin: 2rem 0 2.5rem;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.25);
}

.quick-answer-header {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 800;
  font-size: 1.05rem;
  color: #a5b4fc;
  margin-bottom: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.quick-answer-box p {
  color: #f3f4f6;
  font-size: 1.05rem;
  line-height: 1.7;
  margin: 0;
}

/* Table of Contents */
.toc-box {
  background: var(--bg-secondary);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 1.5rem 2rem;
  margin: 2rem 0 3rem;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}

.toc-title {
  font-weight: 800;
  font-size: 1.15rem;
  color: #fff;
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
  gap: 8px;
}

.toc-list {
  list-style: none;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.6rem 1.5rem;
  margin: 0;
  padding: 0;
}

@media (max-width: 700px) {
  .toc-list {
    grid-template-columns: 1fr;
  }
}

.toc-list a {
  color: var(--text-secondary);
  font-size: 0.95rem;
  display: flex;
  align-items: center;
  gap: 6px;
  transition: color 0.2s;
}

.toc-list a:hover {
  color: #38bdf8;
  text-decoration: none;
}

/* Article Body Content */
.article-content {
  font-size: 1.125rem;
  line-height: 1.85;
  color: #e5e7eb;
}

.article-content h2 {
  font-size: 1.95rem;
  font-weight: 800;
  color: #fff;
  margin: 3rem 0 1.25rem;
  padding-bottom: 0.6rem;
  border-bottom: 1px solid var(--border-light);
  letter-spacing: -0.5px;
}

.article-content h3 {
  font-size: 1.45rem;
  font-weight: 700;
  color: #f3f4f6;
  margin: 2.25rem 0 1rem;
}

.article-content h4 {
  font-size: 1.2rem;
  font-weight: 700;
  color: #e5e7eb;
  margin: 1.5rem 0 0.75rem;
}

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

.article-content ul, .article-content ol {
  margin: 1.5rem 0 1.5rem 2rem;
}

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

.article-content strong {
  color: #fff;
}

/* Step Cards */
.step-card {
  background: var(--bg-secondary);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 1.75rem;
  margin: 1.75rem 0;
  position: relative;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}

.step-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--accent-gradient);
  color: #fff;
  font-weight: 800;
  font-size: 0.95rem;
  padding: 0.25rem 0.85rem;
  border-radius: 9999px;
  margin-bottom: 1rem;
}

.step-title {
  font-size: 1.3rem;
  font-weight: 700;
  color: #fff;
  margin-bottom: 0.75rem;
}

.code-block {
  background: #070a11;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  padding: 1rem 1.25rem;
  font-family: 'Courier New', Courier, monospace;
  font-size: 0.95rem;
  color: #38bdf8;
  margin: 1rem 0;
  overflow-x: auto;
}

.callout-box {
  background: var(--bg-card);
  border-left: 4px solid var(--accent-primary);
  padding: 1.5rem 1.75rem;
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  margin: 2rem 0;
}

.callout-box.tip {
  border-left-color: var(--success);
  background: rgba(16, 185, 129, 0.09);
}

.callout-box.warning {
  border-left-color: var(--warning);
  background: rgba(245, 158, 11, 0.09);
}

.callout-title {
  font-weight: 800;
  color: #fff;
  margin-bottom: 0.5rem;
}

/* Comparison Tables */
.table-wrapper {
  overflow-x: auto;
  margin: 2.5rem 0;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-light);
}

table.comparison-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
  background-color: var(--bg-secondary);
}

table.comparison-table th, table.comparison-table td {
  padding: 1.1rem 1.25rem;
  border-bottom: 1px solid var(--border-light);
}

table.comparison-table th {
  background-color: var(--bg-card);
  color: #fff;
  font-weight: 700;
  font-size: 0.95rem;
}

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

/* Call to Action Box */
.cta-box {
  background: radial-gradient(circle at 50% 0%, rgba(99, 102, 241, 0.25), transparent 75%), var(--bg-secondary);
  border: 1px solid rgba(99, 102, 241, 0.4);
  border-radius: var(--radius-lg);
  padding: 3rem 2rem;
  text-align: center;
  margin: 3.5rem 0;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
}

.cta-box h3 {
  font-size: 1.95rem;
  color: #fff;
  margin-bottom: 0.85rem;
  font-weight: 800;
}

.cta-box p {
  color: var(--text-secondary);
  max-width: 600px;
  margin: 0 auto 1.75rem;
  font-size: 1.1rem;
}

/* FAQ Accordion */
.faq-section {
  margin: 3.5rem 0 2rem;
}

.faq-section h2 {
  font-size: 1.95rem;
  font-weight: 800;
  color: #fff;
  margin-bottom: 1.75rem;
  padding-bottom: 0.6rem;
  border-bottom: 1px solid var(--border-light);
}

.faq-item {
  background-color: var(--bg-secondary);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  margin-bottom: 1.25rem;
  padding: 1.5rem 1.75rem;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.15);
}

.faq-question, .faq-item h3 {
  font-size: 1.2rem;
  color: #fff;
  margin-bottom: 0.65rem;
  font-weight: 700;
}

.faq-answer, .faq-item p {
  color: var(--text-secondary);
  margin-bottom: 0;
  line-height: 1.7;
}

/* Related Guides Grid */
.related-section {
  margin-top: 4rem;
  padding-top: 2.5rem;
  border-top: 1px solid var(--border-light);
}

.related-section h3 {
  font-size: 1.5rem;
  font-weight: 800;
  color: #fff;
  margin-bottom: 1.5rem;
}

.related-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 1.25rem;
}

.related-card {
  background: var(--bg-secondary);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-sm);
  padding: 1.25rem;
  text-decoration: none !important;
  transition: all 0.2s ease;
}

.related-card:hover {
  transform: translateY(-3px);
  border-color: rgba(99, 102, 241, 0.5);
  box-shadow: var(--shadow);
}

.related-card h4 {
  color: #fff;
  font-size: 1.05rem;
  margin-bottom: 0.5rem;
}

.related-card p {
  color: var(--text-muted);
  font-size: 0.85rem;
  line-height: 1.5;
  margin: 0;
}

/* ===================================================
   HOMEPAGE GRID & HERO
   =================================================== */
.hero {
  padding: 4.5rem 1.5rem 3rem;
  text-align: center;
  max-width: 900px;
  margin: 0 auto;
}

.hero-badge {
  display: inline-block;
  background: rgba(99, 102, 241, 0.15);
  border: 1px solid rgba(99, 102, 241, 0.3);
  color: #818cf8;
  padding: 0.35rem 0.85rem;
  border-radius: 9999px;
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: 1.25rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.hero h1 {
  font-size: 2.75rem;
  font-weight: 800;
  line-height: 1.2;
  margin-bottom: 1.25rem;
  color: #ffffff;
}

.hero h1 span {
  background: var(--accent-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero p {
  color: var(--text-secondary);
  font-size: 1.15rem;
  line-height: 1.6;
  max-width: 700px;
  margin: 0 auto 2rem;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

.articles-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
  gap: 2rem;
  margin: 2.5rem 0 4rem;
}

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

.article-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow);
  border-color: rgba(99, 102, 241, 0.4);
}

.card-img-wrapper {
  position: relative;
  height: 180px;
  background: linear-gradient(135deg, #1e1e38, #2a2a50);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.card-badge {
  position: absolute;
  top: 1rem;
  left: 1rem;
  background: rgba(11, 15, 25, 0.85);
  backdrop-filter: blur(8px);
  color: #38bdf8;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 0.25rem 0.65rem;
  border-radius: 4px;
  text-transform: uppercase;
}

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

.card-meta {
  display: flex;
  gap: 1rem;
  color: var(--text-muted);
  font-size: 0.85rem;
  margin-bottom: 0.75rem;
}

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

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

.card-title a:hover {
  color: #818cf8;
}

.card-excerpt {
  color: var(--text-secondary);
  font-size: 0.95rem;
  line-height: 1.5;
  margin-bottom: 1.25rem;
  flex-grow: 1;
}

.card-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 1rem;
  border-top: 1px solid var(--border-light);
  font-size: 0.9rem;
}

.read-more {
  color: var(--accent-secondary);
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 4px;
}

/* Footer */
footer.site-footer {
  background-color: var(--bg-secondary);
  border-top: 1px solid var(--border-light);
  padding: 3.5rem 1.5rem 2rem;
  color: var(--text-muted);
  font-size: 0.9rem;
  margin-top: auto;
}

.footer-container {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 2.5rem;
  margin-bottom: 2.5rem;
}

.footer-col h4, .footer-col h5 {
  color: #fff;
  font-size: 1rem;
  margin-bottom: 1.25rem;
}

.footer-col ul {
  list-style: none;
}

.footer-col ul li {
  margin-bottom: 0.6rem;
}

.footer-col ul a {
  color: var(--text-secondary);
}

.footer-col ul a:hover {
  color: #fff;
}

.footer-bottom {
  max-width: 1200px;
  margin: 0 auto;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border-light);
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.85rem;
}

/* Responsive */
@media (max-width: 768px) {
  .hero h1 { font-size: 2rem; }
  .article-title { font-size: 1.85rem; }
  .footer-container { grid-template-columns: 1fr; }
  .main-nav { display: none; }
  .footer-bottom { flex-direction: column; gap: 1rem; text-align: center; }
}
