/* ============================================================
   AI算力交易平台 - 全局样式
   结构：基础 / 首页(保持原UI) / 通用组件 / 各页面模块
   ============================================================ */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    -webkit-tap-highlight-color: transparent;
}

html { -webkit-text-size-adjust: 100%; }

body {
    background-color: #f4f6fa;
    color: #333;
    display: flex;
    justify-content: center;
    align-items: flex-start;
    min-height: 100vh;
}

/* 模拟移动端容器 */
.mobile-container {
    width: 100%;
    max-width: 430px;
    background: #f7f9fc;
    min-height: 100vh;
    position: relative;
    padding-bottom: 86px; /* 留出底部Tab栏空间 */
    box-shadow: 0 0 20px rgba(0,0,0,0.05);
}

/* ---------- 页面顶栏（首页之外的页面） ---------- */
.topbar {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 16px;
    background: #fff;
    position: sticky;
    top: 0;
    z-index: 90;
    box-shadow: 0 1px 0 rgba(226,232,240,0.6);
}

.tb-back {
    color: #2d3748;
    font-size: 15px;
    text-decoration: none;
    padding: 4px 6px 4px 0;
}

.tb-logo {
    width: 26px;
    height: 26px;
    background: linear-gradient(135deg, #1e6fff, #00d2ff);
    border-radius: 7px;
    color: #fff;
    font-size: 13px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex: none;
}

.tb-title {
    font-size: 17px;
    font-weight: 800;
    color: #1a202c;
    flex: 1;
    line-height: 1.2;
}

.tb-sub {
    font-size: 11px;
    color: #a0aec0;
    font-weight: normal;
    display: block;
    margin-top: 1px;
}

.tb-right {
    display: flex;
    align-items: center;
    gap: 16px;
    color: #4a5568;
    font-size: 17px;
    flex: none;
}

.tb-right a { color: inherit; }

.ic-wrap { position: relative; display: inline-flex; }
.ic-wrap .badge {
    position: absolute;
    top: -6px;
    right: -12px;
}

/* ---------- 首页 Header（保持原UI） ---------- */
.header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px;
    background: #fff;
}

.logo-area { display: flex; align-items: center; gap: 8px; }

.logo-icon {
    width: 32px;
    height: 32px;
    background: linear-gradient(135deg, #1e6fff, #00d2ff);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 16px;
}

.logo-title { font-size: 18px; font-weight: 800; color: #1a202c; }
.logo-subtitle { font-size: 11px; color: #a0aec0; }

.header-actions {
    display: flex;
    gap: 16px;
    color: #4a5568;
    font-size: 18px;
    align-items: center;
}

.header-actions a { color: inherit; }

/* 通用数字角标 */
.badge {
    background: #e53e3e;
    color: white;
    font-size: 10px;
    padding: 2px 5px;
    border-radius: 10px;
    font-weight: bold;
    line-height: 1.2;
}

/* ---------- 搜索框 ---------- */
.search-wrap { padding: 0 16px; margin-top: 12px; }

.search-container { padding: 0 16px 12px; background: #fff; }

.search-box {
    display: flex;
    background: #f1f5f9;
    border-radius: 10px;
    padding: 4px 6px 4px 12px;
    align-items: center;
    border: 1px solid #e2e8f0;
}

.search-box i { color: #a0aec0; margin-right: 8px; }

.search-box input {
    border: none;
    background: transparent;
    width: 100%;
    outline: none;
    font-size: 13px;
    min-width: 0;
}

.search-btn {
    background: #2563eb;
    color: white;
    border: none;
    padding: 6px 16px;
    border-radius: 6px;
    font-weight: 600;
    font-size: 13px;
    cursor: pointer;
    flex: none;
}

/* ---------- 横幅 Banner ---------- */
.banner {
    margin: 12px 16px;
    background: linear-gradient(135deg, #0f172a, #1e3a8a, #2563eb);
    border-radius: 16px;
    padding: 20px;
    color: white;
    position: relative;
    overflow: hidden;
}

.banner h2 { font-size: 20px; margin-bottom: 6px; }
.banner p { font-size: 12px; opacity: 0.8; margin-bottom: 16px; }

.banner-tags { display: flex; gap: 12px; font-size: 11px; opacity: 0.9; flex-wrap: wrap; }
.banner-tags span { display: flex; align-items: center; gap: 4px; }

/* 浅色提示卡 */
.tip {
    margin: 12px 16px;
    background: #ebf8ff;
    border: 1px solid #bee3f8;
    border-radius: 12px;
    padding: 12px 14px;
    font-size: 12px;
    color: #1e40af;
    line-height: 1.8;
}

.tip b { color: #1d4ed8; }

.tip .tip-t { font-weight: 700; font-size: 13px; color: #1e3a8a; display: flex; align-items: center; gap: 6px; }

/* ---------- 统计看板 ---------- */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
    margin: 0 16px 16px;
    background: #fff;
    padding: 14px 8px;
    border-radius: 12px;
    text-align: center;
}

.stat-icon {
    width: 28px;
    height: 28px;
    border-radius: 8px;
    margin: 0 auto 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
}

.stat-label { font-size: 11px; color: #718096; margin-bottom: 4px; }
.stat-value { font-size: 14px; font-weight: 700; color: #2b6cb0; }
.stat-unit { font-size: 10px; font-weight: normal; color: #a0aec0; }

/* ---------- 功能导航圈（首页宫格） ---------- */
.nav-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 8px;
    margin: 0 16px 20px;
    text-align: center;
}

.nav-item { display: flex; flex-direction: column; align-items: center; text-decoration: none; }

.nav-icon {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 18px;
    margin-bottom: 6px;
}

.nav-title { font-size: 12px; font-weight: bold; color: #2d3748; }
.nav-desc { font-size: 9px; color: #a0aec0; margin-top: 2px; }

/* ---------- 区块标题 ---------- */
.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 16px 10px;
}

.section-title { font-size: 16px; font-weight: bold; color: #1a202c; display: flex; align-items: center; gap: 6px; }
.more-link { font-size: 12px; color: #718096; text-decoration: none; }

/* ---------- 首页热门算力卡片 ---------- */
.cards-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    padding: 0 16px;
    margin-bottom: 20px;
}

.gpu-card {
    background: #fff;
    border-radius: 12px;
    padding: 10px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.03);
    border: 1px solid #edf2f7;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    position: relative;
}

.card-badge {
    position: absolute;
    top: 8px;
    right: 8px;
    background: #e6fffa;
    color: #319795;
    font-size: 9px;
    padding: 2px 4px;
    border-radius: 4px;
    font-weight: 600;
}

.gpu-title { font-size: 13px; font-weight: bold; margin-bottom: 6px; padding-right: 32px; white-space: nowrap; }

.gpu-img-box {
    height: 60px;
    margin-bottom: 6px;
}

.gpu-tags { display: flex; gap: 4px; flex-wrap: wrap; margin-bottom: 6px; }

.gpu-tag {
    font-size: 8px;
    padding: 2px 4px;
    border-radius: 3px;
    background: #ebf8ff;
    color: #3182ce;
    white-space: nowrap;
}

.gpu-tag.orange { background: #fffaf0; color: #dd6b20; }
.gpu-tag.green { background: #e6fffa; color: #319795; }

.gpu-price { color: #e53e3e; font-size: 13px; font-weight: bold; margin-bottom: 2px; }
.gpu-price span { font-size: 8px; color: #a0aec0; font-weight: normal; }
.gpu-stock { font-size: 9px; color: #718096; margin-bottom: 8px; }

.rent-btn {
    background: #2563eb;
    color: white;
    border: none;
    padding: 6px 0;
    border-radius: 6px;
    font-size: 11px;
    font-weight: 600;
    cursor: pointer;
    width: 100%;
}

/* 显卡艺术图（替代外链占位图） */
.gpu-art {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: #fff;
    background: linear-gradient(135deg, #0f172a, #334155);
    border-radius: 8px;
    min-height: 46px;
}

.gpu-art .ga-tag { font-size: 8px; opacity: 0.7; letter-spacing: 2px; margin-bottom: 2px; font-weight: 600; }
.gpu-art b { font-size: 17px; letter-spacing: .5px; line-height: 1.15; }
.gpu-art .ga-sub { font-size: 9px; opacity: 0.75; margin-top: 1px; }

/* ---------- 首页优势横排（保持原UI） ---------- */
.features-row {
    display: flex;
    gap: 10px;
    padding: 0 16px;
    overflow-x: auto;
    scrollbar-width: none;
    margin-bottom: 20px;
}

.features-row::-webkit-scrollbar { display: none; }

.feature-item {
    flex: 0 0 120px;
    background: #fff;
    padding: 10px 8px;
    border-radius: 10px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    border: 1px solid #edf2f7;
    box-shadow: 0 2px 6px rgba(0,0,0,0.02);
}

.feature-icon {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    margin-bottom: 6px;
}

.feature-text { display: flex; flex-direction: column; align-items: center; }
.feature-title { font-size: 11px; font-weight: bold; color: #2d3748; white-space: nowrap; }
.feature-desc { font-size: 9px; color: #a0aec0; margin-top: 2px; white-space: nowrap; }

/* ============================================================
   通用组件
   ============================================================ */

/* 分段切换（订单状态等） */
.seg {
    display: flex;
    background: #eef2f7;
    border-radius: 10px;
    padding: 3px;
    margin: 12px 16px;
}

.seg-item {
    flex: 1;
    text-align: center;
    padding: 7px 0;
    font-size: 13px;
    color: #64748b;
    border-radius: 8px;
    cursor: pointer;
    user-select: none;
    transition: all .15s;
}

.seg-item.active {
    background: #fff;
    color: #2563eb;
    font-weight: 700;
    box-shadow: 0 1px 4px rgba(15,23,42,.08);
}

/* 筛选 chips */
.chip-row {
    display: flex;
    gap: 8px;
    padding: 0 16px;
    overflow-x: auto;
    scrollbar-width: none;
}

.chip-row::-webkit-scrollbar { display: none; }

.chip {
    background: #fff;
    border: 1px solid #e2e8f0;
    color: #4a5568;
    border-radius: 999px;
    padding: 6px 14px;
    font-size: 12px;
    cursor: pointer;
    white-space: nowrap;
    flex: none;
    transition: all .15s;
    user-select: none;
}

.chip.active {
    background: #2563eb;
    border-color: #2563eb;
    color: #fff;
    font-weight: 600;
}

.chip-row .chip-count { flex: 1; text-align: right; font-size: 11px; color: #a0aec0; align-self: center; }

/* 行式列表卡片 */
.list { padding: 0 0 12px; }

.row-card {
    background: #fff;
    border: 1px solid #edf2f7;
    border-radius: 12px;
    padding: 12px;
    margin: 0 16px 10px;
    display: flex;
    gap: 12px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.02);
}

.rc-art {
    width: 88px;
    height: 64px;
    border-radius: 10px;
    overflow: hidden;
    flex: none;
    align-self: center;
}

.rc-art .gpu-art { border-radius: 0; }
.rc-art .gpu-art b { font-size: 15px; }

.rc-main { flex: 1; min-width: 0; }

.rc-t { display: flex; align-items: center; gap: 8px; }
.rc-t b { font-size: 14px; color: #1a202c; white-space: nowrap; }
.rc-t .src { font-size: 9px; color: #a0aec0; }

.rc-meta { font-size: 11px; color: #718096; margin-top: 3px; line-height: 1.5; }

.rc-ft {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 8px;
    flex-wrap: wrap;
}

.rc-qty { font-size: 11px; color: #4a5568; }
.rc-total { color: #e53e3e; font-size: 15px; font-weight: bold; }
.rc-total span { font-size: 10px; color: #a0aec0; font-weight: normal; }
.rc-side { flex: none; display: flex; flex-direction: column; align-items: flex-end; justify-content: space-between; }
.rc-side .price { color: #e53e3e; font-size: 16px; font-weight: bold; }
.rc-side .price span { font-size: 10px; color: #a0aec0; font-weight: normal; }
.rc-side .stock { font-size: 10px; color: #718096; margin: 4px 0 8px; text-align: right; }

.ellipsis {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    max-width: 100%;
}

/* 状态标签 */
.st { display: inline-flex; align-items: center; border-radius: 4px; font-size: 10px; font-weight: 600; padding: 2px 7px; flex: none; }
.st-run { background: #e6fffa; color: #319795; }   /* 租用中 / 上架中 / 运行 */
.st-done { background: #edf2f7; color: #718096; }  /* 已完成 / 已下架 */
.st-pay { background: #fffaf0; color: #dd6b20; }   /* 待付款 */
.st-blue { background: #ebf8ff; color: #3182ce; }  /* 可租用 / 可转租 */
.st-red { background: #fff5f5; color: #e53e3e; }   /* 已过期 */
.st-purple { background: #f3e8ff; color: #9333ea; }

/* 按钮 */
.btn {
    border: none;
    background: #2563eb;
    color: #fff;
    padding: 8px 0;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: opacity .15s;
}

.btn:hover { opacity: .9; }

.btn-ghost { background: #fff; color: #4a5568; border: 1px solid #e2e8f0; }
.btn-red { background: #e53e3e; }
.btn-block { width: 100%; }
.btn-xs { padding: 4px 12px; border-radius: 6px; font-size: 11px; }

/* 弹层 */
.mask {
    position: fixed;
    inset: 0;
    background: rgba(15,23,42,.55);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    padding: 0 20px;
}

.mask.show { display: flex; }

.dialog {
    width: 100%;
    max-width: 330px;
    background: #fff;
    border-radius: 16px;
    padding: 18px 18px 16px;
    animation: pop .18s ease;
}

@keyframes pop { from { transform: scale(.92); opacity: 0; } to { transform: scale(1); opacity: 1; } }

.dg-title { font-size: 16px; font-weight: 800; color: #1a202c; text-align: center; }
.dg-model { text-align: center; color: #718096; font-size: 12px; margin-top: 4px; }
.dg-price { text-align: center; color: #e53e3e; font-size: 20px; font-weight: 800; margin: 10px 0 4px; }
.dg-price span { font-size: 11px; color: #a0aec0; font-weight: normal; }
.dg-label { font-size: 12px; color: #4a5568; font-weight: 600; margin: 12px 0 7px; }

.hour-row { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; }
.hour-row::-webkit-scrollbar { display: none; }

.hour {
    flex: none;
    padding: 6px 13px;
    border: 1px solid #e2e8f0;
    border-radius: 999px;
    font-size: 12px;
    color: #4a5568;
    cursor: pointer;
    background: #fff;
    user-select: none;
}

.hour.active { background: #2563eb; border-color: #2563eb; color: #fff; font-weight: 600; }

.stp { display: flex; align-items: center; gap: 14px; }
.stp-btn {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    border: 1px solid #e2e8f0;
    background: #fff;
    color: #2d3748;
    font-size: 15px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.stp-btn:disabled { color: #cbd5e1; border-color: #edf2f7; }
.stp-val { font-size: 15px; font-weight: 700; color: #1a202c; min-width: 24px; text-align: center; }
.stp-cap { font-size: 11px; color: #a0aec0; margin-left: auto; }

.dg-total-row { display: flex; justify-content: space-between; align-items: baseline; background: #f7fafc; border-radius: 10px; padding: 10px 12px; margin: 12px 0; }
.dg-total-row .l { font-size: 12px; color: #718096; }
.dg-total-row .v { color: #e53e3e; font-size: 18px; font-weight: 800; }
.dg-total-row .v span { font-size: 11px; color: #a0aec0; font-weight: normal; }

.dg-btns { display: flex; gap: 10px; }
.dg-btns .btn { flex: 1; padding: 10px 0; border-radius: 10px; font-size: 14px; }

/* Toast 轻提示 */
.toast {
    position: fixed;
    left: 50%;
    bottom: 92px;
    transform: translateX(-50%);
    background: rgba(15,23,42,.92);
    color: #fff;
    font-size: 13px;
    padding: 10px 16px;
    border-radius: 999px;
    z-index: 2000;
    max-width: 86%;
    box-shadow: 0 6px 20px rgba(0,0,0,.25);
    animation: toastIn .2s ease;
    display: flex;
    align-items: center;
    gap: 8px;
    line-height: 1.4;
    text-align: center;
}

.toast i { font-size: 14px; flex: none; }
.toast.ok i { color: #34d399; }
.toast.warn i { color: #fbbf24; }
.toast.err i { color: #f87171; }

@keyframes toastIn { from { transform: translateX(-50%) translateY(10px); opacity: 0; } to { transform: translateX(-50%) translateY(0); opacity: 1; } }
.toast.out { animation: toastOut .2s ease forwards; }
@keyframes toastOut { to { transform: translateX(-50%) translateY(10px); opacity: 0; } }

/* 空状态 */
.empty { padding: 46px 16px; text-align: center; color: #a0aec0; }
.empty i { font-size: 38px; display: block; margin-bottom: 10px; opacity: .6; }
.empty p { font-size: 13px; }

/* ============================================================
   表单（发布算力）
   ============================================================ */
.form-card {
    background: #fff;
    border: 1px solid #edf2f7;
    border-radius: 14px;
    margin: 12px 16px;
    padding: 16px 14px;
}

.f-group { margin-bottom: 14px; }
.f-group:last-child { margin-bottom: 0; }

.f-label { display: block; font-size: 13px; font-weight: 600; color: #2d3748; margin-bottom: 7px; }
.f-label .req { color: #e53e3e; margin-right: 2px; }

.f-input, .f-select {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #e2e8f0;
    border-radius: 9px;
    font-size: 14px;
    background: #fff;
    outline: none;
    color: #1a202c;
}

.f-input:focus, .f-select:focus { border-color: #2563eb; box-shadow: 0 0 0 3px rgba(37,99,235,.12); }
.f-select { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23718096' stroke-width='2.4'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 12px center; padding-right: 34px; }

textarea.f-input { min-height: 68px; resize: vertical; line-height: 1.6; }

.f-row { display: flex; gap: 10px; }
.f-row .f-group { flex: 1; }

.choice { display: flex; gap: 8px; flex-wrap: wrap; }
.choice .chip { padding: 7px 16px; font-size: 13px; }

/* 数量步进器 */
.stp2 { display: flex; align-items: center; gap: 14px; }

/* 开关 */
.switch { position: relative; width: 44px; height: 26px; flex: none; cursor: pointer; }
.switch input { opacity: 0; width: 0; height: 0; }
.switch .tr {
    position: absolute;
    inset: 0;
    background: #cbd5e1;
    border-radius: 999px;
    transition: .2s;
}

.switch .tr::after {
    content: "";
    position: absolute;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #fff;
    top: 3px;
    left: 3px;
    transition: .2s;
    box-shadow: 0 1px 3px rgba(0,0,0,.2);
}

.switch input:checked + .tr { background: #2563eb; }
.switch input:checked + .tr::after { transform: translateX(18px); }

.switch-line { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.switch-line .sl-t { font-size: 13px; font-weight: 600; color: #2d3748; }
.switch-line .sl-d { font-size: 11px; color: #a0aec0; margin-top: 2px; }

/* 发布成功 */
.pub-ok { text-align: center; padding: 30px 0 8px; }
.pub-ok .ok-ic {
    width: 72px;
    height: 72px;
    margin: 0 auto 14px;
    background: #e6fffa;
    color: #0d9488;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 30px;
}

.pub-ok h3 { font-size: 18px; color: #1a202c; margin-bottom: 6px; }
.pub-ok p { font-size: 12px; color: #718096; margin-bottom: 22px; }
.pub-ok .btn { margin: 0 8px; padding: 9px 18px; font-size: 13px; }

/* ============================================================
   我的（个人中心）
   ============================================================ */
.pf-card {
    background: #fff;
    border-radius: 14px;
    margin: 12px 16px 0;
    padding: 16px 14px;
    display: flex;
    align-items: center;
    gap: 12px;
    border: 1px solid #edf2f7;
}

.pf-avatar {
    width: 54px;
    height: 54px;
    border-radius: 50%;
    background: linear-gradient(135deg, #2563eb, #00d2ff);
    color: #fff;
    font-size: 22px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex: none;
}

.pf-name { font-size: 17px; font-weight: 800; color: #1a202c; display: flex; align-items: center; gap: 6px; }
.pf-tag { font-size: 9px; background: #e6fffa; color: #319795; padding: 2px 6px; border-radius: 4px; font-weight: 600; flex: none; }
.pf-tag.orange { background: #fffaf0; color: #dd6b20; }
.pf-sub { font-size: 11px; color: #a0aec0; margin-top: 4px; }

/* 钱包 */
.wallet-card {
    margin: 12px 16px 0;
    background: linear-gradient(135deg, #1e3a8a, #2563eb);
    border-radius: 16px;
    padding: 16px;
    color: #fff;
    display: flex;
    align-items: center;
    gap: 14px;
}

.wallet-card .wc-ic {
    width: 46px;
    height: 46px;
    background: rgba(255,255,255,.16);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    flex: none;
}

.wc-k { font-size: 11px; opacity: .75; }
.wc-v { font-size: 21px; font-weight: 800; margin-top: 2px; }
.wc-v small { font-size: 12px; font-weight: 600; }

.wallet-stats { flex: 1; display: flex; }
.wallet-stats .ws { flex: 1; text-align: right; }
.wallet-stats .ws .ws-v { font-size: 14px; font-weight: 700; }
.wallet-stats .ws .ws-k { font-size: 10px; opacity: .7; margin-top: 2px; }

/* 功能菜单 */
.menu { background: #fff; margin: 14px 16px; border-radius: 12px; overflow: hidden; border: 1px solid #edf2f7; }
.menu-title { font-size: 11px; color: #a0aec0; padding: 11px 14px 5px; font-weight: 600; }
.menu-row {
    display: flex;
    align-items: center;
    gap: 11px;
    padding: 12px 14px;
    background: #fff;
    color: #2d3748;
    font-size: 14px;
    text-decoration: none;
    border-top: 1px solid #f7fafc;
    cursor: pointer;
    width: 100%;
    text-align: left;
}

.menu-row:hover { background: #fafbfe; }
button.menu-row { border: 0; }
button.menu-row:active { background: #f1f5f9; }
.menu-row .mi {
    width: 27px;
    height: 27px;
    border-radius: 7px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 13px;
    flex: none;
}

.menu-row .mr-t { flex: 1; min-width: 0; }
.menu-row .mr-d { font-size: 11px; color: #a0aec0; display: block; margin-top: 1px; }
.menu-row .arr { color: #cbd5e1; font-size: 12px; flex: none; }

/* ============================================================
   应用中心
   ============================================================ */
.app-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    padding: 0 16px 12px;
}

.app-item {
    background: #fff;
    border: 1px solid #edf2f7;
    border-radius: 12px;
    padding: 12px 8px 10px;
    text-align: center;
}

.app-ic {
    width: 42px;
    height: 42px;
    border-radius: 11px;
    margin: 0 auto 8px;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
}

.app-name { font-size: 12px; font-weight: 700; color: #2d3748; white-space: nowrap; }
.app-desc { font-size: 9px; color: #a0aec0; margin-top: 3px; white-space: nowrap; }

.app-btn {
    margin-top: 9px;
    background: #2563eb;
    color: #fff;
    border: none;
    border-radius: 999px;
    font-size: 10px;
    font-weight: 600;
    padding: 4px 0;
    width: 100%;
    cursor: pointer;
}

.app-btn.off { background: #edf2f7; color: #94a3b8; cursor: default; }

/* ============================================================
   底部 Tabbar（由 js/app.js 注入，样式保持原UI）
   ============================================================ */
.bottom-nav {
    position: fixed;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100%;
    max-width: 430px;
    background: #fff;
    border-top: 1px solid #edf2f7;
    display: flex;
    justify-content: space-around;
    align-items: flex-end;
    z-index: 100;
    padding: 6px 4px calc(6px + env(safe-area-inset-bottom));
}

.nav-tab {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-decoration: none;
    color: #a0aec0;
    font-size: 10px;
    gap: 3px;
    padding: 3px 10px;
    border-radius: 8px;
}

.nav-tab.active { color: #2563eb; font-weight: 600; }
.nav-tab i { font-size: 18px; }

.center-fab {
    width: 48px;
    height: 48px;
    background: #2563eb;
    border-radius: 50%;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 19px;
    box-shadow: 0 4px 12px rgba(37,99,235,.35);
    margin: -14px 2px 0;
    text-decoration: none;
    flex: none;
}

.center-fab:active { transform: scale(.95); }

/* ============================================================
   登录 / 注册页
   ============================================================ */
body.auth-body { background: #eef2f7; }

.auth-wrap {
    width: 100%;
    max-width: 430px;
    min-height: 100vh;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 36px 20px;
}

.auth-logo {
    width: 54px;
    height: 54px;
    border-radius: 14px;
    background: linear-gradient(135deg, #1e6fff, #00d2ff);
    color: #fff;
    font-size: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 14px;
    box-shadow: 0 8px 20px rgba(30, 111, 255, .28);
}

.auth-brand h1 { font-size: 21px; font-weight: 800; color: #1a202c; text-align: center; }
.auth-brand p { font-size: 12px; color: #a0aec0; text-align: center; margin-top: 5px; }

.auth-card {
    background: #fff;
    border: 1px solid #edf2f7;
    border-radius: 18px;
    margin-top: 26px;
    padding: 20px 18px 16px;
    box-shadow: 0 10px 30px rgba(15, 23, 42, .06);
}

.auth-card .seg { margin: 0 0 18px; }

.auth-input {
    display: flex;
    align-items: center;
    gap: 10px;
    background: #f7fafc;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    height: 46px;
    padding: 0 12px;
    margin-bottom: 12px;
}

.auth-input i { color: #a0aec0; width: 16px; text-align: center; font-size: 14px; flex: none; }

.auth-input input {
    flex: 1;
    border: none;
    background: transparent;
    outline: none;
    font-size: 14px;
    color: #1a202c;
    min-width: 0;
}

.auth-input:focus-within { border-color: #2563eb; background: #fff; box-shadow: 0 0 0 3px rgba(37, 99, 235, .12); }

.auth-submit {
    width: 100%;
    padding: 12px 0;
    border-radius: 10px;
    font-size: 15px;
    background: #2563eb;
    color: #fff;
    border: none;
    font-weight: 700;
    cursor: pointer;
    margin-top: 4px;
}

.auth-submit:active { opacity: .9; }

.auth-err {
    display: none;
    background: #fff5f5;
    border: 1px solid #fed7d7;
    color: #c53030;
    font-size: 12px;
    border-radius: 8px;
    padding: 8px 10px;
    margin-bottom: 12px;
    text-align: center;
}

.auth-err.show { display: block; }

.auth-agree {
    display: none;
    font-size: 11px;
    color: #718096;
    margin: 2px 2px 12px;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
}

.auth-agree.show { display: flex; }
.auth-agree input { accent-color: #2563eb; width: 14px; height: 14px; }
.auth-agree a { color: #2563eb; text-decoration: none; }

.auth-forgot { display: none; justify-content: flex-end; font-size: 12px; margin-top: 12px; }
.auth-forgot.show { display: flex; }
.auth-forgot a { color: #718096; text-decoration: none; }
.auth-forgot a:active { color: #2563eb; }

.auth-demo {
    margin-top: 14px;
    border: 1px dashed #cbd5e1;
    border-radius: 14px;
    background: #fff;
    padding: 14px;
    text-align: center;
}

.auth-demo .ad-t { font-size: 13px; font-weight: 600; color: #2d3748; }
.auth-demo .ad-d { font-size: 11px; color: #a0aec0; margin: 5px 0 10px; }

.auth-demo button {
    background: #fff;
    border: 1px solid #2563eb;
    color: #2563eb;
    border-radius: 8px;
    padding: 7px 18px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
}

.auth-foot { text-align: center; font-size: 11px; color: #a0aec0; margin-top: 16px; line-height: 1.7; }

/* ============================================================
   App 化微调：手机全宽铺满 / 桌面保持手机画布 / 禁止横向溢出
   ============================================================ */
body { overflow-x: hidden; }

.mobile-container {
    width: 100%;
    max-width: 430px;
    margin: 0 auto;
    overflow-x: hidden;
}

/* ---------- 热门算力卡片：三列紧凑排布，任意机型不溢出 ---------- */
.cards-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
    padding: 0 12px;
}

.gpu-card { min-width: 0; padding: 8px; }
.card-badge { top: 6px; right: 6px; font-size: 8px; }
.gpu-title { font-size: 12px; padding-right: 4px; overflow: hidden; text-overflow: ellipsis; }
.gpu-img-box { height: 50px; margin-bottom: 5px; }
.gpu-art b { font-size: 15px; }
.gpu-art .ga-tag { font-size: 7px; }
.gpu-art .ga-sub { font-size: 8px; }
.gpu-tag { font-size: 8px; }
.gpu-price { font-size: 12px; }
.rent-btn { padding: 5px 0; font-size: 11px; }

/* ---------- 首页轮播（后台可编辑，实时生效） ---------- */
.carousel {
    position: relative;
    margin: 12px 16px;
    border-radius: 16px;
    overflow: hidden;
}

.car-track { display: flex; transition: transform .35s ease; }

.car-slide { min-width: 100%; flex: none; }
.car-slide .banner { margin: 0; padding-bottom: 24px; }

.car-dots {
    position: absolute;
    bottom: 8px;
    left: 0;
    right: 0;
    display: flex;
    justify-content: center;
    gap: 5px;
    z-index: 3;
}

.car-dot {
    width: 6px;
    height: 6px;
    border-radius: 99px;
    background: rgba(255, 255, 255, .4);
    cursor: pointer;
    transition: all .25s;
}

.car-dot.on { background: #fff; width: 15px; }

.banner-tags span.plain { opacity: .92; }
.banner-tags span.plain i { font-size: 9px; }
