/* Кейс 1С: схема модулей вокруг ядра (две сцены — десктоп 722×360 и мобильная 330×300) */

/* мок 1С (без названия заказчика) */
.n-at {
  position: absolute;
  width: 0;
  height: 0;
}

.node {
  position: absolute;
  transform: translate(-50%,-50%);
  display: flex;
  align-items: center;
  gap: 10px;
  height: 46px;
  padding: 0 18px 0 12px;
  border-radius: 14px;
  font-size: 13px;
  color: #EDEEF1;
  white-space: nowrap;
  border: 1px solid transparent;
  background: linear-gradient(#111217,#111217) padding-box,
    linear-gradient(135deg,rgba(255,255,255,.7),rgba(255,255,255,.1) 45%,rgba(255,255,255,.4)) border-box;
  box-shadow: 0 20px 40px -24px rgba(0,0,0,.95);
}

.node i {
  width: 22px;
  height: 22px;
  border-radius: 7px;
  background: linear-gradient(160deg,#FFFFFF,#8C919A 45%,#26282D 55%,#B6BBC3);
  flex-shrink: 0;
}

.node.core {
  height: 58px;
  padding: 0 22px 0 14px;
  font: 500 15px/1 var(--f-disp);
}

.node.core i {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: radial-gradient(circle at 34% 30%,#fff 0 10%,#FF6A2A 45%,#7A2300 100%);
  box-shadow: 0 0 16px rgba(255,77,0,.6);
}

.node small {
  display: block;
  font-size: 10px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: #7E838C;
  margin-top: 2px;
}

.flow {
  stroke-dasharray: 3 7;
  animation: flow 1.6s linear infinite;
}

@keyframes flow {
  to {
    stroke-dashoffset: -20;
  }
}

.orb-dot {
  position: absolute;
  left: 0;
  top: 0;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 12px 2px rgba(255,77,0,.8);
  offset-anchor: 50% 50%;
  offset-rotate: 0deg;
  animation: wsat 16s linear infinite;
}

.fit {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%,-50%) scale(var(--k,1));
}

/* 1С на телефоне и узком планшете — своя компактная сцена 330×300 с крупным текстом (см. адаптив ≤820) */
.fit-m {
  display: none;
}

.fit-m .node {
  height: 38px;
  gap: 8px;
  padding: 0 13px 0 9px;
  border-radius: 12px;
  font-size: 14px;
}

.fit-m .node i {
  width: 18px;
  height: 18px;
  border-radius: 6px;
}

.fit-m .node.core {
  height: auto;
  padding: 9px 16px 9px 11px;
  font-size: 14px;
  line-height: 1.2;
  white-space: nowrap;
}

.fit-m .node.core i {
  width: 24px;
  height: 24px;
  border-radius: 50%;
}

.one-c-cap {
  position: absolute;
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 11px;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: #8C919A;
  white-space: nowrap;
}

.one-c-cap::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 10px var(--accent);
  flex-shrink: 0;
}

/* фон-сетка карточки 1С */
.one-c .case-vis {
  background: linear-gradient(rgba(255,255,255,.035) 1px,transparent 1px) 0 0/100% 36px,
    linear-gradient(90deg,rgba(255,255,255,.035) 1px,transparent 1px) 0 0/72px 100%,
    radial-gradient(420px 300px at 50% 55%,rgba(255,77,0,.11),transparent 70%),
    #08090B;
}

/* размеры сцен совпадают с data-fit / data-fit-sm в разметке */
.fit-d {
  width: 722px;
  height: 360px;
}

.fit-m {
  width: 330px;
  height: 300px;
}

.fit > svg {
  position: absolute;
  left: 0;
  top: 0;
}

@media (max-width:1360px) and (min-width:1181px) {
  /* схема 1С в паре ужимается до ~0.8 — крупнее текст, чтобы подписи не падали ниже ~10px */
  .one-c .fit-d .node {
    font-size: 15px;
  }
  .one-c .fit-d .node.core {
    font-size: 17px;
  }
  .one-c .fit-d .one-c-cap {
    font-size: 12.5px;
  }
}

@media (max-width:820px) {
  /* 1С: компактная сцена 330×300 с крупным текстом — уменьшенная десктопная схема здесь слишком мелкая */
  .one-c .case-vis {
    aspect-ratio: auto;
    height: calc(300px * var(--k,1));
  }
  .one-c .fit-d {
    display: none;
  }
  .one-c .fit-m {
    display: block;
  }
}
