/* ═══════════════════════════════════════════════
   SERASMAC v2 — How It Works
   ═══════════════════════════════════════════════ */

/* ── Proof strip ── */
.sm-hiw-proof-strip {
  display: flex;
  justify-content: center;
  gap: var(--sm-space-10);
  flex-wrap: wrap;
  padding: var(--sm-space-5) 0;
  border-top: 1px solid var(--sm-line);
  border-bottom: 1px solid var(--sm-line);
}

.sm-hiw-proof-item {
  display: flex;
  align-items: center;
  gap: var(--sm-space-3);
  font-size: var(--sm-text-sm);
  font-weight: 600;
  color: var(--sm-ink-soft);
}

.sm-hiw-proof-item .sm-icon {
  width: 20px;
  height: 20px;
  color: var(--sm-teal);
  flex-shrink: 0;
}

/* ── Principles ── */
.sm-hiw-principles-header {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--sm-space-12);
  align-items: start;
  margin-bottom: var(--sm-space-12);
}

.sm-hiw-principles-header h2 {
  margin-top: var(--sm-space-4);
}

.sm-hiw-principles-desc {
  font-size: var(--sm-text-md);
  color: var(--sm-ink-soft);
  line-height: var(--sm-leading-relaxed);
  padding-top: var(--sm-space-2);
}

.sm-hiw-principles-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--sm-space-6);
}

.sm-hiw-principle-num {
  display: block;
  font-family: var(--sm-font-display);
  font-size: var(--sm-text-3xl);
  font-weight: 700;
  color: var(--sm-teal);
  line-height: 1;
  margin-bottom: var(--sm-space-4);
}

.sm-hiw-principle-title {
  font-size: var(--sm-text-lg);
  margin-bottom: var(--sm-space-3);
}

.sm-hiw-principle-text {
  font-size: var(--sm-text-sm);
  color: var(--sm-ink-soft);
  line-height: var(--sm-leading-relaxed);
}

/* ── Journey header ── */
.sm-hiw-journey-header {
  max-width: 640px;
  margin-bottom: var(--sm-space-12);
}

.sm-hiw-journey-header h2 {
  margin-top: var(--sm-space-4);
  margin-bottom: var(--sm-space-4);
}

.sm-hiw-journey-header p {
  font-size: var(--sm-text-md);
  color: var(--sm-ink-soft);
  line-height: var(--sm-leading-relaxed);
}

/* ── Journey layout: rail + steps ── */
.sm-hiw-journey {
  display: grid;
  grid-template-columns: 260px 1fr;
  gap: var(--sm-space-12);
  align-items: start;
}

/* ── Sticky rail (left) ── */
.sm-hiw-rail {
  position: sticky;
  top: calc(var(--sm-space-8) + 100px);
}

.sm-hiw-rail__track {
  display: flex;
  flex-direction: column;
  gap: var(--sm-space-1);
}

.sm-hiw-rail__link {
  display: flex;
  align-items: center;
  gap: var(--sm-space-3);
  padding: var(--sm-space-3) var(--sm-space-4);
  border-radius: var(--sm-radius-md);
  text-decoration: none;
  color: var(--sm-ink-muted);
  font-size: var(--sm-text-sm);
  font-weight: 500;
  transition: all var(--sm-duration-normal) var(--sm-ease-out);
  border-left: 2px solid transparent;
}

.sm-hiw-rail__link:hover,
.sm-hiw-rail__link.is-active {
  color: var(--sm-teal);
  background: rgba(12, 110, 115, 0.04);
  border-left-color: var(--sm-teal);
}

.sm-hiw-rail__num {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: var(--sm-text-xs);
  font-weight: 700;
  border: 1.5px solid var(--sm-line);
  flex-shrink: 0;
  transition: all var(--sm-duration-normal) var(--sm-ease-out);
}

.sm-hiw-rail__link:hover .sm-hiw-rail__num,
.sm-hiw-rail__link.is-active .sm-hiw-rail__num {
  border-color: var(--sm-teal);
  color: var(--sm-teal);
  background: rgba(12, 110, 115, 0.06);
}

.sm-hiw-rail__label {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ── Steps (right) ── */
.sm-hiw-steps {
  display: flex;
  flex-direction: column;
  gap: var(--sm-space-8);
}

.sm-hiw-step {
  background: var(--sm-surface);
  border: 1px solid var(--sm-line);
  border-radius: var(--sm-radius-lg);
  padding: var(--sm-space-8);
  transition: border-color var(--sm-duration-normal) var(--sm-ease-out),
              box-shadow var(--sm-duration-normal) var(--sm-ease-out);
}

.sm-hiw-step:hover {
  border-color: var(--sm-line-strong);
  box-shadow: var(--sm-shadow-sm);
}

/* Step head */
.sm-hiw-step__head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--sm-space-4);
  margin-bottom: var(--sm-space-5);
  padding-bottom: var(--sm-space-5);
  border-bottom: 1px solid var(--sm-line);
}

.sm-hiw-step__head-main {
  display: flex;
  align-items: flex-start;
  gap: var(--sm-space-4);
}

.sm-hiw-step__number {
  font-family: var(--sm-font-display);
  font-size: var(--sm-text-4xl);
  font-weight: 700;
  color: var(--sm-teal);
  line-height: 1;
  letter-spacing: var(--sm-tracking-tight);
  flex-shrink: 0;
}

.sm-hiw-step__phase {
  display: block;
  font-size: var(--sm-text-xs);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: var(--sm-tracking-wider);
  color: var(--sm-copper);
  margin-bottom: var(--sm-space-1);
}

.sm-hiw-step__title {
  font-size: var(--sm-text-xl);
  font-weight: 600;
  color: var(--sm-ink);
  line-height: var(--sm-leading-snug);
}

/* Summary */
.sm-hiw-step__summary {
  font-size: var(--sm-text-md);
  color: var(--sm-ink-soft);
  line-height: var(--sm-leading-relaxed);
  margin-bottom: var(--sm-space-6);
}

/* Two-column grid: customer + seras */
.sm-hiw-step__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--sm-space-4);
  margin-bottom: var(--sm-space-5);
}

.sm-hiw-step__cell {
  background: var(--sm-surface-soft);
  border-radius: var(--sm-radius-md);
  padding: var(--sm-space-5);
}

.sm-hiw-step__cell-head {
  display: flex;
  align-items: center;
  gap: var(--sm-space-2);
  margin-bottom: var(--sm-space-3);
}

.sm-hiw-step__cell-head .sm-icon {
  width: 16px;
  height: 16px;
  color: var(--sm-teal);
  flex-shrink: 0;
}

.sm-hiw-step__cell-head span {
  font-size: var(--sm-text-xs);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: var(--sm-tracking-wide);
  color: var(--sm-ink-muted);
}

.sm-hiw-step__cell p {
  font-size: var(--sm-text-sm);
  color: var(--sm-ink-soft);
  line-height: var(--sm-leading-relaxed);
}

/* Gate */
.sm-hiw-step__gate {
  background: rgba(168, 108, 61, 0.04);
  border: 1px solid rgba(168, 108, 61, 0.12);
  border-radius: var(--sm-radius-md);
  padding: var(--sm-space-4) var(--sm-space-5);
  margin-bottom: var(--sm-space-4);
}

.sm-hiw-step__gate-head {
  display: flex;
  align-items: center;
  gap: var(--sm-space-2);
  margin-bottom: var(--sm-space-2);
}

.sm-hiw-step__gate-head .sm-icon {
  width: 16px;
  height: 16px;
  color: var(--sm-copper);
  flex-shrink: 0;
}

.sm-hiw-step__gate-head strong {
  font-size: var(--sm-text-xs);
  text-transform: uppercase;
  letter-spacing: var(--sm-tracking-wide);
  color: var(--sm-copper);
}

.sm-hiw-step__gate p {
  font-size: var(--sm-text-sm);
  color: var(--sm-ink-soft);
  line-height: var(--sm-leading-relaxed);
}

/* Document indicator */
.sm-hiw-step__document {
  display: flex;
  align-items: center;
  gap: var(--sm-space-2);
  font-size: var(--sm-text-xs);
  font-weight: 600;
  color: var(--sm-ink-muted);
}

.sm-hiw-step__document .sm-icon {
  width: 14px;
  height: 14px;
  color: var(--sm-teal);
  flex-shrink: 0;
}

/* ── Documents backbone ── */
.sm-hiw-documents__intro {
  max-width: 640px;
  margin-bottom: var(--sm-space-12);
}

.sm-hiw-documents__intro h2 {
  margin-top: var(--sm-space-4);
  margin-bottom: var(--sm-space-4);
}

.sm-hiw-documents__intro p {
  font-size: var(--sm-text-md);
  color: var(--sm-ink-soft);
  line-height: var(--sm-leading-relaxed);
}

.sm-hiw-documents__list {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: var(--sm-space-4);
}

.sm-hiw-doc-card {
  background: var(--sm-surface);
  border: 1px solid var(--sm-line);
  border-radius: var(--sm-radius-lg);
  padding: var(--sm-space-6);
  display: flex;
  flex-direction: column;
  gap: var(--sm-space-4);
  transition: border-color var(--sm-duration-normal) var(--sm-ease-out),
              box-shadow var(--sm-duration-normal) var(--sm-ease-out);
}

.sm-hiw-doc-card:hover {
  border-color: var(--sm-teal);
  box-shadow: var(--sm-shadow-sm);
}

.sm-hiw-doc-card__icon {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--sm-radius-md);
  background: rgba(12, 110, 115, 0.06);
  color: var(--sm-teal);
}

.sm-hiw-doc-card__icon .sm-icon {
  width: 20px;
  height: 20px;
}

.sm-hiw-doc-card__num {
  font-family: var(--sm-font-display);
  font-size: var(--sm-text-2xl);
  font-weight: 700;
  color: var(--sm-line-strong);
  line-height: 1;
}

.sm-hiw-doc-card__title {
  font-size: var(--sm-text-md);
  font-weight: 600;
  color: var(--sm-ink);
}

.sm-hiw-doc-card__text {
  font-size: var(--sm-text-sm);
  color: var(--sm-ink-muted);
  line-height: var(--sm-leading-relaxed);
}

/* ── Offer standard ── */
.sm-hiw-offer-header {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--sm-space-12);
  align-items: start;
  margin-bottom: var(--sm-space-12);
}

.sm-hiw-offer-header h2 {
  margin-top: var(--sm-space-4);
}

.sm-hiw-offer-desc {
  font-size: var(--sm-text-md);
  color: var(--sm-ink-soft);
  line-height: var(--sm-leading-relaxed);
  padding-top: var(--sm-space-2);
}

.sm-hiw-offer-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--sm-space-6);
}

.sm-hiw-offer-card__head {
  display: flex;
  align-items: center;
  gap: var(--sm-space-3);
  margin-bottom: var(--sm-space-4);
}

.sm-hiw-offer-card__head .sm-icon {
  width: 20px;
  height: 20px;
  color: var(--sm-teal);
  flex-shrink: 0;
}

.sm-hiw-offer-card__key {
  font-size: var(--sm-text-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: var(--sm-tracking-wider);
  color: var(--sm-teal);
}

.sm-hiw-offer-card__title {
  font-size: var(--sm-text-md);
  font-weight: 600;
  color: var(--sm-ink);
  margin-bottom: var(--sm-space-3);
}

.sm-hiw-offer-card__text {
  font-size: var(--sm-text-sm);
  color: var(--sm-ink-muted);
  line-height: var(--sm-leading-relaxed);
}

/* ── Disclaimer ── */
.sm-hiw-disclaimer {
  background: var(--sm-surface-soft);
  border: 1px solid var(--sm-line);
  border-radius: var(--sm-radius-lg);
  padding: var(--sm-space-6) var(--sm-space-8);
}

.sm-hiw-disclaimer__head {
  display: flex;
  align-items: center;
  gap: var(--sm-space-3);
  margin-bottom: var(--sm-space-3);
}

.sm-hiw-disclaimer__head .sm-icon {
  width: 18px;
  height: 18px;
  color: var(--sm-copper);
  flex-shrink: 0;
}

.sm-hiw-disclaimer__head strong {
  font-size: var(--sm-text-sm);
  color: var(--sm-ink);
}

.sm-hiw-disclaimer p {
  font-size: var(--sm-text-sm);
  color: var(--sm-ink-muted);
  line-height: var(--sm-leading-relaxed);
}

/* ═══════════════════════════════════════════════
   Responsive — How It Works
   ═══════════════════════════════════════════════ */

@media (max-width: 1080px) {
  .sm-hiw-journey {
    grid-template-columns: 1fr;
    gap: var(--sm-space-6);
  }

  .sm-hiw-rail {
    position: static;
  }

  .sm-hiw-rail__track {
    flex-direction: row;
    flex-wrap: wrap;
    gap: var(--sm-space-2);
  }

  .sm-hiw-rail__link {
    border-left: none;
    border-bottom: 2px solid transparent;
    padding: var(--sm-space-2) var(--sm-space-3);
  }

  .sm-hiw-rail__link:hover,
  .sm-hiw-rail__link.is-active {
    border-left: none;
    border-bottom-color: var(--sm-teal);
  }

  .sm-hiw-principles-header,
  .sm-hiw-offer-header {
    grid-template-columns: 1fr;
    gap: var(--sm-space-4);
  }

  .sm-hiw-documents__list {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 768px) {
  .sm-hiw-proof-strip {
    flex-direction: column;
    align-items: center;
    gap: var(--sm-space-4);
  }

  .sm-hiw-principles-grid {
    grid-template-columns: 1fr;
  }

  .sm-hiw-step__grid {
    grid-template-columns: 1fr;
  }

  .sm-hiw-step__head {
    flex-direction: column;
    gap: var(--sm-space-3);
  }

  .sm-hiw-documents__list {
    grid-template-columns: 1fr;
  }

  .sm-hiw-offer-grid {
    grid-template-columns: 1fr;
  }

  .sm-hiw-step {
    padding: var(--sm-space-6);
  }
}

@media (max-width: 480px) {
  .sm-hiw-step__number {
    font-size: var(--sm-text-3xl);
  }

  .sm-hiw-rail__link {
    font-size: var(--sm-text-xs);
    padding: var(--sm-space-2);
  }

  .sm-hiw-rail__num {
    width: 28px;
    height: 28px;
    font-size: 0.7rem;
  }
}
