/* ============================================
   HRVICO — Role Switcher
   ============================================ */

.role-switcher {
  position: relative;
  overflow: hidden;
}

/* Background accent */
.role-switcher::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(108, 63, 197, 0.06) 0%, transparent 70%);
  pointer-events: none;
}

/* Tabs */
.role-tabs {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-xs);
  margin-bottom: var(--space-3xl);
  background: var(--glass-bg);
  border: var(--glass-border);
  border-radius: var(--radius-full);
  padding: 6px;
  width: fit-content;
  margin-left: auto;
  margin-right: auto;
}

.role-tab {
  padding: 12px 28px;
  border-radius: var(--radius-full);
  font-size: var(--fs-sm);
  font-weight: var(--fw-medium);
  color: var(--text-secondary);
  transition: all var(--transition-base);
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: var(--space-xs);
  white-space: nowrap;
}

.role-tab:hover {
  color: var(--text-primary);
}

.role-tab.active {
  background: var(--gradient-cta);
  color: white;
  box-shadow: 0 4px 16px rgba(108, 63, 197, 0.3);
}

.role-tab__icon {
  font-size: var(--fs-base);
}

/* Content Area */
.role-content-area {
  position: relative;
  overflow: hidden;
  /* Will be dynamically sized by JS to match the active panel */
  transition: height 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.role-content {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: var(--space-3xl);
  align-items: center;
  opacity: 0;
  transform: translateY(20px);
  pointer-events: none;
  visibility: hidden;
  transition:
    opacity 0.45s cubic-bezier(0.16, 1, 0.3, 1),
    transform 0.45s cubic-bezier(0.16, 1, 0.3, 1),
    visibility 0s 0.45s;
}

.role-content.active {
  position: relative;
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
  visibility: visible;
  transition:
    opacity 0.45s cubic-bezier(0.16, 1, 0.3, 1) 0.05s,
    transform 0.45s cubic-bezier(0.16, 1, 0.3, 1) 0.05s,
    visibility 0s 0s;
}

/* Text Side */
.role-content__info {
  display: flex;
  flex-direction: column;
  gap: var(--space-xl);
}

.role-content__badge {
  display: inline-flex;
  align-items: center;
  gap: var(--space-xs);
  padding: 6px 16px;
  background: rgba(108, 63, 197, 0.1);
  border: 1px solid rgba(108, 63, 197, 0.2);
  border-radius: var(--radius-full);
  font-size: var(--fs-xs);
  font-weight: var(--fw-semibold);
  color: var(--accent-purple);
  text-transform: uppercase;
  letter-spacing: var(--ls-wider);
  width: fit-content;
}

.role-content__title {
  font-family: var(--font-display);
  font-size: var(--fs-3xl);
  font-weight: var(--fw-bold);
  line-height: var(--lh-snug);
  color: var(--text-primary);
}

.role-content__desc {
  font-size: var(--fs-base);
  color: var(--text-secondary);
  line-height: var(--lh-relaxed);
}

.role-content__features {
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
}

.role-feature {
  display: flex;
  align-items: flex-start;
  gap: var(--space-md);
}

.role-feature__check {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: rgba(108, 63, 197, 0.15);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  font-size: 12px;
  color: var(--accent-purple);
  margin-top: 2px;
}

.role-feature__text {
  font-size: var(--fs-sm);
  color: var(--text-secondary);
  line-height: var(--lh-normal);
}

.role-feature__text strong {
  color: var(--text-primary);
  font-weight: var(--fw-semibold);
}

/* Image Side */
.role-content__visual {
  position: relative;
}

.role-content__image {
  width: 100%;
  border-radius: var(--radius-xl);
  border: 1px solid rgba(108, 63, 197, 0.1);
  box-shadow:
    0 16px 48px rgba(108, 63, 197, 0.1),
    0 4px 12px rgba(0, 0, 0, 0.06);
  transition: transform var(--transition-slow);
}

.role-content.active .role-content__image {
  animation: roleImgIn 0.6s var(--ease-out-expo) forwards;
}

@keyframes roleImgIn {
  0% {
    opacity: 0;
    transform: translateX(30px) scale(0.96);
  }
  100% {
    opacity: 1;
    transform: translateX(0) scale(1);
  }
}

.role-content__image-glow {
  position: absolute;
  inset: -15%;
  background: radial-gradient(ellipse at center, rgba(108, 63, 197, 0.06) 0%, transparent 60%);
  pointer-events: none;
  z-index: -1;
}

/* Responsive */
@media (max-width: 1024px) {
  .role-content {
    grid-template-columns: 1fr;
    gap: var(--space-2xl);
  }

  .role-content__info {
    order: 1;
  }

  .role-content__visual {
    order: 2;
  }
}

@media (max-width: 600px) {
  .role-tabs {
    flex-direction: column;
    border-radius: var(--radius-xl);
    width: 100%;
  }

  .role-tab {
    width: 100%;
    justify-content: center;
  }

  .role-content__title {
    font-size: var(--fs-2xl);
  }
}
