.floating-contacts {
  --fc-accent: var(--accent, #00ff41);
  --fc-accent-on: var(--accent-on, #06101d);
  --fc-bg: var(--surface, #121722);
  --fc-page-bg: var(--bg, #090b12);
  --fc-fg: var(--fg, #f8fafc);
  --fc-muted: var(--muted, #94a3b8);
  --fc-border: var(--border, #2a3447);
  position: fixed;
  right: max(24px, env(safe-area-inset-right));
  bottom: max(24px, env(safe-area-inset-bottom));
  z-index: 1000;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 12px;
  font-family: var(--font-body, "IBM Plex Mono", ui-monospace, monospace);
}

.floating-contacts-toggle {
  width: 56px;
  height: 56px;
  flex: 0 0 56px;
  display: grid;
  place-items: center;
  padding: 0;
  border: 2px solid var(--fc-accent);
  border-radius: 50%;
  background: var(--fc-bg);
  color: var(--fc-accent);
  cursor: pointer;
  box-shadow: 0 4px 24px rgba(0, 255, 65, 0.15);
  transition: color 180ms cubic-bezier(0.2, 0, 0, 1), background 180ms cubic-bezier(0.2, 0, 0, 1), box-shadow 180ms cubic-bezier(0.2, 0, 0, 1), transform 180ms cubic-bezier(0.2, 0, 0, 1);
}

.floating-contacts-toggle:hover,
.floating-contacts-toggle:focus-visible {
  background: var(--fc-accent);
  color: var(--fc-accent-on);
  box-shadow: 0 4px 32px rgba(0, 255, 65, 0.3);
  outline: none;
  transform: scale(1.06);
}

.floating-contacts-toggle svg {
  width: 24px;
  height: 24px;
  pointer-events: none;
}

.floating-contacts-list {
  display: none;
  min-width: 188px;
  max-width: min(280px, calc(100vw - 32px));
  flex-direction: column;
  gap: 8px;
  padding: 12px;
  border: 1px solid var(--fc-border);
  border-radius: 10px;
  background: var(--fc-bg);
  box-shadow: 0 24px 72px rgba(0, 0, 0, 0.42);
}

.floating-contacts.open .floating-contacts-list {
  display: flex;
}

.floating-contacts.open .floating-contacts-toggle {
  transform: rotate(45deg);
}

.floating-contacts .fc-item {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 56px;
  padding: 10px 12px;
  border: 1px solid transparent;
  border-radius: 8px;
  color: var(--fc-fg);
  text-decoration: none;
  transition: border-color 100ms ease, background 100ms ease, transform 180ms cubic-bezier(0.2, 0, 0, 1);
}

.floating-contacts .fc-item:hover,
.floating-contacts .fc-item:focus-visible {
  border-color: var(--fc-accent);
  background: var(--fc-page-bg);
  outline: none;
  transform: translateX(-3px);
}

.floating-contacts .fc-icon {
  width: 36px;
  height: 36px;
  flex: 0 0 36px;
  display: grid;
  place-items: center;
  border-radius: 8px;
}

.floating-contacts .fc-icon svg {
  width: 20px;
  height: 20px;
}

.floating-contacts .fc-copy {
  min-width: 0;
}

.floating-contacts .fc-label,
.floating-contacts .fc-value {
  display: block;
  overflow-wrap: anywhere;
}

.floating-contacts .fc-label {
  color: var(--fc-fg);
  font-size: 12px;
  font-weight: 700;
  line-height: 1.35;
}

.floating-contacts .fc-value {
  margin-top: 2px;
  color: var(--fc-muted);
  font-size: 11px;
  line-height: 1.35;
}

@media (max-width: 520px) {
  .floating-contacts {
    right: max(16px, env(safe-area-inset-right));
    bottom: max(16px, env(safe-area-inset-bottom));
  }

  .floating-contacts-toggle {
    width: 48px;
    height: 48px;
    flex-basis: 48px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .floating-contacts-toggle,
  .floating-contacts .fc-item {
    transition: none;
  }
}
