/* ============================================================
   pages/cart · 购物车 / 结算
   ============================================================ */

.cart-layout { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); gap: 26px; align-items: start; }
@media (max-width: 900px) { .cart-layout { grid-template-columns: 1fr; } }

/* ---------- 面板内边距 ---------- */
.panel-pad { padding: 22px; }
.panel-pad h2 { font-size: 17px; font-weight: 700; margin-bottom: 4px; }
.panel-pad .sub { font-size: 12.5px; color: var(--ink-3); margin-bottom: 16px; }

/* ---------- 单行商品 ---------- */
.line {
  display: grid;
  grid-template-columns: 74px minmax(0, 1fr) auto;
  gap: 16px;
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
  align-items: center;
}
.line:last-child { border-bottom: 0; }
.line .thumb {
  width: 74px;
  height: 74px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.line .thumb img { max-width: 66px; max-height: 66px; object-fit: contain; }
.line .nm { font-size: 14.5px; font-weight: 700; line-height: 1.35; }
.line .nm a:hover { color: var(--brand); text-decoration: underline; }
.line .meta { font-size: 12.5px; color: var(--ink-3); margin-top: 3px; }
.line .unit { font-size: 12.5px; color: var(--ink-2); margin-top: 6px; }
.line .right { text-align: right; display: flex; flex-direction: column; align-items: flex-end; gap: 8px; }
.line .total { font-size: 15px; font-weight: 700; color: var(--brand); }

.remove { border: 0; background: none; color: var(--ink-3); font-size: 12px; cursor: pointer; text-decoration: underline; padding: 0; }
.remove:hover { color: var(--danger); }

.included { font-size: 12px; color: var(--ok); font-weight: 600; }

/* ---------- 表单：必填 / 选填标记 ---------- */
.tag-req,
.tag-opt {
  display: inline-block;
  margin-left: 6px;
  padding: 1px 7px;
  border-radius: 999px;
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: .3px;
  text-transform: uppercase;
  vertical-align: 1px;
}
.tag-req { background: var(--danger-soft, #fdecea); color: var(--danger); }
.tag-opt { background: #eef1f5; color: var(--ink-3); }

.form-err {
  margin: 0 0 12px;
  padding: 9px 12px;
  border-radius: 8px;
  background: #fdecea;
  color: var(--danger);
  font-size: 12.5px;
  line-height: 1.5;
}

/* ---------- 平台联系方式 ---------- */
.chat-card {
  margin-top: 18px;
  padding: 16px 16px 14px;
  border: 1px dashed var(--line);
  border-radius: 10px;
  background: #fafbfd;
}
.chat-title { font-size: 13.5px; font-weight: 700; margin-bottom: 4px; }
.chat-card p { font-size: 12.5px; color: var(--ink-2); margin-bottom: 10px; line-height: 1.55; }
.chat-links { display: flex; flex-direction: column; gap: 8px; }
.chat-link {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: #fff;
  font-size: 13px;
  color: var(--ink-2);
}
.chat-link:hover { border-color: var(--brand); color: var(--brand); }
.chat-link .ic {
  width: 26px;
  height: 26px;
  flex: 0 0 26px;
  border-radius: 7px;
  background: var(--brand-soft);
  color: var(--brand);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
}
.chat-link b { color: var(--ink); font-weight: 700; }
.chat-link[hidden] { display: none !important; }

/* ---------- 下单成功 ---------- */
.confirm { padding: 34px 26px; text-align: center; }
.confirm .tick {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: var(--ok-soft);
  color: var(--ok);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 26px;
  margin: 0 auto 14px;
}
.confirm h2 { font-size: 20px; margin-bottom: 6px; }
.confirm p { font-size: 13.5px; color: var(--ink-2); max-width: 460px; margin: 0 auto 6px; line-height: 1.6; }
.confirm .acts { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; }

/* 明细列表：和 orderbox 同宽居中，别顶着左边缘 */
.done-items {
  max-width: 420px;
  margin: 0 auto 18px;
  padding-left: 18px;
  text-align: left;
  font-size: 13px;
  color: var(--ink-2);
  line-height: 1.9;
}

/* ---------- 下单成功：四个去向按钮 ----------
   胶囊造型（参考运营给的样式稿），但配色全部走 tokens：
   浅底 + 细边 + 图标圆底，主推的 App 用品牌色描边强调。 */
/* 提示语现在在胶囊下方（Google 评价排在第一个，提示压在它头顶会读错），
   所以按钮行下边距收窄，由提示语接管与下方文字链之间的留白。 */
.done-hint {
  font-size: 13px;
  color: var(--ink-2);
  max-width: 460px;
  margin: 0 auto 20px;
  line-height: 1.6;
}
.done-hint[hidden] { display: none !important; }
.done-acts {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
  margin: 0 auto 14px;
}
.done-acts[hidden] { display: none !important; }
.done-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-width: 190px;
  padding: 9px 18px 9px 11px;
  border: 1px solid var(--line);
  border-radius: var(--radius-pill);
  background: var(--card);
  box-shadow: var(--shadow);
  color: var(--ink);
  text-decoration: none;
  transition: border-color .15s, box-shadow .15s, transform .15s;
}
.done-btn:hover {
  border-color: var(--brand-2);
  box-shadow: var(--shadow-lg);
  transform: translateY(-1px);
}
.done-btn .di {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: var(--brand-soft);
  color: var(--brand);
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
}
.done-btn .dt {
  display: flex;
  flex-direction: column;
  line-height: 1.3;
  text-align: left;
}
.done-btn .dt b { font-size: 13.5px; font-weight: 700; }
.done-btn .dt small {
  font-size: 11.5px;
  color: var(--ink-2);
  white-space: nowrap;
}
/* 主推项：App 下载。图标底反色，边框用主蓝。 */
.done-btn.app { border-color: var(--brand-2); }
.done-btn.app .di { background: var(--brand); color: var(--nav-ink); }
/* 评分用行动色的深色版，和站内其它星级一致 */
.done-btn.goog .dt small { color: var(--action-dark); letter-spacing: .5px; }
.done-links { gap: 16px; margin-top: 4px; }
.done-links a {
  font-size: 12.5px;
  color: var(--ink-2);
  text-decoration: underline;
  text-underline-offset: 3px;
}
.done-links a:hover { color: var(--brand); }

.orderbox {
  margin: 18px auto 20px;
  max-width: 420px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fbfcfe;
  padding: 14px 16px;
  text-align: left;
}
.orderbox .kv { display: flex; justify-content: space-between; gap: 14px; font-size: 13.5px; color: var(--ink-2); padding: 4px 0; }
.orderbox .kv b { color: var(--ink); }
