/* 登记系统 / 弹层 / 卡片 等交互层样式（两端共用） */

[hidden] { display: none !important; }

body.is-locked { overflow: hidden; }

/* ---------- 首次引导浮层 ---------- */
.toast {
  position: fixed;
  left: 50%;
  top: 42%;
  z-index: 400;
  max-width: 82vw;
  padding: 12px 18px;
  transform: translate(-50%, -50%) scale(.94);
  background: rgba(0, 0, 0, .78);
  color: #fff;
  font-size: 13px;
  line-height: 20px;
  text-align: center;
  border-radius: 10px;
  opacity: 0;
  pointer-events: none;
  transition: opacity .25s ease, transform .25s ease;
}

.toast.is-open {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1);
  pointer-events: auto;
}

.toast b {
  display: block;
  font-weight: 500;
  font-size: 14px;
}

.toast span {
  color: rgba(255, 255, 255, .82);
}

/* ---------- 遮罩与弹层 ---------- */
.overlay {
  position: fixed;
  inset: 0;
  z-index: 250;
  background: rgba(0, 0, 0, .55);
  opacity: 0;
  transition: opacity .22s ease;
}

.overlay:not([hidden]) { opacity: 1; }

.sheet {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 300;
  display: flex;
  flex-direction: column;
  max-width: 600px;
  margin: 0 auto;
  max-height: 90vh;
  background: #fff;
  border-radius: 16px 16px 0 0;
  box-shadow: 0 -2px 20px rgba(0, 0, 0, .10);
  transform: translateY(100%);
  transition: transform .24s cubic-bezier(.22, .61, .36, 1);
  padding-bottom: env(safe-area-inset-bottom);
}

.sheet.is-open { transform: translateY(0); }

.sheet--full { height: 88vh; }

.sheet__hd {
  flex: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 16px 10px;
}

.sheet__title {
  font-size: 16px;
  font-weight: 500;
  color: #323233;
}

.sheet__close {
  width: 26px;
  height: 26px;
  line-height: 24px;
  text-align: center;
  font-size: 22px;
  font-weight: 400;
  color: #969799;
  cursor: pointer;
  border-radius: 50%;
}

.sheet__close:active { background: #f2f3f5; }

.sheet__sub {
  padding: 0 0 10px;
  font-size: 13px;
  color: #969799;
}

.sheet__bd {
  flex: 1;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  padding: 0 16px 8px;
}

.sheet__err {
  min-height: 18px;
  padding: 8px 0 0;
  font-size: 12px;
  line-height: 18px;
  color: #ee0a24;
}

.sheet__ft {
  flex: none;
  display: flex;
  gap: 10px;
  padding: 12px 16px 16px;
  border-top: 1px solid #f2f3f5;
}

/* ---------- 表单 ---------- */
.field {
  display: flex;
  align-items: center;
  min-height: 46px;
  border-bottom: 1px solid #ebedf0;
}

.field__label {
  flex: none;
  width: 74px;
  font-size: 14px;
  color: #646566;
}

.field input {
  flex: 1;
  min-width: 0;
  border: 0;
  outline: 0;
  background: transparent;
  font-size: 15px;
  color: #323233;
  font-family: inherit;
  padding: 10px 0;
  -webkit-appearance: none;
}

.field input::placeholder { color: #c8c9cc; }

.field--ro .field__val {
  font-size: 15px;
  color: #323233;
}

/* ---------- 按钮 ---------- */
.btn {
  flex: 1;
  height: 44px;
  border: 0;
  border-radius: 6px;
  font-size: 15px;
  font-family: inherit;
  cursor: pointer;
  -webkit-appearance: none;
}

.btn--primary {
  background: #1989fa;
  color: #fff;
}

.btn--primary:active { background: #1677e6; }

.btn--ghost {
  background: #f7f8fa;
  color: #323233;
}

.btn--ghost:active { background: #ebedf0; }

/* ---------- 详情键值表 ---------- */
.kv__row {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 11px 0;
  border-bottom: 1px solid #f2f3f5;
  font-size: 14px;
  line-height: 21px;
}

.kv__k {
  flex: none;
  width: 56px;
  color: #969799;
}

.kv__v {
  flex: 1;
  min-width: 0;
  color: #323233;
  word-break: break-word;
}

.kv__v a { color: #1989fa; text-decoration: none; }

/* ---------- 订单列表 ---------- */
.list-stat {
  padding: 4px 0 12px;
  font-size: 12px;
  color: #969799;
}

.list-stat b {
  color: #323233;
  font-weight: 500;
}

.empty {
  padding: 48px 16px;
  text-align: center;
  font-size: 13px;
  color: #c8c9cc;
}

.ord {
  padding: 12px;
  margin-bottom: 10px;
  background: #f7f8fa;
  border-radius: 10px;
  cursor: pointer;
}

.ord:active { background: #f2f3f5; }

.ord.is-past { opacity: .55; }

.ord__hd {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
}

.ord__room {
  font-size: 14px;
  font-weight: 500;
  color: #323233;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.ord__date {
  flex: none;
  font-size: 12px;
  color: #969799;
}

.ord__bd {
  margin-top: 6px;
  font-size: 13px;
  color: #646566;
}

.ord__note {
  margin-top: 4px;
  font-size: 12px;
  color: #969799;
}

.muted { color: #c8c9cc; }

.tag {
  display: inline-block;
  margin-left: 6px;
  padding: 0 5px;
  font-size: 11px;
  font-style: normal;
  line-height: 16px;
  color: #969799;
  border: 1px solid #dcdee0;
  border-radius: 3px;
}

.tag--live {
  color: #07c160;
  border-color: #07c160;
}

/* ================= 角色顶栏（管理端） ================= */
.rolebar {
  flex: none;
  display: flex;
  align-items: center;
  gap: 10px;
  height: 44px;
  padding: 0 12px;
  box-sizing: border-box;
  background: #1f2d3d;
  color: #fff;
}

.rolebar__back {
  flex: none;
  width: 26px;
  height: 26px;
  margin-left: -6px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: rgba(255, 255, 255, .8);
  text-decoration: none;
  border-radius: 50%;
}

.rolebar__back svg {
  width: 19px;
  height: 19px;
}

.rolebar__back:active {
  background: rgba(255, 255, 255, .12);
}

.rolebar__main {
  flex: 1;
  min-width: 0;
  display: flex;
  align-items: baseline;
  gap: 8px;
}

.rolebar__main b {
  font-size: 14px;
  font-weight: 600;
  letter-spacing: .3px;
}

.rolebar__main span {
  font-size: 11px;
  color: rgba(255, 255, 255, .55);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.rolebar__act {
  flex: none;
  padding: 4px 11px;
  font-size: 12px;
  font-weight: 400;
  color: #fff;
  border: 1px solid rgba(255, 255, 255, .28);
  border-radius: 20px;
  cursor: pointer;
}

.rolebar__act:active {
  background: rgba(255, 255, 255, .12);
}

/* ================= 管理端整体高度分配 ================= */
body.admin {
  display: flex;
  flex-direction: column;
  height: 100vh;
  height: 100dvh;
  padding-bottom: 58px;
  box-sizing: border-box;
  overflow: hidden;
}

body.admin #app {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-height: 0;
}

body.admin .table-wrap {
  flex: 1;
  min-height: 0;
  height: auto;
}

body.admin .collapse {
  flex: none;
}
