
/* ── Page background ── */
.post-page {
  background: var(--grey);
}

/* ── Article container ── */
.post-article {
  padding: 48px 0 80px;
}

.post-wrap {
  max-width: 680px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ── Meta row: back link + date ── */
.post-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 28px;
  gap: 16px;
  flex-wrap: wrap;
}

.post-back {
  font-size: 0.83rem;
  font-weight: 600;
  color: var(--text-muted);
  text-decoration: none;
}
.post-back:hover { color: var(--navy); }

.post-date {
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: capitalize;
  color: var(--text-muted);
}

/* ── Title ── */
.post-article h1 {
  font-size: clamp(1.7rem, 4vw, 2.4rem);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.01em;
  color: var(--text);
  margin-bottom: 18px;
}

/* ── Intro paragraph ── */
.post-intro {
  font-size: 1.08rem;
  line-height: 1.65;
  color: var(--text-muted);
  margin-bottom: 32px;
}

/* ── Divider ── */
.post-divider {
  border: none;
  border-top: 1px solid var(--grey-border);
  margin: 36px 0;
}

/* ── Body content ── */
.post-article h2 {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text);
  margin: 40px 0 12px;
  line-height: 1.25;
}

.post-article p {
  font-size: 0.97rem;
  line-height: 1.8;
  color: var(--text);
  margin-bottom: 18px;
}

.post-article ul,
.post-article ol {
  margin: 0 0 18px 22px;
  color: var(--text);
}

.post-article li {
  font-size: 0.97rem;
  line-height: 1.75;
  margin-bottom: 5px;
}

.post-article strong { font-weight: 700; }

.post-article a { color: var(--navy); }
.post-article a:hover { text-decoration: underline; }

.definition-box {
  background: var(--grey);
  border: 1px solid rgba(21, 61, 100, 0.15);
  border-left: 3px solid var(--navy);
  border-radius: 10px;
  padding: 1rem 1.25rem;
  margin: 1.5rem 0 2rem;
}

.definition-box p {
  margin-bottom: 0;
}

.definition-label {
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--navy);
  margin-bottom: 0.5rem;
}

.definition-text {
  margin: 0;
  font-size: 1.1rem;
  line-height: 1.7;
  color: var(--navy-dark);
}

/* ── Callout box ── */
.callout {
  background: var(--white);
  border-left: 2px solid var(--navy);
  border-radius: 0 4px 4px 0;
  padding: 16px 20px;
  margin: 24px 0;
  font-size: 0.95rem;
  line-height: 1.65;
  color: var(--text);
}

/* ── CRE Concept Box ── */
.concept-box {
  position: relative;
  background: var(--white);
  border: 1px solid var(--grey-border);
  border-radius: 8px;
  padding: 32px 22px 20px; /* increased top padding so tag doesn't clip */
  margin: 42px 0 32px;
}

.concept-tag {
  position: absolute;
  top: -16px;
  left: 16px; /* FIX: was missing px unit */
  min-width: 120px;
  text-align: center;
  background: var(--navy);
  color: var(--white);
  padding: 10px 18px;
  border-radius: 8px;
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  line-height: 1;
}

.concept-box p {
  margin-bottom: 10px;
}

.formula-row {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 8px 0;
  flex-wrap: wrap;
}

.formula-row strong {
  min-width: 90px;
  flex-shrink: 0;
  font-weight: 700;
  color: var(--text);
}

.formula {
  flex: 1;
  font-family: Consolas, Monaco, monospace;
  font-size: 0.92rem;
  color: var(--text);
}

/* ── Excel screenshot ── */
.img-block {
  margin: 32px 0;
}

.img-block img {
  width: 100%;
  height: auto;
  border-radius: 4px;
  border: 1px solid var(--grey-border);
}

.img-block figcaption {
  margin-top: 8px;
  font-size: 0.8rem;
  color: var(--text-muted);
  text-align: center;
}

/* ── YouTube embed ── */
.video-block {
  margin: 32px 0;
  position: relative;
  padding-bottom: 56.25%;
  height: 0;
  overflow: hidden;
  border-radius: 4px;
}

.video-block iframe {
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 100%;
  border: none;
}

/* ── Template buttons ── */
.template-buttons {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin: 32px 0;
}

.template-btn {
  display: inline-block;
  padding: 12px 20px;
  border-radius: 4px;
  font-size: 0.9rem;
  font-weight: 600;
  text-decoration: none;
  border: 1px solid transparent;
}

.template-btn-free {
  background: var(--white);
  color: var(--text);
  border-color: var(--grey-border);
}
.template-btn-free:hover {
  border-color: var(--navy);
  color: var(--navy);
  text-decoration: none;
}

/* FIX: replaced !important with specific selectors */
.post-article .template-btn-paid,
.post-article .template-btn-paid:visited {
  background: var(--navy);
  color: var(--white);
  border-color: var(--navy);
}

.post-article .template-btn-paid:hover {
  background: var(--navy-dark);
  border-color: var(--navy-dark);
  color: var(--white);
  text-decoration: none; /* FIX: consistent with free button, no underline on hover */
}

/* ── Email CTA ── */
.post-cta {
  background: var(--white);
  border: 1px solid var(--grey-border);
  border-radius: 5px;
  padding: 28px;
  margin-top: 40px;
}

/* FIX: replaced !important with specific selectors */
.post-cta .post-cta-label {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--navy);
  margin-bottom: 6px;
}

.post-cta .post-cta-text {
  font-size: 0.95rem;
  color: var(--text-muted);
  margin-bottom: 16px;
}

.post-cta-form {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.post-cta-form input[type="email"] {
  flex: 1;
  min-width: 200px;
  padding: 10px 14px;
  font-size: 0.9rem;
  border: 1px solid var(--grey-border);
  border-radius: 4px;
  background: var(--grey);
  color: var(--text);
}

.post-cta-form input[type="email"]:focus {
  outline: 2px solid var(--navy);
  outline-offset: 1px;
}

.post-cta-form button {
  padding: 10px 20px;
  background: var(--navy);
  color: var(--white);
  border: none;
  border-radius: 4px;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
}
.post-cta-form button:hover { background: var(--navy-dark); }

/* ── Series label ── */
.series-label {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--navy);
  background: rgba(21, 61, 100, 0.08);
  padding: 4px 10px;
  border-radius: 3px;
  margin-bottom: 14px;
}

/* ── Series nav ── */
.series-nav {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  margin: 8px 0;
}

.series-nav a {
  display: flex;
  flex-direction: column;
  gap: 4px;
  text-decoration: none;
  max-width: 45%;
}

.series-nav-prev { align-items: flex-start; }
.series-nav-next { align-items: flex-end; margin-left: auto; }

.series-nav-label {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.series-nav-title {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--navy);
  line-height: 1.3;
}

.series-nav a:hover .series-nav-title { text-decoration: underline; }

/* ── Mobile ── */
@media (max-width: 600px) {
  .post-article { padding: 36px 0 64px; }
  .template-buttons { flex-direction: column; }
  .template-btn { text-align: center; }
  .post-cta-form { flex-direction: column; }
  .post-cta-form button { width: 100%; }
}

@media (max-width: 480px) {
  .series-nav { flex-direction: column; gap: 12px; }
  .series-nav a { max-width: 100%; }
  .series-nav-next { align-items: flex-start; margin-left: 0; }
}
