/* ============================================================
   Nordic Trust Services — Diagrams Stylesheet
   ============================================================ */

.diagram-wrap {
  margin-top: 3rem;
  overflow-x: auto;
}

/* ── HYBRID CLOUD DIAGRAM ── */
.diagram {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 2.5rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0;
}

.diagram__layer {
  width: 100%;
  max-width: 720px;
  border-radius: 10px;
  padding: 1.25rem 1.75rem;
  display: flex;
  align-items: center;
  gap: 1rem;
}
.diagram__layer--purple {
  background: rgba(155,114,207,0.10);
  border: 1.5px solid rgba(155,114,207,0.35);
}
.diagram__layer-icon {
  width: 40px; height: 40px;
  border-radius: 8px;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
  background: rgba(155,114,207,0.15);
  color: #9b72cf;
}
.diagram__layer--purple .diagram__layer-icon { background: rgba(155,114,207,0.15); color: #9b72cf; }
.diagram__layer-content {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}
.diagram__layer-content strong {
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--black);
}
.diagram__layer-content span {
  font-size: 0.78rem;
  color: var(--text-light);
  font-weight: 300;
}

.diagram__arrow {
  height: 32px;
  width: 2px;
  position: relative;
}
.diagram__arrow--gradient {
  background: linear-gradient(to bottom, #9b72cf, #7dd4f0);
  width: 2px;
  height: 32px;
}
.diagram__arrow--gradient::after {
  content: '';
  position: absolute;
  bottom: -5px;
  left: 50%;
  transform: translateX(-50%);
  border-left: 5px solid transparent;
  border-right: 5px solid transparent;
  border-top: 6px solid #7dd4f0;
}

.diagram__row {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
  justify-content: center;
  width: 100%;
  max-width: 800px;
}

.diagram__node {
  flex: 1;
  min-width: 130px;
  max-width: 160px;
  border-radius: 10px;
  padding: 1rem 0.85rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.4rem;
  text-align: center;
}
.diagram__node--blue {
  background: rgba(125,212,240,0.10);
  border: 1.5px solid rgba(125,212,240,0.35);
}
.diagram__node--blue-grey {
  background: rgba(112,147,160,0.10);
  border: 1.5px solid rgba(112,147,160,0.30);
}
.diagram__node-icon {
  width: 32px; height: 32px;
  border-radius: 6px;
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 0.2rem;
}
.diagram__node--blue .diagram__node-icon { background: rgba(125,212,240,0.18); color: #7dd4f0; }
.diagram__node--blue-grey .diagram__node-icon { background: rgba(112,147,160,0.18); color: #7093a0; }
.diagram__node strong { font-size: 0.78rem; font-weight: 700; color: var(--black); }
.diagram__node span { font-size: 0.7rem; color: var(--text-light); font-weight: 400; }

.diagram__benefits {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.5rem;
  justify-content: center;
  padding: 1rem 0 0;
  width: 100%;
  max-width: 720px;
  border-top: 1px solid var(--border);
  margin-top: 1rem;
}
.diagram__benefit {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--text-mid);
}

/* ── TRUST LIFECYCLE FLOW ── */
.diagram--lifecycle {
  flex-direction: row;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 0;
  padding: 2.5rem 1.5rem;
}

.lifecycle__step {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  text-align: center;
  padding: 1.5rem 1.25rem;
  border-radius: 12px;
  min-width: 140px;
  max-width: 160px;
}
.lifecycle__step--purple { background: rgba(155,114,207,0.10); border: 1.5px solid rgba(155,114,207,0.30); }
.lifecycle__step--blue   { background: rgba(125,212,240,0.10); border: 1.5px solid rgba(125,212,240,0.30); }
.lifecycle__step--green  { background: rgba(78,203,141,0.10);  border: 1.5px solid rgba(78,203,141,0.30); }
.lifecycle__step--grey   { background: var(--off-white); border: 1.5px solid var(--border); }

.lifecycle__icon {
  width: 44px; height: 44px;
  border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
}
.lifecycle__step--purple .lifecycle__icon { background: rgba(155,114,207,0.18); color: #9b72cf; }
.lifecycle__step--blue   .lifecycle__icon { background: rgba(125,212,240,0.18); color: #7dd4f0; }
.lifecycle__step--green  .lifecycle__icon { background: rgba(78,203,141,0.18);  color: #4ecb8d; }
.lifecycle__step--grey   .lifecycle__icon { background: var(--border); color: var(--text-mid); }

.lifecycle__label {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--black);
}
.lifecycle__sub {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-light);
}
.lifecycle__desc {
  font-size: 0.72rem;
  color: var(--text-mid);
  font-weight: 300;
  line-height: 1.5;
}
.lifecycle__arrow {
  display: flex;
  align-items: center;
  padding: 0 0.25rem;
  flex-shrink: 0;
}

/* ── COMPARISON TABLE ── */
.comparison-table-wrap {
  overflow-x: auto;
  margin-top: 2.5rem;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
}
.comparison-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.82rem;
  background: var(--white);
}
.comparison-table th {
  padding: 0.85rem 1rem;
  text-align: left;
  font-weight: 700;
  font-size: 0.78rem;
  color: var(--text-mid);
  background: var(--off-white);
  border-bottom: 2px solid var(--border);
  white-space: nowrap;
}
.comparison-table th.nts-col {
  background: rgba(155,114,207,0.08);
  color: #9b72cf;
}
.comparison-table td {
  padding: 0.75rem 1rem;
  border-bottom: 1px solid var(--border);
  color: var(--text-dark);
  vertical-align: middle;
}
.comparison-table tr:last-child td { border-bottom: none; }
.comparison-table tr:hover td { background: var(--off-white); }
.comparison-table td.nts-col { background: rgba(155,114,207,0.05); font-weight: 600; }
.comparison-table td.check { color: #4ecb8d; font-size: 1rem; font-weight: 700; text-align: center; }
.comparison-table td.cross { color: var(--border); font-size: 1rem; text-align: center; }
.comparison-table td.nts-col.check { color: #9b72cf; }

/* ── RESPONSIVE ── */
@media (max-width: 768px) {
  .diagram--lifecycle {
    flex-direction: column;
  }
  .lifecycle__arrow {
    transform: rotate(90deg);
  }
  .diagram__row {
    gap: 0.5rem;
  }
  .diagram__node {
    min-width: 100px;
    max-width: 130px;
  }
}
