/* ========== 全局变量与重置 ========== */
:root {
    --primary: #ff6b35;
    --bg: #f4f5f7;
    --card: #fff;
    --text: #333;
    --text-light: #666;
    --border: #e8e8e8;
}
* { margin: 0; padding: 0; box-sizing: border-box; }
body { font-family: -apple-system, BlinkMacSystemFont, 'PingFang SC', sans-serif; }

/* ========== 通用按钮 ========== */
.btn {
    border-radius: 10px;
    padding: 9px 16px;
    border: none;
    background-color: #c9c9c9;
    color: #333;
    cursor: pointer;
    white-space: nowrap;
    transition: background-color 0.3s ease;
    font-size: 0.9rem;
}
.btn:hover { background-color: #dadada; }
.btn-success { background-color: #27ae60; color: #fff; }
.btn-success:hover { background-color: #219a52; }
.btn-primary { background-color: #f39c12; color: #fff; }
.btn-primary:hover { background-color: #e08e0b; }
.btn-danger { background-color: #e74c3c; color: #fff; }
.btn-danger:hover { background-color: #c0392b; }
.btn-sm { padding: 5px 10px; font-size: 0.8rem; }
.btn-xs { padding: 3px 6px; font-size: 0.65rem; border-radius: 4px; }

/* ========== 订单筛选栏 ========== */
button { cursor: pointer; }
.filter-bar { display: flex; gap: 10px; align-items: center; margin-bottom: 20px; flex-wrap: wrap; }
.filter-bar input { padding: 8px; border: 1px solid var(--border); border-radius: 8px; }
.filter-bar h2 { white-space: nowrap; }

/* ========== 订单卡片 ========== */
.order-card {
    background: var(--card); padding: 15px; margin-bottom: 10px; border-radius: 10px;
    border-left: 4px solid #f39c12;
    box-shadow: 4px 4px 5px #dfdfdf;
}
.order-card.status-confirmed { border-left-color: #3498db; }
.order-card.status-completed { border-left-color: #27ae60; }

/* ========== 全局自定义模态框 ========== */
.custom-modal {
    visibility: hidden;
    position: fixed; top:0; left:0; right:0; bottom:0;
    z-index: 900;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: visibility 0s 0.3s;
}
.custom-modal.open {
    visibility: visible;
    transition: visibility 0s 0s;
}
.custom-modal-mask {
    position: absolute; top:0; left:0; right:0; bottom:0;
    background: rgba(0,0,0,0.4);
    opacity: 0;
    transition: opacity 0.3s ease;
}
.custom-modal.open .custom-modal-mask { opacity: 1; }
.custom-modal-dialog {
    position: relative;
    background: #fff;
    border-radius: 16px;
    padding: 24px 28px;
    text-align: center;
    transform: scale(0.85);
    opacity: 0;
    transition: transform 0.3s ease, opacity 0.3s ease;
    z-index: 1;
    width: 90%;
    box-shadow: 0 12px 40px rgba(0,0,0,0.15);
}
.custom-modal.open .custom-modal-dialog {
    transform: scale(1);
    opacity: 1;
}
.custom-modal-header {
    font-size: 1.15rem;
    font-weight: 700;
    margin-bottom: 12px;
    text-align: left;
}
.custom-modal-body {
    font-size: 0.95rem;
    color: #555;
    text-align: left;
    margin-bottom: 16px;
    line-height: 1.6;
}
.custom-modal-footer {
    text-align: right;
}
.custom-modal-input {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #ddd;
    border-radius: 10px;
    font-size: 1rem;
    outline: none;
    box-sizing: border-box;
}
.custom-modal-input:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(255,107,53,0.15);
}

/* ========== 加餐选择弹窗（客户端用） ========== */
.order-choice-btns {
    display: flex;
    gap: 16px;
    justify-content: center;
    margin: 16px 0;
}
.order-choice-btn {
    flex: 1;
    max-width: 160px;
    padding: 20px 12px;
    border-radius: 16px;
    border: 2px solid #e8e8e8;
    background: #fff;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    transition: all 0.25s ease;
}
.order-choice-btn:hover {
    border-color: var(--primary);
    transform: translateY(-4px);
    box-shadow: 0 6px 20px rgba(255,107,53,0.15);
}
.order-choice-btn i {
    font-size: 2rem;
    color: var(--primary);
}
.order-choice-btn span {
    font-size: 1rem;
    font-weight: 600;
}
.order-choice-btn small {
    font-size: 0.75rem;
    color: #999;
}

/* ========== 加餐标记 ========== */
.addon-badge {
    display: inline-block;
    background: var(--primary);
    color: #fff;
    font-size: 0.6rem;
    padding: 1px 6px;
    border-radius: 8px;
    margin-left: 4px;
    font-weight: 600;
    vertical-align: middle;
}

/* ========== 小票按钮 ========== */
.order-ticket-btn {
    color: #bbb;
    cursor: pointer;
    font-size: 0.9rem;
    margin-left: 6px;
    transition: color 0.2s;
    vertical-align: middle;
}
.order-ticket-btn:hover { color: var(--primary); }
