* {
    box-sizing: border-box;
}

html,
body {
    width: 100%;
    min-height: 100%;
    margin: 0;
}

body {
    font-family: "Segoe UI", Arial, sans-serif;
    color: #102f68;
    background: #dceeff;
}

.pagina-trabajador {
    width: 100%;
    min-height: 100vh;
    background: linear-gradient(rgba(225, 242, 255, 0.78), rgba(235, 247, 255, 0.90)), url("./assets/img/backgrounds/fondo-login.png");
    background-repeat: no-repeat;
    background-position: center;
    background-size: cover;
}

.encabezado-principal {
    width: 100%;
    background: linear-gradient(90deg, #06275e 0%, #073b86 55%, #07326f 100%);
    box-shadow: 0 3px 10px rgba(0, 30, 80, 0.20);
}

.encabezado-contenido {
    width: min(100%, 1180px);
    min-height: 106px;
    margin: 0 auto;
    padding: 12px 46px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}

.contenedor-logo {
    width: 125px;
    height: 80px;
    display: flex;
    align-items: center;
    flex-shrink: 0;
}

.logo-martinrea {
    display: block;
    width: 110px;
    height: 72px;
    object-fit: contain;
}

.perfil-trabajador {
    display: flex;
    align-items: center;
    gap: 15px;
    color: #ffffff;
}

.icono-usuario {
    width: 54px;
    height: 54px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    background: #ffffff;
    border-radius: 50%;
}

.imagen-nomina {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.datos-trabajador {
    min-width: 140px;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.datos-trabajador strong {
    color: #ffffff;
    font-size: 20px;
    font-weight: 750;
}

.datos-trabajador span {
    color: #d8e8ff;
    font-size: 15px;
    font-weight: 500;
}

.badge-externo {
    padding: 8px 13px;
    border: 1px solid rgba(255, 255, 255, .28);
    border-radius: 999px;
    background: rgba(255, 255, 255, .12);
    color: #ffffff;
    font-size: 13px;
    font-weight: 800;
}

.contenido-principal {
    width: min(100%, 930px);
    margin: 0 auto;
    padding: 40px 34px 28px;
}

.titulo-pantalla {
    display: flex;
    align-items: center;
    gap: 28px;
    margin-bottom: 30px;
    padding: 0 36px;
}

.icono-calendario-grande {
    width: 78px;
    height: 78px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    color: #ffffff;
    background: linear-gradient(145deg, #0b438f, #022b68);
    border-radius: 50%;
    box-shadow: 0 8px 20px rgba(0, 49, 115, 0.18);
}

.icono-calendario-grande svg {
    width: 43px;
    height: 43px;
    fill: currentColor;
}

.etiqueta-superior {
    margin: 0 0 4px;
    color: #f26c23;
    font-size: 12px;
    font-weight: 900;
    letter-spacing: .12em;
    text-transform: uppercase;
}

.texto-titulo h1 {
    margin: 0 0 8px;
    color: #0a3274;
    font-size: 34px;
    font-weight: 800;
    line-height: 1.15;
}

.texto-titulo p {
    margin: 0;
    color: #3f4651;
    font-size: 18px;
    line-height: 1.45;
}

.tarjeta-identificacion,
.tarjeta-formulario {
    width: min(100%, 774px);
    margin: 0 auto 24px;
    padding: 28px 30px;
    background: rgba(255, 255, 255, 0.97);
    border-radius: 14px;
    box-shadow: 0 12px 28px rgba(24, 70, 118, .14);
}

.tarjeta-identificacion {
    display: grid;
    gap: 18px;
    border-top: 5px solid #f26c23;
}

.tarjeta-identificacion.validada {
    border-top-color: #1f8c4d;
}

.tarjeta-identificacion h2 {
    margin: 0 0 6px;
    color: #07326f;
}

.tarjeta-identificacion p,
.nota-seguridad {
    margin: 0;
    color: #4d5f72;
}

.formulario-nomina {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 14px;
    align-items: end;
}

.formulario-nomina label {
    display: flex;
    flex-direction: column;
    gap: 8px;
    font-weight: 800;
    color: #07326f;
}

.formulario-nomina input,
.campo-select {
    width: 100%;
    min-height: 58px;
    padding: 0 20px;
    color: #1f2d3d;
    background: #ffffff;
    border: 1px solid #b8c8da;
    border-radius: 10px;
    font-size: 16px;
    outline: none;
}

.formulario-nomina button,
.boton-guardar {
    min-height: 58px;
    padding: 0 28px;
    border: 0;
    border-radius: 10px;
    color: #ffffff;
    background: linear-gradient(135deg, #273b9a, #15318a);
    font-size: 16px;
    font-weight: 800;
    cursor: pointer;
}

.formulario-nomina button:disabled,
.boton-guardar:disabled {
    opacity: .65;
    cursor: progress;
}

.mensaje-validacion {
    min-height: 22px;
    color: #07326f;
    font-size: 14px;
    font-weight: 700;
}

.mensaje-validacion.error {
    color: #9f1f1f;
}

.mensaje-validacion.exito {
    color: #17633b;
}

.resumen-semana-trabajador {
    width: min(100%, 720px);
    margin: 0 auto 24px;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
}

.tarjeta-semana,
.tarjeta-dias-elegidos {
    min-height: 156px;
    padding: 16px 22px;
    display: flex;
    align-items: center;
    gap: 18px;
    background: rgba(255, 255, 255, 0.96);
    border-radius: 14px;
    box-shadow: 0 9px 22px rgba(31, 74, 121, 0.13);
}

.icono-semana,
.icono-dias-elegidos {
    width: 56px;
    height: 56px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    color: #06347b;
}

.icono-semana svg {
    width: 38px;
    height: 38px;
    fill: currentColor;
}

.icono-dias-elegidos {
    color: #ffffff;
    background: linear-gradient(145deg, #124a9a, #07326f);
    border-radius: 50%;
    font-size: 36px;
    font-weight: 800;
}

.datos-semana h2,
.datos-dias-elegidos h2 {
    margin: 0 0 8px;
    color: #092f73;
    font-size: 22px;
}

.datos-semana p,
.datos-dias-elegidos p {
    margin: 0 0 4px;
}

.fecha-limite-registro,
.datos-dias-elegidos small {
    display: block;
    margin-top: 10px;
    color: #9b4d00;
    font-size: 12px;
    font-weight: 800;
}

.chips-dias-elegidos {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
    margin-top: 8px;
}

.chip-dia {
    padding: 7px 12px;
    border-radius: 999px;
    background: #173b8f;
    color: #ffffff;
    font-size: 12px;
    font-weight: 800;
}

.grupo-formulario {
    margin-bottom: 28px;
}

.grupo-formulario h3,
.titulo-campo {
    display: block;
    margin: 0 0 12px;
    color: #07326f;
    font-size: 20px;
    font-weight: 800;
}

.contenedor-dias {
    display: flex;
    flex-wrap: wrap;
    gap: 30px;
}

.boton-dia input {
    position: absolute;
    opacity: 0;
}

.boton-dia span {
    width: 84px;
    height: 68px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #07326f;
    background: #ffffff;
    border: 1px solid #0b438f;
    border-radius: 9px;
    box-shadow: 0 8px 18px rgba(24, 70, 118, .12);
    font-size: 26px;
    font-weight: 900;
    cursor: pointer;
}

.boton-dia input:checked + span {
    color: #ffffff;
    background: linear-gradient(145deg, #0b438f, #022b68);
}

.boton-dia input:disabled + span {
    opacity: .45;
    cursor: not-allowed;
    border-color: #aab8c8;
}

.contenedor-select {
    position: relative;
}

.campo-select {
    appearance: none;
}

.campo-select:disabled {
    background: #eef3f8;
    color: #7b8da2;
}

.flecha-select::after {
    content: "";
    position: absolute;
    right: 22px;
    top: 50%;
    width: 12px;
    height: 12px;
    border-right: 3px solid #07326f;
    border-bottom: 3px solid #07326f;
    transform: translateY(-70%) rotate(45deg);
    pointer-events: none;
}

.texto-opciones {
    margin: 10px 0 0;
    color: #384b63;
    font-size: 14px;
}

.boton-agregar-uso {
    width: 100%;
    min-height: 86px;
    margin-bottom: 24px;
    padding: 16px 20px;
    display: flex;
    align-items: center;
    gap: 16px;
    border: 1px dashed #0b438f;
    border-radius: 14px;
    background: #f6fbff;
    color: #07326f;
    cursor: pointer;
}

.circulo-mas {
    width: 42px;
    height: 42px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    color: #ffffff;
    background: #0b438f;
    font-size: 26px;
    font-weight: 900;
}

.texto-agregar {
    display: flex;
    flex-direction: column;
    text-align: left;
}

.texto-agregar strong {
    font-size: 18px;
}

.texto-agregar small {
    margin-top: 4px;
    color: #4d5f72;
}

.contenedor-registros {
    margin-bottom: 24px;
    padding: 18px;
    border-radius: 12px;
    background: #eef6ff;
}

.contenedor-registros h3 {
    margin: 0 0 12px;
    color: #07326f;
}

.registro-agregado {
    margin-top: 10px;
    padding: 12px 14px;
    border-radius: 10px;
    background: #ffffff;
    border: 1px solid #d4e2f2;
    color: #23394f;
    font-weight: 700;
}

.lista-registros-vacia {
    color: #5d6f82;
}

.boton-guardar {
    width: 100%;
}

.aviso-inferior {
    margin-top: 18px;
    display: flex;
    gap: 12px;
    align-items: flex-start;
    color: #4d5f72;
    font-size: 14px;
}

.icono-informacion {
    width: 24px;
    height: 24px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    color: #ffffff;
    background: #0b438f;
    border-radius: 50%;
    font-weight: 900;
}

[hidden] {
    display: none !important;
}

@media (max-width: 760px) {
    .encabezado-contenido,
    .contenido-principal {
        padding-left: 18px;
        padding-right: 18px;
    }

    .encabezado-contenido,
    .titulo-pantalla {
        flex-direction: column;
        align-items: flex-start;
    }

    .formulario-nomina,
    .resumen-semana-trabajador {
        grid-template-columns: 1fr;
    }

    .titulo-pantalla {
        padding: 0;
    }

    .tarjeta-identificacion,
    .tarjeta-formulario {
        padding: 22px 18px;
    }

    .perfil-trabajador {
        align-items: flex-start;
        flex-wrap: wrap;
    }
}
