/* SOLUTERRA — Blog single article v4 · Premium reading experience */

/* ============================================================
   READING PROGRESS BAR
   ============================================================ */
.reading-progress {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: rgba(168,121,69,.08);
  z-index: 60;
}
.reading-progress span {
  display: block;
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, var(--gold-deep), var(--gold-light));
  transition: width 100ms linear;
}

/* ============================================================
   ARTICLE HERO
   ============================================================ */
.article-page { background: var(--ivory); }

.article-hero {
  background: var(--graphite);
  color: var(--champagne);
  padding: clamp(40px, 6vw, 80px) 0 clamp(56px, 8vw, 80px);
  position: relative;
  isolation: isolate;
  overflow: hidden;
}
.article-hero-bg {
  position: absolute; inset: 0; z-index: 0;
  background:
    radial-gradient(60% 80% at 100% 0%, rgba(191,163,106,.18), transparent 60%),
    radial-gradient(50% 60% at 0% 100%, rgba(168,121,69,.12), transparent 55%),
    linear-gradient(135deg, var(--graphite) 0%, var(--black) 100%);
}
.article-hero-bg::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: repeating-linear-gradient(135deg, transparent 0 20px, rgba(191,163,106,.04) 20px 21px);
}
.article-hero > .container { position: relative; z-index: 1; max-width: 920px; }

.article-hero-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  margin-bottom: 24px;
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(244,239,227,.55);
}
.article-hero-meta .meta-cat {
  padding: 6px 14px;
  background: rgba(191,163,106,.14);
  border: 1px solid rgba(191,163,106,.4);
  border-radius: var(--radius-pill);
  color: var(--gold-light);
  font-weight: 600;
}
.article-hero-meta .meta-dot {
  width: 4px; height: 4px;
  border-radius: 999px;
  background: rgba(244,239,227,.3);
}

.article-hero-h1 {
  font-family: var(--font-display);
  font-weight: 300;
  font-size: clamp(28px, 4.8vw, 52px);
  line-height: 1.08;
  letter-spacing: -0.02em;
  color: var(--ivory);
  margin: 0 0 24px 0;
  max-width: 24ch;
}
.article-hero-h1 em {
  font-style: italic;
  font-weight: 400;
  color: var(--gold-light);
}

.article-hero-lede {
  font-size: clamp(15px, 1.4vw, 18px);
  line-height: 1.65;
  color: rgba(244,239,227,.78);
  margin: 0 0 36px 0;
  max-width: 680px;
}

.article-hero-author {
  display: flex;
  align-items: center;
  gap: 16px;
  padding-top: 28px;
  border-top: 1px solid rgba(191,163,106,.18);
}
.author-avatar.large {
  width: 56px; height: 56px;
  font-size: 16px;
  border: 2px solid rgba(191,163,106,.45);
}
.author-block {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}
.author-name {
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 400;
  font-size: 18px;
  color: var(--ivory);
  letter-spacing: -0.01em;
}
.author-role {
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: rgba(244,239,227,.6);
}

.article-share {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.share-label {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(244,239,227,.5);
  margin-right: 4px;
}
.share-btn {
  width: 36px; height: 36px;
  border-radius: 999px;
  background: rgba(244,239,227,.06);
  border: 1px solid rgba(191,163,106,.28);
  color: var(--gold-light);
  display: grid;
  place-items: center;
  cursor: pointer;
  transition: all 240ms var(--ease-out);
}
.share-btn:hover {
  background: var(--gold-light);
  color: var(--black);
  border-color: var(--gold-light);
  transform: translateY(-2px);
}

/* ============================================================
   COVER IMAGE
   ============================================================ */
.article-cover {
  background: var(--graphite);
  padding-bottom: clamp(40px, 6vw, 80px);
}
.cover-image {
  aspect-ratio: 21/9;
  border-radius: var(--radius-xl);
  overflow: hidden;
  border: 1px solid rgba(191,163,106,.22);
  box-shadow: 0 30px 80px -30px rgba(0,0,0,.6);
  max-width: 920px;
  margin: 0 auto;
}

/* ============================================================
   ARTICLE LAYOUT (TOC sidebar + body)
   ============================================================ */
.article-section {
  background: var(--ivory);
  padding: clamp(48px, 7vw, 80px) 0 clamp(56px, 8vw, 96px);
}
.article-layout {
  display: grid;
  gap: 48px;
  grid-template-columns: 1fr;
  max-width: 1080px;
  margin: 0 auto;
}
@media (min-width: 1000px) {
  .article-layout { grid-template-columns: 240px 1fr; gap: 72px; }
}

/* ============== TOC SIDEBAR ============== */
.article-toc-aside { position: relative; }
.article-toc {
  position: sticky;
  top: 100px;
  display: flex;
  flex-direction: column;
  gap: 18px;
}
.toc-label {
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--gold-deep);
  font-weight: 600;
}
.article-toc ul {
  display: grid;
  gap: 4px;
  padding: 0;
  list-style: none;
  border-left: 1px solid rgba(168,121,69,.22);
  padding-left: 20px;
}
.article-toc li { display: block; }
.article-toc a {
  display: block;
  padding: 9px 0;
  font-family: var(--font-body);
  font-size: 13.5px;
  line-height: 1.4;
  color: var(--text-muted);
  text-decoration: none;
  position: relative;
  transition: color 240ms var(--ease-out), padding-left 320ms var(--ease-out);
}
.article-toc a::before {
  content: "";
  position: absolute;
  left: -21px;
  top: 14px;
  width: 0;
  height: 14px;
  background: var(--gold-deep);
  transition: width 280ms var(--ease-out);
}
.article-toc a:hover { color: var(--gold-deep); padding-left: 4px; }
.article-toc a.is-active {
  color: var(--black);
  font-weight: 600;
  padding-left: 4px;
}
.article-toc a.is-active::before { width: 2px; }

.toc-cta {
  margin-top: 24px;
  padding: 20px;
  background: linear-gradient(135deg, var(--gold-light), var(--gold-aged));
  border-radius: var(--radius-lg);
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.toc-cta-label {
  font-family: var(--font-display);
  font-style: italic;
  font-size: 15px;
  color: var(--black);
  line-height: 1.3;
}
.toc-cta .btn {
  padding: 12px 18px;
  font-size: 11px;
  letter-spacing: 0.12em;
  width: 100%;
  justify-content: center;
}
.toc-cta .btn-primary {
  background: var(--black);
  color: var(--ivory);
  border-color: var(--black);
}
.toc-cta .btn-primary:hover {
  background: #2a2a26;
  border-color: #2a2a26;
}

/* ============== ARTICLE BODY ============== */
.article-body {
  font-family: var(--font-body);
  color: var(--text);
  font-size: 17px;
  line-height: 1.78;
  max-width: 680px;
}

.article-body p {
  margin: 0 0 24px 0;
}
.article-body p strong { color: var(--black); font-weight: 600; }

.article-lead {
  font-family: var(--font-display);
  font-weight: 300;
  font-size: clamp(20px, 2.6vw, 24px);
  line-height: 1.5;
  color: var(--black);
  margin: 0 0 32px 0;
  padding: 0 0 32px 0;
  border-bottom: 1px solid rgba(168,121,69,.18);
  letter-spacing: -0.005em;
}
.article-lead strong { color: var(--gold-deep); font-weight: 400; }

.article-body h2 {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(26px, 3.4vw, 36px);
  line-height: 1.18;
  letter-spacing: -0.02em;
  color: var(--black) !important;
  margin: 56px 0 20px 0;
  scroll-margin-top: 100px;
  position: relative;
  padding-top: 28px;
}
.article-body h2::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 60px;
  height: 2px;
  background: linear-gradient(90deg, var(--gold-deep), var(--gold-light));
  border-radius: 999px;
}
.article-body h3 {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(20px, 2.4vw, 24px);
  line-height: 1.25;
  letter-spacing: -0.01em;
  color: var(--black) !important;
  margin: 36px 0 14px 0;
}

.article-body ul.article-list,
.article-body ol.article-steps {
  margin: 0 0 28px 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 14px;
}
.article-body ul.article-list li {
  position: relative;
  padding-left: 28px;
  font-size: 16px;
  line-height: 1.7;
}
.article-body ul.article-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 12px;
  width: 14px;
  height: 1px;
  background: var(--gold-deep);
}
.article-body ul.article-list li strong { color: var(--black); }

.article-body ol.article-steps {
  counter-reset: step;
}
.article-body ol.article-steps li {
  counter-increment: step;
  position: relative;
  padding-left: 60px;
  font-size: 16px;
  line-height: 1.7;
  padding-bottom: 20px;
  border-bottom: 1px solid rgba(168,121,69,.14);
}
.article-body ol.article-steps li:last-child { border-bottom: 0; }
.article-body ol.article-steps li::before {
  content: counter(step, decimal-leading-zero);
  position: absolute;
  left: 0;
  top: 0;
  width: 40px;
  height: 40px;
  background: var(--ivory);
  border: 1px solid var(--gold-aged);
  border-radius: 999px;
  display: grid;
  place-items: center;
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 300;
  font-size: 16px;
  color: var(--gold-deep);
  letter-spacing: -0.02em;
}
.article-body ol.article-steps li strong { color: var(--black); display: block; margin-bottom: 4px; }

.article-quote {
  margin: 36px 0;
  padding: 32px 32px 28px;
  background: linear-gradient(135deg, var(--graphite), var(--black));
  color: var(--ivory);
  border-radius: var(--radius-lg);
  position: relative;
  overflow: hidden;
}
.article-quote::before {
  content: "“";
  position: absolute;
  top: -10px;
  right: 24px;
  font-family: var(--font-display);
  font-size: 96px;
  color: rgba(191,163,106,.25);
  line-height: 1;
}
.article-quote p {
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 300;
  font-size: 22px;
  line-height: 1.4;
  color: var(--ivory);
  margin: 0 0 16px 0;
  letter-spacing: -0.005em;
  position: relative;
  z-index: 1;
}
.article-quote cite {
  font-family: var(--font-mono);
  font-style: normal;
  font-size: 10.5px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--gold-light);
}

.article-callout {
  display: grid;
  grid-template-columns: 40px 1fr;
  gap: 16px;
  align-items: flex-start;
  margin: 32px 0;
  padding: 22px 24px;
  background: rgba(191,163,106,.10);
  border: 1px solid rgba(168,121,69,.32);
  border-left: 4px solid var(--gold-deep);
  border-radius: var(--radius-md);
}
.article-callout .callout-icon {
  font-size: 22px;
  line-height: 1.5;
}
.article-callout > div {
  font-size: 15px;
  line-height: 1.6;
  color: var(--text);
}
.article-callout strong { color: var(--gold-deep); }

/* ============== LEAD CAPTURE BLOCK ============== */
.article-lead-block {
  display: grid;
  gap: 24px;
  grid-template-columns: 1fr;
  margin: 48px 0;
  padding: 32px;
  background:
    radial-gradient(120% 100% at 0% 0%, rgba(191,163,106,.18), transparent 55%),
    linear-gradient(135deg, var(--graphite), var(--black));
  border-radius: var(--radius-lg);
  color: var(--ivory);
  position: relative;
  overflow: hidden;
}
.article-lead-block::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: repeating-linear-gradient(135deg, transparent 0 16px, rgba(191,163,106,.04) 16px 17px);
}
.article-lead-block > * { position: relative; z-index: 1; }
@media (min-width: 600px) {
  .article-lead-block { grid-template-columns: 1.4fr auto; align-items: center; gap: 32px; }
}
.lead-block-side { display: flex; flex-direction: column; gap: 10px; }
.lead-eyebrow {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--gold-light);
}
.lead-block-side h3 {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: 24px;
  line-height: 1.2;
  color: var(--ivory) !important;
  margin: 0;
  letter-spacing: -0.01em;
}
.lead-block-side p {
  font-size: 14.5px;
  line-height: 1.55;
  color: rgba(244,239,227,.7);
  margin: 0;
}
.article-lead-block .btn-primary {
  background: var(--gold-light);
  color: var(--black);
  border: 0;
  padding: 14px 24px;
  font-size: 11px;
  letter-spacing: 0.14em;
  white-space: nowrap;
}
.article-lead-block .btn-primary:hover {
  background: #d8c08a;
  transform: translateY(-2px);
}

/* ============================================================
   AUTHOR BIO SECTION
   ============================================================ */
.article-author-section {
  background: linear-gradient(180deg, var(--ivory) 0%, #efe6d3 100%);
  padding: clamp(48px, 6vw, 80px) 0;
}
.author-card {
  display: grid;
  gap: 28px;
  grid-template-columns: 1fr;
  align-items: center;
  max-width: 920px;
  margin: 0 auto;
  padding: clamp(28px, 4vw, 48px);
  background: var(--ivory);
  border: 1px solid rgba(168,121,69,.22);
  border-left: 4px solid var(--gold-deep);
  border-radius: var(--radius-xl);
  box-shadow: 0 30px 70px -28px rgba(85,67,30,.18);
}
@media (min-width: 720px) {
  .author-card { grid-template-columns: auto 1fr; gap: 32px; }
}
.author-avatar.xl {
  width: 96px;
  height: 96px;
  font-size: 28px;
  border: 2px solid var(--gold-aged);
  align-self: start;
  justify-self: center;
}
@media (min-width: 720px) {
  .author-avatar.xl { width: 120px; height: 120px; font-size: 36px; justify-self: start; }
}
.author-card-body { display: flex; flex-direction: column; gap: 10px; }
.author-card-label {
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--gold-deep);
}
.author-card-name {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(24px, 3vw, 30px);
  line-height: 1.1;
  letter-spacing: -0.01em;
  color: var(--black) !important;
  margin: 0;
}
.author-card-role {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold-deep);
  margin: 0;
}
.author-card-bio {
  font-size: 14.5px;
  line-height: 1.65;
  color: var(--text-muted);
  margin: 8px 0;
}
.author-card-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 8px;
}
.author-card-actions .btn { padding: 12px 22px; font-size: 11px; letter-spacing: 0.14em; }

/* ============================================================
   RELATED ARTICLES
   ============================================================ */
.article-related {
  background: linear-gradient(180deg, var(--graphite) 0%, var(--black) 100%);
  color: var(--champagne);
  padding: clamp(64px, 8vw, 100px) 0;
  position: relative;
  overflow: hidden;
}
.article-related::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(60% 60% at 100% 0%, rgba(191,163,106,.14), transparent 60%);
}
.article-related > .container { position: relative; z-index: 1; }
.related-head {
  margin-bottom: 40px;
  text-align: center;
}
.related-head .eyebrow.on-dark { color: var(--gold-light); display: inline-flex; }
.related-head .eyebrow.on-dark::before { background: var(--gold-aged); }
.related-head h2 { color: var(--ivory) !important; margin-top: 16px; }
.related-head em.bronze-light { color: var(--gold-light) !important; font-style: italic; font-weight: 400; }

.related-grid {
  display: grid;
  gap: 20px;
  grid-template-columns: 1fr;
}
@media (min-width: 640px) { .related-grid { grid-template-columns: 1fr 1fr; } }
@media (min-width: 1000px) { .related-grid { grid-template-columns: 1fr 1fr 1fr; } }

.related-grid .article-card {
  background: rgba(244,239,227,.04);
  border-color: rgba(191,163,106,.22);
}
.related-grid .article-card .card-title { color: var(--ivory) !important; }
.related-grid .article-card .card-desc { color: rgba(244,239,227,.65); }
.related-grid .article-card .card-foot { border-top-color: rgba(191,163,106,.18); }
.related-grid .article-card .card-time { color: rgba(244,239,227,.5); }
.related-grid .article-card .author-info strong { color: var(--ivory); }
.related-grid .article-card .meta-cat {
  background: rgba(191,163,106,.14);
  border-color: rgba(191,163,106,.32);
  color: var(--gold-light);
}
.related-grid .article-card:hover {
  background: rgba(244,239,227,.08);
  border-color: var(--gold-light);
}

/* ============================================================
   MOBILE
   ============================================================ */
@media (max-width: 720px) {
  .article-hero { padding: 32px 0 40px !important; }
  .article-hero-meta { font-size: 9.5px; gap: 8px; }
  .article-hero-meta .meta-cat { font-size: 9px; padding: 5px 11px; }
  .article-hero-h1 { font-size: 26px !important; }
  .article-hero-lede { font-size: 14.5px !important; margin-bottom: 24px !important; }
  .article-hero-author {
    flex-wrap: wrap;
    gap: 12px;
    padding-top: 20px;
  }
  .author-avatar.large { width: 44px; height: 44px; font-size: 13px; }
  .author-name { font-size: 15px; }
  .author-role { font-size: 9.5px; }
  .article-share {
    width: 100%;
    justify-content: flex-start;
    padding-top: 12px;
    border-top: 1px solid rgba(191,163,106,.14);
  }
  .share-btn { width: 32px; height: 32px; }
  .share-btn svg { width: 12px; height: 12px; }

  .article-cover { padding-bottom: 24px; }
  .cover-image { border-radius: 16px; aspect-ratio: 16/10; }

  .article-section { padding: 32px 0 48px !important; }
  .article-layout { gap: 0 !important; }
  .article-toc-aside { display: none; }

  .article-body { font-size: 15.5px; }
  .article-lead { font-size: 18px !important; padding-bottom: 24px !important; margin-bottom: 24px !important; }
  .article-body h2 { font-size: 24px !important; margin-top: 40px !important; padding-top: 22px; }
  .article-body h3 { font-size: 18px !important; margin-top: 28px !important; }
  .article-body p { margin-bottom: 20px; }
  .article-body ul.article-list li { font-size: 14.5px; padding-left: 22px; }
  .article-body ol.article-steps li { font-size: 14.5px; padding-left: 50px; padding-bottom: 16px; }
  .article-body ol.article-steps li::before { width: 34px; height: 34px; font-size: 13px; }
  .article-quote { padding: 22px 22px 18px; margin: 28px 0; }
  .article-quote p { font-size: 17px; }
  .article-quote::before { font-size: 64px; top: -6px; right: 14px; }
  .article-callout { padding: 16px 18px; grid-template-columns: 28px 1fr; }
  .article-callout > div { font-size: 13.5px; }

  .article-lead-block { padding: 24px 22px !important; margin: 32px 0 !important; }
  .lead-block-side h3 { font-size: 20px !important; }
  .lead-block-side p { font-size: 13.5px; }
  .article-lead-block .btn-primary { width: 100%; justify-content: center; }

  .article-author-section { padding: 40px 0 !important; }
  .author-card { padding: 24px 22px !important; border-radius: 18px !important; }
  .author-card-name { font-size: 22px !important; }
  .author-card-bio { font-size: 13.5px !important; }
  .author-card-actions .btn { width: 100%; justify-content: center; }

  .article-related { padding: 48px 0 !important; }
  .related-head { margin-bottom: 28px; }
  .related-head h2 { font-size: 24px !important; }
}

/* Tablet (TOC visible but compressed) */
@media (min-width: 1000px) and (max-width: 1180px) {
  .article-layout { grid-template-columns: 200px 1fr; gap: 48px; }
  .article-toc a { font-size: 12.5px; }
}
