/* ============================================================
   Shierly Therapy — Blog styles
   Extends styles.css — same design tokens, same fonts
   ============================================================ */

/* ============================================================
   SHARED: force nav to always be scrolled state on sub-pages
   ============================================================ */
.nav.is-scrolled {
  background: rgba(255,255,255,0.96);
  backdrop-filter: blur(12px);
  box-shadow: 0 1px 0 rgba(30,51,85,0.12);
  color: var(--navy);
  text-shadow: none;
}

/* ============================================================
   BLOG LISTING — Hero
   ============================================================ */
.blog-hero {
  position: relative;
  height: clamp(280px, 42vw, 520px);
  display: flex; align-items: flex-end;
  overflow: hidden; color: var(--white);
  margin-top: var(--nav-h);
}
.blog-hero__media { position: absolute; inset: 0; z-index: 0; }
.blog-hero__media img { width: 100%; height: 100%; object-fit: cover; object-position: center 30%; }
.blog-hero__scrim {
  position: absolute; inset: 0;
  background: linear-gradient(to bottom,
    rgba(15,25,45,0.45) 0%,
    rgba(15,25,45,0.78) 70%,
    rgba(15,25,45,0.92) 100%);
}
.blog-hero__content {
  position: relative; z-index: 2;
  width: min(100% - 2 * var(--gutter), var(--maxw)); margin-inline: auto;
  padding-bottom: clamp(2.5rem, 6vh, 4rem);
}
.blog-hero__eyebrow {
  font-family: var(--body); font-size: 0.78rem; letter-spacing: 0.22em;
  text-transform: uppercase; color: rgba(255,255,255,0.7); margin-bottom: 0.6rem;
}
.blog-hero__title {
  font-family: var(--serif); font-size: clamp(2.5rem, 1.5rem + 5vw, 5rem);
  font-weight: 400; letter-spacing: 0.06em; color: var(--white);
  margin-bottom: 0.6rem;
}
.blog-hero__sub {
  font-family: var(--body); font-size: clamp(0.95rem, 0.85rem + 0.4vw, 1.1rem);
  color: rgba(255,255,255,0.8); font-style: italic;
}

/* ============================================================
   BLOG LISTING — Grid
   ============================================================ */
.blog-listing { padding: clamp(3.5rem, 8vh, 6rem) 0; background: var(--white); }

.blog-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 340px), 1fr));
  gap: clamp(1.5rem, 3vw, 2.5rem);
}

.blog-card {
  background: var(--white);
  border: 1px solid rgba(30,51,85,0.1);
  border-radius: 12px;
  overflow: hidden;
  display: flex; flex-direction: column;
  transition: transform 0.4s var(--ease), box-shadow 0.4s var(--ease);
}
.blog-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 24px 48px -16px rgba(30,51,85,0.18);
}
.blog-card__image {
  aspect-ratio: 16 / 9; overflow: hidden;
}
.blog-card__image img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform 0.6s var(--ease);
}
.blog-card:hover .blog-card__image img { transform: scale(1.04); }

.blog-card__body {
  padding: clamp(1.2rem, 3vw, 1.8rem);
  display: flex; flex-direction: column; gap: 0.6rem; flex: 1;
}
.blog-card__date {
  font-family: var(--body); font-size: 0.78rem; letter-spacing: 0.16em;
  text-transform: uppercase; color: var(--blue-accent); font-weight: 700;
}
.blog-card__title {
  font-family: var(--serif); font-size: clamp(1.05rem, 0.9rem + 0.6vw, 1.3rem);
  font-weight: 400; letter-spacing: 0.02em; line-height: 1.3; color: var(--navy);
}
.blog-card__title a { color: inherit; }
.blog-card__title a:hover { color: var(--blue-accent); }
.blog-card__excerpt {
  font-family: var(--body); font-size: 0.95rem; color: var(--ink-soft);
  line-height: 1.65; flex: 1;
}
.blog-card__read {
  font-family: var(--body); font-size: 0.82rem; letter-spacing: 0.12em;
  text-transform: uppercase; color: var(--blue-accent);
  text-decoration: underline; text-underline-offset: 3px;
  margin-top: 0.4rem; align-self: flex-start;
}
.blog-card__read:hover { color: var(--navy); }

/* ============================================================
   ARTICLE — Hero
   ============================================================ */
.post-hero {
  position: relative;
  min-height: clamp(320px, 50vw, 560px);
  display: flex; align-items: flex-end;
  overflow: hidden; color: var(--white);
  margin-top: var(--nav-h);
}
.post-hero__media { position: absolute; inset: 0; z-index: 0; }
.post-hero__media img { width: 100%; height: 100%; object-fit: cover; object-position: center 40%; }
.post-hero__scrim {
  position: absolute; inset: 0;
  background: linear-gradient(to bottom,
    rgba(15,25,45,0.20) 0%,
    rgba(15,25,45,0.55) 55%,
    rgba(15,25,45,0.88) 100%);
}
.post-hero__content {
  position: relative; z-index: 2;
  width: min(100% - 2 * var(--gutter), var(--maxw)); margin-inline: auto;
  padding-bottom: clamp(3rem, 7vh, 5rem);
  max-width: 800px; margin-inline: auto;
}
.post-hero__back {
  display: inline-block;
  font-family: var(--body); font-size: 0.82rem; letter-spacing: 0.12em;
  text-transform: uppercase; color: rgba(255,255,255,0.75);
  margin-bottom: 1.2rem;
  transition: color 0.2s;
}
.post-hero__back:hover { color: var(--white); }
.post-hero__date {
  display: block;
  font-family: var(--body); font-size: 0.78rem; letter-spacing: 0.18em;
  text-transform: uppercase; color: rgba(255,255,255,0.7); margin-bottom: 0.8rem;
}
.post-hero__title {
  font-family: var(--serif); font-size: clamp(1.6rem, 1rem + 3vw, 3rem);
  font-weight: 400; letter-spacing: 0.03em; line-height: 1.18; color: var(--white);
}

/* ============================================================
   ARTICLE — Body
   ============================================================ */
.post-body { background: var(--white); }

.post-body__inner {
  max-width: 680px;
  margin-inline: auto;
  padding: clamp(3rem, 8vh, 5.5rem) var(--gutter);
}

.post-body__inner p {
  font-family: var(--body);
  font-size: clamp(1rem, 0.95rem + 0.3vw, 1.15rem);
  line-height: 1.8;
  color: var(--ink-soft);
  margin-bottom: 1.4rem;
}
.post-body__inner p strong { color: var(--navy); font-weight: 700; }

.post-body__inner h2 {
  font-family: var(--serif);
  font-size: clamp(1.25rem, 1rem + 1.2vw, 1.75rem);
  font-weight: 400; letter-spacing: 0.04em;
  color: var(--navy);
  margin-top: 2.8rem; margin-bottom: 1rem;
}

.post-body__inner h3 {
  font-family: var(--body);
  font-size: clamp(1.05rem, 1rem + 0.3vw, 1.2rem);
  font-weight: 700; letter-spacing: 0.01em;
  color: var(--navy);
  margin-top: 2rem; margin-bottom: 0.6rem;
}

.post-body__inner ul {
  list-style: none; padding: 0;
  margin-bottom: 1.4rem;
  display: flex; flex-direction: column; gap: 0.5rem;
}
.post-body__inner ul li {
  font-family: var(--body);
  font-size: clamp(1rem, 0.95rem + 0.3vw, 1.15rem);
  line-height: 1.75; color: var(--ink-soft);
  padding-left: 1.5rem; position: relative;
}
.post-body__inner ul li::before {
  content: "—"; position: absolute; left: 0; color: var(--blue-accent);
}

/* ============================================================
   ARTICLE — CTA block
   ============================================================ */
.post-cta {
  background: var(--navy);
  padding: clamp(3.5rem, 8vh, 5.5rem) var(--gutter);
  text-align: center; color: var(--white);
}
.post-cta__inner { max-width: 560px; margin-inline: auto; }
.post-cta .section-eyebrow { color: rgba(255,255,255,0.6); }
.post-cta__title {
  font-family: var(--serif); font-size: clamp(1.8rem, 1.2rem + 2.5vw, 2.8rem);
  font-weight: 400; letter-spacing: 0.04em; color: var(--white);
  margin-bottom: 1rem;
}
.post-cta p {
  font-family: var(--body); color: rgba(255,255,255,0.78);
  margin-bottom: 2rem; font-size: 1.05rem; line-height: 1.7;
}

/* ============================================================
   ARTICLE — Comparison table
   ============================================================ */
.post-table-wrap {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  margin: 2.5rem 0;
  border: 1px solid rgba(30,51,85,0.12);
  border-radius: 8px;
}

.post-table {
  width: 100%;
  min-width: 560px;
  border-collapse: collapse;
  font-size: clamp(0.82rem, 0.78rem + 0.18vw, 0.9rem);
  line-height: 1.6;
}

.post-table thead th {
  padding: 0.75rem 1rem;
  text-align: left;
  background: var(--navy);
  color: var(--white);
  font-family: var(--body);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  border-right: 1px solid rgba(255,255,255,0.12);
}
.post-table thead th:first-child { width: 168px; }
.post-table thead th:last-child { border-right: none; }

.post-table tbody th,
.post-table tbody td {
  padding: 0.8rem 1rem;
  vertical-align: top;
  border-bottom: 1px solid rgba(30,51,85,0.1);
  border-right: 1px solid rgba(30,51,85,0.1);
  color: var(--ink-soft);
}
.post-table tbody th:last-child,
.post-table tbody td:last-child { border-right: none; }
.post-table tbody tr:last-child th,
.post-table tbody tr:last-child td { border-bottom: none; }

.post-table tbody th {
  font-family: var(--body);
  font-weight: 700;
  font-size: 0.82rem;
  color: var(--navy);
  background: rgba(30,51,85,0.04);
  white-space: nowrap;
}
.post-table tbody tr:nth-child(even) td { background: rgba(30,51,85,0.02); }

.post-body__inner .post-table-note {
  font-size: 0.875rem;
  font-style: italic;
  line-height: 1.75;
  color: var(--ink-soft);
  border-left: 3px solid rgba(30,51,85,0.2);
  padding: 0.9rem 1.1rem;
  margin-top: -1.2rem;
  margin-bottom: 2.5rem;
  background: rgba(30,51,85,0.03);
  border-radius: 0 4px 4px 0;
}

/* ============================================================
   ARTICLE — Back nav
   ============================================================ */
.post-nav {
  background: var(--grey-bg);
  padding: 1.8rem 0;
  border-top: 1px solid rgba(30,51,85,0.1);
}
.post-nav__back {
  font-family: var(--body); font-size: 0.85rem; letter-spacing: 0.12em;
  text-transform: uppercase; color: var(--blue-accent);
  text-decoration: underline; text-underline-offset: 3px;
}
.post-nav__back:hover { color: var(--navy); }
