/* Browser-style profile tabs above main content card */

.muveup-profile-tabs-strip {
  width: 90%;
  max-width: 1200px;
  margin: 100px auto 0 auto;
  padding: 0;
  box-sizing: border-box;
  position: relative;
  z-index: 3;
}

.muveup-profile-tabs {
  display: flex;
  align-items: flex-end;
  gap: 6px;
  overflow-x: auto;
  overflow-y: hidden;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: thin;
  padding: 0;
}

.muveup-profile-tabs::-webkit-scrollbar {
  height: 4px;
}

.muveup-profile-tabs::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.45);
  border-radius: 4px;
}

.muveup-profile-tab {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  flex: 1 1 0;
  min-width: 120px;
  max-width: none;
  min-height: 52px;
  padding: 13px 22px 12px;
  border: 1px solid rgba(255, 255, 255, 0.4);
  border-bottom: none;
  border-radius: 14px 14px 0 0;
  background: rgba(255, 255, 255, 0.16);
  color: #fff;
  font-family: 'Montserrat', sans-serif;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.25;
  cursor: pointer;
  text-decoration: none;
  box-sizing: border-box;
  transition: background 0.2s ease, color 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
  -webkit-tap-highlight-color: transparent;
  position: relative;
  top: 1px;
}

/* Rightmost element docks squarely to the card's top-right corner */
.muveup-profile-tabs > .muveup-profile-tab:last-child {
  border-top-right-radius: 0;
}

.muveup-profile-tab:hover {
  background: rgba(255, 255, 255, 0.28);
  border-color: rgba(255, 255, 255, 0.55);
}

.muveup-profile-tab:focus-visible {
  outline: 2px solid rgba(255, 255, 255, 0.9);
  outline-offset: 2px;
}

.muveup-profile-tab.is-active {
  background: #fff;
  color: #815da7;
  border-color: #fff;
  box-shadow: 0 -6px 18px rgba(0, 0, 0, 0.1);
  z-index: 2;
  top: 0;
  padding-bottom: 14px;
  min-height: 54px;
}

/* Active tab visually merges with the card below it */
.muveup-profile-tab.is-active::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -2px;
  height: 4px;
  background: #fff;
}

.muveup-profile-tab.is-active .muveup-profile-tab-name {
  color: #e38722;
}

@keyframes muveup-tab-skeleton {
  0%,
  100% {
    opacity: 0.55;
  }
  50% {
    opacity: 0.85;
  }
}

.muveup-profile-tab-avatar {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
  background: #e8e4f0;
  border: 2px solid rgba(255, 255, 255, 0.65);
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.08);
  transition: opacity 0.25s ease;
}

.muveup-profile-tab-avatar[src]:not(.is-loaded) {
  opacity: 0;
}

.muveup-profile-tab-avatar.is-loaded {
  opacity: 1;
  animation: none;
}

.muveup-profile-tab-avatar:not([src]) {
  background: #e8e4f0;
  border-color: rgba(255, 255, 255, 0.45);
  box-shadow: none;
  animation: muveup-tab-skeleton 1.2s ease-in-out infinite;
}

.muveup-profile-tab.is-active .muveup-profile-tab-avatar {
  border-color: rgba(227, 135, 34, 0.35);
}

.muveup-profile-tab-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
  flex: 1;
  text-align: left;
}

.muveup-profile-tab-name {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-weight: 700;
  font-size: 14px;
}

.muveup-profile-tab-formation {
  font-size: 11px;
  font-weight: 500;
  opacity: 0.88;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.muveup-profile-tab.is-active .muveup-profile-tab-formation {
  color: #888;
  opacity: 1;
}

/* Plus tab: add another lineup */
.muveup-profile-tab--add {
  flex: 0 0 auto;
  padding: 13px 18px 12px;
  justify-content: center;
  align-items: center;
  min-height: 52px;
  white-space: nowrap;
  background: rgba(255, 255, 255, 0.12);
  border-style: dashed;
  border-color: rgba(255, 255, 255, 0.5);
  border-radius: 14px 14px 0 0;
}

.muveup-profile-tabs > .muveup-profile-tab--add:last-child {
  border-top-right-radius: 14px;
}

.muveup-profile-tab--add:hover {
  background: rgba(255, 255, 255, 0.26);
  border-color: rgba(255, 255, 255, 0.75);
  border-style: dashed;
}

.muveup-profile-tab--add:focus-visible {
  outline: 2px solid rgba(255, 255, 255, 0.9);
  outline-offset: 2px;
}

.muveup-profile-tab-add-label {
  font-size: 14px;
  font-weight: 600;
  line-height: 1.25;
  color: inherit;
}

/* Content card connects to active tab */
body.has-profile-tabs .container.muveup-profile-tabs-content-anchor,
body.has-profile-tabs .muveup-profile-tabs-content-anchor.container {
  margin-top: 0;
  border-top-left-radius: 0;
  border-top-right-radius: 0;
}

body.has-profile-tabs .wizard-wrapper.muveup-profile-tabs-content-anchor {
  padding-top: 0;
  align-items: flex-start;
}

body.has-profile-tabs .wizard-wrapper.muveup-profile-tabs-content-anchor .wizard-card {
  border-top-left-radius: 0;
  border-top-right-radius: 0;
}

@media (max-width: 900px) {
  .muveup-profile-tabs-strip {
    display: none !important;
    width: calc(100% - 24px);
    margin-top: 88px;
  }

  .muveup-profile-tab {
    min-width: 100px;
    padding: 10px 14px 9px;
    font-size: 13px;
    min-height: 46px;
  }

  .muveup-profile-tab.is-active {
    min-height: 48px;
    padding-bottom: 11px;
  }

  .muveup-profile-tab-avatar {
    width: 24px;
    height: 24px;
  }

  .muveup-profile-tab--add {
    padding: 10px 14px 9px;
    min-height: 46px;
  }

  .muveup-profile-tab-add-label {
    font-size: 12px;
  }

  body.has-profile-tabs .container.muveup-profile-tabs-content-anchor {
    margin-top: 0;
  }
}

@media (max-width: 600px) {
  .muveup-profile-tabs-strip {
    margin-top: 80px;
  }

  .muveup-profile-tab-name {
    font-size: 13px;
  }

}
