/* Stile del Modale */
.flow-recesso-modal {
    display: none;
    position: fixed;
    z-index: 99999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(5px);
}

.flow-recesso-modal-content {
    background-color: #fefefe;
    margin: 10% auto;
    padding: 30px;
    border: 1px solid #888;
    width: 90%;
    max-width: 500px;
    border-radius: 12px;
    position: relative;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}

.flow-recesso-modal-close {
    color: #aaa;
    position: absolute;
    top: 10px;
    right: 20px;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    transition: color 0.3s;
}

.flow-recesso-modal-close:hover,
.flow-recesso-modal-close:focus {
    color: #333;
    text-decoration: none;
    cursor: pointer;
}

/* CSS Pulsante (Footer e Ordini) */
.flow-recesso-btn,
.flow-recesso-order-btn,
.woocommerce-orders-table__cell-order-actions .recesso,
.woocommerce-orders-table__cell-order-actions .view {
    border: 1px solid;
    border-color: #705d4c !important;
    border-radius: 10px !important;
    padding: 5px 15px !important;
    background-color: transparent !important;
    transition: all .5s !important;
    color: #705d4c !important;
    display: inline-block;
    cursor: pointer;
    text-align: center;
    text-decoration: none;
    font-size: 1.1em;
}

.flow-recesso-btn:hover,
.flow-recesso-order-btn:hover,
.woocommerce-orders-table__cell-order-actions .recesso:hover,
.woocommerce-orders-table__cell-order-actions .view:hover {
    background-color: #705d4c !important;
    color: #ffffff !important;
}

/* Testo Recesso Inviato (Pagina Ordini) */
.flow-recesso-text-only,
.recesso_inviato {
    background: transparent !important;
    border: none !important;
    color: red !important;
    padding: 5px 0 !important;
    pointer-events: none !important;
    text-decoration: none !important;
    font-weight: 500 !important;
    font-size: 1.1em !important;
}

/* Testo Ordine Rimborsato in verde */
.flow-recesso-text-only.flow-recesso-refunded-text,
.recesso_rimborsato {
    background: transparent !important;
    border: none !important;
    color: #33974c !important;
    padding: 5px 0 !important;
    pointer-events: none !important;
    text-decoration: none !important;
    font-weight: 500 !important;
    font-size: 1.1em !important;
}

/* Stato disabilitato per ordini > 14 giorni */
.woocommerce-orders-table__cell-order-actions .flow-recesso-order-btn.disabled {
    opacity: 0.5;
    cursor: not-allowed;
    border-color: #999 !important;
    color: #999 !important;
}

.woocommerce-orders-table__cell-order-actions .flow-recesso-order-btn.disabled:hover {
    background-color: transparent !important;
    color: #999 !important;
}

/* Spinner per il caricamento */
.flow-recesso-loading {
    opacity: 0.7;
    pointer-events: none;
}

.woocommerce-orders-table__cell .woocommerce-orders-table__cell-order-actions {
    display: flex;
    justify-content: flex-end;
    gap: 15px;
    align-items: center;
}