/* Bring Radar's intelligence to your existing stack */

.ent-stack {
  --ent-stack-border: #e3e8ee;
  --ent-stack-text: #0a2540;
  --ent-stack-text-soft: #425466;
  --ent-stack-text-muted: #697386;
  --ent-stack-brand: #635bff;
  --ent-stack-chart-success: #ffb6e1;
  --ent-stack-chart-failed: #f03eb5;
  --ent-stack-ui-stroke: rgba(10, 37, 64, 0.08);
  --icon-gradient-start: #7a73ff;
  --icon-gradient-middle: #e0218a;
  --icon-gradient-end: #ff6a00;
  --browser-graphic-dots-color: rgba(163, 174, 190, 0.55);
  --hds-color-util-neutral-500: #697386;
  --hds-color-util-neutral-600: #425466;
  --hds-color-util-neutral-0: #fff;

  background: #fff;
  color: var(--ent-stack-text);
  font-family: sohne-var, Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  padding-block: clamp(2.5rem, 5vw, 4.5rem);
  overflow-x: clip;
}


.ent-stack__header {
  max-width: min(58.333%, 46rem);
  margin-bottom: clamp(2rem, 4vw, 3rem);
}

@media (max-width: 939px) {
  .ent-stack__header {
    max-width: 100%;
  }
}

.ent-stack__title {
  margin: 0;
  font-size: clamp(1.375rem, 2.4vw, 1.75rem);
  line-height: 1.25;
  letter-spacing: -0.02em;
  text-wrap: pretty;
}

.ent-stack__title-main {
  display: inline;
  font-weight: 500;
  color: var(--ent-stack-text);
}

.ent-stack__title-main::after {
  content: "\0020";
}

.ent-stack__title-sub {
  display: inline;
  font-weight: 300;
  color: var(--ent-stack-text-soft);
}

.ent-stack__body {
  display: flex;
  flex-direction: column;
  gap: clamp(2rem, 4vw, 3rem);
  padding-bottom: clamp(1.5rem, 3vw, 2.5rem);
}

@media (max-width: 639px) {
  .ent-stack__graphic {
    order: 1;
  }

  .ent-stack__features {
    order: 2;
  }
}

.ent-stack__features {
  display: grid;
  grid-template-columns: 1fr;
  gap: clamp(1.5rem, 3vw, 2rem);
}

@media (min-width: 640px) {
  .ent-stack__features {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: clamp(2rem, 4vw, 3rem);
  }
}

.ent-stack__feature {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.ent-stack__feature-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border: 1px solid var(--ent-stack-border);
  border-radius: 8px;
  background: #fff;
  flex-shrink: 0;
}

.ent-stack__feature-icon svg {
  display: block;
  width: 24px;
  height: 24px;
}

.ent-stack__feature-copy {
  display: block;
}

.ent-stack__feature-title {
  display: inline;
  margin: 0;
  font-size: 1rem;
  font-weight: 500;
  line-height: 1.5;
  color: var(--ent-stack-text);
}

.ent-stack__feature-title::after {
  content: "\0020";
}

.ent-stack__feature-desc {
  display: inline;
  margin: 0;
  font-size: 1rem;
  font-weight: 300;
  line-height: 1.5;
  color: var(--ent-stack-text-muted);
}

/* ── Gradient graphic shell ── */

.ent-stack__graphic {
  position: relative;
  width: 100%;
  border-radius: 12px;
  overflow: hidden;
  aspect-ratio: 368 / 432;
}

@media (min-width: 640px) {
  .ent-stack__graphic {
    aspect-ratio: 1232 / 608;
  }
}

.ent-stack__graphic-bg {
  position: absolute;
  inset: 0;
  display: block;
  margin: 0;
  pointer-events: none;
}

.ent-stack__graphic-bg img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

.ent-stack__graphic-fg {
  position: absolute;
  inset: 0;
  z-index: 1;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: 20px 0 10px;
  box-sizing: border-box;
  pointer-events: none;
}

.ent-stack__graphic-fg .dom-graphic {
  width: min(calc(100% - 120px), calc((100% - 30px) * 1024 / 749));
  max-height: calc(100% - 10px);
  aspect-ratio: 1024 / 749;
  height: auto;
  container-type: inline-size;
  position: relative;
  flex-shrink: 0;
  margin-left: 80px;
  margin-right: 40px;
  pointer-events: auto;
}

.ent-stack__graphic-fg .dom-graphic__content {
  position: absolute;
  top: 0;
  left: 0;
  width: 1024px;
  height: 749px;
  transform: scale(calc(100cqw / 1024));
  transform-origin: top left;
}


.ent-stack .browser-graphic {
  position: relative;
  width: 1024px;
  height: 749px;
}

@media (max-width: 639px) {
  .ent-stack .browser-graphic {
    width: 100%;
    height: auto;
  }

  .ent-stack .browser-graphic__window {
    display: none;
  }

  .ent-stack .browser-graphic__page {
    position: relative;
    inset: auto;
    border-radius: 10px;
    box-shadow: 0 14px 40px rgba(10, 37, 64, 0.14);
    overflow: hidden;
  }
}

.ent-stack .browser-graphic__window {
  position: absolute;
  inset: 0;
  border-radius: 8px;
  outline: 1px solid var(--ent-stack-ui-stroke);
  background: rgba(248, 250, 253, 0.45);
  box-shadow: 0 15px 35px rgba(10, 37, 64, 0.08);
  backdrop-filter: blur(12px);
}

.ent-stack .browser-graphic__window-top-bar {
  height: 35px;
  display: grid;
  grid-template-columns: 32px 1fr 32px;
  padding: 2px 20px;
  gap: 14px;
  align-items: center;
}

.ent-stack .browser-graphic__url-box {
  justify-self: center;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  width: min(262px, 100%);
  height: 20px;
  padding: 2px 8px;
  border-radius: 16px;
  outline: 1px solid var(--ent-stack-ui-stroke);
  background: rgba(255, 255, 255, 0.38);
  color: var(--ent-stack-text-muted);
  font-size: 9px;
  line-height: 1;
}

.ent-stack .browser-graphic__url-box-content {
  display: flex;
  align-items: center;
  gap: 4px;
}

.ent-stack .browser-graphic__page {
  position: absolute;
  inset: 35px 6px 6px;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 3px 6px rgba(10, 37, 64, 0.06);
  overflow: hidden;
}

/* ── Dashboard graphic ── */

.ent-stack .business-graphic {
  display: flex;
  width: 100%;
  height: 100%;
  font-size: 9px;
  font-weight: 400;
  line-height: 1.35;
  color: var(--ent-stack-text);
}

.ent-stack .business-graphic--mobile {
  display: none;
  height: 100%;
}

@media (max-width: 639px) {
  .ent-stack .browser-graphic__page > .business-graphic:not(.business-graphic--mobile) {
    display: none;
  }

  .ent-stack .business-graphic--mobile {
    display: block;
  }
}

.ent-stack .business-graphic__sidebar {
  width: 154px;
  flex-shrink: 0;
  padding: 14px 10px;
  border-right: 1px solid var(--ent-stack-border);
  background: #f6f9fc;
  overflow: hidden;
}

.ent-stack .business-graphic__account {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 10px;
}

.ent-stack .business-graphic__account-logo {
  flex-shrink: 0;
}

.ent-stack .business-graphic__account-name {
  font-size: 9px;
  font-weight: 500;
  color: var(--ent-stack-text);
  white-space: nowrap;
}

.ent-stack .business-graphic__nav {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.ent-stack .business-graphic__nav-group {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.ent-stack .business-graphic__nav-section-label {
  padding: 4px 6px 2px;
  font-size: 8px;
  font-weight: 500;
  color: var(--ent-stack-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.ent-stack .business-graphic__nav-group-trigger {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 4px;
}

.ent-stack .business-graphic__nav-item {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 3px 6px;
  border-radius: 4px;
  color: var(--ent-stack-text-muted);
  white-space: nowrap;
}

.ent-stack .business-graphic__nav-item--sub {
  padding-left: 18px;
  font-size: 8.5px;
}

.ent-stack .business-graphic__nav-item--active {
  color: var(--ent-stack-brand);
  font-weight: 500;
}

.ent-stack .business-graphic__nav-icon {
  display: inline-flex;
  flex-shrink: 0;
}

.ent-stack .business-graphic__chevron {
  display: inline-flex;
  flex-shrink: 0;
  opacity: 0.7;
}

.ent-stack .business-graphic__main {
  flex: 1;
  min-width: 0;
  padding: 14px 16px 12px;
  overflow: hidden;
}

.ent-stack .business-graphic__page-header {
  margin-bottom: 12px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--ent-stack-border);
}

.ent-stack .business-graphic__title {
  margin-bottom: 8px;
  font-size: 18px;
  font-weight: 600;
  line-height: 1.1;
  letter-spacing: -0.02em;
}

.ent-stack .business-graphic__tabs {
  display: flex;
  flex-wrap: nowrap;
  gap: 14px;
  overflow-x: auto;
  scrollbar-width: none;
}

.ent-stack .business-graphic__tabs::-webkit-scrollbar {
  display: none;
}

.ent-stack .business-graphic__tab {
  flex-shrink: 0;
  padding-bottom: 8px;
  font-size: 10px;
  color: var(--ent-stack-text-muted);
  border-bottom: 2px solid transparent;
}

.ent-stack .business-graphic__tab--active {
  color: var(--ent-stack-brand);
  border-bottom-color: var(--ent-stack-brand);
}

.ent-stack .business-graphic__columns {
  display: flex;
  gap: 18px;
}

.ent-stack .business-graphic__left-col {
  flex: 0 0 60%;
  width: 60%;
  max-width: 60%;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.ent-stack .business-graphic__right-col {
  flex: 0 0 40%;
  width: 40%;
  max-width: 40%;
  padding-top: 2px;
}

@media (max-width: 639px) {
  .ent-stack .business-graphic__right-col {
    display: none;
  }

  .ent-stack .business-graphic__main {
    padding: 14px 14px 10px;
  }

  .ent-stack .business-graphic__title {
    font-size: 17px;
  }

  .ent-stack .business-graphic__tabs {
    gap: 12px;
  }

  .ent-stack .business-graphic__tab {
    font-size: 9px;
  }

  .ent-stack .business-graphic__stat-value {
    font-size: 15px;
  }
}

.ent-stack .business-graphic__section-title {
  margin-bottom: 4px;
  font-size: 11px;
  font-weight: 600;
  line-height: 1.3;
}

.ent-stack .business-graphic__section-desc {
  font-size: 9px;
  line-height: 1.45;
  color: var(--ent-stack-text-muted);
}

.ent-stack .business-graphic__section-desc-link {
  color: var(--ent-stack-brand);
}

.ent-stack .business-graphic__stat-cards {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.ent-stack .business-graphic__stat-card {
  padding: 10px 12px;
  border: 1px solid var(--ent-stack-border);
  border-radius: 6px;
  background: #fff;
}

.ent-stack .business-graphic__stat-card--selected {
  border-color: var(--ent-stack-brand);
  box-shadow: inset 0 2px 0 0 var(--ent-stack-brand);
}

.ent-stack .business-graphic__stat-card--selected .business-graphic__stat-label {
  color: var(--ent-stack-brand);
  font-weight: 500;
}

.ent-stack .business-graphic__stat-label {
  margin-bottom: 4px;
  font-size: 9px;
  color: var(--ent-stack-text-muted);
}

.ent-stack .business-graphic__stat-value {
  font-size: 16px;
  font-weight: 600;
  line-height: 1;
  letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
}

.ent-stack .business-graphic__chart-area {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 28px;
  gap: 8px;
  align-items: stretch;
}

.ent-stack .business-graphic__chart {
  position: relative;
  min-height: 175px;
  padding-top: 8px;
  padding-bottom: 28px;
  overflow: visible;
}

.ent-stack .business-graphic__gridlines {
  position: absolute;
  inset: 8px 0 28px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  pointer-events: none;
}

.ent-stack .business-graphic__gridline {
  height: 1px;
  background: var(--ent-stack-border);
}

.ent-stack .business-graphic__bars {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 28px;
  z-index: 1;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px;
  height: 131px;
  padding: 0 8px;
  overflow: visible;
}

.ent-stack .business-graphic__bar-col {
  position: relative;
  display: flex;
  flex: 1 1 0;
  flex-direction: column;
  align-items: stretch;
  justify-content: flex-end;
  min-width: 0;
  max-width: 72px;
  height: 131px;
  gap: 0;
  overflow: visible;
}

.ent-stack .business-graphic__bar-segment {
  width: 100%;
  max-width: none;
  border-radius: 3px 3px 0 0;
}

/* DOM order: failed then success — flex-end stacks success on bottom, failed on top */
.ent-stack .business-graphic__bar-segment--success {
  background: var(--ent-stack-chart-success);
}

.ent-stack .business-graphic__bar-segment--failed {
  background: var(--ent-stack-chart-failed);
}

.ent-stack .business-graphic__x-label {
  position: absolute;
  top: auto;
  bottom: -26px;
  left: 50%;
  transform: translateX(-50%);
  font-size: 8px;
  line-height: 1;
  color: var(--ent-stack-text-muted);
  white-space: nowrap;
  pointer-events: none;
}

.ent-stack .business-graphic__y-axis {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 8px 0 28px;
  text-align: right;
}

.ent-stack .business-graphic__y-label {
  font-size: 8px;
  color: var(--ent-stack-text-muted);
  font-variant-numeric: tabular-nums;
}

.ent-stack .business-graphic__legend {
  display: flex;
  flex-direction: column;
  border-top: 1px solid var(--ent-stack-border);
}

.ent-stack .business-graphic__legend-row {
  display: grid;
  grid-template-columns: 1fr auto auto;
  align-items: center;
  gap: 8px;
  padding: 8px 0;
  border-bottom: 1px solid var(--ent-stack-border);
}

.ent-stack .business-graphic__legend-row:last-child {
  border-bottom: 0;
}

.ent-stack .business-graphic__legend-key {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.ent-stack .business-graphic__legend-swatch {
  width: 10px;
  height: 10px;
  border-radius: 2px;
  flex-shrink: 0;
}

.ent-stack .business-graphic__legend-swatch--success {
  background: var(--ent-stack-chart-success);
}

.ent-stack .business-graphic__legend-swatch--failed {
  background: var(--ent-stack-chart-failed);
}

.ent-stack .business-graphic__legend-label {
  font-size: 9px;
  color: var(--ent-stack-text);
}

.ent-stack .business-graphic__legend-value {
  font-size: 9px;
  font-weight: 500;
  font-variant-numeric: tabular-nums;
}

.ent-stack .business-graphic__legend-arrow {
  display: inline-flex;
  opacity: 0.55;
}

.ent-stack .business-graphic__resources-title {
  margin-bottom: 8px;
  font-size: 9px;
  font-weight: 600;
  color: var(--ent-stack-text-muted);
}

.ent-stack .business-graphic__resource-item {
  display: flex;
  gap: 8px;
  align-items: flex-start;
  padding: 8px;
  border: 1px solid var(--ent-stack-border);
  border-radius: 6px;
  background: #fff;
}

.ent-stack .business-graphic__resource-icon {
  flex-shrink: 0;
}

.ent-stack .business-graphic__resource-name {
  font-size: 9px;
  font-weight: 500;
  color: var(--ent-stack-brand);
}

.ent-stack .business-graphic__resource-desc {
  margin-top: 2px;
  font-size: 8px;
  line-height: 1.35;
  color: var(--ent-stack-text-muted);
}

.ent-stack .tabular-nums--tight {
  font-variant-numeric: tabular-nums;
}
