* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --bg: #f8f6f2;
  --card: #fff;
  --text: #333;
  --text-muted: #666;
  --primary: #c45c26;
  --primary-hover: #a84d1f;
  --border: #e8e4dc;
  --radius: 8px;
  --shadow: 0 1px 3px rgba(0,0,0,0.08);
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  padding-bottom: 2rem;
}

.app {
  max-width: 480px;
  margin: 0 auto;
  min-height: 100vh;
}

/* 头部 */
.header {
  background: linear-gradient(135deg, #c45c26 0%, #d67a3d 100%);
  color: #fff;
  padding: 1.5rem 1rem 2rem;
  text-align: center;
}

.header h1 {
  font-size: 1.75rem;
  font-weight: 600;
  letter-spacing: 0.1em;
}

.subtitle {
  font-size: 0.9rem;
  opacity: 0.9;
  margin-top: 0.25rem;
}

/* 内容区 */
.main {
  padding: 1rem;
  margin-top: -1rem;
}

.section {
  background: var(--card);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 1.25rem;
  margin-bottom: 1rem;
}

.section h2 {
  font-size: 1rem;
  color: var(--text-muted);
  font-weight: 500;
  margin-bottom: 1rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid var(--border);
}

/* 菜单列表 */
.menu-list {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.menu-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.75rem;
  background: var(--bg);
  border-radius: var(--radius);
}

.menu-item .info {
  flex: 1;
}

.menu-item .name {
  font-weight: 500;
}

.menu-item .price {
  font-size: 0.85rem;
  color: var(--primary);
  margin-top: 0.15rem;
}

.menu-item .qty-wrap {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.menu-item .qty-btn {
  width: 32px;
  height: 32px;
  border: 1px solid var(--border);
  background: var(--card);
  border-radius: 6px;
  font-size: 1.1rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s;
}

.menu-item .qty-btn:active {
  background: var(--border);
}

.menu-item .qty-num {
  min-width: 1.5rem;
  text-align: center;
  font-weight: 500;
}

.loading, .empty {
  color: var(--text-muted);
  font-size: 0.9rem;
  text-align: center;
  padding: 1rem;
}

/* 购物车 */
.cart-items {
  min-height: 2rem;
}

.cart-item {
  display: flex;
  justify-content: space-between;
  padding: 0.5rem 0;
  border-bottom: 1px solid var(--border);
  font-size: 0.95rem;
}

.cart-item:last-child {
  border-bottom: none;
}

.cart-total {
  margin-top: 0.75rem;
  padding-top: 0.75rem;
  border-top: 1px solid var(--border);
  font-size: 1rem;
}

.cart-total strong {
  color: var(--primary);
  font-size: 1.2rem;
}

/* 表单 */
.form {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.form-group label {
  font-size: 0.9rem;
  color: var(--text-muted);
}

.form-group input {
  padding: 0.75rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-size: 1rem;
  background: var(--card);
}

.form-group input:focus {
  outline: none;
  border-color: var(--primary);
}

.hint {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin: -0.5rem 0 0;
}

.btn {
  padding: 0.85rem 1.25rem;
  border: none;
  border-radius: var(--radius);
  font-size: 1rem;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.2s;
}

.btn-primary {
  background: var(--primary);
  color: #fff;
}

.btn-primary:hover, .btn-primary:focus {
  background: var(--primary-hover);
}

.btn-primary:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.btn-secondary {
  background: var(--border);
  color: var(--text);
}

.btn-secondary:hover, .btn-secondary:focus {
  background: #ddd;
}

/* Toast */
.toast {
  position: fixed;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%) translateY(100px);
  background: rgba(0,0,0,0.8);
  color: #fff;
  padding: 0.75rem 1.25rem;
  border-radius: var(--radius);
  font-size: 0.95rem;
  max-width: 90%;
  opacity: 0;
  transition: transform 0.3s, opacity 0.3s;
  z-index: 1000;
  pointer-events: none;
}

.toast.show {
  transform: translateX(-50%) translateY(0);
  opacity: 1;
}
