/* Portal público (VC-017) — hoja global, scoped bajo .portal-publico para no tocar el tema de
   la app autenticada (app.css). Reutiliza #9B2243/#780E3F ya definidos ahí para lo compartido;
   el resto son tokens propios de este rediseño (fondo crema, verdes/rojos de resultado). */

.portal-publico a {
    color: #9B2243;
    text-decoration: none;
}

    .portal-publico a:hover {
        color: #780E3F;
        text-decoration: underline;
    }

.portal-publico *:focus-visible {
    outline: 2px solid #9B2243;
    outline-offset: 2px;
}

/* NavLink es un componente hijo: el CSS aislado de PublicoLayout.razor.css no llega a su <a>
   renderizado (la scope attribute de Blazor solo se aplica a elementos escritos directamente en
   ese .razor), así que estas reglas viven aquí, global. */
.pp-header .pp-nav {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
}

.pp-header .pp-nav-link {
    border: none;
    background: transparent;
    color: #fff;
    font-size: 15px;
    font-weight: 600;
    padding: 10px 18px;
    border-radius: 999px;
    min-height: 44px;
    display: inline-flex;
    align-items: center;
    text-decoration: none;
}

    .pp-header .pp-nav-link:hover {
        background: rgba(255, 255, 255, .22);
        color: #fff;
        text-decoration: none;
    }

    .pp-header .pp-nav-link.active {
        background: rgba(255, 255, 255, .22);
        color: #fff;
    }

.pp-container {
    max-width: 1120px;
    margin: 0 auto;
    padding-left: 20px;
    padding-right: 20px;
}

/* Tipografía */

.pp-h1 {
    font-family: 'Caprasimo', system-ui, sans-serif;
    font-weight: 400;
    color: #780E3F;
    margin: 0 0 10px;
    line-height: 1.1;
}

.pp-h1--hero {
    font-size: clamp(34px, 6vw, 58px);
    line-height: 1.05;
    margin: 0 0 14px;
    max-width: 16ch;
}

.pp-lead {
    font-size: 19px;
    line-height: 1.5;
    margin: 0 0 26px;
    max-width: 52ch;
    color: #645C50;
}

.pp-lead--sm {
    font-size: 18px;
    max-width: 56ch;
}

/* Buscador */

.pp-search-pill {
    display: flex;
    gap: 10px;
    align-items: center;
    border: 1px solid #DCD3C4;
    border-radius: 999px;
    padding: 6px 8px 6px 18px;
    background: #fff;
}

.pp-search-pill--hero {
    max-width: 640px;
    padding: 8px 8px 8px 20px;
    box-shadow: 0 3px 10px rgba(46, 43, 37, .10);
    flex-wrap: wrap;
}

.pp-search-icon {
    flex: 0 0 auto;
    color: #9B2243;
    display: flex;
    align-items: center;
}

.pp-search-input {
    flex: 1 1 220px;
    min-width: 0;
    border: none;
    outline: none;
    font: inherit;
    font-size: 17px;
    color: #2e2b25;
    background: transparent;
    padding: 10px 0;
}

/* Botones */

.pp-btn {
    font: inherit;
    font-size: 16px;
    font-weight: 700;
    border-radius: 999px;
    padding: 12px 26px;
    min-height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    cursor: pointer;
    border: none;
    white-space: nowrap;
}

/* Los botones también se usan como <a> (descargas, "Ver acuerdos"): ".portal-publico a" (1
   clase + 1 tipo) empata o gana en especificidad a estas reglas de una sola clase, así que se
   repiten calificadas con "a.pp-btn--*" para no perder el color contra ese selector base. */
.pp-btn--primary, a.pp-btn--primary {
    background: #9B2243;
    color: #fff;
}

    .pp-btn--primary:hover {
        background: #780E3F;
        color: #fff;
        text-decoration: none;
    }

.pp-btn--outline {
    background: transparent;
    border: 2px solid #9B2243;
    color: #9B2243;
    padding: 10px 24px;
}

    .pp-btn--outline:hover {
        background: #F7E3E8;
        color: #9B2243;
        text-decoration: none;
    }

.pp-btn--outline-muted {
    background: #fff;
    border: 2px solid #DCD3C4;
    color: #780E3F;
    padding: 10px 22px;
}

    .pp-btn--outline-muted:hover {
        border-color: #9B2243;
        background: #FBF6EF;
        color: #780E3F;
        text-decoration: none;
    }

.pp-btn--ghost {
    background: transparent;
    color: #9B2243;
    padding: 6px 0;
    min-height: 0;
    border-radius: 0;
}

    .pp-btn--ghost:hover {
        color: #780E3F;
        text-decoration: none;
    }

.pp-btn--sm {
    font-size: 15px;
    padding: 9px 18px;
    min-height: 40px;
}

/* Chips / badges */

.pp-chip {
    display: inline-flex;
    align-items: center;
    font-size: 13px;
    font-weight: 700;
    padding: 6px 14px;
    border-radius: 999px;
}

.pp-chip--tipo {
    background: #F7E3E8;
    color: #780E3F;
}

.pp-chip--ok {
    background: #E8F0E7;
    color: #3C6642;
}

.pp-chip--warn {
    background: #FBEFD9;
    color: #8A6414;
}

.pp-filter-chip {
    font: inherit;
    font-size: 15px;
    font-weight: 700;
    padding: 9px 18px;
    border-radius: 999px;
    cursor: pointer;
    min-height: 44px;
    border: 2px solid #DCD3C4;
    background: #fff;
    color: #645C50;
}

    .pp-filter-chip.is-active {
        border-color: #9B2243;
        background: #F7E3E8;
        color: #780E3F;
    }

/* Cards genéricas */

.pp-card {
    background: #fff;
    border-radius: 28px;
    box-shadow: 0 1px 2px rgba(46, 43, 37, .14);
}

.pp-card--elevada {
    box-shadow: 0 12px 32px rgba(46, 43, 37, .14);
}

.pp-section-label {
    display: flex;
    align-items: baseline;
    gap: 12px;
    margin-bottom: 14px;
}

    .pp-section-label span:first-child {
        font-size: 12px;
        font-weight: 700;
        letter-spacing: .14em;
        text-transform: uppercase;
        color: #9B2243;
    }

.pp-section-label-rule {
    height: 1px;
    flex: 1;
    background: #DCD3C4;
}

/* Inicio: sesión más reciente */

.pp-reciente {
    overflow: hidden;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

.pp-reciente-info {
    padding: 30px;
    display: flex;
    flex-direction: column;
    gap: 16px;
    min-width: 0;
}

.pp-reciente-resultado {
    background: #F7E3E8;
    padding: 30px;
    display: flex;
    flex-direction: column;
    gap: 14px;
    min-width: 0;
}

.pp-reciente-resultado-titulo {
    font-size: 12px;
    font-weight: 700;
    letter-spacing: .12em;
    text-transform: uppercase;
    color: #780E3F;
}

.pp-resumen-fila {
    display: flex;
    align-items: center;
    gap: 12px;
}

.pp-resumen-num {
    width: 44px;
    height: 44px;
    border-radius: 999px;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    font-weight: 800;
    flex: 0 0 auto;
}

.pp-resumen-num--aprobado {
    background: #4A7B50;
}

.pp-resumen-num--rechazado {
    background: #A8322B;
}

.pp-resumen-num--tramite {
    background: #fff;
    color: #645C50;
    border: 1px solid #DCD3C4;
}

.pp-resumen-texto {
    font-size: 16px;
    color: #2e2b25;
    font-weight: 600;
}

/* Inicio: cifras */

.pp-stat-card {
    background: #fff;
    border-radius: 16px;
    padding: 22px;
    box-shadow: 0 1px 2px rgba(46, 43, 37, .14);
}

.pp-stat-num {
    font-family: 'Caprasimo', system-ui, sans-serif;
    font-size: 38px;
    line-height: 1;
}

.pp-stat-label {
    font-size: 16px;
    color: #645C50;
    margin-top: 8px;
}

/* Inicio: sesiones anteriores */

.pp-prev-item {
    text-align: left;
    font: inherit;
    border: 1px solid #DCD3C4;
    background: #fff;
    border-radius: 16px;
    padding: 18px 20px;
    cursor: pointer;
    display: flex;
    gap: 16px;
    align-items: center;
    flex-wrap: wrap;
    min-height: 44px;
    width: 100%;
}

    .pp-prev-item:hover {
        border-color: #9B2243;
        background: #FBF6EF;
    }

.pp-prev-fecha {
    flex: 0 0 auto;
    width: 56px;
    height: 56px;
    border-radius: 999px;
    background: #F7E3E8;
    color: #780E3F;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    line-height: 1.1;
}

    .pp-prev-fecha span:first-child {
        font-size: 17px;
        font-weight: 800;
    }

    .pp-prev-fecha span:last-child {
        font-size: 11px;
        font-weight: 700;
        text-transform: uppercase;
    }

.pp-prev-texto {
    flex: 1 1 200px;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 4px;
    text-align: left;
}

    .pp-prev-texto strong {
        font-size: 17px;
        font-weight: 700;
        color: #2e2b25;
    }

    .pp-prev-texto span {
        font-size: 15px;
        color: #645C50;
    }

.pp-prev-chevron {
    flex: 0 0 auto;
    color: #9B2243;
    display: flex;
    align-items: center;
}

/* Listado de sesiones */

.pp-filtros-card {
    background: #fff;
    border-radius: 28px;
    padding: 20px;
    box-shadow: 0 3px 10px rgba(46, 43, 37, .10);
    display: flex;
    flex-direction: column;
    gap: 18px;
    margin-bottom: 24px;
}

.pp-filtros-fila {
    display: flex;
    flex-wrap: wrap;
    gap: 22px;
}

.pp-filtro-grupo {
    display: flex;
    flex-direction: column;
    gap: 8px;
    min-width: 0;
}

.pp-filtro-grupo-label {
    font-size: 12px;
    font-weight: 700;
    letter-spacing: .12em;
    text-transform: uppercase;
    color: #645C50;
}

.pp-filtro-chips {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.pp-vista-toggle {
    display: flex;
    gap: 6px;
    background: #F9F4ED;
    border: 1px solid #DCD3C4;
    border-radius: 999px;
    padding: 4px;
}

.pp-vista-btn {
    font: inherit;
    font-size: 15px;
    font-weight: 700;
    padding: 8px 18px;
    border-radius: 999px;
    cursor: pointer;
    border: none;
    min-height: 40px;
    background: transparent;
    color: #645C50;
}

    .pp-vista-btn.is-active {
        background: #9B2243;
        color: #fff;
    }

.pp-resumen-filtro {
    font-size: 16px;
    color: #645C50;
    margin: 0 0 14px;
}

.pp-sesion-card {
    background: #fff;
    border-radius: 28px;
    padding: 24px;
    box-shadow: 0 1px 2px rgba(46, 43, 37, .14);
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.pp-sesion-card-titulo {
    font-size: 22px;
    font-weight: 700;
    margin: 0;
    line-height: 1.25;
}

.pp-sesion-card-meta {
    display: flex;
    gap: 18px;
    flex-wrap: wrap;
    font-size: 15px;
    color: #645C50;
}

/* Vista calendario */

.pp-cal-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
    gap: 14px;
}

.pp-cal-mes {
    background: #fff;
    border-radius: 16px;
    padding: 16px;
    box-shadow: 0 1px 2px rgba(46, 43, 37, .14);
    display: flex;
    flex-direction: column;
    gap: 10px;
    min-height: 120px;
}

.pp-cal-mes-nombre {
    font-size: 13px;
    font-weight: 800;
    letter-spacing: .1em;
    text-transform: uppercase;
    color: #A19786;
}

.pp-cal-mes-nombre--con-sesiones {
    color: #780E3F;
}

.pp-cal-sesiones {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.pp-cal-sesion {
    text-align: left;
    font: inherit;
    border: none;
    background: #F7E3E8;
    border-radius: 12px;
    padding: 10px 12px;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-height: 44px;
    width: 100%;
}

    .pp-cal-sesion:hover {
        background: #F0D2DA;
    }

    .pp-cal-sesion strong {
        font-size: 14px;
        font-weight: 800;
        color: #780E3F;
    }

    .pp-cal-sesion span {
        font-size: 13px;
        color: #645C50;
    }

.pp-cal-vacio {
    font-size: 13px;
    color: #A19786;
}

/* Detalle de sesión */

.pp-detalle-header {
    background: #fff;
    border-bottom: 1px solid #DCD3C4;
}

.pp-detalle-header-inner {
    padding: 26px 20px 30px;
}

.pp-detalle-back {
    border: none;
    background: transparent;
    color: #9B2243;
    font: inherit;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    padding: 8px 0;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 44px;
}

    .pp-detalle-back:hover {
        color: #780E3F;
    }

.pp-detalle-chips {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin: 10px 0 12px;
}

.pp-detalle-titulo {
    font-family: 'Caprasimo', system-ui, sans-serif;
    font-weight: 400;
    font-size: clamp(28px, 5vw, 46px);
    line-height: 1.1;
    margin: 0 0 12px;
    color: #2e2b25;
    max-width: 26ch;
}

.pp-detalle-meta {
    font-size: 18px;
    color: #645C50;
    margin: 0 0 22px;
    line-height: 1.5;
}

.pp-acta-card {
    background: #F9F4ED;
    border: 1px solid #DCD3C4;
    border-radius: 28px;
    padding: 22px;
    display: flex;
    gap: 18px;
    align-items: center;
    flex-wrap: wrap;
}

.pp-acta-icono {
    flex: 0 0 auto;
    width: 56px;
    height: 56px;
    border-radius: 999px;
    background: #9B2243;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
}

.pp-acta-texto {
    flex: 1 1 240px;
    min-width: 0;
}

    .pp-acta-texto strong {
        font-size: 18px;
        font-weight: 700;
        display: block;
    }

    .pp-acta-texto span {
        font-size: 15px;
        color: #645C50;
        margin-top: 3px;
        display: block;
    }

.pp-acta-botones {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.pp-detalle-grid {
    padding-top: 34px;
    padding-bottom: 60px;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 28px;
    align-items: start;
}

.pp-orden-dia {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.pp-punto-card {
    background: #fff;
    border-radius: 28px;
    padding: 24px;
    box-shadow: 0 1px 2px rgba(46, 43, 37, .14);
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.pp-punto-encabezado {
    display: flex;
    gap: 14px;
    align-items: flex-start;
}

.pp-punto-num {
    flex: 0 0 auto;
    width: 40px;
    height: 40px;
    border-radius: 999px;
    background: #F9F4ED;
    color: #645C50;
    font-size: 17px;
    font-weight: 800;
    display: flex;
    align-items: center;
    justify-content: center;
}

.pp-punto-titulo {
    font-size: 19px;
    font-weight: 700;
    margin: 0;
    line-height: 1.35;
    min-width: 0;
}

.pp-punto-descripcion {
    margin: 0;
    font-size: 16px;
    color: #645C50;
    line-height: 1.55;
}

.pp-punto-tramite {
    margin: 0;
    font-size: 15px;
    color: #A19786;
    font-style: italic;
}

.pp-punto-estado-fila {
    display: flex;
    gap: 10px;
    align-items: center;
    flex-wrap: wrap;
}

.pp-punto-estado {
    font-size: 14px;
    font-weight: 800;
    padding: 7px 16px;
    border-radius: 999px;
}

.pp-punto-estado--APROBADO {
    background: #E8F0E7;
    color: #2F5334;
}

.pp-punto-estado--RECHAZADO {
    background: #F7E0DE;
    color: #8A2620;
}

.pp-punto-estado--RETIRADO, .pp-punto-estado--PENDIENTE {
    background: #F9F4ED;
    color: #645C50;
}

.pp-punto-mayoria {
    font-size: 15px;
    color: #645C50;
}

.pp-barra {
    display: flex;
    height: 14px;
    border-radius: 999px;
    overflow: hidden;
    background: #EEE7DB;
}

.pp-barra-favor {
    background: #4A7B50;
}

.pp-barra-contra {
    background: #A8322B;
}

.pp-barra-abst {
    background: #C0B6A5;
}

.pp-barra-leyenda {
    display: flex;
    gap: 18px;
    flex-wrap: wrap;
    font-size: 15px;
    color: #2e2b25;
}

.pp-barra-leyenda-item {
    display: flex;
    align-items: center;
    gap: 8px;
}

.pp-barra-dot {
    width: 12px;
    height: 12px;
    border-radius: 999px;
    flex: 0 0 auto;
}

.pp-barra-dot--favor {
    background: #4A7B50;
}

.pp-barra-dot--contra {
    background: #A8322B;
}

.pp-barra-dot--abst {
    background: #C0B6A5;
}

.pp-asistencia {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.pp-asistencia-card {
    background: #fff;
    border-radius: 28px;
    padding: 8px;
    box-shadow: 0 1px 2px rgba(46, 43, 37, .14);
}

.pp-asistencia-resumen {
    padding: 16px 16px 12px;
    display: flex;
    align-items: baseline;
    gap: 8px;
}

.pp-asistencia-num {
    font-family: 'Caprasimo', system-ui, sans-serif;
    font-size: 32px;
    line-height: 1;
    color: #9B2243;
}

.pp-asistencia-row {
    display: flex;
    gap: 12px;
    align-items: center;
    padding: 12px 16px;
    border-top: 1px solid #EEE7DB;
}

.pp-asistencia-info {
    flex: 1 1 auto;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

    .pp-asistencia-info strong {
        font-size: 16px;
        font-weight: 600;
        color: #2e2b25;
    }

.pp-asistencia-cargo {
    font-size: 13px;
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;
    color: #A19786;
}

.pp-asistencia-suplente {
    font-size: 14px;
    color: #645C50;
    font-style: italic;
}

.pp-asistencia-badge {
    flex: 0 0 auto;
    font-size: 13px;
    font-weight: 700;
    padding: 6px 12px;
    border-radius: 999px;
}

.pp-asistencia-badge--presente {
    background: #E8F0E7;
    color: #3C6642;
}

.pp-asistencia-badge--ausente {
    background: #F7E3E8;
    color: #780E3F;
}

.pp-vacio {
    color: #645C50;
    font-size: 16px;
}

/* Página de contenido largo tipo artículo (VC-090, aviso de privacidad) — el resto del portal
   público es de tarjetas/listas, esta es la primera con prosa/tabla extensas. */
.pp-prosa {
    max-width: 780px;
}

    .pp-prosa h1 {
        font-size: clamp(28px, 4vw, 40px);
    }

    .pp-prosa h2 {
        font-family: 'Caprasimo', system-ui, sans-serif;
        font-weight: 400;
        color: #780E3F;
        font-size: 24px;
        margin: 36px 0 12px;
        line-height: 1.2;
    }

    .pp-prosa p, .pp-prosa li {
        font-size: 16px;
        line-height: 1.6;
        color: #2e2b25;
    }

    .pp-prosa ul {
        margin: 0 0 16px;
        padding-left: 22px;
    }

    .pp-prosa code {
        background: #F7E3E8;
        color: #780E3F;
        padding: 1px 6px;
        border-radius: 6px;
        font-size: 15px;
    }

    .pp-prosa hr {
        border: none;
        border-top: 1px solid #DCD3C4;
        margin: 32px 0;
    }

.pp-prosa-pie {
    color: #A19786;
    font-size: 14px;
}

.pp-aviso-borrador {
    background: #FBF6EF;
    border: 1px solid #DCD3C4;
    border-left: 4px solid #9B2243;
    border-radius: 12px;
    padding: 18px 20px;
    font-size: 15px;
    line-height: 1.6;
    color: #645C50;
    margin: 0 0 28px;
}

    .pp-aviso-borrador code {
        background: #fff;
        padding: 1px 6px;
        border-radius: 6px;
    }

.pp-tabla-scroll {
    overflow-x: auto;
    margin: 0 0 16px;
    border-radius: 16px;
    box-shadow: 0 1px 2px rgba(46, 43, 37, .14);
}

    .pp-tabla-scroll table {
        width: 100%;
        border-collapse: collapse;
        background: #fff;
        font-size: 15px;
    }

    .pp-tabla-scroll th, .pp-tabla-scroll td {
        text-align: left;
        padding: 12px 16px;
        border-bottom: 1px solid #EEE7DB;
        vertical-align: top;
    }

    .pp-tabla-scroll th {
        background: #F9F4ED;
        font-size: 12px;
        font-weight: 800;
        letter-spacing: .06em;
        text-transform: uppercase;
        color: #A19786;
        white-space: nowrap;
    }

    .pp-tabla-scroll tbody tr:last-child td {
        border-bottom: none;
    }

/* VC-090: por debajo de 640px la tabla de datos personales no cabe cómoda — se deja con scroll
   horizontal (arriba) en vez de forzarla a una sola columna, para no perder la relación
   dato/origen/uso de cada renglón. */
@media (max-width: 640px) {
    .pp-tabla-scroll table {
        min-width: 640px;
    }
}
