/* 页面级组件样式 · 门店端 */

/* TabBar */
.sm-tabbar {
  height: 62px;
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(12px);
  border-top: 1px solid var(--color-divider);
  display: flex;
  flex-shrink: 0;
  padding: 0 4px 4px;
  position: relative;
  z-index: 10;
}
.sm-tabbar__item {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  border: none;
  background: transparent;
  cursor: pointer;
  position: relative;
  color: var(--color-text-muted);
  font-family: inherit;
  padding: 6px 0 4px;
  transition: color 0.18s;
}
.sm-tabbar__item.is-active { color: var(--color-primary); }
.sm-tabbar__icon {
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.sm-tabbar__icon svg { width: 22px; height: 22px; display: block; }
.sm-tabbar__label {
  font-size: 10px;
  font-weight: 550;
  letter-spacing: 0.04em;
}
.sm-tabbar__item.is-active .sm-tabbar__label { font-weight: 650; }
.sm-tabbar__indicator {
  position: absolute;
  top: 2px;
  width: 16px;
  height: 3px;
  border-radius: 2px;
  background: linear-gradient(90deg, #165DFF, #36D399);
}

/* Customer card */
.cust-card__main { display: flex; gap: 12px; align-items: flex-start; }
.cust-card__info { flex: 1; min-width: 0; }
.cust-card__name-row { display: flex; align-items: center; gap: 8px; }
.cust-card__name { font-size: 16px; font-weight: 620; color: var(--color-text); }
.cust-card__sub { margin-top: 4px; font-size: 12px; color: var(--color-text-secondary); }
.cust-card__tags { margin-top: 8px; }
.cust-card__foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid var(--color-divider);
}
.cust-card__profit { display: flex; align-items: baseline; }

/* Appointment card */
.appt-card__head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}
.appt-card__service {
  font-size: 16px;
  font-weight: 620;
  color: var(--color-text);
  line-height: 1.35;
  flex: 1;
}
.appt-card__meta {
  background: var(--color-bg-soft);
  border-radius: var(--radius-md);
  padding: 12px 14px;
}
.appt-card__meta-row {
  display: flex;
  align-items: baseline;
  gap: 12px;
  padding: 4px 0;
}
.appt-card__label {
  width: 36px;
  flex-shrink: 0;
  font-size: 12px;
  color: var(--color-text-muted);
  font-weight: 500;
}
.appt-card__value {
  font-size: 13px;
  color: var(--color-text-secondary);
  font-weight: 500;
}
.appt-card__time {
  font-family: var(--font-num);
  font-variant-numeric: tabular-nums;
  color: var(--color-text);
  font-weight: 600;
  font-size: 14px;
}
.appt-card__actions {
  display: flex;
  gap: 8px;
  margin-top: 14px;
}
.appt-card__actions .sm-btn--primary { flex: 1.2; }
.appt-card__actions .sm-btn--ghost { flex: 1; }

/* Flow / finance rows */
.flow-list {
  background: var(--color-bg-elevated);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
  border: 1px solid rgba(232, 236, 242, 0.8);
  overflow: hidden;
  margin-bottom: var(--space-lg);
}
.flow-list__head {
  display: grid;
  grid-template-columns: 1.1fr 1fr 1fr;
  padding: 10px 16px;
  background: var(--color-bg-soft);
  border-bottom: 1px solid var(--color-divider);
  font-size: 11px;
  font-weight: 560;
  color: var(--color-text-muted);
  letter-spacing: 0.04em;
}
.flow-list__head span:nth-child(2),
.flow-list__head span:nth-child(3) { text-align: right; }

.flow-row {
  display: grid;
  grid-template-columns: 1.1fr 1fr 1fr;
  align-items: center;
  padding: 14px 16px;
  border-bottom: 1px solid var(--color-divider);
}
.flow-row:last-child { border-bottom: none; }
.flow-row__date {
  font-family: var(--font-num);
  font-size: 13px;
  font-weight: 600;
  color: var(--color-text);
  font-variant-numeric: tabular-nums;
}
.flow-row__type {
  margin-top: 3px;
  font-size: 11px;
  color: var(--color-text-muted);
}
.flow-row__mid, .flow-row__right { text-align: right; }
.flow-row__label {
  font-size: 10px;
  color: var(--color-text-muted);
  margin-bottom: 3px;
  letter-spacing: 0.03em;
}

/* Revenue hero */
.revenue-hero {
  border-radius: var(--radius-xl);
  padding: 22px 20px 20px;
  color: #fff;
  background: linear-gradient(135deg, #165DFF 0%, #2A7DE8 42%, #36D399 145%);
  box-shadow: 0 10px 28px rgba(22, 93, 255, 0.18);
  position: relative;
  overflow: hidden;
  margin-bottom: var(--space-md);
}
.revenue-hero::after {
  content: '';
  position: absolute;
  right: -40px;
  top: -40px;
  width: 140px;
  height: 140px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  pointer-events: none;
}
.revenue-hero__label {
  font-size: 13px;
  opacity: 0.82;
  font-weight: 500;
  letter-spacing: 0.02em;
}
.revenue-hero__amount {
  margin-top: 8px;
  font-family: var(--font-num);
  font-size: 36px;
  font-weight: 700;
  letter-spacing: -0.03em;
  font-variant-numeric: tabular-nums;
}
.revenue-hero__amount .currency {
  font-size: 18px;
  font-weight: 600;
  margin-right: 4px;
  opacity: 0.9;
}
.revenue-hero__foot {
  display: flex;
  justify-content: space-between;
  margin-top: 18px;
  padding-top: 14px;
  border-top: 1px solid rgba(255, 255, 255, 0.18);
  font-size: 13px;
  opacity: 0.92;
}
.revenue-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: var(--space-lg);
}
.revenue-stat {
  background: var(--color-bg-elevated);
  border-radius: var(--radius-lg);
  padding: 16px;
  box-shadow: var(--shadow-card);
  border: 1px solid rgba(232, 236, 242, 0.8);
  text-align: left;
}
.revenue-stat__label {
  font-size: 12px;
  color: var(--color-text-muted);
  margin-bottom: 8px;
}

/* Login */
.login-page {
  min-height: 100%;
  background:
    radial-gradient(ellipse 80% 50% at 20% -10%, rgba(54, 211, 153, 0.18), transparent 55%),
    linear-gradient(165deg, #165DFF 0%, #3A7AE8 38%, var(--color-bg) 38.2%);
  padding: 52px 20px 28px;
}
.login-brand { text-align: center; color: #fff; margin-bottom: 8px; }
.login-brand__logo {
  width: 68px;
  height: 68px;
  margin: 0 auto 14px;
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.16);
  border: 1px solid rgba(255, 255, 255, 0.22);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 26px;
  font-weight: 700;
  backdrop-filter: blur(8px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
}
.login-brand__title { font-size: 24px; font-weight: 680; letter-spacing: 0.04em; }
.login-brand__sub { margin-top: 6px; font-size: 13px; opacity: 0.82; }
.login-form {
  margin-top: 36px;
  background: #fff;
  border-radius: var(--radius-xl);
  padding: 24px 20px 22px;
  box-shadow: var(--shadow-float);
}
.login-form__title { font-size: 18px; font-weight: 650; color: var(--color-text); }
.login-form__desc { margin: 6px 0 4px; font-size: 13px; color: var(--color-text-secondary); line-height: 1.5; }
.login-tenant {
  display: inline-flex;
  margin-top: 16px;
  padding: 4px 10px;
  border-radius: var(--radius-full);
  background: var(--color-bg-soft);
  font-size: 11px;
  color: var(--color-text-secondary);
  font-family: var(--font-num);
}

/* Mine */
.mine-hero {
  background: linear-gradient(135deg, #165DFF 0%, #2A7DE8 48%, #36D399 160%);
  color: #fff;
  padding: 24px 18px 22px;
  border-radius: 0 0 24px 24px;
  box-shadow: 0 8px 24px rgba(22, 93, 255, 0.14);
}
.mine-hero__name { font-size: 18px; font-weight: 650; }
.mine-hero__code { margin-top: 4px; font-size: 12px; opacity: 0.82; font-family: var(--font-num); }
.mine-quick {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  margin-top: 20px;
  text-align: center;
}
.mine-quick__item {
  cursor: pointer;
  padding: 10px 4px;
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.1);
  transition: background 0.15s;
}
.mine-quick__item:active { background: rgba(255, 255, 255, 0.2); }
.mine-quick__ico {
  width: 28px;
  height: 28px;
  margin: 0 auto 6px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.mine-quick__ico svg { width: 22px; height: 22px; }
.mine-quick__txt { font-size: 11px; opacity: 0.92; font-weight: 500; }

.menu-group { margin-top: 4px; }
.menu-group__title {
  font-size: 12px;
  font-weight: 560;
  color: var(--color-text-muted);
  margin: 4px 0 10px;
  letter-spacing: 0.04em;
}
.menu-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 0;
  border-bottom: 1px solid var(--color-divider);
  font-size: 14px;
  color: var(--color-text);
  cursor: pointer;
}
.menu-item:last-child { border-bottom: none; }
.menu-item__right { color: var(--color-text-muted); font-size: 13px; }
.menu-item--danger { color: var(--color-danger); }

/* Detail tabs */
.detail-tabs {
  display: flex;
  gap: 8px;
  margin-bottom: var(--space-md);
  overflow-x: auto;
}
.detail-tab {
  flex-shrink: 0;
  border: none;
  background: var(--color-bg-elevated);
  color: var(--color-text-secondary);
  padding: 7px 14px;
  border-radius: var(--radius-full);
  font-size: 13px;
  font-weight: 550;
  cursor: pointer;
  box-shadow: var(--shadow-card);
  font-family: inherit;
  border: 1px solid transparent;
}
.detail-tab.is-active {
  background: rgba(22, 93, 255, 0.08);
  color: var(--color-primary);
  border-color: rgba(22, 93, 255, 0.18);
}

.health-box {
  margin-top: 10px;
  padding: 12px 14px;
  background: linear-gradient(135deg, rgba(54, 211, 153, 0.08), rgba(22, 93, 255, 0.05));
  border-radius: var(--radius-md);
  border-left: 3px solid var(--color-mint);
  font-size: 13px;
  color: var(--color-text-secondary);
  line-height: 1.55;
}

.tenant-pill {
  display: inline-flex;
  align-items: center;
  padding: 3px 10px;
  border-radius: var(--radius-full);
  background: rgba(22, 93, 255, 0.07);
  color: var(--color-primary);
  font-size: 11px;
  font-family: var(--font-num);
  font-weight: 550;
}
