body {
    margin: auto;
    width: 100%;
    height: 100%;
    position: relative;
    background-image: url('../img/fondo.png');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-attachment: fixed;
    min-height: 100vh;
}

/* Contenedor para todo el contenido excepto modales */
.main-content {
    transition: filter 0.3s ease;
}

/* Efecto blur cuando se muestra el modal - solo al contenido principal */
.main-content.blur-background {
    filter: blur(2px);
}

/* Estilos para el modal de error */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.6);
}

.modal-content {
    background-color: #fefefe;
    margin: 15% auto;
    padding: 25px;
    border: none;
    border-radius: 15px;
    width: 80%;
    max-width: 400px;
    text-align: center;
    box-shadow: 0 8px 32px rgba(0,0,0,0.4);
    position: relative;
    z-index: 1001;
}

.modal-content h3 {
    color: #FF0000;
    margin-bottom: 15px;
}

.modal-content p {
    margin-bottom: 20px;
    font-size: 1.1em;
}

.close-btn {
    background: #6C1D45;
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 1em;
    transition: background-color 0.3s ease;
    min-width: 100px;
}

.close-btn:hover {
    background: #5a1538;
}

/* Estilos específicos para los botones del modal de inactividad */
.modal-buttons {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-top: 20px;
    flex-wrap: wrap;
}

.btn-continuar {
    background: #6C1D45;
}

.btn-continuar:hover {
    background: #5a1538;
}

.btn-salir {
    background: #999;
}

.btn-salir:hover {
    background: #777;
}

/* Responsive para los botones del modal */
@media (max-width: 480px) {
    .modal-buttons {
        flex-direction: column;
        align-items: center;
        gap: 10px;
    }
    
    .modal-buttons .close-btn {
        width: 80%;
        max-width: 200px;
    }
}

/* Barra superior */
.barra_superior {
    background-color: #6C1D45;
    color: white;
    padding: 15px 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    margin-bottom: 20px;
    min-height: 80px;
}

.barra_superior h4 {
    margin: 0;
    font-size: 1.4em;
    font-weight: bold;
    line-height: 1.2;
    text-align: center;
    flex-grow: 1;
    position: absolute;
    left: 0;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
}

.escudo_barra {
    width: 65px;
    height: 70px;
    position: absolute;
    right: 20px;
    flex-shrink: 0;
}

/* Media Query para dispositivos móviles */
@media (max-width: 768px) {
    .barra_superior {
        flex-direction: column;
        text-align: center;
        padding: 20px 15px;
        min-height: auto;
    }
    
    .barra_superior h4 {
        font-size: 1.2em;
        margin-bottom: 10px;
        position: relative;
        left: auto;
        right: auto;
        top: auto;
        transform: none;
    }
    
    .escudo_barra {
        position: relative;
        right: auto;
        width: 50px;
        height: 55px;
    }
}

.centrar {
    position: relative;
    text-align: center;
    background: rgba(221, 221, 221, 0.95);
    border-radius: 5px;
    padding: 10px;
    width: 300px;
    margin-top: 6%;
    left: 50%;
    transform: translate(-50%, -15%);
    backdrop-filter: blur(5px);
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
}

/* Media Query para hacer el formulario responsivo */
@media (max-width: 768px) {
    .centrar {
        width: 90%;
        max-width: 350px;
        margin-top: 40px;
        transform: translateX(-50%);
        position: relative;
        padding: 20px;
    }
}


.centrado{
  margin-left: auto;
  margin-right: auto;
}


.centrarx {
    position: relative;
    background: #ddd;
    border-radius: 5px;
    padding: 10px;
    width: 300px;
    margin-top: 8%;
    left: 50%;
    transform: translate(-50%, -15%);
}


.centrar2 {
    position: relative;
    background: #fff;
    top: 100px;
    left:  140px;
}

.centrar3 {
    position: center;
    background: #fff;
    border-radius: 5px;
    padding: 500px;
    width: 50px;
    margin-top: 0%;
    left: 50%;
    transform: translate(-50%, -15%);
    text-align: center;
}

.centrar4{ 
    position: relative;
    background: #000;
    border-radius: 5px;
    padding: 20px;
    width: 100px;
    margin-top: 8%;
    left: 50%;
    transform: translate(-50%, -15%);
}    

.Text {
    text-align: center;
    width: 600px;
    margin-top: 8%;
}

.Caja {
    width: 100%;
    display: block;
    font-size: 1.2em;
    text-align: center;
    margin-bottom: 15px;
    margin-top: 20px;
    border-radius: 8px;
    border: 1px solid #ccc;
    padding: 8px;
}

.Boton {
    margin: auto;
    background: #6C1D45;
    color: white;
    border: none;
    padding: 8px;
    margin-bottom: 20px;
    margin-top: 25px;
    width: 150px;
    display: block;
    font-size: 1.2em;
    text-align: center;
    border-radius: 8px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.Boton:hover {
    background: #5a1538;
}

.Entrar {
    width: 250px;
    background: #ddd;
}

td {
    text-align: center;
    padding: 12px 15px;
    border-bottom: 1px solid #ddd;
}

th {
    text-align: center;
    padding: 12px 15px;
    background-color: #6C1D45;
    color: white;
    font-weight: bold;
    border-bottom: 2px solid #5a1538;
}

tr:nth-child(even) {
    background-color: #f8f9fa;
}

tr:hover {
    background-color: #e9ecef;
    transition: background-color 0.3s ease;
}

/* Estilo moderno para la tabla */
table {
    width: 100%;
    max-width: 600px;
    margin: 20px auto;
    border-collapse: collapse;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
    border-radius: 8px;
    overflow: hidden;
    background-color: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(5px);
    table-layout: fixed;
}

/* Contenedor específico para tablas */
.tabla_contenedor {
    width: 100%;
    display: flex;
    justify-content: center;
    margin: 20px 0;
    overflow-x: auto;
}

.btn-descargar {
    display: inline-block;
    background: #6C1D45;
    color: #fff;
    border: none;
    border-radius: 8px;
    padding: 6px 16px;
    font-size: 1em;
    text-decoration: none;
    transition: background 0.3s;
    box-shadow: 0 2px 6px rgba(0,0,0,0.08);
    cursor: pointer;
    margin: 0 auto;
    width: 100px;
    text-align: center;
    white-space: nowrap;
}
.btn-descargar:hover {
    background: #5a1538;
}

/* Estilos para notas con tamaño de fuente uniforme */
.nota_uniforme {
    font-size: 1.2em;
}

.button {
    margin: auto;
    background: #6A5ACD;
    color: white;
    border: none;
    padding: 5px;
    margin-bottom: 50px;
    width: 150px;
    display: block;
    left: 51%;
    font-size: 1.2em;
    text-align: center;
}

.dx{
width: 100%;
margin: 2 auto;
text-align: center;
}

.dx1{
width: 100%;
margin: 2 auto;
text-align: center;
color: red;
}

/*Estilos para logo más pequeño*/
.logo_pequeno {
    width: 120px;
    height: 125px;
}

.logo_pequeno_buscar {
    width: 100px;
    height: 100px;
}

/* Media Queries adicionales para dispositivos móviles */
@media (max-width: 768px) {
    .Caja {
        font-size: 1.1em;
        padding: 12px;
        margin-bottom: 20px;
    }
    
    .Boton {
        font-size: 1.1em;
        padding: 12px;
        width: 160px;
        margin-top: 15px;
    }
    
    .centrar h5 {
        font-size: 1.1em;
        margin-bottom: 20px;
        line-height: 1.3;
    }
    
    .nota_uniforme {
        font-size: 1.1em !important;
        padding: 0 10px;
        line-height: 1.3;
    }
    
    /* Ajustes para la tabla en móviles */
    table {
        font-size: 0.9em;
        margin: 10px auto;
        max-width: 95%;
        table-layout: fixed;
    }
    
    .tabla_contenedor {
        padding: 0 10px;
        overflow-x: auto;
    }
    
    td, th {
        padding: 8px 5px;
        font-size: 0.85em;
        word-break: break-word;
    }
    
    .logo_pequeno {
        width: 100px;
        height: 105px;
    }
    
    .logo_pequeno_buscar {
        width: 80px;
        height: 80px;
    }
}

/* Media Query para pantallas muy pequeñas */
@media (max-width: 480px) {
    .barra_superior h4 {
        font-size: 1.0em;
        line-height: 1.4;
    }
    
    .centrar {
        width: 95%;
        padding: 15px;
        margin-top: 30px;
    }
    
    .escudo_barra {
        width: 45px;
        height: 50px;
    }
    
    /* Ajustes del fondo para móviles */
    body {
        background-attachment: scroll;
        background-size: cover;
        background-position: center top;
    }
}

/* Ajustes adicionales para el modal en móviles */
@media (max-width: 480px) {
    .modal-content {
        width: 90%;
        margin: 25% auto;
        padding: 15px;
    }
}

#imgx {
    width: 45%;
}
#imgz {
    width: 25%;
}