/* ==========================================================================
   The BTC Breakdown — Production stylesheet v2
   Designed for: long-form readability + fast LCP + mobile-first
   Now with: cover images, featured story, more-articles grid
   ========================================================================== */

:root {
  /* Color system — dark theme, calibrated for long reading */
  --bg: #0d0e15;
  --bg-elevated: #161823;
  --bg-card: #1c1f2e;
  --border: #2a2d40;
  --border-soft: #20232f;

  --text: #ebecf2;
  --text-strong: #ffffff;
  --text-muted: #9498a8;
  --text-quiet: #6b6f80;

  --accent: #f7931a;
  --accent-bright: #ffa733;
  --link: #6fb8ff;
  --link-hover: #ffa733;

  --serif: 'Charter', 'Iowan Old Style', 'Georgia', serif;
  --sans: -apple-system, BlinkMacSystemFont, 'Inter', 'SF Pro Text', 'Segoe UI', system-ui, sans-serif;
  --display: -apple-system, BlinkMacSystemFont, 'Inter', 'SF Pro Display', sans-serif;

  --max-narrow: 720px;
  --max-wide: 1080px;
  --max-extra-wide: 1200px;

  --transition: 0.2s ease;
}

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

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

main { flex: 1; }

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

a {
  color: var(--link);
  text-decoration: none;
  transition: color var(--transition);
}
a:hover { color: var(--link-hover); }

/* ==========================================================================
   Containers
   ========================================================================== */

.container {
  max-width: var(--max-narrow);
  margin: 0 auto;
  padding: 0 1.25rem;
}
@media (min-width: 768px) {
  .container { padding: 0 1.5rem; }
}

/* ==========================================================================
   Header
   ========================================================================== */

.site-header {
  background: rgba(13, 14, 21, 0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-soft);
  position: sticky;
  top: 0;
  z-index: 100;
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  padding-top: 1rem;
  padding-bottom: 1rem;
  max-width: var(--max-extra-wide);
}
.site-logo {
  font-family: var(--display);
  font-weight: 800;
  font-size: 1.15rem;
  letter-spacing: -0.02em;
  color: var(--text-strong);
}
.site-logo .accent { color: var(--accent); }
.site-nav {
  display: flex;
  gap: 1.5rem;
  font-size: 0.95rem;
}
.site-nav a {
  color: var(--text-muted);
  font-weight: 500;
}
.site-nav a:hover { color: var(--accent); }

/* ==========================================================================
   Homepage hero
   ========================================================================== */

.hero {
  padding: 5rem 0 4rem;
  border-bottom: 1px solid var(--border-soft);
  background: linear-gradient(180deg, rgba(247, 147, 26, 0.04) 0%, transparent 100%);
}
.hero .container {
  max-width: var(--max-extra-wide);
  text-align: center;
}
.hero-eyebrow {
  font-family: var(--display);
  color: var(--accent);
  font-weight: 600;
  font-size: 0.85rem;
  letter-spacing: 0.15em;
  margin-bottom: 1.25rem;
}
.hero-title {
  font-family: var(--display);
  font-size: clamp(2.5rem, 7vw, 4.5rem);
  font-weight: 800;
  letter-spacing: -0.04em;
  line-height: 1.0;
  color: var(--text-strong);
  margin-bottom: 1.25rem;
}
.hero-tagline {
  font-size: clamp(1.05rem, 2vw, 1.2rem);
  color: var(--text-muted);
  max-width: 540px;
  margin: 0 auto 2rem;
  line-height: 1.5;
}
.hero-cta {
  display: inline-block;
  background: var(--accent);
  color: #1a1100;
  padding: 0.95rem 1.75rem;
  border-radius: 6px;
  font-weight: 700;
  font-size: 0.95rem;
  letter-spacing: 0.01em;
  transition: transform var(--transition), background var(--transition);
}
.hero-cta:hover {
  background: var(--accent-bright);
  transform: translateY(-1px);
}

/* ==========================================================================
   Article list section (homepage)
   ========================================================================== */

.article-list-section {
  padding: 4rem 0 5rem;
}
.article-list-section .container {
  max-width: var(--max-extra-wide);
}

/* Featured (first) article — big card with side-by-side image + body on desktop */
.featured-card {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0;
  background: var(--bg-card);
  border: 1px solid var(--border-soft);
  border-radius: 12px;
  overflow: hidden;
  text-decoration: none;
  color: var(--text);
  transition: border-color var(--transition), transform var(--transition);
  margin-bottom: 4rem;
}
.featured-card:hover {
  border-color: var(--accent);
  transform: translateY(-2px);
  color: var(--text);
}
.featured-image {
  background: #000;
  overflow: hidden;
  aspect-ratio: 16 / 9;
}
.featured-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}
.featured-card:hover .featured-image img { transform: scale(1.03); }
.featured-body {
  padding: 2rem 1.75rem 2rem;
}
.featured-body h2 {
  font-family: var(--display);
  font-size: clamp(1.5rem, 3.5vw, 2.1rem);
  line-height: 1.15;
  font-weight: 800;
  letter-spacing: -0.025em;
  color: var(--text-strong);
  margin-bottom: 0.75rem;
}
.featured-body .card-meta { color: var(--accent); }

@media (min-width: 800px) {
  .featured-card {
    grid-template-columns: 1.25fr 1fr;
  }
  .featured-image { aspect-ratio: auto; height: 100%; }
  .featured-body { padding: 2.5rem 2.5rem 2.5rem; align-self: center; }
}

.section-title {
  font-family: var(--display);
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-muted);
  letter-spacing: 0.15em;
  text-transform: uppercase;
  margin-bottom: 2rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--border-soft);
}

.article-list {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
}
@media (min-width: 720px) {
  .article-list {
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
  }
}
@media (min-width: 1024px) {
  .article-list {
    grid-template-columns: 1fr 1fr 1fr;
  }
}

.article-card {
  display: flex;
  flex-direction: column;
  background: var(--bg-card);
  border: 1px solid var(--border-soft);
  border-radius: 12px;
  text-decoration: none;
  color: var(--text);
  overflow: hidden;
  transition: border-color var(--transition), transform var(--transition);
}
.article-card:hover {
  border-color: var(--accent);
  transform: translateY(-2px);
  color: var(--text);
}
.card-image {
  aspect-ratio: 16 / 9;
  background: #000;
  overflow: hidden;
}
.card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}
.article-card:hover .card-image img { transform: scale(1.04); }
.card-img-placeholder {
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, #1c1f2e 0%, #2a2d40 100%);
}
.card-body {
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  flex: 1;
}
.card-meta {
  font-size: 0.75rem;
  color: var(--text-quiet);
  font-family: var(--display);
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  margin-bottom: 0.75rem;
}
.article-card h2 {
  font-family: var(--display);
  font-size: 1.25rem;
  line-height: 1.25;
  font-weight: 700;
  letter-spacing: -0.015em;
  color: var(--text-strong);
  margin-bottom: 0.75rem;
  flex: 1;
}
.card-excerpt {
  font-size: 0.9rem;
  line-height: 1.55;
  color: var(--text-muted);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.read-more {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--accent);
  margin-top: 1.25rem;
  display: inline-block;
}

/* ==========================================================================
   Article page
   ========================================================================== */

.post-header {
  padding: 4rem 0 1.75rem;
  text-align: left;
}
.post-header .eyebrow {
  font-family: var(--display);
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--accent);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 1rem;
}
.post-header h1 {
  font-family: var(--display);
  font-size: clamp(2rem, 5vw, 3rem);
  line-height: 1.1;
  font-weight: 800;
  letter-spacing: -0.025em;
  color: var(--text-strong);
}

/* Hero image directly under title */
.post-hero {
  max-width: var(--max-wide);
  margin: 0 auto 2.5rem;
  padding: 0 1.25rem;
}
.post-hero img {
  width: 100%;
  height: auto;
  border-radius: 10px;
  background: #000;
  aspect-ratio: 16 / 9;
  object-fit: cover;
}
@media (min-width: 768px) {
  .post-hero { padding: 0 1.5rem; }
}

.post-body {
  font-family: var(--serif);
  font-size: 1.18rem;
  line-height: 1.7;
  color: var(--text);
  padding-bottom: 4rem;
  border-top: 1px solid var(--border-soft);
  padding-top: 2.5rem;
}
@media (max-width: 600px) {
  .post-body { font-size: 1.1rem; line-height: 1.65; padding-top: 2rem; }
}

.post-body > p { margin-bottom: 1.5em; }
.post-body > p:first-of-type {
  font-size: 1.32rem;
  color: var(--text-strong);
  line-height: 1.55;
  margin-bottom: 1.75em;
}
@media (max-width: 600px) {
  .post-body > p:first-of-type { font-size: 1.2rem; }
}

.post-body h2 {
  font-family: var(--display);
  font-size: clamp(1.4rem, 3vw, 1.75rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text-strong);
  margin: 2.75em 0 0.85em;
  line-height: 1.25;
}
.post-body h3 {
  font-family: var(--display);
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text-strong);
  margin: 2em 0 0.6em;
}

.post-body strong { color: var(--text-strong); font-weight: 700; }
.post-body em { font-style: italic; color: var(--text); }

.post-body a {
  color: var(--link);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 4px;
  text-decoration-color: rgba(111, 184, 255, 0.4);
}
.post-body a:hover {
  color: var(--accent);
  text-decoration-color: var(--accent);
}

.post-body ul, .post-body ol { margin: 0 0 1.5em; padding-left: 1.5em; }
.post-body li { margin-bottom: 0.5em; }

.post-body blockquote {
  border-left: 3px solid var(--accent);
  padding: 0.5em 0 0.5em 1.5em;
  margin: 1.5em 0;
  color: var(--text-strong);
  font-style: italic;
  background: rgba(247, 147, 26, 0.04);
}

.affiliate-box {
  background: var(--bg-card);
  border-left: 3px solid var(--accent);
  padding: 1rem 1.25rem;
  margin: 2em 0;
  border-radius: 4px;
  font-size: 0.95rem;
  font-family: var(--sans);
  font-style: normal;
}
.affiliate-box em { color: var(--text-muted); font-style: normal; }

.video-container {
  position: relative;
  padding-bottom: 56.25%;
  height: 0;
  overflow: hidden;
  margin: 2.5em 0;
  border-radius: 10px;
  background: #000;
}
.video-container iframe {
  position: absolute; top: 0; left: 0; width: 100%; height: 100%; border: 0;
}

.post-divider {
  border: 0;
  border-top: 1px solid var(--border-soft);
  margin: 3em 0 2em;
}
.post-cta {
  font-family: var(--sans);
  font-size: 1rem;
  text-align: center;
  color: var(--text-muted);
  padding: 1rem 0;
}
.post-cta a {
  color: var(--accent);
  font-weight: 600;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

/* ==========================================================================
   "More articles" section at bottom of post
   ========================================================================== */

.more-articles {
  background: var(--bg-elevated);
  border-top: 1px solid var(--border-soft);
  padding: 4rem 1.25rem;
}
.more-articles > * {
  max-width: var(--max-extra-wide);
  margin-left: auto;
  margin-right: auto;
}
.more-title {
  font-family: var(--display);
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-muted);
  letter-spacing: 0.15em;
  text-transform: uppercase;
  margin-bottom: 2rem;
}
.more-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
}
@media (min-width: 720px) {
  .more-grid { grid-template-columns: 1fr 1fr 1fr; gap: 2rem; }
}
.more-card {
  display: flex;
  flex-direction: column;
  background: var(--bg-card);
  border: 1px solid var(--border-soft);
  border-radius: 10px;
  overflow: hidden;
  text-decoration: none;
  color: var(--text);
  transition: border-color var(--transition), transform var(--transition);
}
.more-card:hover {
  border-color: var(--accent);
  transform: translateY(-2px);
  color: var(--text);
}
.more-card img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  background: #000;
}
.more-card-body { padding: 1.25rem; }
.more-card-meta {
  font-size: 0.7rem;
  font-family: var(--display);
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--text-quiet);
  margin-bottom: 0.5rem;
}
.more-card h3 {
  font-family: var(--display);
  font-size: 1.05rem;
  line-height: 1.3;
  font-weight: 700;
  color: var(--text-strong);
  letter-spacing: -0.015em;
}

/* ==========================================================================
   Static pages
   ========================================================================== */

.post.page .post-body {
  font-family: var(--sans);
  font-size: 1.05rem;
  line-height: 1.65;
  border-top: 0;
  padding-top: 0;
}
.post.page .post-body > p:first-of-type {
  font-size: 1.05rem;
  color: var(--text);
}
.post.page .post-body h2 {
  font-size: 1.35rem;
  margin: 2em 0 0.6em;
}
.post.page .post-header { padding-bottom: 1rem; }

/* ==========================================================================
   Footer
   ========================================================================== */

.site-footer {
  border-top: 1px solid var(--border-soft);
  padding: 3rem 0 4rem;
  text-align: center;
  background: var(--bg-elevated);
  font-size: 0.9rem;
  color: var(--text-muted);
}
.site-footer .channels {
  display: flex;
  justify-content: center;
  gap: 1.5rem;
  flex-wrap: wrap;
  margin-bottom: 1.25rem;
}
.site-footer .channels a {
  color: var(--accent);
  font-weight: 600;
  font-size: 0.9rem;
}
.site-footer .channels a:hover { color: var(--accent-bright); }
.site-footer .tagline { margin-bottom: 1rem; color: var(--text-muted); }
.site-footer .legal { font-size: 0.8rem; color: var(--text-quiet); }
.site-footer .legal a { color: var(--text-muted); }

/* ==========================================================================
   Selection + print
   ========================================================================== */

::selection { background: var(--accent); color: #1a1100; }

@media print {
  .site-header, .site-footer, .video-container, .post-cta, .more-articles { display: none; }
  body { background: white; color: black; }
  .post-body { font-size: 11pt; }
}
