/* Contenedor general del modal (dialog o div) */
/* Fondo oscuro */

/* CABEZAL */
.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;   /* <-- separa logo a la izq y texto a la derecha */
    gap: 15px;
    background: white;          /* Fondo blanco del cabezal */
    /*padding: 10px 0 11px 0;
    border-bottom: 1px solid #ddd;*/
}

.modal-logo {
    height: 58px;               /* ajustable */
}

.modal-header-text {
    display: flex;
    flex-direction: column;
    line-height: 1.1;
    text-align: left;
}

.modal-header-text .anio {
    font-size: 22px;
    font-weight: 700;
    color: #0D8F3C;             /* verde */
}

.modal-header-text .inscripciones {
    font-size: 16px;
    font-weight: 600;
    color: #0D8F3C;
    margin-right: 20px;
}

/* =======================
   MODAL - CONTENEDOR
   ======================= */

/* Fondo gris pálido del cuerpo del formulario */
.modal-body {
    background: #f0f0f0;     /* gris muy suave */
    padding: 5px 20px 11px 17px;
    border-radius: 0 0 12px 12px;   /* esquinas inferiores */
}

.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.55);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 99999;
}

.modal.show {
    display: flex;
}

/* Caja interior */
.modal-box {
    width: 420px;
    background: #f3f3f3;
    padding: 3px 3px;
    border-radius: 13px;
    position: relative;
    font-family: 'Jost', sans-serif;
}

/* Botón X */
.modal-close {
    position: absolute;
    right: 4px;
    top: -1px;
    background: none;
    border: none;
    font-size: 22px;
    cursor: pointer;
}
.modal-close:hover {
    color: #0D8F3C;
    font-weight: bold;
}

/* =======================
   TÍTULO
   ======================= */
.modal-title {
    font-size: 19px;
    font-weight: 500;
    text-align: left;
    margin-bottom: 8px;
}

/* =======================
   CAMPOS DEL FORMULARIO
   ======================= */
.form-row {
    display: flex;
    border: 1.5px solid #0D8F3C;
    border-radius: 4px;
    margin-bottom: 16px;
    overflow: hidden; /* clave para que el borde sea continuo */
}

/* Label a la izquierda */
.form-label {
    width: 114px;
    padding: 9px;
    font-size: 18px;
    border-right: 1.5px solid #0D8F3C;
    display: flex;
    align-items: normal;
    box-sizing: border-box;
    background: white;
}

/* Inputs */
.form-row input {
    flex: 1;
    padding: 10px;
    border: none !important;
    outline: none;
    font-size: 18px;
    background: white;
}

/* =======================
   TEXTAREA
   ======================= */
.form-row textarea {
    flex: 1;
    padding: 10px;
    min-height: 110px;
    resize: vertical;
    border: none !important;
    outline: none !important;
    background: white;
    box-sizing: border-box;
    font-size: 18px;
}

.btn-enviar2 {
    background: rgb(1, 146, 71);
    color: white;
    width: 40%;
    font-size: 18px;
    border-radius: 4px;
    /*margin: auto;*/
    padding: 6px 50px;
    cursor: pointer;
}

.btn-enviar2:active {
    transform: scale(1.07);
}

.btn-enviar2:hover {
    background: rgb(10,166,91);
}

.btn-cancelar {
    background: rgb(255, 20, 20);
    color: white;
    width: 40%;
    font-size: 18px;
    border-radius: 4px;
    /*margin: auto;*/
    padding: 6px 50px;
    cursor: pointer;
}

.btn-cancelar:active {
    transform: scale(1.07);
}

.btn-cancelar:hover {
    background: rgb(255,114,120);
}


/* ============================
   RESPONSIVE
   ============================ */

/* Hasta 480px (celulares) */
@media (max-width: 480px) {

    .modal-box {
        width: 90%;
        max-width: 420px;   /* mantiene tu tamaño original en desktop */
        margin: 0 10px;
    }

    .modal-title {
        font-size: 16px;
    }
    
    .modal-header {
        flex-direction: row;
        gap: 10px;
        padding: 10px;
    }

    .modal-logo {
        height: 48px;
    }

    .modal-header-text .anio {
        font-size: 20px;
    }

    .modal-header-text .inscripciones {
        font-size: 15px;
    }

    /* Ajusta etiquetas e inputs */
    .form-label {
        width: 89px;
        font-size: 16px;
        padding: 8px;
    }

    .form-row input,
    .form-row textarea {
        font-size: 16px;
        padding: 8px;
    }

    .btn-enviar2 {
        width: 50%;
        font-size: 17px;
        padding: 8px 0;
    }
}

@media (max-width: 388px) {

    .modal-header-text .inscripciones {
        font-size: 12px;
    }

}

@media (max-width: 355px) {

    .modal-header-text .inscripciones {
        font-size: 10px;
    }

}