/* orders.css */
/* Shared Page Layouts */
.page-header { padding: 120px 20px 40px; text-align: center; background: var(--bg-secondary, #fdf6ec); }
.page-header h1 { font-family: 'Dancing Script', cursive; font-size: 3rem; margin-bottom: 10px; background: var(--gradient-primary, linear-gradient(135deg, #4A7CFF, #FF6B9D)); -webkit-background-clip: text; -webkit-text-fill-color: transparent; }
.page-header p { color: var(--text-secondary, #555); font-size: 1.1rem; }
.page-container { max-width: 1200px; margin: 0 auto; padding: 40px 20px; min-height: 50vh; }
.reading-layout { max-width: 800px; margin: 0 auto; line-height: 1.8; color: var(--text-secondary, #555); }

/* Filter Tabs */
.filter-tabs { display: flex; justify-content: center; gap: 10px; margin-bottom: 30px; flex-wrap: wrap; }
.filter-tab { padding: 8px 20px; border-radius: var(--radius-pill, 999px); border: 1px solid var(--glass-border, rgba(0,0,0,0.06)); background: var(--glass-bg, rgba(255,255,255,0.8)); cursor: pointer; font-weight: 500; transition: all 0.3s ease; }
.filter-tab:hover { background: #f0f0f0; }
.filter-tab.active { background: var(--gradient-primary, linear-gradient(135deg, #4A7CFF, #FF6B9D)); color: white; border-color: transparent; }

/* Order Cards */
.orders-grid { display: flex; flex-direction: column; gap: 20px; }
.order-card { background: white; border: 1px solid var(--glass-border, rgba(0,0,0,0.06)); border-radius: var(--radius-lg, 16px); padding: 20px; display: flex; flex-direction: column; gap: 15px; box-shadow: var(--shadow-sm, 0 2px 8px rgba(0,0,0,0.06)); transition: all 0.3s ease; }
.order-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-md, 0 4px 16px rgba(0,0,0,0.1)); }
.order-header { display: flex; justify-content: space-between; align-items: center; border-bottom: 1px solid #eee; padding-bottom: 10px; flex-wrap: wrap; gap: 10px; }
.order-id { font-weight: 600; color: var(--text-primary, #1a1a1a); }
.order-date { font-size: 0.9rem; color: var(--text-muted, #888); }
.order-total { font-weight: 700; color: var(--text-primary); }

/* Status Badges */
.status-badge { padding: 4px 12px; border-radius: var(--radius-pill, 999px); font-size: 0.85rem; font-weight: 600; display: inline-flex; align-items: center; gap: 6px; }
.status-badge.pending { background: #fff3cd; color: #856404; }
.status-badge.accepted { background: #cce5ff; color: #004085; }
.status-badge.packed { background: #e2e3e5; color: #383d41; }
.status-badge.ready { background: #d1ecf1; color: #0c5460; }
.status-badge.shipped { background: #d1ecf1; color: #0c5460; }
.status-badge.in_transit { background: #cce5ff; color: #004085; }
.status-badge.out_for_delivery { background: #ffe8a1; color: #d39e00; }
.status-badge.delivered { background: #d4edda; color: #155724; }
.status-badge.cancelled, .status-badge.rejected { background: #f8d7da; color: #721c24; }

/* Order Actions */
.order-actions { display: flex; justify-content: flex-end; gap: 10px; margin-top: 10px; }
.btn-outline { padding: 8px 16px; border: 1px solid var(--accent-blue, #4A7CFF); color: var(--accent-blue, #4A7CFF); border-radius: var(--radius-sm, 8px); background: transparent; text-decoration: none; font-weight: 500; transition: all 0.3s; cursor: pointer; display: inline-block; }
.btn-outline:hover { background: var(--accent-blue, #4A7CFF); color: white; }
.btn-primary { padding: 8px 16px; border: none; background: var(--gradient-primary); color: white; border-radius: var(--radius-sm, 8px); text-decoration: none; font-weight: 500; transition: all 0.3s; cursor: pointer; display: inline-block; }
.btn-primary:hover { opacity: 0.9; transform: scale(1.02); }

/* Order Detail */
.breadcrumb { margin-bottom: 20px; font-size: 0.9rem; color: var(--text-muted); }
.breadcrumb a { color: var(--accent-blue); text-decoration: none; }
.order-detail-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 30px; flex-wrap: wrap; gap: 15px; }

/* Tracking Timeline */
.timeline-container { background: white; padding: 30px; border-radius: var(--radius-lg); box-shadow: var(--shadow-sm); margin-bottom: 30px; }
.timeline { position: relative; margin: 20px 0; padding-left: 20px; }
.timeline-step { display: flex; gap: 20px; margin-bottom: 30px; position: relative; }
.timeline-step:last-child { margin-bottom: 0; }
.step-indicator { display: flex; flex-direction: column; align-items: center; position: relative; }
.step-circle { width: 32px; height: 32px; border-radius: 50%; display: flex; align-items: center; justify-content: center; z-index: 2; background: white; border: 2px solid #ddd; color: #ddd; font-weight: bold; }
.step-circle.completed { background: var(--gradient-primary); border: none; color: white; }
.step-circle.current { border: 2px solid var(--accent-blue); color: var(--accent-blue); animation: pulse-border 2s infinite; }
@keyframes pulse-border { 0% { box-shadow: 0 0 0 0 rgba(74, 124, 255, 0.4); } 70% { box-shadow: 0 0 0 10px rgba(74, 124, 255, 0); } 100% { box-shadow: 0 0 0 0 rgba(74, 124, 255, 0); } }
.step-line { position: absolute; top: 32px; bottom: -30px; left: 15px; width: 2px; background: #ddd; z-index: 1; }
.timeline-step:last-child .step-line { display: none; }
.step-line.completed { background: var(--gradient-primary); }
.step-content { padding-top: 5px; flex: 1; }
.step-content h4 { margin: 0 0 5px; color: var(--text-muted); font-weight: 500; }
.timeline-step.completed .step-content h4, .timeline-step.current .step-content h4 { color: var(--text-primary); font-weight: 600; }
.step-time { font-size: 0.85rem; color: var(--text-muted); }

/* Order Details Grid */
.order-details-grid { display: grid; grid-template-columns: 2fr 1fr; gap: 20px; }
@media (max-width: 768px) { .order-details-grid { grid-template-columns: 1fr; } }
.detail-card { background: white; padding: 20px; border-radius: var(--radius-lg); box-shadow: var(--shadow-sm); }
.detail-card h3 { margin-top: 0; margin-bottom: 15px; font-family: 'Inter', sans-serif; font-size: 1.1rem; border-bottom: 1px solid #eee; padding-bottom: 10px; }
.order-item-list { display: flex; flex-direction: column; gap: 15px; }
.order-item-row { display: flex; align-items: center; gap: 15px; }
.order-item-img { width: 60px; height: 60px; border-radius: var(--radius-sm); object-fit: cover; background: #f5f5f5; }
.order-item-info { flex: 1; }
.order-item-info h4 { margin: 0 0 5px; font-size: 0.95rem; }
.order-item-qty { font-size: 0.85rem; color: var(--text-muted); }
.order-item-price { font-weight: 600; }

/* Summary & Delivery */
.summary-row { display: flex; justify-content: space-between; margin-bottom: 10px; font-size: 0.95rem; }
.summary-row.total { border-top: 1px solid #eee; padding-top: 10px; font-weight: 700; font-size: 1.1rem; color: var(--text-primary); margin-bottom: 0; }
.summary-row.discount { color: var(--accent-green, #28a745); }
.delivery-info p { margin: 5px 0; font-size: 0.95rem; color: var(--text-secondary); }

/* Accordion */
.accordion { display: flex; flex-direction: column; gap: 15px; }
.accordion-item { background: white; border: 1px solid var(--glass-border); border-radius: var(--radius-md); overflow: hidden; }
.accordion-header { padding: 15px 20px; display: flex; justify-content: space-between; align-items: center; cursor: pointer; background: var(--glass-bg); font-weight: 600; transition: background 0.2s; }
.accordion-header:hover { background: #f9f9f9; }
.accordion-header .icon { transition: transform 0.3s; }
.accordion-item.active .accordion-header .icon { transform: rotate(180deg); }
.accordion-content { max-height: 0; overflow: hidden; transition: max-height 0.3s ease-out; }
.accordion-content-inner { padding: 15px 20px; color: var(--text-secondary); border-top: 1px solid #eee; }
