@charset "UTF-8";
/* =============================================================================
   TIGER 客户端(扫码 / 激活)样式 —— 移动优先
   目标环境: iPhone Safari / Android Chrome / 微信 / Zalo
   ============================================================================= */

:root {
    /* 主色: TGR 字标红(取自官方 logo) */
    --tg-red: #D81319;
    --tg-red-dark: #9E0C0E;
    --tg-red-light: #F0231C;
    --tg-red-soft: #FDECEC;
    /* 辅助色: 虎头橙 */
    --tg-orange: #ED7620;
    --tg-orange-dark: #C85F13;
    --tg-orange-soft: #FFF2E6;
    /* 主按钮 / 强调一律走 primary, 换主色只改这一行 */
    --tg-primary: var(--tg-red);
    --tg-primary-dark: var(--tg-red-dark);
    --tg-primary-soft: var(--tg-red-soft);
    --tg-black: #141414;
    --tg-text: #2B2B2B;
    --tg-muted: #7A7A7A;
    --tg-border: #E8E8E8;
    --tg-bg: #F5F6F8;
    --tg-card: #FFFFFF;
    --tg-success: #1B9C57;
    --tg-success-soft: #E8F6EE;
    --tg-warning: #C8860D;
    --tg-warning-soft: #FDF4E3;
    --tg-danger: #C9372C;
    --tg-danger-soft: #FCEDEC;
    --tg-info: #2C6FD1;
    --tg-info-soft: #EAF2FD;
    --tg-radius: 14px;
    --tg-shadow: 0 1px 3px rgba(0, 0, 0, .06), 0 6px 18px rgba(0, 0, 0, .04);
    /* 等宽字体栈。以前只在 .tg-row-value.is-mono 等处写死, 而 .tg-order-no /
       .tg-status-banner-no 引用的 var(--tg-mono) 没人定义, 一律落到后备的
       ui-monospace —— 中文 Windows 上那是带衬线的新宋体, 同一页上两种等宽字体
       混着用。这里统一定义一次。(2026-09-20 布局修复 L45) */
    --tg-mono: "SF Mono", Consolas, "Courier New", monospace;
}

* { box-sizing: border-box; }

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

body {
    margin: 0;
    padding: 0;
    background: var(--tg-bg);
    color: var(--tg-text);
    font: 15px/1.6 -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC",
          "Hiragino Sans GB", "Microsoft YaHei", Roboto, "Helvetica Neue", Arial, sans-serif;
    -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }

a { color: var(--tg-primary); text-decoration: none; }

/* --- 页头 --- */
.tg-header {
    background: linear-gradient(135deg, var(--tg-black) 0%, #3A3A3A 100%);
    color: #fff;
    padding: 18px 16px 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.tg-brand {
    display: flex;
    flex-direction: column;
    /* 纵向 flex 默认 align-items:stretch, logo 会被拉到副标题那么宽, 再被
       object-fit:contain 居中 —— 越南语副标题长, logo 就被推到中间, 和下面的
       副标题左边对不齐。(2026-09-20 布局修复 L39) */
    align-items: flex-start;
    gap: 4px;
    min-width: 0;
}

/* 官方 logo 原图: 限高等比缩放, 深色页头上自带白描边不需额外处理 */
.tg-brand-logo {
    height: 34px;
    width: auto;
    max-width: 190px;
    object-fit: contain;
}

/* 无 logo 文件时的文字兜底 */
.tg-logo {
    font-size: 22px;
    font-weight: 800;
    letter-spacing: 3px;
    color: #fff;
    display: flex;
    align-items: center;
    gap: 8px;
}

.tg-logo::before {
    content: "";
    width: 5px;
    height: 22px;
    background: var(--tg-primary);
    border-radius: 3px;
}

.tg-logo-sub {
    display: block;
    font-size: 11px;
    letter-spacing: .5px;
    color: rgba(255, 255, 255, .62);
    font-weight: 400;
    margin-top: 2px;
}

/* --- 语言切换 --- */
.tg-lang {
    display: flex;
    background: rgba(255, 255, 255, .13);
    border-radius: 999px;
    padding: 3px;
    flex-shrink: 0;
}

/* 上下内边距 9px 把可点区域撑到约 32px 高(原来只有 24px), 手机上点得中。
   视觉大小(字号 / 底色胶囊)没变, 只是胶囊变高一点。(2026-09-20 布局修复 L50) */
.tg-lang a {
    color: rgba(255, 255, 255, .75);
    font-size: 12px;
    padding: 9px 12px;
    border-radius: 999px;
    line-height: 1.2;
    white-space: nowrap;
}

.tg-lang a.is-active {
    background: var(--tg-primary);
    color: #fff;
    font-weight: 600;
}

/* --- 容器 --- */
.tg-page {
    max-width: 640px;
    margin: 0 auto;
    padding: 16px 16px 40px;
}

.tg-card {
    background: var(--tg-card);
    border-radius: var(--tg-radius);
    box-shadow: var(--tg-shadow);
    overflow: hidden;
    margin-bottom: 14px;
}

.tg-card-head {
    padding: 14px 16px;
    border-bottom: 1px solid var(--tg-border);
    font-size: 15px;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 8px;
}

/* 详情页卡片头的状态徽章要靠右, 和列表卡片头(.tg-order-head)一样两端对齐 ——
   原来它紧贴在单号右边, 右侧空一大片, 同一个产品里两种对齐方式。
   只推状态徽章: 计数徽章(.tg-evidence-count)是标题的一部分, 仍然紧跟标题。
   (2026-09-20 布局修复 L79) */
.tg-card-head > .tg-status {
    margin-left: auto;
    flex: none;
    white-space: nowrap;
}

.tg-card-body { padding: 4px 16px 14px; }

/* 卡片正文顶部只有 4px, 那是给自带 11px 上下内边距的 .tg-row 准备的。
   直接放表单 / 时间线 / 门店列表 / 说明段落时, 内容离标题分隔线只有 4-5px,
   而底部留白有 30px, 上下差了 6 倍。给非 .tg-row 的首个元素补上 12px。
   (2026-09-20 布局修复 L40) */
.tg-card-head + .tg-card-body > :first-child:not(.tg-row):not(.tg-product),
.tg-card-head + .tg-card-body > input[type="hidden"]:first-child + *:not(.tg-row):not(.tg-product) {
    margin-top: 12px;
}

/* 最后一个字段的 16px 下外边距叠在 14px 内边距上, 卡片底部空 30px */
.tg-card-body > .tg-field:last-child,
.tg-card-body > form > .tg-field:last-child {
    margin-bottom: 2px;
}

/* 没有标题栏的卡片(门店登录 / 改密码): 顶部 4px 是给标题栏下方准备的,
   直接放表单时标签会贴着卡片上沿 */
.tg-card > .tg-card-body:first-child { padding-top: 16px; }

/* 兜底: <form class="tg-card"> 里第一个子元素常常是 CSRF 隐藏域, 正文就不再是
   :first-child, 上面那条规则匹配不上, 标签又只剩 4px 贴着圆角。隐藏域不占位置,
   它后面的正文照样算「卡片第一块内容」。(2026-09-20 布局修复 L41) */
.tg-card > input[type="hidden"]:first-child + .tg-card-body { padding-top: 16px; }

/* --- 验证通过横幅 --- */
.tg-verify {
    background: linear-gradient(135deg, #1B9C57 0%, #127F45 100%);
    color: #fff;
    border-radius: var(--tg-radius);
    padding: 20px 16px;
    text-align: center;
    margin-bottom: 14px;
    box-shadow: var(--tg-shadow);
}

.tg-verify-icon {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: rgba(255, 255, 255, .2);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 10px;
    font-size: 26px;
    line-height: 1;
}

.tg-verify-title { font-size: 18px; font-weight: 700; margin-bottom: 4px; }
.tg-verify-tip { font-size: 13px; opacity: .88; }

/* --- 信息行 --- */
.tg-row {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 11px 0;
    border-bottom: 1px dashed var(--tg-border);
}

.tg-row:last-child { border-bottom: 0; }

.tg-row-label {
    color: var(--tg-muted);
    font-size: 13px;
    width: 96px;
    flex-shrink: 0;
    padding-top: 1px;
}

/* 96px 是按中文 4-5 个字定的。越南语标签几乎每条都折成两行, 而且是在词中间
   断开(「Model sản / phẩm」「Thời gian kích / hoạt」), 右边的值只有一行,
   每行都上下错开。放宽到 128px, 390 下值列还剩约 186px, SN / 金额 / 日期时间
   都放得下。等宽编号列(.is-mono)另有规则, 这里排除掉。
   (2026-09-20 布局修复 L38) */
:lang(vi) .tg-row-label:not(.is-mono) { width: 128px; }

.tg-row-value {
    flex: 1;
    font-size: 14px;
    word-break: break-word;
    font-weight: 500;
}

.tg-row-value.is-mono {
    font-family: var(--tg-mono);
    letter-spacing: .5px;
    font-weight: 600;
}

/* --- 状态标签 --- */
.tg-status {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 600;
    line-height: 1.6;
}

.tg-status-success { background: var(--tg-success-soft); color: var(--tg-success); }
.tg-status-warning { background: var(--tg-warning-soft); color: var(--tg-warning); }
.tg-status-danger  { background: var(--tg-danger-soft);  color: var(--tg-danger); }
.tg-status-info    { background: var(--tg-info-soft);    color: var(--tg-info); }
.tg-status-muted   { background: #F0F0F0;                color: var(--tg-muted); }

/* --- 收款账户(门店端只读) ---
   不复用 .tg-row: 它左边是固定 96px 的灰色标签列, 开户人姓名放进去会被折成
   三行, 中文的「默认」还会被拆成「默」「认」两行; 而且门店要核对的恰恰是
   姓名, 放在灰色次要位上层级就反了。这里改成上下两行: 姓名 + 状态 / 渠道 + 后四位。 */
.tg-account {
    padding: 11px 0;
    border-bottom: 1px dashed var(--tg-border);
}

.tg-account:last-child { border-bottom: 0; }

.tg-account-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 10px;
}

.tg-account-holder {
    min-width: 0;
    font-size: 14px;
    font-weight: 600;
    color: var(--tg-text);
    word-break: break-word;
}

.tg-account-head .tg-status {
    flex-shrink: 0;
    white-space: nowrap;
}

.tg-account-meta {
    margin-top: 3px;
    font-size: 13px;
    color: var(--tg-muted);
}

.tg-account-number {
    font-family: var(--tg-mono);
    letter-spacing: .5px;
    color: var(--tg-text);
    white-space: nowrap;
}

.tg-account-default {
    white-space: nowrap;
    font-weight: 600;
    color: var(--tg-text);
}

.tg-account-meta.is-warning { color: var(--tg-warning); }

/* 店主管理本店收款账户的一排小按钮(修改 / 设为默认 / 停用)。
   按钮不许折行拆字: 手机上窄按钮被挤成竖排单字列是踩过的坑, 放不下就整颗换行。 */
.tg-account-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 10px;
}

.tg-account-actions form { margin: 0; }

.tg-btn.tg-btn-sm {
    display: inline-block;
    width: auto;
    padding: 7px 14px;
    border-radius: 9px;
    font-size: 14px;
    white-space: nowrap;
}

/* 账号输入框用等宽字体: 0/O、1/l 一眼分得清, 店主填完能逐位核对 */
.tg-input.is-mono {
    font-family: var(--tg-mono);
    letter-spacing: .5px;
}

/* --- 质保卡 --- */
.tg-warranty {
    padding: 14px 16px;
    border-radius: 12px;
    margin: 0 0 4px;
}

.tg-warranty.is-active  { background: var(--tg-success-soft); }
.tg-warranty.is-expired { background: var(--tg-danger-soft); }
.tg-warranty.is-pending { background: var(--tg-warning-soft); }
.tg-warranty.is-unavailable { background: #F0F0F0; }

.tg-warranty-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    /* 320 宽(iPhone SE 一代 / 小屏安卓)的越南语下两段文字都放不下, 原来不许换行,
       胶囊标签被挤成两行变成带大圆角的方块。(2026-09-20 布局修复 L47) */
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 6px;
}

.tg-warranty-status { font-size: 16px; font-weight: 700; }
.tg-warranty.is-active  .tg-warranty-status { color: var(--tg-success); }
.tg-warranty.is-expired .tg-warranty-status { color: var(--tg-danger); }
.tg-warranty.is-pending .tg-warranty-status { color: var(--tg-warning); }

/* 胶囊标签必须整颗显示: 折行会把 999px 圆角撑成方块(2026-09-20 布局修复 L47) */
.tg-warranty-remaining {
    font-size: 13px;
    font-weight: 600;
    background: rgba(255, 255, 255, .7);
    padding: 3px 10px;
    border-radius: 999px;
    white-space: nowrap;
    flex-shrink: 0;
}

.tg-warranty-tip { font-size: 13px; color: var(--tg-muted); }

.tg-warranty-range {
    display: flex;
    gap: 10px;
    margin-top: 10px;
    font-size: 13px;
}

.tg-warranty-range > div { flex: 1; }
.tg-warranty-range .k { color: var(--tg-muted); font-size: 12px; }
.tg-warranty-range .v { font-weight: 600; }

/* --- 按钮 --- */
.tg-actions { display: grid; gap: 10px; margin-top: 18px; }

/* 提示条自带 14px 下外边距, 叠在按钮区的 10px 间距上就多出一截(2026-09-20 布局修复 L37) */
.tg-actions > .tg-alert { margin-bottom: 0; }

.tg-btn {
    display: block;
    width: 100%;
    padding: 14px 16px;
    border: 0;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 600;
    text-align: center;
    cursor: pointer;
    font-family: inherit;
    line-height: 1.4;
    transition: opacity .15s;
    -webkit-appearance: none;
}

.tg-btn:active { opacity: .82; }

.tg-btn-primary {
    background: var(--tg-primary);
    color: #fff;
    box-shadow: 0 4px 14px rgba(216, 19, 25, .26);
}

.tg-btn-secondary {
    background: #fff;
    color: var(--tg-text);
    border: 1px solid var(--tg-border);
}

.tg-btn:disabled { opacity: .5; cursor: not-allowed; }

/* --- 表单 --- */
.tg-field { margin-bottom: 16px; }

.tg-label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    margin-bottom: 6px;
    color: var(--tg-text);
}

.tg-label .req { color: var(--tg-danger); margin-left: 3px; }
.tg-label .opt { color: var(--tg-muted); font-weight: 400; margin-left: 5px; font-size: 12px; }

.tg-input,
.tg-select {
    width: 100%;
    padding: 12px 14px;
    border: 1px solid var(--tg-border);
    border-radius: 10px;
    font-size: 16px; /* 16px 可避免 iOS Safari 聚焦时自动放大 */
    font-family: inherit;
    color: var(--tg-text);
    background: #fff;
    -webkit-appearance: none;
    appearance: none;
}

.tg-select {
    background-image: url("data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 8'%3E%3Cpath fill='%237A7A7A' d='M1 1l5 5 5-5'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
    background-size: 12px;
    padding-right: 38px;
}

.tg-input:focus,
.tg-select:focus {
    outline: 0;
    border-color: var(--tg-primary);
    box-shadow: 0 0 0 3px rgba(216, 19, 25, .13);
}

/* 多行描述(售后问题描述、处理说明)与文件框: 沿用 .tg-input 的边框和圆角。
   display:block 是必须的: 默认的 inline-block 会按基线对齐, 在下面留出约 6px
   的下伸空间, 于是多行框和下一个字段的间距变成 22px, 别处都是 16px。
   (2026-09-20 布局修复 L53) */
textarea.tg-input { display: block; min-height: 104px; resize: vertical; line-height: 1.5; }
input[type="file"].tg-input { padding: 10px 12px; font-size: 14px; }

/* 字重显式写回 400: 它常被放进 .tg-row-value(font-weight:500) 里当说明文字,
   继承过来就比别处的 .tg-hint 粗, 层级反了。(2026-09-20 布局修复 L54) */
.tg-hint { font-size: 12px; font-weight: 400; color: var(--tg-muted); margin-top: 5px; }

/* 空值占位的破折号(安装进度页的 $dash)。模板一直写着 .tg-muted, CSS 里却从来
   没有这个类, 于是「—」和真有值的行一样是正文色 + 500 字重, 看上去像一个值。
   (2026-09-20 布局修复 L42) */
.tg-muted { color: var(--tg-muted); font-weight: 400; }

.tg-warning-text { color: var(--tg-warning); }

.tg-error-text { font-size: 12px; color: var(--tg-danger); margin-top: 5px; }

/* --- 提示条 --- */
.tg-alert {
    padding: 12px 14px;
    border-radius: 10px;
    font-size: 14px;
    margin-bottom: 14px;
    display: flex;
    gap: 9px;
    align-items: flex-start;
}

.tg-alert-danger  { background: var(--tg-danger-soft);  color: var(--tg-danger); }
.tg-alert-success { background: var(--tg-success-soft); color: var(--tg-success); }
.tg-alert-warning { background: var(--tg-warning-soft); color: var(--tg-warning); }

/* --- 空 / 错误页 --- */
.tg-empty {
    text-align: center;
    padding: 56px 24px;
    background: var(--tg-card);
    border-radius: var(--tg-radius);
    box-shadow: var(--tg-shadow);
}

.tg-empty-icon { font-size: 52px; line-height: 1; margin-bottom: 14px; }
.tg-empty-title { font-size: 18px; font-weight: 700; margin-bottom: 8px; }
.tg-empty-tip { font-size: 14px; color: var(--tg-muted); max-width: 380px; margin: 0 auto; }

/* --- 产品头 --- */
.tg-product {
    display: flex;
    gap: 14px;
    align-items: flex-start;
    padding: 4px 0 12px;
    border-bottom: 1px solid var(--tg-border);
    margin-bottom: 4px;
}

.tg-product-img {
    width: 74px;
    height: 74px;
    border-radius: 10px;
    background: var(--tg-orange-soft);
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    overflow: hidden;
}

.tg-product-img img { width: 100%; height: 100%; object-fit: cover; }

.tg-product-name { font-size: 16px; font-weight: 700; line-height: 1.45; margin-bottom: 4px; }
.tg-product-meta { font-size: 13px; color: var(--tg-muted); }

/* 注册页把 SN 放在产品名下面并写了 is-mono, 但只有 .tg-row-value.is-mono /
   .tg-input.is-mono 有定义, 这里落到了普通比例字体 —— 同一个 SN 在产品页是等宽
   加粗、在注册页是灰色细体, 客户对不上是不是同一台机器。(2026-09-20 布局修复 L51) */
.tg-product-meta.is-mono {
    font-family: var(--tg-mono);
    letter-spacing: .5px;
    font-weight: 600;
    color: var(--tg-text);
}

/* .tg-product 的 margin-bottom:4px 是按后面跟 .tg-row(自带 11px 上内边距)配的。
   注册页后面直接跟 <form>, 分隔线到第一个标签就只剩 4px, 而字段之间是 16px。
   (2026-09-20 布局修复 L51) */
.tg-product + form { margin-top: 14px; }

/* --- 页脚 --- */
.tg-footer {
    text-align: center;
    padding: 22px 16px 28px;
    color: var(--tg-muted);
    font-size: 12px;
    line-height: 1.8;
}

.tg-footer strong { color: var(--tg-text); letter-spacing: 2px; }

/* --- 大屏 --- */
@media (min-width: 560px) {
    .tg-page { padding: 24px 20px 48px; }
    .tg-row-label { width: 120px; }
    :lang(vi) .tg-row-label:not(.is-mono) { width: 156px; }

    /* 页头跟正文对齐: .tg-page 是 max-width:640 居中 + 20px 内边距, 页头原来是
       通栏, 屏幕越宽 logo 和下面的卡片左边差得越远(768 下差 63px), 看着像两套
       栅格拼起来的。max() 保证窄于 640 时仍是 20px。(2026-09-20 布局修复 L49) */
    .tg-header {
        padding-left: max(20px, calc((100% - 640px) / 2 + 20px));
        padding-right: max(20px, calc((100% - 640px) / 2 + 20px));
    }

    /* 原来是两列网格, 按钮数量为奇数时落单的那个只占左半边, 右半边空着。
       改成 flex 自适应: 落单的次按钮自动撑满整行, 两个次按钮仍各占一半。
       (2026-09-20 布局修复 L37) */
    .tg-actions {
        display: flex;
        flex-wrap: wrap;
        gap: 10px;
    }

    .tg-actions > * { flex: 1 1 calc(50% - 5px); }

    .tg-actions > .tg-btn-primary,
    .tg-actions > .tg-alert { flex-basis: 100%; }
}

/* ===========================================================================
   安装服务 —— 门店选择、时段选择、进度时间线
   颜色一律引用上面的 :root 变量, 不在组件里写死色值。
   =========================================================================== */

.tg-hide { display: none !important; }

/* --- 门店卡片(可选中) --- */
.tg-store {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 12px;
    margin-bottom: 10px;
    border: 1px solid var(--tg-border);
    border-radius: var(--tg-radius);
    background: var(--tg-card);
    cursor: pointer;
    transition: border-color .15s, background .15s;
}

.tg-store:last-child { margin-bottom: 0; }

.tg-store.is-active {
    border-color: var(--tg-primary);
    background: var(--tg-primary-soft);
}

.tg-store input[type="radio"] {
    margin-top: 3px;
    width: 18px;
    height: 18px;
    accent-color: var(--tg-primary);
    flex: 0 0 auto;
}

.tg-store-body { flex: 1; min-width: 0; }

/* 级别徽章是 JS 追加到门店名里面的。门店名长到要折行时, 行内块徽章会带着
   6px 左外边距掉到第二行, 于是徽章比门店名右缩 6px, 左边对不齐。
   改成 flex + gap: 换行后徽章和门店名左对齐。(2026-09-20 布局修复 L46) */
.tg-store-name {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 4px 6px;
    font-size: 15px;
    font-weight: 700;
    color: var(--tg-text);
    line-height: 1.4;
}

.tg-store-level {
    display: inline-block;
    margin-left: 0;
    padding: 1px 7px;
    border-radius: 10px;
    background: var(--tg-info-soft);
    color: var(--tg-info);
    font-size: 11px;
    font-weight: 600;
    vertical-align: middle;
}

.tg-store-meta {
    margin-top: 3px;
    font-size: 13px;
    color: var(--tg-muted);
    line-height: 1.5;
}

.tg-store-fee {
    margin-top: 6px;
    font-size: 13px;
    font-weight: 700;
    color: var(--tg-primary);
}

/* 免费用绿色短标签, 不和「要收钱」抢视觉重量 */
.tg-store-fee.is-free {
    color: var(--tg-success);
    font-weight: 600;
}

/* --- 时段选择 --- */
.tg-slots {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
}

.tg-slot {
    padding: 11px 6px;
    border: 1px solid var(--tg-border);
    border-radius: 10px;
    background: var(--tg-card);
    color: var(--tg-text);
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    font-family: inherit;
}

.tg-slot.is-active {
    border-color: var(--tg-primary);
    background: var(--tg-primary);
    color: #FFFFFF;
}

/* 约满的时段保留在页面上但点不动 —— 直接隐藏会让客户以为门店不开门 */
.tg-slot.is-disabled,
.tg-slot:disabled {
    background: var(--tg-bg);
    color: var(--tg-muted);
    cursor: not-allowed;
    text-decoration: line-through;
}

/* --- 核对手机号看完整地址的小表单 --- */

/* 和页面顶部的绿色横幅 .tg-verify 没有关系, 只是模板里一直用着这个类名,
   而 CSS 从来没有定义过它: 表单既没有与上面信息行的间距, 按钮也靠 .tg-actions
   撑宽(≥560 时会缩成半格)。现在表单排在门店卡所有信息行之后, 上一行自己的虚线
   就是分隔线, 这里只补间距, 按钮用 .tg-btn 本身的 width:100%。
   (2026-09-20 布局修复 L42) */
.tg-verify-form { margin-top: 12px; }
.tg-verify-form > .tg-hint { margin: 0 0 10px; }

/* --- 安装进度时间线 --- */
.tg-timeline { position: relative; padding-left: 22px; }

.tg-timeline-item { position: relative; padding-bottom: 16px; }
.tg-timeline-item:last-child { padding-bottom: 0; }

/* 竖线由每个节点自己画一段连到下一个圆点, 而不是在容器上画一条通到底的线。
   原来最后一个节点下面还拖着一截灰线; 只有一个节点时(刚提交)圆点下面挂着一段
   没连到任何东西的短线。left:-16px 让线心和 ::before 圆点的圆心重合。
   (2026-09-20 布局修复 L48) */
.tg-timeline-item:not(:last-child)::after {
    content: "";
    position: absolute;
    left: -16px;
    top: 16px;
    bottom: -4px;
    width: 2px;
    background: var(--tg-border);
}

.tg-timeline-item::before {
    content: "";
    position: absolute;
    left: -21px;
    top: 4px;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: var(--tg-border);
    border: 2px solid var(--tg-card);
}

/* 最新一步用品牌红点出来, 客户一眼知道现在走到哪了 */
.tg-timeline-item.is-current::before {
    background: var(--tg-primary);
    box-shadow: 0 0 0 3px var(--tg-primary-soft);
}

.tg-timeline-item.is-done::before { background: var(--tg-success); }

.tg-timeline-title {
    font-size: 14px;
    font-weight: 700;
    color: var(--tg-text);
    line-height: 1.4;
}

.tg-timeline-time {
    margin-top: 2px;
    font-size: 12px;
    color: var(--tg-muted);
}

.tg-timeline-remark {
    margin-top: 3px;
    font-size: 13px;
    color: var(--tg-muted);
}

/* --- 进度页的大状态条 --- */
.tg-status-banner {
    padding: 18px 16px;
    border-radius: var(--tg-radius);
    text-align: center;
    margin-bottom: 14px;
}

.tg-status-banner.is-progress { background: var(--tg-info-soft); }
.tg-status-banner.is-done     { background: var(--tg-success-soft); }
.tg-status-banner.is-wait     { background: var(--tg-warning-soft); }

.tg-status-banner-title {
    font-size: 18px;
    font-weight: 800;
    line-height: 1.35;
}

.tg-status-banner.is-progress .tg-status-banner-title { color: var(--tg-info); }
.tg-status-banner.is-done     .tg-status-banner-title { color: var(--tg-success); }
.tg-status-banner.is-wait     .tg-status-banner-title { color: var(--tg-warning); }

.tg-status-banner-sub {
    margin-top: 5px;
    font-size: 13px;
    color: var(--tg-muted);
    line-height: 1.55;
}

.tg-status-banner-no {
    margin-top: 8px;
    font-family: var(--tg-mono, ui-monospace, monospace);
    font-size: 13px;
    font-weight: 700;
    color: var(--tg-text);
    letter-spacing: .5px;
}

@media (min-width: 560px) {
    .tg-slots { grid-template-columns: repeat(3, 1fr); }
}

/* ===========================================================================
   门店端 / 师傅端工作台
   Bang cong viec cua hang / ky thuat vien

   与客户端共用同一套变量与 .tg-* 前缀。颜色一律引用 :root 变量,
   组件里不写死色值 —— 换主色时只改一处。
   =========================================================================== */

.tg-portal-body {
    /* 底部标签栏是 fixed 的, 给内容留出它的高度 + iPhone 安全区,
       否则最后一张卡片永远被标签栏压着。
       原来写死 64px, 而标签栏高度是内容撑出来的: 越南语标签折两行实测 63px,
       只剩 1px 余量, 标签再长一点最后一张卡片就被压住。下面给 .tg-tabbar 定死
       min-height:64px, 这里再多留 12px 余量。(2026-09-20 布局修复 L80) */
    padding-bottom: calc(76px + env(safe-area-inset-bottom, 0px));
}

.tg-portal-header {
    position: sticky;
    top: 0;
    z-index: 20;
}

.tg-portal-header { padding: 12px 14px; }

/* 门店名可以很长(「Tiger Service Center Ba Dinh」), 不加这两条的话
   它会把右边的语言切换和退出按钮挤成竖排的单字列 —— 在 375px 的手机上
   一眼就能看出来, 但只看桌面宽度是发现不了的 */
.tg-portal-header .tg-brand { flex: 1 1 auto; min-width: 0; }

.tg-portal-header .tg-logo-sub {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* flex:none + width:auto: 品牌区被右边的工具区挤窄时, 父级的 img{max-width:100%}
   会把 logo 一起压小(360px 安卓机上从 120px 压到 56px)。logo 是定高等比的,
   不该跟着容器缩。(2026-09-20 布局修复 L73) */
.tg-portal-header .tg-brand-logo { flex: none; width: auto; height: 32px; max-width: 160px; }  /* 正式 logo 的 TGR 只占三分之一高, 26px 时字太小 */

.tg-portal-tools {
    flex: none;
    display: flex;
    align-items: center;
    gap: 8px;
}

.tg-portal-tools .tg-lang { flex: none; }
.tg-portal-tools .tg-lang a { padding: 5px 9px; }

/* 顶栏三块抢宽度: 语言切换和「我的账号」都是 flex:none, 品牌区是唯一能压的,
   于是 390 越南语下门店名只剩「Tiger Service ...」、师傅端只剩「Kỹ thuật viên ...」
   —— 看不出是哪家店、哪位师傅, 等于没显示。
   界面文字只能来自语言包, 不能在 CSS 里换成「中 / VN」这种缩写, 所以改成:
   窄屏收紧工具区的内边距和字号, 给品牌区留保底宽度, 名字允许折成两行。
   (2026-09-20 布局修复 L73) */
@media (max-width: 460px) {
    .tg-portal-header { padding-left: 12px; padding-right: 12px; gap: 8px; }

    .tg-portal-header .tg-brand { min-width: 116px; }

    .tg-portal-header .tg-logo-sub {
        white-space: normal;
        display: -webkit-box;
        -webkit-line-clamp: 2;
        -webkit-box-orient: vertical;
        line-height: 1.25;
    }

    .tg-portal-tools { gap: 6px; }
    .tg-portal-tools .tg-lang { padding: 2px; }
    .tg-portal-tools .tg-lang a { padding: 5px 7px; font-size: 11px; }
    .tg-portal-logout { padding: 6px 8px; font-size: 11px; }
}

/* 380 以下收回品牌区的保底宽度: 顶栏三块加起来要「12 + 116 + 8 + 244 = 380px」,
   工具区是 flex:none 压不动, 视口窄于 380 时整页就会横向滚动 —— 实测 375
   (iPhone SE2 / 7 / 8)溢出 5px、360(多数安卓)溢出 20px、320 溢出 60px。
   店名被截断只是看不全, 整页横滚是连布局都歪了, 这两档让品牌区继续可压缩;
   名字仍然按上面那条折两行显示, 380 及以上保底宽度照旧。
   (2026-09-20 布局修复 L73 回归修正) */
@media (max-width: 379px) {
    .tg-portal-header .tg-brand { min-width: 0; }
}

/* 顶栏和底部标签栏跟正文对齐: 正文 .tg-page 是 max-width:640 居中 + 20px 内边距,
   这两条原来都是通栏, 768 下 logo 在 x=14、页面标题在 x=84, 像两套栅格。
   (2026-09-20 布局修复 L72) */
@media (min-width: 560px) {
    .tg-portal-header {
        padding-left: max(20px, calc((100% - 640px) / 2 + 20px));
        padding-right: max(20px, calc((100% - 640px) / 2 + 20px));
    }

    .tg-tabbar {
        padding-left: max(0px, calc((100% - 640px) / 2));
        padding-right: max(0px, calc((100% - 640px) / 2));
    }
}

.tg-portal-logout {
    flex: none;
    appearance: none;
    border: 1px solid rgba(255, 255, 255, .28);
    background: transparent;
    color: #FFFFFF;
    font-size: 12px;
    line-height: 1;
    padding: 7px 10px;
    border-radius: 999px;
    cursor: pointer;
    white-space: nowrap;
}

.tg-portal-logout:active { opacity: .7; }

.tg-portal-page { padding-top: 14px; }

.tg-portal-title {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 6px;
}

.tg-portal-title h1 {
    margin: 0;
    font-size: 19px;
    font-weight: 700;
    color: var(--tg-text);
}

.tg-portal-back {
    flex: none;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: var(--tg-card);
    border: 1px solid var(--tg-border);
    color: var(--tg-text);
    font-size: 22px;
    line-height: 26px;
    text-align: center;
    text-decoration: none;
}

.tg-portal-sub {
    margin: 0 0 14px;
    font-size: 13px;
    color: var(--tg-muted);
    line-height: 1.6;
}

/* --- 登录 / 找回密码页上的次要链接("忘记密码?"、"返回登录") --- */
.tg-auth-link {
    margin: 14px 0 0;
    font-size: 13px;
    text-align: right;
}

.tg-auth-link a,
.tg-auth-links a {
    color: var(--tg-primary);
    text-decoration: none;
}

.tg-auth-links {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    margin: 14px 2px 0;
    font-size: 13px;
}

/* 重新发送验证码: 倒计时期间按钮置灰, 下面一行写着还要等几秒 */
.tg-resend {
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px dashed var(--tg-border);
}

.tg-resend .tg-hint {
    text-align: center;
}

/* 验证码输入框: 大字号 + 等宽 + 字距, 手机上一眼看清输了几位 */
.tg-input.is-code {
    font-size: 22px;
    letter-spacing: 6px;
    text-align: center;
    font-variant-numeric: tabular-nums;
}

.tg-portal-hint {
    margin: 0 0 10px;
    font-size: 12px;
    color: var(--tg-muted);
}

/* --- 底部标签栏 --- */

.tg-tabbar {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 30;
    display: flex;
    /* 标签栏高度原来完全由内容撑出来(中文一行 51px, 越南语两行 63px),
       正文预留的 64px 是个魔法数字, 只剩 1px 余量。定死 64px:
       标签已经 -webkit-line-clamp:2, 再长也不会把栏撑高。(2026-09-20 布局修复 L80) */
    min-height: 64px;
    background: var(--tg-card);
    border-top: 1px solid var(--tg-border);
    padding-bottom: env(safe-area-inset-bottom, 0px);
    box-shadow: 0 -2px 12px rgba(0, 0, 0, .05);
}

.tg-tabbar-item {
    flex: 1 1 0;
    min-width: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    /* 标签栏定了 min-height:64px(见 .tg-tabbar), 中文标签只有一行时内容要在
       栏里居中, 否则底下空一截。(2026-09-20 布局修复 L80) */
    justify-content: center;
    gap: 3px;
    padding: 9px 2px 8px;
    text-decoration: none;
    color: var(--tg-muted);
}

.tg-tabbar-item.is-active { color: var(--tg-primary); }

.tg-tabbar-icon { font-size: 17px; line-height: 1; }

/* 允许折成两行而不是截断。越南语的标签明显比中文长
   (「今日安装」=「Lắp đặt hôm nay」), 单行省略号会把它切成
   「Lắp đặt hôm...」—— 五个标签里有两个认不出来就等于没有标签栏。 */
.tg-tabbar-label {
    font-size: 11px;
    line-height: 1.15;
    text-align: center;
    max-width: 100%;
    white-space: normal;
    word-break: break-word;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* --- 页签切换 --- */

.tg-segment {
    display: flex;
    gap: 6px;
    overflow-x: auto;
    margin-bottom: 14px;
    padding-bottom: 2px;
    -webkit-overflow-scrolling: touch;
}

.tg-segment::-webkit-scrollbar { display: none; }

/* 平板及以上宽度直接把页签平铺换行, 不再横向滚动 —— 越南语 5 个页签总宽 689px,
   768 下容器只有 600px, 滚动条里看不见的页签等于不存在。
   手机宽度仍然横向滚动, 由 layout/portal.php 底部那几行 JS 把当前页签滚进视野。
   (2026-09-20 布局修复 L69) */
@media (min-width: 560px) {
    .tg-segment {
        flex-wrap: wrap;
        overflow-x: visible;
        row-gap: 8px;
    }
}

.tg-segment-item {
    flex: none;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 8px 13px;
    border-radius: 999px;
    border: 1px solid var(--tg-border);
    background: var(--tg-card);
    color: var(--tg-text);
    font-size: 13px;
    text-decoration: none;
    white-space: nowrap;
}

.tg-segment-item.is-active {
    background: var(--tg-primary);
    border-color: var(--tg-primary);
    color: #FFFFFF;
}

.tg-segment-badge {
    display: inline-block;
    min-width: 17px;
    padding: 0 5px;
    border-radius: 999px;
    background: var(--tg-primary-soft);
    color: var(--tg-primary);
    font-size: 11px;
    font-weight: 700;
    line-height: 17px;
    text-align: center;
}

.tg-segment-item.is-active .tg-segment-badge {
    background: rgba(255, 255, 255, .24);
    color: #FFFFFF;
}

/* --- 安装单卡片 --- */

.tg-order-list { display: grid; gap: 12px; }

/* 纵向 flex + 下面的 .tg-order-foot{margin-top:auto}: 卡片排成多列时 grid 会把
   它们拉成等高, 原来 display:block 的页脚不会被推到底, 多出来的高度全堆在卡片
   最下面, 两张卡的「门店应收」分隔横线一条高一条低。(2026-09-20 布局修复 L76) */
.tg-order {
    display: flex;
    flex-direction: column;
    background: var(--tg-card);
    border: 1px solid var(--tg-border);
    border-radius: var(--tg-radius);
    box-shadow: var(--tg-shadow);
    padding: 13px 14px;
    text-decoration: none;
    color: var(--tg-text);
}

.tg-order:active { opacity: .88; }

/* flex-wrap: 徽章加上 nowrap 之后, 卡片头的最小宽度变成「编号 113 + 间距 8 + 徽章 170
   = 291」, 再加 15px 内边距要 321px —— 320 的小屏(iPhone SE 一代 / 小安卓)上卡片
   反而比屏幕宽, 整页横向滚动。允许卡片头整行换行: 放不下时徽章整颗掉到第二行,
   胶囊本身仍然不折。实测 360 / 390 / 768 下卡片宽度与徽章尺寸不变, 只在 ≤325 生效。
   (2026-09-20 布局修复 L70 回归修正) */
.tg-order-head {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    margin-bottom: 8px;
}

/* 卡片窄下来(多列时每张只有 294-330px)时, 状态徽章不许折行 —— 折了圆角胶囊
   会被撑成方块, 旁边单行的安装编号又是垂直居中的, 两者明显错位。
   该让步的是编号: 它自己可以断行。(2026-09-20 布局修复 L70) */
.tg-order-head .tg-status {
    flex: none;
    white-space: nowrap;
}

.tg-order-no {
    flex: 0 1 auto;
    min-width: 0;
    font-family: var(--tg-mono, ui-monospace, monospace);
    font-size: 13px;
    font-weight: 700;
    letter-spacing: .4px;
}

.tg-order-product {
    display: flex;
    align-items: baseline;
    flex-wrap: wrap;
    gap: 6px;
}

.tg-order-product-name { font-size: 15px; font-weight: 700; line-height: 1.4; }

.tg-order-model {
    font-size: 12px;
    color: var(--tg-muted);
    background: var(--tg-bg);
    border-radius: 4px;
    padding: 1px 6px;
}

.tg-order-sn {
    margin: 4px 0 10px;
    font-family: var(--tg-mono, ui-monospace, monospace);
    font-size: 12px;
    color: var(--tg-muted);
    letter-spacing: .5px;
}

.tg-order-meta {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px 12px;
    /* 和页脚之间的 11px 间距原来写在 .tg-order-foot 的 margin-top 上,
       页脚改成 margin-top:auto 贴底后挪到这里(2026-09-20 布局修复 L76) */
    margin: 0 0 11px;
    padding: 10px 0 0;
    border-top: 1px dashed var(--tg-border);
}

.tg-order-meta > div { min-width: 0; }
.tg-order-meta > div.is-wide { grid-column: 1 / -1; }

/* 左右两列的标签行数不一样时(越南语普遍两行、中文一行), 下面的数值就不在同一条
   水平线上, 金额高低错落。用 subgrid 让同一行的 dt / dd 共用行高。
   不支持 subgrid 的浏览器退回现在的表现, 不会更差。(2026-09-20 布局修复 L74) */
@supports (grid-template-rows: subgrid) {
    .tg-order-meta > div {
        display: grid;
        grid-template-rows: subgrid;
        grid-row: span 2;
        row-gap: 0;
    }
}

.tg-order-meta dt {
    font-size: 11px;
    color: var(--tg-muted);
    margin-bottom: 2px;
}

.tg-order-meta dd {
    margin: 0;
    font-size: 13px;
    line-height: 1.5;
    word-break: break-word;
}

.tg-order-meta dd.is-muted { color: var(--tg-muted); }

/* 预约时间这类「日期 + 时段」的值不许从中间断开:
   模板把日期和时段各包一个 .is-nowrap, 放不下就整段换行, 不会切成
   「19/09/2026 11:00-」/「12:00」。(2026-09-20 布局修复 L77) */
.tg-order-meta .is-nowrap { white-space: nowrap; }

.tg-order-foot {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    /* 卡片等高时页脚贴底, 分隔横线才对得齐(配合 .tg-order 的纵向 flex) */
    margin-top: auto;
    padding-top: 10px;
    border-top: 1px solid var(--tg-border);
}

.tg-order-fee { min-width: 0; font-size: 12px; color: var(--tg-muted); }
.tg-order-fee strong { margin-left: 5px; font-size: 14px; color: var(--tg-primary); }

/* 「查看详情 ›」是固定的一句话, 折成两行只会让人以为渲染坏了 */
.tg-order-go { flex: none; white-space: nowrap; font-size: 12px; color: var(--tg-muted); }

/* --- 详情页 --- */

.tg-row-value.is-muted { color: var(--tg-muted); font-weight: 400; }
.tg-row-value.is-danger { color: var(--tg-danger); }
/* 结算页把标签列当成「编号列」用(INS202609190038 / AS202609190006)。
   等宽的 15 位安装编号要 105px, 而标签列写死 96px 且禁止收缩, 编号溢出自己的格子,
   和右边的金额之间只剩 3px, 看上去像「INS202609190038300.000 ₫」连成一串。
   编号列按内容给宽度, 96px 打底, 最多占半屏多一点。(2026-09-20 布局修复 L71) */
.tg-row-label.is-mono {
    font-family: var(--tg-mono, ui-monospace, monospace);
    width: auto;
    min-width: 96px;
    max-width: 60%;
}

.tg-contact { display: flex; gap: 10px; margin-top: 12px; }
.tg-contact .tg-btn { flex: 1 1 0; }

.tg-btn-danger {
    background: var(--tg-danger);
    color: #FFFFFF;
}

/* 次要按钮是白底 + 很淡的边框。客户端那边它落在灰色页面背景上, 对比够;
   工作台里所有按钮都在白色卡片内部, 白底白卡片叠一起就只剩一圈几乎看不见的
   细线 —— 看上去像一行文字而不是能按的东西。给它一点底色。 */
.tg-portal-page .tg-btn-secondary {
    background: var(--tg-bg);
    border-color: #D8D8D8;
}

/* 折叠式操作表单: 手机上一屏放不下四五个带输入框的表单,
   收起来以后「当前该做什么」才看得清 */
.tg-disclosure {
    border: 1px solid var(--tg-border);
    border-radius: 10px;
    margin-bottom: 10px;
    overflow: hidden;
}

/* flex 两端对齐取代 float:right —— 浮动的标记在文案折行时会浮到第一行右上角、
   文字绕着它排(2026-09-20 布局修复 L78) */
.tg-disclosure > summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 12px 14px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    background: var(--tg-bg);
    list-style: none;
}

.tg-disclosure > summary::-webkit-details-marker { display: none; }

/* 展开收起标记用两条线画, 不用全角「＋」「－」: 系统字体里这两个全角字形的
   粗细和字宽差很多, 展开后的横杠比收起时的加号小一大圈, 像渲染缺字。
   (2026-09-20 布局修复 L78) */
.tg-disclosure > summary::after {
    content: "";
    flex: none;
    width: 11px;
    height: 11px;
    background:
        linear-gradient(var(--tg-muted), var(--tg-muted)) center / 11px 1.5px no-repeat,
        linear-gradient(var(--tg-muted), var(--tg-muted)) center / 1.5px 11px no-repeat;
}

.tg-disclosure[open] > summary::after {
    background: linear-gradient(var(--tg-muted), var(--tg-muted)) center / 11px 1.5px no-repeat;
}

.tg-disclosure.is-danger > summary { color: var(--tg-danger); }

.tg-disclosure > form { padding: 14px; }

.tg-card-body > form { margin-bottom: 10px; }

/* --- 费用高亮 --- */

.tg-fee-highlight {
    margin: 12px 0;
    padding: 13px 14px;
    border-radius: 10px;
    background: var(--tg-primary-soft);
}

.tg-fee-highlight > div {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 10px;
}

.tg-fee-highlight .k { font-size: 13px; color: var(--tg-text); font-weight: 600; }
.tg-fee-highlight .v { font-size: 19px; font-weight: 700; color: var(--tg-primary); }

.tg-fee-tip {
    margin: 6px 0 0;
    font-size: 12px;
    line-height: 1.6;
    color: var(--tg-muted);
}

/* --- 安装照片 --- */

.tg-evidence-group { margin-bottom: 16px; }

.tg-evidence-title {
    display: flex;
    align-items: center;
    gap: 7px;
    font-size: 13px;
    font-weight: 600;
    margin-bottom: 8px;
}

.tg-evidence-count {
    display: inline-block;
    min-width: 18px;
    padding: 0 6px;
    border-radius: 999px;
    background: var(--tg-bg);
    color: var(--tg-muted);
    font-size: 11px;
    font-weight: 700;
    line-height: 18px;
    text-align: center;
}

.tg-evidence-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
}

.tg-evidence-item { margin: 0; }

.tg-evidence-item img {
    display: block;
    width: 100%;
    aspect-ratio: 1 / 1;
    object-fit: cover;
    border-radius: 8px;
    border: 1px solid var(--tg-border);
    background: var(--tg-bg);
}

.tg-evidence-item figcaption {
    margin-top: 4px;
    font-size: 11px;
    color: var(--tg-muted);
    text-align: center;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.tg-upload {
    margin-top: 14px;
    padding-top: 14px;
    border-top: 1px dashed var(--tg-border);
}

/* --- 师傅端流程进度条 --- */

.tg-steps { list-style: none; margin: 0; padding: 0; }

.tg-step {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 9px 0;
    border-bottom: 1px solid var(--tg-border);
}

.tg-step:last-child { border-bottom: 0; }

.tg-step-no {
    flex: none;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: var(--tg-bg);
    color: var(--tg-muted);
    font-size: 12px;
    font-weight: 700;
    line-height: 22px;
    text-align: center;
}

.tg-step-label { flex: 1 1 auto; font-size: 14px; min-width: 0; }

.tg-step-state { flex: none; font-size: 11px; color: var(--tg-muted); }

.tg-step.is-done .tg-step-no { background: var(--tg-success); color: #FFFFFF; }
.tg-step.is-done .tg-step-label { color: var(--tg-muted); }
.tg-step.is-done .tg-step-state { color: var(--tg-success); }

.tg-step.is-current .tg-step-no { background: var(--tg-primary); color: #FFFFFF; }
.tg-step.is-current .tg-step-label { font-weight: 700; }
.tg-step.is-current .tg-step-state { color: var(--tg-primary); font-weight: 700; }

.tg-step.is-locked .tg-step-label { color: var(--tg-muted); }

/* --- 结算明细 --- */

.tg-settle-item {
    padding: 11px 0;
    border-bottom: 1px solid var(--tg-border);
}

.tg-settle-item:last-child { border-bottom: 0; }

.tg-settle-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 10px;
    font-size: 13px;
}

.tg-settle-head .is-mono { font-family: var(--tg-mono, ui-monospace, monospace); }
.tg-settle-head strong { color: var(--tg-primary); font-size: 14px; }

.tg-settle-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 4px 12px;
    margin-top: 4px;
    font-size: 12px;
    color: var(--tg-muted);
}

.tg-settle-meta .is-mono { font-family: var(--tg-mono, ui-monospace, monospace); }
.tg-settle-meta .is-danger,
.tg-settle-head .is-danger { color: var(--tg-danger); }

/* --- 翻页 --- */

.tg-pager { display: flex; gap: 10px; margin-top: 16px; }
.tg-pager .tg-btn { flex: 1 1 0; }

/* --- 勾选项(申请入驻「我本人也上门安装」): 整行可点, 勾选框放大到手指点得中 --- */

.tg-check {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
}

.tg-check input {
    flex: none;
    width: 20px;
    height: 20px;
    margin: 1px 0 0;
    accent-color: var(--tg-primary);
}

/* 登录页下方「申请成为合作门店」: 与卡片隔开, 居中一行 */
.tg-apply-entry {
    margin: 18px 0 0;
    text-align: center;
    font-size: 14px;
}

/* 平板及以上: 卡片两列, 标签栏回到常规宽度 */
@media (min-width: 720px) {
    /* 原来无条件两列。正文最宽 640px, 两列每张卡只剩 294px:
       越南语状态徽章折成两行、「查看详情 ›」被拆开、「门店应收」也折行;
       结算页只有一张卡时还会缩成半宽, 右边空一片像漏渲染了一半。
       改成够宽才排两列 —— 每张卡至少 330px, 放不下就老老实实一列占满。
       (2026-09-20 布局修复 L70 / L75) */
    .tg-order-list { grid-template-columns: repeat(auto-fit, minmax(330px, 1fr)); }
    .tg-evidence-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
