/* Elimina las flechas de los inputs numéricos en Chrome */
input[type="number"]::-webkit-inner-spin-button,
input[type="number"]::-webkit-outer-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

/* Estilos generales */
body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #f0f4f8;
    color: #333;
    margin: 0;
    padding: 30px;
}

.container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 50px;
}

/* Estilo para cada figura (rectángulo o triángulo) */
.figura {
    background-color: #fff;
    border: 2px solid #2ecc71;
    border-radius: 15px;
    padding: 25px;
    width: 320px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    text-align: center;
}

.figura h1 {
    color: #2ecc71;
    margin-bottom: 20px;
}

/* Inputs y etiquetas */
.figura label {
    display: block;
    text-align: left;
    width: 100%;
    margin-top: 12px;
    font-weight: 500;
}

.figura input {
    width: 100%;
    padding: 8px;
    margin-top: 5px;
    border: 1px solid #ccc;
    border-radius: 5px;
}

/* Botón de calcular */
.figura button {
    margin-top: 20px;
    background-color: #2ecc71;
    color: white;
    border: none;
    padding: 10px 15px;
    border-radius: 8px;
    cursor: pointer;
    font-weight: bold;
    transition: background-color 0.3s ease;
}

.figura button:hover {
    background-color: #27ae60;
}

/* Resultados */
.figura p {
    margin-top: 15px;
    font-weight: bold;
    color: #2c3e50;
}