/* ESTILOS GENERALES */
body {
    margin: 0;
    font-family: Arial, Helvetica, sans-serif;
    background: white;
    color: black;
}

header {
    background: #D6272C;
    color: white;
    padding: 20px;
    text-align: center;
}

.logo {
    width: 150px;   /* Ajusta el ancho */
}

.titulo {
    text-align: center;
     font-size: 12px; /* Tamaño pequeño */
}

h2 {
    color: red;
}

/* CONTENEDORES */
main {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 30px;
    padding: 20px;
}

.simulador, .formulario {
    width: 100%;
    max-width: 400px;
    background: #f5f5f5;
    border: 2px solid red;
    padding: 20px;
    border-radius: 10px;
}

/* INPUTS */
input, button {
    width: 90%;
    padding: 10px;
    margin-top: 8px;
    margin-bottom: 15px;
    border-radius: 5px;
    border: 1px solid black;
}

button {
    background: red;
    color: white;
    cursor: pointer;
    border: none;
    display: block;      /* convierte el botón en elemento de bloque */
    margin: 20px auto;   /* lo centra horizontalmente */
}
button:hover {
    background: black;
}

/* RESULTADO */
#resultado {
    margin-top: 10px;
    padding: 10px;
    background: white;
    border: 1px solid red;
}

.error {
    color: red;
}

/* RESPONSIVE */
@media (max-width: 600px) {
    main {
        flex-direction: column;
        align-items: center;
    }
}

.tasa-visible {
    font-size: 18px;
    font-weight: bold;
    color: red;
    margin-top: -5px;
    margin-bottom: 15px;
    padding: 0.5rem;
}

footer {
    background: #D6272C;   /* mismo color que header */
    color: white;
    text-align: center;
    padding: 20px;
    margin-top: 30px;
    font-size: 14px;
    border-top: 2px solid red;
}

footer p {
    margin: 5px 0;
}


.whatsapp-float {
    position: fixed;
    width: 65px;
    height: 65px;
    bottom: 25px;
    right: 25px;
    background-color: #25D366;
    color: #FFF;
    border-radius: 50%;
    text-align: center;
    font-size: 28px;
    box-shadow: 0px 3px 10px rgba(0,0,0,0.3);
    z-index: 999;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: transform .2s ease-in-out;
}

.whatsapp-float img {
    width: 38px;
    height: 38px;
}

.whatsapp-float:hover {
    transform: scale(1.1);
}

.alert {
    position: fixed;
    top: 20px;
    right: 20px;
    background-color: #4CAF50;
    color: white;
    padding: 15px 25px;
    border-radius: 5px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    font-family: Arial, sans-serif;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-width: 250px;
    max-width: 90%;
    animation: slideIn 0.5s ease-out;
    box-sizing: border-box;
}

@keyframes slideIn {
    from {opacity: 0; transform: translateX(100%);}
    to {opacity: 1; transform: translateX(0);}
}

.alert button {
    background: transparent;
    border: none;
    color: white;
    font-weight: bold;
    font-size: 16px;
    cursor: pointer;
    margin-left: 10px;
}

@media (max-width: 600px) {
    .alert {
        top: auto;
        bottom: 20px;
        right: 50%;
        transform: translateX(50%);
        padding: 12px 20px;
        font-size: 14px;
        min-width: 200px;
    }
}
