/* ── Compare Page Styles ── */
.compare-page {
  --content-max: 1200px;
}

.compare-hero {
  padding-top: clamp(48px, 6vw, 72px);
  padding-bottom: clamp(32px, 4vw, 48px);
  text-align: center;
}

.compare-hero .section-header {
  max-width: 780px;
  margin: 0 auto;
}

.compare-hero h1 {
  font-family: var(--font-heading);
  font-size: clamp(2.2rem, 4.5vw, 3.4rem);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin: 12px 0 16px;
  color: var(--text);
  line-height: 1.15;
}

.compare-hero p {
  color: var(--text-secondary);
  font-size: clamp(1.05rem, 1.8vw, 1.25rem);
  line-height: 1.6;
}

/* ── Matrix Table ── */
.matrix-section {
  padding: clamp(32px, 4vw, 56px) 0;
}

.matrix-wrapper {
  margin-top: 32px;
  overflow-x: auto;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  -webkit-overflow-scrolling: touch;
}

/* Keep company names visible while rows scroll out of view on short screens. */
@media (max-width: 900px) {
  .matrix-wrapper {
    overflow-y: auto;
    max-height: 68vh;
    overscroll-behavior: contain;
    scrollbar-width: thin;
  }

  .matrix-table thead th {
    position: sticky;
    top: 0;
    z-index: 4;
  }

  .matrix-table thead .col-feature {
    z-index: 5;
  }
}

.matrix-table {
  width: 100%;
  border-collapse: collapse;
  text-align: center;
  font-size: 0.92rem;
  min-width: 820px;
}

.matrix-table th,
.matrix-table td {
  padding: 16px 14px;
  border-bottom: 1px solid var(--border);
  border-right: 1px solid var(--border);
  vertical-align: middle;
}

.matrix-table th:last-child,
.matrix-table td:last-child {
  border-right: none;
}

.matrix-table thead th {
  background: var(--bg-secondary);
  font-family: var(--font-heading);
  font-size: 1.05rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--text);
  text-transform: uppercase;
  padding: 20px 14px;
}

.matrix-table .col-feature {
  text-align: left;
  font-weight: 600;
  width: 260px;
  min-width: 220px;
  position: sticky;
  left: 0;
  background: var(--surface);
  z-index: 2;
}

.matrix-table thead .col-feature {
  background: var(--bg-secondary);
  z-index: 3;
}

/* Highlight Dataslate Column */
.matrix-table .col-dataslate {
  background: rgba(212, 168, 67, 0.05);
  font-weight: 600;
  color: var(--text);
}

.matrix-table thead .col-dataslate {
  background: rgba(212, 168, 67, 0.12);
  border-top: 3px solid var(--accent);
  position: relative;
}

.matrix-table .badge-hero {
  display: inline-block;
  font-size: 0.7rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  background: var(--accent);
  color: var(--btn-primary-text);
  padding: 2px 8px;
  border-radius: var(--radius);
  margin-top: 4px;
  font-weight: 700;
}

.matrix-table tbody tr:hover td {
  background-color: rgba(255, 255, 255, 0.02);
}

.matrix-table tbody tr:hover .col-feature,
.matrix-table tbody tr:hover th.col-feature {
  background-color: var(--surface);
}

.matrix-table tbody tr:hover .col-dataslate {
  background-color: rgba(212, 168, 67, 0.09);
}

.matrix-footnote {
  margin-top: 16px;
  font-size: 0.78rem;
  color: var(--text-tertiary);
  line-height: 1.5;
}

.matrix-sources {
  margin: 10px 0 0;
  padding: 0;
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 6px 18px;
  font-size: 0.76rem;
  color: var(--text-tertiary);
}

.matrix-sources a {
  color: var(--accent-text);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.matrix-sources a:hover {
  color: var(--text);
}

/* ── Decision Guide ── */
.decision-section {
  padding: clamp(36px, 4vw, 56px) 0 0;
}

.decision-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
}

@media (min-width: 820px) {
  .decision-grid {
    grid-template-columns: 1.1fr 0.9fr;
    align-items: stretch;
  }
}

.decision-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: clamp(22px, 3vw, 30px);
}

.decision-card--dataslate {
  border-color: var(--accent);
  background: var(--surface-elevated);
}

.decision-label {
  display: block;
  font-family: var(--font-heading);
  font-size: 0.86rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent-text);
  margin-bottom: 14px;
}

.decision-card ul {
  list-style: none;
  margin: 0 0 12px;
  padding: 0;
  display: grid;
  gap: 10px;
}

.decision-card li {
  position: relative;
  padding-left: 22px;
  color: var(--text-secondary);
  font-size: 0.92rem;
  line-height: 1.5;
}

.decision-card--dataslate li {
  color: var(--text);
}

.decision-card li::before {
  content: '✓';
  position: absolute;
  left: 0;
  color: var(--accent-text);
  font-weight: 700;
}

.decision-card:not(.decision-card--dataslate) li::before {
  content: '›';
}

.decision-note {
  margin: 4px 0 0;
  font-size: 0.76rem;
  color: var(--text-secondary);
  line-height: 1.5;
}

@media (max-width: 768px) {
  .matrix-table {
    min-width: 760px;
    font-size: 0.82rem;
  }

  .matrix-table th,
  .matrix-table td {
    padding: 10px 8px;
  }

  .matrix-table thead th {
    padding: 14px 8px;
    font-size: 0.88rem;
  }

  .matrix-table .col-feature {
    width: 135px;
    min-width: 120px;
    font-size: 0.8rem;
    padding: 10px 8px;
  }

  .matrix-table .matrix-detail {
    font-size: 0.72rem;
  }
}

.matrix-table .icon-yes {
  color: var(--accent-text);
  font-weight: 700;
  font-size: 1.15rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
}

.matrix-table .icon-no {
  color: var(--text-tertiary);
  font-size: 1.1rem;
}

.matrix-table .matrix-detail {
  display: block;
  font-size: 0.76rem;
  font-weight: 400;
  color: var(--text-secondary);
  margin-top: 3px;
}

/* ── Deep Dive Guides ── */
.guides-section {
  padding: clamp(48px, 6vw, 80px) 0;
  background: var(--bg-secondary);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.guides-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 28px;
  margin-top: 40px;
}

@media (min-width: 900px) {
  .guides-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

.guide-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: clamp(24px, 3vw, 32px);
  display: flex;
  flex-direction: column;
  transition: border-color 0.2s ease, transform 0.2s ease;
}

.guide-card:hover {
  border-color: var(--accent);
  transform: translateY(-2px);
}

.guide-badge {
  display: inline-block;
  align-self: flex-start;
  font-family: var(--font-heading);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent-text);
  background: var(--primary-light);
  border: 1px solid var(--accent-light);
  padding: 3px 8px;
  border-radius: var(--radius);
  margin-bottom: 16px;
}

.guide-card h3 {
  font-family: var(--font-heading);
  font-size: 1.35rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  margin: 0 0 12px;
  color: var(--text);
}

.guide-card .guide-lead {
  color: var(--text-secondary);
  font-size: 0.96rem;
  line-height: 1.6;
  margin-bottom: 20px;
}

.guide-breakdown {
  display: grid;
  gap: 16px;
  border-top: 1px solid var(--border);
  padding-top: 18px;
  margin-top: auto;
}

.guide-point {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.guide-point-label {
  font-family: var(--font-heading);
  font-size: 0.82rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.guide-point-label--pain {
  color: var(--danger);
}

.guide-point-label--solution {
  color: var(--accent-text);
}

.guide-point-label--exit {
  color: var(--text-secondary);
}

.guide-point p {
  color: var(--text-secondary);
  font-size: 0.88rem;
  line-height: 1.5;
  margin: 0;
}

/* ── FAQ on Compare ── */
.compare-faq-section {
  padding: clamp(48px, 6vw, 80px) 0;
}

/* ── Bottom Call to Action ── */
.compare-cta-section {
  padding: clamp(48px, 6vw, 80px) 0;
  background: var(--bg-secondary);
  border-top: 1px solid var(--border);
  text-align: center;
}

.compare-cta-inner {
  max-width: 680px;
  margin: 0 auto;
}

.compare-cta-inner h2 {
  font-family: var(--font-heading);
  font-size: clamp(1.8rem, 3.5vw, 2.6rem);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 14px;
  color: var(--text);
}

.compare-cta-inner p {
  color: var(--text-secondary);
  font-size: 1.05rem;
  line-height: 1.6;
  margin-bottom: 28px;
}

.compare-cta-buttons {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
}
