/* Boton principal en ficha de producto y carrito */
.ce-boton-wrapper {
    margin: 15px 0;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
}

.ce-boton-carrito {
    margin-top: 20px;
}

.ce-boton-principal {
    background: #2d6a4f;
    color: #fff;
    border: none;
    padding: 12px 24px;
    font-size: 15px;
    font-weight: 600;
    border-radius: 6px;
    cursor: pointer;
    transition: background 0.2s;
}

.ce-boton-principal:hover {
    background: #1b4332;
}

.ce-boton-subtexto {
    font-size: 12px;
    color: #666;
}

/* Modal overlay */
.ce-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.55);
    z-index: 999999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.ce-modal {
    background: #fff;
    border-radius: 12px;
    max-width: 520px;
    width: 100%;
    padding: 32px;
    position: relative;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

.ce-modal-cerrar {
    position: absolute;
    top: 12px;
    right: 16px;
    background: none;
    border: none;
    font-size: 28px;
    cursor: pointer;
    color: #999;
    line-height: 1;
}

.ce-modal-cerrar:hover {
    color: #333;
}

.ce-modal h3 {
    margin: 0 0 16px;
    font-size: 20px;
    color: #1b4332;
}

/* Escalas de bonificacion */
.ce-escalas {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin: 20px 0;
}

.ce-escala {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    background: #f0f7f4;
    border-radius: 8px;
    border-left: 4px solid #2d6a4f;
}

.ce-escala-total {
    background: #d4edda;
    border-left-color: #155724;
}

.ce-escala-monto {
    font-size: 14px;
    color: #333;
}

.ce-escala-bonif {
    font-size: 14px;
    color: #1b4332;
}

.ce-nota {
    font-size: 12px;
    color: #888;
    margin: 10px 0 20px;
}

/* Boton secundario */
.ce-boton-secundario {
    background: #fff;
    color: #2d6a4f;
    border: 2px solid #2d6a4f;
    padding: 10px 20px;
    font-size: 14px;
    font-weight: 600;
    border-radius: 6px;
    cursor: pointer;
    width: 100%;
    transition: background 0.2s, color 0.2s;
}

.ce-boton-secundario:hover {
    background: #2d6a4f;
    color: #fff;
}

/* Formulario */
.ce-campo {
    margin-bottom: 14px;
}

.ce-campo label {
    display: block;
    font-size: 13px;
    color: #555;
    margin-bottom: 4px;
    font-weight: 500;
}

.ce-campo input,
.ce-campo select {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #ccc;
    border-radius: 6px;
    font-size: 14px;
    box-sizing: border-box;
}

.ce-campo input:focus,
.ce-campo select:focus {
    border-color: #2d6a4f;
    outline: none;
    box-shadow: 0 0 0 2px rgba(45, 106, 79, 0.15);
}

.ce-boton-cotizar {
    width: 100%;
    margin-top: 6px;
}

.ce-link-volver {
    background: none;
    border: none;
    color: #2d6a4f;
    cursor: pointer;
    font-size: 13px;
    padding: 8px 0;
    text-decoration: underline;
}

/* Resultados */
.ce-resultado {
    margin: 16px 0;
}

.ce-resultado-fila {
    display: flex;
    justify-content: space-between;
    padding: 10px 0;
    border-bottom: 1px solid #eee;
    font-size: 14px;
}

.ce-resultado-fila span {
    color: #666;
}

.ce-resultado-bonif strong {
    color: #2d6a4f;
}

.ce-resultado-final {
    border-bottom: none;
    padding: 14px 0;
    background: #f0f7f4;
    border-radius: 8px;
    padding: 14px 16px;
    margin-top: 8px;
}

.ce-resultado-final span,
.ce-resultado-final strong {
    font-size: 16px;
    color: #1b4332;
}

.ce-resultado-acciones {
    margin-top: 12px;
}

.ce-aclaracion {
    font-size: 11px;
    color: #999;
    font-style: italic;
    margin: 12px 0 0;
}

/* Loader */
.ce-loader {
    text-align: center;
    padding: 40px 0;
}

.ce-spinner {
    width: 36px;
    height: 36px;
    border: 3px solid #eee;
    border-top-color: #2d6a4f;
    border-radius: 50%;
    animation: ce-spin 0.7s linear infinite;
    margin: 0 auto 12px;
}

@keyframes ce-spin {
    to { transform: rotate(360deg); }
}

/* Error */
.ce-error {
    text-align: center;
    padding: 20px 0;
}

.ce-error p {
    color: #c0392b;
    font-size: 14px;
    margin-bottom: 16px;
}

/* Responsive */
@media (max-width: 540px) {
    .ce-modal {
        padding: 24px 20px;
        border-radius: 8px;
    }
    .ce-escala {
        flex-direction: column;
        align-items: flex-start;
        gap: 4px;
    }
}
