/*
 * ═══════════════════════════════════════════════════════════════
 *  LM Websolutions — Leistungen Page
 *  leistungen.css — Orbital services diagram + page-specific styles
 * ═══════════════════════════════════════════════════════════════
 */

/* ── Section wrapper ─────────────────────────────────────────── */
.ls-section {
  background: var(--bg);
  padding: 60px 0 140px;
}

/* ═══════════════════════════════════════════════════════════════
   ORBITAL DIAGRAM (desktop ≥ 769px)
   ═══════════════════════════════════════════════════════════════ */

.ls-orbital-outer {
  position: relative;
  width: 100%;
  max-width: 820px;
  height: 780px;
  margin: 0 auto;
  user-select: none;
}

/* SVG overlay for connection lines */
.ls-orbital-svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  overflow: visible;
}

/* Orbit ring (sized by JS) */
.ls-orbit-ring {
  position: absolute;
  border-radius: 50%;
  border: 1px solid rgba(10, 10, 10, 0.07);
  pointer-events: none;
  transition: none;
}

/* ── Center circle ───────────────────────────────────────────── */
.ls-center {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 156px;
  height: 156px;
  border-radius: 50%;
  background: var(--navy);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  z-index: 10;
  box-shadow: 0 4px 48px rgba(15, 31, 68, 0.28), 0 0 0 1px rgba(15, 31, 68, 0.12);
}

/* Subtle outer pulse ring */
.ls-center-pulse {
  position: absolute;
  inset: -10px;
  border-radius: 50%;
  border: 1px solid rgba(15, 31, 68, 0.12);
  animation: ls-pulse-ring 3.5s ease-in-out infinite;
  pointer-events: none;
}

@keyframes ls-pulse-ring {
  0%, 100% { transform: scale(1); opacity: 0.6; }
  50%       { transform: scale(1.06); opacity: 0.2; }
}

.ls-center-text {
  font-family: var(--font-heading);
  font-size: 14.5px;
  font-weight: 700;
  color: #ffffff;
  line-height: 1.3;
  letter-spacing: -0.01em;
}

.ls-center-brand {
  display: block;
  font-family: var(--font-sans);
  font-size: 9px;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.38);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  margin-top: 5px;
}

/* ── Orbital nodes ───────────────────────────────────────────── */
.ls-node {
  position: absolute;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
  transform: translate(-50%, -50%);
  z-index: 5;
  outline: none;
  transition: none; /* position managed by JS */
}

.ls-node-icon {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: #ffffff;
  border: 1.5px solid rgba(10, 10, 10, 0.09);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--navy);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
  transition: background 0.28s ease, border-color 0.28s ease,
              color 0.28s ease, box-shadow 0.28s ease, transform 0.28s ease;
  flex-shrink: 0;
}

.ls-node:hover .ls-node-icon,
.ls-node.ls-active .ls-node-icon {
  background: var(--navy);
  border-color: var(--navy);
  color: #ffffff;
  box-shadow: 0 6px 22px rgba(15, 31, 68, 0.28);
  transform: scale(1.1);
}

.ls-node-label {
  font-family: var(--font-heading);
  font-size: 12.5px;
  font-weight: 600;
  color: rgba(10, 10, 10, 0.5);
  text-align: center;
  line-height: 1.35;
  pointer-events: none;
  transition: color 0.28s ease;
  max-width: 140px;
  white-space: normal;
}

.ls-node:hover .ls-node-label,
.ls-node.ls-active .ls-node-label {
  color: var(--navy);
}

/* ── Popup card ──────────────────────────────────────────────── */
.ls-popup {
  position: absolute;
  background: #ffffff;
  border: 1.5px solid rgba(10, 10, 10, 0.08);
  border-radius: 14px;
  padding: 20px 22px 22px;
  width: 220px;
  box-shadow: 0 8px 40px rgba(0, 0, 0, 0.11), 0 2px 10px rgba(0, 0, 0, 0.06);
  z-index: 30;
  pointer-events: auto;
  opacity: 0;
  transform: scale(0.93) translateY(8px);
  transition: opacity 0.22s ease, transform 0.22s ease;
}

.ls-popup:not([hidden]) {
  display: block;
}

.ls-popup[hidden] {
  display: none;
}

.ls-popup.ls-popup-visible {
  opacity: 1;
  transform: scale(1) translateY(0);
}

.ls-popup-tag {
  display: inline-block;
  font-size: 9.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--accent);
  margin-bottom: 9px;
}

.ls-popup-title {
  font-family: var(--font-heading);
  font-size: 14.5px;
  font-weight: 700;
  color: var(--navy);
  letter-spacing: -0.02em;
  line-height: 1.25;
  margin-bottom: 8px;
}

.ls-popup-desc {
  font-size: 13px;
  line-height: 1.6;
  color: rgba(10, 10, 10, 0.48);
  margin-bottom: 16px;
}

.ls-popup-link {
  font-family: var(--font-heading);
  font-size: 13px;
  font-weight: 600;
  color: var(--navy);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  transition: gap 0.2s, color 0.2s;
}

.ls-popup-link:hover {
  gap: 9px;
  color: var(--accent);
}

/* Connector dot between popup and node */
.ls-popup::before {
  content: '';
  position: absolute;
  width: 6px;
  height: 6px;
  background: var(--navy);
  border-radius: 50%;
}

/* ═══════════════════════════════════════════════════════════════
   MOBILE CARD GRID (≤ 768px)
   ═══════════════════════════════════════════════════════════════ */

.ls-mobile-grid {
  display: none;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.ls-mobile-card {
  background: #ffffff;
  border: 1.5px solid rgba(10, 10, 10, 0.08);
  border-radius: 14px;
  padding: 22px 18px 20px;
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
  gap: 10px;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.04);
  transition: box-shadow 0.25s ease, transform 0.25s ease, border-color 0.25s ease;
  position: relative;
  overflow: hidden;
}

.ls-mobile-card:hover {
  box-shadow: 0 6px 24px rgba(0, 0, 0, 0.09);
  transform: translateY(-3px);
  border-color: rgba(15, 31, 68, 0.15);
}

.ls-mc-icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: rgba(15, 31, 68, 0.06);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--navy);
  transition: background 0.25s;
}

.ls-mobile-card:hover .ls-mc-icon {
  background: var(--navy);
  color: #ffffff;
}

.ls-mc-num {
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: rgba(10, 10, 10, 0.32);
}

.ls-mc-title {
  font-family: var(--font-heading);
  font-size: 14px;
  font-weight: 700;
  color: var(--navy);
  letter-spacing: -0.02em;
  line-height: 1.3;
}

.ls-mc-tag {
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--accent);
  margin-top: auto;
}

.ls-mc-arrow {
  position: absolute;
  top: 20px;
  right: 18px;
  font-size: 14px;
  color: rgba(10, 10, 10, 0.2);
  transition: color 0.2s, transform 0.2s;
}

.ls-mobile-card:hover .ls-mc-arrow {
  color: var(--navy);
  transform: translateX(3px);
}

/* Last card spans full width on odd count (5 items = 2+2+1) */
.ls-mobile-card:last-child:nth-child(odd) {
  grid-column: 1 / -1;
  max-width: calc(50% - 7px);
}

/* ═══════════════════════════════════════════════════════════════
   RESPONSIVE
   ═══════════════════════════════════════════════════════════════ */

@media (max-width: 900px) {
  .ls-orbital-outer { display: none; }
  .ls-mobile-grid { display: grid; }
  .ls-section { padding: 40px 0 80px; }
}

@media (max-width: 440px) {
  .ls-mobile-grid { grid-template-columns: 1fr; }
  .ls-mobile-card:last-child:nth-child(odd) {
    grid-column: auto;
    max-width: 100%;
  }
}
