/* 乐淘无忧商行 - 桌面版全宽布局 */
* { margin: 0; padding: 0; box-sizing: border-box; }
body { font-family: 'Microsoft YaHei', 'PingFang SC', -apple-system, sans-serif; background: #f0f2f5; color: #333; font-size: 15px; min-height: 100vh; display: flex; flex-direction: column; }
a { text-decoration: none; color: #1a73e8; }
a:hover { color: #1557b0; }

.container { width: 100%; padding: 0 40px; margin: 0 auto; }

/* ========== 头部导航 - 全宽 ========== */
.site-header { background: #fff; box-shadow: 0 2px 8px rgba(0,0,0,0.08); position: sticky; top: 0; z-index: 100; }
.header-inner { display: flex; align-items: center; justify-content: space-between; height: 64px; gap: 40px; }
.logo { font-size: 24px; font-weight: 700; color: #1a73e8 !important; white-space: nowrap; letter-spacing: 1px; }
.main-nav { display: flex; gap: 6px; align-items: center; }
.main-nav a { padding: 9px 18px; border-radius: 8px; color: #555; font-size: 15px; font-weight: 500; transition: all 0.2s; white-space: nowrap; }
.main-nav a:hover { background: #e8f0fe; color: #1a73e8; }
.main-nav a.active { background: #1a73e8; color: #fff; }
.user-info-header { display: flex; align-items: center; gap: 12px; font-size: 14px; white-space: nowrap; }
.user-info-header .badge { background: #e8f0fe; color: #1a73e8; padding: 4px 10px; border-radius: 4px; font-size: 12px; font-weight: 500; }
.user-info-header .balance { color: #f5222d; font-weight: 600; }

/* 底部 */
.site-footer { margin-top: auto; background: #fff; border-top: 1px solid #e8e8e8; padding: 28px 0; text-align: center; color: #999; font-size: 14px; }

/* 主内容 */
main { padding: 24px 0; flex: 1; }

/* Flash消息 */
.flash-msg { background: #e6f7ff; border: 1px solid #91d5ff; color: #0050b3; padding: 12px 20px; border-radius: 8px; margin-bottom: 20px; font-size: 15px; }

/* ========== 登录/注册 - 居中双栏 ========== */
.auth-page { background: linear-gradient(135deg, #1a73e8 0%, #1557b0 50%, #0d47a1 100%); min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 40px; }
.auth-container { max-width: 960px; width: 100%; display: grid; grid-template-columns: 1fr 1fr; background: #fff; border-radius: 16px; overflow: hidden; box-shadow: 0 20px 60px rgba(0,0,0,0.3); }
.auth-banner { background: linear-gradient(135deg, #1a73e8, #0d47a1); color: #fff; padding: 60px 40px; display: flex; flex-direction: column; justify-content: center; }
.auth-banner h1 { font-size: 32px; font-weight: 700; margin-bottom: 16px; }
.auth-banner p { font-size: 16px; opacity: 0.9; line-height: 1.6; }
.auth-form-side { padding: 48px 40px; display: flex; flex-direction: column; justify-content: center; }
.auth-form-side h2 { font-size: 28px; color: #1a73e8; margin-bottom: 32px; font-weight: 700; }
.auth-form-side .form-group { margin-bottom: 22px; }
.auth-form-side .form-group label { display: block; margin-bottom: 8px; font-size: 15px; color: #555; font-weight: 500; }
.auth-form-side .form-group input,
.auth-form-side .form-group select { width: 100%; padding: 13px 16px; border: 2px solid #e8e8e8; border-radius: 8px; font-size: 16px; transition: border 0.2s; outline: none; }
.auth-form-side .form-group input:focus,
.auth-form-side .form-group select:focus { border-color: #1a73e8; }
.auth-form-side .btn { width: 100%; padding: 14px; font-size: 17px; border-radius: 8px; font-weight: 600; }
.auth-form-side .form-footer { margin-top: 24px; font-size: 15px; color: #666; }

/* ========== 通用表单 ========== */
.form-group { margin-bottom: 20px; }
.form-group label { display: block; margin-bottom: 8px; font-size: 15px; color: #555; font-weight: 500; }
.form-group input, .form-group select, .form-group textarea { width: 100%; padding: 12px 16px; border: 2px solid #e8e8e8; border-radius: 8px; font-size: 15px; transition: border 0.2s; outline: none; background: #fff; }
.form-group input:focus, .form-group select:focus, .form-group textarea:focus { border-color: #1a73e8; box-shadow: 0 0 0 3px rgba(26,115,232,0.1); }
.form-group .help-text { font-size: 13px; color: #999; margin-top: 4px; }

/* ========== 按钮 ========== */
.btn { display: inline-block; padding: 11px 28px; border-radius: 8px; font-size: 15px; cursor: pointer; border: none; transition: all 0.2s; text-align: center; white-space: nowrap; font-weight: 500; }
.btn-primary { background: #1a73e8; color: #fff; }
.btn-primary:hover { background: #1557b0; }
.btn-success { background: #52c41a; color: #fff; }
.btn-success:hover { background: #389e0d; }
.btn-danger { background: #ff4d4f; color: #fff; }
.btn-danger:hover { background: #cf1322; }
.btn-warning { background: #faad14; color: #fff; }
.btn-warning:hover { background: #d48806; }
.btn-block { width: 100%; display: block; }
.btn-sm { padding: 6px 16px; font-size: 13px; }
.btn-lg { padding: 14px 36px; font-size: 17px; }
.btn:disabled { opacity: 0.6; cursor: not-allowed; }

.form-footer { margin-top: 24px; font-size: 15px; color: #666; display: flex; gap: 12px; flex-wrap: wrap; }

/* ========== 卡片 - 全宽 ========== */
.card { background: #fff; border-radius: 10px; box-shadow: 0 1px 4px rgba(0,0,0,0.06); overflow: hidden; margin-bottom: 16px; }
.card-header { padding: 16px 24px; border-bottom: 1px solid #f0f0f0; font-size: 16px; font-weight: 600; display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 12px; }
.card-body { padding: 24px; }
.card-body.no-padding { padding: 0; }

/* ========== 商品网格 ========== */
.items-grid { display: grid; grid-template-columns: repeat(5, 1fr); gap: 16px; margin-top: 16px; }
.item-card { background: #fff; border-radius: 10px; box-shadow: 0 1px 4px rgba(0,0,0,0.06); overflow: hidden; transition: transform 0.2s, box-shadow 0.2s; }
.item-card:hover { transform: translateY(-3px); box-shadow: 0 4px 16px rgba(0,0,0,0.12); }
.item-body { padding: 20px; }
.item-body h3 { font-size: 16px; margin-bottom: 12px; color: #1a73e8; font-weight: 600; }
.item-detail { display: flex; justify-content: space-between; padding: 6px 0; font-size: 13px; border-bottom: 1px dashed #f0f0f0; }
.item-detail:last-child { border-bottom: none; }
.item-detail .label { color: #888; min-width: 75px; }
.item-detail .value { color: #333; font-weight: 500; }
.item-footer { padding: 14px 20px; background: #fafafa; display: flex; justify-content: space-between; align-items: center; }
.item-price { font-size: 22px; font-weight: 700; color: #f5222d; }
.item-price small { font-size: 14px; font-weight: 400; }

.deposit-badge { display: inline-block; background: #fff7e6; color: #d46b08; font-size: 12px; padding: 3px 10px; border-radius: 4px; border: 1px solid #ffd591; }

/* 状态标签 */
.status-tag { display: inline-block; padding: 3px 10px; border-radius: 4px; font-size: 13px; font-weight: 500; }
.status-active { background: #f6ffed; color: #52c41a; border: 1px solid #b7eb8f; }
.status-submitted { background: #fff0f6; color: #c41d7f; border: 1px solid #ffadd2; }
.status-completed { background: #f6ffed; color: #389e0d; border: 1px solid #b7eb8f; }
.status-sold { background: #fff7e6; color: #fa8c16; border: 1px solid #ffd591; }
.status-disabled { background: #f5f5f5; color: #999; border: 1px solid #d9d9d9; }
.status-paid { background: #e6f7ff; color: #1890ff; border: 1px solid #91d5ff; }

/* 搜索条 */
.search-bar { background: #fff; border-radius: 10px; padding: 16px 24px; box-shadow: 0 1px 4px rgba(0,0,0,0.06); margin-bottom: 16px; }
.search-bar form { display: flex; gap: 12px; align-items: center; }
.search-bar input { flex: 1; padding: 11px 16px; border: 2px solid #e8e8e8; border-radius: 8px; font-size: 15px; outline: none; }
.search-bar input:focus { border-color: #1a73e8; }
.search-bar .btn { min-width: 100px; padding: 11px 24px; }

/* ========== 表格 ========== */
.table-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.data-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.data-table th { background: #fafafa; padding: 14px 16px; text-align: left; font-weight: 600; border-bottom: 2px solid #e8e8e8; white-space: nowrap; color: #555; font-size: 13px; }
.data-table td { padding: 14px 16px; border-bottom: 1px solid #f0f0f0; }
.data-table tbody tr:hover td { background: #fafafa; }

/* 面板页 */
.page-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 20px; flex-wrap: wrap; gap: 16px; }
.page-header h2 { font-size: 22px; color: #333; font-weight: 700; }

/* 余额显示 */
.balance-card { background: linear-gradient(135deg, #1a73e8, #1557b0); color: #fff; border-radius: 10px; padding: 28px; margin-bottom: 16px; display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 16px; }
.balance-card h3 { font-size: 14px; opacity: 0.9; margin-bottom: 4px; font-weight: 400; }
.balance-card .amount { font-size: 40px; font-weight: 700; }
.balance-card .actions { display: flex; gap: 10px; flex-wrap: wrap; }
.balance-card .actions .btn { background: rgba(255,255,255,0.2); color: #fff; }
.balance-card .actions .btn:hover { background: rgba(255,255,255,0.35); }

/* 充值页面 */
.recharge-options { display: grid; grid-template-columns: repeat(6, 1fr); gap: 12px; margin-bottom: 20px; }
.recharge-option { background: #fff; border: 2px solid #e8e8e8; border-radius: 10px; padding: 16px; text-align: center; cursor: pointer; transition: all 0.2s; }
.recharge-option:hover { border-color: #1a73e8; transform: translateY(-2px); }
.recharge-option.selected { border-color: #1a73e8; background: #e8f0fe; }
.recharge-option .amount { font-size: 22px; font-weight: 700; color: #333; }
.recharge-option .bonus { font-size: 12px; color: #52c41a; margin-top: 3px; }

/* 二维码弹窗 */
.qr-wrapper { text-align: center; padding: 20px; }
.qr-wrapper img { max-width: 260px; }

/* PC端多栏布局 */
.profile-layout { display: grid; grid-template-columns: 320px 1fr; gap: 16px; align-items: start; }
.order-detail-layout { display: grid; grid-template-columns: 2fr 1fr; gap: 16px; align-items: start; }

/* ========== 响应式 ========== */
@media (max-width: 1400px) {
    .items-grid { grid-template-columns: repeat(4, 1fr); }
    .recharge-options { grid-template-columns: repeat(4, 1fr); }
    .container { padding: 0 28px; }
}

@media (max-width: 1100px) {
    .items-grid { grid-template-columns: repeat(3, 1fr); }
    .recharge-options { grid-template-columns: repeat(3, 1fr); }
    .container { padding: 0 24px; }
    .order-detail-layout { grid-template-columns: 1fr; }
}

@media (max-width: 768px) {
    .container { padding: 0 14px; }
    .header-inner { flex-wrap: wrap; height: auto; padding: 10px 0; gap: 8px; justify-content: center; }
    .main-nav { width: 100%; justify-content: center; gap: 2px; }
    .main-nav a { padding: 7px 10px; font-size: 13px; }
    .user-info-header { width: 100%; justify-content: center; font-size: 13px; }
    main { padding: 14px 0; }
    .items-grid { grid-template-columns: 1fr; gap: 12px; }
    .recharge-options { grid-template-columns: repeat(2, 1fr); gap: 8px; }
    .profile-layout { grid-template-columns: 1fr; }
    .card-header { padding: 12px 16px; font-size: 15px; }
    .card-body { padding: 16px; }
    .balance-card { padding: 20px; }
    .balance-card .amount { font-size: 32px; }
    .page-header h2 { font-size: 18px; }
    .search-bar { padding: 12px 14px; }
    .search-bar form { flex-direction: column; }
    .data-table { font-size: 13px; }
    .data-table th, .data-table td { padding: 10px 12px; }
    .item-price { font-size: 18px; }
    .auth-container { grid-template-columns: 1fr; max-width: 480px; }
    .auth-banner { display: none; }
    .auth-form-side { padding: 32px 24px; }
    .auth-form-side h2 { font-size: 24px; }
    .logo { font-size: 20px; }
    .order-detail-layout { grid-template-columns: 1fr; }
}
