:root {
  color-scheme: light;
  --ink: #1d252c;
  --muted: #63717c;
  --line: #dfe6ea;
  --soft: #f5f8f7;
  --panel: #ffffff;
  --accent: #0b7a75;
  --accent-strong: #075f5a;
  --warm: #c54f2e;
  --gold: #b7791f;
  --ok: #247a3d;
  --danger: #b42318;
  --shadow: 0 14px 34px rgba(29, 37, 44, 0.12);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-width: 320px;
  color: var(--ink);
  background: #f3f6f5;
  font-family:
    Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    "Noto Sans SC", "PingFang SC", "Microsoft YaHei", sans-serif;
  letter-spacing: 0;
}

button,
input,
select,
textarea {
  font: inherit;
}

button {
  border: 0;
  cursor: pointer;
}

.shell {
  min-height: 100vh;
  display: grid;
  grid-template-rows: auto 1fr;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px clamp(16px, 4vw, 36px);
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(14px);
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 180px;
}

.brand-mark {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: var(--accent);
  color: #fff;
  font-weight: 800;
  box-shadow: 0 8px 20px rgba(11, 122, 117, 0.22);
}

.brand-title {
  margin: 0;
  font-size: 18px;
  line-height: 1.15;
}

.brand-subtitle {
  margin: 2px 0 0;
  color: var(--muted);
  font-size: 12px;
}

.tabs {
  display: flex;
  gap: 6px;
  padding: 4px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--soft);
}

.private-portal-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 36px;
  padding: 0 12px;
  border: 1px solid rgba(11, 122, 117, 0.28);
  border-radius: 8px;
  background: #eef7f7;
  color: var(--accent-strong);
  font-size: 13px;
  font-weight: 800;
  white-space: nowrap;
}

.private-portal-badge button {
  min-height: 26px;
  padding: 0 8px;
  border-radius: 7px;
  color: #fff;
  background: var(--accent);
  font-size: 12px;
}

.portal-auth-card {
  width: min(520px, 100%);
  display: grid;
  gap: 16px;
  margin: 48px auto;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 18px 38px rgba(29, 37, 44, 0.08);
}

.portal-auth-card h2 {
  margin: 0 0 6px;
}

.portal-auth-card p {
  margin: 0;
  color: var(--muted);
  line-height: 1.5;
}

.mode-switch {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 42px;
  padding: 0 12px 0 8px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  white-space: nowrap;
  box-shadow: 0 10px 22px rgba(15, 23, 42, 0.06);
}

.mode-switch span {
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: #eef7f7;
  color: var(--accent);
  font-weight: 800;
}

.mode-switch strong {
  font-size: 13px;
}

.mode-switch.enterprise {
  border-color: rgba(11, 122, 117, 0.35);
  background: #f3fbf9;
}

.mode-switch.enterprise span {
  background: var(--accent);
  color: #fff;
}

.mode-segment {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
  min-width: 238px;
  padding: 4px;
  border: 1px solid rgba(255, 255, 255, 0.42);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.2);
  box-shadow: 0 12px 28px rgba(11, 42, 39, 0.2);
}

.mode-segment button {
  min-height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 0 9px;
  border-radius: 7px;
  color: rgba(255, 255, 255, 0.92);
  background: transparent;
  font-weight: 900;
  white-space: nowrap;
}

.mode-segment button.active {
  color: var(--accent-strong);
  background: #fff;
}

.mode-segment span {
  width: 22px;
  height: 22px;
  display: grid;
  place-items: center;
  border-radius: 7px;
  color: inherit;
  background: rgba(255, 255, 255, 0.2);
  font-size: 12px;
}

.mode-segment button.active span {
  color: #fff;
  background: var(--accent);
}

.mode-segment strong {
  font-size: 12px;
}

.tab {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 38px;
  padding: 0 13px;
  border-radius: 7px;
  color: var(--muted);
  background: transparent;
  white-space: nowrap;
}

.tab-icon {
  width: 22px;
  height: 22px;
  display: grid;
  place-items: center;
  border-radius: 7px;
  color: var(--accent-strong);
  background: #dcefeb;
  font-size: 12px;
  font-weight: 900;
}

.tab.active {
  color: var(--ink);
  background: #fff;
  box-shadow: 0 1px 4px rgba(29, 37, 44, 0.08);
}

.main {
  width: min(1440px, 100%);
  margin: 0 auto;
  padding: 24px clamp(16px, 4vw, 36px) 118px;
}

.view {
  display: none;
}

.view.active {
  display: block;
}

.shop-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 22px;
  align-items: start;
}

.customer-page,
.mine-page {
  padding-bottom: 12px;
}

.hero {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 280px;
  gap: 22px;
  align-items: stretch;
  margin-bottom: 22px;
  padding: 18px 22px;
  min-height: 168px;
  border-radius: 8px;
  color: #fff;
  background:
    linear-gradient(105deg, rgba(17, 82, 78, 0.94), rgba(17, 82, 78, 0.68)),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='900' height='460' viewBox='0 0 900 460'%3E%3Crect fill='%23e7f0ed' width='900' height='460'/%3E%3Ccircle cx='678' cy='224' r='145' fill='%23f7d9ba'/%3E%3Ccircle cx='678' cy='224' r='118' fill='%23fff6e7'/%3E%3Cellipse cx='662' cy='222' rx='76' ry='32' fill='%23c54f2e'/%3E%3Cellipse cx='704' cy='190' rx='44' ry='22' fill='%23f6b95b'/%3E%3Cellipse cx='616' cy='181' rx='38' ry='18' fill='%230b7a75'/%3E%3Crect x='110' y='302' width='280' height='38' rx='19' fill='%23b7791f' opacity='.62'/%3E%3Crect x='95' y='254' width='320' height='62' rx='31' fill='%23fff' opacity='.82'/%3E%3Cpath d='M139 276h236' stroke='%23c54f2e' stroke-width='12' stroke-linecap='round'/%3E%3Cpath d='M153 294h198' stroke='%230b7a75' stroke-width='10' stroke-linecap='round'/%3E%3C/svg%3E");
  background-size: cover;
  background-position: center;
  overflow: hidden;
}

.hero-mode-switch {
  position: absolute;
  top: 48px;
  right: 16px;
  z-index: 2;
}

.hero-mode-switch .mode-switch {
  min-height: 40px;
  border-color: rgba(255, 255, 255, 0.5);
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 12px 28px rgba(11, 42, 39, 0.24);
}

.hero-mode-switch .mode-switch.enterprise {
  background: #fff7df;
  border-color: rgba(246, 185, 91, 0.95);
}

.hero h2 {
  margin: 0 0 10px;
  font-size: clamp(28px, 4vw, 52px);
  line-height: 1.02;
}

.hero p {
  max-width: 620px;
  margin: 0;
  color: rgba(255, 255, 255, 0.88);
  font-size: 16px;
  line-height: 1.65;
}

.hero-address {
  margin-top: 8px !important;
  font-size: 13px !important;
  color: rgba(255, 255, 255, 0.95) !important;
}

.hero-tools {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-top: 12px;
}

.hero-tools .share-row {
  margin-top: 0;
}

.support-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 34px;
  padding: 0 12px;
  border: 1px solid rgba(255, 255, 255, 0.38);
  border-radius: 999px;
  color: #fff;
  background: rgba(255, 255, 255, 0.16);
  font-size: 13px;
  font-weight: 800;
  cursor: pointer;
}

.support-chip span {
  display: inline-grid;
  place-items: center;
  width: 20px;
  height: 20px;
  border-radius: 999px;
  color: #0f766e;
  background: #fff;
}

.support-panel {
  display: grid;
  gap: 8px;
  max-width: 420px;
  margin-top: 10px;
  padding: 10px;
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.94);
  color: var(--ink);
}

.support-chat,
.support-thread-list {
  display: grid;
  gap: 8px;
}

.support-compose,
.support-history {
  display: grid;
  gap: 8px;
}

.support-history {
  padding-top: 8px;
  border-top: 1px solid var(--line);
}

.support-history > strong {
  font-size: 12px;
}

.support-thread {
  display: grid;
  gap: 8px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.support-thread-head,
.support-reply-row {
  display: grid;
  gap: 8px;
  align-items: center;
}

.support-thread-head {
  grid-template-columns: minmax(120px, 0.8fr) minmax(0, 1fr) auto auto;
  width: 100%;
  padding: 0;
  color: var(--ink);
  text-align: left;
  background: transparent;
}

.support-reply-row {
  grid-template-columns: minmax(0, 1fr) auto auto;
}

.login-modal {
  max-width: 460px;
}

.login-code-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
}

.support-thread-head em {
  overflow: hidden;
  color: var(--muted);
  font-style: normal;
  font-size: 12px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.support-thread-head span {
  padding: 3px 7px;
  border-radius: 999px;
  color: #075985;
  background: #e0f2fe;
  font-size: 11px;
  font-weight: 800;
}

.support-thread-head b {
  color: var(--muted);
}

.chat-line {
  display: grid;
  gap: 2px;
  max-width: 88%;
  padding: 7px 9px;
  border-radius: 8px;
  font-size: 12px;
  line-height: 1.35;
}

.chat-line.customer {
  justify-self: start;
  background: #f4f7f7;
}

.chat-line.staff {
  justify-self: end;
  color: #064e3b;
  background: #dcfce7;
}

.chat-line strong {
  font-size: 11px;
}

.support-panel .field label {
  color: var(--muted);
}

.support-actions {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px;
}

.hero-stats {
  align-self: end;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.admin-hero-actions {
  position: absolute;
  top: 18px;
  right: 18px;
  display: flex;
  gap: 8px;
}

.admin-hero-actions button {
  min-width: 92px;
  min-height: 48px;
  padding: 8px 10px;
  border: 1px solid rgba(255, 255, 255, 0.42);
  border-radius: 8px;
  color: #fff;
  background: rgba(255, 255, 255, 0.16);
  text-align: left;
}

.admin-hero-actions strong,
.admin-hero-actions span {
  display: block;
}

.admin-hero-actions strong {
  font-size: 18px;
}

.admin-hero-actions span {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.86);
}

.stat {
  padding: 14px;
  border: 1px solid rgba(255, 255, 255, 0.24);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.13);
}

.stat strong {
  display: block;
  font-size: 20px;
}

.hours-stat strong {
  display: grid;
  gap: 2px;
  font-size: 13px;
  line-height: 1.2;
}

.hours-stat strong span {
  display: block;
  color: #fff;
  font-size: 13px;
  white-space: nowrap;
}

.stat span {
  color: rgba(255, 255, 255, 0.78);
  font-size: 12px;
}

.share-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  margin-top: 10px;
}

.share-mark,
.share-btn {
  width: 30px;
  height: 30px;
  display: inline-grid;
  place-items: center;
  border: 1px solid rgba(11, 122, 117, 0.18);
  border-radius: 7px;
  color: var(--accent-strong);
  background: #eef8f6;
}

.share-mark {
  color: var(--warm);
  background: #fff7ef;
}

.share-btn svg,
.share-mark svg {
  width: 17px;
  height: 17px;
}

.hero .share-btn,
.hero .share-mark {
  border-color: rgba(255, 255, 255, 0.3);
  color: #fff;
  background: rgba(255, 255, 255, 0.16);
}

.cart-share {
  margin-bottom: 10px;
}

.toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 16px;
}

.order-menu {
  display: grid;
  grid-template-columns: 128px minmax(0, 1fr);
  gap: 14px;
  align-items: start;
}

.category-rail {
  position: sticky;
  top: 82px;
  display: grid;
  max-height: calc(100vh - 110px);
  overflow: auto;
  border-radius: 8px;
  background: #eef3f4;
}

.category-tab {
  min-height: 54px;
  padding: 8px 10px;
  border-left: 3px solid transparent;
  color: var(--muted);
  text-align: center;
  background: transparent;
  font-size: 14px;
  line-height: 1.25;
}

.category-tab.active {
  border-left-color: var(--accent);
  color: var(--ink);
  background: #fff;
  font-weight: 800;
}

.menu-list-wrap {
  min-width: 0;
}

.promo-bar,
.member-panel,
.compact-panel {
  margin: 0 0 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  overflow: hidden;
}

.promo-summary,
.member-row,
.compact-title {
  width: 100%;
  min-height: 46px;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 12px;
  text-align: left;
  background: #fff;
}

.promo-summary span:first-child {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.2;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.compact-title span:first-child {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  color: var(--muted);
  font-size: 12px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.compact-title strong {
  margin-right: 8px;
  color: var(--accent-strong);
}

.groupbuy-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(180px, 1fr));
  gap: 8px;
  padding: 10px;
  border-top: 1px solid var(--line);
  background: #f8fbfb;
}

.groupbuy-card {
  min-height: 58px;
  padding: 9px 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  text-align: left;
  background: #fff;
}

.groupbuy-card.active {
  border-color: var(--accent);
  background: #e8f5f3;
}

.groupbuy-card strong,
.groupbuy-card span {
  display: block;
}

.groupbuy-card strong {
  font-size: 13px;
}

.groupbuy-card span {
  margin-top: 3px;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.3;
}

.split-intro .groupbuy-list,
.catering-panel {
  background: #fff;
}

.catering-head {
  display: grid;
  gap: 6px;
  padding: 14px;
  border-bottom: 1px solid var(--line);
}

.catering-head strong {
  color: var(--ink);
  font-size: 16px;
}

.catering-head span {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.5;
}

.catering-form {
  padding: 12px;
}

.catering-recent {
  padding: 10px 12px 12px;
}

.readonly-fee {
  color: #6b7280;
  background: #f3f4f6;
  cursor: not-allowed;
}

.member-admin-grid {
  display: grid;
  gap: 12px;
}

.member-admin-card {
  display: grid;
  gap: 10px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.member-admin-summary {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr) auto;
  gap: 10px;
  align-items: center;
  width: 100%;
  padding: 8px;
  color: var(--ink);
  text-align: left;
  background: #f8faf9;
}

.member-admin-summary strong,
.member-admin-summary em {
  display: block;
}

.member-admin-summary em {
  overflow: hidden;
  color: var(--muted);
  font-style: normal;
  font-size: 12px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.member-admin-form {
  padding: 0;
}

.enterprise-min {
  padding: 7px 9px;
  border-radius: 8px;
}

.enterprise-min.warn {
  border: 1px solid #fecaca;
  color: #991b1b;
  background: #fff1f2;
}

.enterprise-min.ok {
  border: 1px solid #a7f3d0;
  color: #065f46;
  background: #ecfdf5;
}

.group-progress {
  display: grid;
  gap: 6px;
  margin-top: 8px;
  padding: 9px;
  border-radius: 8px;
  background: #f8fbfb;
}

.group-progress-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  color: var(--muted);
  font-size: 12px;
}

.group-progress-head strong {
  color: var(--accent-strong);
}

.progress-track {
  height: 9px;
  overflow: hidden;
  border-radius: 999px;
  background: #dfe6ea;
}

.progress-track span {
  height: 100%;
  display: block;
  border-radius: inherit;
  background: linear-gradient(90deg, #18c5c3, #0b7a75);
  transition: width 0.25s ease;
}

.group-progress.complete .progress-track {
  box-shadow: 0 0 16px rgba(24, 197, 195, 0.55);
}

.group-progress.complete .progress-track span {
  background: linear-gradient(90deg, #18c5c3, #f6b95b, #e54848, #18c5c3);
}

.group-progress em {
  color: var(--muted);
  font-style: normal;
  font-size: 12px;
}

.line-status {
  display: inline-block;
  margin-left: 6px;
  padding: 2px 6px;
  border-radius: 999px;
  color: var(--accent-strong);
  background: #e8f5f3;
  font-size: 11px;
  font-weight: 800;
}

.line-status.pending {
  border: 1px solid #93c5fd;
  color: #075985;
  background: #e0f2fe;
}

.line-status.success {
  border: 1px solid #86efac;
  color: #166534;
  background: #dcfce7;
}

.history-list {
  display: grid;
  gap: 12px;
  padding: 10px;
  border-top: 1px solid var(--line);
  background: #f8fbfb;
}

.history-group {
  display: grid;
  gap: 8px;
}

.history-group h3 {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
}

.history-card {
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.history-head,
.history-item,
.history-actions {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
}

.history-head strong,
.history-head span,
.history-item strong,
.history-item span {
  display: block;
}

.history-head span,
.history-item span {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.4;
}

.history-items {
  display: grid;
  gap: 8px;
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid var(--line);
}

.history-item {
  flex-wrap: wrap;
}

.history-item > div {
  flex: 1;
  min-width: 180px;
}

.history-actions {
  justify-content: flex-start;
  margin-top: 10px;
}

.inline-form {
  flex: 1 0 100%;
  margin-top: 8px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--soft);
}

.compact-empty {
  padding: 14px 10px;
}

.promo-summary strong {
  margin-right: 8px;
  color: var(--warm);
}

.chevron {
  width: 26px;
  height: 26px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  border-radius: 7px;
  color: var(--accent-strong);
  background: #e8f5f3;
  font-weight: 900;
}

.promo-menu {
  display: grid;
  grid-template-columns: repeat(2, minmax(180px, 1fr));
  gap: 8px;
  padding: 10px;
  border-top: 1px solid var(--line);
  background: #fff8f1;
}

.promo-option {
  min-height: 48px;
  padding: 9px 10px;
  border: 1px solid #f1c9aa;
  border-radius: 8px;
  text-align: left;
  background: #fff;
}

.promo-option strong,
.promo-option span {
  display: block;
}

.promo-option strong {
  color: var(--warm);
  font-size: 13px;
}

.promo-option span {
  margin-top: 3px;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.25;
}

.member-avatar {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  border-radius: 8px;
  color: #fff;
  background: var(--warm);
  font-weight: 900;
  overflow: hidden;
}

.member-avatar.large {
  width: 64px;
  height: 64px;
  border-radius: 18px;
  font-size: 28px;
}

.member-avatar img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.member-fixed,
.member-live {
  display: flex;
  align-items: center;
  gap: 9px;
  min-width: 0;
}

.member-fixed {
  flex: 1;
}

.member-live {
  flex: 0 0 auto;
}

.member-fixed strong,
.member-live strong {
  color: var(--ink);
  font-size: 13px;
  white-space: nowrap;
}

.member-fixed span,
.member-live span {
  min-width: 0;
  color: var(--muted);
  font-size: 12px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.member-editor {
  padding: 10px 12px 12px;
  border-top: 1px solid var(--line);
  background: var(--soft);
}

.review-editor {
  padding: 10px 12px 12px;
  border-top: 1px solid var(--line);
  background: var(--soft);
}

.reward-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
}

.reward-chip {
  min-height: 32px;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--accent-strong);
  background: #fff;
  font-size: 12px;
  font-weight: 700;
}

.member-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-start;
  margin-top: 10px;
}

.mine-page {
  display: grid;
  gap: 14px;
  margin-top: -24px;
  margin-right: calc(0px - clamp(16px, 4vw, 36px));
  margin-left: calc(0px - clamp(16px, 4vw, 36px));
  background: #f3f4f5;
}

.mine-hero {
  position: relative;
  display: grid;
  gap: 14px;
  padding: 26px clamp(16px, 4vw, 36px) 18px;
  color: #fff;
  background:
    linear-gradient(135deg, rgba(19, 25, 32, 0.96), rgba(43, 47, 52, 0.92)),
    radial-gradient(circle at 18% 0%, rgba(246, 185, 91, 0.22), transparent 34%);
}

.mine-profile-trigger {
  display: inline-flex;
  align-items: center;
  justify-self: start;
  gap: 13px;
  color: #fff;
  text-align: left;
}

.mine-profile-trigger button {
  padding: 0;
  color: #fff;
  text-align: left;
  background: transparent;
}

.avatar-upload-trigger {
  position: relative;
  display: inline-grid;
  cursor: pointer;
}

.avatar-upload-trigger input {
  position: absolute;
  inset: 0;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.mine-profile-trigger strong,
.mine-profile-trigger em {
  display: block;
}

.mine-profile-trigger strong {
  font-size: 25px;
  line-height: 1.15;
}

.mine-profile-trigger em {
  margin-top: 4px;
  color: rgba(255, 255, 255, 0.78);
  font-style: normal;
  font-size: 14px;
}

.mine-icons {
  position: absolute;
  right: clamp(16px, 4vw, 36px);
  top: 28px;
  display: flex;
  gap: 10px;
}

.mine-icons button {
  display: inline-grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border-radius: 999px;
  color: #fff;
  background: rgba(255, 255, 255, 0.12);
  font-weight: 900;
}

.mine-icons svg {
  width: 20px;
  height: 20px;
}

.settings-panel {
  position: absolute;
  top: 72px;
  right: clamp(16px, 4vw, 36px);
  z-index: 5;
  display: grid;
  gap: 8px;
  width: min(320px, calc(100vw - 32px));
  padding: 12px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 8px;
  color: var(--ink);
  background: #fff;
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.22);
}

.settings-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  width: 100%;
  padding: 9px;
  border-radius: 8px;
  color: var(--ink);
  text-align: left;
  background: #f8faf9;
}

.settings-row strong,
.settings-row em {
  display: block;
}

.settings-row em {
  margin-top: 2px;
  color: var(--muted);
  font-style: normal;
  font-size: 12px;
}

.danger-link {
  width: 100%;
  padding: 10px;
  border-radius: 8px;
  color: #b91c1c;
  background: #fee2e2;
  font-weight: 900;
}

.vip-strip {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 6px;
}

.vip-strip strong {
  margin-right: 6px;
  font-size: 26px;
  font-style: italic;
}

.vip-strip .secondary {
  color: #18323b;
  background: #f2f8fb;
  border-radius: 999px;
}

.vip-perks {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  overflow-x: auto;
}

.vip-perks div {
  min-height: 86px;
  padding: 12px;
  border: 1px solid rgba(255, 255, 255, 0.24);
  border-radius: 8px;
  background: rgba(12, 24, 35, 0.62);
}

.vip-perks strong,
.vip-perks span {
  display: block;
}

.vip-perks strong {
  font-size: 16px;
}

.vip-perks span {
  margin-top: 8px;
  color: rgba(255, 255, 255, 0.72);
  font-size: 12px;
  line-height: 1.35;
}

.mine-card {
  margin: 0 clamp(16px, 4vw, 36px);
  padding: 16px;
  border-radius: 8px;
  background: #fff;
}

.mine-card h2 {
  margin: 0 0 14px;
  font-size: 20px;
}

.card-title-line {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.card-title-line h2 {
  margin-bottom: 0;
}

.card-title-line span {
  color: var(--muted);
}

.wallet-actions {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin-top: 14px;
}

.wallet-actions button {
  min-height: 48px;
  border-radius: 8px;
  background: #f2f2f3;
  font-size: 19px;
  font-weight: 800;
}

.wallet-actions span {
  margin-left: 4px;
  padding: 1px 5px;
  border-radius: 8px;
  color: #fff;
  background: #ff3b1f;
  font-size: 12px;
}

.asset-grid,
.benefit-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px 12px;
}

.benefit-grid.four {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.asset-item {
  min-width: 0;
}

.asset-item span,
.mine-tool span {
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  border-radius: 9px;
  color: #fff;
  background: #18c5c3;
  font-weight: 900;
}

.asset-item strong,
.asset-item em {
  display: block;
}

.asset-item strong {
  margin-top: 6px;
  font-size: 15px;
}

.asset-item em {
  margin-top: 4px;
  color: var(--muted);
  font-style: normal;
  font-size: 13px;
}

.favorite-strip {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr)) auto;
  gap: 10px;
  align-items: center;
}

.favorite-thumb {
  aspect-ratio: 1.55 / 1;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: var(--soft);
  overflow: hidden;
}

.favorite-thumb img,
.favorite-thumb svg {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.mine-tool {
  position: relative;
  min-height: 72px;
  display: grid;
  justify-items: center;
  align-content: center;
  gap: 8px;
  text-align: center;
  background: transparent;
}

.mine-tool em {
  position: absolute;
  top: 0;
  padding: 2px 7px;
  border-radius: 999px;
  color: #fff;
  background: #ff3b1f;
  font-style: normal;
  font-size: 11px;
}

.mine-tool strong {
  font-size: 14px;
}

.invite-banners {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-top: 16px;
}

.invite-banners button {
  min-height: 74px;
  padding: 14px;
  border-radius: 8px;
  color: #073b42;
  text-align: left;
  background: #dff7ff;
}

.invite-banners button + button {
  color: #fff;
  background: #18c5c3;
}

.invite-banners strong,
.invite-banners span {
  display: block;
}

.invite-banners strong {
  font-size: 20px;
}

.invite-banners span {
  margin-top: 6px;
  font-size: 15px;
}

.muted-text {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.45;
}

.simple-page-head {
  margin: 0 0 12px;
  padding: 18px 16px;
  border-radius: 8px;
  background: #fff;
}

.simple-page-head h2 {
  margin: 0 0 4px;
}

.simple-page-head p {
  margin: 0;
  color: var(--muted);
}

.customer-bottom-nav {
  position: fixed;
  left: 50%;
  bottom: 0;
  z-index: 45;
  width: min(100%, 1120px);
  transform: translateX(-50%);
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  padding: 8px 10px calc(8px + env(safe-area-inset-bottom));
  border-top: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 -8px 24px rgba(29, 37, 44, 0.08);
}

.customer-bottom-nav button {
  min-height: 52px;
  display: grid;
  justify-items: center;
  gap: 3px;
  color: #8c9399;
  font-size: 12px;
  font-weight: 800;
  background: transparent;
}

.customer-bottom-nav span {
  width: 25px;
  height: 25px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  border: 2px solid currentColor;
  font-size: 12px;
}

.customer-bottom-nav em {
  font-style: normal;
}

.customer-bottom-nav button.active {
  color: #18bfc0;
}

.customer-bottom-nav button.disabled,
.customer-bottom-nav button:disabled {
  color: #cbd5e1;
  cursor: not-allowed;
}

.form-grid.compact {
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
}

.form-grid.compact .field {
  margin-top: 0;
}

.form-grid.time-inline {
  grid-template-columns: minmax(120px, 1.4fr) minmax(80px, 0.8fr) minmax(80px, 0.8fr);
  align-items: end;
  margin-top: 12px;
}

button:disabled {
  cursor: not-allowed;
  opacity: 0.5;
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.chip {
  min-height: 36px;
  padding: 0 13px;
  border: 1px solid var(--line);
  border-radius: 18px;
  color: var(--muted);
  background: #fff;
}

.chip.active {
  border-color: var(--accent);
  color: var(--accent-strong);
  background: #e8f5f3;
}

.search {
  width: min(320px, 100%);
  min-height: 38px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.menu-list {
  display: grid;
  gap: 12px;
  margin-top: 12px;
}

.item-card,
.cart,
.panel,
.order-card,
.form-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  box-shadow: 0 1px 0 rgba(29, 37, 44, 0.03);
}

.item-card {
  display: grid;
  grid-template-columns: 132px minmax(0, 1fr);
  gap: 14px;
  padding: 12px;
  overflow: hidden;
}

.item-art {
  width: 132px;
  height: 132px;
  border-radius: 8px;
  display: grid;
  place-items: center;
  background: var(--art-bg, #e8f5f3);
  overflow: hidden;
}

.item-art.photo-art {
  background: #fff;
}

.item-art svg {
  width: 118px;
  height: 92px;
}

.item-photo {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  object-position: 70% center;
}

.item-body {
  min-width: 0;
  padding: 0;
}

.item-title-row {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 10px;
}

.item-title-row h3 {
  margin: 0;
  font-size: 18px;
  line-height: 1.25;
}

.item-desc {
  min-height: 0;
  margin: 6px 0 8px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.55;
  clear: both;
}

.sales-line {
  margin-top: 6px;
  color: var(--muted);
  font-size: 13px;
}

.item-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: 8px;
}

.price-stack {
  display: flex;
  align-items: baseline;
  gap: 6px;
}

.price-stack strong {
  color: #e54848;
  font-size: 20px;
  font-weight: 900;
}

.price-stack span {
  color: #98a1a9;
  text-decoration: line-through;
  font-size: 13px;
}

.add-circle {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  color: #fff;
  background: #16bfc1;
  font-size: 26px;
  line-height: 1;
}

.spec-btn {
  min-height: 34px;
  padding: 0 12px;
  border-radius: 999px;
  color: #fff;
  background: #16bfc1;
  font-size: 14px;
  font-weight: 800;
}

.spec-btn.is-disabled,
.add-circle.is-disabled {
  min-width: 76px;
  color: #6d747b;
  background: #e6e9ec;
  box-shadow: none;
}

.item-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 9px;
}

.item-tags span {
  min-height: 24px;
  display: inline-flex;
  align-items: center;
  padding: 0 8px;
  border-radius: 7px;
  color: var(--accent-strong);
  background: #e8f5f3;
  font-size: 12px;
  font-weight: 700;
}

.row-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.product-editor-empty {
  margin-top: 12px;
  padding: 12px;
  border: 1px dashed var(--line);
  border-radius: 8px;
  color: var(--muted);
  background: var(--soft);
  font-size: 13px;
}

.product-editor {
  margin-top: 0;
  padding: 0;
  border-top: 0;
  background: #fbfdfc;
  min-height: 0;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
}

.admin-product-modal {
  max-width: 760px;
  width: min(760px, calc(100vw - 24px));
  max-height: min(86vh, 720px);
  align-self: center;
}

.admin-quick-modal {
  max-width: 820px;
}

.admin-product-modal .product-editor {
  background: transparent;
}

.admin-product-modal .panel-title {
  margin-bottom: 12px;
  padding: 0;
}

.admin-product-modal .modal-body {
  max-height: min(70vh, 680px);
  overflow: auto;
}

.admin-editor-scroll {
  min-height: 0;
  overflow: auto;
  padding-right: 4px;
}

.admin-editor-foot {
  position: sticky;
  bottom: 0;
  display: flex;
  justify-content: flex-end;
  padding-top: 10px;
  margin-top: 10px;
  border-top: 1px solid var(--line);
  background: #fff;
}

.admin-editor-foot .primary {
  width: min(220px, 100%);
}

.editor-preview {
  display: grid;
  grid-template-columns: 104px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  margin-bottom: 10px;
}

.editor-preview .item-art {
  width: 104px;
  height: 78px;
  border-radius: 8px;
}

.editor-image-upload {
  position: relative;
  cursor: pointer;
}

.editor-image-upload input {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
}

.editor-image-upload > span {
  position: absolute;
  left: 8px;
  right: 8px;
  bottom: 8px;
  display: block;
  padding: 4px 6px;
  border-radius: 6px;
  color: #fff;
  background: rgba(29, 37, 44, 0.72);
  text-align: center;
  font-size: 11px;
}

.editor-preview span {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
}

.editor-preview .editor-image-upload > span {
  color: #fff;
  font-size: 11px;
}

.editor-form {
  display: grid;
  gap: 8px;
}

.editor-line {
  display: grid;
  gap: 8px;
}

.editor-line.two {
  grid-template-columns: minmax(0, 1fr) minmax(110px, 0.55fr);
}

.editor-line.four {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.compact-product-form {
  align-content: start;
}

.editor-form .field {
  min-width: 0;
  margin-top: 0;
}

.editor-form .field label {
  font-size: 11px;
}

.editor-form .field input,
.editor-form .field select,
.editor-form .field textarea {
  min-height: 34px;
  padding: 7px 8px;
  font-size: 13px;
}

.option-editor {
  margin-top: 12px;
}

.option-library {
  display: grid;
  gap: 8px;
}

.option-picker {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  gap: 8px;
}

.option-pick {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  padding: 9px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  font-size: 12px;
}

.option-pick span {
  display: grid;
  gap: 2px;
  color: var(--muted);
}

.option-pick strong {
  color: var(--ink);
}

.mini-help {
  margin: 8px 0 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}

.panel-title.compact {
  margin-bottom: 8px;
}

.option-edit-card {
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.option-edit-card + .option-edit-card {
  margin-top: 8px;
}

.inline-check {
  min-height: 38px;
  align-items: center;
  margin: 0;
}

.danger-text {
  color: var(--danger);
}

.item-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.primary,
.secondary,
.danger,
.ghost {
  min-height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 0 14px;
  border-radius: 8px;
  font-weight: 700;
}

.primary {
  color: #fff;
  background: var(--accent);
}

.primary:hover {
  background: var(--accent-strong);
}

.secondary {
  color: var(--accent-strong);
  background: #e8f5f3;
}

.danger {
  color: #fff;
  background: var(--danger);
}

.ghost {
  color: var(--muted);
  background: transparent;
}

.cart-launcher {
  position: fixed;
  right: clamp(16px, 4vw, 34px);
  bottom: 92px;
  z-index: 40;
  min-height: 54px;
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 0 16px;
  border-radius: 999px;
  color: #fff;
  background: var(--accent);
  box-shadow: var(--shadow);
  font-weight: 900;
}

.cart-launcher svg {
  width: 23px;
  height: 23px;
}

.cart-launcher strong {
  min-width: 24px;
  height: 24px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  color: var(--accent-strong);
  background: #fff;
  font-size: 13px;
}

.cart-launcher.has-items {
  background: #12a9aa;
}

.cart-backdrop {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: grid;
  justify-items: end;
  background: rgba(29, 37, 44, 0.32);
}

.cart-drawer {
  width: min(430px, 100%);
  height: 100%;
  display: grid;
  grid-template-rows: auto 1fr;
  background: #fff;
  box-shadow: -18px 0 42px rgba(29, 37, 44, 0.18);
  overflow: hidden;
}

.cart-drawer-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 16px;
  border-bottom: 1px solid var(--line);
}

.cart-drawer-head h2 {
  margin: 0;
  font-size: 18px;
}

.cart {
  min-height: 0;
  padding: 16px;
  overflow: auto;
}

.account-box {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
  align-items: center;
  margin-bottom: 14px;
  padding: 12px;
  border-radius: 8px;
  background: #f8fbfb;
  border: 1px solid var(--line);
}

.account-box strong,
.account-box span {
  display: block;
}

.account-box span,
.line-options {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}

.cart h2,
.panel h2,
.form-card h2 {
  margin: 0 0 14px;
  font-size: 20px;
}

.empty {
  padding: 24px 10px;
  color: var(--muted);
  text-align: center;
  border: 1px dashed var(--line);
  border-radius: 8px;
  background: var(--soft);
}

.cart-lines {
  display: grid;
  gap: 10px;
}

.cart-line {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--line);
}

.cart-line strong {
  display: block;
  margin-bottom: 4px;
}

.qty {
  display: inline-grid;
  grid-template-columns: 32px 34px 32px;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
}

.qty button {
  height: 32px;
  background: #fff;
}

.qty span {
  text-align: center;
  color: var(--muted);
}

.field {
  display: grid;
  gap: 6px;
  margin-top: 12px;
}

.field label {
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.field input,
.field select,
.field textarea {
  width: 100%;
  min-height: 38px;
  padding: 9px 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.totals {
  display: grid;
  gap: 8px;
  margin: 14px 0;
}

.total-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: var(--muted);
}

.total-row.final {
  color: var(--ink);
  font-size: 20px;
  font-weight: 800;
}

.total-row.gift strong {
  color: var(--ok);
}

.columns {
  display: grid;
  grid-template-columns: repeat(3, minmax(220px, 1fr));
  gap: 14px;
  align-items: start;
}

.panel {
  padding: 14px;
  min-height: 360px;
}

.panel-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 12px;
}

.count {
  min-width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  color: var(--accent-strong);
  background: #e8f5f3;
  font-weight: 800;
}

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

.order-card {
  padding: 12px;
}

.order-head {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 8px;
}

.order-id {
  font-weight: 900;
}

.badge {
  display: inline-flex;
  align-items: center;
  min-height: 25px;
  padding: 0 9px;
  border-radius: 13px;
  color: #fff;
  background: var(--accent);
  font-size: 12px;
  font-weight: 800;
  white-space: nowrap;
}

.badge.ready {
  background: var(--ok);
}

.order-meta,
.order-items {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.55;
}

.order-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
}

.group-order-board {
  min-height: 0;
  margin-bottom: 16px;
}

.group-board-toggle {
  width: 100%;
  margin: 0;
  padding: 0;
  text-align: left;
  background: transparent;
}

.group-order-board .panel-title {
  align-items: flex-start;
}

.group-order-board .panel-title p {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.45;
}

.group-order-detail {
  display: grid;
  gap: 10px;
  margin-top: 10px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.group-order-detail:not(.complete) {
  border-color: #7dd3fc;
  background: #f8fcff;
}

.group-order-detail.complete {
  border-color: #18c5c3;
  box-shadow: 0 0 0 2px rgba(24, 197, 195, 0.12);
}

.group-detail-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  width: 100%;
  padding: 0;
  border: 0;
  color: inherit;
  text-align: left;
  background: transparent;
}

.group-detail-head:hover strong {
  color: var(--accent-strong);
}

.group-state-badge,
.order-status-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  min-height: 26px;
  padding: 3px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 900;
  white-space: nowrap;
}

.group-state-badge.pending,
.order-status-pill.pending {
  color: #075985;
  background: #dff4ff;
  border: 1px solid #38bdf8;
}

.group-state-badge.success,
.order-status-pill.success {
  color: #047857;
  background: #dcfce7;
  border: 1px solid #34d399;
}

.group-state-badge b {
  color: inherit;
  font-size: 14px;
  line-height: 1;
}

.group-detail-head strong,
.group-detail-head span {
  display: block;
}

.group-detail-head span {
  margin-top: 3px;
  color: var(--muted);
  font-size: 12px;
}

.group-detail-head .group-state-badge {
  display: inline-flex;
  margin-top: 0;
  font-size: 12px;
}

.group-detail-head .group-state-badge.pending {
  color: #075985;
}

.group-detail-head .group-state-badge.success {
  color: #047857;
}

.group-order-lines {
  display: grid;
  gap: 8px;
  padding-top: 8px;
  border-top: 1px solid var(--line);
}

.group-order-line {
  display: grid;
  gap: 3px;
  padding: 8px;
  border-radius: 8px;
  background: var(--soft);
}

.group-order-line-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 4px;
}

.group-order-line strong,
.group-order-line span,
.group-order-line em {
  display: block;
}

.group-order-line span,
.group-order-line em {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.4;
}

.group-order-line em {
  font-style: normal;
}

.admin-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(320px, 0.75fr);
  gap: 18px;
}

.admin-control-grid {
  display: grid;
  gap: 12px;
}

.admin-quick {
  min-height: 38px;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  padding: 8px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.admin-quick span {
  color: var(--muted);
  font-size: 13px;
}

.admin-quick strong {
  margin-right: 3px;
  color: var(--ink);
  font-size: 16px;
}

.admin-module {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  overflow: hidden;
}

.admin-module summary {
  min-height: 52px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 12px;
  cursor: pointer;
  list-style: none;
}

.admin-module summary::-webkit-details-marker {
  display: none;
}

.admin-module summary span {
  display: grid;
  gap: 3px;
}

.admin-module summary strong {
  font-size: 16px;
}

.admin-module summary em {
  color: var(--muted);
  font-style: normal;
  font-size: 12px;
}

.admin-module summary b {
  color: var(--muted);
  font-weight: 800;
  transition: transform 0.2s ease;
}

.admin-module[open] summary b {
  transform: rotate(180deg);
}

.admin-module-body {
  display: grid;
  gap: 10px;
  padding: 0 10px 10px;
  border-top: 1px solid var(--line);
}

.admin-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.admin-full-btn {
  width: 100%;
}

.admin-menu-manager {
  display: grid;
  grid-template-columns: 112px minmax(0, 1fr);
  gap: 12px;
  align-items: start;
}

.admin-category-list {
  display: grid;
  align-content: start;
  gap: 6px;
  position: sticky;
  top: 86px;
}

.admin-list-title {
  padding: 4px 2px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.admin-category-list button {
  min-height: 40px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--muted);
  background: #fff;
  text-align: left;
}

.admin-category-list button.active {
  border-color: var(--accent);
  color: var(--ink);
  background: #e8f5f3;
  font-weight: 800;
}

.admin-category-list span {
  color: var(--muted);
  font-size: 11px;
}

.admin-menu-content {
  min-width: 0;
  display: grid;
  gap: 8px;
}

.admin-menu-content-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  min-height: 34px;
  padding: 0 4px;
}

.admin-menu-content-head strong {
  font-size: 16px;
}

.admin-menu-content-head span {
  color: var(--muted);
  font-size: 12px;
}

.compact-action {
  min-height: 32px;
  padding: 0 12px;
  border-radius: 7px;
  font-size: 12px;
}

.admin-menu-items,
.category-order-editor {
  display: grid;
  gap: 8px;
}

.admin-item-row,
.category-order-row {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.admin-item-row.dragging {
  opacity: 0.52;
}

.drag-handle {
  width: 30px;
  height: 34px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--muted);
  background: var(--soft);
  cursor: grab;
  font-weight: 800;
}

.admin-item-main {
  min-width: 0;
  display: grid;
  gap: 3px;
}

.admin-item-main span,
.admin-item-main em {
  color: var(--muted);
  font-style: normal;
  font-size: 12px;
  line-height: 1.35;
}

.admin-order-history {
  display: grid;
  gap: 8px;
}

.admin-history-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.admin-history-row strong,
.admin-history-row span,
.admin-history-row em {
  display: block;
}

.admin-history-row span,
.admin-history-row em {
  margin-top: 3px;
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  line-height: 1.35;
}

.admin-history-row > div:last-child {
  text-align: right;
  white-space: nowrap;
}

.category-order-row {
  grid-template-columns: minmax(0, 1fr) auto auto;
}

.category-order-row input {
  min-height: 38px;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.icon-btn {
  width: 34px;
  height: 34px;
  display: inline-grid;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--accent-strong);
  background: #fff;
  font-weight: 800;
}

.table {
  width: 100%;
  border-collapse: collapse;
}

.table th,
.table td {
  padding: 11px 8px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}

.table th {
  color: var(--muted);
  font-size: 12px;
}

.form-card {
  padding: 16px;
}

aside .form-card + .form-card {
  margin-top: 14px;
}

.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.full {
  grid-column: 1 / -1;
}

.promo-list {
  display: grid;
  gap: 10px;
  margin-top: 12px;
}

.promo {
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--soft);
}

.toast {
  position: fixed;
  right: 18px;
  bottom: 158px;
  z-index: 90;
  max-width: min(420px, calc(100vw - 36px));
  padding: 13px 15px;
  border-radius: 8px;
  color: #fff;
  background: var(--ink);
  box-shadow: var(--shadow);
  transform: translateY(16px);
  opacity: 0;
  pointer-events: none;
  transition: 0.2s ease;
}

.toast.show {
  transform: translateY(0);
  opacity: 1;
}

.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 70;
  display: grid;
  place-items: end center;
  padding: 12px;
  background: rgba(29, 37, 44, 0.38);
}

.item-modal {
  width: min(560px, 100%);
  max-height: min(760px, calc(100vh - 36px));
  display: grid;
  grid-template-rows: auto 1fr auto;
  border-radius: 8px;
  background: #fff;
  box-shadow: var(--shadow);
  overflow: hidden;
}

.modal-head,
.modal-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 16px;
  border-bottom: 1px solid var(--line);
}

.modal-foot {
  border-top: 1px solid var(--line);
  border-bottom: 0;
}

.modal-head h2 {
  margin: 0 0 4px;
  font-size: 22px;
}

.modal-head p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
}

.modal-body {
  overflow: auto;
  padding: 16px;
}

.option-group {
  margin: 0 0 16px;
  padding: 0;
  border: 0;
}

.option-group legend {
  width: 100%;
  display: flex;
  justify-content: space-between;
  margin-bottom: 8px;
  font-weight: 800;
}

.option-group legend span {
  color: var(--muted);
  font-size: 12px;
}

.option-list {
  display: grid;
  gap: 8px;
}

.option-row {
  min-height: 46px;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 10px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--soft);
}

.option-row strong {
  color: var(--warm);
}

.training-page {
  display: grid;
  gap: 18px;
}

.training-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 22px;
  align-items: end;
  padding: 28px;
  border-radius: 8px;
  color: #fff;
  background:
    linear-gradient(105deg, rgba(22, 68, 62, 0.95), rgba(42, 86, 69, 0.78)),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='1200' height='520' viewBox='0 0 1200 520'%3E%3Crect width='1200' height='520' fill='%23e9f3ef'/%3E%3Crect x='740' y='92' width='270' height='180' rx='18' fill='%23fff6e7'/%3E%3Crect x='770' y='122' width='210' height='18' rx='9' fill='%230b7a75' opacity='.75'/%3E%3Crect x='770' y='160' width='160' height='18' rx='9' fill='%23c54f2e' opacity='.8'/%3E%3Crect x='770' y='198' width='190' height='18' rx='9' fill='%23b7791f' opacity='.75'/%3E%3Ccircle cx='980' cy='362' r='90' fill='%23f8e4d4'/%3E%3Cellipse cx='980' cy='362' rx='60' ry='24' fill='%23c54f2e'/%3E%3Cellipse cx='928' cy='340' rx='34' ry='16' fill='%230b7a75'/%3E%3Crect x='130' y='342' width='330' height='48' rx='24' fill='%23ffffff' opacity='.72'/%3E%3Cpath d='M164 366h250' stroke='%23b7791f' stroke-width='13' stroke-linecap='round'/%3E%3C/svg%3E");
  background-size: cover;
  background-position: center;
}

.training-kicker {
  display: inline-flex;
  margin-bottom: 10px;
  padding: 5px 9px;
  border: 1px solid rgba(255, 255, 255, 0.36);
  border-radius: 999px;
  color: rgba(255, 255, 255, 0.88);
  font-size: 12px;
  font-weight: 800;
}

.training-hero h2 {
  max-width: 760px;
  margin: 0 0 10px;
  font-size: clamp(30px, 4vw, 50px);
  line-height: 1.05;
}

.training-hero p {
  max-width: 720px;
  margin: 0;
  color: rgba(255, 255, 255, 0.88);
  line-height: 1.75;
}

.training-hero-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}

.training-hero-grid div {
  min-height: 92px;
  display: grid;
  place-content: center;
  gap: 4px;
  border: 1px solid rgba(255, 255, 255, 0.26);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.14);
  text-align: center;
}

.training-hero-grid strong {
  font-size: 28px;
}

.training-hero-grid span {
  color: rgba(255, 255, 255, 0.8);
  font-size: 12px;
}

.training-section,
.training-checklist {
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.training-section-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 14px;
}

.training-section-head h2 {
  margin: 0;
  font-size: 22px;
}

.training-section-head p {
  margin: 5px 0 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.45;
}

.training-filters {
  display: grid;
  grid-template-columns: minmax(240px, 360px) 140px;
  gap: 8px;
}

.training-filters.compact {
  grid-template-columns: 180px;
}

.training-filters select {
  min-height: 44px;
  padding: 0 11px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--ink);
  background: #fff;
}

.shift-grid,
.recipe-grid {
  display: grid;
  gap: 12px;
}

.shift-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.shift-card,
.recipe-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fbfb;
}

.shift-card {
  padding: 14px;
}

.shift-card h3,
.recipe-card h3,
.recipe-card h4 {
  margin: 0;
}

.shift-card ul,
.recipe-card ol,
.recipe-card ul {
  margin: 10px 0 0;
  padding-left: 20px;
  color: var(--muted);
  line-height: 1.55;
}

.recipe-card {
  overflow: hidden;
}

.recipe-card-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 42px;
  gap: 12px;
  padding: 16px;
  background: #fff;
}

.recipe-card-head span {
  color: var(--accent-strong);
  font-size: 12px;
  font-weight: 800;
}

.recipe-card-head h3 {
  margin-top: 4px;
  font-size: 22px;
}

.recipe-card-head p {
  margin: 7px 0 0;
  color: var(--muted);
  line-height: 1.5;
}

.video-link {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  color: #fff;
  background: var(--warm);
  font-weight: 900;
  text-decoration: none;
}

.recipe-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 10px 16px;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: #f4f7f7;
}

.recipe-meta span {
  padding: 4px 8px;
  border-radius: 999px;
  color: var(--accent-strong);
  background: #e8f5f3;
  font-size: 12px;
  font-weight: 800;
}

.recipe-columns {
  display: grid;
  grid-template-columns: minmax(260px, 0.9fr) minmax(0, 1.1fr);
  gap: 14px;
  padding: 16px;
}

.recipe-card h4 {
  margin-bottom: 8px;
  color: var(--ink);
  font-size: 14px;
}

.ingredient-list {
  display: grid;
  gap: 6px;
}

.ingredient-list div {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  min-height: 34px;
  padding: 7px 9px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.ingredient-list span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ingredient-list strong {
  color: var(--warm);
}

.table-wrap {
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.training-table {
  min-width: 920px;
  border: 0;
}

.training-table td,
.training-table th {
  vertical-align: top;
}

.training-table td:nth-child(5) {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}

@media (max-width: 1180px) {
  .shop-layout,
  .admin-layout {
    grid-template-columns: 1fr;
  }

  .cart {
    position: static;
  }

  .admin-menu-manager {
    grid-template-columns: 128px minmax(0, 1fr);
  }

  .columns,
  .promo-menu,
  .groupbuy-list {
    grid-template-columns: repeat(2, minmax(220px, 1fr));
  }

  .form-grid.compact {
    grid-template-columns: repeat(2, 1fr);
  }

  .form-grid.time-inline {
    grid-template-columns: minmax(120px, 1.4fr) minmax(80px, 0.8fr) minmax(80px, 0.8fr);
  }

  .training-hero,
  .recipe-columns {
    grid-template-columns: 1fr;
  }

  .shift-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 760px) {
  .topbar {
    align-items: stretch;
    flex-direction: column;
  }

  .tabs {
    overflow-x: auto;
  }

  .tab {
    flex: 0 0 auto;
  }

  .hero {
    grid-template-columns: 1fr;
    padding: 18px;
  }

  .hero-mode-switch {
    top: 54px;
    right: 16px;
  }

  .hero-stats {
    grid-template-columns: 1fr 1fr;
  }

  .training-hero {
    padding: 20px;
  }

  .training-hero-grid,
  .training-filters,
  .training-section-head {
    grid-template-columns: 1fr;
  }

  .training-section-head {
    display: grid;
  }

  .training-filters {
    width: 100%;
  }

  .columns,
  .promo-menu,
  .groupbuy-list,
  .admin-actions,
  .form-grid,
  .form-grid.compact {
    grid-template-columns: 1fr;
  }

  .admin-menu-manager {
    grid-template-columns: 92px minmax(0, 1fr);
    gap: 8px;
  }

  .admin-category-list {
    grid-template-columns: 1fr;
    position: static;
  }

  .admin-category-list button {
    min-height: 38px;
    padding: 7px 8px;
    font-size: 12px;
  }

  .form-grid.time-inline {
    grid-template-columns: minmax(112px, 1.35fr) minmax(72px, 0.8fr) minmax(72px, 0.8fr);
  }

  .member-row {
    align-items: flex-start;
  }

  .member-fixed,
  .member-live {
    align-items: flex-start;
    flex-direction: column;
    gap: 2px;
  }

  .mine-profile-trigger strong {
    font-size: 22px;
  }

  .mine-icons {
    right: 14px;
  }

  .vip-perks {
    grid-template-columns: repeat(3, 160px);
  }

  .asset-grid,
  .benefit-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .benefit-grid.four {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .invite-banners {
    grid-template-columns: 1fr 1fr;
  }

  .mine-tool strong,
  .asset-item strong {
    font-size: 13px;
  }

  .favorite-strip {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .full {
    grid-column: auto;
  }

  .order-menu {
    grid-template-columns: 88px minmax(0, 1fr);
    gap: 10px;
  }

  .category-tab {
    min-height: 48px;
    font-size: 12px;
  }

  .item-card {
    grid-template-columns: 104px minmax(0, 1fr);
    gap: 10px;
    padding: 10px;
  }

  .item-art {
    width: 104px;
    height: 104px;
  }

  .item-title-row h3 {
    font-size: 15px;
  }

  .price-stack strong {
    font-size: 17px;
  }
}

@media (max-width: 480px) {
  .shell {
    max-width: 100vw;
    overflow-x: hidden;
  }

  .topbar {
    padding: 10px 12px;
  }

  .brand-title {
    font-size: 16px;
  }

  .main {
    padding: 10px 8px 96px;
  }

  .hero {
    display: grid;
    grid-template-columns: 1fr;
    gap: 10px;
    min-height: 0;
    margin-bottom: 10px;
    padding: 12px;
    overflow: visible;
  }

  .hero-mode-switch {
    position: static;
    order: 3;
    width: 100%;
  }

  .hero-mode-switch .mode-switch {
    width: 100%;
    min-height: 38px;
    justify-content: center;
    padding: 0 10px;
    box-shadow: none;
  }

  .hero-mode-switch .mode-segment {
    width: 100%;
    min-width: 0;
    box-shadow: none;
  }

  .mode-segment button {
    min-width: 0;
    padding: 0 6px;
  }

  .mode-segment span {
    width: 21px;
    height: 21px;
  }

  .mode-switch span {
    width: 24px;
    height: 24px;
    border-radius: 7px;
  }

  .mode-switch strong {
    font-size: 12px;
  }

  .hero h2 {
    max-width: none;
    margin-bottom: 6px;
    font-size: 22px;
    line-height: 1.15;
  }

  .hero-address {
    max-width: 100%;
    margin-top: 4px !important;
    font-size: 11px !important;
    line-height: 1.35 !important;
  }

  .hero-tools {
    gap: 6px;
    margin-top: 8px;
  }

  .support-chip {
    min-height: 30px;
    padding: 0 9px;
    font-size: 12px;
  }

  .hero-tools .share-row {
    flex: 0 0 auto;
  }

  .share-row {
    flex-wrap: nowrap;
    gap: 4px;
    max-width: 100%;
  }

  .share-mark,
  .share-btn {
    flex: 0 0 28px;
    width: 28px;
    height: 28px;
    padding: 0;
    overflow: hidden;
  }

  .share-btn svg,
  .share-mark svg {
    width: 16px;
    height: 16px;
    display: block;
  }

  .hero-stats {
    grid-template-columns: 1fr 1fr;
    gap: 7px;
    order: 4;
  }

  .stat {
    min-width: 0;
    padding: 9px;
  }

  .stat strong {
    font-size: 14px;
    line-height: 1.2;
  }

  .stat span {
    font-size: 11px;
  }

  .hours-stat strong,
  .hours-stat strong span {
    font-size: 11px;
  }

  .promo-summary,
  .compact-title {
    min-height: 38px;
    padding: 7px 9px;
  }

  .promo-summary span:first-child,
  .compact-title span:first-child {
    font-size: 11px;
  }

  .order-menu {
    grid-template-columns: 56px minmax(0, 1fr);
    gap: 7px;
  }

  .category-rail {
    top: 8px;
    border-radius: 7px;
  }

  .category-tab {
    min-height: 40px;
    padding: 6px 4px;
    border-left-width: 2px;
    font-size: 11px;
    line-height: 1.15;
    word-break: keep-all;
  }

  .search {
    height: 38px;
    padding: 0 10px;
    font-size: 13px;
  }

  .menu-list {
    gap: 8px;
    margin-top: 8px;
  }

  .item-card {
    grid-template-columns: 70px minmax(0, 1fr);
    gap: 8px;
    padding: 8px;
    border-radius: 7px;
  }

  .item-art {
    width: 70px;
    height: 70px;
    border-radius: 7px;
  }

  .item-art svg {
    width: 64px;
    height: 50px;
  }

  .item-title-row h3 {
    display: -webkit-box;
    overflow: hidden;
    font-size: 14px;
    line-height: 1.22;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
  }

  .sales-line {
    margin-top: 3px;
    font-size: 11px;
    line-height: 1.2;
  }

  .item-tags {
    gap: 4px;
    margin-top: 5px;
  }

  .item-tags span {
    min-height: 19px;
    padding: 0 5px;
    border-radius: 6px;
    font-size: 10px;
  }

  .item-desc {
    display: -webkit-box;
    overflow: hidden;
    margin: 5px 0 6px;
    font-size: 11px;
    line-height: 1.35;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
  }

  .item-bottom {
    gap: 6px;
    margin-top: 5px;
  }

  .price-stack {
    min-width: 0;
    gap: 4px;
  }

  .price-stack strong {
    font-size: 16px;
  }

  .price-stack span {
    font-size: 11px;
  }

  .add-circle {
    flex: 0 0 30px;
    width: 30px;
    height: 30px;
    font-size: 22px;
  }

  .spec-btn {
    min-height: 30px;
    padding: 0 9px;
    font-size: 12px;
  }

  .item-body .share-row {
    margin-top: 6px;
    justify-content: flex-start;
  }

  .item-body .share-mark,
  .item-body .share-btn {
    flex-basis: 25px;
    width: 25px;
    height: 25px;
  }

  .item-body .share-btn svg,
  .item-body .share-mark svg {
    width: 14px;
    height: 14px;
  }

  .cart-launcher {
    right: 12px;
    bottom: calc(78px + env(safe-area-inset-bottom));
  }

  .customer-bottom-nav {
    padding: 6px 4px calc(6px + env(safe-area-inset-bottom));
  }

  .customer-bottom-nav button {
    min-height: 48px;
    font-size: 11px;
  }

  .customer-bottom-nav span {
    width: 23px;
    height: 23px;
  }
}

@media (max-width: 380px) {
  .order-menu {
    grid-template-columns: 58px minmax(0, 1fr);
  }

  .category-tab {
    font-size: 10px;
  }

  .item-card {
    grid-template-columns: 74px minmax(0, 1fr);
  }

  .item-art {
    width: 74px;
    height: 74px;
  }
}
