/* ============================================================================
   /federaciones — solo lo exclusivo de esta vista (v4 corporativo)
   - Que incluye: perfiles en pestañas con portal de ejemplo por rol
   - Diferencial: recorrido de un campeonato (fondo blanco)
   ============================================================================ */

/* ---------------------------------------------------------------------------
   Perfiles
   --------------------------------------------------------------------------- */
.fed-roles__list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 36px;
}

.fed-roles__tab {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 11px 18px;
  border: 1.5px solid var(--kdx-line);
  border-radius: 999px;
  background: #fff;
  font-family: 'Poppins', system-ui, sans-serif;
  font-size: .92rem;
  font-weight: 600;
  color: var(--kdx-body);
  cursor: pointer;
  transition: border-color .2s ease, background-color .2s ease, color .2s ease;
}

.fed-roles__tab:hover { border-color: rgba(37, 99, 235, .45); color: var(--kdx-ink); }
.fed-roles__tab.is-on { border-color: var(--kdx-ink); background: var(--kdx-ink); color: #fff; }
.fed-roles__tab:focus-visible { outline: 3px solid rgba(56, 189, 248, .55); outline-offset: 2px; }

/* Sin JS: sin pestañas, todos los perfiles en columna */
.fed-roles:not(.is-ready) .fed-roles__list { display: none; }
.fed-roles:not(.is-ready) .fed-roles__stage { display: grid; gap: 48px; }
.fed-roles.is-ready .fed-role { display: none; }
.fed-roles.is-ready .fed-role.is-on { display: grid; animation: fed-in .45s var(--svx-ease); }

@keyframes fed-in {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: none; }
}

.fed-role {
  display: grid;
  grid-template-columns: 1fr;
  gap: 32px;
  align-items: center;
}

@media (min-width: 992px) {
  .fed-role { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 64px; }
}

.fed-role__title {
  margin: 0 0 12px;
  font-family: 'Poppins', system-ui, sans-serif;
  font-size: clamp(1.3rem, 2.2vw, 1.65rem);
  font-weight: 600;
  letter-spacing: -.02em;
  color: var(--kdx-ink);
}

.fed-role__copy > p { margin: 0; max-width: 46ch; font-size: 1.04rem; line-height: 1.7; color: var(--kdx-body); }

.fed-role__scope {
  display: flex !important;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 10px;
  margin-top: 22px !important;
  padding-top: 18px;
  border-top: 1px solid var(--kdx-line);
}

.fed-role__scope span { font-size: .84rem; color: var(--kdx-muted); }
.fed-role__scope strong { font-family: 'Poppins', system-ui, sans-serif; font-size: 1.02rem; color: var(--kdx-ink); }

/* Portal de ejemplo (imita la app) */
.fed-portal {
  border-radius: 14px;
  overflow: hidden;
  background: #fff;
  border: 1px solid #e1e7f0;
  box-shadow: var(--kdx-shadow);
  font-family: 'Open Sans', system-ui, sans-serif;
}

.fed-portal__bar {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 16px;
  background: #eef2f8;
  border-bottom: 1px solid #e1e7f0;
}

.fed-portal__bar strong {
  min-width: 0;
  font-family: 'Poppins', system-ui, sans-serif;
  font-size: .86rem;
  font-weight: 600;
  color: var(--kdx-ink);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.fed-portal__body {
  display: grid;
  grid-template-columns: 170px 1fr;
  min-height: 230px;
}

.fed-portal__menu {
  margin: 0;
  padding: 14px 10px;
  list-style: none;
  background: #0e1b3d;
}

.fed-portal__menu li {
  padding: 8px 10px;
  border-radius: 7px;
  font-size: .78rem;
  color: #8fa6c8;
}

.fed-portal__menu li.is-on { background: rgba(56, 189, 248, .12); color: #fff; }

.fed-portal__main { padding: 16px; min-width: 0; }

.fed-portal__h {
  display: block;
  margin: 2px 2px 10px;
  font-size: .72rem;
  font-weight: 600;
  color: #7a8aa3;
}

.fed-portal__rows {
  margin: 0;
  padding: 4px 0;
  list-style: none;
  border-radius: 10px;
  background: #fff;
  border: 1px solid #e6ebf3;
}

.fed-portal__body { background: #f6f8fc; }

.fed-portal__rows li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px;
  font-size: .86rem;
  color: var(--kdx-ink);
}

.fed-portal__rows li + li { border-top: 1px solid #eef2f7; }
.fed-portal .svx-pill { font-size: .72rem; padding: 4px 10px; }

@media (max-width: 991px) {
  .fed-roles__list { flex-wrap: nowrap; overflow-x: auto; padding-bottom: 6px; margin-bottom: 28px; }
  .fed-roles__tab { flex: 0 0 auto; }
}

@media (max-width: 575px) {
  .fed-portal__body { grid-template-columns: 1fr; min-height: 0; }
  .fed-portal__menu { display: flex; gap: 4px; overflow: hidden; padding: 10px; }
  .fed-portal__menu li { white-space: nowrap; }
  .fed-portal__main { padding: 12px; }
}

/* ---------------------------------------------------------------------------
   Recorrido de un campeonato (fondo blanco)
   --------------------------------------------------------------------------- */
.fed-flow {
  display: grid;
  grid-template-columns: 1fr;
  gap: 44px;
}

@media (min-width: 992px) {
  .fed-flow { grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: 80px; }
  .fed-flow__head { position: sticky; top: 110px; align-self: start; }
}

.fed-flow__head .kdx-lead { margin-top: 16px; }
.fed-flow__photo { margin-top: 30px; box-shadow: none; }

.fed-flow__photo figcaption {
  position: absolute;
  left: 14px;
  bottom: 14px;
  padding: 8px 14px;
  border-radius: 999px;
  background: rgba(8, 15, 36, .78);
  -webkit-backdrop-filter: blur(6px);
          backdrop-filter: blur(6px);
  font-size: .8rem;
  font-weight: 600;
  color: #fff;
}

.fed-flow__steps {
  position: relative;
  margin: 0;
  padding: 0;
  list-style: none;
}

/* Linea vertical que une los pasos */
.fed-flow__steps::before {
  content: '';
  position: absolute;
  left: 21px;
  top: 22px;
  bottom: 40px;
  width: 2px;
  background: var(--kdx-line);
}

.fed-flow__step {
  position: relative;
  display: grid;
  grid-template-columns: 44px 1fr;
  gap: 22px;
  padding-bottom: 34px;
}

.fed-flow__step:last-child { padding-bottom: 0; }

.fed-flow__dot {
  position: relative;
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--kdx-white);
  border: 1px solid var(--kdx-line);
  font-family: 'Poppins', system-ui, sans-serif;
  font-weight: 600;
  color: var(--kdx-blue);
}

.main-wrapper .fed-flow__step h3 {
  margin: 8px 0 6px;
  font-family: 'Poppins', system-ui, sans-serif;
  font-size: 1.2rem;
  font-weight: 600;
  letter-spacing: -.015em;
  color: var(--kdx-ink);
}

.fed-flow__step p { margin: 0; max-width: 48ch; font-size: 1rem; line-height: 1.65; color: var(--kdx-body); }

.fed-roles__ask { margin-top: 28px; }

@media (prefers-reduced-motion: reduce) {
  .fed-roles.is-ready .fed-role.is-on { animation: none; }
}

/* ---------------------------------------------------------------------------
   Estandar de secciones (v7): cabecera centrada en Perfiles, pestañas
   centradas y la descripcion del rol en un panel redondeado.
   --------------------------------------------------------------------------- */
@media (min-width: 992px) {
  .fed-roles__list { justify-content: center; }
}

.fed-role__copy {
  padding: 28px 30px;
  border: 1px solid var(--kdx-line);
  border-radius: 24px;
  background: #fff;
  box-shadow: 0 12px 30px -24px rgba(8, 15, 36, .35);
}

.fed-portal { border-radius: 20px; }

.fed-roles__ask { display: flex; width: fit-content; margin: 32px auto 0; }

@media (max-width: 575px) {
  .fed-role__copy { padding: 22px 20px; }
}

/* La nota de la pantalla de ejemplo va bajo el portal (columna derecha) */
@media (min-width: 992px) {
  .fed-roles.is-ready .fed-roles__stage > .svx-showcase__note { justify-self: end; text-align: right; }
}
