/* =====================================================================
   Tema visual MatchMentoring CB — trasladado del proyecto legacy.
   Paleta: cian #50C0E5, teal #1CAAC3, navy #00457A, teal oscuro #027795,
   naranja #F9901B. Tipografía: Mulish.
   ===================================================================== */

:root {
    --mm-cyan: #50c0e5;
    --mm-teal: #1caac3;
    --mm-teal-dark: #027795;
    --mm-navy: #00457a;
    --mm-orange: #f9901b;
    --mm-ink: #282828;

    /* Sobrescribe variables de Bootstrap para que todo el framework herede la marca */
    --bs-primary: #1caac3;
    --bs-primary-rgb: 28, 170, 195;
    --bs-link-color: #50c0e5;
    --bs-link-color-rgb: 80, 192, 229;
    --bs-link-hover-color: #00457a;
    --bs-link-hover-color-rgb: 0, 69, 122;
    --bs-body-font-family: 'Mulish', system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}

html {
    font-size: 14px;
    position: relative;
    min-height: 100%;
}

@media (min-width: 768px) {
    html {
        font-size: 16px;
    }
}

body {
    margin-bottom: 60px;
    font-family: var(--bs-body-font-family);
    color: var(--mm-ink);
}

h1, h2, h3, h4, h5, h6, .navbar-brand {
    font-family: var(--bs-body-font-family);
}

a {
    color: var(--mm-cyan);
    text-decoration: none;
}

a:hover {
    color: var(--mm-navy);
}

/* ---------- Foco accesible con color de marca ---------- */
.btn:focus, .btn:active:focus, .btn-link.nav-link:focus,
.form-control:focus, .form-check-input:focus {
    box-shadow: 0 0 0 0.1rem #fff, 0 0 0 0.25rem rgba(80, 192, 229, .65);
}

/* ---------- Cabecera / navbar ---------- */
.navbar {
    background: #fff;
}

.navbar-brand img {
    max-height: 44px;
    width: auto;
}

.navbar .nav-link {
    color: #000;
    font-weight: 600;
}

.navbar .nav-link:hover {
    color: var(--mm-teal);
}

.navbar .nav-link.active {
    color: var(--mm-cyan) !important;
    font-weight: 700;
}

/* ---------- Botones ---------- */
.btn-primary {
    --bs-btn-bg: var(--mm-teal);
    --bs-btn-border-color: var(--mm-teal);
    --bs-btn-hover-bg: var(--mm-teal-dark);
    --bs-btn-hover-border-color: var(--mm-teal-dark);
    --bs-btn-active-bg: var(--mm-navy);
    --bs-btn-active-border-color: var(--mm-navy);
    --bs-btn-disabled-bg: var(--mm-teal);
    --bs-btn-disabled-border-color: var(--mm-teal);
}

.btn-outline-primary {
    --bs-btn-color: var(--mm-teal);
    --bs-btn-border-color: var(--mm-teal);
    --bs-btn-hover-bg: var(--mm-teal);
    --bs-btn-hover-border-color: var(--mm-teal);
    --bs-btn-active-bg: var(--mm-teal-dark);
    --bs-btn-active-border-color: var(--mm-teal-dark);
}

/* ---------- Enlaces de tablas / acentos ---------- */
.table > thead th {
    color: var(--mm-navy);
}

.text-primary {
    color: var(--mm-teal) !important;
}

/* =====================================================================
   Pantallas de acceso (login, recuperación de contraseña) — _AuthLayout.
   Fondo teal con imagen y tarjeta translúcida centrada, como el legacy.
   ===================================================================== */
.mm-auth-body {
    min-height: 100vh;
    margin: 0;
    background: url('/img/fondo-intro.jpg') no-repeat center center fixed;
    background-size: cover;
    background-color: var(--mm-teal);
    display: flex;
    flex-direction: column;
}

.mm-auth-wrapper {
    flex: 1 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px 16px;
}

.mm-auth-card {
    width: 100%;
    max-width: 380px;
    background-color: rgba(255, 255, 255, .92);
    border-radius: 14px;
    box-shadow: 9px 10px 25px 5px rgba(1, 1, 1, .15);
    padding: 32px 28px;
}

.mm-auth-logo {
    display: block;
    max-width: 230px;
    max-height: 80px;
    width: 100%;
    height: auto;
    margin: 0 auto 24px;
}

/* Inputs redondeados de las pantallas de acceso (estilo legacy) */
.mm-auth-card .form-control {
    border-radius: 50px;
    border: 2px solid #e6e6e6;
    padding: 12px 18px;
}

.mm-auth-card .form-floating > label {
    padding-left: 18px;
}

.mm-auth-card .form-control:focus {
    border-color: var(--mm-cyan);
    box-shadow: none;
}

.mm-auth-card .btn-primary {
    border-radius: 50px;
    padding-top: 10px;
    padding-bottom: 10px;
}

/* Selector de idioma sobre el fondo teal */
.mm-auth-lang {
    text-align: center;
    padding: 14px;
}

.mm-auth-lang a {
    color: #fff;
    font-weight: 600;
    opacity: .85;
    margin: 0 6px;
}

.mm-auth-lang a:hover {
    color: #fff;
    opacity: 1;
}

/* ---------- Pie de página ---------- */
.footer {
    position: absolute;
    bottom: 0;
    width: 100%;
    white-space: nowrap;
    line-height: 60px;
}

/* =====================================================================
   Fase 1 · Pantalla de bienvenida del programa (onboarding). Calcado del
   legacy (Menu.aspx / InicioMentoring.xslt): badge FASE 01, títulos,
   botones pill amarillos (#fee594) y hero lateral (bienvenida-MM.png).
   ===================================================================== */
.mm-welcome-content {
    max-width: 460px;
    margin-top: 40px;
}

.mm-fase-label {
    font-size: 2.5rem;
    /* El legacy solo carga Mulish 400 y 900: su "bold" cae a 900 (negra). Lo replicamos. */
    font-weight: 900;
    margin: 0 18px 0 0;
    line-height: 1;
    align-self: center;
}

.mm-fase-badge {
    width: 92px;
    height: auto;
}

.mm-welcome-hi {
    font-size: 2rem;
    color: #000;
    font-weight: 100;
    line-height: 2rem;
    margin-bottom: 0;
}

.mm-brand-title {
    font-size: 2rem;
    color: #000;
    /* Como en el legacy, "Match" se muestra en negra (900). */
    font-weight: 900;
    line-height: 2rem;
    margin-top: -2px;
}

.mm-brand-title .accent {
    color: var(--mm-cyan);
    font-weight: 900;
}

.mm-welcome-text {
    margin-top: 18px;
}

/* Botones pill amarillos del programa (estilo legacy) */
.btn-mm-pill {
    border-radius: 35px;
    background-color: #fee594;
    padding: 15px 30px;
    border: 0;
    color: #000;
    font-weight: 700;
}

.btn-mm-pill:hover {
    background-color: var(--mm-orange);
    color: #fff;
}

.btn-mm-pill:disabled,
.btn-mm-pill.disabled {
    background-color: #fef0c2;
    color: #8a8a8a;
    cursor: not-allowed;
}

.mm-welcome-hero {
    width: 100%;
    height: auto;
}

@media (max-width: 991.98px) {
    .mm-welcome-content {
        max-width: 100%;
        margin-top: 16px;
    }

    .mm-welcome-hero {
        margin-top: 24px;
    }
}

/* =====================================================================
   Fase 2 · Pantalla de espera de emparejamiento (fin de la Fase 1).
   Calcado del legacy PantallaFase2.xslt: badge FASE 02, "¡Emparejamiento!",
   "Muchas gracias" en teal, mensaje por rol y hero lateral (matching-v2.png).
   ===================================================================== */
.mm-phase2-content {
    max-width: 480px;
    margin-top: 40px;
}

.mm-phase2-matching {
    font-size: 2rem;
    font-weight: 900;
    color: #000;
    line-height: 1;
    margin-bottom: .35rem;
}

.mm-phase2-thanks {
    font-size: 2.6rem;
    font-weight: 900;
    color: var(--mm-teal);
    line-height: 1.1;
    margin-bottom: 1rem;
}

.mm-phase2-text {
    max-width: 42ch;
}

.mm-phase2-hero {
    width: 100%;
    height: auto;
}

@media (max-width: 991.98px) {
    .mm-phase2-content {
        max-width: 100%;
        margin-top: 16px;
    }

    .mm-phase2-hero {
        margin-top: 24px;
    }
}

/* Resultado EDA: imagen del cuadrante de Kolb del estilo (adaptador/divergente/…),
   como el legacy (images/*-big.png). */
.mm-eda-type-img {
    width: 120px;
    height: auto;
    max-width: 100%;
}

/* =====================================================================
   Cabecera y pie del participante (_ParticipantLayout) — co-marca,
   saludo "Hola {Nombre}", menú hamburguesa y "Powered by", como el legacy.
   ===================================================================== */
.mm-phead-logo {
    height: 42px;
    width: auto;
}

.mm-phead-cobrand {
    height: 50px;
    width: auto;
}

.mm-phead-divider {
    display: inline-block;
    width: 1px;
    height: 38px;
    background: #d8d8d8;
    margin: 0 18px;
}

.mm-phead-hi {
    color: #000;
    font-size: 1.05rem;
}

/* Botón hamburguesa con barras teal (estilo legacy) */
.mm-phead-burger {
    background: none;
    border: 0;
    padding: 6px 4px;
    line-height: 0;
}

.mm-phead-burger span {
    display: block;
    width: 28px;
    height: 3px;
    margin: 5px 0;
    border-radius: 2px;
    background: var(--mm-teal);
}

.mm-pfooter {
    background: #fff;
    border-top: 1px solid #eee;
}

.mm-pfooter-powered {
    max-width: 240px;
    height: auto;
}

@media (max-width: 575.98px) {
    .mm-phead-cobrand {
        height: 40px;
    }

    .mm-phead-divider {
        margin: 0 10px;
    }
}

/* ===== Cabecera de pasos de la Fase 1 (réplica de CabeceraFase1.xslt) ===== */
.mm-stepper {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: flex-end;
    gap: 8px 24px;
    margin: 0 0 32px;
    padding-bottom: 16px;
    border-bottom: 1px solid #e7e7e7;
}

.mm-step {
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    text-align: center;
    min-width: 96px;
    padding: 8px 10px 6px;
    font-weight: 800;
    text-decoration: none;
    border-bottom: 3px solid transparent;
}

.mm-step-icon {
    width: 64px;
    height: 64px;
    object-fit: contain;
    margin-bottom: 8px;
}

.mm-step-label {
    font-size: 0.95rem;
    line-height: 1.1;
}

/* Tres tonos de icono según el estado (el SVG es negro sobre fondo blanco; la opacidad
   lo aclara hacia gris): negro = navegable, gris intermedio = actual, gris claro = no accesible. */

/* Paso actual: icono en gris intermedio + etiqueta resaltada con subrayado. */
.mm-step-active {
    color: var(--mm-navy);
    border-bottom-color: var(--mm-teal);
    cursor: default;
}

.mm-step-active .mm-step-icon {
    opacity: 0.5;
}

/* Paso completado: icono negro, navegable. */
.mm-step-done {
    color: var(--mm-teal);
    cursor: pointer;
}

.mm-step-done .mm-step-icon {
    opacity: 1;
}

.mm-step-done:hover {
    color: var(--mm-navy);
    text-decoration: none;
}

.mm-step-done:hover .mm-step-icon {
    opacity: 0.75;
}

/* Paso pendiente actual (frontera): navegable para retomarlo, icono a media opacidad. */
.mm-step-reachable {
    color: var(--mm-teal);
    cursor: pointer;
}

.mm-step-reachable .mm-step-icon {
    opacity: 0.5;
}

.mm-step-reachable:hover {
    color: var(--mm-navy);
    text-decoration: none;
}

.mm-step-reachable:hover .mm-step-icon {
    opacity: 0.75;
}

/* Paso aún no alcanzable: icono en gris claro, deshabilitado. */
.mm-step-disabled {
    color: #b6b6b6;
    cursor: default;
}

.mm-step-disabled .mm-step-icon {
    opacity: 0.2;
}

@media (max-width: 576px) {
    .mm-step { min-width: 80px; padding: 6px; }
    .mm-step-icon { width: 48px; height: 48px; }
    .mm-step-label { font-size: 0.8rem; }
}

/* =====================================================================
   Matriz de afinidad de matching (mentee × mentor, mapa de calor).
   ===================================================================== */
.mm-matrix-wrap {
    overflow: auto;
    max-height: 72vh;
    border: 1px solid #dee2e6;
    border-radius: 12px;
}

.mm-matrix {
    border-collapse: separate;
    border-spacing: 0;
    margin: 0;
    font-size: 0.85rem;
    width: auto;
}

.mm-matrix th,
.mm-matrix td {
    border-bottom: 1px solid #eef0f2;
    border-right: 1px solid #eef0f2;
}

/* Cabecera de mentores: fija arriba. */
.mm-matrix thead th {
    position: sticky;
    top: 0;
    z-index: 2;
    background: #fff;
    vertical-align: bottom;
    padding: 8px 6px;
    text-align: center;
    font-weight: 600;
}

/* Esquina superior izquierda: fija en ambos ejes. */
.mm-matrix .mm-matrix-corner {
    position: sticky;
    left: 0;
    top: 0;
    z-index: 4;
    background: #fff;
    text-align: left;
    color: #6c757d;
    font-weight: 600;
    min-width: 150px;
    white-space: nowrap;
}

.mm-th-mentor { min-width: 96px; max-width: 122px; }

.mm-th-name {
    display: block;
    max-width: 112px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    color: var(--mm-navy);
}

.mm-th-cap {
    display: block;
    font-size: 0.72rem;
    color: #8a8f94;
    font-weight: 400;
}

/* Columna de mentees: fija a la izquierda. */
.mm-th-mentee {
    position: sticky;
    left: 0;
    z-index: 1;
    background: #fff;
    text-align: left;
    font-weight: 600;
    color: var(--mm-navy);
    min-width: 150px;
    max-width: 180px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    padding: 6px 10px;
}

.mm-cell {
    position: relative;
    text-align: center;
    padding: 0;
    cursor: pointer;
    min-width: 62px;
}

.mm-cell .mm-cell-val { display: block; padding: 7px 4px; }

.mm-cell:hover { outline: 2px solid var(--mm-teal); outline-offset: -2px; }

.mm-cell-badge {
    position: absolute;
    top: 1px;
    right: 3px;
    font-size: 0.7rem;
    line-height: 1;
}

/* Buckets del mapa de calor (paleta de marca). */
.mm-aff-0 { background: #e9f7fa; color: #12707f; }
.mm-aff-1 { background: #bce7ee; color: #0c5c68; }
.mm-aff-2 { background: #7fd3e0; color: #083e47; }
.mm-aff-3 { background: var(--mm-teal); color: #fff; }
.mm-aff-4 { background: var(--mm-teal-dark); color: #fff; }

/* Estados superpuestos. */
.mm-cell.mm-k-best { outline: 2px solid var(--mm-cyan); outline-offset: -2px; }
.mm-cell.mm-k-best .mm-cell-badge { color: #fff; }
.mm-cell.mm-k-closed { outline: 2px solid var(--mm-navy); outline-offset: -2px; }
.mm-cell.mm-k-closed .mm-cell-badge { color: #fff; }
.mm-cell.mm-k-forbidden { background: #f8d7da !important; color: #842029 !important; }
.mm-cell.mm-k-forbidden .mm-cell-badge { color: #842029; }
.mm-cell.mm-same { background: #f6f7f8; color: #c3c8cc; cursor: default; }
.mm-cell.mm-same:hover { outline: none; }
.mm-cell.mm-full { opacity: 0.4; }
.mm-cell.mm-selected { outline: 3px solid var(--mm-navy) !important; outline-offset: -3px; }

/* Lista de sugerencias: filas seleccionables (mismo detalle que la matriz al pulsarlas). */
.mm-sug-row { cursor: pointer; }
.mm-sug-row:hover > td { background: #f1fafc; }
.mm-sug-row:focus-visible { outline: 2px solid var(--mm-teal-dark); outline-offset: -2px; }
.mm-sug-row.mm-selected > td,
.mm-sug-row.mm-selected > th { box-shadow: inset 3px 0 0 0 var(--mm-navy); background: #eef7fa; }
.mm-th-mentor.mm-full .mm-th-name { color: #8a8f94; }
.mm-row-resolved .mm-th-mentee { color: #8a8f94; }

/* Toggles de densidad. */
.mm-matrix.mm-only-best .mm-cell:not(.mm-k-best):not(.mm-k-closed):not(.mm-same) { opacity: 0.2; }
.mm-matrix.mm-only-best .mm-cell.mm-full { opacity: 0.12; }
.mm-matrix.mm-hide-full [data-full="1"] { display: none; }
/* Filtro dinámico por nombre (cliente): oculta columnas de mentor y filas de mentee. */
.mm-col-hidden { display: none; }
.mm-row-hidden { display: none; }

/* Leyenda y glifos. */
.mm-legend-box {
    display: inline-block;
    width: 12px;
    height: 12px;
    border-radius: 3px;
    vertical-align: -1px;
}

.mm-glyph { font-weight: 700; vertical-align: -1px; }
.mm-glyph-best { color: var(--mm-cyan); }
.mm-glyph-closed { color: var(--mm-navy); }
.mm-glyph-forbidden { color: #dc3545; }

/* Barras del panel de detalle. */
.mm-bar-row { display: flex; align-items: center; gap: 8px; margin: 4px 0; }
.mm-bar-label { width: 130px; font-size: 0.8rem; color: #6c757d; }
.mm-bar-track { flex: 1; height: 8px; background: #eef0f2; border-radius: 4px; position: relative; }
.mm-bar-fill { height: 100%; background: var(--mm-teal); border-radius: 4px; }
/* Pulgar fijo (tipo slider) que marca el punto exacto del valor sobre la barra. */
.mm-bar-thumb { position: absolute; top: 50%; width: 14px; height: 14px; border-radius: 50%; background: #fff; border: 3px solid var(--mm-teal-dark); transform: translate(-50%, -50%); box-shadow: 0 1px 3px rgba(0, 0, 0, .25); }
.mm-bar-val { width: 46px; text-align: right; font-size: 0.8rem; font-weight: 600; }
/* Columnas numéricas: peso aportado (afinidad × peso) y peso total (peso del criterio). */
.mm-bar-contrib, .mm-bar-max { flex: none; text-align: right; font-size: 0.8rem; font-variant-numeric: tabular-nums; }
.mm-bar-contrib { width: 58px; font-weight: 600; color: var(--mm-teal-dark); }
.mm-bar-max { width: 48px; color: #6c757d; }
.mm-bar-info-spacer { width: 16px; flex: none; }
/* Fila de cabecera de las columnas del desglose. */
.mm-bar-head {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0 0 3px;
    font-size: 0.58rem;
    font-weight: 600;
    color: #9aa0a6;
    white-space: nowrap;
}
.mm-bar-track-spacer { flex: 1; }
.mm-bar-head .mm-bar-val, .mm-bar-head .mm-bar-contrib, .mm-bar-head .mm-bar-max {
    color: #9aa0a6;
    font-weight: 600;
    font-size: inherit;
}
/* Fila del desglose pulsable: abre el popup con la explicación del criterio. */
.mm-bar-row.mm-bar-click { cursor: pointer; border-radius: 4px; padding: 2px 4px; margin: 2px -4px; }
.mm-bar-row.mm-bar-click:hover,
.mm-bar-row.mm-bar-click:focus-visible { background: #f1fafc; outline: none; }
.mm-bar-info { color: var(--mm-teal); font-size: 0.85rem; opacity: 0.55; margin-left: 2px; }
.mm-bar-row.mm-bar-click:hover .mm-bar-info,
.mm-bar-row.mm-bar-click:focus-visible .mm-bar-info { opacity: 1; }

/* ---- Cabecera del popup de explicación ---- */
.mm-explain-head {
    align-items: flex-start;
    gap: 0.5rem;
    background: linear-gradient(135deg, #f1fafc 0%, #ffffff 70%);
    border-bottom: 2px solid var(--mm-teal);
}
.mm-explain-head-inner { flex: 1; min-width: 0; }
.mm-explain-crit {
    color: var(--mm-navy);
    font-weight: 700;
    margin-bottom: 0.5rem;
}
.mm-explain-pair { display: flex; flex-wrap: wrap; align-items: center; gap: 0.4rem 1rem; }
.mm-explain-role { display: inline-flex; align-items: center; gap: 0.4rem; min-width: 0; }
.mm-explain-role-tag {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    font-size: 0.68rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    padding: 0.12rem 0.5rem;
    border-radius: 999px;
    color: #fff;
    white-space: nowrap;
}
.mm-role-mentor .mm-explain-role-tag { background: var(--mm-teal); }
.mm-role-mentee .mm-explain-role-tag { background: var(--mm-navy); }
.mm-explain-role-name { font-weight: 600; color: #2b3948; overflow-wrap: anywhere; }

/* Utilidad de color de marca para iconos/textos */
/* Panel de pesos (sliders) del matching */
.mm-weights { border-color: #cfe9ef; background: #f6fcfd; }
.mm-weights-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
    gap: 10px 22px;
}
.mm-weight { display: flex; flex-direction: column; gap: 2px; }
.mm-weight-label {
    font-size: 0.8rem; font-weight: 600; color: #37505a;
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.mm-weight-ctl { display: flex; align-items: center; gap: 10px; }
.mm-weight-ctl .mm-weight-range { flex: 1; margin: 0; accent-color: var(--mm-teal); }
.mm-weight-val {
    min-width: 44px; text-align: right; font-size: 0.82rem; font-weight: 700;
    color: var(--mm-teal-dark); font-variant-numeric: tabular-nums;
}

.text-teal { color: var(--mm-teal) !important; }

/* =====================================================================
   Dashboard del gestor (Manager/Index): cabecera con programa activo +
   selector, y rejilla de tiles por bloque funcional (estilo legacy).
   ===================================================================== */
.mm-mgr-hero {
    background: linear-gradient(135deg, var(--mm-navy) 0%, var(--mm-teal-dark) 100%);
    color: #fff;
    border-radius: 16px;
    padding: 22px 26px;
}

.mm-mgr-hero .mm-mgr-eyebrow {
    text-transform: uppercase;
    letter-spacing: 0.08em;
    font-size: 0.75rem;
    font-weight: 700;
    opacity: 0.8;
}

.mm-mgr-hero h1 {
    color: #fff;
    font-weight: 900;
    margin: 2px 0 0;
}

/* El selector de programa hereda estilo claro sobre el fondo teal. */
.mm-mgr-hero .dropdown-toggle {
    background: rgba(255, 255, 255, .14);
    border: 1px solid rgba(255, 255, 255, .35);
    color: #fff;
    font-weight: 700;
}

.mm-mgr-hero .dropdown-toggle:hover,
.mm-mgr-hero .dropdown-toggle:focus {
    background: rgba(255, 255, 255, .24);
    color: #fff;
}

/* Rejilla de tiles: en pantallas grandes los 8 bloques van en una sola fila;
   se reduce a 4 y 2 columnas en tabletas y móviles. */
.mm-tiles {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
}

@media (min-width: 576px) {
    .mm-tiles {
        grid-template-columns: repeat(4, 1fr);
    }
}

@media (min-width: 992px) {
    .mm-tiles {
        grid-template-columns: repeat(8, 1fr);
        gap: 10px;
    }
}

.mm-tile {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    text-align: center;
    gap: 8px;
    padding: 20px 10px 16px;
    background: #fff;
    border: 1px solid #e7edef;
    border-radius: 14px;
    color: var(--mm-navy);
    text-decoration: none;
    box-shadow: 0 1px 2px rgba(0, 69, 122, .04);
    transition: transform .12s ease, box-shadow .12s ease, border-color .12s ease;
}

a.mm-tile:hover {
    color: var(--mm-navy);
    border-color: var(--mm-teal);
    box-shadow: 0 8px 22px rgba(0, 69, 122, .12);
    transform: translateY(-3px);
    text-decoration: none;
}

/* Tile del bloque actualmente seleccionado (cabecera persistente). */
.mm-tile.active {
    border-color: var(--mm-teal);
    background: #f1fafc;
    box-shadow: inset 0 -3px 0 0 var(--mm-teal);
}

.mm-tile.active .mm-tile-icon {
    background: var(--mm-teal);
    color: #fff;
}

.mm-tile-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 52px;
    height: 52px;
    border-radius: 50%;
    background: #e9f7fa;
    color: var(--mm-teal-dark);
    font-size: 1.5rem;
}

a.mm-tile:hover .mm-tile-icon {
    background: var(--mm-teal);
    color: #fff;
}

.mm-tile-label {
    font-weight: 800;
    font-size: 0.92rem;
    line-height: 1.15;
}

.mm-tile-desc {
    font-size: 0.72rem;
    color: #6c757d;
    line-height: 1.2;
}

/* Tile de bloque aún no disponible */
.mm-tile-disabled {
    cursor: default;
    background: #f6f8f9;
    border-style: dashed;
    box-shadow: none;
    opacity: 0.8;
}

.mm-tile-disabled .mm-tile-icon {
    background: #eceff1;
    color: #aab2b7;
}

.mm-tile-disabled .mm-tile-label {
    color: #8a9298;
}

.mm-tile-soon {
    font-size: 0.66rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: #9aa0a6;
    background: #e7ebed;
    border-radius: 999px;
    padding: 1px 8px;
}

/* =====================================================================
   Resumen del panel del gestor: donut de emparejamiento, barra de reparto
   por fase y barras de distribución de estilos EDA (tono único de marca).
   ===================================================================== */
/* Donut de una sola magnitud (% del total). El hueco central lleva el número. */
.mm-donut {
    --pct: 0;
    width: 132px;
    height: 132px;
    border-radius: 50%;
    background: conic-gradient(var(--mm-teal) calc(var(--pct) * 1%), #e7edef 0);
    display: grid;
    place-items: center;
    flex: none;
}

.mm-donut-hole {
    width: 96px;
    height: 96px;
    border-radius: 50%;
    background: #fff;
    display: grid;
    place-items: center;
    text-align: center;
    line-height: 1.05;
}

.mm-donut-val {
    font-size: 1.55rem;
    font-weight: 900;
    color: var(--mm-navy);
}

.mm-donut-cap {
    font-size: 0.66rem;
    color: #6c757d;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

/* Leyenda con cuadrito de color (parte-del-todo). */
.mm-legend {
    display: flex;
    flex-direction: column;
    gap: 6px;
    font-size: 0.85rem;
}

.mm-legend-item {
    display: flex;
    align-items: center;
    gap: 8px;
}

.mm-legend-swatch {
    display: inline-block;
    width: 12px;
    height: 12px;
    border-radius: 3px;
    flex: none;
}

.mm-legend-swatch.is-on {
    background: var(--mm-teal);
}

.mm-legend-swatch.is-off {
    background: #e7edef;
}

.mm-legend-count {
    margin-left: auto;
    font-weight: 700;
    color: var(--mm-navy);
    font-variant-numeric: tabular-nums;
}

/* Barra segmentada de dos partes (p. ej. Fase 1 vs Fase 2). */
.mm-seg {
    display: flex;
    height: 16px;
    border-radius: 8px;
    overflow: hidden;
    background: #e7edef;
}

.mm-seg-on {
    background: var(--mm-teal);
    min-width: 2px;
}

/* Barras horizontales de distribución (tono único; la identidad va en la etiqueta). */
.mm-hbar-row {
    display: grid;
    grid-template-columns: 8.5rem 1fr auto;
    align-items: center;
    gap: 10px;
    margin: 8px 0;
}

.mm-hbar-label {
    font-size: 0.85rem;
    color: var(--mm-ink);
    line-height: 1.15;
}

.mm-hbar-track {
    height: 10px;
    border-radius: 6px;
    background: #eef2f4;
    overflow: hidden;
}

.mm-hbar-fill {
    display: block; /* imprescindible: en un <span> inline el width/height se ignoran y la barra no se rellena */
    height: 100%;
    border-radius: 6px;
    background: var(--mm-teal);
    min-width: 2px;
}

.mm-hbar-count {
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--mm-navy);
    font-variant-numeric: tabular-nums;
    min-width: 1.5rem;
    text-align: right;
}
