/* ── Article Components — Warm Trust (Baby Gear Guide) v2.0 ── */

/* ── Hero Image ── */
.article-hero {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border-radius: var(--radius-lg);
  margin-bottom: 2rem;
}

.article-hero img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.article-hero::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 50%;
  background: linear-gradient(transparent, rgba(255, 248, 240, 0.9));
  pointer-events: none;
}

@media (max-width: 768px) {
  .article-hero {
    aspect-ratio: 4 / 3;
    border-radius: 0;
    margin-left: -1rem;
    margin-right: -1rem;
    width: calc(100% + 2rem);
  }
}

/* ── Comparison Table ── */
.comparison-table-wrapper {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  margin: 2rem 0;
  border-radius: var(--radius-lg);
  border: 1px solid var(--wt-border);
}

.comparison-table,
.wp-block-table.is-style-comparison table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.95rem;
}

.comparison-table thead th,
.wp-block-table.is-style-comparison th {
  background: var(--wt-warm-gold);
  color: var(--wt-white);
  font-weight: 600;
  padding: 14px 16px;
  text-align: left;
  position: sticky;
  top: 0;
  z-index: 1;
}

.comparison-table tbody tr:nth-child(even) {
  background: var(--wt-foundation);
}

.comparison-table tbody tr:nth-child(odd) {
  background: var(--wt-white);
}

.comparison-table td {
  padding: 12px 16px;
  border-bottom: 1px solid var(--wt-border);
  vertical-align: middle;
}

.comparison-table .check-yes::before {
  content: "\2713";
  color: var(--wt-sage);
  font-weight: bold;
  font-size: 1.1rem;
}

.comparison-table .check-no::before {
  content: "\2717";
  color: var(--wt-primary-coral);
  font-weight: bold;
  font-size: 1.1rem;
}

.comparison-table .cta-cell a {
  display: inline-block;
  background: var(--wt-warm-gold);
  color: var(--wt-white) !important;
  padding: 8px 16px;
  border-radius: var(--radius);
  font-weight: 600;
  font-size: 0.85rem;
  text-decoration: none;
  white-space: nowrap;
}

.comparison-table .cta-cell a:hover {
  background: var(--wt-warm-gold-hover);
}

@media (max-width: 768px) {
  .comparison-table {
    font-size: 0.85rem;
  }

  .comparison-table td,
  .comparison-table th {
    padding: 8px 10px;
  }

  /* Sticky first column on mobile */
  .comparison-table td:first-child,
  .comparison-table th:first-child {
    position: sticky;
    left: 0;
    background: inherit;
    z-index: 1;
    min-width: 120px;
    font-weight: 600;
  }
}

/* ── Enhanced Author Box (injected by PHP) ── */
.author-box .author-avatar {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--wt-sage);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--wt-white);
  font-weight: 700;
  font-size: 1.1rem;
  flex-shrink: 0;
}

/* ── Sticky CTA slide-up animation ── */
.sticky-cta {
  transform: translateY(100%);
  animation: slideUp 0.3s ease-out 2s forwards;
}

@keyframes slideUp {
  to { transform: translateY(0); }
}

/* Dismiss button */
.sticky-cta .dismiss-btn {
  position: absolute;
  top: -12px;
  right: 12px;
  width: 24px;
  height: 24px;
  background: var(--wt-deep-brown);
  color: var(--wt-white);
  border: none;
  border-radius: 50%;
  font-size: 14px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}

/* CSS-only dismiss via checkbox */
#sticky-cta-dismiss:checked ~ .sticky-cta {
  display: none !important;
}

#sticky-cta-dismiss {
  display: none;
}

/* Body padding to prevent sticky CTA overlap */
body.single-post {
  padding-bottom: 70px;
}

/* ── Quick Verdict Box ── */
.verdict-box {
  background: rgba(135, 168, 120, 0.1);
  border: 2px solid var(--wt-warm-gold);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  margin: 1.5rem 0;
  text-align: center;
}

.verdict-box .verdict-score {
  font-size: 2.5rem;
  font-weight: 800;
  color: var(--wt-primary-coral);
}

.verdict-box .verdict-label {
  font-size: 0.9rem;
  color: var(--wt-deep-brown-light);
  text-transform: uppercase;
  letter-spacing: 2px;
}

/* ── Star Rating display ── */
.star-rating {
  color: var(--wt-warm-gold);
  font-size: 1.1rem;
  letter-spacing: 2px;
}

/* ── Breadcrumb ── */
.breadcrumb {
  font-size: 0.85rem;
  color: var(--wt-deep-brown-light);
  margin-bottom: 1rem;
}

.breadcrumb a {
  color: var(--wt-warm-gold);
  text-decoration: none;
}

.breadcrumb a:hover {
  text-decoration: underline;
}

.breadcrumb .separator {
  margin: 0 0.4rem;
  color: var(--wt-deep-brown-light);
}
