:root {
    --primary-color: #4a6cf7;
    --secondary-color: #6c757d;
    --background-color: #f8f9fa;
    --border-color: #dee2e6;
    --text-color: #212529;
    --hover-color: #e9ecef;
    --card-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.mobile-user-orders {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    max-width: 100%;
    margin: 0;
    background: white;
    padding: 0;
    color: var(--text-color);
    position: relative;
    min-height: 100vh;
}

.orders-header {
    padding: 20px;
    background: linear-gradient(135deg, var(--primary-color), #2c4fd6);
    color: white;
    border-radius: 0 0 20px 20px;
    box-shadow: var(--card-shadow);
    margin-bottom: 20px;
}

.orders-header h2 {
    margin: 0;
    font-size: 1.4rem;
    text-align: center;
}

.orders-tabs {
    display: flex;
    border-bottom: 1px solid var(--border-color);
    margin: 0 10px;
}

.orders-tab {
    flex: 1;
    padding: 15px;
    background: none;
    border: none;
    cursor: pointer;
    font-weight: 500;
    color: var(--secondary-color);
    transition: all 0.3s;
    border-bottom: 2px solid transparent;
}

.orders-tab.active {
    color: var(--primary-color);
    border-bottom: 2px solid var(--primary-color);
}

.orders-content {
    padding: 15px 10px;
}

.orders-tab-content {
    display: none;
}

.orders-tab-content.active {
    display: block;
}

.order-card {
    background: white;
    border-radius: 12px;
    padding: 15px;
    margin-bottom: 15px;
    box-shadow: var(--card-shadow);
}

.order-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 12px;
    padding-bottom: 10px;
    border-bottom: 1px solid var(--border-color);
}

.order-id {
    font-weight: 600;
    color: var(--text-color);
}

.order-date {
    color: var(--secondary-color);
    font-size: 14px;
}

.order-details {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

.order-status {
    padding: 5px 10px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 500;
}

.status-processing {
    background-color: #e8f4ff;
    color: #0066cc;
}

.status-completed {
    background-color: #e6f7ee;
    color: #00a65a;
}

.status-on-hold {
    background-color: #fff8e6;
    color: #ff9900;
}

.status-cancelled {
    background-color: #ffe6e6;
    color: #ff3333;
}

.status-refunded {
    background-color: #f2f2f2;
    color: #666666;
}

.status-failed {
    background-color: #ffe6e6;
    color: #ff3333;
}

.status-pending {
    background-color: #fff8e6;
    color: #ff9900;
}

.order-total {
    font-weight: 600;
    color: var(--text-color);
}

.view-order-btn {
    display: block;
    text-align: center;
    padding: 12px;
    background-color: var(--primary-color);
    color: white;
    text-decoration: none;
    border-radius: 8px;
    font-weight: 500;
    transition: background-color 0.3s;
}

.view-order-btn:hover {
    background-color: #3a5cd8;
}

.no-orders {
    text-align: center;
    padding: 40px 20px;
    color: var(--secondary-color);
}

/* Support pour la langue arabe */
body[lang="ar"] .mobile-user-orders {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    direction: rtl;
    text-align: right;
}

body[lang="ar"] .order-header,
body[lang="ar"] .order-details {
    direction: rtl;
}


/* Modal Styles */
.order-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 1000;
    justify-content: center;
    align-items: center;
}

.order-modal.active {
    display: flex;
}

.modal-content {
    background-color: white;
    border-radius: 12px;
    width: 90%;
    max-width: 500px;
    max-height: 80vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
    border-bottom: 1px solid var(--border-color);
}

.modal-header h3 {
    margin: 0;
    font-size: 1.2rem;
}

.modal-close {
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: var(--secondary-color);
}

.modal-body {
    padding: 20px;
    overflow-y: auto;
    flex-grow: 1;
}

.modal-footer {
    padding: 15px 20px;
    border-top: 1px solid var(--border-color);
    text-align: right;
}

.modal-close-btn {
    padding: 10px 20px;
    background-color: var(--primary-color);
    color: white;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 500;
}

/* Order Details Styles */
.order-summary {
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 1px solid var(--border-color);
}

.summary-item {
    display: flex;
    justify-content: space-between;
    margin-bottom: 10px;
}

.summary-label {
    font-weight: 500;
    color: var(--secondary-color);
}

.summary-value {
    font-weight: 500;
}

.order-products {
    margin-bottom: 20px;
}

.order-products h4 {
    margin: 0 0 15px 0;
    font-size: 1.1rem;
    color: var(--text-color);
}

.product-item {
    display: flex;
    justify-content: space-between;
    margin-bottom: 15px;
    padding-bottom: 15px;
    border-bottom: 1px solid var(--border-color);
}

.product-name {
    flex: 2;
    font-weight: 500;
}

.product-quantity {
    flex: 1;
    text-align: center;
    color: var(--secondary-color);
    font-size: 14px;
}

.product-price {
    flex: 1;
    text-align: right;
    font-weight: 500;
}

.order-totals {
    border-top: 2px solid var(--border-color);
    padding-top: 15px;
}

.total-item {
    display: flex;
    justify-content: space-between;
    margin-bottom: 10px;
}

.total-label {
    font-weight: 500;
}

.total-value {
    font-weight: 500;
}

.grand-total {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--primary-color);
    margin-top: 10px;
    padding-top: 10px;
    border-top: 1px solid var(--border-color);
}

/* Support RTL pour le modal */
body[lang="ar"] .modal-header,
body[lang="ar"] .summary-item,
body[lang="ar"] .product-item,
body[lang="ar"] .total-item {
    direction: rtl;
}

body[lang="ar"] .modal-footer {
    text-align: left;
}




