/* Estilos para el Modal y el Catálogo con Precios */

/* Modal base */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8);
    z-index: 1000;
    overflow-y: auto;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from {opacity: 0;}
    to {opacity: 1;}
}

/* Contenido del modal */
.modal-content {
    position: relative;
    background-color: #fff;
    margin: 5% auto;
    padding: 30px;
    width: 85%;
    max-width: 600px;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    animation: slideDown 0.4s ease;
}

@keyframes slideDown {
    from {transform: translateY(-50px); opacity: 0;}
    to {transform: translateY(0); opacity: 1;}
}

/* Botón para cerrar el modal */
.close-modal, .close-catalogo {
    position: absolute;
    top: 15px;
    right: 20px;
    font-size: 28px;
    font-weight: bold;
    color: #999;
    cursor: pointer;
    transition: 0.3s;
}

.close-modal:hover, .close-catalogo:hover {
    color: #C8A97E;
}

/* Encabezado del modal */
.modal-header {
    margin-bottom: 25px;
    padding-bottom: 20px;
    border-bottom: 1px solid #eee;
    text-align: center;
}

.modal-header h2 {
    color: #445566;
    font-size: 26px;
    margin-bottom: 10px;
}

.modal-header p {
    color: #777;
    font-size: 16px;
    line-height: 1.5;
}

/* Formulario dentro del modal */
.modal-form .form-group {
    margin-bottom: 20px;
}

.modal-form label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: #555;
}

.modal-form .form-control {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #ddd;
    border-radius: 6px;
    background-color: #f9f9f9;
    font-family: 'Montserrat', sans-serif;
    transition: border-color 0.3s, box-shadow 0.3s;
}

.modal-form .form-control:focus {
    border-color: #C8A97E;
    box-shadow: 0 0 0 3px rgba(200, 169, 126, 0.2);
    outline: none;
}

.modal-form small {
    color: #999;
    font-size: 12px;
}

/* Mensaje de estado del formulario */
.form-message {
    display: none;
    padding: 12px;
    margin-bottom: 20px;
    border-radius: 6px;
    text-align: center;
}

.form-message.success {
    display: block;
    background-color: #e6f7e9;
    color: #2e7d32;
    border: 1px solid #a5d6a7;
}

.form-message.error {
    display: block;
    background-color: #fdedee;
    color: #c62828;
    border: 1px solid #ef9a9a;
}

/* Botón del formulario */
.modal-form .form-button {
    width: 100%;
    background-color: #C8A97E;
    color: white;
    border: none;
    padding: 14px 20px;
    font-size: 16px;
    font-weight: 600;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s;
    margin-top: 10px;
}

.modal-form .form-button:hover {
    background-color: #b8996e;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

/* Estilos para el catálogo con precios */
.catalogo-content {
    max-width: 900px;
    width: 90%;
}

.catalogo-productos {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 25px;
    margin-bottom: 30px;
}

.producto-precio {
    background-color: #fff;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    transition: all 0.3s;
}

.producto-precio:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

.producto-precio img {
    width: 100%;
    height: 180px;
    object-fit: cover;
}

.producto-precio h3 {
    padding: 15px 15px 5px;
    font-size: 18px;
    color: #445566;
}

.producto-precio .descripcion {
    padding: 0 15px 10px;
    font-size: 14px;
    color: #777;
    min-height: 60px;
}

.producto-precio .precio {
    padding: 10px 15px;
    font-size: 18px;
    font-weight: 700;
    color: #C8A97E;
    background-color: #f9f7f2;
    text-align: center;
    border-top: 1px solid #eee;
}

#downloadCatalogo {
    display: block;
    width: 100%;
    max-width: 300px;
    margin: 0 auto;
    background-color: #445566;
}

#downloadCatalogo:hover {
    background-color: #3a4a59;
}

/* Responsive */
@media (max-width: 768px) {
    .modal-content {
        width: 90%;
        padding: 20px;
        margin: 10% auto;
    }
    
    .catalogo-productos {
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
        gap: 15px;
    }
}

@media (max-width: 576px) {
    .modal-content {
        width: 95%;
        padding: 15px;
        margin: 15% auto 5%;
    }
    
    .modal-header h2 {
        font-size: 22px;
    }
    
    .catalogo-productos {
        grid-template-columns: 1fr;
    }
    
    .producto-precio img {
        height: 200px;
    }
}