:root {
  /* Color Palette - Premium Financial */
  --bg-color: #F3F4F6;
  --card-bg: #FFFFFF;
  --text-primary: #111827;
  --text-secondary: #4B5563;
  --accent-color: #2563EB;
  --accent-hover: #1D4ED8;
  --success-color: #059669;
  --danger-color: #DC2626;
  --border-color: #E5E7EB;

  /* Typography */
  --font-serif: 'Playfair Display', serif;
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-mono: 'JetBrains Mono', 'Menlo', monospace;

  /* Spacing & Layout - Industry Standard */
  --container-max: 1240px;
  --header-height: 70px;
  --radius-sm: 6px;
  --radius-md: 8px;
  --shadow-sm: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

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

body {
  background-color: var(--bg-color);
  color: var(--text-primary);
  font-family: var(--font-sans);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  background-image: radial-gradient(#E5E7EB 1px, transparent 1px);
  background-size: 24px 24px;
  min-height: 100vh;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-sans);
  font-weight: 700;
  color: var(--text-primary);
  letter-spacing: -0.025em;
}

h1 {
  font-family: var(--font-serif);
}

a {
  color: var(--accent-color);
  text-decoration: none;
  font-weight: 500;
  transition: all 0.15s ease;
}

a:hover {
  text-decoration: underline;
  color: var(--accent-hover);
}

/* Layout Container - Centered & Constrained */
.container {
  width: 90%;
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* Navbar */
.navbar {
  position: sticky;
  top: 0;
  z-index: 50;
  background-color: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-color);
  height: var(--header-height);
  display: flex;
  align-items: center;
  box-shadow: var(--shadow-sm);
}

.navbar-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
}

.brand {
  font-family: var(--font-sans);
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--text-primary);
  letter-spacing: -0.05em;
  text-transform: uppercase;
  color: #000;
  text-decoration: none !important;
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.brand img {
  height: 36px;
  width: auto;
  display: block;
}

.brand span {
  color: var(--accent-color);
}

/* Hero Section */
.hero {
  padding: 5rem 0 3rem;
  max-width: 800px;
}

.hero-date {
  font-family: var(--font-mono);
  font-size: 0.875rem;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 0.75rem;
  display: block;
  border-left: 2px solid var(--accent-color);
  padding-left: 0.75rem;
}

.hero-title {
  font-size: 3rem;
  line-height: 1.1;
  margin-bottom: 1.5rem;
  color: #111;
}

.hero-excerpt {
  font-size: 1.125rem;
  color: var(--text-secondary);
  line-height: 1.6;
  max-width: 65ch;
}

/* Grid Label */
.grid-label {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-secondary);
  border-bottom: 2px solid var(--text-primary);
  margin: 4rem 0 2rem;
  padding-bottom: 0.5rem;
  display: inline-block;
  font-weight: 600;
}

/* Posts Grid - Mobile First CSS Grid */
.posts-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
  margin-bottom: 4rem;
}

/* Tablet: 2 Columns */
@media (min-width: 500px) {
  .posts-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
  }
}

/* Desktop: 3 Columns */
@media (min-width: 850px) {
  .posts-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
  }
}

/* Large Desktop: Maintain 3 Columns, Centered */
@media (min-width: 1200px) {
  .posts-grid {
    gap: 2.5rem;
  }
}

/* Post Card */
.post-card {
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 1.5rem;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  display: flex;
  flex-direction: column;
  height: 100%;
  box-shadow: var(--shadow-sm);
}

@media (min-width: 500px) {
  .post-card {
    padding: 1.75rem;
  }
}

@media (min-width: 850px) {
  .post-card {
    padding: 2rem;
  }
}

.post-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: var(--accent-color);
}

.post-meta {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-secondary);
  margin-bottom: 0.75rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.post-meta::before {
  content: '📅';
  font-size: 0.9rem;
}

.post-title {
  font-size: 1.125rem;
  margin-bottom: 0.75rem;
  line-height: 1.4;
  font-weight: 600;
}

@media (min-width: 500px) {
  .post-title {
    font-size: 1.25rem;
  }
}

.post-title a {
  color: var(--text-primary);
  text-decoration: none;
}

.post-title a:hover {
  color: var(--accent-color);
}

.post-excerpt {
  flex-grow: 1;
  font-size: 0.9375rem;
  color: var(--text-secondary);
  margin-bottom: 1.25rem;
  line-height: 1.6;
  display: -webkit-box;
  -webkit-line-clamp: 4;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

@media (min-width: 850px) {
  .post-excerpt {
    font-size: 1rem;
    -webkit-line-clamp: 5;
  }
}

.tags {
  margin-bottom: 1rem !important;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.tag {
  display: inline-block;
  background: linear-gradient(135deg, #F3F4F6 0%, #E5E7EB 100%);
  padding: 0.25rem 0.75rem;
  border-radius: 50px;
  font-size: 0.75rem;
  font-family: var(--font-mono);
  color: var(--text-secondary);
  border: 1px solid #D1D5DB;
  transition: all 0.2s ease;
}

.tag:hover {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  border-color: transparent;
  transform: translateY(-1px);
}

.read-more-btn {
  font-size: 0.875rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--accent-color);
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  transition: all 0.2s ease;
  padding: 0.625rem 1rem;
  border-radius: var(--radius-sm);
  background: rgba(37, 99, 235, 0.08);
  align-self: flex-start;
}

.read-more-btn:hover {
  background: rgba(37, 99, 235, 0.15);
  gap: 0.75rem;
  text-decoration: none;
}

.read-more-btn::after {
  content: '→';
  font-weight: 700;
  transition: transform 0.2s ease;
}

.read-more-btn:hover::after {
  transform: translateX(4px);
}

/* Article Page */
article {
  max-width: 720px;
  margin: 3rem auto;
  background: white;
  padding: 2rem;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
}

@media (min-width: 768px) {
  article {
    padding: 3rem;
    margin: 4rem auto;
  }
}

.article-header {
  margin-bottom: 2rem;
  padding-bottom: 2rem;
  border-bottom: 1px solid var(--border-color);
}

.article-title {
  font-size: 2rem;
  margin-bottom: 1rem;
}

@media (min-width: 768px) {
  .article-title {
    font-size: 2.5rem;
  }
}

.article-meta {
  font-family: var(--font-mono);
  color: var(--text-secondary);
  font-size: 0.875rem;
}

/* Prose Content */
.prose {
  font-size: 1rem;
  color: #374151;
  line-height: 1.8;
}

@media (min-width: 768px) {
  .prose {
    font-size: 1.125rem;
  }
}

.prose p {
  margin-bottom: 1.5rem;
}

.prose h2 {
  font-size: 1.5rem;
  margin-top: 2.5rem;
  margin-bottom: 1rem;
  color: #111;
  border-left: 4px solid var(--accent-color);
  padding-left: 1rem;
}

.prose h3 {
  font-size: 1.25rem;
  margin-top: 2rem;
  margin-bottom: 1rem;
}

.prose ul,
.prose ol {
  margin-bottom: 1.5rem;
  padding-left: 1.5rem;
}

.prose li {
  margin-bottom: 0.5rem;
}

/* Key Takeaways Card */
.key-takeaways {
  background: #F0FDF4 !important;
  border-left: 4px solid var(--success-color) !important;
  border-radius: var(--radius-sm);
  padding: 1.5rem;
  margin: 2rem 0;
}

.key-takeaways h2 {
  font-size: 1.1rem !important;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--success-color) !important;
  margin: 0 0 1rem 0 !important;
  border: none !important;
  padding: 0 !important;
}

.key-takeaways li {
  font-size: 1rem;
  color: #064E3B;
}

/* Blockquotes */
blockquote {
  margin: 2.5rem 0;
  padding: 1.5rem 2rem;
  background: #EFF6FF;
  border-left: 4px solid var(--accent-color);
  font-style: italic;
  font-size: 1.125rem;
  color: #1E3A8A;
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
}

/* Hype Components */
.flash-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  padding: 0.25rem 0.5rem;
  border-radius: 4px;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-right: 0.5rem;
}

.flash-tag.bull {
  background: #DCFCE7;
  color: #166534;
  border: 1px solid #86EFAC;
}

.flash-tag.bear {
  background: #FEE2E2;
  color: #991B1B;
  border: 1px solid #FECACA;
}

.flash-tag.alpha {
  background: #FEF3C7;
  color: #92400E;
  border: 1px solid #FCD34D;
}

.alpha-box {
  background: #FFFBEB;
  border: 1px solid #FCD34D;
  border-left: 4px solid #D97706;
  padding: 1.5rem;
  margin: 2rem 0;
  border-radius: 4px;
}

.alpha-box h3 {
  color: #92400E;
  margin-top: 0;
  font-size: 1.1rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.market-stat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 1rem;
  margin: 2rem 0;
}

.stat-card {
  background: #F8FAFC;
  border: 1px solid #E2E8F0;
  padding: 1rem;
  border-radius: 4px;
  text-align: center;
}

.stat-label {
  font-size: 0.75rem;
  color: #64748B;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 0.25rem;
}

.stat-value {
  font-size: 1.25rem;
  font-weight: 700;
  color: #0F172A;
  font-family: var(--font-mono);
}

.stat-value.up {
  color: #16A34A;
}

.stat-value.down {
  color: #DC2626;
}

/* Tables */
.table-container {
  overflow-x: auto;
  margin: 2.5rem 0;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
}

table {
  width: 100%;
  border-collapse: collapse;
  font-family: var(--font-mono);
  font-size: 0.9rem;
}

th {
  text-align: left;
  padding: 1rem;
  background-color: #F8FAFC;
  border-bottom: 2px solid var(--border-color);
  color: var(--text-secondary);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-size: 0.75rem;
}

td {
  padding: 1rem;
  border-bottom: 1px solid var(--border-color);
  color: var(--text-primary);
}

tr:last-child td {
  border-bottom: none;
}

tr:nth-child(even) {
  background-color: #FAFAFA;
}

/* Footer */
.site-footer {
  margin-top: 4rem;
}

.partner-section {
  background: linear-gradient(135deg, #111827 0%, #1F2937 100%);
  border-radius: var(--radius-md);
  padding: 2rem;
  margin-bottom: 2rem;
  border: 1px solid #374151;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
}

.partner-header {
  text-align: center;
  margin-bottom: 2rem;
}

.partner-icon {
  font-size: 2.5rem;
  display: block;
  margin-bottom: 1rem;
}

.partner-header h3 {
  color: #F9FAFB;
  font-size: 1.5rem;
  margin-bottom: 0.5rem;
  font-weight: 700;
}

.partner-subtitle {
  color: #9CA3AF;
  font-size: 0.9375rem;
  max-width: 500px;
  margin: 0 auto;
}

.partner-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

@media (min-width: 500px) {
  .partner-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 850px) {
  .partner-grid {
    grid-template-columns: repeat(4, 1fr);
    gap: 1.5rem;
  }
}

.partner-card {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid #374151;
  border-radius: var(--radius-sm);
  padding: 1.25rem;
  transition: all 0.3s ease;
  display: flex;
  flex-direction: column;
}

@media (min-width: 850px) {
  .partner-card {
    padding: 1.5rem;
  }
}

.partner-card:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: #4B5563;
  transform: translateY(-2px);
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.3);
}

.partner-card-header {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 0.75rem;
}

.card-icon {
  font-size: 1.5rem;
  flex-shrink: 0;
}

.partner-card-header h4 {
  color: #F3F4F6;
  font-size: 1rem;
  font-weight: 600;
  margin: 0;
}

.card-desc {
  color: #D1D5DB;
  font-size: 0.875rem;
  line-height: 1.5;
  margin-bottom: 1rem;
  flex-grow: 1;
}

.card-desc strong {
  color: #FCD34D;
  font-weight: 600;
}

.partner-btn {
  display: inline-block;
  background: linear-gradient(135deg, #3B82F6 0%, #2563EB 100%);
  color: #FFFFFF !important;
  padding: 0.625rem 1rem;
  border-radius: var(--radius-sm);
  font-size: 0.875rem;
  font-weight: 600;
  text-align: center;
  text-decoration: none !important;
  transition: all 0.2s ease;
  border: none;
  cursor: pointer;
}

.partner-btn:hover {
  background: linear-gradient(135deg, #2563EB 0%, #1D4ED8 100%);
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.4);
  transform: translateY(-1px);
}

.affiliate-disclaimer {
  text-align: center;
  padding-top: 1.25rem;
  border-top: 1px solid #374151;
  color: #6B7280;
  font-size: 0.8125rem;
}

/* Footer Bottom */
.footer-bottom {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  padding: 2rem 0;
  border-top: 2px solid #E5E7EB;
  text-align: center;
}

@media (min-width: 768px) {
  .footer-bottom {
    flex-direction: row;
    justify-content: space-between;
    text-align: left;
  }
}

.footer-brand {
  text-align: center;
}

@media (min-width: 768px) {
  .footer-brand {
    text-align: left;
  }
}

.brand-mark {
  font-family: var(--font-sans);
  font-size: 1.125rem;
  font-weight: 800;
  color: #111827;
  letter-spacing: -0.05em;
  text-transform: uppercase;
}

.brand-mark span {
  color: var(--accent-color);
}

.tagline {
  color: var(--text-secondary);
  font-size: 0.8125rem;
  margin-top: 0.25rem;
}

.footer-links {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.75rem;
  font-size: 0.8125rem;
  color: var(--text-secondary);
}

.footer-links a {
  color: var(--accent-color);
  text-decoration: none;
}

.footer-links a:hover {
  text-decoration: underline;
}

.divider {
  color: #D1D5DB;
  margin: 0 0.25rem;
}

.copyright {
  color: var(--text-secondary);
  font-weight: 500;
}

/* Stats Section */
.stats-section {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  border-radius: 12px;
  padding: 2rem;
  margin: 3rem 0;
  color: white;
  box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
}

.stats-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
  margin-top: 1rem;
}

@media (min-width: 500px) {
  .stats-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.stat-card {
  background: rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(10px);
  border-radius: 8px;
  padding: 1.25rem;
  text-align: center;
  transition: transform 0.2s;
}

.stat-card:hover {
  transform: translateY(-2px);
}

.stat-value {
  font-size: 1.75rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
}

.stat-label {
  font-size: 0.8125rem;
  opacity: 0.9;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.popular-posts {
  margin-top: 1.5rem;
  padding-top: 1rem;
  border-top: 1px solid rgba(255, 255, 255, 0.2);
}

.popular-posts h3 {
  font-size: 0.9375rem;
  margin-bottom: 0.75rem;
  opacity: 0.9;
}

.popular-posts ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.popular-posts li {
  padding: 0.5rem 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.popular-posts li:last-child {
  border-bottom: none;
}

.popular-posts a {
  color: white;
  text-decoration: none;
  font-size: 0.875rem;
  transition: opacity 0.2s;
}

.popular-posts a:hover {
  opacity: 0.8;
  text-decoration: underline;
}

.stat-emoji {
  font-size: 1.5rem;
  margin-bottom: 0.5rem;
  display: block;
}

/* Table Styling */
.prose table { width: 100%; border-collapse: collapse; margin: 2rem 0; font-size: 0.9rem; background: #fff; border-radius: 8px; overflow: hidden; box-shadow: 0 1px 3px rgba(0,0,0,0.1); }
.prose th { background-color: #F9FAFB; color: #4B5563; font-weight: 600; text-align: left; padding: 12px 15px; border-bottom: 2px solid #E5E7EB; text-transform: uppercase; letter-spacing: 0.05em; }
.prose td { padding: 12px 15px; border-bottom: 1px solid #E5E7EB; color: #111827; }
.prose tr:hover td { background-color: #F3F4F6; }

/* Footer */
.site-footer { background-color: #111827; color: #9CA3AF; padding: 4rem 0 2rem; margin-top: 6rem; }
.footer-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 3rem; margin-bottom: 3rem; }
.footer-heading { color: white; font-size: 0.875rem; text-transform: uppercase; letter-spacing: 0.1em; margin-bottom: 1.25rem; font-weight: 700; }
.footer-links { list-style: none; }
.footer-links li { margin-bottom: 0.75rem; }
.footer-links a { color: #9CA3AF; font-weight: 400; }
.footer-links a:hover { color: white; }
.footer-bottom { border-top: 1px solid #374151; padding-top: 2rem; display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 1rem; font-size: 0.875rem; }

/* --- Sovereign Refinement v9.1 --- */
.prose { max-width: 800px; margin: 0 auto; font-size: 1.15rem; line-height: 1.8; color: #1f2937; }
.prose h3 { font-size: 1.75rem; margin-top: 3rem; color: #111827; border-left: 4px solid #2563EB; padding-left: 1rem; }
.flash-tag { display: inline-block; padding: 0.25rem 0.75rem; border-radius: 4px; font-weight: 700; font-size: 0.75rem; text-transform: uppercase; margin-right: 0.5rem; }
.flash-tag.alpha { background: #111827; color: white; }
.flash-tag.bull { background: #059669; color: white; }
.affiliate-disclaimer { margin-top: 4rem; padding: 1.5rem; background: #f9fafb; border-radius: 8px; font-size: 0.9rem; color: #6b7280; border: 1px solid #e5e7eb; }

/* Institutional Compatibility Layer - v9.1 */
/* This ensures legacy Tailwind tables and un-wrapped content still look premium */
table { width: 100%; border-collapse: collapse; margin: 2rem 0; font-family: "JetBrains Mono", monospace; }
th, td { padding: 12px 15px; border-bottom: 1px solid #E5E7EB; text-align: left; }
th { background-color: #F9FAFB; font-weight: 700; text-transform: uppercase; color: #4B5563; font-size: 0.75rem; }
.px-6 { padding-left: 1.5rem; padding-right: 1.5rem; }
.py-4 { padding-top: 1rem; padding-bottom: 1rem; }
.font-bold { font-weight: 700; }
article { max-width: 900px; margin: 0 auto; padding: 2rem; background: white; border-radius: 12px; box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1); }

/* Grid Integrity Fix - v9.1 */
/* Ensures all cards stay aligned regardless of title length */
.post-grid, .posts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 2rem;
    align-items: stretch;
}
.post-card {
    display: flex;
    flex-direction: column;
    height: 100%;
    background: white;
    border-radius: 12px;
    padding: 1.5rem;
    border: 1px solid #E5E7EB;
    transition: transform 0.2s, box-shadow 0.2s;
}
.post-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
}
.post-title {
    font-size: 1.25rem;
    line-height: 1.4;
    margin: 0.75rem 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    min-height: 3.5rem;
}
.post-excerpt {
    font-size: 0.95rem;
    color: #4B5563;
    flex-grow: 1;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin-bottom: 1.5rem;
}
strong { display: inline; }
