:root {
  --bg-canvas: #F2F3F5;
  --surface-panel: #FFFFFF;
  --ink-primary: #141414;
  --ink-secondary: #5C5C5C;
  --accent-red: #B81D24;
  --metal-trim: #C8CDD2;
  --line-steel: #D6DAE0;
}

* {
  box-sizing: border-box;
  -webkit-tap-highlight-color: transparent;
}

html, body {
  margin: 0;
  padding: 0;
  height: 100%;
  background-color: var(--bg-canvas);
  color: var(--ink-primary);
  font-family: -apple-system, BlinkMacSystemFont, 'PingFang SC', 'Microsoft YaHei', sans-serif;
  font-size: 14px;
  line-height: 1.45;
}

.tabular-num {
  font-variant-numeric: tabular-nums;
}

.hidden {
  display: none !important;
}

.card {
  background-color: var(--surface-panel);
  border: 1px solid var(--line-steel);
  border-radius: 6px;
}

button {
  font-family: inherit;
  cursor: pointer;
}

.btn-primary {
  background-color: var(--accent-red);
  color: #FFFFFF;
  border: 1px solid var(--accent-red);
  border-radius: 6px;
  font-weight: 600;
  padding: 9px 14px;
  font-size: 13px;
}

.btn-dark {
  background-color: var(--ink-primary);
  color: #FFFFFF;
  border: 1px solid var(--ink-primary);
  border-radius: 6px;
  font-weight: 600;
  padding: 9px 14px;
  font-size: 13px;
}

.btn-outline {
  background-color: #FFFFFF;
  color: var(--ink-primary);
  border: 1px solid var(--ink-primary);
  border-radius: 6px;
  font-weight: 500;
  padding: 8px 12px;
  font-size: 13px;
}

.btn-sm {
  padding: 6px 10px;
  font-size: 12px;
}

.tag-steel {
  display: inline-block;
  padding: 2px 7px;
  font-size: 11px;
  color: var(--ink-secondary);
  background-color: #ECEFF3;
  border: 1px solid var(--metal-trim);
  border-radius: 4px;
}

.tag-red {
  display: inline-block;
  padding: 2px 7px;
  font-size: 11px;
  color: var(--accent-red);
  background-color: #FDF2F2;
  border: 1px solid #F0B7BA;
  border-radius: 4px;
  font-weight: 600;
}

/* Desktop Top Bar */
.desktop-topbar {
  height: 54px;
  background-color: #FFFFFF;
  border-bottom: 1px solid var(--line-steel);
  padding: 0 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.topbar-left {
  display: flex;
  align-items: center;
  gap: 10px;
}

.topbar-brand {
  font-size: 16px;
  font-weight: 700;
}

.topbar-badge {
  font-size: 12px;
  color: var(--ink-secondary);
  background: #ECEFF3;
  border: 1px solid var(--metal-trim);
  padding: 2px 8px;
  border-radius: 4px;
}

.topbar-controls {
  display: flex;
  align-items: center;
  gap: 10px;
}

.mode-switch {
  display: inline-flex;
  background: #ECEFF3;
  padding: 3px;
  border-radius: 6px;
  border: 1px solid var(--line-steel);
}

.mode-btn {
  border: none;
  background: transparent;
  padding: 5px 12px;
  font-size: 12px;
  color: var(--ink-secondary);
  border-radius: 4px;
  font-weight: 600;
}

.mode-btn.active {
  background: var(--ink-primary);
  color: #FFFFFF;
}

/* Workspace Layout */
.workspace-shell {
  height: calc(100vh - 54px);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 24px;
  padding: 16px 24px;
  overflow: hidden;
}

/* Phone Simulator Frame (Desktop mode-phone) */
body.mode-phone .app-frame {
  width: 390px;
  height: min(844px, calc(100vh - 86px));
  background: var(--bg-canvas);
  border: 2px solid var(--ink-primary);
  border-radius: 16px;
  box-shadow: 0 12px 32px rgba(20, 20, 20, 0.12);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  flex-shrink: 0;
}

/* Desktop Widescreen Mode */
body.mode-desktop .app-frame {
  width: 100%;
  height: 100%;
  background: var(--bg-canvas);
  border: 1px solid var(--line-steel);
  border-radius: 8px;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

body.mode-desktop .lan-dock,
body.mode-desktop .bottom-tabbar {
  display: none;
}

body.mode-desktop .configurator-split {
  flex-direction: row;
  flex: 1;
  min-height: 0;
}

body.mode-desktop .stage-column {
  flex: 1;
  min-width: 0;
  height: 100%;
  border-right: 1px solid var(--line-steel);
}

body.mode-desktop .stage-row {
  flex: 1;
  min-height: 0;
  height: auto;
}

body.mode-desktop .stage-step-rail {
  width: 148px;
}

body.mode-desktop .stage-viewport {
  flex: 1;
  min-height: 0;
  height: 100%;
}

body.mode-desktop .drawer-column {
  width: 440px;
  flex: none;
  height: 100%;
}

.app-page {
  display: none;
  flex: 1;
  min-height: 0;
  overflow-y: auto;
}

.app-page.active {
  display: flex;
  flex-direction: column;
}

#pageConfigurator.active {
  overflow: hidden;
  background: #FFFFFF;
}

/* Compact Single-Row Header (44px) */
.wizard-topbar {
  height: 44px;
  background: #FFFFFF;
  border-bottom: 1px solid #ECEFF3;
  padding: 0 12px;
  display: flex;
  align-items: center;
  flex-shrink: 0;
}

.wizard-title-row {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.icon-nav-btn {
  width: 30px;
  height: 30px;
  border-radius: 8px;
  border: 1px solid #E5E7EB;
  background: #F7F8FA;
  color: var(--ink-primary);
  font-size: 18px;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.wizard-title-group {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
}

.wizard-title {
  font-size: 17px;
  font-weight: 600;
  color: var(--ink-primary);
  white-space: nowrap;
}

.hud-price-pill {
  border: 1px solid #E5E7EB;
  background: #FDF2F2;
  color: var(--accent-red);
  font-size: 12px;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: 8px;
  white-space: nowrap;
}

.topbar-right-actions {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}

.header-action-btn {
  border: 1px solid #D6DAE0;
  background: #FFFFFF;
  color: var(--ink-primary);
  font-size: 12px;
  font-weight: 500;
  padding: 4px 10px;
  border-radius: 8px;
}

.configurator-split {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-height: 0;
  min-width: 0;
  width: 100%;
}

.stage-column {
  display: flex;
  flex-direction: column;
  flex-shrink: 0;
  min-width: 0;
  width: 100%;
}

/* Floating Gradient Left 4-Dot Stepper + 3D Viewport Row */
.stage-row {
  position: relative;
  display: flex;
  align-items: stretch;
  width: 100%;
  height: 214px;
  background: #F4F5F7;
  border-bottom: 1px solid #ECEFF3;
  flex-shrink: 0;
}

.stage-step-rail {
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 112px;
  z-index: 11;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  padding-left: 10px;
  background: linear-gradient(90deg, rgba(244, 245, 247, 0.94) 0%, rgba(244, 245, 247, 0.72) 55%, rgba(244, 245, 247, 0) 100%);
  -webkit-mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.08) 0%, #000 18%, #000 82%, rgba(0, 0, 0, 0.08) 100%);
  mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.08) 0%, #000 18%, #000 82%, rgba(0, 0, 0, 0.08) 100%);
  pointer-events: none;
  transition: transform 0.22s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.2s ease;
}

.stage-step-rail.hud-evade {
  transform: translateX(-44px);
  opacity: 0;
  pointer-events: none;
}

.kinetic-step-track {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
  pointer-events: none;
}

.kinetic-step-list {
  position: absolute;
  left: 0;
  right: 0;
  top: 50%;
  margin-top: -15px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  transform: translateY(calc(var(--active-idx, 0) * -30px));
  transition: transform 0.52s cubic-bezier(0.22, 1, 0.36, 1);
  pointer-events: none;
}

.stage-step-dot-btn.kinetic-step-item {
  pointer-events: auto;
  width: auto;
  max-width: 100%;
  height: 30px;
  padding: 0 4px 0 0;
  border: none;
  background: transparent;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 0;
  cursor: pointer;
  flex-shrink: 0;
  transform-origin: left center;
  transition: opacity 0.42s cubic-bezier(0.22, 1, 0.36, 1), transform 0.42s cubic-bezier(0.22, 1, 0.36, 1);
}

.stage-step-dot-btn.kinetic-step-item[data-dist="0"] {
  opacity: 1;
  transform: scale(1);
}

.stage-step-dot-btn.kinetic-step-item[data-dist="1"] {
  opacity: 0.34;
  transform: scale(0.93);
}

.stage-step-dot-btn.kinetic-step-item[data-dist="2"] {
  opacity: 0.16;
  transform: scale(0.88);
}

.stage-step-dot-btn.kinetic-step-item[data-dist="3"] {
  opacity: 0.08;
  transform: scale(0.84);
}

.stage-step-dot-btn.kinetic-step-item:hover:not(.active) {
  opacity: 0.72;
}

.kinetic-step-icon {
  width: 0;
  height: 18px;
  margin-right: 0;
  opacity: 0;
  transform: translateX(-8px) scale(0.65);
  overflow: hidden;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  color: var(--step-accent, var(--accent-red));
  transition: width 0.38s cubic-bezier(0.22, 1, 0.36, 1), margin-right 0.38s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.3s ease, transform 0.42s cubic-bezier(0.22, 1, 0.36, 1);
}

.stage-step-dot-btn.kinetic-step-item.active .kinetic-step-icon {
  width: 17px;
  margin-right: 5px;
  opacity: 1;
  transform: translateX(0) scale(1);
}

.kinetic-step-icon svg {
  width: 15px;
  height: 15px;
  display: block;
}

.kinetic-step-label {
  position: relative;
  display: inline-block;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: -0.01em;
  color: #3B4250;
  white-space: nowrap;
  line-height: 1.2;
  transition: font-size 0.38s cubic-bezier(0.22, 1, 0.36, 1), color 0.35s ease, font-weight 0.25s ease;
}

.stage-step-dot-btn.kinetic-step-item.active .kinetic-step-label {
  font-size: 16px;
  font-weight: 800;
  color: #14171F;
  background-image: linear-gradient(108deg, #14171F 0%, #14171F 38%, rgba(255, 255, 255, 0.92) 50%, #14171F 62%, #14171F 100%);
  background-size: 240% 100%;
  background-position: 100% 0;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.stage-step-dot-btn.kinetic-step-item.active.sweep .kinetic-step-label {
  animation: kineticGlassSweep 0.85s cubic-bezier(0.22, 1, 0.36, 1) both;
}

@keyframes kineticGlassSweep {
  0% {
    background-position: 115% 0;
  }
  100% {
    background-position: -35% 0;
  }
}

.kinetic-step-num {
  margin-left: 3px;
  font-size: 9px;
  font-weight: 700;
  color: #8892A0;
  vertical-align: super;
  line-height: 1;
}

.stage-step-dot-btn.kinetic-step-item.done .kinetic-step-num {
  color: var(--accent-red);
}

.stage-step-dot-btn.kinetic-step-item.active .kinetic-step-num {
  color: var(--step-accent, var(--accent-red));
}

.stage-viewport {
  position: relative;
  flex: 1;
  min-width: 0;
  height: 100%;
  background: #F4F5F7;
  overflow: hidden;
}

.three-container {
  width: 100%;
  height: 100%;
  touch-action: none;
}

.stage-pulse-ring {
  position: absolute;
  inset: 0;
  pointer-events: none;
  border: 2px solid rgba(184, 29, 36, 0.55);
  animation: stageRipple 0.55s ease-out forwards;
}

.stage-focus-banner {
  position: absolute;
  top: 10px;
  left: 110px;
  z-index: 12;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  max-width: calc(100% - 190px);
  padding: 5px 10px;
  border-radius: 999px;
  background: rgba(253, 242, 242, 0.94);
  border: 1px solid #F0B7BA;
  color: var(--accent-red);
  font-size: 11px;
  font-weight: 600;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
  backdrop-filter: blur(6px);
}

.stage-focus-banner.hidden {
  display: none;
}

.stage-focus-exit {
  border: 1px solid #F0B7BA;
  background: #FFFFFF;
  color: var(--accent-red);
  font-size: 10px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 999px;
  cursor: pointer;
  flex-shrink: 0;
}

.step-feedback-banner {
  position: absolute;
  top: 10px;
  left: 46px;
  max-width: calc(100% - 196px);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  z-index: 22;
  background: rgba(20, 20, 20, 0.88);
  color: #FFFFFF;
  font-size: 11px;
  font-weight: 600;
  padding: 5px 10px;
  border-radius: 999px;
  border-left: 3px solid var(--accent-red);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.16);
  pointer-events: none;
  animation: feedbackBannerIn 0.28s cubic-bezier(0.22, 1, 0.36, 1);
}

.stage-view-pills {
  position: absolute;
  top: 8px;
  right: 8px;
  z-index: 10;
  display: flex;
  gap: 2px;
  background: rgba(255, 255, 255, 0.92);
  padding: 2px 3px;
  border-radius: 8px;
  border: 1px solid #E2E6EC;
}

.stage-view-pill {
  border: none;
  background: transparent;
  padding: 2px 6px;
  font-size: 10px;
  color: var(--ink-secondary);
  border-radius: 6px;
  font-weight: 500;
}

.stage-view-pill.active {
  background: var(--ink-primary);
  color: #FFFFFF;
  font-weight: 600;
}

.stage-bottom-bar {
  position: absolute;
  left: 8px;
  right: 8px;
  bottom: 6px;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  pointer-events: none;
  transition: transform 0.14s linear, opacity 0.14s linear;
}

.stage-bottom-bar.hud-evade {
  transform: translateY(14px);
  opacity: 0;
  pointer-events: none;
}

.stage-bottom-bar.hud-evade .badge-360,
.stage-bottom-bar.hud-evade .dims-pill,
.stage-bottom-bar.hud-evade .stage-pill-btn,
.stage-bottom-bar.hud-evade .btn-stage-reset {
  pointer-events: none;
}

.badge-360,
.dims-pill,
.stage-pill-btn,
.btn-stage-reset {
  pointer-events: auto;
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid #E2E6EC;
  border-radius: 8px;
  font-size: 11px;
  color: var(--ink-primary);
}

.stage-bottom-actions {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  flex-shrink: 0;
}

.stage-pill-btn {
  padding: 2px 8px;
  font-weight: 600;
  color: var(--ink-primary);
  flex-shrink: 0;
  transition: background-color 0.16s ease, border-color 0.16s ease, color 0.16s ease;
}

.stage-pill-btn.active {
  background: #FDF2F2;
  border-color: var(--accent-red);
  color: var(--accent-red);
}

.badge-360 {
  padding: 2px 7px;
  font-weight: 600;
  color: var(--ink-secondary);
}

.dims-pill {
  padding: 2px 8px;
  font-weight: 500;
  max-width: 60%;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.tag-red-mini {
  background: #FDF2F2;
  color: var(--accent-red);
  padding: 1px 5px;
  border-radius: 4px;
  font-size: 10px;
  font-weight: 600;
}

.btn-stage-reset {
  padding: 2px 8px;
  font-weight: 500;
  color: var(--ink-primary);
  flex-shrink: 0;
  cursor: pointer;
  transition: background-color 0.16s ease, border-color 0.16s ease, color 0.16s ease;
}

.btn-stage-reset.active {
  background: #FDF2F2;
  border-color: #B81D24;
  color: #B81D24;
  font-weight: 600;
}

.stage-reset-wrap {
  position: relative;
  display: inline-flex;
  flex-shrink: 0;
}

@keyframes resetMenuPop {
  from {
    opacity: 0;
    transform: translateY(6px) scale(0.96);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.stage-reset-menu {
  position: absolute;
  bottom: calc(100% + 6px);
  right: 0;
  min-width: 196px;
  padding: 4px;
  border-radius: 10px;
  background: #FFFFFF;
  border: 1px solid #E2E6EC;
  box-shadow: 0 10px 26px rgba(15, 23, 42, 0.14);
  z-index: 45;
  pointer-events: auto;
  animation: resetMenuPop 0.22s cubic-bezier(0.22, 1, 0.36, 1) both;
}

.stage-bottom-bar.hud-evade .stage-reset-menu {
  opacity: 0;
  pointer-events: none;
}

.stage-reset-opt {
  width: 100%;
  padding: 7px 10px;
  border: none;
  border-radius: 7px;
  background: transparent;
  text-align: left;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 2px;
  transition: background-color 0.15s ease;
}

.stage-reset-opt:hover {
  background: #F4F5F7;
}

.stage-reset-opt.danger:hover {
  background: #FDF2F2;
}

.stage-reset-opt-title {
  font-size: 12px;
  font-weight: 600;
  color: #1A1D21;
  line-height: 1.25;
}

.stage-reset-opt.danger .stage-reset-opt-title {
  color: #B81D24;
}

.stage-reset-opt-sub {
  font-size: 10px;
  color: #6B7280;
  line-height: 1.25;
}

.stage-empty {
  position: absolute;
  left: 20px;
  right: 20px;
  top: 40%;
  text-align: center;
  background: rgba(255, 255, 255, 0.94);
  border: 1px solid var(--line-steel);
  padding: 12px;
  border-radius: 8px;
  color: var(--ink-secondary);
  font-size: 12px;
}

.slot-strip-wrap {
  background: #FFFFFF;
  border-bottom: 1px solid #ECEFF3;
  padding: 5px 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  width: 100%;
  min-width: 0;
  overflow: hidden;
}

.slot-head-right {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}

.btn-quick-delete {
  border: 1px solid #F0B7BA;
  background: #FDF2F2;
  color: var(--accent-red);
  font-size: 11px;
  font-weight: 600;
  padding: 3px 9px;
  border-radius: 8px;
}

.btn-quick-delete:disabled {
  opacity: 0.4;
  cursor: default;
}

.item-focus-pills {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  white-space: nowrap;
  padding-bottom: 6px;
  margin-bottom: 8px;
  border-bottom: 1px solid #ECEFF3;
}

.item-focus-pill {
  border: 1px solid #E2E6EC;
  background: #F7F8FA;
  color: var(--ink-secondary);
  font-size: 12px;
  font-weight: 600;
  padding: 5px 11px;
  border-radius: 999px;
  flex-shrink: 0;
}

.item-focus-pill.active {
  background: #141414;
  border-color: #141414;
  color: #FFFFFF;
}

.step-sub-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 8px;
}

.btn-skip-pill {
  border: 1px solid #D1D5DB;
  background: #FFFFFF;
  color: var(--ink-secondary);
  font-size: 11px;
  font-weight: 600;
  padding: 3px 9px;
  border-radius: 999px;
  flex-shrink: 0;
}

.lock-scope-bar {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  margin-bottom: 10px;
}

.side-insert-tag {
  display: inline-block;
  margin-left: 4px;
  font-size: 9px;
  font-weight: 700;
  color: var(--accent-red);
  background: #FDF2F2;
  padding: 0 4px;
  border-radius: 3px;
}

.slot-strip-hint {
  font-size: 10px;
  color: #7A828C;
}

.socket-mini-badge {
  font-size: 10px;
  font-weight: 700;
  color: #0F5132;
  background: #E8F5EE;
  border: 1px solid #BCE3CE;
  padding: 1px 7px;
  border-radius: 999px;
}

.slot-strip-fade-wrap {
  position: relative;
  flex: 1;
  min-width: 0;
  overflow: hidden;
  display: flex;
  align-items: center;
}

.slot-fade {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 24px;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.14s ease;
  z-index: 3;
}

.slot-fade.visible {
  opacity: 1;
}

.slot-fade-left {
  left: 0;
  background: linear-gradient(90deg, #FFFFFF 18%, rgba(255, 255, 255, 0) 100%);
}

.slot-fade-right {
  right: 0;
  background: linear-gradient(270deg, #FFFFFF 18%, rgba(255, 255, 255, 0) 100%);
}

.slot-strip {
  flex: 1;
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 6px;
  overflow-x: auto;
  white-space: nowrap;
  padding: 2px 4px 2px 0;
  user-select: none;
  scrollbar-width: none;
}

.slot-strip::-webkit-scrollbar {
  display: none;
}

.slot-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 9px 4px 5px;
  font-size: 12px;
  font-weight: 500;
  background: #F7F8FA;
  border: 1px solid #E2E6EC;
  border-radius: 8px;
  flex-shrink: 0;
  cursor: grab;
  touch-action: pan-x;
  transition: transform 0.12s ease, border-color 0.12s ease, background-color 0.12s ease;
}

.slot-num-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 18px;
  height: 18px;
  padding: 0 4px;
  border-radius: 5px;
  background: #E6E9EE;
  color: #141414;
  font-size: 11px;
  font-weight: 700;
  line-height: 1;
}

.slot-pill.selected {
  border-color: var(--accent-red);
  background: #FDF2F2;
  color: var(--accent-red);
  font-weight: 600;
}

.slot-pill.selected .slot-num-badge {
  background: var(--accent-red);
  color: #FFFFFF;
}

.slot-pill.nonstd {
  border-style: dashed;
}

.slot-pill.dragging {
  cursor: grabbing;
  transform: translateY(-2px);
  border-color: var(--accent-red);
  background: #FFFFFF;
  color: var(--accent-red);
  box-shadow: 0 3px 10px rgba(20, 20, 20, 0.12);
  z-index: 20;
}

.slot-pill.drop-target {
  border-color: var(--accent-red);
  border-style: dashed;
  background: #FFF5F5;
}

.socket-chip {
  font-size: 10px;
  background: #141414;
  color: #FFD43B;
  padding: 0 4px;
  border-radius: 4px;
  line-height: 15px;
}

/* Elevated Floating Slot Context Card above Footer */
.slot-action-dock {
  margin: 6px 12px 8px;
  padding: 5px 12px 10px;
  background: #FFFFFF;
  border: 1px solid #DDE2E8;
  border-radius: 12px;
  box-shadow: 0 6px 18px rgba(20, 20, 20, 0.08);
  display: flex;
  flex-direction: column;
  gap: 7px;
  flex-shrink: 0;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.slot-action-dock.dock-enter {
  animation: dockPopIn 0.28s cubic-bezier(0.22, 1, 0.36, 1);
}

.slot-action-dock.dock-nudge {
  animation: dockNudge 0.22s ease-out;
}

@keyframes dockPopIn {
  0% {
    opacity: 0;
    transform: translateY(12px) scale(0.985);
    border-color: var(--accent-red);
    box-shadow: 0 8px 22px rgba(184, 29, 36, 0.18);
  }
  65% {
    border-color: #F0B7BA;
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
    border-color: #DDE2E8;
    box-shadow: 0 6px 18px rgba(20, 20, 20, 0.08);
  }
}

@keyframes dockNudge {
  0% {
    transform: scale(0.99);
    border-color: var(--accent-red);
    box-shadow: 0 6px 18px rgba(184, 29, 36, 0.14);
  }
  100% {
    transform: scale(1);
    border-color: #DDE2E8;
    box-shadow: 0 6px 18px rgba(20, 20, 20, 0.08);
  }
}

.dock-grab-zone {
  width: 100%;
  height: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: grab;
  touch-action: none;
}

.dock-grab-bar {
  width: 38px;
  height: 4px;
  border-radius: 999px;
  background: rgba(138, 146, 158, 0.55);
  transition: width 0.2s ease, background-color 0.2s ease;
}

.slot-action-dock.expanded .dock-grab-bar {
  width: 48px;
  background: rgba(110, 118, 130, 0.78);
}

.dock-head-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.dock-target-tag {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 14px;
  font-weight: 600;
  color: var(--ink-primary);
  min-width: 0;
}

.dock-num-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 22px;
  height: 22px;
  padding: 0 6px;
  border-radius: 6px;
  background: var(--ink-primary);
  color: #FFFFFF;
  font-size: 12px;
  font-weight: 700;
  line-height: 1;
  flex-shrink: 0;
}

.dock-target-name {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.dock-actions-row {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: nowrap;
  overflow-x: auto;
  scrollbar-width: none;
}

.dock-actions-row::-webkit-scrollbar {
  display: none;
}

.dock-close-btn {
  width: 26px;
  height: 26px;
  border: 1px solid #E5E7EB;
  border-radius: 7px;
  background: #F7F8FA;
  color: var(--ink-secondary);
  font-size: 12px;
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.ctx-btn {
  flex: 1;
  min-width: 0;
  height: 32px;
  padding: 0 8px;
  font-size: 12px;
  font-weight: 500;
  background: #F4F5F7;
  border: 1px solid #E2E6EC;
  border-radius: 8px;
  color: var(--ink-primary);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  white-space: nowrap;
  flex-shrink: 0;
}

.ctx-btn.active-expand {
  border-color: var(--accent-red);
  background: #FDF2F2;
  color: var(--accent-red);
  font-weight: 700;
}

/* Smooth Expandable Inline Dimension Customization Drawer inside Dock */
.dock-custom-drawer {
  display: grid;
  grid-template-rows: 0fr;
  opacity: 0;
  transition: grid-template-rows 0.24s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.2s ease, margin-top 0.24s ease;
}

.slot-action-dock.expanded .dock-custom-drawer {
  grid-template-rows: 1fr;
  opacity: 1;
  margin-top: 2px;
}

.dock-custom-inner {
  min-height: 0;
  overflow: hidden;
}

.dock-custom-split {
  display: grid;
  grid-template-columns: 112px 1fr;
  gap: 10px;
  padding-top: 9px;
  border-top: 1px solid #ECEFF3;
  align-items: center;
}

.dock-custom-preview {
  background: #F7F8FA;
  border: 1px solid #E5E7EB;
  border-radius: 10px;
  padding: 6px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
}

.dock-custom-std-dims {
  font-size: 10px;
  color: var(--ink-secondary);
  white-space: nowrap;
}

.dock-custom-form {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
}

.dock-custom-hint {
  font-size: 11px;
  color: var(--ink-secondary);
  line-height: 1.3;
}

.dock-dim-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 6px;
}

.dock-dim-field {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.dock-dim-label {
  font-size: 10px;
  color: var(--ink-secondary);
  font-weight: 600;
}

.dock-dim-input {
  width: 100%;
  height: 30px;
  padding: 0 6px;
  border: 1px solid #D6DAE0;
  border-radius: 6px;
  background: #F8F9FB;
  font-size: 12px;
  color: var(--ink-primary);
}

.dock-remark-input {
  width: 100%;
  height: 30px;
  padding: 0 8px;
  border: 1px solid #D6DAE0;
  border-radius: 6px;
  background: #F8F9FB;
  font-size: 12px;
  color: var(--ink-primary);
}

.dock-dim-input:focus,
.dock-remark-input:focus {
  outline: none;
  border-color: var(--accent-red);
  background: #FFFFFF;
}

.dock-custom-btns {
  display: flex;
  gap: 6px;
  justify-content: flex-end;
}

.ctx-btn.accent {
  border-color: #C8CDD2;
  background: #FFFFFF;
  font-weight: 600;
}

.ctx-btn.danger {
  border-color: #F0B7BA;
  background: #FDF2F2;
  color: var(--accent-red);
}

.drawer-column {
  flex: 1;
  min-height: 0;
  min-width: 0;
  display: flex;
  flex-direction: column;
  background: #FFFFFF;
}

.drawer-body {
  flex: 1;
  min-height: 0;
  min-width: 0;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 8px 12px 14px;
}

.step-panel-anim {
  animation: stepSlideIn 0.14s ease-out;
}

.insert-banner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  color: var(--ink-secondary);
  margin-bottom: 6px;
}

.link-red {
  color: var(--accent-red);
  font-weight: 600;
  background: transparent;
  border: none;
  padding: 0;
  font-size: 12px;
}

.cat-pills {
  display: flex;
  gap: 8px;
  margin-bottom: 8px;
  flex-wrap: wrap;
}

.cat-pill {
  padding: 5px 12px;
  font-size: 14px;
  font-weight: 500;
  background: #F7F8FA;
  border: 1px solid #E2E6EC;
  border-radius: 8px;
  color: var(--ink-secondary);
}

.cat-pill.active {
  background: var(--ink-primary);
  border-color: var(--ink-primary);
  color: #FFFFFF;
  font-weight: 600;
}

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

.sku-card {
  min-width: 0;
  min-height: 82px;
  padding: 7px 8px;
  background: #FFFFFF;
  border: 1px solid #E5E7EB;
  border-radius: 10px;
  text-align: left;
  display: flex;
  align-items: center;
  gap: 7px;
  transition: transform 0.12s ease, border-color 0.12s ease, background-color 0.12s ease;
}

.sku-card:active {
  transform: translateY(1px);
  border-color: var(--accent-red);
  background: #FDF2F2;
}

.sku-thumb {
  height: 66px;
  width: auto;
  min-width: 24px;
  max-width: 44px;
  padding: 2px 3px;
  border-radius: 6px;
  background: #F6F7F9;
  border: 1px solid #ECEFF3;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  overflow: hidden;
}

.sku-thumb-img {
  height: 100%;
  width: auto;
  max-width: 100%;
  object-fit: contain;
  display: block;
}

.sku-meta {
  flex: 1;
  min-width: 0;
}

.sku-plus-circle {
  width: 22px;
  height: 22px;
  border-radius: 6px;
  border: 1px solid #D6DAE0;
  color: var(--accent-red);
  font-size: 14px;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  background: #FFFFFF;
}

/* Tool Matching Cards & Accessory Underline Tabs (matching mockup Screen 2 & 3) */
.underline-tabs {
  display: flex;
  border-bottom: 1px solid #ECEFF3;
  margin-bottom: 10px;
  gap: 6px;
}

.underline-tab {
  flex: 1;
  border: none;
  background: transparent;
  padding: 8px 4px;
  font-size: 13px;
  color: var(--ink-secondary);
  border-bottom: 2px solid transparent;
  font-weight: 500;
}

.underline-tab.active {
  color: var(--ink-primary);
  font-weight: 700;
  border-bottom-color: var(--accent-red);
}

.tool-intro-head {
  margin-bottom: 8px;
}

.tool-intro-title {
  font-size: 16px;
  font-weight: 800;
  color: var(--ink-primary);
}

.tool-intro-sub {
  font-size: 12px;
  color: var(--ink-secondary);
  margin-top: 2px;
}

.tool-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.tool-card,
.lock-radio-card {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  background: #FFFFFF;
  border: 1px solid #E5E7EB;
  border-radius: 10px;
  text-align: left;
  transition: border-color 0.13s ease, background-color 0.13s ease, transform 0.13s ease;
}

.tool-card.active,
.lock-radio-card.active {
  border-color: var(--accent-red);
  background: #FDF2F2;
}

.tool-thumb {
  width: 68px;
  height: 48px;
  border-radius: 8px;
  background: #F4F5F7;
  border: 1px solid #E5E7EB;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.tool-info {
  flex: 1;
  min-width: 0;
}

.tool-title-line {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.tool-name {
  font-size: 15px;
  font-weight: 600;
  color: var(--ink-primary);
}

.badge-upgrade {
  font-size: 11px;
  font-weight: 600;
  color: var(--accent-red);
  background: #FDF2F2;
  padding: 1px 6px;
  border-radius: 6px;
}

.tool-sub {
  font-size: 12px;
  color: var(--ink-secondary);
  margin-top: 2px;
}

.radio-check {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  border: 1.5px solid #C8CDD2;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  color: transparent;
  background: #FFFFFF;
  flex-shrink: 0;
  transition: background-color 0.14s ease, border-color 0.14s ease;
}

.tool-card.active .radio-check,
.lock-radio-card.active .radio-check {
  background: var(--accent-red);
  border-color: var(--accent-red);
  color: #FFFFFF;
}

.socket-status-card {
  padding: 9px 11px;
  background: #F4F8F6;
  border: 1px solid #C5E0D0;
  border-radius: 8px;
  margin-bottom: 8px;
}

.socket-status-title {
  font-size: 12px;
  font-weight: 600;
  color: #0F5132;
}

.socket-status-sub {
  font-size: 12px;
  color: #2C5E44;
  margin-top: 2px;
}

/* Sticky Wizard Footer Bar */
.wizard-footer {
  background: #FFFFFF;
  border-top: 1px solid #E5E7EB;
  padding: 6px 12px 8px;
  flex-shrink: 0;
}

.footer-status-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 12px;
  margin-bottom: 6px;
}

.footer-status-text {
  color: var(--ink-primary);
  font-weight: 500;
}

.footer-link-btn {
  border: none;
  background: transparent;
  color: var(--ink-secondary);
  font-size: 12px;
  padding: 0;
}

.footer-cta-row {
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: 8px;
}

.btn-footer-outline {
  height: 44px;
  border: 1px solid #D6DAE0;
  background: #FFFFFF;
  color: var(--ink-primary);
  border-radius: 10px;
  font-size: 14px;
  font-weight: 500;
  transition: background-color 0.12s ease, transform 0.12s ease;
}

.btn-footer-primary {
  height: 44px;
  border: none;
  background: var(--accent-red);
  color: #FFFFFF;
  border-radius: 10px;
  font-size: 15px;
  font-weight: 600;
  transition: transform 0.12s ease, filter 0.12s ease;
}

.btn-footer-primary:active,
.btn-footer-outline:active {
  transform: translateY(1px);
  filter: brightness(0.95);
}

/* Lightweight Transition Keyframes */
@keyframes stepSlideIn {
  from { opacity: 0; transform: translateX(6px); }
  to { opacity: 1; transform: translateX(0); }
}

@keyframes feedbackBannerIn {
  from { opacity: 0; transform: translateY(-4px); }
  to { opacity: 1; transform: translateY(0); }
}

.sku-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.sku-code {
  font-size: 12px;
  font-weight: 600;
}

.sku-cat {
  font-size: 10px;
  color: var(--ink-secondary);
  background: #ECEFF3;
  padding: 1px 5px;
  border-radius: 4px;
}

.sku-name {
  margin-top: 0;
  font-size: 13.5px;
  font-weight: 600;
  line-height: 1.25;
  color: var(--ink-primary);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.sku-dim {
  margin-top: 3px;
  font-size: 11px;
  color: var(--ink-secondary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.app-block {
  padding-bottom: 12px;
  margin-bottom: 12px;
  border-bottom: 1px solid #ECEFF3;
}

.app-title {
  font-size: 13px;
  font-weight: 700;
  margin-bottom: 8px;
}

.app-sub {
  font-size: 11px;
  color: var(--ink-secondary);
}

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

.swatch-item {
  flex: 0 0 calc(50% - 4px);
  box-sizing: border-box;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px;
  border: 1px solid var(--line-steel);
  border-radius: 5px;
  background: #F8F9FB;
  font-size: 12px;
  text-align: left;
}

.mod-item-card {
  padding: 8px 10px;
  margin-bottom: 8px;
  border: 1px solid var(--line-steel);
  border-radius: 5px;
  background: #F8F9FB;
}

.mod-item-head {
  display: flex;
  justify-content: space-between;
  font-size: 12px;
  font-weight: 700;
  margin-bottom: 6px;
}

.mod-tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}

.mod-tag {
  font-size: 11px;
  padding: 2px 7px;
  border-radius: 3px;
  background: #ECEFF3;
  color: var(--ink-primary);
}

.mod-tag.off {
  background: #F5F6F8;
  color: #9AA1A8;
  text-decoration: line-through;
}

.swatch-item.active {
  border-color: var(--accent-red);
  background: #FDF2F2;
  font-weight: 600;
}

.swatch-box {
  width: 18px;
  height: 18px;
  border-radius: 3px;
  border: 1px solid #141414;
  flex-shrink: 0;
}

.policy-note {
  margin-top: 8px;
  padding: 8px 10px;
  background: #F7F8FA;
  border: 1px solid var(--line-steel);
  border-radius: 5px;
  font-size: 11px;
  color: var(--ink-secondary);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
}

.spec-kv {
  display: flex;
  justify-content: space-between;
  padding: 4px 0;
  font-size: 12px;
  color: var(--ink-secondary);
}

.spec-kv .val {
  color: var(--ink-primary);
  font-weight: 600;
}

.switch-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
}

.quote-total-row {
  margin-top: 8px;
  padding-top: 8px;
  border-top: 1px solid var(--line-steel);
  display: flex;
  justify-content: space-between;
  font-weight: 700;
  font-size: 14px;
}

.quote-total-row .total-val {
  color: var(--accent-red);
}

.ns-alert {
  margin-top: 8px;
  padding: 7px 10px;
  background: #FDF2F2;
  border: 1px solid #F0B7BA;
  border-radius: 5px;
  color: var(--accent-red);
  font-size: 12px;
  font-weight: 600;
}

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

.export-grid .full {
  grid-column: span 2;
}

/* Mall Homepage (DS Quiet Precision Style) */
#pageMall {
  padding: 10px 14px calc(32px + env(safe-area-inset-bottom, 0px));
  background: #FFFFFF;
  overflow-x: hidden;
}

#pageMall.active {
  display: block;
}

#pageMallList {
  padding: 0 14px calc(36px + env(safe-area-inset-bottom, 0px));
  background: #FFFFFF;
  overflow-x: hidden;
}

#pageMallList.active {
  display: block;
}

.mall-list-topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  margin: 0 -14px;
  padding: 8px 14px;
  height: 46px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  background: rgba(255, 255, 255, 0.96);
  border-bottom: 1px solid #EEF0F3;
}

.mall-list-stat {
  font-size: 12px;
  color: #5C636E;
  min-width: 44px;
  text-align: right;
}

.mall-list-search {
  margin-top: 10px;
}

.mall-brand-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 4px 0 10px;
}

.mall-brand-left {
  display: flex;
  align-items: center;
  gap: 8px;
}

.mall-brand-logo {
  height: 15px;
  width: auto;
  display: block;
}

.mall-brand-sep {
  width: 1px;
  height: 12px;
  background: #D8DCE3;
}

.mall-brand-wordmark {
  margin: 0;
  font-size: 15px;
  font-weight: 700;
  color: #1A1D21;
  letter-spacing: 0.02em;
}

.mall-manage-link {
  border: none;
  background: transparent;
  padding: 4px 2px;
  font-size: 12px;
  color: #8C939E;
  cursor: pointer;
}

.mall-search-bar {
  height: 36px;
  padding: 0 11px;
  border-radius: 9px;
  background: #F3F4F6;
  display: flex;
  align-items: center;
  gap: 7px;
  margin-bottom: 10px;
}

.mall-search-ico {
  width: 15px;
  height: 15px;
  color: #8C939E;
  flex-shrink: 0;
}

.mall-search-input {
  flex: 1;
  min-width: 0;
  height: 34px;
  border: none;
  background: transparent;
  font-size: 13px;
  color: #1A1D21;
  outline: none;
}

.mall-search-input::placeholder {
  color: #8C939E;
}

.mall-search-clear {
  border: none;
  background: transparent;
  font-size: 16px;
  color: #8C939E;
  cursor: pointer;
  padding: 0 4px;
}

.mall-hero-card {
  position: relative;
  height: 236px;
  flex-shrink: 0;
  border-radius: 10px;
  overflow: hidden;
  background: #EAEDF1;
  border: 1px solid #E6E8EC;
}

.mall-hero-copy {
  position: relative;
  z-index: 2;
  padding: 11px 14px 0;
  pointer-events: none;
}

.mall-hero-title {
  font-size: 17px;
  font-weight: 700;
  color: #1A1D21;
  line-height: 1.2;
}

.mall-hero-rule {
  width: 24px;
  height: 2px;
  margin-top: 5px;
  background: #B81D24;
  border-radius: 2px;
}

.mall-hero-sub {
  margin-top: 5px;
  font-size: 12px;
  color: #5C636E;
}

.mall-hero-3d {
  position: absolute;
  left: 0;
  right: 0;
  top: 44px;
  bottom: 30px;
  width: 100%;
  height: calc(100% - 74px);
  z-index: 1;
  cursor: grab;
}

.mall-hero-3d:active {
  cursor: grabbing;
}

.mall-hero-360-tag {
  position: absolute;
  top: 10px;
  right: 12px;
  z-index: 2;
  padding: 2px 7px;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.82);
  border: 1px solid #DCE0E6;
  font-size: 10px;
  color: #5C636E;
  pointer-events: none;
}

.mall-hero-spec {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 3;
  height: 30px;
  background: rgba(255, 255, 255, 0.94);
  border-top: 1px solid #E6E8EC;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.hero-spec-btn {
  border: none;
  background: transparent;
  height: 30px;
  padding: 0 10px;
  font-size: 11.5px;
  font-weight: 500;
  color: #3D434D;
  cursor: pointer;
}

.hero-spec-btn:hover,
.hero-spec-btn:active {
  color: #B81D24;
  font-weight: 600;
}

.hero-spec-sep {
  color: #CBD1DA;
}

.mall-core-cta-row {
  display: flex;
  gap: 9px;
  margin-top: 10px;
}

.mall-cta-primary {
  flex: 3;
  height: 40px;
  border: none;
  border-radius: 9px;
  background: #B81D24;
  color: #FFFFFF;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
}

.mall-cta-secondary {
  flex: 2;
  height: 40px;
  border-radius: 9px;
  background: #FFFFFF;
  border: 1px solid #D8DCE3;
  color: #1A1D21;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
}

.mall-cat-bar {
  margin-top: 10px;
  padding: 10px 0;
  border-top: 1px solid #EEF0F3;
  border-bottom: 1px solid #EEF0F3;
  display: flex;
  align-items: center;
}

.mall-cat-item {
  flex: 1;
  border: none;
  background: transparent;
  padding: 2px 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  font-size: 12px;
  color: #1A1D21;
  cursor: pointer;
  white-space: nowrap;
}

.mall-cat-item.active {
  color: #B81D24;
  font-weight: 600;
}

.mall-cat-ico {
  width: 15px;
  height: 15px;
  flex-shrink: 0;
}

.mall-cat-sep {
  width: 1px;
  height: 14px;
  background: #EAECEF;
}

.mall-featured-section {
  margin-top: 13px;
}

.mall-sec-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 6px;
}

.mall-sec-title {
  margin: 0;
  font-size: 16px;
  font-weight: 700;
  color: #1A1D21;
}

.mall-sec-more {
  border: none;
  background: transparent;
  font-size: 12px;
  color: #5C636E;
  cursor: pointer;
}

.mall-profile-notice {
  margin-bottom: 8px;
  padding: 7px 10px;
  border-radius: 8px;
  background: #F6F7F9;
  border: 1px solid #E6E8EC;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  font-size: 11px;
  color: #1A1D21;
}

.mall-profile-reset {
  border: none;
  background: transparent;
  font-size: 11px;
  color: #B81D24;
  font-weight: 600;
  cursor: pointer;
  flex-shrink: 0;
}

.mall-u-tabs {
  display: flex;
  align-items: center;
  gap: 20px;
  border-bottom: 1px solid #EEF0F3;
  margin-bottom: 8px;
  overflow-x: auto;
  overscroll-behavior-x: contain;
  scrollbar-width: none;
  white-space: nowrap;
}

.mall-u-tabs::-webkit-scrollbar,
.mall-count-pills::-webkit-scrollbar {
  display: none;
}

.mall-u-tab {
  position: relative;
  border: none;
  background: transparent;
  padding: 6px 1px 8px;
  font-size: 13px;
  color: #5C636E;
  cursor: pointer;
  flex: 0 0 auto;
}

.mall-u-tab.active {
  color: #B81D24;
  font-weight: 600;
}

.mall-u-tab.active::after {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 2px;
  background: #B81D24;
  border-radius: 2px;
}

.mall-count-pills {
  display: flex;
  align-items: center;
  flex-wrap: nowrap;
  gap: 7px;
  overflow-x: auto;
  overscroll-behavior-x: contain;
  touch-action: pan-x;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  padding: 2px 0 10px;
  margin-bottom: 2px;
}

.mall-count-pill {
  flex: 0 0 auto;
  min-height: 32px;
  padding: 5px 12px;
  border-radius: 6px;
  border: 1px solid transparent;
  background: #F3F4F6;
  color: #4B5563;
  font-size: 12px;
  line-height: 1.2;
  white-space: nowrap;
  cursor: pointer;
  transition: background-color 0.14s ease, color 0.14s ease, border-color 0.14s ease;
}

.mall-count-pill.active {
  background: #FDF2F2;
  color: #B81D24;
  border-color: #F5C2C4;
  font-weight: 600;
}

.mall-product-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 9px;
  padding-bottom: 20px;
}

.mall-product-card {
  min-width: 0;
  border-radius: 8px;
  border: 1px solid #E8EAEE;
  background: #FFFFFF;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  cursor: pointer;
  transition: border-color 0.16s ease;
}

.mall-product-card:hover {
  border-color: #D0D5DD;
}

.mall-product-img-box {
  height: 118px;
  background: #F5F6F8;
  padding: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.mall-product-img-box img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}

.mall-product-body {
  padding: 9px 10px 10px;
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
}

.mall-product-title {
  font-size: 14px;
  font-weight: 600;
  color: #1A1D21;
  line-height: 1.35;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.mall-product-sku {
  margin-top: 4px;
  font-size: 12px;
  color: #5C636E;
  line-height: 1.35;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.mall-product-dims {
  margin-top: 2px;
  margin-bottom: 8px;
  font-size: 12px;
  color: #7A828E;
  line-height: 1.3;
  overflow-wrap: anywhere;
}

.mall-product-fit {
  margin-top: 4px;
  margin-bottom: 6px;
  font-size: 11px;
  font-weight: 600;
  color: #B81D24;
}

.mall-product-fit.over {
  color: #8C939E;
  font-weight: 400;
}

.mall-product-foot {
  margin-top: auto;
  padding-top: 7px;
  border-top: 1px solid #F1F3F6;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 12px;
  color: #5C636E;
}

.mall-empty-box {
  grid-column: 1 / -1;
  padding: 32px 14px;
  text-align: center;
  border: 1px solid #E8EAEE;
  border-radius: 8px;
  background: #F9FAFB;
}

.mall-empty-text {
  font-size: 13px;
  color: #5C636E;
  margin-bottom: 12px;
}

/* Independent Recommendations Page & Customer Auth Card (White / Light Grey / Industrial Red) */
@keyframes pageFadeSlideIn {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

#pageRecommendations.active {
  display: flex;
  flex-direction: column;
  background: #F7F8FA;
  animation: pageFadeSlideIn 0.22s ease-out;
}

.rec-topbar {
  height: 46px;
  padding: 0 14px;
  background: #FFFFFF;
  border-bottom: 1px solid #EEF0F3;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-shrink: 0;
}

.rec-modify-link {
  border: none;
  background: transparent;
  color: #B81D24;
  font-size: 13px;
  font-weight: 600;
  padding: 6px 2px;
  cursor: pointer;
}

.rec-scroll {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 12px 14px calc(40px + env(safe-area-inset-bottom, 0px));
}

.rec-summary-card {
  background: #FFFFFF;
  border: 1px solid #E8EAEE;
  border-radius: 10px;
  padding: 12px;
  margin-bottom: 12px;
}

.rec-summary-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 8px;
}

.rec-summary-title {
  font-size: 14px;
  font-weight: 700;
  color: #1A1D21;
}

.rec-size-badge {
  font-size: 11px;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: 4px;
}

.rec-size-badge.fit {
  background: #FDF2F2;
  color: #B81D24;
}

.rec-size-badge.pending {
  background: #F3F4F6;
  color: #4B5563;
}

.rec-summary-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.rec-sum-pill {
  font-size: 12px;
  color: #374151;
  background: #F4F5F7;
  padding: 4px 8px;
  border-radius: 5px;
}

.rec-result-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 13px;
  color: #4B5563;
  margin: 4px 0 10px;
}

.rec-result-meta strong {
  color: #B81D24;
}

.rec-result-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.rec-item-card {
  background: #FFFFFF;
  border: 1px solid #E8EAEE;
  border-radius: 10px;
  padding: 11px;
  cursor: pointer;
}

.rec-item-top {
  display: flex;
  gap: 10px;
  align-items: flex-start;
}

.rec-item-thumb {
  width: 96px;
  height: 76px;
  border-radius: 6px;
  background: #F5F6F8;
  padding: 4px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.rec-item-thumb img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}

.rec-item-info {
  flex: 1;
  min-width: 0;
}

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

.rec-item-title {
  font-size: 14px;
  font-weight: 600;
  color: #1A1D21;
  line-height: 1.35;
}

.rec-item-sku {
  margin-top: 3px;
  font-size: 12px;
  color: #5C636E;
  overflow-wrap: anywhere;
}

.rec-item-dims {
  margin-top: 2px;
  font-size: 12px;
  color: #7A828E;
}

.rec-reasons-box {
  margin-top: 9px;
  padding: 8px 10px;
  background: #F8F9FA;
  border-radius: 6px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.rec-reason-line {
  font-size: 12px;
  color: #374151;
  line-height: 1.4;
}

.rec-item-foot {
  margin-top: 9px;
  padding-top: 8px;
  border-top: 1px solid #F1F3F6;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 12px;
  color: #5C636E;
}

.rec-empty-state {
  background: #FFFFFF;
  border: 1px solid #E8EAEE;
  border-radius: 10px;
  padding: 26px 16px;
  text-align: center;
}

.rec-empty-title {
  font-size: 15px;
  font-weight: 700;
  color: #1A1D21;
  margin-bottom: 8px;
}

.rec-empty-desc {
  font-size: 12px;
  color: #5C636E;
  line-height: 1.6;
  margin-bottom: 16px;
}

.rec-empty-btns {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
}

.rec-footer-actions {
  margin-top: 16px;
  display: flex;
  gap: 8px;
  justify-content: space-between;
}

.rec-footer-actions button {
  flex: 1;
}

.my-auth-card {
  background: #FFFFFF;
  border: 1px solid #E8EAEE;
  border-radius: 10px;
  padding: 12px;
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.my-auth-user {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.my-auth-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: #F3F4F6;
  border: 1px solid #E5E7EB;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  font-weight: 700;
  color: #5C636E;
  overflow: hidden;
  flex-shrink: 0;
}

.my-auth-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.entry-cta-btn.loading {
  opacity: 0.78;
  cursor: wait;
}

.mall-product-price {
  font-size: 13px;
  font-weight: 700;
  color: #B81D24;
}

.preset-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(165px, 1fr));
  gap: 10px;
  padding-bottom: 16px;
}

.preset-card {
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.elevation-box {
  position: relative;
  height: 110px;
  background: #E8EBEF;
  border-bottom: 1px solid var(--line-steel);
  padding: 20px 10px 10px;
  display: flex;
  align-items: flex-end;
}

.elevation-row {
  width: 100%;
  height: 76px;
  display: flex;
  align-items: flex-end;
  gap: 2px;
}

.mini-cab {
  height: 100%;
  border: 1.5px solid #141414;
  position: relative;
}

.mini-cab.corner {
  border-right: 4px solid var(--accent-red);
}

.mini-upper {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 15px;
  border-bottom: 1.5px solid #141414;
}

.mini-countertop {
  position: absolute;
  top: 38px;
  left: 0;
  right: 0;
  height: 5px;
  background: #C8CDD2;
  border-top: 1px solid #141414;
  border-bottom: 1px solid #141414;
}

.elevation-badge {
  position: absolute;
  top: 6px;
  left: 6px;
  background: #141414;
  color: #FFFFFF;
  font-size: 10px;
  padding: 2px 6px;
  border-radius: 3px;
}

.preset-body {
  padding: 10px;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.preset-title {
  font-size: 13px;
  font-weight: 700;
}

.preset-dims {
  margin-top: 3px;
  font-size: 11px;
  color: var(--ink-secondary);
}

.preset-tags {
  margin-top: 6px;
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}

.preset-footer {
  margin-top: auto;
  padding-top: 8px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.preset-price {
  font-size: 13px;
  font-weight: 700;
  color: var(--accent-red);
}

/* Schemes Page */
#pageSchemes {
  padding: 12px;
}

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

.top-bar-actions {
  display: flex;
  gap: 6px;
}

.page-title {
  font-size: 16px;
  font-weight: 700;
}

.page-sub {
  margin-top: 2px;
  font-size: 11px;
  color: var(--ink-secondary);
}

.schemes-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding-bottom: 16px;
}

.scheme-card {
  padding: 12px;
}

.scheme-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 8px;
}

.thumb-row {
  margin-top: 8px;
  display: flex;
  gap: 6px;
  overflow-x: auto;
}

.thumb-img {
  width: 64px;
  height: 64px;
  object-fit: cover;
  border-radius: 4px;
  border: 1px solid var(--line-steel);
}

.thumb-img.rendered {
  border-color: var(--accent-red);
  border-width: 2px;
}

.scheme-actions {
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid #ECEFF3;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

/* Bottom Tabbar */
.bottom-tabbar {
  min-height: 52px;
  padding: 4px 0 env(safe-area-inset-bottom, 0px);
  background: #FFFFFF;
  border-top: 1px solid #EAECEF;
  display: flex;
  flex-shrink: 0;
}

.bottom-tab {
  flex: 1;
  border: none;
  background: transparent;
  font-size: 11px;
  color: #5C5C5C;
  font-weight: 500;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  cursor: pointer;
}

.bottom-tab .tab-ico {
  width: 20px;
  height: 20px;
  display: block;
}

.bottom-tab.active {
  color: #B81D24;
  font-weight: 600;
}

/* LAN Dock */
.lan-dock {
  width: 320px;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  max-height: calc(100vh - 86px);
  overflow-y: auto;
}

.dock-title {
  font-size: 14px;
  font-weight: 700;
}

.dock-sub {
  font-size: 12px;
  color: var(--ink-secondary);
  margin-top: 2px;
}

.qr-box {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 10px;
  background: #FFFFFF;
  border: 1px solid var(--line-steel);
  border-radius: 6px;
  min-height: 200px;
}

.qr-box svg {
  width: 185px;
  height: 185px;
}

.dock-url-row {
  display: flex;
  gap: 6px;
}

.dock-tip {
  font-size: 11px;
  color: var(--ink-secondary);
  background: #F7F8FA;
  border: 1px solid var(--line-steel);
  padding: 8px;
  border-radius: 4px;
}

.dock-divider {
  height: 1px;
  background: #ECEFF3;
}

.quick-nav-btns {
  margin-top: 8px;
  display: flex;
  gap: 6px;
}

.dock-live-summary {
  font-size: 12px;
  color: var(--ink-secondary);
}

/* Forms & Modals */
.form-row {
  margin-bottom: 10px;
}

.form-label {
  display: block;
  font-size: 12px;
  color: var(--ink-secondary);
  margin-bottom: 4px;
}

.form-input {
  width: 100%;
  height: 36px;
  padding: 0 10px;
  border: 1px solid var(--line-steel);
  border-radius: 5px;
  background: #F8F9FB;
  font-size: 13px;
}

.modal-mask {
  position: fixed;
  inset: 0;
  background: rgba(20, 20, 20, 0.58);
  z-index: 300;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
}

.modal-card {
  width: 100%;
  max-width: 520px;
  max-height: 88vh;
  overflow-y: auto;
  padding: 16px;
}

.modal-title {
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 10px;
}

.modal-btns {
  margin-top: 14px;
  display: flex;
  justify-content: flex-end;
  gap: 8px;
}

.poster-preview-img {
  width: 100%;
  border: 1px solid var(--line-steel);
  border-radius: 4px;
}

.toast-box {
  position: fixed;
  bottom: 72px;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(20, 20, 20, 0.9);
  color: #FFFFFF;
  padding: 8px 16px;
  border-radius: 6px;
  font-size: 13px;
  z-index: 400;
}

/* Mobile Responsive Override (< 960px) */
@media (max-width: 959px) {
  .desktop-topbar,
  .lan-dock {
    display: none !important;
  }

  .workspace-shell {
    width: 100%;
    max-width: 100vw;
    height: 100dvh;
    padding: 0;
    overflow: hidden;
  }

  body.mode-phone .app-frame,
  body.mode-desktop .app-frame {
    width: 100%;
    max-width: 100%;
    min-width: 0;
    height: 100dvh;
    border: none;
    border-radius: 0;
    box-shadow: none;
    overflow: hidden;
  }

  body.mode-desktop .configurator-split {
    flex-direction: column;
  }

  body.mode-desktop .drawer-column {
    width: 100%;
  }

  body.mode-desktop .bottom-tabbar {
    display: flex;
  }

  .stage-row {
    height: clamp(190px, 28dvh, 232px);
  }

  .stage-step-rail {
    width: 112px;
  }
}

.reel-card-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-bottom: 10px;
}

.reel-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding: 10px 6px;
  border: 1.5px solid #E2E6EC;
  border-radius: 10px;
  background: #FFFFFF;
  color: var(--ink-primary);
  cursor: pointer;
  transition: border-color 0.16s ease, background-color 0.16s ease, box-shadow 0.16s ease;
}

.reel-card.active {
  border-color: var(--accent-red);
  background: #FFF6F6;
  box-shadow: 0 2px 8px rgba(184, 29, 36, 0.12);
}

.reel-swatch {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  border: 2px solid rgba(20, 20, 20, 0.12);
}

.reel-card-title {
  font-size: 13px;
  font-weight: 700;
}

.reel-card-sub {
  font-size: 11px;
  color: var(--ink-secondary);
}

/* =========================================================
 * Riff 2: Liquid Dropdown Flow Entry Overlay
 * ========================================================= */
.entry-flow-overlay {
  position: absolute;
  inset: 0;
  z-index: 260;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: safe center;
  overflow-y: auto;
  padding: 16px;
  background: rgba(20, 20, 20, 0.45);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  transition: opacity 0.28s ease;
}

.entry-flow-overlay.leaving {
  opacity: 0;
  pointer-events: none;
}

.entry-liquid-card {
  width: 100%;
  max-width: 358px;
  padding: 16px 16px 14px;
  background: #FFFFFF;
  border-radius: 12px;
  border: 1px solid #E6E8EC;
  box-shadow: 0 12px 32px rgba(15, 23, 42, 0.14);
  animation: entryCardEnter 0.52s cubic-bezier(0.22, 1, 0.36, 1) both;
}

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

.inquiry-close-btn {
  width: 28px;
  height: 28px;
  border: none;
  border-radius: 7px;
  background: #F3F4F6;
  color: #5C636E;
  font-size: 18px;
  line-height: 1;
  cursor: pointer;
  flex-shrink: 0;
}

@keyframes entryCardEnter {
  from {
    opacity: 0;
    transform: translateY(14px) scale(0.97);
    filter: blur(6px);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
    filter: blur(0);
  }
}

.entry-form-pane {
  display: grid;
  grid-template-rows: 1fr;
  opacity: 1;
  transition: grid-template-rows 0.46s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.28s ease;
}

.entry-form-pane > .entry-pane-inner {
  min-height: 0;
  overflow: visible;
}

.entry-form-pane.collapsing {
  grid-template-rows: 0fr;
  opacity: 0;
  pointer-events: none;
}

.entry-form-pane.collapsing > .entry-pane-inner {
  overflow: hidden;
}

.entry-header-anim {
  animation: entryBlurTextIn 0.52s cubic-bezier(0.22, 1, 0.36, 1) 0.06s both;
}

@keyframes entryBlurTextIn {
  from {
    opacity: 0;
    transform: translateY(6px);
    filter: blur(5px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
    filter: blur(0);
  }
}

.entry-title {
  margin: 0;
  font-size: 16px;
  font-weight: 700;
  color: #1A1D21;
}

.entry-subtitle {
  margin: 3px 0 0;
  font-size: 12px;
  color: #5C636E;
}

.entry-field-wrap {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-rows: 0fr;
  opacity: 0;
  margin-top: 0;
  transform: translateY(10px);
  filter: blur(4px);
  pointer-events: none;
  transition:
    grid-template-rows 0.46s cubic-bezier(0.22, 1, 0.36, 1),
    opacity 0.34s ease,
    margin-top 0.46s cubic-bezier(0.22, 1, 0.36, 1),
    transform 0.46s cubic-bezier(0.22, 1, 0.36, 1),
    filter 0.34s ease;
}

.entry-field-wrap > .entry-field-inner {
  min-height: 0;
  overflow: hidden;
}

.entry-field-wrap:has(.entry-dd.open),
.entry-field-wrap.dd-active {
  z-index: 60;
}

.entry-field-wrap.revealed {
  grid-template-rows: 1fr;
  opacity: 1;
  margin-top: 12px;
  transform: translateY(0);
  filter: blur(0);
  pointer-events: auto;
}

#entryField1.revealed {
  margin-top: 0;
}

.entry-field-wrap.revealed > .entry-field-inner {
  overflow: visible;
}

.entry-field-label {
  font-size: 12px;
  font-weight: 600;
  color: #1A1D21;
  margin-bottom: 5px;
}

.entry-dd {
  position: relative;
  z-index: 1;
}

.entry-dd.open {
  z-index: 60;
}

.entry-dd-trigger {
  width: 100%;
  height: 38px;
  padding: 0 11px;
  border-radius: 8px;
  border: 1px solid #D8DCE3;
  background: #FFFFFF;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  font-size: 13px;
  color: #1A1D21;
  cursor: pointer;
  transition: border-color 0.22s ease, box-shadow 0.24s ease, background-color 0.2s ease;
}

.entry-dd.open .entry-dd-trigger {
  background: #FFFFFF;
  border-color: #B81D24;
  box-shadow: 0 0 0 3px rgba(184, 29, 36, 0.10);
}

.entry-dd-val {
  font-weight: 500;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.entry-dd-val.placeholder {
  font-weight: 400;
  color: #8C939E;
}

.entry-dd-chevron {
  font-size: 14px;
  color: #8C939E;
  line-height: 1;
  transition: transform 0.32s cubic-bezier(0.22, 1, 0.36, 1), color 0.2s ease;
}

.entry-dd.open .entry-dd-chevron {
  transform: rotate(180deg);
  color: #B81D24;
}

.entry-dd-menu {
  position: absolute;
  left: 0;
  right: 0;
  top: calc(100% + 4px);
  z-index: 70;
  padding: 4px;
  border-radius: 9px;
  background: #FFFFFF;
  border: 1px solid #E6E8EC;
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.14);
  opacity: 0;
  transform: translateY(-6px) scale(0.96);
  filter: blur(3px);
  transform-origin: top center;
  pointer-events: none;
  transition:
    opacity 0.22s ease,
    transform 0.34s cubic-bezier(0.22, 1, 0.36, 1),
    filter 0.24s ease;
}

.entry-dd.open .entry-dd-menu {
  opacity: 1;
  transform: translateY(0) scale(1);
  filter: blur(0);
  pointer-events: auto;
}

.entry-dd-option {
  width: 100%;
  padding: 9px 11px;
  border: none;
  border-radius: 8px;
  background: transparent;
  text-align: left;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 2px;
  transition: background-color 0.16s ease, transform 0.16s ease;
}

.entry-dd-option:active {
  transform: scale(0.985);
}

.entry-dd-option:hover,
.entry-dd-option.selected {
  background: #FDF2F2;
}

.entry-dd-option.selected .entry-dd-opt-title {
  color: #B81D24;
}

.entry-dd-opt-title {
  font-size: 13px;
  font-weight: 600;
  color: #1A1D21;
}

.entry-dd-opt-sub {
  font-size: 11px;
  color: #5C636E;
}

.entry-cta-btn {
  width: 100%;
  height: 40px;
  margin-top: 14px;
  border: none;
  border-radius: 9px;
  background: #E5E7EB;
  color: #8C939E;
  font-size: 13px;
  font-weight: 600;
  cursor: not-allowed;
  transition:
    background-color 0.24s ease,
    color 0.24s ease,
    transform 0.18s cubic-bezier(0.22, 1, 0.36, 1),
    box-shadow 0.24s ease;
}

.entry-cta-btn.ready {
  background: #B81D24;
  color: #FFFFFF;
  cursor: pointer;
  box-shadow: 0 6px 16px rgba(184, 29, 36, 0.22);
}

.entry-cta-btn.ready:hover {
  background: #9E171D;
}

.entry-cta-btn.ready:active {
  transform: scale(0.985);
}

.entry-skip-btn {
  width: 100%;
  margin-top: 8px;
  padding: 6px 10px;
  border: none;
  background: transparent;
  color: #5C636E;
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  transition: color 0.18s ease;
}

.entry-skip-btn:hover {
  color: #1A1D21;
}

.inq-label-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 6px;
}

.inq-unknown-btn {
  padding: 3px 9px;
  border-radius: 6px;
  border: 1px solid #D8DCE3;
  background: #FFFFFF;
  font-size: 11px;
  color: #5C636E;
  cursor: pointer;
}

.inq-unknown-btn.active {
  border-color: #B81D24;
  background: #FDF2F2;
  color: #B81D24;
  font-weight: 600;
}

.inq-unknown-note {
  padding: 9px 10px;
  border-radius: 8px;
  background: #F6F7F9;
  border: 1px solid #E6E8EC;
  font-size: 11px;
  color: #5C636E;
  line-height: 1.4;
}

.entry-success-pane {
  display: grid;
  grid-template-rows: 0fr;
  opacity: 0;
  transition:
    grid-template-rows 0.46s cubic-bezier(0.22, 1, 0.36, 1) 0.12s,
    opacity 0.34s ease 0.16s;
}

.entry-success-pane > .entry-success-inner {
  min-height: 0;
  overflow: hidden;
  text-align: center;
}

.entry-success-pane.active {
  grid-template-rows: 1fr;
  opacity: 1;
}

.entry-check-circle {
  width: 52px;
  height: 52px;
  margin: 4px auto 14px;
  border-radius: 50%;
  background: #4ADE80;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 8px 24px rgba(74, 222, 128, 0.34);
  transform: scale(0.5);
  transition: transform 0.5s cubic-bezier(0.22, 1, 0.36, 1) 0.18s;
}

.entry-success-pane.active .entry-check-circle {
  transform: scale(1);
}

.entry-check-svg {
  width: 30px;
  height: 30px;
}

.entry-check-path {
  fill: none;
  stroke: #FFFFFF;
  stroke-width: 3.4;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-dasharray: 36;
  stroke-dashoffset: 36;
  transition: stroke-dashoffset 0.42s cubic-bezier(0.22, 1, 0.36, 1) 0.36s;
}

.entry-success-pane.active .entry-check-path {
  stroke-dashoffset: 0;
}

.entry-success-title {
  margin: 0;
  font-size: 18px;
  font-weight: 800;
  color: #111827;
}

.entry-success-sub {
  margin: 6px 0 0;
  font-size: 12px;
  color: #6B7280;
}

.intro-splash-stage {
  position: absolute;
  inset: 0;
  z-index: 280;
  background: #0F172A;
  display: flex;
  align-items: center;
  justify-content: center;
}

.entry-size-box {
  padding: 10px;
  border-radius: 13px;
  border: 1px solid #E5E7EB;
  background: #F9FAFB;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.entry-shape-switch {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
  padding: 3px;
  border-radius: 10px;
  background: #EEF2F7;
}

.entry-shape-btn {
  height: 30px;
  border: none;
  border-radius: 8px;
  background: transparent;
  color: #64748B;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  transition: background-color 0.2s ease, color 0.2s ease, box-shadow 0.2s ease;
}

.entry-shape-btn.active {
  background: #FFFFFF;
  color: #B81D24;
  box-shadow: 0 1px 4px rgba(15, 23, 42, 0.08);
}

.entry-lshape-hint {
  padding: 5px 8px;
  border-radius: 7px;
  background: #F3F4F6;
  color: #5C636E;
  font-size: 11px;
  line-height: 1.4;
}

.entry-size-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

.entry-size-label {
  width: 62px;
  font-size: 12px;
  font-weight: 600;
  color: #374151;
  flex-shrink: 0;
}

.entry-size-input {
  flex: 1;
  min-width: 0;
  height: 36px;
  padding: 0 10px;
  border-radius: 9px;
  border: 1px solid #D1D5DB;
  background: #FFFFFF;
  font-size: 13px;
  font-weight: 600;
  color: #111827;
}

.entry-size-input:focus {
  outline: none;
  border-color: #2E8BFF;
  box-shadow: 0 0 0 2px rgba(46, 139, 255, 0.14);
}

.entry-size-unit {
  width: 44px;
  text-align: right;
  font-size: 11px;
  color: #6B7280;
  flex-shrink: 0;
}

.entry-size-quick {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}

.entry-quick-pill {
  padding: 4px 8px;
  border-radius: 999px;
  border: 1px solid #E2E8F0;
  background: #FFFFFF;
  color: #475569;
  font-size: 11px;
  font-weight: 600;
  cursor: pointer;
}

.entry-quick-pill:hover {
  border-color: #2E8BFF;
  color: #2E8BFF;
}

.entry-sub-cta-btn {
  width: 100%;
  margin-top: 8px;
  padding: 8px 10px;
  border-radius: 11px;
  border: 1px solid #E2E8F0;
  background: #F8FAFC;
  color: #334155;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
}

/* Step 1 Space Constraint Banner & Disabled SKU */
.step1-constraint-bar {
  margin-bottom: 8px;
  padding: 7px 10px;
  border-radius: 10px;
  background: #EEF6FF;
  border: 1px solid #BFDBFE;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  font-size: 12px;
  color: #1E3A8A;
}

.btn-remove-constraint {
  padding: 3px 8px;
  border-radius: 999px;
  border: 1px solid #93C5FD;
  background: #FFFFFF;
  color: #1D4ED8;
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
  flex-shrink: 0;
}

.sku-card.constrained-disabled {
  opacity: 0.44;
  background: #F8FAFC;
  border-style: dashed;
}

.sku-constraint-tag {
  display: inline-block;
  margin-top: 2px;
  padding: 1px 5px;
  border-radius: 4px;
  background: #FEE2E2;
  color: #B91C1C;
  font-size: 10px;
  font-weight: 700;
}

/* Step 2 私人定制 Swatch Card & QR Modal */
.swatch-item.private-custom-item {
  border-style: dashed;
  border-color: #B81D24;
  background: linear-gradient(135deg, #FFF7F7 0%, #FFFFFF 100%);
  color: #B81D24;
  font-weight: 700;
}

.swatch-box.prismatic {
  background: conic-gradient(from 45deg, #B81D24, #F59E0B, #06B6D4, #6366F1, #B81D24);
  border-color: rgba(184, 29, 36, 0.35);
}

.qr-longpress-zone {
  margin: 12px auto 8px;
  padding: 14px;
  width: 214px;
  border-radius: 16px;
  border: 2px dashed #CBD5E1;
  background: #F8FAFC;
  text-align: center;
  user-select: none;
  -webkit-user-select: none;
  touch-action: none;
  transition: border-color 0.2s ease, background-color 0.2s ease, transform 0.2s ease;
}

.qr-longpress-zone.pressing {
  border-color: #16A34A;
  background: #F0FDF4;
  transform: scale(0.98);
}

.qr-longpress-svg svg,
.qr-longpress-img {
  width: 170px;
  height: 170px;
  display: block;
  margin: 0 auto;
  border-radius: 8px;
}

.qr-progress-track {
  margin-top: 8px;
  height: 5px;
  border-radius: 999px;
  background: #E2E8F0;
  overflow: hidden;
}

.qr-progress-fill {
  height: 100%;
  width: 0%;
  background: #16A34A;
  transition: width 0.06s linear;
}

/* Waterfall Style Mall */
.waterfall-grid {
  column-count: 2;
  column-gap: 10px;
  padding-bottom: 28px;
}

@media (min-width: 720px) {
  body.mode-desktop .waterfall-grid {
    column-count: 3;
    column-gap: 12px;
  }
}

.waterfall-card {
  break-inside: avoid;
  -webkit-column-break-inside: avoid;
  margin-bottom: 10px;
  border-radius: 14px;
  overflow: hidden;
  background: #FFFFFF;
  border: 1px solid #E5E7EB;
  box-shadow: 0 4px 14px rgba(15, 23, 42, 0.04);
  cursor: pointer;
  transition: transform 0.16s ease, box-shadow 0.16s ease;
}

.waterfall-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.08);
}

.wf-cover {
  position: relative;
  background: #ECEFF3;
  overflow: hidden;
}

.wf-cover img {
  width: 100%;
  display: block;
  object-fit: cover;
}

.wf-media-pill {
  position: absolute;
  left: 7px;
  top: 7px;
  padding: 2px 7px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.72);
  color: #FFFFFF;
  font-size: 10px;
  font-weight: 600;
}

.wf-fit-pill {
  position: absolute;
  right: 7px;
  top: 7px;
  padding: 2px 7px;
  border-radius: 999px;
  font-size: 10px;
  font-weight: 700;
  background: rgba(22, 163, 74, 0.92);
  color: #FFFFFF;
}

.wf-fit-pill.over {
  background: rgba(217, 119, 6, 0.92);
}

.wf-body {
  padding: 9px 10px 10px;
}

.wf-title {
  font-size: 13px;
  font-weight: 700;
  color: #111827;
  line-height: 1.3;
}

.wf-sub {
  margin-top: 3px;
  font-size: 11px;
  color: #6B7280;
  line-height: 1.35;
}

.wf-metrics {
  margin-top: 7px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 11px;
  color: #475569;
}

.wf-customer-line {
  margin-top: 6px;
  padding-top: 6px;
  border-top: 1px dashed #E5E7EB;
  font-size: 11px;
  color: #334155;
  display: flex;
  justify-content: space-between;
  gap: 6px;
}

.wf-quote-snippet {
  margin-top: 5px;
  padding: 5px 7px;
  border-radius: 7px;
  background: #F8FAFC;
  font-size: 11px;
  color: #475569;
  line-height: 1.35;
}

/* E-Commerce Style Detail Modal & Library Manager */
.mall-gallery-tabs {
  display: flex;
  gap: 6px;
  margin-bottom: 8px;
}

.mall-gallery-tab {
  flex: 1;
  padding: 6px 8px;
  border-radius: 8px;
  border: 1px solid #E2E8F0;
  background: #F8FAFC;
  font-size: 12px;
  font-weight: 600;
  color: #475569;
  cursor: pointer;
}

.mall-gallery-tab.active {
  background: #FFFFFF;
  border-color: #B81D24;
  color: #B81D24;
}

.mall-gallery-frame {
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid #E5E7EB;
  background: #F4F5F7;
}

.mall-gallery-frame img {
  width: 100%;
  height: 210px;
  object-fit: contain;
  background: #F4F5F7;
  display: block;
}

.mall-detail-3d-wrap {
  position: relative;
  height: 214px;
  background: #F4F5F7;
}

.mall-detail-3d {
  width: 100%;
  height: 100%;
  cursor: grab;
}

.mall-detail-3d:active {
  cursor: grabbing;
}

.mall-detail-360-tag {
  position: absolute;
  top: 8px;
  left: 8px;
  z-index: 2;
  padding: 2px 7px;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.88);
  border: 1px solid #DCE0E6;
  font-size: 10px;
  color: #5C636E;
  pointer-events: none;
}

.mall-detail-3d-actions {
  position: absolute;
  right: 8px;
  bottom: 8px;
  z-index: 3;
  display: flex;
  align-items: center;
  gap: 6px;
}

.mall-detail-3d-btn {
  height: 26px;
  padding: 0 9px;
  border-radius: 6px;
  border: 1px solid #D8DCE3;
  background: rgba(255, 255, 255, 0.94);
  font-size: 11px;
  font-weight: 600;
  color: #1A1D21;
  cursor: pointer;
}

.mall-detail-3d-btn.active {
  border-color: #B81D24;
  background: #FDF2F2;
  color: #B81D24;
}

.mall-variant-group {
  margin-top: 10px;
}

.mall-variant-label {
  font-size: 12px;
  font-weight: 700;
  color: #374151;
  margin-bottom: 5px;
}

.mall-comment-box {
  margin-top: 10px;
  padding: 8px 10px;
  border-radius: 10px;
  background: #F8FAFC;
  border: 1px solid #E2E8F0;
  max-height: 150px;
  overflow-y: auto;
}

.mall-comment-item {
  padding: 5px 0;
  border-bottom: 1px dashed #E2E8F0;
  font-size: 12px;
}

.mall-comment-item:last-child {
  border-bottom: none;
}

/* =========================================================
   Sales Studio Offline Edition & HD Export Animations
   ========================================================= */
body.edition-sales-studio {
  background: var(--bg-canvas);
}

body.edition-sales-studio .desktop-topbar,
body.edition-sales-studio .lan-dock,
body.edition-sales-studio .sim-only-el,
body.edition-sales-studio .sim-only-tab,
body.edition-sales-studio #entryFlowOverlay {
  display: none !important;
}

body.edition-sales-studio .sales-only-tab,
body.edition-sales-studio .sales-export-pill {
  display: inline-flex !important;
}

body.edition-sales-studio .workspace-shell {
  height: 100vh;
  height: 100dvh;
  padding: 0;
  gap: 0;
}

body.edition-sales-studio .app-frame {
  width: 100% !important;
  max-width: 100% !important;
  height: 100vh !important;
  height: 100dvh !important;
  border: none !important;
  border-radius: 0 !important;
  box-shadow: none !important;
  padding-top: env(safe-area-inset-top);
}

body.edition-sales-studio .bottom-tabbar {
  display: flex !important;
  padding-bottom: env(safe-area-inset-bottom);
}

.sales-export-pill {
  background: #B81D24 !important;
  color: #FFFFFF !important;
  border-color: #B81D24 !important;
  font-weight: 700 !important;
  padding: 5px 12px !important;
}

/* Export Progress & Success Check Animation */
.export-anim-card {
  text-align: center;
  padding: 20px 14px 16px;
}

.export-spinner-ring {
  width: 62px;
  height: 62px;
  margin: 0 auto 14px;
  border-radius: 50%;
  border: 4px solid #E5E7EB;
  border-top-color: #B81D24;
  animation: exportSpin 0.85s linear infinite;
}

@keyframes exportSpin {
  to {
    transform: rotate(360deg);
  }
}

.export-progress-track {
  width: 100%;
  height: 8px;
  border-radius: 999px;
  background: #E5E7EB;
  overflow: hidden;
  margin: 12px 0 8px;
}

.export-progress-fill {
  height: 100%;
  width: 10%;
  border-radius: 999px;
  background: linear-gradient(90deg, #B81D24 0%, #E85D12 100%);
  transition: width 240ms ease;
}

.export-success-wrap {
  padding: 18px 10px 14px;
  text-align: center;
}

.export-success-circle {
  width: 72px;
  height: 72px;
  margin: 0 auto 14px;
  border-radius: 50%;
  background: #16A34A;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 0 0 rgba(22, 163, 74, 0.42);
  animation: exportSuccessPop 0.55s cubic-bezier(0.22, 1, 0.36, 1) forwards, exportSuccessPulse 1.1s ease-out 0.15s forwards;
}

@keyframes exportSuccessPop {
  0% { transform: scale(0.4); opacity: 0; }
  70% { transform: scale(1.08); opacity: 1; }
  100% { transform: scale(1); opacity: 1; }
}

@keyframes exportSuccessPulse {
  0% { box-shadow: 0 0 0 0 rgba(22, 163, 74, 0.45); }
  100% { box-shadow: 0 0 0 18px rgba(22, 163, 74, 0); }
}

.export-success-svg {
  width: 40px;
  height: 40px;
  fill: none;
  stroke: #FFFFFF;
  stroke-width: 3.4;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.export-success-path {
  stroke-dasharray: 42;
  stroke-dashoffset: 42;
  animation: exportTickDraw 0.42s ease-out 0.15s forwards;
}

@keyframes exportTickDraw {
  to { stroke-dashoffset: 0; }
}

/* 5-in-1 Sales Output Gallery */
.export-kind-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
  margin: 10px 0 12px;
}

.export-kind-check {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 9px 10px;
  border: 1px solid #E5E7EB;
  border-radius: 8px;
  background: #F9FAFB;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
}

.export-kind-check input {
  accent-color: #B81D24;
  width: 16px;
  height: 16px;
}

.export-tabs {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  padding-bottom: 6px;
  margin-bottom: 8px;
}

.export-tab-btn {
  flex: none;
  padding: 6px 11px;
  border-radius: 999px;
  border: 1px solid #D6DAE0;
  background: #F8FAFC;
  font-size: 12px;
  font-weight: 600;
  color: #374151;
}

.export-tab-btn.active {
  background: #141414;
  border-color: #141414;
  color: #FFFFFF;
}

.export-preview-stage {
  border: 1px solid #E5E7EB;
  border-radius: 10px;
  background: #F4F5F7;
  padding: 6px;
  text-align: center;
}

.export-preview-stage img {
  width: 100%;
  max-height: 46vh;
  object-fit: contain;
  border-radius: 6px;
  display: block;
  margin: 0 auto;
}

/* Asset Manager Page */
.assets-header {
  margin: 10px 12px 8px;
  padding: 12px;
  flex-shrink: 0;
}

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

.assets-subtabs {
  display: flex;
  gap: 6px;
  margin-top: 10px;
}

.assets-subtab {
  flex: 1;
  padding: 7px 8px;
  border-radius: 8px;
  border: 1px solid #E5E7EB;
  background: #F3F4F6;
  font-size: 12px;
  font-weight: 600;
  color: #4B5563;
}

.assets-subtab.active {
  background: #141414;
  border-color: #141414;
  color: #FFFFFF;
}

.assets-body {
  flex: 1;
  overflow-y: auto;
  padding: 0 12px 18px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.asset-batch-card,
.brand-asset-card,
.recipe-card {
  padding: 12px;
}

.asset-batch-thumbs {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 6px;
  margin-top: 8px;
}

.asset-batch-thumb {
  border: 1px solid #E5E7EB;
  border-radius: 6px;
  overflow: hidden;
  background: #FFFFFF;
  padding: 0;
}

.asset-batch-thumb img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  display: block;
}

.asset-batch-thumb span {
  display: block;
  font-size: 10px;
  color: #4B5563;
  padding: 2px 3px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.brand-preview-box {
  height: 74px;
  border-radius: 8px;
  border: 1px dashed #CBD5E1;
  background: #1F242B;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 8px;
  margin: 8px 0;
}

.brand-preview-box img {
  max-width: 100%;
  max-height: 56px;
  object-fit: contain;
}

/* =========================================================
 * Independent DeWu-Style Product Detail Page
 * ========================================================= */
#appFrame.detail-mode .bottom-tabbar {
  display: none;
}

#pageProductDetail {
  display: none;
  flex-direction: column;
  height: 100%;
  background: #FFFFFF;
}

#pageProductDetail.active {
  display: flex;
}

.pd-topbar {
  height: 44px;
  padding: 0 12px;
  border-bottom: 1px solid #ECEFF3;
  background: #FFFFFF;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  flex-shrink: 0;
}

.pd-back-btn,
.pd-share-btn {
  height: 30px;
  padding: 0 10px;
  border-radius: 7px;
  border: 1px solid #E2E5EB;
  background: #FFFFFF;
  font-size: 12px;
  font-weight: 500;
  color: #1A1D21;
  flex-shrink: 0;
}

.pd-top-title {
  flex: 1;
  min-width: 0;
  text-align: center;
  font-size: 14px;
  font-weight: 700;
  color: #1A1D21;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.pd-preview-banner {
  padding: 6px 12px;
  background: #FEF3C7;
  color: #92400E;
  font-size: 11px;
  font-weight: 600;
  text-align: center;
  flex-shrink: 0;
}

.pd-scroll {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  padding-bottom: calc(80px + env(safe-area-inset-bottom));
}

.pd-gallery-card {
  background: #F4F5F7;
  border-bottom: 1px solid #ECEFF3;
}

.pd-group-tabs {
  display: flex;
  justify-content: center;
  gap: 16px;
  padding: 8px 12px 0;
}

.pd-group-tab {
  border: none;
  background: transparent;
  padding: 4px 2px 6px;
  font-size: 12px;
  font-weight: 600;
  color: #5C636E;
  border-bottom: 2px solid transparent;
}

.pd-group-tab.active {
  color: #B81D24;
  border-bottom-color: #B81D24;
}

.pd-gallery-viewport {
  position: relative;
  width: 100%;
  height: 268px;
  overflow: hidden;
}

.pd-gallery-track {
  display: flex;
  width: 100%;
  height: 100%;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
}

.pd-gallery-track::-webkit-scrollbar {
  display: none;
}

.pd-gallery-slide {
  flex: 0 0 100%;
  width: 100%;
  height: 100%;
  scroll-snap-align: center;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 12px 16px;
}

.pd-gallery-slide img {
  max-width: 100%;
  max-height: 100%;
  width: auto;
  height: auto;
  object-fit: contain;
  cursor: zoom-in;
  display: block;
}

.pd-gallery-counter {
  position: absolute;
  right: 12px;
  bottom: 12px;
  padding: 3px 9px;
  border-radius: 999px;
  background: rgba(20, 20, 20, 0.56);
  color: #FFFFFF;
  font-size: 11px;
  font-weight: 600;
}

.pd-view3d-pill {
  position: absolute;
  left: 12px;
  bottom: 12px;
  height: 28px;
  padding: 0 12px;
  border-radius: 999px;
  border: 1px solid #D8DCE3;
  background: rgba(255, 255, 255, 0.94);
  color: #1A1D21;
  font-size: 12px;
  font-weight: 600;
  box-shadow: 0 4px 12px rgba(15, 23, 42, 0.10);
}

.pd-gallery-caption {
  padding: 6px 14px 10px;
  font-size: 11px;
  color: #5C636E;
  text-align: center;
  min-height: 24px;
}

.pd-section {
  padding: 16px 14px;
  border-bottom: 8px solid #F5F6F8;
}

.pd-title {
  margin: 0;
  font-size: 18px;
  font-weight: 700;
  line-height: 1.35;
  color: #1A1D21;
}

.pd-meta-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 8px;
}

.pd-sku-chip,
.pd-dims-chip {
  padding: 3px 8px;
  border-radius: 6px;
  background: #F4F5F7;
  border: 1px solid #E5E7EB;
  font-size: 11px;
  color: #4B5563;
}

.pd-selling-list {
  margin: 10px 0 0;
  padding-left: 16px;
  color: #374151;
  font-size: 13px;
  line-height: 1.6;
}

.pd-sec-title {
  margin: 0 0 10px;
  font-size: 14px;
  font-weight: 700;
  color: #1A1D21;
}

.pd-spec-rows {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.pd-spec-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  font-size: 12px;
  padding-bottom: 7px;
  border-bottom: 1px solid #F1F3F6;
}

.pd-spec-row:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.pd-spec-key {
  color: #6B7280;
  flex-shrink: 0;
}

.pd-spec-val {
  color: #1A1D21;
  font-weight: 500;
  text-align: right;
}

.pd-detail-copy {
  margin: 0;
  font-size: 13px;
  line-height: 1.6;
  color: #374151;
}

.pd-detail-images {
  margin-top: 10px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.pd-detail-images img {
  width: 100%;
  border-radius: 8px;
  border: 1px solid #ECEFF3;
  background: #F6F7F9;
  object-fit: contain;
  max-height: 300px;
  cursor: zoom-in;
}

.pd-feedback-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.pd-fb-item {
  padding: 11px 12px;
  border-radius: 9px;
  border: 1px solid #ECEFF3;
  background: #FAFAFB;
}

.pd-fb-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 6px;
}

.pd-fb-author {
  font-size: 12px;
  font-weight: 700;
  color: #1A1D21;
}

.pd-fb-badge {
  padding: 2px 7px;
  border-radius: 4px;
  background: #FDF2F2;
  color: #B81D24;
  font-size: 10px;
  font-weight: 600;
}

.pd-fb-content {
  font-size: 12px;
  line-height: 1.55;
  color: #374151;
}

.pd-fb-imgs {
  margin-top: 8px;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.pd-fb-imgs img {
  width: 68px;
  height: 54px;
  border-radius: 6px;
  object-fit: cover;
  border: 1px solid #E5E7EB;
  cursor: zoom-in;
}

.pd-bottom-bar {
  position: relative;
  z-index: 20;
  padding: 10px 14px calc(10px + env(safe-area-inset-bottom));
  background: #FFFFFF;
  border-top: 1px solid #E6E8EC;
  display: flex;
  gap: 10px;
  flex-shrink: 0;
}

.pd-btn-secondary {
  flex: 1;
  height: 40px;
  border-radius: 8px;
  border: 1px solid #D5DAE2;
  background: #FFFFFF;
  color: #1A1D21;
  font-size: 13px;
  font-weight: 600;
}

.pd-btn-primary {
  flex: 1.25;
  height: 40px;
  border-radius: 8px;
  border: none;
  background: #B81D24;
  color: #FFFFFF;
  font-size: 13px;
  font-weight: 600;
}

.consult-qr-svg-wrap {
  width: 168px;
  height: 168px;
  margin: 0 auto 6px;
}

.consult-qr-svg-wrap svg {
  width: 100%;
  height: 100%;
  display: block;
}

.consult-summary-box {
  margin: 10px 0;
  padding: 10px;
  border-radius: 8px;
  border: 1px solid #E6E8EC;
  background: #F7F8FA;
  font-size: 12px;
  line-height: 1.55;
  color: #1A1D21;
  white-space: pre-wrap;
}

