/* ═══════════════════════════════════════════════════════════════
   FRAMEWORK-DETAIL.CSS — Single framework + funnel rail
   ═══════════════════════════════════════════════════════════════ */

.fw-single-hero { background: var(--clr-void); border-bottom: 1px solid var(--glass-border); }
.fw-single-cluster-pill {
  display: inline-flex;
  margin-bottom: 1rem;
  padding: 6px 14px;
  border-radius: 8px;
  font-size: 0.65rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #6ee7b7;
  background: rgba(16, 185, 129, 0.08);
  border: 1px solid rgba(16, 185, 129, 0.22);
}

.fw-single-grid { align-items: start; }
.fw-article-body .za-p-rich table {
  width: 100%;
  border-collapse: collapse;
  margin: 1.5rem 0;
  font-size: 0.9375rem;
}
.fw-article-body .za-p-rich th,
.fw-article-body .za-p-rich td {
  border: 1px solid var(--clr-border);
  padding: 0.75rem 1rem;
  text-align: left;
}
.fw-article-body .za-p-rich th {
  background: rgba(16, 185, 129, 0.06);
  font-weight: 700;
}

.fw-assessment-cta {
  margin-top: 3rem;
  padding: 2rem 2.25rem;
  border-radius: 16px;
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.06), rgba(45, 212, 191, 0.04));
  border: 1px solid rgba(16, 185, 129, 0.18);
}
.fw-assessment-cta h3 {
  margin: 0 0 0.5rem;
  font-size: 1.25rem;
  color: var(--clr-heading);
}
.fw-assessment-cta p {
  margin: 0 0 1.25rem;
  color: var(--clr-text-muted);
  line-height: 1.65;
}

/* Funnel cluster rail — theme-aware (light sidebar + midnight) */
.fw-funnel-rail {
  padding: 1.25rem;
  border-radius: 16px;
  background: linear-gradient(160deg, rgba(16, 185, 129, 0.07), rgba(16, 185, 129, 0.02));
  border: 1px solid rgba(16, 185, 129, 0.22);
  margin-bottom: 1.25rem;
  color: var(--clr-heading);
}
.fw-funnel-rail__cluster {
  margin-bottom: 1rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--clr-border);
}
.fw-funnel-rail__label {
  display: block;
  font-size: 0.625rem;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--clr-text-faint);
  margin-bottom: 0.35rem;
}
.fw-funnel-rail__cluster-id {
  font-size: 0.8125rem;
  font-weight: 700;
  color: #047857;
  letter-spacing: 0.02em;
  line-height: 1.45;
  word-break: break-word;
}
.fw-funnel-rail__title {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--clr-text-muted);
  margin-bottom: 0.85rem;
}
.fw-funnel-rail__title svg { color: #10b981; flex-shrink: 0; }
.fw-funnel-rail__steps {
  list-style: none;
  margin: 0 0 1rem;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}
.fw-funnel-rail__link {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0.65rem 0.75rem;
  border-radius: 10px;
  text-decoration: none;
  color: var(--clr-heading);
  background: var(--clr-gray-100);
  border: 1px solid var(--clr-border);
  transition: border-color 0.2s, background 0.2s, box-shadow 0.2s;
}
.fw-funnel-rail__link:hover {
  border-color: rgba(16, 185, 129, 0.45);
  background: rgba(16, 185, 129, 0.08);
  box-shadow: 0 4px 14px rgba(16, 185, 129, 0.12);
}
.fw-funnel-rail__link svg:last-child {
  color: var(--clr-text-faint);
  flex-shrink: 0;
  transition: transform 0.2s, color 0.2s;
}
.fw-funnel-rail__link:hover svg:last-child {
  color: #059669;
  transform: translateX(2px);
}
.fw-funnel-rail__icon {
  color: #059669;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 8px;
  background: rgba(16, 185, 129, 0.12);
}
.fw-funnel-rail__text { flex: 1; min-width: 0; }
.fw-funnel-rail__step-label {
  display: block;
  font-size: 0.6875rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--clr-text-faint);
}
.fw-funnel-rail__slug {
  display: block;
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--clr-text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.fw-funnel-rail__network {
  margin-bottom: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}
.fw-funnel-rail__network-link {
  font-size: 0.8125rem;
  font-weight: 600;
  color: #0d9488;
  text-decoration: none;
}
.fw-funnel-rail__network-link:hover { text-decoration: underline; color: #047857; }
.fw-funnel-rail__cta {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  padding: 0.75rem 1rem;
  border-radius: 10px;
  font-size: 0.8125rem;
  font-weight: 700;
  text-decoration: none;
  color: #fff;
  background: linear-gradient(135deg, #059669, #0d9488);
  border: 1px solid rgba(5, 150, 105, 0.35);
  box-shadow: 0 6px 18px rgba(16, 185, 129, 0.22);
  transition: opacity 0.2s, transform 0.2s, box-shadow 0.2s;
}
.fw-funnel-rail__cta:hover {
  opacity: 0.95;
  transform: translateY(-1px);
  box-shadow: 0 8px 22px rgba(16, 185, 129, 0.28);
}
.fw-funnel-rail__cta svg { color: #fff; }

html.theme-midnight .fw-funnel-rail,
[data-theme="dark"] .fw-funnel-rail {
  background: linear-gradient(160deg, rgba(16, 185, 129, 0.1), rgba(16, 185, 129, 0.03));
  border-color: rgba(16, 185, 129, 0.28);
}
html.theme-midnight .fw-funnel-rail__cluster-id,
[data-theme="dark"] .fw-funnel-rail__cluster-id {
  color: #6ee7b7;
}
html.theme-midnight .fw-funnel-rail__link,
[data-theme="dark"] .fw-funnel-rail__link {
  background: rgba(15, 23, 42, 0.55);
  border-color: rgba(255, 255, 255, 0.08);
  color: var(--clr-heading);
}
html.theme-midnight .fw-funnel-rail__slug,
[data-theme="dark"] .fw-funnel-rail__slug {
  color: #cbd5e1;
}

.fw-related-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: var(--sp-6);
}
.fw-related-card {
  display: block;
  padding: var(--sp-6);
  border-radius: var(--r-xl);
  background: var(--clr-surface);
  border: 1px solid var(--clr-border);
  text-decoration: none;
  transition: transform var(--t-spring), border-color 0.25s;
}
.fw-related-card:hover {
  transform: translateY(-4px);
  border-color: rgba(16, 185, 129, 0.35);
}
.fw-related-card__cat {
  font-size: var(--fs-xs);
  color: #10b981;
  font-weight: var(--fw-bold);
  text-transform: uppercase;
  margin-bottom: var(--sp-2);
}
.fw-related-card__title {
  font-size: var(--fs-lg);
  font-weight: var(--fw-semibold);
  color: var(--clr-heading);
  line-height: 1.4;
  margin-bottom: var(--sp-2);
}
.fw-related-card__meta {
  font-size: var(--fs-xs);
  color: var(--clr-text-faint);
}

@media (max-width: 960px) {
  .fw-single-sidebar { order: -1; }
  .fw-funnel-rail { margin-bottom: 0; }
}
