@font-face {
  font-family: "Oframe Sans";
  src: local("Noto Sans KR ExtraLight"), local("Noto Sans KR Light"), local("Noto Sans KR");
  font-style: normal;
  font-weight: 200;
  font-display: swap;
}

@font-face {
  font-family: "Oframe Sans";
  src: local("Noto Sans KR Regular"), local("Noto Sans KR"), local("NotoSansKR-Regular");
  font-style: normal;
  font-weight: 400;
  font-display: swap;
}

@font-face {
  font-family: "Oframe Sans";
  src: local("Noto Sans KR Bold"), local("Noto Sans KR"), local("NotoSansKR-Bold");
  font-style: normal;
  font-weight: 700;
  font-display: swap;
}

@font-face {
  font-family: "Oframe Dashboard";
  src:
    local("Pretendard Variable"),
    local("PretendardVariable"),
    local("Pretendard"),
    url("../fonts/PretendardVariable.ttf") format("truetype"),
    url("/PretendardVariable.ttf") format("truetype");
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
}

:root {
  --font-sans: "Oframe Sans", "Noto Sans KR", "Apple SD Gothic Neo", "Malgun Gothic", sans-serif;
  --font-dashboard: "Oframe Dashboard", "Pretendard Variable", "Pretendard", "Apple SD Gothic Neo", "Malgun Gothic", sans-serif;
  --page-bg: #ececec;
  --surface: #f3f3f3;
  --surface-soft: #f7f7f7;
  --line: #d1d1d1;
  --line-strong: #3d3d3d;
  --text: #111111;
  --muted: #747474;
  --sidebar: #242424;
  --sidebar-accent: #8c3f10;
  --panel-shadow: 0 10px 30px rgba(0, 0, 0, 0.04);
  --accent-green: #48cb58;
  --accent-gray: #b8b8b8;
  --accent-blue: #4aa7d1;
  --accent-danger: #d56731;
  --brand-brown: #7a3d12;
  --brand-brown-deep: #5b2a0a;
  --login-panel-bg: rgba(248, 248, 248, 0.985);
  --login-text: #222222;
  --success: #1d8f51;
  --error: #b63f2f;
  --info: #7a3d12;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
}

body {
  font-family: var(--font-sans);
  color: var(--text);
  background: var(--page-bg);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

a {
  color: inherit;
  text-decoration: none;
}

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

.page-dashboard .dashboard-content {
  font-family: var(--font-dashboard);
}

button {
  cursor: pointer;
}

img {
  max-width: 100%;
  display: block;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

[hidden] {
  display: none !important;
}

/* ------------------------------
   Login — cinematic premium redesign
   (모든 JS 훅 유지: [data-auth-form], 스텝/필드/리셋/메시지/제출 버튼)
------------------------------ */

.page-login {
  /* 로그인 전용 토큰(글로벌 변수 비침투) */
  --lp-espresso: #2a1c12;
  --lp-espresso-deep: #160d06;
  --lp-bronze: #9c5a23;
  --lp-bronze-deep: #6e3c12;
  --lp-bronze-bright: #cf914f;
  --lp-gold: #e6c597;
  --lp-text: #2a1c12;
  --lp-muted: #6f5a4b;
  --lp-card-bg: rgba(250, 245, 238, 0.74);
  --lp-card-border: rgba(255, 255, 255, 0.6);
  --lp-field-bg: rgba(255, 252, 247, 0.55);
  --lp-field-border: rgba(122, 61, 18, 0.2);
  --lp-field-border-focus: #9c5a23;
  background: var(--lp-espresso-deep);
  min-height: 100vh;
  overflow: hidden;
}

.login-shell {
  position: relative;
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  padding: clamp(24px, 5vw, 76px);
  overflow: hidden;
}

/* ── 풀블리드 시네마틱 배경 (장식 전용) ── */
.login-visual {
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
}

.login-visual__media {
  position: absolute;
  inset: -5%;
  background: url("../images/login-hero.jpg") center center / cover no-repeat;
  transform: scale(1.04);
  animation: lpKenBurns 36s ease-in-out infinite alternate;
  will-change: transform;
}

.login-visual__scrim {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(104deg, rgba(22, 13, 6, 0.66) 0%, rgba(22, 13, 6, 0.4) 30%, rgba(22, 13, 6, 0.04) 58%, rgba(22, 13, 6, 0.26) 100%),
    radial-gradient(130% 120% at 16% 46%, rgba(22, 13, 6, 0.32), transparent 56%);
}

.login-visual__orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(64px);
  opacity: 0.55;
  mix-blend-mode: screen;
  will-change: transform;
}

.login-visual__orb--1 {
  width: 44vmax;
  height: 44vmax;
  left: -13vmax;
  top: -12vmax;
  background: radial-gradient(circle, rgba(231, 197, 151, 0.55), transparent 62%);
  animation: lpDrift1 28s ease-in-out infinite alternate;
}

.login-visual__orb--2 {
  width: 36vmax;
  height: 36vmax;
  right: -9vmax;
  bottom: -12vmax;
  background: radial-gradient(circle, rgba(156, 90, 35, 0.5), transparent 60%);
  animation: lpDrift2 32s ease-in-out infinite alternate;
}

.login-visual__grain {
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0.08;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='200' height='200'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  background-size: 200px 200px;
}

/* ── 글래스 인증 카드 ── */
.login-panel {
  position: relative;
  z-index: 2;
  width: min(444px, 100%);
}

.login-card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: clamp(22px, 2.4vw, 30px);
  padding: clamp(30px, 3vw, 46px);
  border-radius: 26px;
  background: var(--lp-card-bg);
  border: 1px solid var(--lp-card-border);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.55),
    0 34px 90px -28px rgba(18, 10, 4, 0.62),
    0 10px 28px -16px rgba(18, 10, 4, 0.45);
  -webkit-backdrop-filter: blur(24px) saturate(155%);
  backdrop-filter: blur(24px) saturate(155%);
  overflow: hidden;
  animation: lpCardIn 0.95s cubic-bezier(0.16, 0.84, 0.3, 1) both;
}

.login-card::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: 0;
  height: 3px;
  background: linear-gradient(90deg, transparent, var(--lp-bronze-bright), var(--lp-gold), transparent);
}

.login-brand {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.login-brand__kicker {
  font-size: 0.7rem;
  letter-spacing: 0.34em;
  text-transform: uppercase;
  font-weight: 700;
  color: var(--lp-bronze);
  animation: lpRise 0.7s cubic-bezier(0.16, 0.84, 0.3, 1) both;
  animation-delay: 0.18s;
}

.login-brand__title {
  margin: 12px 0 0;
  line-height: 1;
  animation: lpRise 0.7s cubic-bezier(0.16, 0.84, 0.3, 1) both;
  animation-delay: 0.26s;
}

.login-brand__logo {
  display: block;
  height: clamp(2.1rem, 2.8vw, 2.4rem);
  width: auto;
  object-fit: contain;
}

.login-brand__subtitle {
  margin: 14px 0 0;
  font-family: var(--font-dashboard);
  font-size: clamp(1.85rem, 2.4vw, 2.2rem);
  line-height: 1;
  letter-spacing: -0.03em;
  font-weight: 300;
  color: var(--lp-text);
  animation: lpRise 0.7s cubic-bezier(0.16, 0.84, 0.3, 1) both;
  animation-delay: 0.34s;
}

.login-brand__system {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin: 13px 0 0;
  padding: 0;
  border: 0;
  font-size: 0.92rem;
  line-height: 1.3;
  color: var(--lp-muted);
  animation: lpRise 0.7s cubic-bezier(0.16, 0.84, 0.3, 1) both;
  animation-delay: 0.42s;
}

.login-brand__system::before {
  content: "";
  flex: 0 0 auto;
  width: 26px;
  height: 2px;
  border-radius: 2px;
  background: linear-gradient(90deg, var(--lp-bronze), transparent);
}

.login-form-area {
  margin: 0;
  padding: 0;
  animation: lpRise 0.7s cubic-bezier(0.16, 0.84, 0.3, 1) both;
  animation-delay: 0.5s;
}

.auth-box {
  width: 100%;
}

.login-form {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.login-form__steps {
  display: grid;
}

.login-step {
  display: grid;
  gap: 16px;
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  transform: translateY(10px);
  pointer-events: none;
  transition: opacity 0.3s ease, transform 0.3s ease, max-height 0.36s ease;
}

.login-step.is-active {
  max-height: 260px;
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

.login-field {
  display: grid;
  gap: 7px;
}

.login-field label {
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-weight: 700;
  color: var(--lp-muted);
}

.login-field input,
.login-field select {
  width: 100%;
  height: 50px;
  padding: 0 14px;
  border-radius: 12px;
  border: 1px solid var(--lp-field-border);
  background: var(--lp-field-bg);
  color: var(--lp-text);
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.25s ease, background-color 0.2s ease;
}

.login-field input[readonly] {
  color: #7b6a5f;
  background: rgba(122, 61, 18, 0.05);
}

.login-field input:disabled {
  opacity: 0.5;
}

.login-field input::placeholder {
  color: rgba(111, 90, 75, 0.45);
}

.login-field input:focus,
.login-field select:focus {
  border-color: var(--lp-field-border-focus);
  background: rgba(255, 253, 250, 0.85);
  box-shadow: 0 0 0 4px rgba(156, 90, 35, 0.14), 0 10px 22px -14px rgba(110, 60, 18, 0.55);
}

.form-message {
  min-height: 20px;
  margin: 0;
  font-size: 0.9rem;
  line-height: 1.4;
  color: var(--lp-muted);
  transition: color 0.2s ease;
}

.form-message[data-state="success"] {
  color: var(--success);
}

.form-message[data-state="error"] {
  color: var(--error);
}

.form-message[data-state="info"] {
  color: var(--lp-bronze-deep);
}

.login-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.login-button {
  position: relative;
  flex: 1 1 auto;
  min-width: 0;
  height: 52px;
  padding: 0 22px;
  border: 0;
  border-radius: 13px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  overflow: hidden;
  font-size: 1rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  color: #fff6ec;
  background: linear-gradient(135deg, var(--lp-bronze-bright) 0%, var(--lp-bronze) 48%, var(--lp-bronze-deep) 100%);
  box-shadow: 0 16px 32px -14px rgba(110, 60, 18, 0.7), inset 0 1px 0 rgba(255, 255, 255, 0.22);
  transition: transform 0.2s ease, box-shadow 0.25s ease, filter 0.2s ease;
}

.login-button::after {
  content: "\2192";
  font-size: 1.05rem;
  line-height: 1;
  transform: translateX(0);
  transition: transform 0.25s ease;
}

.login-button::before {
  content: "";
  position: absolute;
  top: 0;
  left: -65%;
  width: 48%;
  height: 100%;
  background: linear-gradient(100deg, transparent, rgba(255, 255, 255, 0.5), transparent);
  transform: skewX(-18deg);
  transition: left 0.6s ease;
  pointer-events: none;
}

.login-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 22px 42px -14px rgba(110, 60, 18, 0.8), inset 0 1px 0 rgba(255, 255, 255, 0.24);
  filter: saturate(1.05);
}

.login-button:hover::after {
  transform: translateX(4px);
}

.login-button:hover::before {
  left: 125%;
}

.login-button:active {
  transform: translateY(0);
}

.login-button:disabled {
  opacity: 0.6;
  cursor: default;
}

.login-reset-button {
  flex: 0 0 auto;
  height: 52px;
  padding: 0 18px;
  border-radius: 13px;
  border: 1px solid var(--lp-field-border);
  background: rgba(255, 252, 247, 0.5);
  color: var(--lp-bronze-deep);
  font-size: 0.92rem;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: background-color 0.2s ease, border-color 0.2s ease, transform 0.15s ease;
}

.login-reset-button:hover {
  background: rgba(255, 252, 247, 0.85);
  border-color: var(--lp-field-border-focus);
}

.login-reset-button:active {
  transform: translateY(1px);
}

.login-card__foot {
  display: flex;
  align-items: center;
  animation: lpRise 0.7s cubic-bezier(0.16, 0.84, 0.3, 1) both;
  animation-delay: 0.62s;
}

.login-card__support {
  margin: 0;
  font-size: 0.78rem;
  line-height: 1.6;
  letter-spacing: 0.01em;
  color: var(--lp-muted);
}

.login-button.is-loading {
  color: transparent;
  pointer-events: none;
  filter: saturate(0.95);
}

.login-button.is-loading::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 20px;
  height: 20px;
  margin: -10px 0 0 -10px;
  border-radius: 50%;
  border: 2px solid rgba(255, 246, 236, 0.35);
  border-top-color: #fff6ec;
  transform: none;
  animation: loginSpin 0.7s linear infinite;
}

.login-button.is-loading::before {
  display: none;
}

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

.login-support {
  position: absolute;
  right: clamp(18px, 2.4vw, 42px);
  bottom: clamp(16px, 2.4vw, 32px);
  z-index: 2;
  margin: 0;
  max-width: min(560px, 64%);
  color: rgba(255, 248, 240, 0.92);
  text-align: right;
  font-size: clamp(0.8rem, 1vw, 0.94rem);
  line-height: 1.6;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.5);
}

@keyframes lpKenBurns {
  from { transform: scale(1.04); }
  to { transform: scale(1.16) translate(-1.5%, -1.2%); }
}

@keyframes lpDrift1 {
  from { transform: translate(0, 0); }
  to { transform: translate(8%, 6%); }
}

@keyframes lpDrift2 {
  from { transform: translate(0, 0); }
  to { transform: translate(-7%, -5%); }
}

@keyframes lpCardIn {
  from { opacity: 0; transform: translateY(28px) scale(0.985); filter: blur(6px); }
  to { opacity: 1; transform: none; filter: blur(0); }
}

@keyframes lpRise {
  from { opacity: 0; transform: translateY(14px); }
  to { opacity: 1; transform: none; }
}

@keyframes lpPulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(29, 143, 81, 0.45); }
  50% { box-shadow: 0 0 0 5px rgba(29, 143, 81, 0); }
}

/* 로그인 반응형 (풀블리드 배경 + 글래스 카드) */
@media (max-width: 560px) {
  .login-shell {
    justify-content: center;
    padding: 20px;
  }

  .login-panel {
    width: 100%;
  }

  .login-support {
    left: 18px;
    right: 18px;
    max-width: none;
    text-align: center;
    font-size: 0.74rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .login-visual__media,
  .login-visual__orb,
  .login-secure__dot,
  .login-card,
  .login-brand__kicker,
  .login-brand__title,
  .login-brand__subtitle,
  .login-brand__system,
  .login-form-area,
  .login-card__foot {
    animation: none !important;
  }

  .login-visual__media {
    transform: scale(1.04);
  }

  .login-button::before {
    display: none;
  }
}

.section-heading {
  margin-bottom: 12px;
}

.section-heading h2 {
  margin: 0;
  font-size: 1.35rem;
  letter-spacing: -0.04em;
}

.section-heading p {
  margin: 8px 0 0;
  color: #5f554d;
  font-size: 0.95rem;
}

/* ------------------------------
   Dashboard
------------------------------ */

.page-dashboard {
  min-height: 100vh;
  background:
    radial-gradient(circle at top left, rgba(190, 214, 186, 0.48), transparent 34%),
    radial-gradient(circle at right 12%, rgba(182, 212, 227, 0.36), transparent 30%),
    linear-gradient(180deg, #eef2ec 0%, #e7ebe7 100%);
}

.dashboard-shell {
  --dashboard-sidebar-open-width: 260px;
  --dashboard-sidebar-width: var(--dashboard-sidebar-open-width);
  min-height: 100vh;
  display: grid;
  grid-template-columns: var(--dashboard-sidebar-width) minmax(0, 1fr);
  align-items: start;
  position: relative;
  overflow-x: hidden;
  transition: grid-template-columns 0.24s ease;
}

.dashboard-shell.is-sidebar-collapsed {
  --dashboard-sidebar-width: 0px;
}

.sidebar {
  position: fixed;
  left: 0;
  top: 0;
  bottom: 0;
  z-index: 30;
  width: var(--dashboard-sidebar-open-width);
  min-height: 100vh;
  height: 100vh;
  padding: 28px 22px 22px;
  display: flex;
  flex-direction: column;
  background: linear-gradient(180deg, #2c2c2c 0%, var(--sidebar) 100%);
  color: #ffffff;
  border-right: 1px solid rgba(255, 255, 255, 0.08);
  overflow-x: hidden;
  overflow-y: auto;
  transform: translateX(0);
  transform-origin: left center;
  transition: transform 0.24s ease, opacity 0.18s ease, visibility 0.18s ease, box-shadow 0.18s ease;
  box-shadow: 16px 0 34px rgba(11, 15, 21, 0.16);
}

.dashboard-shell.is-sidebar-collapsed .sidebar {
  transform: translateX(calc(-1 * var(--dashboard-sidebar-open-width)));
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.sidebar__brand {
  margin-top: 20px;
  margin-bottom: 22px;
  line-height: 1.02;
}

.sidebar__brand-title {
  display: block;
  font-size: 2.14rem;
  letter-spacing: -0.05em;
  font-weight: 200;
}

.sidebar__brand-logo {
  display: block;
  height: 1.7rem;
  width: auto;
  object-fit: contain;
  filter: brightness(0) invert(1);
}

.sidebar__brand-subtitle {
  display: block;
  margin-top: 4px;
  font-size: 0.92rem;
  letter-spacing: 0.02em;
  opacity: 0.96;
}

.profile-card,
.attendance-card {
  border: 1px solid #5b5b5b;
  background: #484848;
}

.profile-card {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 12px 14px;
  margin-bottom: 14px;
}

.profile-card__content {
  min-width: 0;
}

.profile-card__avatar {
  position: relative;
  flex: 0 0 28px;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: #d5d5d5;
}

.profile-card__avatar::before,
.profile-card__avatar::after {
  content: "";
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  background: #8c8c8c;
}

.profile-card__avatar::before {
  top: 5px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
}

.profile-card__avatar::after {
  bottom: 3px;
  width: 18px;
  height: 9px;
  border-radius: 10px 10px 3px 3px;
}

.profile-card__name {
  margin: 0 0 4px;
  font-size: 0.98rem;
  font-weight: 700;
  word-break: keep-all;
}

.profile-card__meta {
  margin: 0;
  font-size: 0.74rem;
  color: rgba(255, 255, 255, 0.9);
  line-height: 1.55;
}

.attendance-card {
  padding: 12px 14px;
  margin-bottom: 22px;
}

.attendance-card__row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  font-size: 0.77rem;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.92);
}

.attendance-card__row strong {
  font-size: 0.8rem;
  font-weight: 700;
  text-align: right;
}

.attendance-card__row + .attendance-card__row {
  margin-top: 4px;
}

.attendance-card__row--worktime strong {
  color: #ffd8b5;
}

.sidebar__bottom {
  min-height: 0;
  display: flex;
  flex: 1 1 auto;
  flex-direction: column;
}

.sidebar__nav {
  display: grid;
  grid-auto-rows: max-content;
  align-content: start;
  gap: 10px;
  min-height: 0;
  flex: 1 1 auto;
  margin-bottom: 0;
  overflow-y: auto;
  padding-right: 4px;
}

.sidebar__nav::-webkit-scrollbar {
  width: 6px;
}

.sidebar__nav::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.18);
  border-radius: 999px;
}

.sidebar__nav-item,
.sidebar-nav-group__toggle,
.sidebar__action {
  border: 0;
  font-family: inherit;
}

.sidebar-nav-group {
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.04);
}

.sidebar-nav-group__toggle {
  width: 100%;
  min-height: 40px;
  padding: 0 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  background: rgba(255, 255, 255, 0.06);
  color: #f5f5f5;
  font-size: 0.9rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  transition: background-color 0.16s ease, color 0.16s ease;
}

.sidebar-nav-group__toggle:hover {
  background: rgba(255, 255, 255, 0.1);
}

.sidebar-nav-group__toggle:disabled {
  opacity: 0.5;
  cursor: default;
}

.sidebar-nav-group__label {
  white-space: nowrap;
}

.sidebar-nav-group__chevron {
  width: 7px;
  height: 7px;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(45deg);
  transition: transform 0.16s ease;
}

.sidebar-nav-group.is-open .sidebar-nav-group__chevron {
  transform: rotate(225deg);
}

.sidebar-nav-group__items {
  display: grid;
  gap: 6px;
  max-height: 0;
  overflow: hidden;
  padding: 0 8px;
  transition: max-height 0.2s ease, padding-top 0.2s ease, padding-bottom 0.2s ease;
}

.sidebar-nav-group.is-open .sidebar-nav-group__items {
  max-height: 220px;
  padding-top: 7px;
  padding-bottom: 8px;
}

.sidebar__nav-item {
  width: 100%;
  min-height: 38px;
  padding: 0 12px;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  text-align: left;
  background: transparent;
  color: #f4f4f4;
  font-size: 0.92rem;
  font-weight: 560;
  border-radius: 8px;
  transition: background-color 0.18s ease;
}

.sidebar__nav-item.is-active {
  background: var(--sidebar-accent);
  color: #ffffff;
  font-size: 0.95rem;
  font-weight: 700;
}

.sidebar__nav-item:not(.is-active):hover {
  background: rgba(255, 255, 255, 0.06);
}

.sidebar__actions {
  margin-top: auto;
  display: grid;
  gap: 10px;
  padding-top: 20px;
}

.sidebar__action {
  width: 100%;
  min-height: 44px;
  padding: 0 16px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  font-size: 0.95rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  transition: background-color 0.18s ease, transform 0.18s ease, opacity 0.18s ease;
}

.sidebar__action--checkout {
  background: #7a3d12;
}

.sidebar__action--checkout:hover {
  background: #5b2a0a;
}

.sidebar__action--logout {
  background: #3d3d3d;
}

.sidebar__action--logout:hover {
  background: #4b4b4b;
}

.sidebar__action:active {
  transform: translateY(1px);
}

.sidebar__action:disabled {
  opacity: 0.65;
  cursor: default;
}

/* ===== 채널 전환 드롭다운 ===== */
.channel-switcher {
  margin-bottom: 18px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.channel-switcher[hidden] {
  display: none;
}

.channel-switcher__label {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.55);
}

.channel-switcher__field {
  position: relative;
}

.channel-switcher__select {
  width: 100%;
  min-height: 44px;
  padding: 0 38px 0 14px;
  border: 1px solid #5b5b5b;
  border-radius: 10px;
  background: #484848;
  color: #ffffff;
  font-family: inherit;
  font-size: 0.98rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  appearance: none;
  -webkit-appearance: none;
  cursor: pointer;
  transition: border-color 0.18s ease, background-color 0.18s ease;
}

.channel-switcher__select:hover {
  border-color: #7a7a7a;
  background: #4f4f4f;
}

.channel-switcher__select:focus-visible {
  outline: none;
  border-color: var(--sidebar-accent, #8c3f10);
  box-shadow: 0 0 0 2px rgba(176, 106, 44, 0.4);
}

.channel-switcher__select option {
  color: #1f1f1f;
}

.channel-switcher__chevron {
  position: absolute;
  top: 50%;
  right: 15px;
  width: 8px;
  height: 8px;
  margin-top: -6px;
  border-right: 2px solid rgba(255, 255, 255, 0.75);
  border-bottom: 2px solid rgba(255, 255, 255, 0.75);
  transform: rotate(45deg);
  pointer-events: none;
}

/* ===== 채널 변경 확인 모달 ===== */
.channel-confirm-modal {
  position: fixed;
  inset: 0;
  z-index: 12000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
}

.channel-confirm-modal__scrim {
  position: absolute;
  inset: 0;
  background: rgba(20, 16, 12, 0.55);
}

.channel-confirm-modal__dialog {
  position: relative;
  width: min(100%, 380px);
  padding: 26px 24px 20px;
  background: #ffffff;
  border-radius: 14px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.28);
  text-align: center;
  animation: channelConfirmIn 0.16s ease-out;
}

@keyframes channelConfirmIn {
  from { opacity: 0; transform: translateY(8px) scale(0.98); }
  to { opacity: 1; transform: none; }
}

.channel-confirm-modal__title {
  margin: 0 0 20px;
  font-size: 1.02rem;
  font-weight: 600;
  line-height: 1.55;
  color: var(--text, #111111);
}

.channel-confirm-modal__title strong {
  font-weight: 800;
}

.channel-confirm-modal__actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.channel-confirm-modal__btn {
  min-height: 46px;
  border: 1px solid transparent;
  border-radius: 10px;
  font-family: inherit;
  font-size: 0.96rem;
  font-weight: 700;
  cursor: pointer;
  transition: background-color 0.16s ease, filter 0.16s ease, transform 0.12s ease;
}

.channel-confirm-modal__btn:active {
  transform: translateY(1px);
}

.channel-confirm-modal__btn--ghost {
  background: #f1efea;
  color: #4a4a4a;
  border-color: #e0dbd2;
}

.channel-confirm-modal__btn--ghost:hover {
  background: #e8e4dc;
}

.channel-confirm-modal__btn--primary {
  background: var(--sidebar-accent, #8c3f10);
  color: #ffffff;
}

.channel-confirm-modal__btn--primary:hover {
  filter: brightness(1.08);
}

.channel-confirm-modal__btn--primary:focus-visible {
  outline: 3px solid rgba(140, 63, 16, 0.4);
  outline-offset: 2px;
}

/* 사이드바 하단으로 이동한 사용자 카드 — 퇴근/로그아웃 바로 위에 붙인다 */
.profile-card--foot {
  margin: 12px 0 8px;
  padding: 11px 13px;
  align-items: center;
}

.profile-card--foot .profile-card__name {
  margin-bottom: 2px;
  font-size: 0.92rem;
}

/* 퇴근 · 로그아웃 한 줄 배치 (사용자 카드 바로 아래) */
.sidebar__actions--row {
  grid-template-columns: 1fr 1fr;
  margin-top: 0;
  padding-top: 0;
}

.sidebar__actions--row .sidebar__action {
  width: 100%;
}

/* 대시보드 바로가기 버튼 목록 */
.dashboard-quicklinks {
  display: grid;
  gap: 8px;
}

.dashboard-quicklink {
  width: 100%;
  min-height: 44px;
  padding: 0 16px;
  display: inline-flex;
  align-items: center;
  justify-content: flex-start;
  gap: 8px;
  border: 1px solid var(--line, #d1d1d1);
  border-radius: 10px;
  background: #ffffff;
  color: var(--text, #111111);
  font-family: inherit;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  transition: border-color 0.16s ease, background-color 0.16s ease, transform 0.16s ease;
}

.dashboard-quicklink::after {
  content: "→";
  margin-left: auto;
  opacity: 0.45;
}

.dashboard-quicklink:hover {
  border-color: var(--sidebar-accent, #8c3f10);
  background: #fbf6ef;
}

.dashboard-quicklink:active {
  transform: translateY(1px);
}

/* 고객상담 대시보드 (준비 중) */
.dashboard-consult-empty {
  margin-top: 18px;
  padding: 48px 28px;
  border: 1px dashed var(--line, #d1d1d1);
  border-radius: 16px;
  background: #faf7f2;
  text-align: center;
}

.dashboard-consult-empty__title {
  margin: 0 0 8px;
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text, #111111);
}

.dashboard-consult-empty__text {
  margin: 0;
  font-size: 0.9rem;
  color: var(--muted, #747474);
}

/* ============================================================
   고객상담 데스크 (CONSULT · 방문상담) — 고객과 함께 보는 화면
   ============================================================ */
.app-panel--consult-desk {
  --c-ink: #211c17;
  --c-ink-soft: #6f655b;
  --c-line: #e7ded2;
  --c-line-soft: #f0e9df;
  --c-bg: #faf7f2;
  --c-card: #ffffff;
  --c-accent: #9a6a3a;
  --c-accent-deep: #7a4f27;
  --c-accent-soft: #f4ece1;
  --c-danger: #b4532f;
}

.consult-desk {
  display: flex;
  flex-direction: column;
  gap: 16px;
  min-height: 100%;
  padding: 4px 2px 12px;
  font-feature-settings: "tnum" 1;
}

/* 고객상담 헤더 히어로 */
.consult-hero {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 22px 26px;
  border: 1px solid var(--c-line);
  border-radius: 16px;
  background: linear-gradient(118deg, #ffffff 0%, #fbf5ec 100%);
  box-shadow: 0 8px 24px -18px rgba(73, 48, 22, 0.5);
}

.consult-hero__eyebrow {
  margin: 0 0 6px;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  color: var(--c-accent);
}

.consult-hero__title {
  margin: 0;
  font-size: 1.5rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--c-ink);
}

.consult-hero__sub {
  margin: 7px 0 0;
  font-size: 0.86rem;
  color: var(--c-ink-soft);
}

.consult-hero__meta {
  display: flex;
  align-items: center;
  gap: 14px;
  flex: 0 0 auto;
}

.consult-hero__consultant {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 2px;
  font-size: 0.86rem;
  font-weight: 700;
  color: var(--c-ink);
}

.consult-hero__consultant em {
  font-style: normal;
  font-size: 0.74rem;
  font-weight: 500;
  color: var(--c-ink-soft);
}

.consult-desk__chip {
  padding: 5px 13px;
  border-radius: 999px;
  background: var(--c-accent-soft);
  color: var(--c-accent-deep);
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.01em;
}

/* 3단 레이아웃 */
.consult-desk__grid {
  display: grid;
  grid-template-columns: minmax(290px, 0.92fr) minmax(440px, 1.55fr) minmax(280px, 0.82fr);
  gap: 16px;
  align-items: start;
}

.consult-card {
  display: flex;
  flex-direction: column;
  border: 1px solid var(--c-line);
  border-radius: 16px;
  background: var(--c-card);
  box-shadow: 0 10px 30px -22px rgba(73, 48, 22, 0.55);
  overflow: hidden;
}

.consult-card__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 18px 12px;
  border-bottom: 1px solid var(--c-line-soft);
}

.consult-card__title {
  margin: 0;
  font-family: inherit;
  font-size: 1.04rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--c-ink);
}

.consult-card__eyebrow {
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.24em;
  color: #c4b7a6;
}

/* 공통 입력/필드 */
.consult-field { display: flex; flex-direction: column; gap: 5px; }
.consult-field--split { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.consult-field--split > div { display: flex; flex-direction: column; gap: 5px; }
.consult-field--inline { flex-direction: row; align-items: center; justify-content: space-between; gap: 10px; }

.consult-field__label {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  color: var(--c-ink-soft);
}

.consult-input {
  width: 100%;
  min-height: 40px;
  padding: 0 12px;
  border: 1px solid var(--c-line);
  border-radius: 9px;
  background: #fdfbf8;
  color: var(--c-ink);
  font-family: inherit;
  font-size: 0.9rem;
  transition: border-color 0.16s ease, box-shadow 0.16s ease, background-color 0.16s ease;
}
.consult-input::placeholder { color: #c2b6a6; }
.consult-input:focus-visible {
  outline: none;
  border-color: var(--c-accent);
  box-shadow: 0 0 0 3px rgba(154, 106, 58, 0.16);
  background: #fff;
}
.consult-input[readonly] { background: #f6f1ea; color: #4a4239; cursor: default; }
.consult-input--sm { min-height: 34px; font-size: 0.85rem; width: auto; }
select.consult-input { cursor: pointer; appearance: none; -webkit-appearance: none;
  background-image: linear-gradient(45deg, transparent 50%, #9a8b78 50%), linear-gradient(135deg, #9a8b78 50%, transparent 50%);
  background-position: calc(100% - 16px) 50%, calc(100% - 11px) 50%;
  background-size: 5px 5px, 5px 5px; background-repeat: no-repeat; padding-right: 30px; }

.consult-textarea { min-height: 80px; padding: 10px 12px; resize: vertical; line-height: 1.5; }
.consult-textarea--sm { min-height: 54px; }

/* 버튼 */
.consult-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: 40px;
  padding: 0 16px;
  border: 1px solid transparent;
  border-radius: 9px;
  font-family: inherit;
  font-size: 0.88rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  cursor: pointer;
  transition: background-color 0.16s ease, border-color 0.16s ease, filter 0.16s ease, transform 0.12s ease;
}
.consult-btn--sm { min-height: 36px; padding: 0 13px; font-size: 0.84rem; }
.consult-btn--block { width: 100%; }
.consult-btn:active { transform: translateY(1px); }
.consult-btn--primary { background: linear-gradient(135deg, var(--c-accent) 0%, var(--c-accent-deep) 100%); color: #fff6ec; box-shadow: 0 10px 22px -14px rgba(122, 79, 39, 0.9); }
.consult-btn--primary:hover { filter: brightness(1.06); }
.consult-btn--ghost { background: #fff; border-color: var(--c-line); color: #4a4239; }
.consult-btn--ghost:hover { border-color: var(--c-accent); color: var(--c-accent-deep); background: #fffdfa; }
.consult-btn--danger-ghost { background: #fff; border-color: #ecd6cd; color: var(--c-danger); }
.consult-btn--danger-ghost:hover { background: #fdf4f1; border-color: var(--c-danger); }

.consult-link { background: none; border: 0; padding: 0; font-family: inherit; font-size: 0.78rem; font-weight: 700; color: var(--c-accent-deep); cursor: pointer; text-decoration: underline; text-underline-offset: 2px; }
.consult-link--muted { color: var(--c-ink-soft); font-weight: 600; }
.consult-link:hover { color: var(--c-accent); }

.consult-inline { display: flex; gap: 8px; }
.consult-inline .consult-input { flex: 1 1 auto; }
.consult-inline .consult-btn { flex: 0 0 auto; }

/* 좌측 · 고객정보 */
.consult-cust__lookup { padding: 16px 18px 14px; border-bottom: 1px solid var(--c-line-soft); display: flex; flex-direction: column; gap: 9px; }
.consult-cust__hint { margin: 2px 0 0; font-size: 0.72rem; color: #a99a88; display: flex; align-items: center; gap: 8px; }
.consult-cust__fields { padding: 16px 18px; display: flex; flex-direction: column; gap: 12px; }
.consult-cust__foot { margin-top: auto; padding: 0 18px 16px; }

/* 중앙 · 견적 시스템 */
.consult-quote .consult-card__head { flex-wrap: wrap; row-gap: 10px; }
.consult-quote__tabs { display: inline-flex; gap: 4px; padding: 3px; border-radius: 10px; background: #f3ece2; }
.consult-quote__tab { border: 0; background: transparent; padding: 6px 14px; border-radius: 8px; font-family: inherit; font-size: 0.82rem; font-weight: 700; color: var(--c-ink-soft); cursor: pointer; transition: background-color 0.16s ease, color 0.16s ease; }
.consult-quote__tab.is-active { background: #fff; color: var(--c-accent-deep); box-shadow: 0 2px 6px -3px rgba(122, 79, 39, 0.5); }

.consult-quote__toolbar { display: flex; gap: 8px; padding: 14px 18px 0; }

.consult-quote__table-wrap { margin: 14px 18px 0; border: 1px solid var(--c-line-soft); border-radius: 12px; overflow: auto; max-height: 320px; }
.consult-quote__table { width: 100%; border-collapse: collapse; font-size: 0.86rem; }
.consult-quote__table thead th { position: sticky; top: 0; z-index: 1; background: #f7f1e8; color: var(--c-ink-soft); font-weight: 700; font-size: 0.76rem; letter-spacing: 0.01em; text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--c-line); white-space: nowrap; }
.consult-quote__table tbody td { padding: 11px 12px; border-bottom: 1px solid var(--c-line-soft); color: var(--c-ink); vertical-align: middle; }
.consult-quote__table tbody tr:last-child td { border-bottom: 0; }
.consult-quote__table tbody tr:hover { background: #fdfaf5; }
.consult-quote__col-check { width: 38px; text-align: center; }
.consult-quote__col-edit { width: 56px; }
.consult-quote__col-price { text-align: right; }
.consult-quote__table td.consult-quote__col-price { text-align: right; font-weight: 700; }
.consult-quote__empty td { padding: 38px 12px !important; text-align: center; color: #b3a594; font-size: 0.85rem; }

.consult-quote__bottom { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; padding: 16px 18px 18px; margin-top: auto; }

.consult-panel { border: 1px solid var(--c-line); border-radius: 12px; background: #fdfbf8; padding: 14px; display: flex; flex-direction: column; gap: 9px; }
.consult-panel__head { font-size: 0.8rem; font-weight: 700; color: var(--c-ink-soft); padding-bottom: 8px; margin-bottom: 2px; border-bottom: 1px solid var(--c-line-soft); }

.consult-totals__row { display: flex; align-items: center; justify-content: space-between; gap: 10px; font-size: 0.86rem; color: var(--c-ink-soft); }
.consult-totals__row strong { color: var(--c-ink); font-weight: 700; }
.consult-totals__discount { color: var(--c-danger) !important; }
.consult-totals__row--total { padding-top: 9px; border-top: 1px solid var(--c-line); margin-top: 2px; }
.consult-totals__row--total span { font-weight: 700; color: var(--c-ink); }
.consult-totals__row--total strong { font-family: inherit; font-size: 1.28rem; font-weight: 800; color: var(--c-accent-deep); }
.consult-totals__row--due { padding-top: 4px; }
.consult-totals__actions { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 4px; }

.consult-docs__type { display: flex; gap: 16px; padding-bottom: 4px; }
.consult-radio { display: inline-flex; align-items: center; gap: 6px; font-size: 0.85rem; font-weight: 600; color: var(--c-ink); cursor: pointer; }
.consult-radio input { accent-color: var(--c-accent); }
.consult-docs__actions { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 8px; }
.consult-docs__fields { display: flex; flex-direction: column; gap: 8px; margin-top: 2px; }
.consult-docs__note { margin: 4px 0 0; font-size: 0.7rem; line-height: 1.5; color: #b1a392; }

/* 우측 · 상담이력 */
.consult-notes { min-height: 0; }
.consult-notes__area { flex: 1 1 auto; width: auto; box-sizing: border-box; margin: 16px 18px 0; min-height: 260px; }
.consult-notes__foot { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 14px 18px 16px; }
.consult-notes__foot-actions { display: flex; gap: 8px; }

/* 견적 행 상세 */
.consult-quote__muted { color: #b3a594; }
.consult-quote__name { font-weight: 600; }
.consult-quote__opt-summary { font-size: 0.82rem; color: var(--c-ink-soft); line-height: 1.45; }
.consult-quote__qty { display: inline-flex; align-items: center; gap: 6px; margin-top: 6px; font-size: 0.74rem; color: #a99a88; }
.consult-quote__qty input { width: 56px; min-height: 28px; padding: 0 8px; border: 1px solid var(--c-line); border-radius: 7px; background: #fff; font-family: inherit; font-size: 0.82rem; text-align: center; }
.consult-chip-btn { border: 1px solid var(--c-line); background: #fff; color: var(--c-accent-deep); border-radius: 7px; padding: 4px 10px; font-family: inherit; font-size: 0.78rem; font-weight: 700; cursor: pointer; transition: background-color 0.16s ease, border-color 0.16s ease; }
.consult-chip-btn:hover { background: var(--c-accent-soft); border-color: var(--c-accent); }

/* 고객상담 모달 (상품선택 / 옵션편집 / 값입력) */
.consult-modal { position: fixed; inset: 0; z-index: 12000; display: flex; align-items: center; justify-content: center; padding: 18px; }
.consult-modal__scrim { position: absolute; inset: 0; background: rgba(28, 20, 12, 0.5); }
.consult-modal__dialog { position: relative; width: min(100%, 460px); max-height: 86vh; display: flex; flex-direction: column; background: #fff; border-radius: 16px; box-shadow: 0 26px 64px rgba(40, 26, 12, 0.34); overflow: hidden; animation: channelConfirmIn 0.16s ease-out; }
.consult-modal__head { display: flex; align-items: center; justify-content: space-between; padding: 16px 18px; border-bottom: 1px solid #efe7da; }
.consult-modal__head h3 { margin: 0; font-family: inherit; font-size: 1.04rem; font-weight: 800; letter-spacing: -0.01em; color: #211c17; }
.consult-modal__x { border: 0; background: none; font-size: 1.4rem; line-height: 1; color: #9a8b78; cursor: pointer; padding: 0 4px; }
.consult-modal__x:hover { color: #211c17; }
.consult-modal__body { padding: 16px 18px; overflow: auto; }
.consult-modal__foot { display: flex; align-items: center; justify-content: flex-end; gap: 10px; padding: 14px 18px; border-top: 1px solid #efe7da; background: #fdfbf8; }
.consult-modal__empty { margin: 12px 0; text-align: center; color: #b3a594; font-size: 0.88rem; }

.consult-pick-list { display: flex; flex-direction: column; gap: 8px; }
.consult-pick { display: grid; grid-template-columns: 1fr auto; grid-template-areas: "name price" "meta price"; gap: 2px 12px; align-items: center; text-align: left; padding: 12px 14px; border: 1px solid #e7ded2; border-radius: 11px; background: #fff; cursor: pointer; transition: border-color 0.16s ease, background-color 0.16s ease; }
.consult-pick:hover { border-color: #9a6a3a; background: #fffdfa; }
.consult-pick__name { grid-area: name; font-weight: 700; color: #211c17; }
.consult-pick__meta { grid-area: meta; font-size: 0.78rem; color: #a99a88; }
.consult-pick__price { grid-area: price; font-weight: 700; color: #7a4f27; }

.consult-editor__name { font-weight: 700; color: #211c17; margin-bottom: 12px; }
.consult-editor__name span { display: block; margin-top: 3px; font-size: 0.78rem; font-weight: 500; color: #a99a88; }
.consult-optgroup { padding: 12px 0; border-top: 1px solid #f0e9df; }
.consult-optgroup__head { font-size: 0.82rem; font-weight: 700; color: #6f655b; margin-bottom: 8px; }
.consult-req { display: inline-block; margin-left: 4px; padding: 1px 7px; border-radius: 999px; background: #f4ece1; color: #9a6a3a; font-size: 0.66rem; }
.consult-optgroup__items { display: flex; flex-wrap: wrap; gap: 8px; }
.consult-opt { display: inline-flex; align-items: center; gap: 6px; padding: 7px 12px; border: 1px solid #e7ded2; border-radius: 9px; background: #fdfbf8; font-size: 0.84rem; color: #211c17; cursor: pointer; transition: border-color 0.16s ease, background-color 0.16s ease; }
.consult-opt.is-on { border-color: #9a6a3a; background: #f4ece1; font-weight: 600; }
.consult-opt input { accent-color: #9a6a3a; }
.consult-opt em { font-style: normal; color: #7a4f27; font-weight: 700; }
.consult-editor__qty { display: flex; align-items: center; justify-content: space-between; padding-top: 14px; margin-top: 4px; border-top: 1px solid #f0e9df; font-size: 0.86rem; font-weight: 600; color: #6f655b; }
.consult-editor__qty input { width: 80px; min-height: 36px; padding: 0 10px; border: 1px solid #e7ded2; border-radius: 8px; text-align: center; font-family: inherit; font-size: 0.9rem; }
.consult-editor__price { font-family: inherit; font-size: 1.16rem; font-weight: 800; color: #7a4f27; }
.consult-valuebox { display: flex; flex-direction: column; gap: 7px; }

/* 버튼 줄바꿈 방지 + 수정칩 폭 */
.consult-btn { white-space: nowrap; }
.consult-quote__col-edit { width: 64px; }
.consult-chip-btn { white-space: nowrap; }
.consult-input--mono { font-variant-numeric: tabular-nums; letter-spacing: 0.02em; }
.consult-cust__guide { margin: 0; font-size: 0.74rem; line-height: 1.55; color: #a99a88; }
.consult-cust__guide b { color: var(--c-accent-deep); }

/* 견적 행 썸네일 */
.consult-quote__cell { display: inline-flex; align-items: center; gap: 9px; }
.consult-thumb { width: 38px; height: 38px; flex: 0 0 38px; border-radius: 8px; object-fit: cover; border: 1px solid var(--c-line); background: #f6f1ea; }
.consult-thumb--empty { display: inline-block; }

/* 상품 추가 — 카테고리 탭 + 사진 그리드 */
.consult-cat-tabs { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 14px; }
.consult-cat-tab { border: 1px solid var(--c-line); background: #fff; color: var(--c-ink-soft); border-radius: 999px; padding: 7px 14px; font-family: inherit; font-size: 0.82rem; font-weight: 700; cursor: pointer; transition: background-color 0.16s ease, border-color 0.16s ease, color 0.16s ease; }
.consult-cat-tab:hover { border-color: var(--c-accent); color: var(--c-accent-deep); }
.consult-cat-tab.is-active { background: var(--c-accent); border-color: var(--c-accent); color: #fff6ec; }
.consult-modal__dialog:has(.consult-pick-grid) { width: min(100%, 640px); }
.consult-pick-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.consult-pcard { display: flex; flex-direction: column; gap: 4px; padding: 10px; border: 1px solid var(--c-line); border-radius: 12px; background: #fff; cursor: pointer; text-align: left; transition: border-color 0.16s ease, box-shadow 0.16s ease, transform 0.12s ease; }
.consult-pcard:hover { border-color: var(--c-accent); box-shadow: 0 10px 22px -16px rgba(122, 79, 39, 0.7); transform: translateY(-1px); }
.consult-pcard__thumb { display: flex; align-items: center; justify-content: center; aspect-ratio: 4 / 3; width: 100%; border-radius: 9px; overflow: hidden; background: #f6f1ea; margin-bottom: 4px; }
.consult-pcard__thumb img { width: 100%; height: 100%; object-fit: cover; }
.consult-pcard__noimg { font-size: 0.74rem; color: #c4b7a6; }
.consult-pcard__name { font-size: 0.9rem; font-weight: 700; color: var(--c-ink); line-height: 1.3; }
.consult-pcard__meta { font-size: 0.72rem; color: #a99a88; }
.consult-pcard__price { margin-top: 2px; font-size: 0.92rem; font-weight: 800; color: var(--c-accent-deep); }

/* 배송 등록 모달 */
.consult-delivery { display: flex; flex-direction: column; gap: 12px; }
.consult-delivery .consult-input + .consult-input { margin-top: 8px; }
.consult-input--zip { max-width: 120px; }
.consult-check { display: inline-flex; align-items: center; gap: 7px; font-size: 0.85rem; font-weight: 600; color: var(--c-ink); cursor: pointer; }
.consult-check input { accent-color: var(--c-accent); }
.consult-delivery .consult-field--split { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }

/* 고객 문자 발송 모달 */
.consult-send { display: flex; flex-direction: column; gap: 12px; }
.consult-send .consult-textarea { min-height: 110px; }
.consult-input--locked { background: #efe9e0; color: #6f655b; cursor: not-allowed; font-weight: 700; letter-spacing: 0.02em; }

/* 좁은 화면 대응 (단일 모니터 기준이지만 안전장치) */
@media (max-width: 1180px) {
  .consult-desk__grid { grid-template-columns: 1fr; }
  .consult-quote__bottom { grid-template-columns: 1fr; }
}

.dashboard-content {
  grid-column: 2;
  min-width: 0;
  min-height: 100vh;
  padding: clamp(14px, 2.4vw, 26px);
  position: relative;
}

.dashboard-content__topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 0 8px 10px;
}

.sidebar-toggle {
  min-height: 44px;
  padding: 0 16px;
  display: inline-flex;
  align-items: center;
  gap: 12px;
  border: 1px solid #d5dbe3;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: var(--panel-shadow);
  color: #23272d;
  font-size: 0.92rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  transition: background-color 0.18s ease, border-color 0.18s ease, transform 0.18s ease, color 0.18s ease;
}

.sidebar-toggle:hover {
  border-color: #b9c2ce;
  background: #ffffff;
}

.sidebar-toggle:active {
  transform: translateY(1px);
}

.sidebar-toggle:focus-visible {
  outline: 2px solid rgba(122, 61, 18, 0.2);
  outline-offset: 0;
}

.sidebar-toggle__icon {
  display: inline-grid;
  grid-auto-rows: 2px;
  gap: 4px;
  flex: 0 0 auto;
  width: 18px;
}

.sidebar-toggle__icon span {
  display: block;
  width: 100%;
  height: 2px;
  border-radius: 999px;
  background: currentColor;
  transition: transform 0.18s ease, opacity 0.18s ease;
}

.dashboard-shell:not(.is-sidebar-collapsed) .sidebar-toggle__icon span:nth-child(1) {
  transform: translateY(6px) rotate(45deg);
}

.dashboard-shell:not(.is-sidebar-collapsed) .sidebar-toggle__icon span:nth-child(2) {
  opacity: 0;
}

.dashboard-shell:not(.is-sidebar-collapsed) .sidebar-toggle__icon span:nth-child(3) {
  transform: translateY(-6px) rotate(-45deg);
}

.sidebar-toggle__label {
  white-space: nowrap;
}

.app-loading-overlay {
  position: fixed;
  inset: 0;
  z-index: 2200;
  display: grid;
  place-items: center;
  padding: 24px;
  background:
    radial-gradient(circle at top, rgba(255, 255, 255, 0.3), transparent 48%),
    rgba(241, 236, 227, 0.72);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.2s ease, visibility 0.2s ease;
}

.app-loading-overlay.is-visible {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

.app-loading-overlay__card {
  width: min(100%, 266px);
  padding: 18px 17px 14px;
  border: 1px solid rgba(192, 178, 160, 0.9);
  border-radius: 18px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(248, 243, 235, 0.96));
  box-shadow: 0 18px 34px rgba(76, 58, 41, 0.16);
  text-align: center;
}

.app-loading-overlay__title {
  margin: 0;
  color: #2d241b;
  font-size: clamp(1.08rem, 2.1vw, 1.34rem);
  font-weight: 800;
  letter-spacing: -0.04em;
}

.app-loading-overlay__message {
  margin: 7px 0 0;
  color: #6e5d4f;
  font-size: 0.84rem;
  line-height: 1.48;
}

.app-loading-overlay__subtext {
  margin: 3px 0 0;
  color: #8a7a6a;
  font-size: 0.77rem;
  line-height: 1.42;
}

.app-loading-overlay__bar {
  --app-loading-progress: 0%;
  position: relative;
  margin-top: 12px;
  height: 10px;
  border: 1px solid rgba(169, 156, 142, 0.9);
  border-radius: 999px;
  background: linear-gradient(180deg, rgba(233, 226, 216, 0.9), rgba(246, 241, 234, 0.96));
  box-shadow: inset 0 1px 2px rgba(92, 74, 56, 0.14);
  overflow: hidden;
}

.app-loading-overlay__bar::before {
  content: '';
  position: absolute;
  top: 1px;
  bottom: 1px;
  left: 1px;
  width: var(--app-loading-progress, 0%);
  max-width: calc(100% - 2px);
  min-width: 0;
  border-radius: inherit;
  background: linear-gradient(90deg, #d28a3f 0%, #f1b664 58%, #f7d08f 100%);
  box-shadow:
    0 0 0 1px rgba(181, 116, 34, 0.2),
    0 6px 12px rgba(210, 138, 63, 0.28);
  transition: width 5s cubic-bezier(0.25, 0.8, 0.25, 1);
}

.dashboard-fullscreen-toggle[hidden] {
  display: none !important;
}

.dashboard-fullscreen-toggle {
  /* AI 비서 버튼(우상단 고정)과 겹치지 않도록 그 왼쪽에 고정 배치한다. */
  position: fixed;
  top: 24px;
  right: 132px;
  z-index: 1190;
  min-height: 44px;
  padding: 0 15px;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  border: 1px solid #cfd7e1;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: var(--panel-shadow);
  color: #25313f;
  font-size: 0.88rem;
  font-weight: 580;
  letter-spacing: -0.01em;
  transition: border-color 0.18s ease, background-color 0.18s ease, color 0.18s ease, transform 0.18s ease;
}

.dashboard-fullscreen-toggle:hover {
  border-color: #b8c2d0;
  background: #ffffff;
}

.dashboard-fullscreen-toggle:active {
  transform: translateY(1px);
}

.dashboard-fullscreen-toggle:focus-visible {
  outline: 2px solid rgba(73, 115, 169, 0.24);
  outline-offset: 0;
}

.dashboard-fullscreen-toggle.is-active {
  border-color: rgba(31, 91, 156, 0.35);
  background: rgba(227, 240, 255, 0.88);
  color: #16436e;
}

.dashboard-fullscreen-toggle__icon {
  width: 15px;
  height: 15px;
  display: inline-block;
  position: relative;
  flex: 0 0 auto;
}

.dashboard-fullscreen-toggle__icon::before,
.dashboard-fullscreen-toggle__icon::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(currentColor, currentColor) left top / 2px 7px no-repeat,
    linear-gradient(currentColor, currentColor) left top / 7px 2px no-repeat,
    linear-gradient(currentColor, currentColor) right top / 2px 7px no-repeat,
    linear-gradient(currentColor, currentColor) right top / 7px 2px no-repeat,
    linear-gradient(currentColor, currentColor) left bottom / 2px 7px no-repeat,
    linear-gradient(currentColor, currentColor) left bottom / 7px 2px no-repeat,
    linear-gradient(currentColor, currentColor) right bottom / 2px 7px no-repeat,
    linear-gradient(currentColor, currentColor) right bottom / 7px 2px no-repeat;
  transition: transform 0.18s ease, opacity 0.18s ease;
}

.dashboard-fullscreen-toggle__icon::after {
  inset: 2px;
  opacity: 0;
  transform: scale(0.72);
}

.dashboard-fullscreen-toggle.is-active .dashboard-fullscreen-toggle__icon::before {
  opacity: 0;
  transform: scale(1.14);
}

.dashboard-fullscreen-toggle.is-active .dashboard-fullscreen-toggle__icon::after {
  opacity: 1;
  transform: scale(1);
}

.dashboard-fullscreen-toggle__label {
  white-space: nowrap;
}

.delivery-mobile-topbar {
  display: none;
}

.delivery-mobile-topbar__row {
  display: grid;
  gap: 8px;
}

.delivery-mobile-topbar__row--primary {
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
}

.delivery-mobile-topbar__brand {
  min-width: 0;
  display: grid;
  gap: 4px;
}

.delivery-mobile-topbar__logo-block {
  display: inline-grid;
  justify-items: start;
  gap: 2px;
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
}

.delivery-mobile-topbar__logo {
  color: #ffffff;
  font-size: 1.58rem;
  font-weight: 900;
  letter-spacing: 0;
  line-height: 1;
  display: inline-flex;
  align-items: center;
}

.delivery-mobile-topbar__logo-img {
  display: block;
  height: 1.3rem;
  width: auto;
  object-fit: contain;
  filter: brightness(0) invert(1);
}

.delivery-mobile-topbar__logo-sub {
  color: rgba(255, 255, 255, 0.62);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0;
  line-height: 1.2;
}

.delivery-mobile-topbar__user {
  color: rgba(255, 255, 255, 0.78);
  font-size: 0.8rem;
  font-weight: 700;
  line-height: 1.35;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.delivery-mobile-topbar__actions {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.delivery-mobile-topbar__actions .toolbar-button {
  min-height: 34px;
  padding: 0 10px;
  font-size: 0.8rem;
}

.delivery-mobile-topbar__actions .delivery-mobile-topbar__checkout {
  border-color: #7a3d12;
  background: #7a3d12;
  color: #ffffff;
}

.delivery-mobile-topbar__actions .delivery-mobile-topbar__checkout:hover {
  border-color: #5b2a0a;
  background: #5b2a0a;
}

.delivery-mobile-topbar__actions .delivery-mobile-topbar__logout {
  border-color: #3d3d3d;
  background: #3d3d3d;
  color: #ffffff;
}

.delivery-mobile-topbar__actions .delivery-mobile-topbar__logout:hover {
  border-color: #2f2f2f;
  background: #2f2f2f;
}

.delivery-mobile-topbar__row--meta {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.delivery-mobile-chip {
  min-width: 0;
  padding: 8px 9px;
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.08);
  display: grid;
  gap: 3px;
}

.delivery-mobile-chip span {
  color: rgba(255, 255, 255, 0.62);
  font-size: 0.68rem;
  line-height: 1.25;
}

.delivery-mobile-chip strong {
  color: #ffffff;
  font-size: 0.9rem;
  font-weight: 800;
  letter-spacing: 0;
}

.delivery-mobile-chip--accent {
  border-color: rgba(126, 177, 206, 0.48);
  background: rgba(126, 177, 206, 0.18);
}

.delivery-mobile-topbar__tabs {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px;
}

.delivery-mobile-tab {
  min-height: 34px;
  border: 1px solid #c8d0d8;
  border-radius: 10px;
  background: #ffffff;
  color: #324252;
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.delivery-mobile-tab.is-active {
  border-color: #266fbc;
  background: linear-gradient(180deg, #4e95e9 0%, #3f84d3 100%);
  color: #ffffff;
}

.welcome {
  padding: 8px 8px 14px;
}

.welcome__title {
  margin: 0;
  font-size: clamp(1.62rem, 2.4vw, 2.2rem);
  line-height: 1.18;
  letter-spacing: -0.05em;
  font-weight: 660;
}

.welcome__subtitle {
  margin: 10px 0 0;
  font-size: 1rem;
  font-weight: 390;
  color: #506056;
}

.attendance-strip {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 12px;
}

.summary-tile {
  min-width: 0;
  padding: 13px 16px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.72);
  backdrop-filter: blur(8px);
  box-shadow: var(--panel-shadow);
}

.summary-tile--accent {
  background: rgba(247, 239, 232, 0.92);
}

.summary-tile__label {
  display: block;
  color: #666;
  font-size: 0.84rem;
  font-weight: 450;
}

.summary-tile__value {
  display: block;
  margin-top: 6px;
  font-size: clamp(1rem, 1.8vw, 1.24rem);
  line-height: 1.2;
  letter-spacing: -0.03em;
  font-weight: 620;
}

.dashboard-grid {
  display: grid;
  gap: 14px;
}

.dashboard-grid--top {
  grid-template-columns: minmax(0, 2.15fr) minmax(330px, 1fr);
  margin-bottom: 14px;
}

.dashboard-grid--bottom {
  grid-template-columns: minmax(0, 1.55fr) minmax(360px, 1.15fr);
}

.panel {
  min-width: 0;
  background: var(--surface);
  border: 1px solid var(--line);
  box-shadow: var(--panel-shadow);
}

.panel__header {
  display: flex;
  align-items: baseline;
  gap: 12px;
  padding: 18px 24px 16px;
  border-bottom: 1px solid var(--line-strong);
}

.panel__title {
  margin: 0;
  font-size: clamp(1.2rem, 1.8vw, 1.62rem);
  line-height: 1.2;
  letter-spacing: -0.04em;
  font-weight: 700;
}

.panel__title strong {
  margin-left: 8px;
  font-size: 1.55em;
  font-weight: 700;
}

.panel__body {
  padding: 18px 24px 24px;
}

.panel__body--placeholder {
  display: grid;
  place-items: center;
  min-height: 320px;
  color: #7d7d7d;
  text-align: center;
}

.panel--tasks,
.panel--orders-today,
.panel--active-orders,
.panel--placeholder {
  min-height: 338px;
}

.panel--tasks .panel__body {
  display: grid;
  place-items: center;
  min-height: 230px;
  color: #8d8d8d;
  font-size: 1rem;
  font-weight: 700;
}

.channel-list {
  display: grid;
  gap: 8px;
  padding-top: 2px;
}

.channel-row {
  min-height: 58px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 0 24px;
  border: 1px solid rgba(0, 0, 0, 0.1);
  font-size: 1rem;
  font-weight: 700;
}

.channel-row strong {
  font-size: clamp(1.4rem, 2.2vw, 1.9rem);
  line-height: 1;
  letter-spacing: -0.04em;
  font-weight: 700;
}

.channel-row--naver {
  background: var(--accent-green);
}

.channel-row--others {
  background: var(--accent-gray);
}

.channel-row--today {
  background: var(--accent-blue);
}

.overview-link {
  display: block;
  width: 100%;
  margin-top: 18px;
  padding-top: 8px;
  border: 0;
  background: transparent;
  color: #7e7e7e;
  font-size: 1rem;
  font-weight: 700;
  text-align: center;
}

.status-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-top: 6px;
}

.status-tile {
  min-height: 254px;
  padding: 22px 18px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  align-items: center;
  text-align: center;
  background: #dcdcdc;
}

.status-tile__label {
  margin-bottom: 12px;
  font-size: 0.98rem;
  font-weight: 700;
}

.status-tile strong {
  font-size: clamp(1.95rem, 3vw, 2.6rem);
  line-height: 1;
  letter-spacing: -0.05em;
  font-weight: 700;
}

.status-tile--warning .status-tile__label {
  color: var(--accent-danger);
}

.panel--placeholder {
  background: #f0f0f0;
}

.app-panel--dashboard .panel {
  border-radius: 18px;
  background: rgba(250, 250, 248, 0.88);
  backdrop-filter: blur(12px);
  overflow: hidden;
}

.app-panel--dashboard .panel__header {
  align-items: flex-start;
  justify-content: space-between;
  padding: 18px 20px 14px;
  border-bottom-color: rgba(74, 84, 76, 0.14);
}

.app-panel--dashboard .panel__title {
  font-size: clamp(1.04rem, 1.55vw, 1.28rem);
  font-weight: 590;
  color: #18251b;
}

.app-panel--dashboard .panel__title strong {
  display: inline-block;
  margin-left: 8px;
  font-size: 1.38em;
  font-weight: 680;
  color: #0f1812;
}

.app-panel--dashboard .panel__body {
  padding: 17px 20px 19px;
}

.panel__header--dashboard > div {
  min-width: 0;
}

.panel__eyebrow {
  margin: 0 0 8px;
  font-size: 0.73rem;
  font-weight: 560;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: #748277;
}

.panel__badge {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 0 12px;
  border-radius: 10px;
  font-size: 0.76rem;
  font-weight: 560;
  color: #314435;
  background: rgba(49, 68, 53, 0.08);
  white-space: nowrap;
}

.panel__badge--warning {
  color: #8f4a17;
  background: rgba(213, 103, 49, 0.12);
}

.dashboard-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(360px, 0.88fr);
  gap: 12px;
}

.dashboard-side-stack {
  display: grid;
  gap: 12px;
}

.panel--reminders {
  min-height: 100%;
}

.panel__body--reminders {
  display: grid;
  gap: 12px;
}

.dashboard-section-copy {
  margin: 0;
  font-size: 0.88rem;
  line-height: 1.55;
  font-weight: 390;
  color: #5c6b60;
}

.dashboard-reminder-hero {
  padding: 16px 16px;
  border-radius: 14px;
  display: grid;
  gap: 6px;
}

.dashboard-reminder-hero.is-loading {
  background: rgba(95, 115, 101, 0.08);
}

.dashboard-reminder-hero.is-clear {
  background: linear-gradient(135deg, rgba(81, 131, 95, 0.12), rgba(255, 255, 255, 0.92));
}

.dashboard-reminder-hero.is-alert {
  background: linear-gradient(135deg, rgba(213, 103, 49, 0.16), rgba(255, 244, 236, 0.98));
}

.dashboard-reminder-hero__count {
  font-size: clamp(1.58rem, 2.2vw, 2rem);
  line-height: 1;
  letter-spacing: -0.05em;
  font-weight: 700;
  color: #122117;
}

.dashboard-reminder-hero__text {
  margin: 0;
  font-size: 0.86rem;
  line-height: 1.5;
  font-weight: 390;
  color: #445347;
}

.dashboard-pill-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.dashboard-pill {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 0 11px;
  border-radius: 10px;
  font-size: 0.79rem;
  font-weight: 550;
  color: #213125;
  background: rgba(55, 69, 59, 0.08);
}

.dashboard-pill--received {
  background: rgba(84, 126, 102, 0.12);
}

.dashboard-pill--in-production {
  background: rgba(134, 110, 60, 0.12);
}

.dashboard-pill--ready-to-ship {
  background: rgba(72, 111, 147, 0.12);
}

.dashboard-pill--shipping-started {
  background: rgba(50, 124, 182, 0.12);
}

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

.dashboard-reminder-item {
  width: 100%;
  padding: 13px 14px;
  border: 1px solid rgba(39, 54, 43, 0.08);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.82);
  display: grid;
  gap: 6px;
  text-align: left;
  transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
}

.dashboard-reminder-item:hover {
  transform: translateY(-1px);
  border-color: rgba(39, 54, 43, 0.16);
  box-shadow: 0 10px 18px rgba(21, 31, 24, 0.08);
}

.dashboard-reminder-item__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.dashboard-reminder-item__days,
.dashboard-reminder-item__status {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 0 8px;
  border-radius: 8px;
  font-size: 0.74rem;
  font-weight: 600;
}

.dashboard-reminder-item__days {
  color: #8f4a17;
  background: rgba(213, 103, 49, 0.14);
}

.dashboard-reminder-item__status {
  color: #405447;
  background: rgba(64, 84, 71, 0.08);
}

.dashboard-reminder-item__title {
  font-size: 0.92rem;
  line-height: 1.35;
  font-weight: 620;
  color: #152217;
}

.dashboard-reminder-item__copy {
  font-size: 0.84rem;
  line-height: 1.5;
  font-weight: 390;
  color: #56655a;
}

.dashboard-empty-state,
.dashboard-inline-note {
  margin: 0;
  font-size: 0.83rem;
  line-height: 1.5;
  font-weight: 390;
  color: #66746a;
}

.panel--orders-today,
.panel--active-highlight,
.panel--account-presence,
.panel--active-status {
  min-height: auto;
}

.panel__body--today-orders {
  display: grid;
  gap: 10px;
}

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

.channel-row {
  min-height: 68px;
  padding: 13px 14px;
  border: 0;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: #ffffff;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

.channel-row__main {
  min-width: 0;
  display: grid;
  gap: 4px;
}

.channel-row__label {
  font-size: 0.9rem;
  font-weight: 580;
  letter-spacing: -0.02em;
}

.channel-row__note {
  font-size: 0.75rem;
  line-height: 1.45;
  font-weight: 390;
  opacity: 0.9;
}

.channel-row strong {
  display: inline-flex;
  align-items: flex-end;
  gap: 4px;
  font-size: clamp(1.28rem, 2vw, 1.58rem);
  line-height: 1;
  letter-spacing: -0.05em;
  font-weight: 700;
}

.channel-row strong span {
  font-size: 0.78rem;
  line-height: 1.2;
  font-weight: 500;
  opacity: 0.9;
}

.channel-row--naver {
  background: linear-gradient(135deg, #03c75a 0%, #1cab60 100%);
}

.channel-row--imweb {
  background: linear-gradient(135deg, #85888d 0%, #676d74 100%);
}

.channel-row--ohouse {
  background: linear-gradient(135deg, #73c9ee 0%, #5ab7df 100%);
}

.channel-row--cafe24 {
  background: linear-gradient(135deg, #5f6873 0%, #4c5560 100%);
}

.overview-link--dashboard {
  width: auto;
  margin-top: 0;
  padding: 0;
  font-size: 0.8rem;
  font-weight: 560;
  color: #647369;
}

.active-highlight {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.active-highlight__eyebrow {
  margin: 0 0 8px;
  font-size: 0.7rem;
  font-weight: 560;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: #79907e;
}

.active-highlight__title {
  margin: 0;
  font-size: clamp(1.12rem, 1.6vw, 1.38rem);
  line-height: 1.2;
  letter-spacing: -0.04em;
  font-weight: 630;
  color: #112014;
}

.active-highlight__copy {
  margin: 6px 0 0;
  max-width: 22rem;
  font-size: 0.84rem;
  line-height: 1.5;
  font-weight: 390;
  color: #5c6e61;
}

.active-highlight__metric {
  flex: 0 0 auto;
  min-width: 98px;
  padding: 14px 14px 12px;
  border-radius: 12px;
  background: linear-gradient(135deg, rgba(38, 79, 48, 0.12), rgba(255, 255, 255, 0.96));
  text-align: right;
}

.active-highlight__metric strong {
  display: block;
  font-size: clamp(1.58rem, 2.2vw, 1.96rem);
  line-height: 1;
  letter-spacing: -0.05em;
  font-weight: 700;
  color: #102015;
}

.active-highlight__metric span {
  display: block;
  margin-top: 4px;
  font-size: 0.76rem;
  font-weight: 490;
  color: #64786a;
}

.panel__body--active-status {
  padding-top: 14px;
}

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

.dashboard-status-card {
  min-width: 0;
  padding: 14px;
  border-radius: 12px;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 10px;
}

.dashboard-status-card--received {
  background: rgba(93, 130, 107, 0.12);
}

.dashboard-status-card--in-production {
  background: rgba(153, 126, 56, 0.12);
}

.dashboard-status-card--ready-to-ship {
  background: rgba(90, 126, 171, 0.12);
}

.dashboard-status-card--shipping-started {
  background: rgba(66, 140, 194, 0.12);
}

.dashboard-status-card__icon {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.84);
  color: #27412f;
}

.dashboard-status-card__icon svg {
  width: 20px;
  height: 20px;
  fill: currentColor;
}

.dashboard-status-card__body {
  min-width: 0;
  display: grid;
  gap: 4px;
}

.dashboard-status-card__label {
  font-size: 0.86rem;
  line-height: 1.3;
  font-weight: 610;
  color: #17251a;
}

.dashboard-status-card__description {
  font-size: 0.74rem;
  line-height: 1.45;
  font-weight: 390;
  color: #5b6d60;
}

.dashboard-status-card__count {
  display: inline-flex;
  align-items: flex-end;
  gap: 3px;
  font-size: clamp(1.12rem, 1.8vw, 1.38rem);
  line-height: 1;
  letter-spacing: -0.05em;
  font-weight: 700;
  color: #122117;
}

.dashboard-status-card__count span {
  font-size: 0.74rem;
  line-height: 1.2;
  font-weight: 480;
  color: #627368;
}

.panel__body--account-presence {
  padding-top: 14px;
}

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

.dashboard-account-card {
  padding: 12px;
  border: 1px solid rgba(43, 61, 48, 0.1);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.9);
  display: grid;
  gap: 6px;
}

.dashboard-account-card__top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.dashboard-account-card__name {
  min-width: 0;
  font-size: 0.84rem;
  line-height: 1.35;
  font-weight: 610;
  color: #1a2820;
}

.dashboard-account-card__status {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 0.72rem;
  font-weight: 560;
}

.dashboard-account-card__dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #99a4ae;
}

.dashboard-account-card__meta {
  margin: 0;
  font-size: 0.75rem;
  line-height: 1.4;
  font-weight: 390;
  color: #66756b;
}

.dashboard-account-card.is-online {
  border-color: rgba(21, 123, 54, 0.24);
  background: rgba(230, 249, 236, 0.94);
}

.dashboard-account-card.is-online .dashboard-account-card__status {
  color: #0f7c35;
}

.dashboard-account-card.is-online .dashboard-account-card__dot {
  background: #15a34a;
}

.dashboard-account-card.is-offline {
  border-color: rgba(90, 103, 114, 0.22);
  background: rgba(245, 248, 251, 0.9);
}

.dashboard-account-card.is-offline .dashboard-account-card__status {
  color: #5f6b78;
}

.dashboard-account-card.is-offline .dashboard-account-card__dot {
  background: #8a97a4;
}

.dashboard-reminder-item--manual-sync .dashboard-reminder-item__days {
  color: #0f7c35;
  background: rgba(39, 154, 80, 0.15);
}

.dashboard-reminder-item--manual-sync .dashboard-reminder-item__status {
  color: #0f7c35;
  background: rgba(39, 154, 80, 0.12);
}

.dashboard-reminder-item--shipping-delay .dashboard-reminder-item__days {
  color: #1c5e92;
  background: rgba(63, 137, 198, 0.14);
}

.dashboard-reminder-item--production-delay .dashboard-reminder-item__days {
  color: #835c12;
  background: rgba(206, 157, 47, 0.16);
}

.dashboard-reminder-item--missing-info .dashboard-reminder-item__days {
  color: #4e6376;
  background: rgba(129, 150, 171, 0.16);
}

.dashboard-reminder-item--cancelled-alert .dashboard-reminder-item__days {
  color: #a73b2f;
  background: rgba(214, 87, 63, 0.16);
}

.dashboard-reminder-item--cancelled-alert .dashboard-reminder-item__status {
  color: #8e3328;
  background: rgba(214, 87, 63, 0.12);
}

.dashboard-reminder-item--production-overdue-alert .dashboard-reminder-item__days {
  color: #9f3018;
  background: rgba(224, 109, 66, 0.16);
}

.dashboard-reminder-item--production-overdue-alert .dashboard-reminder-item__status {
  color: #8f2a14;
  background: rgba(224, 109, 66, 0.12);
}

.dashboard-pill--overdue {
  background: rgba(213, 103, 49, 0.14);
}

.dashboard-pill--cancelled-alert {
  background: rgba(214, 87, 63, 0.14);
}

.dashboard-pill--production-overdue-alert {
  background: rgba(224, 109, 66, 0.16);
}

.dashboard-pill--shipping-delay {
  background: rgba(72, 133, 189, 0.14);
}

.dashboard-pill--production-delay {
  background: rgba(160, 125, 58, 0.15);
}

.dashboard-pill--missing-info {
  background: rgba(122, 138, 156, 0.14);
}

.dashboard-pill--manual-sync {
  background: rgba(46, 149, 86, 0.15);
}

/* ------------------------------
   Responsive
------------------------------ */

@media (max-width: 1400px) {
  .dashboard-layout {
    grid-template-columns: minmax(0, 1fr) minmax(320px, 0.92fr);
  }

  .dashboard-account-grid {
    grid-template-columns: 1fr;
  }

  .dashboard-grid--top {
    grid-template-columns: minmax(0, 1.8fr) minmax(300px, 0.95fr);
  }

  .dashboard-grid--bottom {
    grid-template-columns: minmax(0, 1.35fr) minmax(320px, 1fr);
  }

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

  .status-tile {
    min-height: 155px;
  }
}

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

  .dashboard-side-stack {
    grid-template-columns: 1fr;
  }

  .dashboard-content {
    padding: 16px;
  }

  .dashboard-content__topbar {
    padding: 0 6px 12px;
  }

  .sidebar-toggle {
    min-height: 40px;
    padding: 0 14px;
    gap: 10px;
    font-size: 0.88rem;
  }

  .section-hero {
    gap: 16px;
    padding: 6px 6px 18px;
  }

  .section-hero__eyebrow {
    font-size: 0.82rem;
  }

  .section-hero__title {
    font-size: clamp(1.54rem, 2.1vw, 1.92rem);
  }

  .section-hero__subtitle {
    margin-top: 8px;
    font-size: 0.92rem;
  }

  .summary-chip {
    padding: 12px 12px;
  }

  .summary-chip span {
    font-size: 0.78rem;
  }

  .summary-chip strong {
    margin-top: 5px;
    font-size: 1.12rem;
  }

  .active-highlight__metric {
    min-width: 110px;
  }

  .product-toolbar,
  .order-toolbar {
    gap: 14px;
  }

  .toolbar-button,
  .page-button {
    min-height: 40px;
    padding: 0 14px;
    font-size: 0.9rem;
  }

  .toolbar-field {
    min-width: 156px;
    font-size: 0.78rem;
  }

  .toolbar-field select,
  .table-select,
  .table-input {
    height: 38px;
  }

  .toolbar-field select,
  .table-select,
  .table-input {
    padding-left: 10px;
    padding-right: 10px;
  }

  .product-table th,
  .product-table td,
  .order-table th,
  .order-table td {
    padding: 11px 10px;
  }

  .product-table th,
  .order-table th {
    font-size: 0.84rem;
  }

  .order-table {
    min-width: 2500px;
  }

  .order-table__col--select {
    width: 52px;
  }

  .order-table__col--order-code {
    width: 216px;
  }

  .order-table__col--platform {
    width: 108px;
  }

  .order-table__col--date {
    width: 124px;
  }

  .order-table__col--status {
    width: 148px;
  }

  .order-table__col--fulfillment {
    width: 112px;
  }

  .order-table__col--category {
    width: 282px;
  }

  .order-table__col--spec {
    width: 176px;
  }

  .order-table__col--color {
    width: 156px;
  }

.order-table__col--options {
  width: 198px;
}

.order-table__col--quantity {
  width: 86px;
}

.order-table__col--amount {
  width: 118px;
}

  .order-table__col--buyer,
  .order-table__col--receiver {
    width: 112px;
  }

  .order-table__col--phone {
    width: 140px;
  }

  .order-table__col--location {
    width: 226px;
  }

  .order-table__col--request {
    width: 218px;
  }

  .order-cell__title {
    font-size: 0.95rem;
  }

  .order-cell__meta,
  .order-cell__submeta {
    font-size: 0.74rem;
  }

  .section-hero__summary--delivery-waiting {
    min-width: 0;
    width: 100%;
  }

  .delivery-layout,
  .account-layout,
  .account-detail-grid {
    grid-template-columns: 1fr;
  }

  .account-detail-panel + .account-detail-panel {
    border-left: 0;
    border-top: 1px solid #eee6db;
  }

  .delivery-table,
  .account-table,
  .account-history-table {
    min-width: 680px;
  }
}

@media (max-width: 1120px) {
  .dashboard-shell {
    --dashboard-sidebar-open-width: 212px;
  }

  .sidebar {
    padding-inline: 16px;
  }

  .dashboard-content {
    padding-inline: 18px;
  }

  .attendance-strip,
  .dashboard-layout,
  .dashboard-grid--top,
  .dashboard-grid--bottom {
    grid-template-columns: 1fr;
  }

  .panel--placeholder {
    min-height: 300px;
  }
}

@media (max-width: 760px) {
  .dashboard-shell {
    grid-template-columns: 1fr;
  }

  .dashboard-shell.is-sidebar-collapsed {
    --dashboard-sidebar-width: 1fr;
  }

  .sidebar {
    position: static;
    width: auto;
    min-height: auto;
    height: auto;
    padding: 18px 18px 20px;
    gap: 18px;
    overflow: visible;
    transform: none;
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
  }

  .dashboard-content {
    grid-column: 1;
  }

  .dashboard-content__topbar {
    display: none;
  }

  .sidebar__brand,
  .profile-card,
  .attendance-card {
    margin: 0;
  }

  .profile-card,
  .attendance-card {
    max-width: 360px;
  }

  .sidebar__bottom {
    min-height: auto;
  }

  .sidebar__nav {
    display: grid;
    gap: 10px;
    margin-bottom: 0;
    overflow: visible;
    padding-right: 0;
    width: min(100%, 360px);
  }

  .sidebar-nav-group {
    width: 100%;
  }

  .sidebar-nav-group__toggle {
    min-height: 42px;
  }

  .sidebar__nav-item {
    min-height: 40px;
    border: 0;
  }

  .sidebar__actions {
    margin-top: 0;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    max-width: 360px;
    padding-top: 12px;
  }

  .welcome {
    padding-inline: 2px;
  }

  .delivery-table,
  .account-table,
  .account-history-table {
    min-width: 620px;
  }

  .account-form-grid {
    grid-template-columns: 1fr;
  }

  .delivery-queue-item {
    grid-template-columns: 32px minmax(0, 1fr);
  }

  .delivery-queue-item > .mini-button {
    grid-column: 1 / -1;
    justify-self: end;
  }

  .account-detail-actions {
    width: 100%;
  }

  .account-detail-actions .toolbar-button {
    flex: 1 1 auto;
  }
}

@media (max-width: 620px) {
  .sidebar__actions {
    grid-template-columns: 1fr;
  }

  .panel__header,
  .panel__body {
    padding-inline: 16px;
  }

  .app-panel--dashboard .panel__header {
    gap: 12px;
    flex-direction: column;
    align-items: flex-start;
  }

  .dashboard-reminder-hero,
  .dashboard-reminder-item,
  .dashboard-status-card {
    border-radius: 10px;
  }

  .channel-row,
  .dashboard-status-card,
  .active-highlight {
    align-items: flex-start;
  }

  .channel-row,
  .active-highlight {
    flex-direction: column;
  }

  .channel-row strong,
  .active-highlight__metric {
    align-self: stretch;
    justify-content: flex-end;
    text-align: right;
  }

  .dashboard-status-grid {
    grid-template-columns: 1fr;
  }

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

  .channel-row {
    min-height: 50px;
    padding-inline: 14px;
  }

  .channel-row strong {
    font-size: 1.22rem;
  }

  .dashboard-account-grid {
    grid-template-columns: 1fr;
  }

  .login-button {
    width: 100%;
  }
}

/* ------------------------------
   Dashboard Fullscreen
------------------------------ */

.dashboard-shell.is-dashboard-fullscreen {
  --dashboard-sidebar-width: 0px;
  grid-template-columns: 0 minmax(0, 1fr);
}

.dashboard-shell.is-dashboard-fullscreen .sidebar {
  transform: translateX(calc(-1 * var(--dashboard-sidebar-open-width)));
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.dashboard-shell.is-dashboard-fullscreen .dashboard-content {
  grid-column: 1 / -1;
  min-height: 100vh;
  padding: 10px 12px 12px;
}

.dashboard-shell.is-dashboard-fullscreen .dashboard-content__topbar {
  justify-content: flex-end;
  padding: 0 0 8px;
}

.dashboard-shell.is-dashboard-fullscreen .sidebar-toggle {
  display: none;
}

.dashboard-shell.is-dashboard-fullscreen .welcome,
.dashboard-shell.is-dashboard-fullscreen .attendance-strip {
  display: none;
}

.dashboard-shell.is-dashboard-fullscreen .dashboard-layout {
  grid-template-columns: minmax(0, 1.22fr) minmax(330px, 0.9fr);
  gap: 10px;
  height: calc(100vh - 74px);
  min-height: 0;
  overflow: hidden;
}

.dashboard-shell.is-dashboard-fullscreen .dashboard-side-stack {
  min-height: 0;
  grid-template-rows: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.dashboard-shell.is-dashboard-fullscreen .app-panel--dashboard .panel {
  height: 100%;
  display: flex;
  flex-direction: column;
  border-radius: 10px;
  box-shadow: 0 10px 20px rgba(33, 41, 35, 0.08);
  backdrop-filter: none;
}

.dashboard-shell.is-dashboard-fullscreen .app-panel--dashboard .panel__header {
  padding: 12px 14px 10px;
}

.dashboard-shell.is-dashboard-fullscreen .app-panel--dashboard .panel__body {
  padding: 12px 14px 14px;
  flex: 1 1 auto;
  min-height: 0;
  overflow: auto;
}

.dashboard-shell.is-dashboard-fullscreen .app-panel--dashboard .panel__title {
  font-size: clamp(0.98rem, 1.2vw, 1.12rem);
  font-weight: 560;
}

.dashboard-shell.is-dashboard-fullscreen .app-panel--dashboard .panel__title strong {
  font-size: 1.24em;
  font-weight: 650;
}

.dashboard-shell.is-dashboard-fullscreen .panel__eyebrow {
  margin-bottom: 6px;
  font-size: 0.68rem;
}

.dashboard-shell.is-dashboard-fullscreen .panel__badge {
  min-height: 26px;
  border-radius: 8px;
  padding: 0 10px;
  font-size: 0.72rem;
  font-weight: 520;
}

.dashboard-shell.is-dashboard-fullscreen .dashboard-section-copy {
  font-size: 0.8rem;
  line-height: 1.45;
}

.dashboard-shell.is-dashboard-fullscreen .dashboard-reminder-hero {
  padding: 12px;
  border-radius: 9px;
}

.dashboard-shell.is-dashboard-fullscreen .dashboard-reminder-hero__count {
  font-size: clamp(1.3rem, 1.8vw, 1.62rem);
}

.dashboard-shell.is-dashboard-fullscreen .dashboard-reminder-hero__text {
  font-size: 0.8rem;
}

.dashboard-shell.is-dashboard-fullscreen .dashboard-reminder-list {
  gap: 7px;
}

.dashboard-shell.is-dashboard-fullscreen .dashboard-reminder-item {
  padding: 10px 11px;
  border-radius: 8px;
}

.dashboard-shell.is-dashboard-fullscreen .dashboard-reminder-item__title {
  font-size: 0.84rem;
}

.dashboard-shell.is-dashboard-fullscreen .dashboard-reminder-item__copy {
  font-size: 0.77rem;
  line-height: 1.4;
}

.dashboard-shell.is-dashboard-fullscreen .channel-list--dashboard {
  gap: 8px;
}

.dashboard-shell.is-dashboard-fullscreen .channel-row {
  min-height: 56px;
  border-radius: 9px;
  padding: 9px 11px;
}

.dashboard-shell.is-dashboard-fullscreen .channel-row__label {
  font-size: 0.82rem;
  font-weight: 550;
}

.dashboard-shell.is-dashboard-fullscreen .channel-row__note {
  font-size: 0.72rem;
}

.dashboard-shell.is-dashboard-fullscreen .channel-row strong {
  font-size: clamp(1.05rem, 1.55vw, 1.3rem);
}

.dashboard-shell.is-dashboard-fullscreen .overview-link--dashboard {
  font-size: 0.76rem;
}

.dashboard-shell.is-dashboard-fullscreen .dashboard-status-grid {
  gap: 8px;
}

.dashboard-shell.is-dashboard-fullscreen .dashboard-status-card {
  padding: 10px;
  border-radius: 9px;
  gap: 8px;
}

.dashboard-shell.is-dashboard-fullscreen .dashboard-status-card__icon {
  width: 32px;
  height: 32px;
  border-radius: 8px;
}

.dashboard-shell.is-dashboard-fullscreen .dashboard-status-card__icon svg {
  width: 17px;
  height: 17px;
}

.dashboard-shell.is-dashboard-fullscreen .dashboard-status-card__label {
  font-size: 0.8rem;
  font-weight: 560;
}

.dashboard-shell.is-dashboard-fullscreen .dashboard-status-card__description {
  font-size: 0.71rem;
}

.dashboard-shell.is-dashboard-fullscreen .dashboard-status-card__count {
  font-size: clamp(0.96rem, 1.35vw, 1.14rem);
}

.dashboard-shell.is-dashboard-fullscreen .dashboard-account-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 7px;
}

.dashboard-shell.is-dashboard-fullscreen .dashboard-account-card {
  padding: 10px;
  border-radius: 9px;
}

.dashboard-shell.is-dashboard-fullscreen .dashboard-account-card__name {
  font-size: 0.78rem;
  font-weight: 560;
}

.dashboard-shell.is-dashboard-fullscreen .dashboard-account-card__status {
  font-size: 0.68rem;
}

.dashboard-shell.is-dashboard-fullscreen .dashboard-account-card__meta {
  font-size: 0.7rem;
  line-height: 1.35;
}

@media (max-width: 1080px) {
  .dashboard-shell.is-dashboard-fullscreen .dashboard-layout {
    grid-template-columns: 1fr;
    height: calc(100vh - 74px);
  }

  .dashboard-shell.is-dashboard-fullscreen .dashboard-side-stack {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    grid-template-rows: minmax(0, 1fr);
  }
}

@media (max-width: 860px) {
  .dashboard-shell.is-dashboard-fullscreen .dashboard-layout {
    height: auto;
    overflow: visible;
  }

  .dashboard-shell.is-dashboard-fullscreen .dashboard-side-stack {
    grid-template-columns: 1fr;
  }
}

/* ------------------------------
   App panels / Product management
------------------------------ */

.has-modal-open {
  overflow: hidden;
}

.app-panel {
  display: none;
}

.app-panel.is-active {
  display: block;
}

body.is-delivery-mobile .app-panel.is-active:not([data-panel="delivery-my"]):not([data-panel="settlement"]):not([data-panel="ledger-settlement"]) {
  display: none;
}

body.is-delivery-mobile .sidebar {
  display: none;
}

body.is-delivery-mobile .dashboard-shell {
  grid-template-columns: 1fr;
}

body.is-delivery-mobile .dashboard-content {
  grid-column: 1;
  min-height: auto;
  padding: 8px 9px calc(94px + env(safe-area-inset-bottom));
}

body.is-delivery-mobile .dashboard-content__topbar {
  display: none;
}

body.is-delivery-mobile .delivery-mobile-topbar {
  display: grid;
  position: relative;
  overflow: hidden;
  gap: 11px;
  margin: 0 0 10px;
  padding: 13px 13px 12px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 9px;
  background:
    radial-gradient(circle at 14% 0%, rgba(155, 95, 38, 0.34) 0%, rgba(155, 95, 38, 0) 38%),
    linear-gradient(135deg, rgba(255, 255, 255, 0.1) 0%, rgba(255, 255, 255, 0) 38%),
    linear-gradient(180deg, #2b2d2d 0%, #181b1d 100%);
  box-shadow: 0 16px 34px rgba(21, 24, 25, 0.22);
}

body.is-delivery-mobile .delivery-mobile-topbar::after {
  content: "";
  position: absolute;
  right: -26px;
  bottom: -38px;
  width: 138px;
  height: 138px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.035);
  pointer-events: none;
}

body.is-delivery-mobile .delivery-mobile-topbar__row {
  position: relative;
  z-index: 1;
}

body.is-delivery-mobile .delivery-mobile-topbar__row--primary {
  gap: 11px;
  align-items: start;
}

body.is-delivery-mobile .delivery-mobile-topbar__brand {
  gap: 7px;
}

body.is-delivery-mobile .delivery-mobile-topbar__logo {
  font-size: 1.68rem;
}

body.is-delivery-mobile .delivery-mobile-topbar__logo-img {
  height: 1.4rem;
}

body.is-delivery-mobile .delivery-mobile-topbar__user {
  display: inline-flex;
  width: fit-content;
  max-width: 100%;
  min-height: 26px;
  align-items: center;
  padding: 0 9px;
  border-left: 3px solid #9b5f26;
  border-radius: 0 999px 999px 0;
  background: rgba(255, 255, 255, 0.08);
  color: rgba(255, 255, 255, 0.82);
}

body.is-delivery-mobile .delivery-mobile-topbar__actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  align-items: start;
}

body.is-delivery-mobile .delivery-mobile-topbar__actions .toolbar-button {
  min-height: 36px;
  padding: 0 9px;
  border-radius: 4px;
  font-size: 0.78rem;
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.18);
}

body.is-delivery-mobile .delivery-mobile-topbar__row--meta {
  gap: 7px;
}

body.is-delivery-mobile .delivery-mobile-chip {
  min-height: 58px;
  padding: 9px 10px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

body.is-delivery-mobile .delivery-mobile-topbar__tabs {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 5px;
  padding: 4px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.07);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

body.is-delivery-mobile .delivery-mobile-tab {
  min-height: 36px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: rgba(255, 255, 255, 0.68);
  font-size: 0.86rem;
  font-weight: 800;
  letter-spacing: 0;
}

body.is-delivery-mobile .delivery-mobile-tab.is-active {
  background: #ffffff;
  color: #182233;
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.18);
}

body.is-delivery-mobile .section-hero--delivery-waiting {
  padding: 2px 2px 10px;
}

body.is-delivery-mobile .section-hero--delivery-waiting .section-hero__summary {
  min-width: 0;
  width: 100%;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

body.is-delivery-mobile .summary-chip {
  padding: 10px 10px;
}

body.is-delivery-mobile .summary-chip span {
  font-size: 0.74rem;
}

body.is-delivery-mobile .summary-chip strong {
  font-size: 1rem;
}

body.is-delivery-mobile [data-panel="delivery-waiting"] .delivery-layout {
  grid-template-columns: 1fr;
}

body.is-delivery-mobile [data-panel="delivery-waiting"] .delivery-card--waiting {
  display: block;
}

body.is-delivery-mobile [data-panel="delivery-waiting"] .delivery-card--queue {
  min-height: auto;
}

body.is-delivery-mobile [data-panel="delivery-waiting"] .delivery-queue-item {
  grid-template-columns: 30px minmax(0, 1fr);
}

body.is-delivery-mobile [data-panel="delivery-waiting"] .delivery-queue-item > .mini-button {
  display: none;
}

body.is-delivery-mobile .section-hero--delivery-installation {
  padding: 2px 2px 10px;
}

body.is-delivery-mobile .section-hero--delivery-installation .section-hero__summary {
  min-width: 0;
  width: 100%;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

body.is-delivery-mobile [data-panel="delivery-installation"] .delivery-toolbar {
  gap: 8px;
}

body.is-delivery-mobile [data-panel="delivery-installation"] .delivery-toolbar__actions {
  width: 100%;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

body.is-delivery-mobile [data-panel="delivery-installation"] .toolbar-button {
  width: 100%;
  padding-left: 8px;
  padding-right: 8px;
}

body.is-delivery-mobile [data-panel="delivery-installation"] .delivery-route-item {
  grid-template-columns: 30px minmax(0, 1fr);
  padding: 9px 10px;
}

body.is-delivery-mobile [data-panel="delivery-installation"] .delivery-route-actions .mini-button {
  flex: 1 1 calc(33.33% - 6px);
  min-width: 0;
}

body.is-delivery-mobile [data-panel="delivery-installation"] .delivery-table-wrap {
  overflow: visible;
}

body.is-delivery-mobile [data-panel="delivery-installation"] .delivery-table {
  min-width: 0;
}

body.is-delivery-mobile [data-panel="delivery-installation"] .delivery-table--installation thead {
  display: none;
}

body.is-delivery-mobile [data-panel="delivery-installation"] .delivery-table--installation,
body.is-delivery-mobile [data-panel="delivery-installation"] .delivery-table--installation tbody,
body.is-delivery-mobile [data-panel="delivery-installation"] .delivery-table--installation tr,
body.is-delivery-mobile [data-panel="delivery-installation"] .delivery-table--installation td {
  display: block;
  width: 100%;
}

body.is-delivery-mobile [data-panel="delivery-installation"] .delivery-table--installation tr[data-delivery-installation-row] {
  margin: 0 0 10px;
  border: 1px solid #ddd2c4;
  border-radius: 12px;
  background: #ffffff;
  padding: 10px 10px 8px;
}

body.is-delivery-mobile [data-panel="delivery-installation"] .delivery-table--installation tr[data-delivery-installation-row] > td {
  border: 0;
  padding: 0;
  margin-top: 6px;
}

body.is-delivery-mobile [data-panel="delivery-installation"] .delivery-table--installation tr[data-delivery-installation-row] > td:first-child {
  margin-top: 0;
}

body.is-delivery-mobile [data-panel="delivery-installation"] .delivery-table--installation tr[data-delivery-installation-row] > td:nth-child(2) {
  display: none;
}

body.is-delivery-mobile [data-panel="delivery-installation"] .delivery-table--installation tr.delivery-route-marker td {
  margin: 8px 0;
  border-radius: 10px;
  padding: 7px 10px;
}

body.is-delivery-mobile [data-panel="delivery-installation"] .delivery-installation-actions {
  gap: 6px;
}

body.is-delivery-mobile [data-panel="delivery-installation"] .delivery-installation-actions .mini-button {
  flex: 1 1 calc(50% - 6px);
  min-width: 0;
}

body.is-delivery-mobile [data-panel="delivery-installation"] .delivery-route-proof {
  width: 100%;
  justify-content: center;
}

body.is-delivery-mobile [data-panel="delivery-installation"] .delivery-route-name {
  font-size: 1.02rem;
}

body.is-delivery-mobile [data-panel="delivery-installation"] .delivery-route-status-main {
  font-size: 0.86rem;
}

body.is-delivery-mobile [data-panel="delivery-installation"] .delivery-table--installation tr[data-delivery-installation-row] > td:nth-child(5) {
  font-size: 0.9rem;
  color: #2c231b;
  font-weight: 700;
}

body.is-delivery-mobile [data-panel="delivery-installation"] .delivery-table--installation tr[data-delivery-installation-row] > td:nth-child(6) {
  color: #1a61b2;
  text-decoration: underline;
  text-underline-offset: 2px;
}

body.is-delivery-mobile [data-panel="delivery-installation"] .delivery-table--installation tr[data-delivery-installation-row] > td:nth-child(7) {
  color: #56493d;
  line-height: 1.45;
}

body.is-delivery-mobile [data-panel="delivery-my"] .delivery-toolbar {
  position: fixed;
  left: 50%;
  right: auto;
  bottom: calc(12px + env(safe-area-inset-bottom));
  z-index: 235;
  width: min(464px, calc(100vw - 20px));
  margin: 0;
  padding: 9px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 10px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.11) 0%, rgba(255, 255, 255, 0) 38%),
    linear-gradient(180deg, rgba(31, 39, 54, 0.98) 0%, rgba(21, 27, 39, 0.99) 100%);
  box-shadow: 0 18px 38px rgba(18, 24, 34, 0.28);
  transform: translateX(-50%);
  animation: delivery-my-actionbar-rise 0.24s ease both;
  transition: transform 0.24s ease, opacity 0.24s ease;
}

/* 디테일 모달이 열린 동안: 하단 툴바 + 현재 카드 잠시 내려서 숨김 */
body.is-delivery-mobile.has-delivery-modal-open [data-panel="delivery-my"] .delivery-toolbar,
body.is-delivery-mobile.has-delivery-modal-open [data-panel="delivery-my"] .delivery-my-current-card {
  transform: translate3d(-50%, 140%, 0);
  opacity: 0;
  pointer-events: none;
  animation: none;
}

body.is-delivery-mobile [data-panel="delivery-my"] .section-hero {
  display: none;
}

/* 기사 모바일: "현재 향하고 있는 주문" 카드 (배송출발 후만 표시) */
.delivery-my-current-card {
  display: none;
}

body.is-delivery-mobile [data-panel="delivery-my"] .delivery-my-current-card {
  display: flex;
  flex-direction: column;
  gap: 2px;
  position: fixed;
  left: 50%;
  bottom: calc(80px + env(safe-area-inset-bottom));
  transform: translateX(-50%);
  z-index: 234;
  width: min(464px, calc(100vw - 20px));
  padding: 8px 10px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 10px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.08) 0%, rgba(255, 255, 255, 0) 38%),
    linear-gradient(180deg, rgba(31, 39, 54, 0.98) 0%, rgba(21, 27, 39, 0.99) 100%);
  box-shadow: 0 14px 28px rgba(18, 24, 34, 0.28);
  color: #f1eee7;
  animation: delivery-my-actionbar-rise 0.24s ease both;
  transition: transform 0.24s ease, opacity 0.24s ease;
}

body.is-delivery-mobile [data-panel="delivery-my"] .delivery-my-current-card[hidden] {
  display: none;
}

/* 기사 모바일: "현재 이동 중" 카드가 보이는 동안 본문 하단에 추가 스크롤 여백을 확보합니다. */
body.is-delivery-mobile.has-delivery-current-card .dashboard-content {
  padding-bottom: calc(94px + env(safe-area-inset-bottom) + var(--delivery-current-card-height, 132px) + 12px);
}

.delivery-my-current-card__status {
  align-self: flex-start;
  padding: 1px 7px;
  border-radius: 999px;
  background: rgba(255, 184, 92, 0.18);
  color: #ffc888;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.delivery-my-current-card__status[data-state="installing"] {
  background: rgba(110, 207, 130, 0.18);
  color: #9bdfaf;
}

.delivery-my-current-card__name {
  margin-top: 1px;
  font-size: 0.9rem;
  color: #ffffff;
  line-height: 1.2;
  font-weight: 700;
}

.delivery-my-current-card__row {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
}

.delivery-my-current-card__row .delivery-detail-copy-btn {
  flex-shrink: 0;
  min-height: 26px;
  padding: 0 8px;
  font-size: 0.7rem;
  font-weight: 700;
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.18);
  color: #f1eee7;
}

.delivery-my-current-card__row .delivery-detail-copy-btn.is-copied {
  background: rgba(110, 207, 130, 0.22);
  border-color: rgba(110, 207, 130, 0.45);
  color: #9bdfaf;
}

.delivery-my-current-card__text {
  flex: 1 1 0;
  min-width: 0;
  font-size: 0.8rem;
  line-height: 1.35;
  color: #d8d2c3;
  white-space: normal;
  word-break: keep-all;
  overflow-wrap: anywhere;
}

.delivery-my-current-card__text--phone {
  color: #88c5ff;
}

body.is-delivery-mobile [data-panel="delivery-my"] .panel--delivery-installation {
  border: 0;
  border-radius: 0;
  box-shadow: none;
  background: transparent;
}

body.is-delivery-mobile [data-panel="delivery-my"] .panel__body--delivery-installation {
  padding: 0;
}

body.is-delivery-mobile [data-panel="delivery-my"] .delivery-toolbar__filters {
  display: none;
}

body.is-delivery-mobile [data-panel="delivery-my"] .delivery-toolbar__actions {
  width: 100%;
  display: grid;
  justify-content: stretch;
  justify-items: stretch;
  align-items: center;
  grid-template-columns: 42px 0 minmax(0, 1fr);
  grid-template-areas: "refresh save launch";
  gap: 7px;
  transition: grid-template-columns 0.24s ease;
}

body.is-delivery-mobile [data-panel="delivery-my"] .delivery-toolbar__actions.has-dirty-order {
  grid-template-columns: 42px minmax(92px, 0.82fr) minmax(112px, 1fr);
}

body.is-delivery-mobile [data-panel="delivery-my"] [data-delivery-my-print] {
  display: none;
}

body.is-delivery-mobile [data-panel="delivery-my"] .toolbar-button {
  width: 100%;
  min-height: 42px;
  padding-left: 8px;
  padding-right: 8px;
  border-radius: 6px;
  font-size: 0.82rem;
  box-shadow: none;
}

body.is-delivery-mobile [data-panel="delivery-my"] [data-delivery-my-refresh] {
  width: 42px;
  min-width: 42px;
  min-height: 42px;
  height: 42px;
  padding: 0;
  grid-area: refresh;
  background: #ffffff;
  border-color: rgba(255, 255, 255, 0.88);
  color: #172033;
}

body.is-delivery-mobile [data-panel="delivery-my"] [data-delivery-my-refresh] .toolbar-button__icon {
  margin-right: 0;
  font-size: 1.05rem;
}

body.is-delivery-mobile [data-panel="delivery-my"] [data-delivery-my-refresh] .toolbar-button__label {
  display: none;
}

body.is-delivery-mobile [data-panel="delivery-my"] [data-delivery-my-save-order] {
  grid-area: save;
  justify-self: stretch;
  width: 100%;
  max-width: 0;
  opacity: 0;
  pointer-events: none;
  overflow: hidden;
  transform: translate3d(-8px, 0, 0);
  border-color: transparent;
  background: #0a6fd1;
  color: #ffffff;
  font-weight: 700;
  padding-left: 0;
  padding-right: 0;
  transition: max-width 0.24s ease, opacity 0.24s ease, transform 0.24s ease, border-color 0.24s ease, padding 0.24s ease;
}

body.is-delivery-mobile [data-panel="delivery-my"] .delivery-toolbar__actions.has-dirty-order [data-delivery-my-save-order].is-visible {
  max-width: 100%;
  opacity: 1;
  pointer-events: auto;
  transform: translate3d(0, 0, 0);
  border-color: #0656a8;
  padding-left: 8px;
  padding-right: 8px;
}

body.is-delivery-mobile [data-panel="delivery-my"] [data-delivery-my-start-route],
body.is-delivery-mobile [data-panel="delivery-my"] [data-delivery-my-stop-route] {
  grid-area: launch;
  justify-self: stretch;
  width: 100%;
  min-height: 42px;
  box-shadow: 0 8px 18px rgba(12, 15, 20, 0.22);
}

body.is-delivery-mobile [data-panel="delivery-my"] [data-delivery-my-start-route]:not([hidden]),
body.is-delivery-mobile [data-panel="delivery-my"] [data-delivery-my-stop-route]:not([hidden]) {
  animation: delivery-my-launch-rise 0.24s ease;
}

@keyframes delivery-my-actionbar-rise {
  0% {
    opacity: 0;
    transform: translate3d(-50%, 18px, 0) scale(0.98);
  }
  100% {
    opacity: 1;
    transform: translate3d(-50%, 0, 0) scale(1);
  }
}

@keyframes delivery-my-launch-rise {
  0% {
    opacity: 0;
    transform: translate3d(0, 14px, 0) scale(0.98);
  }
  100% {
    opacity: 1;
    transform: translate3d(0, 0, 0) scale(1);
  }
}

body.is-delivery-mobile [data-panel="delivery-my"] .delivery-table-wrap {
  overflow: auto;
  border: 1px solid #d9d0c4;
  border-radius: 8px;
  background: #ffffff;
}

body.is-delivery-mobile [data-panel="delivery-my"] .delivery-table--my {
  min-width: 718px;
  table-layout: fixed;
}

body.is-delivery-mobile [data-panel="delivery-my"] .delivery-table--my th,
body.is-delivery-mobile [data-panel="delivery-my"] .delivery-table--my td {
  padding: 5px 6px;
  font-size: 0.75rem;
  line-height: 1.3;
  border-right-color: #f0ebe3;
  border-bottom-color: #eee7dc;
}

body.is-delivery-mobile [data-panel="delivery-my"] .delivery-table--my tr[data-delivery-my-row] > td {
  background: #ffffff;
  vertical-align: middle;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

body.is-delivery-mobile [data-panel="delivery-my"] .delivery-table--my .delivery-table__col--actions {
  width: 112px;
}

body.is-delivery-mobile [data-panel="delivery-my"] .delivery-table--my .delivery-table__col--buyer {
  width: 84px;
}

body.is-delivery-mobile [data-panel="delivery-my"] .delivery-table--my .delivery-table__col--product {
  width: 136px;
}

body.is-delivery-mobile [data-panel="delivery-my"] .delivery-table--my .delivery-table__col--contact {
  width: 112px;
}

body.is-delivery-mobile [data-panel="delivery-my"] .delivery-table--my .delivery-table__col--address {
  width: 176px;
}

body.is-delivery-mobile [data-panel="delivery-my"] .delivery-table--my .delivery-table__col--status {
  width: 84px;
}

body.is-delivery-mobile [data-panel="delivery-my"] .delivery-table--my tr.delivery-route-marker td {
  font-size: 0.74rem;
  padding: 5px 7px;
}

body.is-delivery-mobile [data-panel="delivery-my"] .delivery-installation-actions {
  gap: 6px;
  flex-wrap: nowrap;
  align-items: center;
  justify-content: center;
}

body.is-delivery-mobile [data-panel="delivery-my"] .delivery-installation-actions .mini-button {
  flex: 0 0 auto;
  min-width: 44px;
  min-height: 28px;
  padding: 0 8px;
  font-size: 0.75rem;
}

body.is-delivery-mobile [data-panel="delivery-my"] .delivery-route-proof {
  width: auto;
  justify-content: flex-start;
  font-size: 0.64rem;
  padding: 1px 5px;
  display: none;
}

body.is-delivery-mobile [data-panel="delivery-my"] .delivery-route-name {
  max-width: 100%;
  font-size: 0.82rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

body.is-delivery-mobile [data-panel="delivery-my"] .delivery-route-status-main,
body.is-delivery-mobile [data-panel="delivery-my"] .delivery-route-status-sub {
  display: inline;
  font-size: 0.72rem;
  margin: 0;
}

body.is-delivery-mobile [data-panel="delivery-my"] .delivery-route-status-sub::before {
  content: " | ";
  color: #8a7e72;
}

.app-panel--products {
  min-width: 0;
}

.section-hero {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
  padding: 8px 10px 22px;
}

.section-hero__eyebrow {
  margin: 0;
  color: var(--brand-brown);
  font-size: 0.88rem;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.section-hero__title {
  margin: 6px 0 0;
  font-size: clamp(1.7rem, 2.35vw, 2.18rem);
  line-height: 1.15;
  letter-spacing: -0.05em;
}

.section-hero__subtitle {
  max-width: 760px;
  margin: 10px 0 0;
  color: #6d6d6d;
  font-size: 0.97rem;
}

.section-hero--orders > :first-child {
  flex: 1 1 auto;
  min-width: 0;
}

.section-hero__summary {
  flex: 0 0 auto;
  display: grid;
  grid-template-columns: repeat(4, minmax(132px, 1fr));
  gap: 12px;
  align-self: flex-start;
  min-width: 568px;
}

.section-hero--orders .section-hero__summary {
  flex: 0 1 640px;
  width: min(100%, 640px);
  min-width: 0;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 10px;
  align-self: end;
}

.summary-chip {
  min-width: 0;
  padding: 14px 16px;
  border: 1px solid var(--line);
  background: var(--surface);
  box-shadow: var(--panel-shadow);
  white-space: nowrap;
}

.summary-chip--accent {
  background: #f6efe7;
}

.summary-chip--audit {
  cursor: pointer;
  border-color: #e0a14a;
  background: #fff8e1;
  color: inherit;
  text-align: left;
  font: inherit;
  transition: background-color 0.18s ease, transform 0.18s ease;
}

.summary-chip--audit:hover {
  background: #fceeb4;
}

.summary-chip--audit:active {
  transform: translateY(1px);
}

.summary-chip--audit strong {
  color: #8a4a14;
}

.summary-chip span {
  display: block;
  font-size: 0.84rem;
  color: var(--muted);
}

.summary-chip strong {
  display: block;
  margin-top: 6px;
  font-size: 1.25rem;
}

.section-hero--orders .summary-chip {
  padding: 12px 12px;
  white-space: normal;
}

.section-hero--orders .summary-chip span {
  font-size: 0.76rem;
  line-height: 1.25;
}

.section-hero--orders .summary-chip strong {
  margin-top: 4px;
  font-size: 1.08rem;
  line-height: 1.1;
  white-space: nowrap;
}

.panel--coming-soon .panel__body--placeholder {
  min-height: 320px;
}

.panel--products .panel__body--products,
.panel--orders .panel__body--orders {
  padding-top: 22px;
}

.section-hero--orders {
  padding-bottom: 12px;
}

.product-toolbar,
.order-toolbar {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 18px;
  margin-bottom: 12px;
}

.product-toolbar__actions,
.product-toolbar__filters,
.order-toolbar__actions,
.order-toolbar__filters {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}

.order-toolbar__meta {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px 18px;
}

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

.order-toolbar__top-row {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px 16px;
  flex-wrap: nowrap;
}

.order-toolbar__top-row .order-toolbar__actions {
  flex: 0 1 auto;
  min-width: 0;
}

.order-toolbar__right {
  flex: 1 1 360px;
  min-width: 280px;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
}

.order-toolbar__bottom {
  display: flex;
  justify-content: flex-end;
  margin-top: 14px;
}

.order-toolbar__bottom .order-toolbar__right {
  flex: 0 0 auto;
  min-width: 0;
}

.order-toolbar__filters-row {
  width: 100%;
}

.order-toolbar__filters {
  width: 100%;
  align-items: flex-end;
}

.order-toolbar__search {
  flex: 2 1 360px;
  min-width: 280px;
  display: flex;
  align-items: flex-end;
  gap: 10px;
}

.order-toolbar__search .toolbar-field {
  min-width: 0;
}

.order-toolbar__search-field {
  flex: 0 0 138px;
}

.order-toolbar__search-query {
  flex: 1 1 auto;
}

.order-toolbar__search-input {
  display: flex;
  align-items: center;
  gap: 8px;
}

.order-toolbar__search-input .table-input {
  flex: 1 1 auto;
}

.order-toolbar__filters .toolbar-field {
  flex: 1 1 158px;
  min-width: 142px;
}

.order-toolbar__filters .toolbar-field--compact {
  flex-basis: 138px;
}

.order-toolbar__pagination {
  flex: 0 1 auto;
  min-width: 0;
  display: flex;
  justify-content: flex-end;
}

.order-toolbar__pagination .order-pagination {
  width: auto;
}

.order-pagination {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 10px 12px;
}

.order-pagination__summary {
  color: #74685f;
  font-size: 0.88rem;
  font-weight: 600;
}

.product-toolbar__hint,
.order-toolbar__hint {
  margin: 0 0 14px;
  color: #74685f;
  font-size: 0.89rem;
}

.toolbar-button,
.mini-button,
.page-button {
  border: 1px solid #bcbcbc;
  background: #ffffff;
  color: #222222;
  transition: background-color 0.18s ease, border-color 0.18s ease, color 0.18s ease, transform 0.18s ease, opacity 0.18s ease;
}

.toolbar-icon-button {
  width: 42px;
  height: 42px;
  flex: 0 0 42px;
  padding: 0;
  border: 1px solid #bcbcbc;
  background: #ffffff;
  color: #222222;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 1.18rem;
  line-height: 1;
  transition: background-color 0.18s ease, border-color 0.18s ease, color 0.18s ease, transform 0.18s ease, opacity 0.18s ease;
}

.toolbar-button,
.page-button {
  min-height: 42px;
  padding: 0 16px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.95rem;
  font-weight: 600;
  white-space: nowrap;
}

.toolbar-button__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-right: 6px;
  font-size: 1rem;
  line-height: 1;
}

.toolbar-button__label {
  display: inline-block;
}

.toolbar-button:hover,
.mini-button:hover,
.page-button:hover,
.toolbar-icon-button:hover {
  border-color: #969696;
  background: #f7f7f7;
}

.toolbar-button:disabled,
.mini-button:disabled,
.page-button:disabled,
.toolbar-icon-button:disabled {
  opacity: 0.55;
  cursor: default;
}

.toolbar-button--primary,
.mini-button--primary {
  border-color: var(--brand-brown);
  background: var(--brand-brown);
  color: #ffffff;
}

.toolbar-button--primary:hover,
.mini-button--primary:hover {
  border-color: var(--brand-brown-deep);
  background: var(--brand-brown-deep);
}

.toolbar-button--accent,
.mini-button--accent {
  border-color: #1d5f88;
  background: #1d5f88;
  color: #ffffff;
}

.toolbar-button--accent:hover,
.mini-button--accent:hover {
  border-color: #174a69;
  background: #174a69;
}

.toolbar-icon-button--accent {
  border-color: #1d5f88;
  background: #1d5f88;
  color: #ffffff;
}

.toolbar-icon-button--accent:hover {
  border-color: #174a69;
  background: #174a69;
}

.toolbar-button--danger {
  border-color: #b74a3e;
  background: #b74a3e;
  color: #ffffff;
}

.toolbar-button--danger:hover {
  border-color: #95372e;
  background: #95372e;
}


.toolbar-button--naver {
  border-color: rgba(3, 199, 90, 0.24);
  background: rgba(3, 199, 90, 0.08);
  color: #047a3a;
}

.toolbar-button--naver:hover {
  border-color: rgba(3, 199, 90, 0.36);
  background: rgba(3, 199, 90, 0.14);
}

.mini-button--danger {
  border-color: #c35b4c;
  color: #b54232;
}

.mini-button--danger:hover {
  background: #fff4f2;
}

.mini-button--ghost {
  background: #ffffff;
}

.toolbar-field {
  display: grid;
  gap: 6px;
  min-width: 168px;
  font-size: 0.82rem;
  font-weight: 700;
  color: #5f5f5f;
}

.toolbar-field select,
.table-select,
.table-input {
  width: 100%;
  min-width: 0;
  height: 40px;
  border: 1px solid #d0d0d0;
  background: #ffffff;
  color: #222222;
}

.toolbar-field select,
.table-select {
  padding: 0 12px;
}

.table-input {
  padding: 0 12px;
}

.table-input::placeholder {
  color: #a0a0a0;
}

.table-input:focus,
.table-select:focus,
.toolbar-field select:focus {
  outline: 2px solid rgba(122, 61, 18, 0.2);
  outline-offset: 0;
  border-color: rgba(122, 61, 18, 0.45);
}

.product-table-wrap {
  overflow-x: auto;
  border: 1px solid var(--line);
  background: #ffffff;
}

.product-table {
  width: 100%;
  min-width: 1040px;
  border-collapse: collapse;
  table-layout: fixed;
}

.product-table th,
.product-table td {
  border-bottom: 1px solid #e1e1e1;
  border-right: 1px solid #ededed;
  padding: 14px 12px;
  vertical-align: top;
  background: #ffffff;
}

.product-table th:last-child,
.product-table td:last-child {
  border-right: 0;
}

.product-table th {
  position: sticky;
  top: 0;
  z-index: 1;
  background: #f2f2f2;
  font-size: 0.88rem;
  font-weight: 700;
  text-align: center;
  white-space: nowrap;
}

.product-table tbody tr {
  transition: background-color 0.16s ease, box-shadow 0.16s ease;
}

.product-table tbody tr:hover td {
  background: #f5eadc;
}

.product-row.is-dirty td {
  box-shadow: inset 0 1px 0 rgba(122, 61, 18, 0.12), inset 0 -1px 0 rgba(122, 61, 18, 0.12);
}

.product-row.is-saving {
  opacity: 0.7;
}

.product-code-cell {
  display: grid;
  gap: 8px;
}

.product-code-cell__code {
  font-size: 0.98rem;
  font-weight: 700;
}

.product-code-cell__meta {
  display: inline-flex;
  width: fit-content;
  max-width: 100%;
  padding: 3px 8px;
  border-radius: 999px;
  font-size: 0.74rem;
  font-weight: 700;
}

.row-status--saved {
  background: rgba(29, 143, 81, 0.1);
  color: var(--success);
}

.row-status--dirty {
  background: rgba(122, 61, 18, 0.1);
  color: var(--brand-brown);
}

.row-status--new {
  background: rgba(74, 167, 209, 0.12);
  color: #16617f;
}

.product-image-box {
  width: 132px;
  height: 100px;
  border: 1px solid #d9d9d9;
  background: #f4f4f4;
  overflow: hidden;
}

.product-image-box__image,
.product-image-box__placeholder {
  width: 100%;
  height: 100%;
}

.product-image-box__image {
  object-fit: cover;
}

.product-image-box__placeholder {
  display: grid;
  place-items: center;
  padding: 12px;
  text-align: center;
  color: #9a9a9a;
  font-size: 0.78rem;
}

.product-image-cell {
  display: flex;
  align-items: flex-start;
  gap: 8px;
}

.product-image-actions {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin: 0;
}

.mini-button--icon {
  width: 34px;
  min-width: 34px;
  padding: 0;
}

.mini-button {
  min-height: 34px;
  padding: 0 11px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.84rem;
  font-weight: 700;
  white-space: nowrap;
}

.table-input--price {
  text-align: right;
}

/* 상품 옵션 수정 · 공정 관리 모달 — 둥근 모서리 금지(전부 각진 모던) */
[data-option-modal],
[data-option-modal] *,
[data-product-process-modal],
[data-product-process-modal] * {
  border-radius: 0 !important;
}

.option-count {
  display: block;
  margin-top: 8px;
  font-size: 0.76rem;
  color: #707070;
}

.toggle-check {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding-top: 8px;
  font-size: 0.88rem;
  font-weight: 700;
}

.toggle-check input {
  width: 16px;
  height: 16px;
}

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

.product-empty {
  margin-top: 14px;
  padding: 22px 18px;
  border: 1px dashed #c7c7c7;
  background: #fafafa;
  color: #7d7d7d;
  text-align: center;
}

.product-pagination {
  margin-top: 18px;
  display: flex;
  justify-content: center;
}

.page-button-group {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.page-button.is-active {
  border-color: var(--brand-brown);
  background: var(--brand-brown);
  color: #ffffff;
}

.quick-notification-stack {
  position: fixed;
  right: max(22px, env(safe-area-inset-right));
  bottom: max(22px, env(safe-area-inset-bottom));
  z-index: 240;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 12px;
  pointer-events: none;
}

.quick-notification {
  width: min(468px, calc(100vw - 36px));
  padding: 18px 20px;
  pointer-events: auto;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 18px;
  background: linear-gradient(180deg, rgba(30, 39, 57, 0.97) 0%, rgba(23, 31, 46, 0.99) 100%);
  box-shadow: 0 18px 46px rgba(8, 13, 23, 0.34), 0 8px 18px rgba(8, 13, 23, 0.16);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  cursor: pointer;
  opacity: 0;
  transform: translate3d(0, 16px, 0) scale(0.98);
  transition: opacity 0.24s ease, transform 0.24s ease, box-shadow 0.24s ease, border-color 0.24s ease;
}

.quick-notification.is-visible {
  opacity: 1;
  transform: translate3d(0, 0, 0) scale(1);
}

.quick-notification.is-bumping {
  transform: translate3d(0, 0, 0) scale(1.012);
}

.quick-notification[data-state="success"] {
  border-color: rgba(110, 231, 183, 0.16);
  box-shadow: 0 18px 46px rgba(8, 13, 23, 0.34), 0 8px 18px rgba(10, 37, 30, 0.18);
}

.quick-notification[data-state="error"] {
  border-color: rgba(248, 113, 113, 0.18);
  box-shadow: 0 18px 46px rgba(26, 11, 16, 0.36), 0 8px 18px rgba(56, 16, 21, 0.18);
}

.quick-notification[data-state="warning"] {
  border-color: rgba(251, 191, 36, 0.2);
  box-shadow: 0 18px 46px rgba(31, 21, 8, 0.34), 0 8px 18px rgba(58, 39, 11, 0.18);
}

.quick-notification[data-state="info"] {
  border-color: rgba(147, 197, 253, 0.16);
}

.quick-notification__badge {
  display: inline-flex;
  margin-bottom: 9px;
  padding: 5px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.09);
  color: rgba(244, 247, 252, 0.8);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.quick-notification__title {
  display: block;
  margin-bottom: 6px;
  color: rgba(247, 249, 252, 0.92);
  font-size: 0.92rem;
  font-weight: 700;
  line-height: 1.4;
  letter-spacing: -0.012em;
}

.quick-notification__text {
  display: block;
  margin: 0;
  color: rgba(255, 255, 255, 0.97);
  font-size: clamp(1rem, 0.97rem + 0.12vw, 1.08rem);
  font-weight: 700;
  line-height: 1.55;
  letter-spacing: -0.013em;
  word-break: keep-all;
}

.quick-notification__detail {
  display: block;
  margin-top: 8px;
  color: rgba(229, 236, 244, 0.78);
  font-size: 0.92rem;
  line-height: 1.55;
  letter-spacing: -0.01em;
  word-break: break-word;
}

.toolbar-field--compact {
  min-width: 156px;
}

.toolbar-field--modal {
  min-width: 138px;
}

.order-bulk-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin: 0 0 14px;
  padding: 14px 16px;
  border: 1px solid #e6ddd1;
  background: #faf7f2;
}

.order-bulk-bar__summary {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.order-bulk-bar__summary strong {
  font-size: 1rem;
}

.order-bulk-bar__summary span {
  color: #766d63;
  font-size: 0.84rem;
  line-height: 1.45;
}

.order-bulk-bar__actions {
  display: flex;
  align-items: end;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 10px;
}

.order-toolbar__detail-search {
  display: flex;
  align-items: flex-end;
  flex: 0 0 auto;
}

.order-toolbar__detail-search .toolbar-button {
  height: 40px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.order-detail-search-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 20px;
  height: 20px;
  padding: 0 6px;
  border-radius: 999px;
  background: #ffffff;
  color: #74461f;
  font-size: 0.72rem;
  font-weight: 800;
}

.order-detail-search {
  position: fixed;
  top: 96px;
  right: max(28px, env(safe-area-inset-right));
  z-index: 220;
  width: min(420px, calc(100vw - 32px));
  max-height: calc(100vh - 140px);
  display: flex;
  flex-direction: column;
  background: #ffffff;
  border: 1px solid #d9cfbe;
  border-radius: 18px;
  box-shadow: 0 24px 60px rgba(67, 36, 13, 0.22), 0 8px 20px rgba(67, 36, 13, 0.12);
  overflow: hidden;
  animation: order-detail-search-enter 0.22s cubic-bezier(0.2, 0.9, 0.2, 1);
}

.order-detail-search[hidden] {
  display: none;
}

@keyframes order-detail-search-enter {
  from {
    opacity: 0;
    transform: translate3d(8px, -10px, 0);
  }
  to {
    opacity: 1;
    transform: translate3d(0, 0, 0);
  }
}

.order-detail-search__header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  padding: 18px 20px 12px;
  border-bottom: 1px solid #f1ece4;
  background: #fbf7f2;
}

.order-detail-search__title {
  font-size: 1rem;
  font-weight: 800;
  color: #2d2417;
}

.order-detail-search__subtitle {
  margin: 4px 0 0;
  font-size: 0.78rem;
  color: #6a5f53;
  line-height: 1.45;
}

.order-detail-search__close {
  flex: 0 0 auto;
  width: 32px;
  height: 32px;
  border: 0;
  background: transparent;
  font-size: 1.4rem;
  line-height: 1;
  color: #6a5f53;
  cursor: pointer;
  border-radius: 8px;
}

.order-detail-search__close:hover {
  background: rgba(116, 70, 31, 0.08);
  color: #2d2417;
}

.order-detail-search__body {
  flex: 1 1 auto;
  overflow-y: auto;
  padding: 16px 20px;
  display: grid;
  gap: 18px;
}

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

.order-detail-search__section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
}

.order-detail-search__section-title {
  margin: 0;
  font-size: 0.88rem;
  font-weight: 800;
  color: #2d2417;
}

.order-detail-search__section-hint {
  width: 100%;
  margin: 0;
  font-size: 0.74rem;
  color: #8b7d6c;
  line-height: 1.45;
}

.order-detail-search__section-actions {
  display: flex;
  gap: 6px;
}

.order-detail-search__chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.order-detail-search__chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 6px 12px;
  border: 1px solid #d9cfbe;
  border-radius: 999px;
  background: #ffffff;
  color: #4a3f33;
  font-size: 0.78rem;
  font-weight: 700;
  cursor: pointer;
  transition: border-color 0.18s ease, background 0.18s ease, color 0.18s ease;
}

.order-detail-search__chip:hover {
  border-color: #74461f;
}

.order-detail-search__chip.is-active {
  background: #74461f;
  border-color: #74461f;
  color: #ffffff;
}

.order-detail-search__chip[disabled] {
  opacity: 0.55;
  cursor: not-allowed;
}

.order-detail-search__date-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.order-detail-search__date-grid .toolbar-field {
  min-width: 0;
}

.order-detail-search__date-grid[hidden] {
  display: none;
}

.order-detail-search__toggle {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.82rem;
  font-weight: 700;
  color: #4a3f33;
  cursor: pointer;
}

.order-detail-search__toggle input {
  width: 16px;
  height: 16px;
  accent-color: #74461f;
}

.order-detail-search__footer {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  padding: 12px 20px 16px;
  border-top: 1px solid #f1ece4;
  background: #fbf7f2;
}

@media (max-width: 720px) {
  .order-detail-search {
    top: auto;
    right: 12px;
    left: 12px;
    bottom: 12px;
    width: auto;
    max-height: 80vh;
  }
}

.order-floating-action {
  position: fixed;
  right: max(22px, env(safe-area-inset-right));
  bottom: max(22px, env(safe-area-inset-bottom));
  z-index: 235;
  pointer-events: none;
  transform: translate3d(0, 18px, 0);
  opacity: 0;
}

.order-floating-action[hidden] {
  display: none;
}

.order-floating-action.is-visible {
  animation: order-floating-action-enter 0.28s cubic-bezier(0.2, 0.9, 0.2, 1) forwards;
}

.order-floating-action.is-hiding {
  animation: order-floating-action-exit 0.22s cubic-bezier(0.4, 0, 1, 1) forwards;
}

.order-floating-action__stack {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 12px;
}

.order-floating-action__button {
  --floating-action-bg: linear-gradient(180deg, #9a6a3f 0%, #74461f 52%, #633913 100%);
  --floating-action-shadow: 0 18px 46px rgba(67, 36, 13, 0.28), 0 8px 18px rgba(67, 36, 13, 0.16), inset 0 1px 0 rgba(255, 255, 255, 0.14);
  --floating-action-hover-shadow: 0 22px 54px rgba(67, 36, 13, 0.32), 0 10px 22px rgba(67, 36, 13, 0.18);
  --floating-action-focus-ring: rgba(143, 98, 57, 0.18);
  min-width: min(340px, calc(100vw - 36px));
  min-height: 62px;
  padding: 0 18px 0 24px;
  display: inline-grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 18px;
  border: 0;
  border-radius: 20px;
  background: var(--floating-action-bg);
  box-shadow: var(--floating-action-shadow);
  color: #ffffff;
  font-size: clamp(1rem, 0.97rem + 0.16vw, 1.1rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  pointer-events: auto;
  cursor: pointer;
  transition: box-shadow 0.24s ease, filter 0.24s ease, transform 0.24s ease;
}

.order-floating-action__button[data-action-mode="outsourced"] {
  --floating-action-bg: linear-gradient(180deg, #2d6a4f 0%, #1f5a42 52%, #174836 100%);
  --floating-action-shadow: 0 18px 46px rgba(23, 72, 54, 0.28), 0 8px 18px rgba(23, 72, 54, 0.16), inset 0 1px 0 rgba(255, 255, 255, 0.14);
  --floating-action-hover-shadow: 0 22px 54px rgba(23, 72, 54, 0.32), 0 10px 22px rgba(23, 72, 54, 0.18);
  --floating-action-focus-ring: rgba(45, 106, 79, 0.2);
}

.order-floating-action__button[data-action-mode="pack-only"] {
  --floating-action-bg: linear-gradient(180deg, #2f5fb3 0%, #244b91 52%, #1b376d 100%);
  --floating-action-shadow: 0 18px 46px rgba(27, 55, 109, 0.28), 0 8px 18px rgba(27, 55, 109, 0.16), inset 0 1px 0 rgba(255, 255, 255, 0.14);
  --floating-action-hover-shadow: 0 22px 54px rgba(27, 55, 109, 0.32), 0 10px 22px rgba(27, 55, 109, 0.18);
  --floating-action-focus-ring: rgba(47, 95, 179, 0.2);
}

.order-floating-action__button[data-action-mode="mixed"],
.order-floating-action__button[data-action-mode="unavailable"] {
  --floating-action-bg: linear-gradient(180deg, #6e7685 0%, #596171 52%, #474f5d 100%);
  --floating-action-shadow: 0 18px 46px rgba(48, 54, 64, 0.24), 0 8px 18px rgba(48, 54, 64, 0.14), inset 0 1px 0 rgba(255, 255, 255, 0.12);
  --floating-action-hover-shadow: 0 22px 54px rgba(48, 54, 64, 0.28), 0 10px 22px rgba(48, 54, 64, 0.16);
  --floating-action-focus-ring: rgba(110, 118, 133, 0.18);
}

/* 묶음 분리 - 진한 회색 토스트 액션 */
.order-floating-action__button[data-action-mode="split-pending"] {
  --floating-action-bg: linear-gradient(180deg, #4a4f57 0%, #353941 52%, #24272d 100%);
  --floating-action-shadow: 0 18px 46px rgba(28, 30, 34, 0.34), 0 8px 18px rgba(28, 30, 34, 0.20), inset 0 1px 0 rgba(255, 255, 255, 0.10);
  --floating-action-hover-shadow: 0 22px 54px rgba(28, 30, 34, 0.40), 0 10px 22px rgba(28, 30, 34, 0.24);
  --floating-action-focus-ring: rgba(74, 79, 87, 0.32);
}

/* 묶음 펼침 행에서 노출되는 분리 토글 버튼 */
.order-split-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 60px;
  height: 28px;
  padding: 0 12px;
  border: 1px solid #c8bfb2;
  border-radius: 999px;
  background: #ffffff;
  color: #5a4a32;
  font: inherit;
  font-size: 0.78rem;
  font-weight: 700;
  cursor: pointer;
  transition: background-color 0.16s ease, color 0.16s ease, border-color 0.16s ease, box-shadow 0.16s ease;
}

.order-split-toggle:hover {
  background: #f6efe4;
  border-color: var(--brand-brown);
  color: var(--brand-brown);
}

.order-split-toggle:focus-visible {
  outline: none;
  box-shadow: 0 0 0 3px rgba(122, 61, 18, 0.18);
}

.order-split-toggle.is-pending {
  background: #2f343c;
  border-color: #1f2229;
  color: #ffffff;
}

.order-split-toggle.is-pending:hover {
  background: #1f2229;
  color: #ffffff;
}

.order-floating-action__label {
  min-width: 0;
  text-align: left;
  line-height: 1.25;
  word-break: keep-all;
}

.order-floating-action__arrow {
  width: 40px;
  height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  color: rgba(255, 248, 241, 0.96);
  font-size: 1.18rem;
  line-height: 1;
  transform: translateX(0);
  transition: transform 0.22s ease, background-color 0.22s ease;
}

.order-floating-action__button:hover {
  box-shadow: var(--floating-action-hover-shadow);
  filter: brightness(1.03);
  transform: translateY(-1px);
}

.order-floating-action__button:hover .order-floating-action__arrow {
  transform: translateX(2px);
  background: rgba(255, 255, 255, 0.16);
}

.order-floating-action__button:focus-visible {
  outline: none;
  box-shadow: 0 0 0 4px var(--floating-action-focus-ring), var(--floating-action-shadow);
}

.order-floating-action__button:disabled {
  cursor: default;
  opacity: 0.72;
  filter: none;
  transform: none;
}

@keyframes order-floating-action-enter {
  from {
    opacity: 0;
    transform: translate3d(0, 18px, 0);
  }
  to {
    opacity: 1;
    transform: translate3d(0, 0, 0);
  }
}

@keyframes order-floating-action-exit {
  from {
    opacity: 1;
    transform: translate3d(0, 0, 0);
  }
  to {
    opacity: 0;
    transform: translate3d(0, 20px, 0);
  }
}

.order-table-shell {
  position: relative;
}

.order-table-scroll {
  overflow-x: auto;
  overflow-y: hidden;
  border: 1px solid var(--line);
  border-bottom: 0;
  background: #f8f5ef;
}

.order-table-scroll__inner {
  height: 16px;
}

.order-table-wrap {
  overflow-x: auto;
  border: 1px solid var(--line);
  background: #ffffff;
}

.order-table-scroll:not([hidden]) + .order-table-wrap {
  border-top: 0;
}

.order-table {
  width: 100%;
  min-width: 2500px;
  border-collapse: collapse;
  table-layout: fixed;
}

.order-table th,
.order-table td {
  border-bottom: 1px solid #e7e1d8;
  border-right: 1px solid #efebe6;
  padding: 13px 12px;
  vertical-align: top;
  background: #ffffff;
}

.order-table th:last-child,
.order-table td:last-child {
  border-right: 0;
}

.order-table th {
  position: sticky;
  top: 0;
  z-index: 2;
  background: #f3f1ed;
  font-size: 0.88rem;
  font-weight: 700;
  text-align: center;
  white-space: nowrap;
}

.order-table tbody tr {
  transition: background-color 0.16s ease, box-shadow 0.16s ease;
  cursor: pointer;
}

.order-row--group-start td {
  border-top: 2px solid #ded8cf;
}

.order-table tbody tr:hover td {
  background: #faf4ec;
}

.order-row.is-selected td {
  background: #f7efe4;
}

.order-row.is-selected:hover td {
  background: #f5ebde;
}

.order-row--grouped td {
  background: #f3f5f7;
  cursor: pointer;
}

.order-row--grouped:hover td {
  background: #eceff3;
}

.order-row--summary.is-expanded td {
  background: #e7ebf0;
}

.order-row--detail td {
  background: #f7f8fa;
  cursor: pointer;
}

.order-row--detail:hover td {
  background: #eef1f5;
}

.order-row--detail-representative td {
  background: #f1f4f8;
}

.order-table__col--select {
  width: 56px;
}

.order-table__col--order-code {
  width: 228px;
}

.order-table__col--platform {
  width: 116px;
}

.order-table__col--date {
  width: 132px;
}

.order-table__col--status {
  width: 156px;
}

.order-table__col--fulfillment {
  width: 120px;
}

.order-table__col--category {
  width: 300px;
}

.order-table__col--spec {
  width: 188px;
}

.order-table__col--color {
  width: 168px;
}

.order-table__col--options {
  width: 214px;
}

.order-table__col--quantity {
  width: 92px;
}

.order-table__col--amount {
  width: 126px;
}

.order-table__col--buyer {
  width: 156px;
}

.order-table__cell--buyer .order-cell__text {
  white-space: nowrap;
}

.order-table__col--receiver {
  width: 120px;
}

.order-table__col--phone {
  width: 148px;
}

.order-table__col--location {
  width: 248px;
}

.order-table__col--request {
  width: 244px;
}

.order-table__cell--select,
.order-table__cell--platform,
.order-table__cell--date,
.order-table__cell--status,
.order-table__cell--fulfillment,
.order-table__cell--quantity,
.order-table__cell--amount,
.order-table__cell--buyer,
.order-table__cell--receiver,
.order-table__cell--phone {
  text-align: center;
  vertical-align: middle;
}

.order-table__cell--select {
  padding-inline: 8px;
}

.order-check {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  position: relative;
}

.order-check input {
  position: absolute;
  inset: 0;
  margin: 0;
  opacity: 0;
  cursor: pointer;
}

.order-check span {
  width: 18px;
  height: 18px;
  border: 1px solid #cfc6bc;
  border-radius: 4px;
  background: #ffffff;
  position: relative;
}

.order-check input:focus + span {
  box-shadow: 0 0 0 3px rgba(122, 61, 18, 0.12);
  border-color: var(--brand-brown);
}

.order-check input:checked + span {
  border-color: var(--brand-brown);
  background: var(--brand-brown);
}

.order-check input:checked + span::after {
  content: '';
  position: absolute;
  left: 5px;
  top: 1px;
  width: 5px;
  height: 10px;
  border: solid #ffffff;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

.order-check--header {
  margin: 0 auto;
}

.order-platform-badge,
.order-status-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 74px;
  padding: 6px 10px;
  border-radius: 999px;
  font-size: 0.76rem;
  font-weight: 700;
}

.order-platform-badge--naver {
  background: rgba(3, 199, 90, 0.12);
  color: #047a3a;
}

.order-platform-badge--future-interior {
  background: rgba(107, 114, 128, 0.15);
  color: #4b5563;
}

.order-platform-badge--cafe24 {
  background: rgba(107, 114, 128, 0.15);
  color: #4b5563;
}

.order-platform-badge--ohouse {
  background: rgba(46, 164, 204, 0.12);
  color: #1d6f8d;
}

.order-platform-badge--burnians {
  background: rgba(82, 96, 117, 0.14);
  color: #3e4f66;
}

.order-platform-badge--bricksa {
  background: rgba(84, 92, 106, 0.14);
  color: #3f4a5d;
}

.order-platform-badge--imweb {
  background: rgba(108, 84, 214, 0.12);
  color: #4e35ae;
}

.order-platform-badge--manual {
  background: rgba(122, 61, 18, 0.11);
  color: var(--brand-brown);
}

/* 방문상담 결제상태 배지 (활성주문 목록) */
.order-pay-badge {
  display: inline-block;
  margin-top: 4px;
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  white-space: nowrap;
}
.order-pay-badge--paid { background: rgba(29, 143, 81, 0.14); color: #1d8f51; }
.order-pay-badge--unpaid { background: rgba(182, 63, 47, 0.13); color: #b63f2f; }
.order-pay-badge--pending { background: rgba(122, 61, 18, 0.1); color: #8a6a3a; }
.order-pay-badge--cancelled { background: rgba(116, 116, 116, 0.16); color: #6b6b6b; }

.order-status-select,
.order-kind-select {
  width: 100%;
  min-width: 0;
  height: 42px;
  padding: 0 12px;
  border: 1px solid #d8d1c9;
  border-radius: 999px;
  background: #ffffff;
  color: #2f2f2f;
  font: inherit;
  font-weight: 700;
}

.order-fulfillment-field {
  display: grid;
  gap: 6px;
}

.order-status-field {
  display: grid;
  gap: 4px;
}

.order-status-tracking__link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 16px;
  color: #5d6672;
  font-size: 0.7rem;
  font-weight: 600;
  line-height: 1.25;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.order-status-tracking__list {
  display: grid;
  gap: 6px;
}

.order-status-tracking__link:hover,
.order-status-tracking__link:focus-visible {
  color: #36475f;
}

.order-status-tracking__link:focus-visible {
  outline: none;
}

.order-status-tracking__link--disabled {
  color: #8e8e8e;
  text-decoration: none;
  pointer-events: none;
}

.order-status-tracking__text {
  display: inline-block;
  width: 100%;
  word-break: break-all;
}

.order-fulfillment-review-badge {
  display: inline-flex;
  width: fit-content;
  align-items: center;
  justify-content: center;
  justify-self: center;
  min-height: 24px;
  padding: 0 10px;
  border: 1px solid transparent;
  border-radius: 999px;
  background: rgba(177, 74, 74, 0.14);
  color: #8f2b2b;
  font-family: inherit;
  font-size: 0.72rem;
  font-weight: 700;
  line-height: 1.3;
  text-align: center;
  cursor: pointer;
  transition: background-color 0.14s ease, color 0.14s ease, opacity 0.14s ease;
}

.order-fulfillment-review-badge:hover,
.order-fulfillment-review-badge:focus-visible {
  background: rgba(177, 74, 74, 0.2);
  color: #782121;
}

.order-fulfillment-review-badge:focus-visible {
  outline: none;
}

.order-fulfillment-review-badge:disabled {
  opacity: 0.65;
  cursor: default;
}


.order-status-select[data-status="received"] {
  background: rgba(220, 161, 66, 0.16);
  border-color: rgba(220, 161, 66, 0.42);
  color: #8c6110;
}

.order-status-select[data-status="in-production"] {
  background: rgba(37, 139, 94, 0.14);
  border-color: rgba(37, 139, 94, 0.35);
  color: #176742;
}

.order-status-select[data-status="ready-to-ship"] {
  background: rgba(52, 111, 179, 0.14);
  border-color: rgba(52, 111, 179, 0.34);
  color: #234f87;
}

.order-status-select[data-status="shipping-started"] {
  background: rgba(97, 112, 202, 0.14);
  border-color: rgba(97, 112, 202, 0.34);
  color: #3c53a8;
}

.order-status-select[data-status="shipped"] {
  background: rgba(84, 119, 191, 0.14);
  border-color: rgba(84, 119, 191, 0.34);
  color: #2f528e;
}

.order-status-select[data-status="delivered"] {
  background: rgba(29, 137, 78, 0.16);
  border-color: rgba(29, 137, 78, 0.35);
  color: #185f3b;
}

.order-status-select[data-status="cancelled"] {
  background: rgba(177, 74, 74, 0.14);
  border-color: rgba(177, 74, 74, 0.34);
  color: #8f2b2b;
}

.order-status-select:focus,
.order-kind-select:focus {
  outline: 0;
  border-color: var(--brand-brown);
  box-shadow: 0 0 0 3px rgba(122, 61, 18, 0.12);
}

.order-status-select:disabled,
.order-kind-select:disabled {
  background: #f3f3f3;
  color: #7a7a7a;
}

.order-status-select--compact {
  min-width: 132px;
}

/* === 이전주문 패널: 배지형 dropdown(읽기전용)·압축형 표·좌측정렬 필터 === */
.panel--orders-history .order-status-select--readonly,
.panel--orders-history .order-status-select--readonly:disabled {
  cursor: default;
  opacity: 1;
  appearance: none;
  -webkit-appearance: none;
  background-image: none;
  width: 100%;
  min-width: 0;
  height: 26px;
  padding: 0 8px;
  font-size: 0.74rem;
  font-weight: 700;
  text-align: center;
  text-align-last: center;
}

.panel--orders-history .order-status-select--readonly[data-status="cancelled"] {
  background: rgba(177, 74, 74, 0.18);
  border-color: rgba(177, 74, 74, 0.42);
  color: #8f2b2b;
}

.panel--orders-history .order-status-select--readonly[data-status="delivered"] {
  background: rgba(29, 137, 78, 0.18);
  border-color: rgba(29, 137, 78, 0.42);
  color: #185f3b;
}

.panel--orders-history .order-table {
  min-width: 2160px;
}

.panel--orders-history .order-table th,
.panel--orders-history .order-table td {
  padding: 6px 8px;
  vertical-align: middle;
  font-size: 0.84rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.panel--orders-history .order-table th {
  padding-block: 8px;
  font-size: 0.82rem;
}

.panel--orders-history .order-cell__text,
.panel--orders-history .order-cell__amount {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.3;
}

.panel--orders-history .order-status-field {
  gap: 0;
}

.panel--orders-history .order-platform-badge {
  min-width: 56px;
  padding: 3px 8px;
  font-size: 0.72rem;
}

.panel--orders-history .order-table__col--order-code {
  width: 96px;
}

.panel--orders-history .order-table__col--platform {
  width: 84px;
}

.panel--orders-history .order-table__col--status {
  width: 110px;
}

.panel--orders-history .order-table__col--fulfillment {
  width: 78px;
}

.panel--orders-history .order-table__col--category {
  width: 220px;
}

.panel--orders-history .order-table__col--spec {
  width: 150px;
}

.panel--orders-history .order-table__col--color {
  width: 120px;
}

.panel--orders-history .order-table__col--options {
  width: 160px;
}

.panel--orders-history .order-table__col--quantity {
  width: 70px;
}

.panel--orders-history .order-table__col--amount {
  width: 104px;
}

.panel--orders-history .order-table__col--buyer {
  width: 152px;
}

.panel--orders-history .order-table__col--date {
  width: 116px;
}

.panel--orders-history .order-table__col--receiver {
  width: 90px;
}

.panel--orders-history .order-table__col--phone {
  width: 124px;
}

.panel--orders-history .order-table__col--location {
  width: 220px;
}

.panel--orders-history .order-table__col--request {
  width: 200px;
}

/* 헤로 영역 칩들을 우측 끝으로 더 붙이고, 칩 자체 너비를 컨텐츠 기준으로 줄임 */
.section-hero--orders.section-hero--orders-history .section-hero__summary,
.app-panel[data-panel="orders-history"] .section-hero__summary {
  flex: 0 0 auto;
  width: auto;
  min-width: 0;
  margin-left: auto;
  justify-content: flex-end;
  grid-template-columns: repeat(4, minmax(112px, max-content));
  gap: 8px;
}

.app-panel[data-panel="orders-history"] .summary-chip {
  padding: 10px 12px;
  white-space: nowrap;
}

/* 필터 + 페이지네이션 + 새로고침 버튼을 한 줄로 배치 */
.order-toolbar--single-row {
  display: block;
}

.order-toolbar--single-row .order-toolbar__filters {
  display: flex;
  align-items: flex-end;
  flex-wrap: nowrap;
  gap: 8px;
  width: 100%;
  min-width: 0;
}

.order-toolbar--single-row .order-toolbar__right {
  display: flex;
  align-items: flex-end;
  gap: 8px;
  flex: 0 0 auto;
  min-width: 0;
  width: auto;
}

/* 필터 줄 정렬: 빈 공간 없이 좌측에서 순서대로 채워 넣음 */
.app-panel[data-panel="orders-history"] .order-toolbar__filters {
  align-items: flex-end;
  flex-wrap: nowrap;
  gap: 8px;
  justify-content: flex-start;
}

.app-panel[data-panel="orders-history"] .order-toolbar__filters .toolbar-field {
  flex: 0 1 108px;
  min-width: 80px;
}

.app-panel[data-panel="orders-history"] .order-toolbar__search {
  flex: 3 1 360px;
  min-width: 280px;
  display: flex;
  align-items: flex-end;
  gap: 6px;
}

.app-panel[data-panel="orders-history"] .order-toolbar__filters .order-toolbar__search-field.toolbar-field {
  flex: 0 1 100px;
  min-width: 80px;
}

.app-panel[data-panel="orders-history"] .order-toolbar__filters .order-toolbar__search-query.toolbar-field {
  flex: 1 1 220px;
  min-width: 200px;
}

.order-cell__order-link {
  width: 100%;
  padding: 0;
  border: 0;
  background: transparent;
  text-align: left;
  cursor: pointer;
}

.order-cell__order-link:hover .order-cell__order-code,
.order-cell__order-link:focus-visible .order-cell__order-code {
  color: var(--brand-brown);
}

.order-cell__order-link:focus-visible {
  outline: none;
}

.order-cell__order-link:focus-visible .order-cell__order-code {
  text-decoration-thickness: 2px;
}

.order-cell__order-code {
  display: inline-flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
  font-size: 0.92rem;
  font-weight: 800;
  color: #2f2f2f;
  letter-spacing: 0.02em;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 2px;
}

.order-cell__order-label {
  text-decoration: inherit;
  text-underline-offset: inherit;
  word-break: break-all;
}

.order-alert-dot {
  display: inline-flex;
  width: 9px;
  height: 9px;
  border-radius: 999px;
  background: #d24d37;
  box-shadow: 0 0 0 3px rgba(210, 77, 55, 0.15);
  flex: 0 0 auto;
}

.order-alert-dot--inline {
  width: 8px;
  height: 8px;
  box-shadow: 0 0 0 2px rgba(210, 77, 55, 0.14);
}

.order-cell__submeta {
  display: block;
  margin-top: 4px;
  font-size: 0.76rem;
  color: #7c7368;
  word-break: break-word;
  line-height: 1.45;
}

.order-cell__title {
  display: block;
  font-weight: 700;
  line-height: 1.45;
}

.order-cell__meta {
  display: block;
  margin-top: 6px;
  color: #6d6d6d;
  font-size: 0.78rem;
  line-height: 1.45;
}

.order-group-toggle {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  width: 100%;
}

.order-group-expand {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 32px;
  width: 32px;
  height: 32px;
  padding: 0;
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: #6d7681;
  cursor: pointer;
  transition: background-color 0.16s ease, color 0.16s ease;
}

.order-group-expand:hover,
.order-group-expand:focus-visible {
  background: rgba(176, 184, 195, 0.2);
  color: #4f5863;
}

.order-group-expand:focus-visible {
  outline: none;
}

.order-group-expand--placeholder {
  visibility: hidden;
  pointer-events: none;
}

.order-group-expand__chevron {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 1.62rem;
  line-height: 1;
  transition: transform 0.16s ease;
}

.order-group-expand.is-expanded .order-group-expand__chevron {
  transform: rotate(90deg);
}

.order-group-toggle__body {
  min-width: 0;
}

.order-group-toggle__detail {
  flex: 1 1 auto;
  min-width: 0;
  padding: 0;
  border: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  text-align: left;
  cursor: pointer;
}

.order-group-toggle__detail:hover .order-cell__order-code,
.order-group-toggle__detail:focus-visible .order-cell__order-code {
  color: #49515b;
}

.order-group-toggle__detail:focus-visible {
  outline: none;
}

.order-group-toggle__detail:focus-visible .order-cell__order-code {
  text-decoration-thickness: 2px;
}

.order-group-toggle__badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-top: 6px;
  min-height: 24px;
  padding: 0 12px;
  border-radius: 999px;
  background: #dde3ea;
  color: #4f5863;
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  white-space: nowrap;
}

.order-cell__text {
  line-height: 1.55;
  color: #2f2f2f;
  white-space: pre-line;
  word-break: break-word;
}

.order-cell__text--muted {
  color: #777777;
}

.order-cell__amount {
  display: inline-flex;
  justify-content: center;
  width: 100%;
  font-weight: 700;
  white-space: nowrap;
}

.order-cell__detail-button {
  margin-top: 8px;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--brand-brown);
  font: inherit;
  font-size: 0.78rem;
  font-weight: 700;
  text-decoration: underline;
  text-underline-offset: 2px;
  cursor: pointer;
}

.order-detail-code {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.order-detail-code__branch {
  flex: 0 0 auto;
  margin-top: 3px;
  color: #9b8c78;
  font-size: 0.95rem;
  line-height: 1;
}

.order-detail-code__main {
  min-width: 0;
}

.order-detail-code__button {
  display: block;
  min-width: 0;
  width: 100%;
  padding: 0;
  border: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  text-align: left;
  cursor: pointer;
}

.order-detail-code__button:hover .order-detail-code__line,
.order-detail-code__button:focus-visible .order-detail-code__line {
  color: #49515b;
}

.order-detail-code__button:focus-visible {
  outline: none;
}

.order-detail-code__line {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #2f2f2f;
  font-size: 0.84rem;
  font-weight: 700;
  line-height: 1.4;
  word-break: break-word;
}

.order-detail-code__label {
  display: inline-flex;
  align-items: center;
  margin-top: 6px;
  min-height: 22px;
  padding: 0 9px;
  border-radius: 999px;
  background: #e7ebf0;
  color: #646d78;
  font-size: 0.7rem;
  font-weight: 700;
  white-space: nowrap;
}

.order-detail-code__label--representative {
  background: #dde3ea;
  color: #4f5863;
}

.order-row--detail .order-cell__meta {
  margin-top: 4px;
  font-size: 0.75rem;
}

.order-row--detail .order-cell__submeta {
  margin-top: 6px;
}

.order-row--detail .order-table__cell--status,
.order-row--detail .order-table__cell--fulfillment,
.order-row--detail .order-table__cell--platform,
.order-row--detail .order-table__cell--buyer,
.order-row--detail .order-table__cell--date,
.order-row--detail .order-table__cell--receiver,
.order-row--detail .order-table__cell--phone,
.order-row--detail .order-table__cell--location,
.order-row--detail .order-table__cell--request {
  color: #a09485;
}

.order-empty {
  margin-top: 14px;
  padding: 22px 18px;
  border: 1px dashed #c7c7c7;
  background: #fafafa;
  color: #7d7d7d;
  text-align: center;
}

.section-hero--active-orders .section-hero__summary {
  min-width: 180px;
  grid-template-columns: minmax(0, 1fr);
}

.panel__body--active-orders {
  padding: 16px 18px 20px;
}

.active-orders-toolbar {
  margin-bottom: 12px;
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 10px;
  flex-wrap: wrap;
}

.active-orders-toolbar__actions,
.active-orders-toolbar__filters {
  display: flex;
  align-items: flex-end;
  gap: 10px;
  flex-wrap: wrap;
}

.active-orders-toolbar__actions {
  margin-right: auto;
}

.active-orders-toolbar__field {
  min-width: 168px;
}

.active-order-table-wrap {
  overflow: auto;
  border: 1px solid #e3ddd5;
  background: #ffffff;
}

.active-order-table {
  width: 100%;
  min-width: 1340px;
  border-collapse: collapse;
  table-layout: fixed;
}

.active-order-table th,
.active-order-table td {
  padding: 11px 12px;
  border-bottom: 1px solid #ebe5dd;
  border-right: 1px solid #f1ece6;
  vertical-align: top;
  background: #ffffff;
}

.active-order-table th:last-child,
.active-order-table td:last-child {
  border-right: 0;
}

.active-order-table th {
  position: sticky;
  top: 0;
  z-index: 2;
  background: #f6f1ea;
  color: #4f4437;
  font-size: 0.8rem;
  font-weight: 800;
  letter-spacing: -0.01em;
  text-align: left;
  white-space: nowrap;
}

.active-order-table tbody tr:hover td {
  background: #fcf7f1;
}

.active-order-table__col--select {
  width: 52px;
}

.active-order-table__col--complete {
  width: 84px;
}

.active-order-table__col--product {
  width: 244px;
}

.active-order-table__col--customer {
  width: 164px;
}

.active-order-table__col--platform {
  width: 96px;
}

.active-order-table__col--spec {
  width: 140px;
}

.active-order-table__cell--platform {
  text-align: center;
  vertical-align: middle;
}

.active-order-table__col--color {
  width: 140px;
}

.active-order-table__col--options {
  width: 190px;
}

.active-order-table__col--contact {
  width: 116px;
}

.active-order-table__col--request {
  width: 210px;
}

.active-order-table__cell {
  font-size: 0.88rem;
}

.active-order-table__cell--group {
  background: #fffdf9;
  vertical-align: middle;
}

.active-order-table__cell .order-cell__text {
  font-size: 0.86rem;
  line-height: 1.52;
}

.active-order-table__cell--complete,
.active-order-table__cell--contact {
  text-align: center;
  vertical-align: middle;
}

.active-order-table__cell--select {
  padding-inline: 8px;
  text-align: center;
  vertical-align: middle;
}

.active-order-table__cell--request.active-order-table__cell--group {
  vertical-align: top;
}

.active-order-row--group-start td {
  border-top: 3px solid #d3c0a8;
}

.active-order-row--group-end td {
  border-bottom: 3px solid #d3c0a8;
}

.active-order-row--group-start .active-order-table__cell--group {
  border-bottom: 3px solid #d3c0a8;
}

.pack-order-row--packed td {
  background: #f3faf4;
}

.pack-order-row--packed:hover td {
  background: #edf7ef;
}

.pack-order-row--packed .active-order-table__cell--group {
  background: #f6fcf7;
}

.active-order-product {
  display: block;
  color: #2d2925;
  font-size: 0.94rem;
  font-weight: 800;
  line-height: 1.42;
  word-break: break-word;
}

.active-order-product-button {
  padding: 0;
  display: inline-flex;
  flex-direction: column;
  align-items: flex-start;
  width: 100%;
  min-height: auto;
  border: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  text-align: left;
  cursor: pointer;
}

.active-order-product-button:hover .active-order-product,
.active-order-product-button:focus-visible .active-order-product {
  color: var(--brand-brown);
}

.active-order-product-button:focus-visible {
  outline: 2px solid rgba(159, 110, 67, 0.35);
  outline-offset: 3px;
  border-radius: 8px;
}

.active-order-code {
  padding: 0;
  display: inline-flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 3px;
  width: auto;
  min-height: auto;
  border: 0;
  background: transparent;
  color: var(--brand-brown);
  font: inherit;
  font-size: 0.92rem;
  font-weight: 800;
  line-height: 1.35;
  text-align: left;
  text-decoration: underline;
  text-decoration-thickness: 1.5px;
  text-underline-offset: 3px;
  cursor: pointer;
}

.active-order-code__main {
  display: inline-flex;
  align-items: center;
}

.active-order-code__sub {
  color: #7a6d5f;
  font-size: 0.74rem;
  font-weight: 480;
  line-height: 1.35;
  letter-spacing: -0.01em;
  text-decoration: none;
}

.active-order-code:hover,
.active-order-code:focus-visible {
  color: var(--brand-brown-deep);
}

.active-order-code:hover .active-order-code__sub,
.active-order-code:focus-visible .active-order-code__sub {
  color: #6d6154;
}

.active-order-code:focus-visible {
  outline: none;
}

.active-order-complete-button,
.active-order-contact-button,
.pack-order-complete-button {
  min-width: 72px;
  min-height: 36px;
  text-decoration: none;
}

.active-order-complete-button {
  padding: 0;
  border-radius: 12px;
}

.pack-order-complete-button {
  padding: 0 10px;
  border-radius: 12px;
}

.active-order-empty {
  margin-top: 12px;
  padding: 20px 18px;
  border: 1px dashed #d4cbc0;
  background: #fbf8f4;
  color: #7a7168;
  text-align: center;
}

.section-hero__summary--delivery-waiting {
  min-width: 360px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.section-hero--delivery-installation .section-hero__summary {
  min-width: 360px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.panel__body--delivery-waiting,
.panel__body--delivery-installation,
.panel__body--accounts {
  padding: 16px 18px 20px;
}

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

.delivery-toolbar__filters,
.delivery-toolbar__actions,
.account-toolbar__actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}

.account-toolbar__hint {
  margin: 0;
  color: #6f6458;
  font-size: 0.88rem;
}

.delivery-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.56fr) minmax(360px, 1.04fr);
  gap: 16px;
}

.account-layout {
  display: grid;
  grid-template-columns: minmax(280px, 0.84fr) minmax(420px, 1.56fr);
  gap: 14px;
}

.delivery-card,
.account-card {
  border: 1px solid #ded7cd;
  background: #ffffff;
}

.delivery-card__header,
.account-card__header {
  padding: 14px 16px;
  border-bottom: 1px solid #ede8df;
  display: grid;
  gap: 4px;
}

.delivery-card__header h2,
.account-card__header h2 {
  margin: 0;
  font-size: 1.02rem;
  letter-spacing: -0.02em;
}

.delivery-card__header p {
  margin: 0;
  color: #73685d;
  font-size: 0.82rem;
  line-height: 1.45;
}

.delivery-table-wrap,
.account-table-wrap,
.account-history-wrap {
  overflow: auto;
}

.delivery-table,
.account-table,
.account-history-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 740px;
}

.delivery-table {
  min-width: 980px;
  table-layout: fixed;
}

.delivery-table th,
.delivery-table td,
.account-table th,
.account-table td,
.account-history-table th,
.account-history-table td {
  border-bottom: 1px solid #f1ece4;
  border-right: 1px solid #f4f0ea;
  padding: 10px 12px;
  font-size: 0.84rem;
  text-align: left;
  vertical-align: top;
  background: #ffffff;
}

.delivery-table th:last-child,
.delivery-table td:last-child,
.account-table th:last-child,
.account-table td:last-child,
.account-history-table th:last-child,
.account-history-table td:last-child {
  border-right: 0;
}

.delivery-table th,
.account-table th,
.account-history-table th {
  position: sticky;
  top: 0;
  z-index: 1;
  background: #f5efe8;
  color: #56483a;
  font-size: 0.78rem;
  font-weight: 800;
}

.delivery-table tbody tr.is-selected td,
.account-table tbody tr.is-selected td {
  background: #f8f2e8;
}

.delivery-table tbody tr:hover td,
.account-table tbody tr:hover td {
  background: #fbf7f2;
}

.delivery-table__col--select {
  width: 68px;
}

.delivery-table__col--code {
  width: 160px;
}

.delivery-table__col--product {
  width: 184px;
}

.delivery-table__col--contact {
  width: 120px;
}

.delivery-table__col--address {
  width: 312px;
}

.delivery-table__col--assigned {
  width: 120px;
}

.delivery-table__col--actions {
  width: 220px;
}

.delivery-table--my .delivery-table__col--actions {
  width: 168px;
}

.delivery-table--my tr[data-delivery-my-row] > td {
  vertical-align: middle;
}

.delivery-table--my .delivery-table__cell--actions {
  vertical-align: middle;
  white-space: nowrap;
}

.delivery-table__col--reorder {
  width: 72px;
}

.delivery-table__col--cancel {
  width: 96px;
}

.delivery-table__col--contact-action {
  width: 108px;
}

.delivery-table__col--actions-combo {
  width: 176px;
}

.delivery-table__col--scheduled {
  width: 156px;
}

.delivery-installation-actions-combo {
  display: flex;
  flex-direction: row;
  flex-wrap: nowrap;
  gap: 4px;
  align-items: center;
}

.delivery-installation-actions-combo .mini-button {
  flex: 1 1 0;
  min-width: 0;
  min-height: 30px;
  padding: 0 6px;
  white-space: nowrap;
}

.delivery-installation-scheduled {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.delivery-installation-scheduled__select {
  width: 100%;
  height: 34px;
  padding: 0 8px;
  border: 1px solid #d0c4b1;
  border-radius: 8px;
  background: #ffffff;
  color: #2d2417;
  font-size: 0.82rem;
  font-weight: 700;
}

.delivery-installation-scheduled__select:focus {
  outline: 2px solid rgba(122, 61, 18, 0.2);
  outline-offset: 0;
  border-color: rgba(122, 61, 18, 0.45);
}

.delivery-installation-scheduled__select[disabled] {
  background: #f5efe6;
  color: #6a5f53;
  cursor: not-allowed;
}

.delivery-installation-scheduled__select.is-pending {
  color: #8b7d6c;
  font-weight: 600;
}

.delivery-installation-scheduled__readonly {
  display: inline-flex;
  align-items: center;
  padding: 6px 10px;
  border-radius: 8px;
  background: #f5efe6;
  font-size: 0.82rem;
  font-weight: 700;
  color: #4a3f33;
}

.delivery-installation-scheduled__hint {
  font-size: 0.7rem;
  color: #8b7d6c;
}

.delivery-installation-print-modal__dialog {
  width: min(560px, calc(100vw - 32px));
}

.delivery-installation-print-modal__body {
  display: grid;
  gap: 14px;
  padding: 16px 22px;
}

.delivery-installation-print-modal__section {
  display: grid;
  gap: 8px;
  padding: 14px 16px;
  border: 1px solid #e7decd;
  border-radius: 12px;
  background: #fffaf3;
}

.delivery-installation-print-modal__section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
}

.delivery-installation-print-modal__toggle {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.92rem;
  font-weight: 800;
  color: #2d2417;
  cursor: pointer;
}

.delivery-installation-print-modal__toggle input {
  width: 18px;
  height: 18px;
  accent-color: #74461f;
}

.delivery-installation-print-modal__hint {
  margin: 0;
  font-size: 0.78rem;
  color: #6a5f53;
  line-height: 1.5;
}

.delivery-installation-print-modal__field {
  width: 100%;
}

.delivery-installation-print-modal__field[hidden] {
  display: none;
}

.delivery-installation-print-modal__manual-count {
  margin: 0;
  padding: 8px 12px;
  border-radius: 8px;
  background: #fbf7f2;
  font-size: 0.82rem;
  font-weight: 700;
  color: #4a3f33;
  text-align: center;
}

.delivery-installation-selection-bar {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 12px;
  padding: 10px 14px;
  border-radius: 12px;
  border: 1px solid #e7decd;
  background: #fffaf3;
  font-size: 0.84rem;
  color: #4a3f33;
}

.delivery-installation-selection-bar[hidden] {
  display: none;
}

.delivery-installation-selection-bar strong {
  font-size: 0.92rem;
  color: #2d2417;
}

.delivery-installation-selection-bar .toolbar-button {
  margin-left: auto;
}

.delivery-installation-table-select {
  width: 16px;
  height: 16px;
  accent-color: #74461f;
  cursor: pointer;
}

.delivery-installation-table-select[disabled] {
  cursor: not-allowed;
  opacity: 0.5;
}

.delivery-installation-print-modal__summary {
  margin: 0;
  padding: 10px 14px;
  background: #f5efe6;
  border-radius: 10px;
  font-size: 0.84rem;
  font-weight: 700;
  color: #4a3f33;
  text-align: center;
}

.delivery-table__col--buyer {
  width: 110px;
}

.delivery-table__col--driver {
  width: 120px;
}

.delivery-table__col--status {
  width: 82px;
}

.delivery-table__col--proof {
  width: 108px;
}

.delivery-table__col--zone {
  width: 96px;
}

.delivery-table--installation .delivery-table__col--address {
  width: 244px;
}

.delivery-installation-actions {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  align-items: center;
}

.delivery-table--my .delivery-installation-actions {
  min-height: 32px;
  justify-content: center;
}

.delivery-installation-actions .mini-button {
  min-width: 72px;
  min-height: 32px;
}

.delivery-table--my button[data-action="delivery-my-drag-handle"] {
  touch-action: none;
  user-select: none;
  -webkit-user-select: none;
  font-weight: 800;
  cursor: grab;
}

.delivery-table--my button[data-action="delivery-my-drag-handle"]:disabled {
  cursor: not-allowed;
}

.delivery-table--installation tr.is-drag-armed button[data-action="delivery-my-drag-handle"],
body.is-delivery-row-dragging .delivery-table--my button[data-action="delivery-my-drag-handle"] {
  cursor: grabbing;
}

body.is-delivery-row-dragging {
  cursor: grabbing;
  user-select: none;
  -webkit-user-select: none;
}

.delivery-installation-button-cell {
  text-align: center;
  white-space: nowrap;
}

.delivery-table--installation tr.is-selected td {
  background: #f4f9ff;
}

.delivery-table--installation tr.is-drag-armed td {
  background: #eef5ff;
}

.delivery-table--installation tr.is-dragging {
  opacity: 0.58;
}

.delivery-table--my tr.is-completed > td {
  background: #f1eee8;
  color: #8a7e72;
}

.delivery-table--my tr.is-completed .delivery-route-name {
  color: #75695e;
  text-decoration-color: rgba(117, 105, 94, 0.42);
}

.delivery-table--my tr.is-completed .delivery-route-status-main {
  color: #75695e;
}

.delivery-table--my tr.is-completed .mini-button {
  opacity: 0.48;
}

.delivery-table--installation tr.delivery-route-marker td,
.delivery-table--installation tr.delivery-route-marker:hover td,
.delivery-table--installation tr.delivery-route-marker.is-selected td {
  border: 1px solid #9dc8ff;
  background: linear-gradient(100deg, #4d8ff1 0%, #76c6ff 45%, #4d8ff1 100%);
  background-size: 200% 100%;
  animation: delivery-route-marker-flow 2.2s linear infinite;
  color: #ffffff;
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.01em;
  text-align: left;
  -webkit-tap-highlight-color: transparent;
}

.delivery-route-marker__icon {
  display: inline-block;
  width: 0;
  height: 0;
  margin-right: 6px;
  border-left: 5px solid transparent;
  border-right: 5px solid transparent;
  border-top: 8px solid rgba(255, 255, 255, 0.96);
  transform: translateY(1px);
}

@keyframes delivery-route-marker-flow {
  0% {
    background-position: 0% 0;
  }
  100% {
    background-position: 200% 0;
  }
}

.delivery-route-status-main {
  display: block;
  color: #1e5ca8;
  font-size: 0.82rem;
  font-weight: 800;
}

.delivery-route-status-main--waiting {
  color: #6b6258;
}

.delivery-route-status-main--completed {
  color: #217345;
}

.delivery-route-status-main--shipping {
  color: #1e65bd;
}

.delivery-route-status-sub {
  display: block;
  margin-top: 1px;
  color: #5b5045;
  font-size: 0.72rem;
}

.delivery-proof-modal__dialog {
  max-width: min(760px, calc(100vw - 28px));
}

.delivery-proof-modal__body {
  display: flex;
  justify-content: center;
  background: #111111;
}

.delivery-proof-modal__image {
  display: block;
  width: 100%;
  max-height: min(72vh, 720px);
  object-fit: contain;
  background: #111111;
}

.production-photo-modal__dialog {
  width: min(100%, 720px);
}

.production-photo-modal__body {
  display: grid;
  gap: 14px;
}

.production-photo-modal__summary {
  padding: 12px 14px;
  border: 1px solid #e6ddd1;
  border-radius: 14px;
  background: #ffffff;
}

.production-photo-modal__preview {
  display: flex;
  justify-content: center;
  min-height: 220px;
  border: 1px solid #e6ddd1;
  border-radius: 14px;
  background: #111111;
  overflow: hidden;
}

.production-photo-modal__preview img {
  display: block;
  width: 100%;
  max-height: min(48vh, 460px);
  object-fit: contain;
}

.delivery-route-list {
  margin: 0;
  padding: 8px 2px 0;
  list-style: none;
  display: grid;
  gap: 10px;
}

.delivery-route-current-marker {
  min-height: 34px;
  padding: 7px 12px;
  border-radius: 10px;
  border: 1px solid #9dc8ff;
  background: linear-gradient(90deg, #4d8ff1 0%, #76c6ff 100%);
  color: #ffffff;
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.01em;
}

.delivery-route-item {
  border: 1px solid #ddd4c8;
  background: #ffffff;
  border-radius: 12px;
  padding: 10px 12px;
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  gap: 10px;
  align-items: flex-start;
}

.delivery-route-item.is-current {
  border-color: #4f95f1;
  box-shadow: 0 0 0 2px rgba(79, 149, 241, 0.14);
  background: #f7fbff;
}

.delivery-route-item.is-dragging {
  opacity: 0.55;
}

.delivery-route-item__handle {
  width: 30px;
  height: 30px;
  border: 1px solid #c8ced6;
  border-radius: 9px;
  background: #f4f7fb;
  color: #5f6d7c;
  font-size: 1rem;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  user-select: none;
  touch-action: none;
}

.delivery-route-item.is-drag-armed .delivery-route-item__handle {
  border-color: #4f95f1;
  background: #eaf4ff;
  color: #255cad;
}

.delivery-route-main {
  min-width: 0;
  display: grid;
  gap: 6px;
}

.delivery-route-main__top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.delivery-route-name {
  border: 0;
  background: transparent;
  color: #2f241a;
  font-size: 0.94rem;
  font-weight: 800;
  padding: 0;
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.delivery-route-name:hover,
.delivery-route-name:focus-visible {
  color: #804d21;
}

.delivery-route-status {
  font-size: 0.74rem;
  font-weight: 800;
  color: #1f5aa5;
  background: #e7f2ff;
  border: 1px solid #b6d5ff;
  padding: 3px 7px;
  border-radius: 999px;
  white-space: nowrap;
}

.delivery-route-meta {
  display: grid;
  gap: 2px;
  color: #5b5148;
  font-size: 0.8rem;
}

.delivery-route-meta__product {
  color: #352b22;
  font-size: 0.9rem;
  font-weight: 700;
}

.delivery-route-meta__phone {
  color: #1761b5;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.delivery-route-meta__address {
  line-height: 1.42;
}

.delivery-route-proof {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  color: #18653c;
  background: #e7f7ed;
  border: 1px solid #addbbc;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 700;
  padding: 2px 8px;
}

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

.delivery-route-actions .mini-button {
  min-width: 72px;
}

.delivery-code {
  display: block;
  color: #3a2e22;
  font-size: 0.9rem;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.delivery-code-button {
  width: 100%;
  padding: 0;
  border: 0;
  background: transparent;
  text-align: left;
  cursor: pointer;
}

.delivery-code-button:hover .delivery-code,
.delivery-code-button:focus-visible .delivery-code {
  color: #855327;
}

.delivery-code-button:focus-visible {
  outline: 2px solid rgba(122, 61, 18, 0.24);
  outline-offset: 4px;
}

.delivery-product {
  display: block;
  font-size: 0.88rem;
  color: #2f2821;
  white-space: normal;
  line-height: 1.4;
  word-break: keep-all;
  overflow-wrap: anywhere;
}

.delivery-product--compact {
  white-space: normal;
  line-height: 1.35;
  word-break: keep-all;
  overflow-wrap: anywhere;
}

.delivery-address {
  display: block;
  color: #43392f;
  white-space: normal;
  line-height: 1.45;
  word-break: keep-all;
  overflow-wrap: anywhere;
}

.delivery-submeta {
  display: block;
  margin-top: 4px;
  color: #7a6f63;
  font-size: 0.76rem;
  line-height: 1.45;
}

.delivery-submeta--multiline {
  white-space: normal;
  word-break: keep-all;
  overflow-wrap: anywhere;
}

.delivery-submeta--compact {
  white-space: normal;
  line-height: 1.35;
  word-break: keep-all;
  overflow-wrap: anywhere;
}

.delivery-table tbody tr[data-delivery-row-key] td:not(.delivery-table__cell--select):not(.delivery-table__cell--code) {
  cursor: pointer;
}

.delivery-assigned {
  display: inline-flex;
  min-height: 24px;
  padding: 0 10px;
  border-radius: 999px;
  align-items: center;
  font-size: 0.74rem;
  font-weight: 700;
}

.delivery-assigned.is-free {
  background: #edf3ea;
  color: #3b6a41;
}

.delivery-assigned.is-mine {
  background: #e8eef7;
  color: #2e567f;
}

.delivery-assigned.is-locked {
  background: #f2ebe7;
  color: #8a5c44;
}

.delivery-empty,
.account-empty {
  padding: 16px;
  text-align: center;
  color: #776c60;
  font-size: 0.86rem;
  border-top: 1px dashed #e2dace;
}

.delivery-card--queue {
  display: flex;
  flex-direction: column;
}

.delivery-queue {
  margin: 0;
  padding: 12px 12px 0;
  list-style: none;
  display: grid;
  gap: 8px;
}

.delivery-queue-item {
  border: 1px solid #ddd4c8;
  background: #fbf8f2;
  min-height: 64px;
  padding: 8px 10px;
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
}

.delivery-queue-item.is-dragging {
  opacity: 0.55;
}

.delivery-queue-item__handle {
  width: 30px;
  height: 30px;
  border: 1px solid #c9cdd3;
  border-radius: 10px;
  background: #f3f5f7;
  color: #666f7a;
  font-size: 1rem;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: grab;
}

.delivery-queue-item__main {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.delivery-queue-item__remove {
  width: 28px;
  height: 28px;
  padding: 0;
  border: 1px solid #dacfbf;
  border-radius: 999px;
  background: #ffffff;
  color: #805a3d;
  font-size: 0.8rem;
  font-weight: 800;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: border-color 0.18s ease, background-color 0.18s ease, color 0.18s ease, transform 0.18s ease;
}

.delivery-queue-item__remove:hover {
  border-color: #c6b6a1;
  background: #faf3ea;
  color: #68452d;
}

.delivery-queue-item__remove:active {
  transform: translateY(1px);
}

.delivery-queue-item__remove:focus-visible {
  outline: 2px solid rgba(122, 61, 18, 0.2);
  outline-offset: 0;
}

.delivery-queue-item__title {
  color: #2d251d;
  font-size: 0.88rem;
  line-height: 1.3;
}

.delivery-queue-item__sub,
.delivery-queue-item__meta {
  color: #72675b;
  font-size: 0.76rem;
  line-height: 1.35;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.delivery-queue-actions {
  padding: 12px;
  margin-top: auto;
  border-top: 1px solid #eee8de;
  display: flex;
  justify-content: flex-end;
}

.delivery-detail-modal__dialog {
  width: min(100%, 1100px);
}

.delivery-detail-modal__body {
  display: grid;
  grid-template-rows: auto 1fr;
  gap: 18px;
}

.delivery-detail-summary__grid {
  display: grid;
  grid-template-columns: minmax(240px, 0.86fr) minmax(0, 1.14fr);
  gap: 12px;
}

.delivery-detail-summary__card {
  position: relative;
  padding: 16px 18px 56px;
  border: 1px solid #e3d8ca;
  border-radius: 18px;
  background: #ffffff;
}

.delivery-detail-summary__card--wide {
  min-width: 0;
}

.delivery-detail-summary__label {
  display: block;
  color: #8b755f;
  font-size: 0.78rem;
  font-weight: 700;
}

.delivery-detail-summary__value {
  display: block;
  margin-top: 6px;
  color: #2f261d;
  font-size: 1rem;
  line-height: 1.4;
  white-space: normal;
  word-break: keep-all;
  overflow-wrap: anywhere;
}

.delivery-detail-summary__text {
  margin: 6px 0 0;
  color: #6e5f50;
  font-size: 0.84rem;
  line-height: 1.55;
  white-space: normal;
  word-break: keep-all;
  overflow-wrap: anywhere;
}

.delivery-detail-summary__actions {
  position: absolute;
  right: 12px;
  bottom: 10px;
  display: flex;
  gap: 6px;
}

.delivery-detail-copy-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 36px;
  padding: 0 12px;
  border: 1px solid #d8cfc4;
  border-radius: 8px;
  background: #f7f3ef;
  color: #7a6553;
  font-size: 0.82rem;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.12s, color 0.12s, border-color 0.12s;
  -webkit-tap-highlight-color: transparent;
}

.delivery-detail-copy-btn--labeled {
  background: #fff;
  border-color: #c5b9a8;
  color: #2c231b;
}

.delivery-detail-copy-btn:hover {
  background: #ede8e1;
  border-color: #bfb4a6;
}

.delivery-detail-copy-btn.is-copied {
  background: #e6f4ea;
  border-color: #8ecfa0;
  color: #2e7d4a;
}

.delivery-detail-table-wrap {
  overflow: auto;
  min-height: 180px;
  border: 1px solid #e4dacc;
  border-radius: 18px;
  background: #ffffff;
}

.delivery-detail-table {
  width: 100%;
  min-width: 880px;
  border-collapse: collapse;
  table-layout: fixed;
}

.delivery-detail-table th,
.delivery-detail-table td {
  padding: 12px 14px;
  border-bottom: 1px solid #f0e9df;
  border-right: 1px solid #f4eee6;
  text-align: left;
  vertical-align: top;
  font-size: 0.84rem;
}

.delivery-detail-table th:last-child,
.delivery-detail-table td:last-child {
  border-right: 0;
}

.delivery-detail-table th {
  position: sticky;
  top: 0;
  z-index: 1;
  background: #f5efe8;
  color: #5c4b3b;
  font-size: 0.78rem;
  font-weight: 800;
}

.delivery-detail-table__col--line {
  width: 138px;
}

.delivery-detail-table__col--product {
  width: 228px;
}

.delivery-detail-table__col--spec {
  width: 148px;
}

.delivery-detail-table__col--color {
  width: 148px;
}

.delivery-detail-table__col--qty {
  width: 74px;
}

.delivery-detail-table__product {
  display: block;
  color: #2f241b;
  font-weight: 700;
  white-space: normal;
  word-break: keep-all;
  overflow-wrap: anywhere;
}

.delivery-detail-table__sub {
  display: block;
  margin-top: 4px;
  color: #7b6a5b;
  font-size: 0.75rem;
  line-height: 1.45;
  white-space: normal;
  word-break: keep-all;
  overflow-wrap: anywhere;
}

.delivery-detail-table__text {
  display: block;
  color: #43392f;
  line-height: 1.5;
  white-space: normal;
  word-break: keep-all;
  overflow-wrap: anywhere;
}

.delivery-detail-table__qty {
  text-align: center;
  font-weight: 700;
  white-space: nowrap;
}

@media (max-width: 900px) {
  .delivery-detail-summary__grid {
    grid-template-columns: 1fr;
  }
}

.account-card__header--detail {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
}

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

.account-detail-grid {
  display: grid;
  grid-template-columns: minmax(220px, 0.76fr) minmax(0, 1.24fr);
}

.account-detail-panel + .account-detail-panel {
  border-left: 1px solid #eee6db;
}

.account-detail-list {
  margin: 0;
  padding: 14px 16px;
  display: grid;
  gap: 8px;
}

.account-detail-list__row {
  display: grid;
  grid-template-columns: 92px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  font-size: 0.86rem;
}

.account-detail-list__row dt {
  color: #7a6d60;
}

.account-detail-list__row dd {
  margin: 0;
  color: #2f2a23;
  word-break: break-word;
}

.account-history-wrap {
  min-height: 280px;
}

.account-table {
  min-width: 560px;
}

.account-history-table {
  min-width: 600px;
}

.account-history-table th,
.account-history-table td {
  padding: 9px 10px;
  white-space: nowrap;
}

.account-history-table__col--date {
  width: 126px;
}

.account-history-table__col--time {
  width: 96px;
}

.account-history-table__col--count {
  width: 68px;
}

.account-history-table__col--duration {
  width: 96px;
}

.account-table__col--name {
  width: 124px;
}

.account-table__col--id {
  width: 124px;
}

.account-table__col--role {
  width: 108px;
}

.account-table__col--status {
  width: 90px;
}

.account-table__col--online {
  width: 72px;
}

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

.table-form-label {
  display: grid;
  gap: 6px;
  color: #5a534b;
  font-size: 0.82rem;
  font-weight: 700;
}

.table-form-hint {
  color: #8b7b6a;
  font-size: 0.74rem;
  font-weight: 600;
  line-height: 1.4;
}

.table-input--readonly {
  background: #f7f1e8;
  color: #4a3b2f;
  font-weight: 700;
}

.account-modal__dialog {
  width: min(860px, 100%);
}

.customer-contact-modal__dialog {
  width: min(100%, 640px);
}

.pack-ship-modal__dialog {
  width: min(100%, 760px);
}

.customer-contact-modal__body {
  display: grid;
  gap: 18px;
}

.pack-ship-modal__body {
  display: grid;
  gap: 14px;
}

.pack-ship-modal__notice {
  padding: 14px 16px;
  border: 1px solid #eadfce;
  border-radius: 16px;
  background: #faf6ef;
}

.pack-ship-modal__notice strong {
  display: block;
  color: #3a3025;
  font-size: 0.94rem;
}

.pack-ship-modal__notice p {
  margin: 8px 0 0;
  color: #76695c;
  font-size: 0.86rem;
  line-height: 1.5;
}

.pack-ship-modal__summary-wrap {
  border: 1px solid #e6ddd1;
  border-radius: 14px;
  background: #ffffff;
  overflow: auto;
}

.pack-ship-modal__summary-table {
  width: 100%;
  min-width: 560px;
  border-collapse: collapse;
}

.pack-ship-modal__summary-table th,
.pack-ship-modal__summary-table td {
  border-bottom: 1px solid #f0e9df;
  border-right: 1px solid #f5efe8;
  padding: 10px 12px;
  text-align: left;
  vertical-align: top;
  font-size: 0.84rem;
  line-height: 1.45;
}

.pack-ship-modal__summary-table th:last-child,
.pack-ship-modal__summary-table td:last-child {
  border-right: 0;
}

.pack-ship-modal__summary-table th {
  background: #f7f1e8;
  color: #584a3b;
  font-size: 0.78rem;
  font-weight: 800;
}

.pack-ship-modal__summary-table tbody tr:last-child td {
  border-bottom: 0;
}

.pack-ship-modal__col--name {
  width: 138px;
}

.pack-ship-modal__col--address {
  width: 300px;
}

.pack-ship-modal__col--product {
  width: auto;
}

.pack-ship-modal__form {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px 12px;
  align-items: end;
}

.pack-ship-modal__checkbox {
  grid-column: 1 / -1;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: #65574a;
  font-size: 0.82rem;
  font-weight: 700;
  line-height: 1.4;
}

.pack-ship-modal__checkbox input {
  width: 15px;
  height: 15px;
}

.pack-batch-modal__dialog {
  width: min(100%, 700px);
}

.pack-batch-modal__body {
  display: grid;
  gap: 16px;
}

.pack-batch-modal__grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.pack-batch-modal__file-field .table-input {
  padding-block: 10px;
}

.pack-batch-modal__file-name {
  margin: 0;
  color: #6c5e50;
  font-size: 0.86rem;
  line-height: 1.5;
}

.pack-review-modal__dialog {
  width: min(96vw, 1480px);
}

.pack-review-modal__body {
  display: grid;
  gap: 16px;
}

.pack-review-modal__summary {
  display: grid;
  gap: 6px;
  padding: 16px 18px;
  border: 1px solid #eadfce;
  border-radius: 18px;
  background: #faf6ef;
}

.pack-review-modal__summary strong {
  color: #362d24;
  font-size: 0.96rem;
}

.pack-review-modal__summary p {
  margin: 0;
  color: #736557;
  font-size: 0.88rem;
  line-height: 1.55;
}

.pack-review-modal__table-wrap {
  border: 1px solid #e3ddd5;
  border-radius: 16px;
  background: #ffffff;
  overflow: auto;
}

.pack-review-table {
  width: 100%;
  min-width: 1240px;
  border-collapse: collapse;
}

.pack-review-table th,
.pack-review-table td {
  padding: 10px 12px;
  border-bottom: 1px solid #efe7dd;
  border-right: 1px solid #f4eee7;
  text-align: left;
  vertical-align: top;
  font-size: 0.84rem;
  line-height: 1.45;
}

.pack-review-table th:last-child,
.pack-review-table td:last-child {
  border-right: 0;
}

.pack-review-table th {
  position: sticky;
  top: 0;
  z-index: 2;
  background: #f6f1ea;
  color: #524535;
  font-size: 0.78rem;
  font-weight: 800;
  white-space: nowrap;
}

.pack-review-table tbody tr:last-child td {
  border-bottom: 0;
}

.pack-review-table__row--warning td {
  background: #fffaf3;
}

.pack-review-table__row--error td {
  background: #fff4f4;
}

.pack-review-table__checkbox {
  text-align: center;
  vertical-align: middle;
}

.pack-review-table__input,
.pack-review-table__select,
.pack-review-table__textarea {
  width: 100%;
  min-width: 88px;
}

.pack-review-table__textarea {
  min-height: 58px;
  padding: 10px 11px;
  border: 1px solid #d8d0c5;
  border-radius: 10px;
  background: #ffffff;
  color: #23201d;
  font: inherit;
  line-height: 1.45;
  resize: vertical;
}

.pack-review-table__textarea:focus {
  outline: 2px solid rgba(122, 61, 18, 0.18);
  outline-offset: 0;
  border-color: rgba(122, 61, 18, 0.38);
}

.pack-review-table__issues {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.pack-review-table__issue {
  display: inline-flex;
  align-items: center;
  padding: 4px 8px;
  border-radius: 999px;
  background: rgba(185, 97, 44, 0.12);
  color: #8d4d1f;
  font-size: 0.76rem;
  font-weight: 700;
  white-space: nowrap;
}

.pack-review-table__issue--error {
  background: rgba(181, 73, 73, 0.14);
  color: #973838;
}

.customer-contact-modal__notice {
  padding: 16px 18px;
  border: 1px solid #eadfce;
  border-radius: 18px;
  background: #faf6ef;
}

.customer-contact-modal__notice strong {
  display: block;
  color: #3a3025;
  font-size: 0.94rem;
}

.customer-contact-modal__notice p {
  margin: 8px 0 0;
  color: #76695c;
  font-size: 0.9rem;
  line-height: 1.55;
}

.customer-contact-modal__list .order-detail-list__row {
  grid-template-columns: 112px minmax(0, 1fr);
}

.customer-contact-modal__call {
  text-decoration: none;
}

.customer-contact-modal__call[aria-disabled="true"] {
  pointer-events: none;
  opacity: 0.55;
}

.panel--customers {
  border-color: #e5ddd3;
  background: linear-gradient(180deg, rgba(252, 249, 244, 0.92) 0%, rgba(247, 242, 234, 0.88) 100%);
}

.panel__body--customers {
  display: grid;
  grid-template-columns: minmax(320px, 396px) minmax(0, 1fr);
  gap: 22px;
  align-items: start;
}

.app-panel--customer-messages {
  min-width: 0;
}

.section-hero__summary--customer-messages {
  grid-template-columns: repeat(3, minmax(128px, 1fr));
  min-width: min(100%, 470px);
}

.panel--customer-messages {
  border-color: #dfd6ca;
  background: linear-gradient(180deg, rgba(252, 249, 244, 0.94) 0%, rgba(247, 242, 234, 0.9) 100%);
}

.panel__body--customer-messages {
  display: grid;
  gap: 18px;
  padding-top: 22px;
}

.customer-message-toolbar {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: start;
  gap: 14px 18px;
}

.customer-message-toolbar__summary {
  min-width: 0;
}

.customer-message-toolbar__summary strong {
  display: block;
  color: #2f261e;
  font-size: 1rem;
}

.customer-message-toolbar__summary span {
  display: block;
  margin-top: 4px;
  color: #766a5f;
  font-size: 0.85rem;
}

.customer-message-toolbar__controls {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 12px;
}

.customer-message-toggle {
  position: relative;
  display: inline-grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: 12px;
  min-height: 72px;
  padding: 10px 16px;
  border: 1px solid #e0d6c9;
  border-radius: 0;
  background: #fffaf4;
  color: #2f261e;
  cursor: pointer;
}

.customer-message-toggle input {
  position: absolute;
  inline-size: 1px;
  block-size: 1px;
  opacity: 0;
  pointer-events: none;
}

.customer-message-toggle__track {
  position: relative;
  width: 50px;
  height: 28px;
  display: inline-block;
  border-radius: 999px;
  background: #c7b9aa;
  transition: background 0.18s ease;
}

.customer-message-toggle__thumb {
  position: absolute;
  top: 4px;
  left: 4px;
  display: block;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: #ffffff;
  box-shadow: 0 2px 5px rgba(47, 38, 30, 0.22);
  transform: translateX(0);
  transition: transform 0.18s ease;
}

.customer-message-toggle input:checked + .customer-message-toggle__track {
  background: #1f6f50;
}

.customer-message-toggle input:checked + .customer-message-toggle__track .customer-message-toggle__thumb {
  transform: translateX(22px);
}

.customer-message-toggle:has(input:focus-visible) {
  outline: 2px solid rgba(31, 111, 80, 0.28);
  outline-offset: 2px;
}

.customer-message-toggle__text {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.customer-message-toggle__text span,
.customer-message-toggle__text strong {
  display: block;
  margin: 0;
  line-height: 1.2;
}

.customer-message-toggle__text span {
  color: #5f5348;
  font-size: 0.76rem;
  font-weight: 800;
}

.customer-message-toggle__text strong {
  color: #2f261e;
  font-size: 0.9rem;
}

.customer-message-toolbar__actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 10px;
}

.customer-message-layout {
  display: grid;
  grid-template-columns: minmax(300px, 390px) minmax(0, 1fr);
  gap: 18px;
  align-items: start;
}

.customer-message-flow,
.customer-message-editor {
  min-width: 0;
}

.customer-message-flow__list {
  display: grid;
  gap: 10px;
}

.customer-message-flow-card {
  width: 100%;
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr);
  gap: 12px;
  padding: 14px;
  border: 1px solid #e0d6c9;
  background: rgba(255, 255, 255, 0.9);
  text-align: left;
  box-shadow: 0 12px 24px rgba(83, 63, 39, 0.07);
  cursor: pointer;
}

.customer-message-flow-card.is-selected {
  border-color: #b66b2e;
  background: #fff8ef;
  box-shadow: 0 16px 30px rgba(151, 91, 39, 0.14);
}

.customer-message-flow-card__step {
  width: 38px;
  height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: #24445f;
  color: #fff;
  font-weight: 800;
}

.customer-message-flow-card[data-active="false"] .customer-message-flow-card__step {
  background: #8b8176;
}

.customer-message-flow-card__body {
  min-width: 0;
}

.customer-message-flow-card__top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.customer-message-flow-card__title {
  margin: 0;
  color: #2f261e;
  font-size: 0.96rem;
  font-weight: 800;
}

.customer-message-flow-card__badge {
  flex: 0 0 auto;
  padding: 4px 8px;
  border-radius: 999px;
  background: #e8f0f5;
  color: #24445f;
  font-size: 0.72rem;
  font-weight: 800;
}

.customer-message-flow-card[data-active="false"] .customer-message-flow-card__badge {
  background: #eee8e0;
  color: #71675d;
}

.customer-message-flow-card__trigger {
  margin: 6px 0 0;
  color: #65594e;
  font-size: 0.82rem;
  line-height: 1.45;
}

.customer-message-flow-card__meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 10px;
}

.customer-message-flow-card__meta span {
  padding: 4px 7px;
  border: 1px solid #ded4c8;
  border-radius: 999px;
  color: #5f5348;
  font-size: 0.72rem;
  font-weight: 700;
}

.customer-message-editor {
  border: 1px solid #e0d6c9;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 14px 30px rgba(83, 63, 39, 0.08);
}

.customer-message-editor__empty {
  padding: 30px;
  color: #766a5f;
  font-weight: 700;
  text-align: center;
}

.customer-message-editor__form {
  display: grid;
  gap: 16px;
  padding: 20px;
}

.customer-message-editor__header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.customer-message-editor__header h2 {
  margin: 7px 0 0;
  color: #2f261e;
  font-size: 1.25rem;
  line-height: 1.25;
}

.customer-message-editor__header > span,
.customer-message-editor__badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 5px 9px;
  border-radius: 999px;
  font-size: 0.74rem;
  font-weight: 800;
}

.customer-message-editor__badge {
  background: #e8f0f5;
  color: #24445f;
}

.customer-message-editor__header > span {
  background: #f0e7dc;
  color: #6a5746;
  white-space: nowrap;
}

.customer-message-field {
  display: grid;
  gap: 8px;
}

.customer-message-field span,
.customer-message-variable-panel strong,
.customer-message-preview strong {
  color: #5c5146;
  font-size: 0.82rem;
  font-weight: 800;
}

.customer-message-template-textarea {
  min-height: 430px;
  line-height: 1.5;
  resize: vertical;
}

.customer-message-variable-panel,
.customer-message-preview {
  display: grid;
  gap: 10px;
  padding: 14px;
  border: 1px solid #e2d8cc;
  background: #fbf7f1;
}

.customer-message-variable-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.customer-message-variable-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 9px;
  border: 1px solid #d9ccbd;
  border-radius: 999px;
  background: #fff;
  color: #5d5146;
  font-size: 0.76rem;
  font-weight: 800;
}

.customer-message-variable-chip code {
  color: #24445f;
  font-family: inherit;
  font-weight: 900;
}

.customer-message-preview p,
.customer-message-preview pre {
  margin: 0;
  white-space: pre-wrap;
  word-break: keep-all;
  overflow-wrap: anywhere;
}

.customer-message-preview p {
  color: #2f261e;
  font-weight: 800;
}

.customer-message-preview pre {
  max-height: 260px;
  overflow: auto;
  color: #4f463d;
  font-family: inherit;
  font-size: 0.88rem;
  line-height: 1.55;
}

.customer-search-panel,
.customer-detail-panel {
  min-width: 0;
}

.customer-search-card,
.customer-detail-card,
.customer-history-card,
.customer-detail-empty {
  border: 1px solid #e4dbcf;
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.88);
  box-shadow: 0 18px 36px rgba(83, 63, 39, 0.08);
}

.customer-search-card {
  display: grid;
  gap: 18px;
  padding: 24px;
}

.customer-search-card__header h2,
.customer-detail-card__header h3,
.customer-history-card h3 {
  margin: 0;
}

.customer-search-card__header p:last-child {
  margin: 8px 0 0;
  color: #6f6459;
  font-size: 0.94rem;
  line-height: 1.6;
}

.customer-search-card__eyebrow,
.customer-detail-header__eyebrow {
  margin: 0 0 8px;
  color: #aa5a19;
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.customer-search-form {
  display: grid;
  grid-template-columns: minmax(0, 156px) minmax(0, 1fr);
  gap: 12px;
  align-items: end;
}

.customer-search-form__field {
  display: grid;
  gap: 8px;
}

.customer-search-form__field span,
.customer-message-form__field span {
  color: #5c5146;
  font-size: 0.82rem;
  font-weight: 700;
}

.customer-search-form__field--input {
  grid-column: span 1;
}

.customer-search-form__actions {
  grid-column: 1 / -1;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.customer-search-hint {
  margin: -4px 0 0;
  color: #776b60;
  font-size: 0.82rem;
  line-height: 1.45;
}

.customer-search-message {
  min-height: 22px;
  margin: -6px 0 0;
  font-size: 0.84rem;
  font-weight: 700;
}

.customer-search-message[data-state="success"] {
  color: #2f6f3c;
}

.customer-search-message[data-state="error"] {
  color: #b33b35;
}

.customer-search-message[data-state="warning"] {
  color: #8a5a14;
}

.customer-search-message[data-state="info"] {
  color: #6a5c50;
}

.customer-search-guide {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.customer-search-guide__item {
  padding: 14px 14px 15px;
  border: 1px solid #ece2d5;
  border-radius: 18px;
  background: linear-gradient(180deg, rgba(252, 246, 238, 0.92) 0%, rgba(255, 255, 255, 0.96) 100%);
}

.customer-search-guide__item strong {
  display: block;
  color: #352d27;
  font-size: 0.88rem;
}

.customer-search-guide__item span {
  display: block;
  margin-top: 6px;
  color: #7b6f63;
  font-size: 0.8rem;
  line-height: 1.45;
}

.customer-search-results {
  display: grid;
  gap: 12px;
}

.customer-search-results__header,
.customer-detail-card__header,
.customer-detail-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
}

.customer-search-results__header h3 {
  margin: 0;
  font-size: 1rem;
}

.customer-search-results__header span,
.customer-detail-card__header span,
.customer-detail-phone-badge {
  color: #7c6f63;
  font-size: 0.82rem;
  font-weight: 700;
}

.customer-search-results__list {
  display: grid;
  gap: 10px;
  max-height: 420px;
  overflow: auto;
  padding-right: 4px;
}

.customer-search-results__empty {
  margin: 0;
  padding: 18px 16px;
  border: 1px dashed #d4c7b8;
  border-radius: 18px;
  background: rgba(250, 247, 242, 0.92);
  color: #7d7267;
  font-size: 0.88rem;
  line-height: 1.55;
}

.customer-search-result-item {
  width: 100%;
  display: grid;
  gap: 10px;
  padding: 16px 18px;
  border: 1px solid #e8ddd1;
  border-radius: 18px;
  background: #ffffff;
  color: #2a2520;
  text-align: left;
  transition: border-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
}

.customer-search-result-item:hover,
.customer-search-result-item:focus-visible,
.customer-search-result-item.is-active {
  border-color: rgba(170, 90, 25, 0.42);
  box-shadow: 0 16px 28px rgba(170, 90, 25, 0.12);
  transform: translateY(-1px);
}

.customer-search-result-item:focus-visible {
  outline: 2px solid rgba(170, 90, 25, 0.22);
  outline-offset: 0;
}

.customer-search-result-item__top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.customer-search-result-item__name {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 10px;
  align-items: baseline;
}

.customer-search-result-item__name strong {
  font-size: 0.98rem;
}

.customer-search-result-item__name span,
.customer-search-result-item__meta,
.customer-search-result-item__note {
  color: #74695f;
  font-size: 0.84rem;
}

.customer-search-result-item__meta {
  display: grid;
  gap: 4px;
}

.customer-search-result-item__note {
  line-height: 1.5;
}

.customer-detail-empty {
  padding: 56px 28px;
  text-align: center;
}

.customer-detail-empty strong {
  display: block;
  color: #30261e;
  font-size: 1.18rem;
}

.customer-detail-empty p {
  max-width: 520px;
  margin: 12px auto 0;
  color: #7a6e61;
  line-height: 1.7;
}

.customer-detail-content {
  display: grid;
  gap: 18px;
}

.customer-detail-header {
  padding: 26px 28px;
  border: 1px solid #e4dbcf;
  border-radius: 24px;
  background: linear-gradient(135deg, rgba(253, 250, 245, 0.95) 0%, rgba(246, 239, 228, 0.88) 100%);
  box-shadow: 0 18px 34px rgba(94, 72, 47, 0.08);
}

.customer-detail-header__copy {
  min-width: 0;
}

.customer-detail-header__copy h2 {
  margin: 0;
  font-size: clamp(1.55rem, 2.2vw, 2rem);
  line-height: 1.18;
}

.customer-detail-header__subtitle {
  margin: 10px 0 0;
  color: #6d6156;
  font-size: 0.95rem;
  line-height: 1.6;
  white-space: pre-line;
}

.customer-detail-header__actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 10px;
}

.customer-detail-header__call {
  text-decoration: none;
}

.customer-detail-header__call[aria-disabled="true"] {
  pointer-events: none;
  opacity: 0.55;
}

.customer-summary-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}

.customer-summary-card {
  padding: 18px 18px 20px;
  border: 1px solid #e6dccf;
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 14px 28px rgba(89, 66, 40, 0.07);
}

.customer-summary-card span {
  display: block;
  color: #7a6f64;
  font-size: 0.8rem;
  font-weight: 700;
}

.customer-summary-card strong {
  display: block;
  margin-top: 10px;
  color: #1f1a15;
  font-size: clamp(1.12rem, 1.8vw, 1.45rem);
  line-height: 1.28;
}

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

.customer-detail-card,
.customer-history-card {
  padding: 22px 22px 24px;
}

.customer-history-table-wrap {
  overflow: auto;
  margin-top: 16px;
}

.customer-history-table {
  width: 100%;
  min-width: 1040px;
  border-collapse: collapse;
  table-layout: fixed;
}

.customer-history-table th,
.customer-history-table td {
  padding: 13px 12px;
  border-bottom: 1px solid #eee5db;
  vertical-align: top;
  text-align: left;
}

.customer-history-table th {
  color: #735f4e;
  font-size: 0.8rem;
  font-weight: 800;
  background: rgba(250, 246, 240, 0.94);
}

.customer-history-table td {
  color: #2d2721;
  font-size: 0.9rem;
  line-height: 1.55;
}

.customer-history-table tbody tr:hover td {
  background: rgba(250, 242, 232, 0.75);
}

.customer-history-table__col--ordered-at {
  width: 108px;
}

.customer-history-table__col--erp {
  width: 138px;
}

.customer-history-table__col--platform {
  width: 96px;
}

.customer-history-table__col--products {
  width: 260px;
}

.customer-history-table__col--amount {
  width: 124px;
}

.customer-history-table__col--status {
  width: 102px;
}

.customer-history-product-list {
  display: grid;
  gap: 6px;
}

.customer-history-product-line strong {
  display: block;
  font-size: 0.9rem;
}

.customer-history-product-line span {
  display: block;
  margin-top: 2px;
  color: #76685d;
  font-size: 0.8rem;
}

.customer-history-table__muted {
  color: #8a7f74;
}

.customer-modal__scrim {
  background: rgba(241, 236, 228, 0.42);
  backdrop-filter: blur(12px);
}

.customer-picker-modal__dialog {
  width: min(100%, 760px);
}

.customer-picker-modal__body,
.customer-message-modal__body {
  display: grid;
  gap: 18px;
}

.customer-picker-modal__notice {
  padding: 18px 20px;
  border: 1px solid #e6d9ca;
  border-radius: 18px;
  background: linear-gradient(180deg, rgba(251, 246, 238, 0.92) 0%, rgba(255, 255, 255, 0.96) 100%);
}

.customer-picker-modal__notice strong {
  display: block;
  color: #372d25;
  font-size: 0.96rem;
}

.customer-picker-modal__notice p {
  margin: 8px 0 0;
  color: #76695c;
  line-height: 1.55;
}

.customer-picker-list {
  display: grid;
  gap: 12px;
}

.customer-picker-item {
  width: 100%;
  display: grid;
  gap: 10px;
  padding: 18px 20px;
  border: 1px solid #e7dccc;
  border-radius: 20px;
  background: #ffffff;
  color: #2d2720;
  text-align: left;
  transition: border-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
}

.customer-picker-item:hover,
.customer-picker-item:focus-visible {
  border-color: rgba(170, 90, 25, 0.42);
  box-shadow: 0 18px 32px rgba(170, 90, 25, 0.12);
  transform: translateY(-1px);
}

.customer-picker-item:focus-visible {
  outline: 2px solid rgba(170, 90, 25, 0.2);
  outline-offset: 0;
}

.customer-picker-item__top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.customer-picker-item__title strong {
  display: block;
  font-size: 1rem;
}

.customer-picker-item__title span,
.customer-picker-item__meta,
.customer-picker-item__hint {
  color: #756a60;
  font-size: 0.84rem;
}

.customer-picker-item__meta {
  display: grid;
  gap: 4px;
}

.customer-picker-item__hint {
  line-height: 1.55;
}

.customer-message-modal__dialog {
  width: min(100%, 760px);
}

.customer-message-form {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px 16px;
}

.customer-message-form__field {
  display: grid;
  gap: 8px;
}

.customer-message-form__field--full {
  grid-column: 1 / -1;
}

.customer-message-form__textarea {
  min-height: 220px;
}

body.is-modal-open {
  overflow: hidden;
}

@media (max-width: 1240px) {
  .panel__body--customers {
    grid-template-columns: minmax(280px, 360px) minmax(0, 1fr);
  }

  .customer-message-layout {
    grid-template-columns: minmax(280px, 340px) minmax(0, 1fr);
  }

  .customer-summary-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .customer-detail-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}

@media (max-width: 840px) {
  .panel__body--customers {
    grid-template-columns: minmax(0, 1fr);
  }

  .customer-message-layout,
  .section-hero__summary--customer-messages {
    grid-template-columns: minmax(0, 1fr);
    min-width: 0;
  }

  .customer-message-toolbar {
    grid-template-columns: minmax(0, 1fr);
    align-items: stretch;
  }

  .customer-message-toolbar__controls,
  .customer-message-toggle,
  .customer-message-toolbar__actions,
  .customer-message-toolbar__actions .toolbar-button {
    width: 100%;
  }

  .customer-message-toolbar__controls {
    justify-content: stretch;
  }

  .customer-search-form,
  .customer-message-form,
  .customer-search-guide {
    grid-template-columns: minmax(0, 1fr);
  }

  .customer-detail-header,
  .customer-search-results__header,
  .customer-detail-card__header,
  .customer-picker-item__top,
  .customer-search-result-item__top {
    flex-direction: column;
  }

  .customer-detail-header__actions {
    width: 100%;
    justify-content: stretch;
  }

  .customer-detail-header__actions .toolbar-button {
    flex: 1 1 auto;
    justify-content: center;
  }

  .customer-summary-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .customer-history-table {
    min-width: 860px;
  }
}

.order-detail-modal {
  position: fixed;
  inset: 0;
  z-index: 70;
  display: grid;
  place-items: center;
  padding: 24px;
}

.order-detail-modal[hidden] {
  display: none;
}

.order-detail-modal__scrim {
  position: absolute;
  inset: 0;
  border: 0;
  background: rgba(12, 10, 8, 0.46);
}

.order-detail-modal__dialog {
  position: relative;
  width: min(1180px, 100%);
  max-height: min(88vh, 940px);
  display: flex;
  flex-direction: column;
  gap: 18px;
  padding: 22px;
  border-radius: 22px;
  background: #ffffff;
  box-shadow: 0 28px 60px rgba(0, 0, 0, 0.22);
  overflow: hidden;
}

.order-detail-modal__header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.order-detail-modal__copy {
  display: grid;
  gap: 6px;
  min-width: 0;
}

.order-detail-modal__eyebrow {
  margin: 0;
  color: #7a6f63;
  font-size: 0.86rem;
  font-weight: 600;
}

.order-detail-modal__title {
  margin: 0;
  font-size: 1.38rem;
  line-height: 1.25;
}

.order-detail-modal__header-actions {
  display: flex;
  align-items: flex-start;
  gap: 12px;
}

.order-detail-modal__header-actions .toolbar-button {
  height: 40px;
}

.order-detail-modal__close {
  width: 42px;
  height: 42px;
  border: 1px solid #d3ccc2;
  border-radius: 999px;
  background: #ffffff;
  color: #2a2a2a;
  font-size: 1.8rem;
  line-height: 1;
}


.order-detail-modal__stage-track {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  padding: 14px 18px;
  border: 1px solid #e9dfd2;
  border-radius: 18px;
  background: #faf7f2;
}

.order-stage-chip {
  min-height: 38px;
  padding: 0 14px;
  border: 1px solid #d6cfc5;
  border-radius: 999px;
  background: #ffffff;
  color: #3a342f;
  font: inherit;
  font-weight: 700;
  white-space: nowrap;
}

.order-stage-chip.is-active {
  border-color: rgba(122, 61, 18, 0.35);
  background: rgba(122, 61, 18, 0.12);
  color: var(--brand-brown);
}

.order-stage-chip--danger {
  color: #8f2b2b;
}

.order-stage-chip--danger.is-active {
  border-color: rgba(177, 74, 74, 0.36);
  background: rgba(177, 74, 74, 0.12);
  color: #8f2b2b;
}

.order-stage-track__separator,
.order-stage-track__divider {
  color: #8c8175;
  font-weight: 700;
}

.order-detail-modal__group {
  padding: 16px 18px;
  border: 1px solid #e9dfd2;
  border-radius: 18px;
  background: #faf7f2;
}

.order-detail-modal__group-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.order-detail-modal__group-header strong {
  display: block;
  font-size: 1rem;
}

.order-detail-modal__group-header p {
  margin: 6px 0 0;
  color: #7b7064;
  font-size: 0.84rem;
}

.order-detail-modal__group-list {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  padding-bottom: 4px;
}

.order-detail-group-item {
  min-width: 180px;
  padding: 12px 14px;
  border: 1px solid #ddd3c8;
  border-radius: 14px;
  background: #ffffff;
  color: #2f2f2f;
  text-align: left;
}

.order-detail-group-item strong {
  display: block;
  font-size: 0.82rem;
  color: #7d7265;
}

.order-detail-group-item span {
  display: block;
  margin-top: 4px;
  font-size: 0.92rem;
  font-weight: 700;
  line-height: 1.4;
}

.order-detail-group-item.is-active {
  border-color: rgba(122, 61, 18, 0.38);
  background: #f6efe7;
  box-shadow: inset 0 0 0 1px rgba(122, 61, 18, 0.15);
}

.order-detail-modal__body {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 18px;
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  overflow-x: hidden;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  padding-right: 4px;
}

.order-detail-panel--editor {
  grid-column: 1 / -1;
}

.order-detail-panel__card {
  padding: 18px;
  border: 1px solid #e7e0d7;
  border-radius: 18px;
  background: #fbfaf8;
}

.order-detail-panel__heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 14px;
}

.order-detail-panel__heading h3 {
  margin: 0;
  font-size: 1rem;
}

.order-detail-panel__heading span {
  color: #7b6d5c;
  font-size: 0.8rem;
  font-weight: 700;
}

.order-detail-panel__actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  margin-left: auto;
}

.order-detail-panel__actions .toolbar-button {
  min-height: 36px;
  padding-inline: 12px;
  font-size: 0.86rem;
}

.order-detail-list {
  display: grid;
  gap: 0;
}

.order-detail-list__row {
  display: grid;
  grid-template-columns: 124px minmax(0, 1fr);
  gap: 12px;
  padding: 10px 0;
  border-bottom: 1px solid #ece7df;
}

.order-detail-list__row:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}

.order-detail-list__row:first-child {
  padding-top: 0;
}

.order-detail-list__row dt {
  color: #7a7065;
  font-size: 0.84rem;
  font-weight: 700;
}

.order-detail-list__value {
  margin: 0;
  color: #2f2f2f;
  font-size: 0.92rem;
  line-height: 1.6;
  white-space: pre-line;
  word-break: break-word;
}

.order-detail-list__value--muted {
  color: #8c847c;
}

.order-detail-edit-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px 14px;
}

.order-detail-edit-field {
  display: grid;
  gap: 6px;
}

.order-detail-edit-field > span {
  color: #6f6357;
  font-size: 0.82rem;
  font-weight: 700;
}

.order-detail-edit-field--full {
  grid-column: 1 / -1;
}

.order-detail-edit-textarea {
  width: 100%;
  min-height: 84px;
  padding: 10px 12px;
  border: 1px solid #d0d0d0;
  border-radius: 12px;
  background: #ffffff;
  color: #222222;
  font-size: 0.9rem;
  line-height: 1.45;
  resize: vertical;
}

.order-detail-edit-textarea:focus {
  outline: 2px solid rgba(122, 61, 18, 0.2);
  outline-offset: 0;
  border-color: rgba(122, 61, 18, 0.45);
}

.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(0, 0, 0, 0.42);
}

.modal-card {
  width: min(100%, 460px);
  padding: 24px;
  border: 1px solid #dadada;
  background: #ffffff;
  box-shadow: 0 24px 56px rgba(0, 0, 0, 0.18);
}

.modal-card__title {
  margin: 0;
  font-size: 1.4rem;
  line-height: 1.2;
}

.modal-card__description {
  margin: 12px 0 0;
  color: #666666;
  font-size: 0.98rem;
}

.modal-card__actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 20px;
}

@media (max-width: 1280px) {
  .order-bulk-bar {
    flex-direction: column;
    align-items: stretch;
  }

  .order-bulk-bar__actions {
    justify-content: flex-start;
  }
}

@media (max-width: 1160px) {
  .section-hero,
  .product-toolbar,
  .order-toolbar {
    flex-direction: column;
  }

  .section-hero__summary {
    width: 100%;
    min-width: 0;
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .section-hero--orders .section-hero__summary {
    align-self: stretch;
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }
}

@media (max-width: 900px) {
  .section-hero__summary {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .section-hero--orders .section-hero__summary {
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }

  .product-toolbar__filters,
  .order-toolbar__filters,
  .order-toolbar__meta,
  .order-toolbar__top-row,
  .order-toolbar__right,
  .order-toolbar__filters-row {
    width: 100%;
  }

  .order-toolbar__top-row {
    flex-wrap: wrap;
  }

  .order-toolbar__right {
    min-width: 0;
  }

  .order-toolbar__pagination,
  .order-pagination {
    justify-content: flex-start;
  }

  .order-toolbar__search {
    min-width: 0;
  }

  .toolbar-field {
    flex: 1 1 200px;
  }
}

@media (max-width: 620px) {
  .section-hero {
    padding-inline: 0;
  }

  .section-hero__summary {
    grid-template-columns: 1fr;
  }

  .summary-chip {
    min-width: 0;
  }

  .toolbar-button,
  .page-button {
    width: 100%;
  }

  .product-toolbar__actions,
  .product-toolbar__filters,
  .order-toolbar__actions,
  .order-toolbar__filters,
  .order-toolbar__meta,
  .order-toolbar__top-row,
  .order-toolbar__right,
  .order-toolbar__filters-row,
  .order-toolbar__pagination,
  .order-pagination {
    width: 100%;
  }

  .order-toolbar__right {
    flex-wrap: wrap;
  }

  .toolbar-icon-button {
    margin-left: auto;
  }

  .order-toolbar__search {
    width: 100%;
    flex-wrap: wrap;
  }

  .order-toolbar__search-field,
  .order-toolbar__search-query {
    flex: 1 1 100%;
  }

  .toolbar-field {
    min-width: 0;
    width: 100%;
  }
}

@media (max-width: 980px) {
  .order-detail-modal {
    padding: 16px;
  }

  .order-detail-modal__dialog {
    width: 100%;
    max-height: 92vh;
    padding: 18px;
  }

  .order-detail-modal__header {
    flex-direction: column;
  }

  .order-detail-modal__header-actions {
    width: 100%;
    justify-content: space-between;
  }

  .order-detail-modal__header-actions .toolbar-field {
    min-width: 0;
    flex: 1 1 auto;
  }

  .order-detail-modal__body {
    grid-template-columns: 1fr;
  }


  .order-detail-modal__stage-track {
    gap: 8px;
  }
}

@media (max-width: 720px) {
  .order-detail-list__row {
    grid-template-columns: 1fr;
    gap: 6px;
  }

  .order-detail-edit-grid {
    grid-template-columns: 1fr;
  }

  .order-detail-modal__group-list {
    flex-direction: column;
  }

  .order-detail-group-item {
    min-width: 0;
    width: 100%;
  }
}

/* ------------------------------
   Product table refinement / option modal
------------------------------ */

.product-table {
  min-width: 1100px;
}

.product-table__col--code {
  width: 9%;
}

.product-table__col--category {
  width: 11%;
}

.product-table__col--name {
  width: 16%;
}

.product-table__col--image {
  width: 14%;
}

.product-table__col--price {
  width: 11%;
}

.product-table__col--production {
  width: 10%;
}

.product-table__col--option {
  width: 10.5%;
}

.product-table__col--mapping {
  width: 8.5%;
}

.product-table__col--active {
  width: 4.5%;
}

.product-table__col--actions {
  width: 7.5%;
}

.product-table__cell--production,
.product-table__cell--option,
.product-table__cell--mapping,
.product-table__cell--active,
.product-table th:nth-child(6),
.product-table th:nth-child(7),
.product-table th:nth-child(8),
.product-table th:nth-child(9) {
  text-align: center;
}

.product-table__cell--production,
.product-table__cell--option,
.product-table__cell--mapping,
.product-table__cell--active {
  vertical-align: middle;
}

.product-table__cell--production .table-select,
.product-table__cell--option .mini-button,
.product-table__cell--option .option-count,
.product-table__cell--option .process-count,
.product-table__cell--mapping .mini-button,
.product-table__cell--mapping .mapping-count {
  margin-inline: auto;
}

.product-table__cell--actions {
  vertical-align: middle;
}

.product-table__cell--price {
  vertical-align: middle;
}

.product-table__cell--price .table-input,
.product-table__cell--name .table-input,
.product-table__cell--category .table-select,
.product-table__cell--production .table-select {
  height: 46px;
}

.toggle-check--compact {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding-top: 0;
  min-height: 24px;
}

.toggle-check--compact input {
  margin: 0;
}

.option-count,
.mapping-count {
  margin-top: 10px;
  font-size: 0.78rem;
  color: #6d6d6d;
}

.process-count {
  display: block;
  margin-top: 4px;
  font-size: 0.74rem;
  color: #5f6d61;
  text-align: center;
}

.process-count.is-muted {
  color: #8e8e8e;
}

.product-cell-buttons {
  display: grid;
  justify-items: center;
  gap: 8px;
}

.product-cell-buttons__row {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

/* 톱니 설정 모달 — 노출설정 토글 */
.ps-toggle {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 11px 2px;
  cursor: pointer;
}
.ps-toggle__label {
  display: flex;
  flex-direction: column;
  font-size: 14px;
  font-weight: 600;
  color: #1a1815;
}
.ps-toggle__label small {
  margin-top: 2px;
  font-size: 12px;
  font-weight: 400;
  color: #9a958c;
}
/* 레버형 토글 스위치 */
.ps-switch {
  appearance: none;
  -webkit-appearance: none;
  flex: none;
  position: relative;
  width: 44px;
  height: 24px;
  border-radius: 999px;
  background: #d6d2ca;
  cursor: pointer;
  transition: background-color 0.2s ease;
}
.ps-switch::after {
  content: "";
  position: absolute;
  top: 2px;
  left: 2px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.25);
  transition: transform 0.2s ease;
}
.ps-switch:checked {
  background: #74461f;
}
.ps-switch:checked::after {
  transform: translateX(20px);
}
.ps-switch:focus-visible {
  outline: 2px solid #74461f;
  outline-offset: 2px;
}
.ps-soon {
  opacity: 0.5;
}
/* 톱니 설정 모달 — 폭 축소 */
[data-product-settings-modal] .sf-modal__dialog {
  width: min(480px, 96vw);
}

/* HOVER 이미지 + 크롭 */
.ps-hover {
  margin-top: 8px;
}
.ps-hover__thumb {
  width: 96px;
  aspect-ratio: 4 / 5;
  overflow: hidden;
  border: 1px solid #e6e3dc;
  background: #f4f4f4;
}
.ps-hover__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.ps-hover__actions {
  display: flex;
  gap: 8px;
  margin-top: 8px;
}
.sf-modal--crop .sf-modal__dialog {
  width: min(640px, 96vw);
}
.ps-crop-stage {
  max-height: 56vh;
}
.ps-crop-stage img {
  display: block;
  max-width: 100%;
}

.mapping-count {
  display: block;
  white-space: normal;
  line-height: 1.4;
}

.product-image-box {
  margin-inline: auto;
}

.product-image-actions {
  justify-content: center;
}

.product-process-modal__dialog {
  width: min(100%, 760px);
}

.product-process-modal__body {
  display: grid;
  gap: 14px;
}

.product-process-modal__notice {
  display: grid;
  gap: 6px;
  padding: 14px 16px;
  border: 1px solid #e3dfd7;
  border-radius: 12px;
  background: #faf8f3;
}

.product-process-modal__notice strong {
  color: #35291d;
  font-size: 0.95rem;
}

.product-process-modal__notice p {
  margin: 0;
  color: #5d5244;
  font-size: 0.82rem;
  line-height: 1.45;
}

.product-process-modal__list {
  display: grid;
  gap: 4px;
}

.product-process-flow {
  display: grid;
  gap: 4px;
}

.product-process-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
  align-items: center;
}

.product-process-arrow {
  justify-self: center;
  color: #7c6a58;
  font-size: 1rem;
  line-height: 1;
}

.product-process-modal__add {
  justify-self: flex-start;
}

.product-process-modal__empty {
  margin: 0;
}

.option-modal {
  position: fixed;
  inset: 0;
  z-index: 90;
  display: grid;
  place-items: center;
  padding: 24px;
}

.option-modal[hidden] {
  display: none;
}

.option-modal__scrim {
  position: absolute;
  inset: 0;
  border: 0;
  background: rgba(0, 0, 0, 0.45);
}

.option-modal__dialog {
  position: relative;
  z-index: 1;
  width: min(100%, 1280px);
  max-height: calc(100vh - 48px);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid #d9d9d9;
  border-radius: 20px;
  background: #ffffff;
  box-shadow: 0 32px 72px rgba(0, 0, 0, 0.2);
}

.option-modal__header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  padding: 28px 28px 22px;
  border-bottom: 1px solid #ececec;
}

.option-modal__copy {
  min-width: 0;
}

.option-modal__title {
  margin: 0;
  font-size: clamp(1.6rem, 2.4vw, 2.1rem);
  line-height: 1.2;
}

.option-modal__subtitle {
  margin: 10px 0 0;
  color: #666666;
  font-size: 1rem;
}

.option-modal__close {
  width: 44px;
  height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  background: transparent;
  color: #333333;
  font-size: 2.1rem;
  line-height: 1;
}

.option-modal__tabs {
  display: flex;
  gap: 8px;
  padding: 18px 28px 0;
  border-bottom: 1px solid #efefef;
  background: #ffffff;
}

.option-modal__tab {
  min-height: 46px;
  padding: 0 18px;
  border: 1px solid transparent;
  border-bottom: 0;
  border-radius: 14px 14px 0 0;
  background: transparent;
  color: #666666;
  font-size: 0.96rem;
  font-weight: 700;
}

.option-modal__tab.is-active {
  border-color: #dddddd;
  background: #f8f8f8;
  color: #111111;
}

.option-modal__body {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  padding: 24px 28px 28px;
  background: #fbfbfb;
}

.option-modal__panel {
  display: none;
}

.option-modal__panel.is-active {
  display: block;
}

.option-modal__section {
  margin-bottom: 18px;
}

.option-modal__section--top {
  padding: 18px 20px;
  border: 1px solid #e3e3e3;
  border-radius: 18px;
  background: #ffffff;
}

.option-preset-picker,
.option-modal__section--preset-top {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.option-preset-picker__field,
.option-preset-editor__field {
  display: grid;
  gap: 8px;
  min-width: min(420px, 100%);
  flex: 1 1 420px;
}

.option-preset-picker__field span,
.option-preset-editor__field span {
  font-size: 0.88rem;
  font-weight: 700;
  color: #4f4f4f;
}

.option-preset-picker__actions,
.option-preset-editor__actions,
.option-modal__footer-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}

.option-editor {
  display: grid;
  gap: 18px;
}

.option-editor-empty {
  padding: 22px 20px;
  border: 1px dashed #cfcfcf;
  border-radius: 18px;
  background: #ffffff;
  color: #777777;
  text-align: center;
}

.option-group-card {
  padding: 18px 18px 20px;
  border: 1px solid #dddddd;
  border-radius: 20px;
  background: #ffffff;
}

.option-group-card__header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.option-group-card__header-main {
  flex: 1 1 auto;
  min-width: 0;
}

.option-group-card__index {
  display: inline-flex;
  margin-bottom: 10px;
  padding: 5px 10px;
  border-radius: 999px;
  background: rgba(122, 61, 18, 0.1);
  color: var(--brand-brown);
  font-size: 0.78rem;
  font-weight: 700;
}

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

.option-group-card__field span {
  font-size: 0.9rem;
  font-weight: 700;
  color: #4f4f4f;
}

.option-group-card__controls {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px 18px;
  margin-top: 16px;
}

.option-check {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 40px;
  padding: 0 14px;
  border: 1px solid #e2e2e2;
  border-radius: 999px;
  background: #ffffff;
  font-size: 0.9rem;
  font-weight: 700;
}

.option-check input {
  width: 16px;
  height: 16px;
}

.option-inline-field {
  display: inline-grid;
  gap: 6px;
  min-width: 140px;
  font-size: 0.84rem;
  font-weight: 700;
  color: #5b5b5b;
}

.table-input--compact {
  width: 112px;
  text-align: center;
}

.option-group-card__items {
  margin-top: 18px;
  padding-top: 18px;
  border-top: 1px solid #ededed;
}

.option-group-card__items-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 220px 94px;
  gap: 12px;
  margin-bottom: 10px;
  color: #6d6d6d;
  font-size: 0.84rem;
  font-weight: 700;
}

.option-group-card__items-list {
  display: grid;
  gap: 10px;
  margin-bottom: 12px;
}

.option-item-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 220px 94px;
  gap: 12px;
}

.preset-library {
  margin-bottom: 18px;
  padding: 18px 20px;
  border: 1px solid #e3e3e3;
  border-radius: 18px;
  background: #ffffff;
}

.preset-library__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}

.preset-library__header strong {
  font-size: 1rem;
}

.preset-library__header span {
  color: #6c6c6c;
  font-size: 0.88rem;
  font-weight: 700;
}

.preset-library__list {
  display: grid;
  gap: 10px;
}

.preset-list__empty {
  color: #787878;
  font-size: 0.92rem;
}

.preset-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 14px 16px;
  border: 1px solid #e7e7e7;
  border-radius: 14px;
  background: #fcfcfc;
}

.preset-card.is-active {
  border-color: rgba(122, 61, 18, 0.32);
  background: #f9f2ea;
}

.preset-card__main {
  min-width: 0;
}

.preset-card__name {
  display: block;
  font-size: 0.96rem;
  line-height: 1.35;
}

.preset-card__meta {
  display: block;
  margin-top: 4px;
  color: #6a6a6a;
  font-size: 0.82rem;
}

.preset-card__actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}

.option-modal__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 18px 28px 24px;
  border-top: 1px solid #ececec;
  background: #ffffff;
}

.mapping-count.is-linked {
  color: var(--brand-brown);
  font-weight: 700;
}

.mapping-modal__dialog {
  width: min(100%, 1120px);
}

.mapping-modal__body {
  display: grid;
  gap: 18px;
}

.mapping-modal__toolbar {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  padding: 18px 20px;
  border: 1px solid #e3e3e3;
  border-radius: 18px;
  background: #ffffff;
}

.mapping-modal__summary {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
  color: #666666;
  font-size: 0.92rem;
  font-weight: 700;
}

.mapping-modal__summary strong {
  color: #111111;
}

.mapping-modal__notice {
  padding: 14px 16px;
  border: 1px solid rgba(122, 61, 18, 0.14);
  border-radius: 16px;
  background: rgba(122, 61, 18, 0.05);
  color: #6b543f;
  font-size: 0.9rem;
  line-height: 1.55;
}

.mapping-modal__list {
  display: grid;
  gap: 12px;
}

.mapping-candidate {
  display: grid;
  grid-template-columns: 22px minmax(0, 1fr);
  gap: 14px;
  align-items: flex-start;
  padding: 16px 18px;
  border: 1px solid #e3e3e3;
  border-radius: 18px;
  background: #ffffff;
  cursor: pointer;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.mapping-candidate:hover {
  border-color: rgba(122, 61, 18, 0.24);
  box-shadow: 0 12px 28px rgba(17, 17, 17, 0.06);
}

.mapping-candidate.is-selected {
  border-color: rgba(122, 61, 18, 0.36);
  background: #f9f2ea;
}

.mapping-candidate.is-conflicted {
  border-color: #e5d7c7;
}

.mapping-candidate__check {
  width: 18px;
  height: 18px;
  margin: 4px 0 0;
}

.mapping-candidate__body {
  min-width: 0;
}

.mapping-candidate__heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.mapping-candidate__name {
  font-size: 0.98rem;
  line-height: 1.45;
}

.mapping-candidate__chips {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.mapping-chip {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 10px;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 700;
  white-space: nowrap;
}

.mapping-chip--platform {
  background: #f0f2f5;
  color: #49525c;
}

.mapping-chip--selected {
  background: rgba(122, 61, 18, 0.12);
  color: var(--brand-brown);
}

.mapping-chip--warning {
  background: rgba(176, 92, 23, 0.12);
  color: #9b5a18;
}

.mapping-chip--muted {
  background: #f5f5f5;
  color: #7a7a7a;
}

.mapping-candidate__meta,
.mapping-candidate__keys {
  margin-top: 8px;
  color: #666666;
  font-size: 0.86rem;
  line-height: 1.55;
}

.order-sync-settings-modal__dialog {
  width: min(100%, 920px);
}

.order-sync-settings-modal__body {
  display: grid;
  gap: 12px;
}

.order-sync-settings-modal__section {
  padding: 16px 18px;
  border: 1px solid #e3e3e3;
  border-radius: 14px;
  background: #ffffff;
}

.order-sync-settings-modal__section--guide {
  padding-top: 12px;
  padding-bottom: 12px;
}

.order-sync-settings-modal__guide {
  margin: 0;
  color: #55645a;
  font-size: 0.85rem;
  line-height: 1.45;
}

.order-sync-settings-table-wrap {
  overflow-x: auto;
}

.order-sync-settings-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 680px;
}

.order-sync-settings-table th,
.order-sync-settings-table td {
  padding: 10px 8px;
  border-bottom: 1px solid #ededed;
  text-align: left;
  font-size: 0.86rem;
  line-height: 1.4;
  vertical-align: middle;
}

.order-sync-settings-table thead th {
  padding-top: 8px;
  padding-bottom: 8px;
  color: #55655a;
  font-size: 0.76rem;
  font-weight: 650;
  letter-spacing: 0.03em;
}

.order-sync-settings-table tbody th {
  width: 120px;
  color: #202f26;
  font-weight: 620;
}

.order-sync-settings-table tbody tr:last-child th,
.order-sync-settings-table tbody tr:last-child td {
  border-bottom: 0;
}

.order-sync-mode-badge {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 0 8px;
  border-radius: 8px;
  background: rgba(31, 126, 77, 0.14);
  color: #0f7c35;
  font-size: 0.72rem;
  font-weight: 620;
}

.order-sync-mode-badge--manual {
  background: rgba(103, 118, 133, 0.14);
  color: #4f6072;
}

.order-sync-manual-text {
  color: #768475;
  font-size: 0.8rem;
}

.sync-toggle {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.sync-toggle input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.sync-toggle__track {
  width: 38px;
  height: 22px;
  padding: 2px;
  border-radius: 999px;
  background: #d2d8de;
  display: inline-flex;
  align-items: center;
  transition: background-color 0.18s ease;
}

.sync-toggle__thumb {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: #ffffff;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.16);
  transform: translateX(0);
  transition: transform 0.18s ease;
}

.sync-toggle input:checked + .sync-toggle__track {
  background: #17a34a;
}

.sync-toggle input:checked + .sync-toggle__track .sync-toggle__thumb {
  transform: translateX(16px);
}

.sync-toggle input:disabled + .sync-toggle__track {
  opacity: 0.6;
}

.sync-toggle__text {
  color: #4f5f54;
  font-size: 0.76rem;
  font-weight: 620;
}

.sync-interval-field,
.sync-manual-field {
  display: grid;
  gap: 4px;
}

.sync-manual-field__schedule {
  color: #5d6c62;
  font-size: 0.73rem;
  line-height: 1.35;
  font-weight: 460;
}

.order-import-modal__dialog {
  width: min(94vw, 1380px);
}

.order-import-modal__body {
  display: block;
}

.order-import-modal__panel {
  display: none;
}

.order-import-modal__panel.is-active {
  display: grid;
  gap: 14px;
}

.order-import-modal__section {
  padding: 18px 20px;
  border: 1px solid #e3e3e3;
  border-radius: 18px;
  background: #ffffff;
}

.order-import-daily {
  display: grid;
  gap: 14px;
}

.order-import-daily__hint {
  margin: 0;
}

.order-import-daily__table-wrap {
  overflow: auto;
  border: 1px solid #e4e4e4;
  border-radius: 14px;
  background: #ffffff;
}

.order-import-daily__table {
  width: 100%;
  min-width: 1080px;
  border-collapse: collapse;
  font-size: 0.84rem;
  table-layout: fixed;
}

.order-import-daily__table th,
.order-import-daily__table td {
  padding: 10px 8px;
  border-bottom: 1px solid #ececec;
  vertical-align: top;
}

.order-import-daily__table thead th:nth-child(1),
.order-import-daily__table tbody th {
  width: 110px;
}

.order-import-daily__table thead th:nth-child(3),
.order-import-daily__table tbody td:nth-child(3) {
  width: 190px;
}

.order-import-daily__table thead th:nth-child(4),
.order-import-daily__table tbody td:nth-child(4) {
  width: 170px;
}

.order-import-daily__table thead th {
  position: sticky;
  top: 0;
  z-index: 1;
  background: #faf6f0;
  color: #544131;
  font-size: 0.8rem;
  font-weight: 700;
  text-align: left;
}

.order-import-daily__table tbody th {
  color: #252525;
  font-size: 0.86rem;
  font-weight: 700;
}

.order-import-daily__table tbody tr:last-child th,
.order-import-daily__table tbody tr:last-child td {
  border-bottom: 0;
}

.order-import-daily__inputs {
  display: grid;
  gap: 8px;
}

.order-import-daily__file {
  display: flex;
  align-items: center;
  gap: 10px;
}

.order-import-daily__file-name {
  color: #575757;
  font-size: 0.78rem;
  line-height: 1.35;
  word-break: break-all;
}

.order-import-daily__paste-label {
  color: #585858;
  font-size: 0.76rem;
  font-weight: 600;
}

.order-import-daily__paste {
  width: 100%;
  min-height: 72px;
  padding: 9px 10px;
  border: 1px solid #d5d5d5;
  border-radius: 10px;
  background: #ffffff;
  color: #252525;
  font-size: 0.8rem;
  line-height: 1.45;
  resize: vertical;
}

.order-import-daily__password {
  width: min(100%, 240px);
}

.order-import-daily__status {
  display: grid;
  gap: 6px;
}

.order-import-daily__status-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: fit-content;
  min-height: 28px;
  padding: 0 12px;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 700;
}

.order-import-daily__status-badge.is-due {
  background: rgba(191, 39, 39, 0.12);
  color: #9a1f1f;
}

.order-import-daily__status-badge.is-done {
  background: rgba(24, 135, 73, 0.14);
  color: #177345;
}

.order-import-daily__status-badge.is-waiting {
  background: rgba(92, 115, 140, 0.14);
  color: #43556a;
}

.order-import-daily__status-note {
  color: #5f6760;
  font-size: 0.75rem;
  line-height: 1.35;
}

.order-import-daily__actions {
  display: grid;
  gap: 8px;
}

.order-import-daily__footer {
  display: flex;
  justify-content: flex-end;
}

.order-import-daily__footer .toolbar-button {
  min-width: 180px;
}

.order-import-modal__field {
  min-width: 0;
}

.order-import-modal__hint {
  margin: 10px 0 0;
  color: #6b543f;
  font-size: 0.88rem;
  line-height: 1.45;
}

.order-import-dropzone {
  display: grid;
  justify-items: center;
  gap: 10px;
  padding: 20px 18px;
  border: 1px dashed rgba(122, 61, 18, 0.38);
  border-radius: 16px;
  background: rgba(122, 61, 18, 0.04);
  text-align: center;
  cursor: pointer;
  transition: border-color 0.2s ease, background-color 0.2s ease, box-shadow 0.2s ease;
}

.order-import-dropzone.is-dragover {
  border-color: rgba(122, 61, 18, 0.6);
  background: rgba(122, 61, 18, 0.08);
  box-shadow: 0 12px 28px rgba(122, 61, 18, 0.12);
}

.order-import-dropzone strong {
  font-size: 0.96rem;
}

.order-import-dropzone p {
  margin: 0;
  color: #676767;
  font-size: 0.88rem;
}

.order-import-dropzone .toolbar-button {
  min-width: 160px;
}

.order-import-dropzone__file {
  color: #575757;
  font-size: 0.84rem;
  line-height: 1.35;
  word-break: break-all;
}

.order-import-modal__textarea-field {
  display: grid;
  gap: 8px;
}

.order-import-modal__textarea-field > span {
  color: #4f4f4f;
  font-size: 0.88rem;
  font-weight: 700;
}

.order-import-modal__paste {
  width: 100%;
  min-height: 180px;
  padding: 12px;
  border: 1px solid #d0d0d0;
  border-radius: 12px;
  background: #ffffff;
  color: #222222;
  font-size: 0.9rem;
  line-height: 1.5;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, 'Liberation Mono', 'Courier New', monospace;
  resize: vertical;
}

.order-import-modal__paste:focus {
  outline: 2px solid rgba(122, 61, 18, 0.2);
  outline-offset: 0;
  border-color: rgba(122, 61, 18, 0.45);
}

.order-manual-modal__dialog {
  width: min(980px, 100%);
}

.order-manual-modal__body {
  max-height: min(64vh, 700px);
  overflow: auto;
}

.order-manual-form__section {
  display: grid;
  gap: 12px;
}

.order-manual-form__section + .order-manual-form__section {
  margin-top: 20px;
  padding-top: 18px;
  border-top: 1px solid #ededed;
}

.order-manual-form__section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.order-manual-form__section-title {
  margin: 0;
  color: #242424;
  font-size: 1rem;
}

.order-manual-products {
  display: grid;
  gap: 12px;
}

.order-manual-product {
  display: grid;
  gap: 0;
  border: 1px solid #d8dde6;
  border-radius: 10px;
  background: #ffffff;
  overflow: hidden;
}

.order-manual-product__tab {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 8px 14px;
  background: linear-gradient(180deg, #f5f7fb 0%, #eef1f6 100%);
  border-bottom: 1px solid #d8dde6;
  border-top-left-radius: 10px;
  border-top-right-radius: 10px;
  position: relative;
}

.order-manual-product__tab::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  bottom: -1px;
  width: 4px;
  background: #4063ff;
  border-top-left-radius: 10px;
}

.order-manual-product__tab-label {
  color: #1c2533;
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: 0.01em;
}

.order-manual-product__remove {
  width: 24px;
  height: 24px;
  border-radius: 999px;
  border: 1px solid #cbd0d8;
  background: #ffffff;
  color: #6c7280;
  font-size: 16px;
  line-height: 1;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.order-manual-product__remove:hover:not(:disabled) {
  border-color: #ef4444;
  color: #ef4444;
}

.order-manual-product__remove:disabled {
  cursor: not-allowed;
  opacity: 0.5;
}

.order-manual-product__body {
  padding: 14px;
}

.order-manual-product__name-field {
  display: grid;
  gap: 6px;
}

.order-manual-product__name-input[hidden] {
  display: none;
}

.order-manual-form__required {
  color: #d94545;
  font-style: normal;
  font-weight: 700;
  margin-left: 2px;
}

.order-manual-form__field-label-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.order-manual-form__inline-toggle {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 0.74rem;
  font-weight: 500;
  color: #6c7280;
  cursor: pointer;
}

.order-manual-form__inline-toggle input[type="checkbox"] {
  margin: 0;
  width: 13px;
  height: 13px;
}

.order-manual-form__inline-button {
  border: 1px solid #c5cbd5;
  background: #ffffff;
  color: #404858;
  border-radius: 6px;
  padding: 2px 8px;
  font-size: 0.74rem;
  font-weight: 600;
  cursor: pointer;
}

.order-manual-form__inline-button:hover {
  border-color: #4063ff;
  color: #4063ff;
}

.order-manual-parts-modal__dialog {
  width: min(92vw, 560px);
}

.order-manual-parts-modal__body {
  display: grid;
  gap: 10px;
  max-height: 60vh;
  overflow-y: auto;
}

.order-manual-parts-modal__row {
  display: grid;
  gap: 8px;
  padding: 10px 12px;
  border: 1px solid #e2e6ee;
  border-radius: 8px;
  background: #ffffff;
  transition: border-color 0.12s ease, background 0.12s ease;
}

.order-manual-parts-modal__row.is-selected {
  border-color: #4063ff;
  background: #f4f7ff;
}

.order-manual-parts-modal__check {
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
}

.order-manual-parts-modal__name {
  font-weight: 600;
  color: #1c2533;
}

.order-manual-parts-modal__options {
  display: grid;
  gap: 8px;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  padding-left: 24px;
}

.order-manual-parts-modal__option {
  display: grid;
  gap: 4px;
  font-size: 0.82rem;
  color: #4f5566;
}

.order-manual-parts-modal__option select {
  padding: 4px 6px;
  border-radius: 6px;
  border: 1px solid #cbd0d8;
}

.order-manual-parts-modal__empty {
  color: #6c7280;
  text-align: center;
  padding: 16px;
}

.order-manual-form__grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px 14px;
}

.order-manual-form__field {
  display: grid;
  gap: 6px;
}

.order-manual-form__field > span {
  color: #4f4f4f;
  font-size: 0.86rem;
  font-weight: 700;
}

.order-manual-form__field--full {
  grid-column: 1 / -1;
}

@media (max-width: 1160px) {
  .option-modal {
    padding: 16px;
  }

  .option-modal__dialog {
    width: min(100%, 1080px);
  }

  .pack-review-modal__dialog {
    width: min(100%, 1080px);
  }

  .order-import-modal__dialog {
    width: min(98vw, 1320px);
  }

  .product-table__col--code {
    width: 10%;
  }

  .product-table__col--name {
    width: 19%;
  }

  .product-table__col--image {
    width: 14%;
  }
}

@media (max-width: 900px) {
  .option-group-card__items-head,
  .option-item-row {
    grid-template-columns: minmax(0, 1fr) 170px 82px;
  }

  .order-sync-settings-modal__section {
    padding: 14px;
  }

  .order-sync-settings-table {
    min-width: 620px;
  }

  .order-import-modal__section {
    padding: 16px;
  }

  .order-import-daily__table {
    min-width: 900px;
  }

  .order-manual-form__grid {
    grid-template-columns: 1fr;
  }

  .pack-batch-modal__grid {
    grid-template-columns: 1fr;
  }

  .mapping-modal__toolbar {
    align-items: stretch;
  }

  .mapping-modal__summary {
    width: 100%;
    justify-content: space-between;
  }

  .option-modal__footer {
    align-items: stretch;
    flex-direction: column;
  }

  .option-modal__footer-actions {
    width: 100%;
  }

  .option-modal__footer .toolbar-button {
    width: 100%;
  }
}

@media (max-width: 720px) {
  .option-modal__dialog {
    max-height: calc(100dvh - 20px);
  }

  .option-modal__header,
  .option-modal__body,
  .option-modal__tabs,
  .option-modal__footer {
    padding-inline: 18px;
  }

  .option-group-card__header {
    flex-direction: column;
  }

  .order-import-dropzone .toolbar-button {
    width: 100%;
  }

  .order-import-daily__file {
    align-items: stretch;
    flex-direction: column;
  }

  .order-import-daily__file .toolbar-button {
    width: 100%;
  }

  .order-import-daily__footer {
    justify-content: stretch;
  }

  .order-import-daily__footer .toolbar-button {
    width: 100%;
  }

  .order-sync-settings-table {
    min-width: 560px;
  }

  .option-group-card__items-head {
    display: none;
  }

  .option-item-row {
    grid-template-columns: 1fr;
  }

  .mapping-candidate {
    grid-template-columns: 20px minmax(0, 1fr);
    padding: 14px;
  }

  .mapping-candidate__heading {
    flex-direction: column;
  }

  .product-toolbar__actions {
    width: 100%;
  }

  .product-toolbar__actions .toolbar-button {
    flex: 1 1 180px;
  }

  .quick-notification-stack {
    left: 16px;
    right: 16px;
    bottom: max(16px, env(safe-area-inset-bottom));
    align-items: stretch;
  }

  .order-floating-action {
    left: 16px;
    right: 16px;
    bottom: max(16px, env(safe-area-inset-bottom));
  }

  .order-floating-action__button {
    width: 100%;
    min-width: 0;
    min-height: 58px;
    border-radius: 18px;
  }

  .quick-notification {
    width: auto;
    max-width: none;
    padding: 17px 18px;
    border-radius: 17px;
  }

  .quick-notification__text {
    font-size: 1rem;
  }

.quick-notification__detail {
    font-size: 0.9rem;
  }
}

@media (max-width: 900px) {
  .active-order-table {
    min-width: 1340px;
  }

  .active-orders-toolbar {
    align-items: stretch;
  }

  .active-orders-toolbar__actions {
    margin-right: 0;
    width: 100%;
  }

  .active-orders-toolbar__actions .toolbar-button {
    width: 100%;
  }

  .active-orders-toolbar__filters {
    width: 100%;
    justify-content: stretch;
  }

  .active-orders-toolbar__field {
    flex: 1 1 220px;
  }

  .customer-contact-modal__list .order-detail-list__row {
    grid-template-columns: 96px minmax(0, 1fr);
  }
}

@media (max-width: 720px) {
  .panel__body--active-orders {
    padding: 14px;
  }

  .pack-ship-modal__form {
    grid-template-columns: 1fr;
  }

  .pack-ship-modal__summary-table {
    min-width: 0;
  }

  .customer-contact-modal__list .order-detail-list__row {
    grid-template-columns: 1fr;
    gap: 6px;
  }
}

/* ============================================================
   매출 (Sales) / 매입 (Purchases) 패널
   ============================================================ */

/* 매출/매입: 타이틀(section-hero)은 박스 밖에 두고, 본문만 직각 사각형 컨테이너 안에 */
.ledger-body {
  display: flex;
  flex-direction: column;
  gap: 22px;
  padding: 22px 24px 32px;
  background: #f3f4f6;
  border: 1px solid #e1e4ea;
  border-radius: 0;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
}

.app-panel--sales,
.app-panel--purchases {
  background: transparent;
}

.sales-tabs {
  display: flex;
  gap: 4px;
  margin: 0 0 12px;
  border-bottom: 1px solid #e5e7eb;
}

.sales-tabs__tab {
  border: 0;
  background: transparent;
  padding: 10px 18px;
  font-size: 14px;
  font-weight: 600;
  color: #64748b;
  cursor: pointer;
  border-bottom: 2px solid transparent;
  transition: color 0.15s ease, border-color 0.15s ease;
}

.sales-tabs__tab:hover {
  color: #1f2937;
}

.sales-tabs__tab.is-active {
  color: #2563eb;
  border-bottom-color: #2563eb;
}

.sales-tab-hint {
  margin: 0 0 12px;
  font-size: 13px;
  color: #64748b;
}

.real-sales-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 14px;
  margin-bottom: 14px;
  background: #f8fafc;
  border: 1px solid #e5e8ee;
  border-radius: 10px;
  font-size: 13px;
}

.real-sales-toolbar__left {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #475569;
}

.real-sales-toolbar__right {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.real-sales-toolbar__status {
  font-size: 12px;
  color: #6b7280;
  min-width: 100px;
}

.real-sales-toolbar__status[data-kind="ok"] { color: #047857; }
.real-sales-toolbar__status[data-kind="error"] { color: #b91c1c; }
.real-sales-toolbar__status[data-kind="progress"] { color: #2563eb; }
.real-sales-toolbar__status[data-kind="warn"] { color: #b45309; }

.real-sales-form {
  margin-top: 18px;
  padding: 16px 18px;
  background: #fff;
  border: 1px solid #e5e8ee;
  border-radius: 12px;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
}

.real-sales-form .sales-section__header {
  align-items: center;
  margin-bottom: 6px;
}

.purchases-form__footer {
  display: flex;
  gap: 8px;
  align-items: center;
  margin-top: 8px;
}

.toolbar-button--xs {
  padding: 4px 8px;
  font-size: 12px;
}

.active-orders-toolbar__status {
  margin-left: 8px;
  font-size: 12px;
  color: #6b7280;
  align-self: center;
}
.active-orders-toolbar__status[data-kind="ok"] { color: #047857; }
.active-orders-toolbar__status[data-kind="error"] { color: #b91c1c; }
.active-orders-toolbar__status[data-kind="progress"] { color: #2563eb; }
.active-orders-toolbar__status[data-kind="warn"] { color: #b45309; }

.sales-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 14px;
  padding: 12px 14px;
  border: 1px solid #e5e8ee;
  border-radius: 10px;
  background: #fafbfd;
}

.sales-toolbar__group {
  display: flex;
  gap: 8px;
  align-items: flex-end;
  flex-wrap: wrap;
}

.sales-toolbar__group--filters {
  flex-grow: 1;
  justify-content: flex-end;
}

.sales-toolbar__view {
  border: 1px solid #d6dae3;
  background: #fff;
  color: #4b5160;
  padding: 8px 16px;
  border-radius: 999px;
  font-weight: 500;
  cursor: pointer;
  transition: all .15s ease;
}

.sales-toolbar__view:hover {
  border-color: #9aa3b3;
}

.sales-toolbar__view.is-active {
  background: #1f2937;
  border-color: #1f2937;
  color: #fff;
}

.sales-toolbar__field {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 12px;
  color: #6b7280;
  min-width: 140px;
}

.sales-toolbar__field > .table-select,
.sales-toolbar__field > .table-input {
  min-width: 140px;
}

.sales-summary-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
}

.sales-summary-card {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 14px 16px;
  background: #fff;
  border: 1px solid #e5e8ee;
  border-radius: 10px;
}

.sales-summary-card__label {
  margin: 0;
  font-size: 12px;
  color: #6b7280;
  letter-spacing: .02em;
}

.sales-summary-card__value {
  font-size: 22px;
  color: #111827;
  font-weight: 700;
}

.sales-summary-card__hint {
  font-size: 11px;
  color: #9ca3af;
}

.sales-summary-card--warn {
  background: #fff8ec;
  border-color: #f5d999;
}

.sales-summary-card--warn .sales-summary-card__value {
  color: #b45309;
}

.sales-section {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 16px 18px;
  background: #fff;
  border: 1px solid #e5e8ee;
  border-radius: 12px;
}

.ledger-pagination {
  display: flex;
  align-items: center;
  gap: 10px;
  padding-top: 6px;
  flex-wrap: wrap;
}

.ledger-pagination__btn {
  border: 1px solid #d6dae3;
  background: #fff;
  border-radius: 8px;
  padding: 6px 14px;
  font-size: 13px;
  cursor: pointer;
  color: #4b5160;
}

.ledger-pagination__btn:hover:not(:disabled) {
  border-color: #6b7280;
}

.ledger-pagination__btn:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

.ledger-pagination__info {
  font-size: 13px;
  color: #4b5160;
  font-variant-numeric: tabular-nums;
}

.ledger-pagination__size {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  color: #6b7280;
  margin-left: auto;
}

.sales-section__header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.sales-section__header h2,
.sales-section__header h3 {
  margin: 0;
  font-size: 15px;
  color: #1f2937;
}

.sales-section__caption {
  margin: 0;
  font-size: 12px;
  color: #6b7280;
}

.sales-table-wrap {
  overflow-x: auto;
  border: 1px solid #e5e8ee;
  border-radius: 10px;
}

.sales-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
  background: #fff;
}

.sales-table th,
.sales-table td {
  padding: 10px 12px;
  text-align: left;
  border-bottom: 1px solid #eef1f5;
  white-space: nowrap;
}

.sales-table thead th {
  background: #f6f7fa;
  color: #4b5160;
  font-weight: 600;
  position: sticky;
  top: 0;
}

.sales-table tbody tr:hover {
  background: #f9fafc;
}

.sales-table__cell--num {
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.sales-table__empty {
  text-align: center !important;
  color: #9ca3af;
  padding: 24px !important;
}

.sales-table__row--missing {
  background: #fffaf0;
}

.sales-badge {
  display: inline-block;
  padding: 1px 8px;
  font-size: 11px;
  border-radius: 999px;
  background: #fef3c7;
  color: #92400e;
  margin-left: 6px;
}

/* --- 매입 --- */
.purchases-config {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  border-radius: 999px;
  background: #f3f4f6;
  font-size: 12px;
  color: #4b5160;
  align-self: flex-start;
}

.purchases-config__dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #9ca3af;
}

.purchases-config.is-enabled {
  background: #ecfdf5;
  color: #047857;
}
.purchases-config.is-enabled .purchases-config__dot {
  background: #10b981;
}

.purchases-config.is-disabled {
  background: #fef2f2;
  color: #b91c1c;
}
.purchases-config.is-disabled .purchases-config__dot {
  background: #ef4444;
}

.purchases-scan__layout {
  display: grid;
  grid-template-columns: minmax(220px, 320px) 1fr;
  gap: 18px;
}

@media (max-width: 960px) {
  .purchases-scan__layout {
    grid-template-columns: 1fr;
  }
}

.purchases-dropzone {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 240px;
  border: 2px dashed #c7cdd6;
  border-radius: 12px;
  background: #fafbfd;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  transition: all .15s ease;
}

.purchases-dropzone:hover,
.purchases-dropzone:focus-visible {
  border-color: #6b7280;
  background: #f4f6fa;
}

.purchases-dropzone.is-dragover {
  border-color: #2563eb;
  background: #eff6ff;
}

.purchases-dropzone__placeholder {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  color: #6b7280;
  font-size: 13px;
}

.purchases-dropzone__placeholder strong {
  color: #1f2937;
  font-size: 14px;
}

.purchases-dropzone__preview {
  width: 100%;
  height: 100%;
  max-height: 360px;
  object-fit: contain;
  background: #000;
}

.purchases-form {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.purchases-form__actions {
  display: flex;
  gap: 8px;
  align-items: center;
}

.purchases-form__message {
  margin: 0;
  font-size: 12px;
  color: #6b7280;
  min-height: 16px;
}

.purchases-form__message.is-error {
  color: #b91c1c;
}

.purchases-form__message.is-success {
  color: #047857;
}

.purchases-form__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 10px;
}

.table-form-label--block {
  grid-column: 1 / -1;
}

.table-form-label--wide {
  grid-column: span 2;
  min-width: 0;
}

@media (max-width: 720px) {
  .table-form-label--wide {
    grid-column: 1 / -1;
  }
}

.table-input--num {
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.purchases-items {
  border: 1px solid #e5e8ee;
  border-radius: 10px;
  background: #fff;
}

.purchases-items__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 12px;
  border-bottom: 1px solid #eef1f5;
}

.purchases-items__header h3 {
  margin: 0;
  font-size: 14px;
  color: #1f2937;
}

.toolbar-button--ghost {
  background: transparent;
  border: 1px dashed #c7cdd6;
}

.purchases-items__table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}

.purchases-items__table th,
.purchases-items__table td {
  padding: 6px 8px;
  border-bottom: 1px solid #f1f3f7;
}

.purchases-items__table th {
  background: #f9fafc;
  color: #6b7280;
  font-weight: 500;
}

.purchases-items__table input {
  width: 100%;
  border: 1px solid #e0e3ea;
  border-radius: 6px;
  padding: 5px 8px;
  font-size: 13px;
}

.purchases-items__table .purchases-items__remove {
  background: none;
  border: none;
  color: #9ca3af;
  cursor: pointer;
  font-size: 18px;
}

.purchases-items__table .purchases-items__remove:hover {
  color: #ef4444;
}

.purchases-form__footer {
  display: flex;
  justify-content: flex-end;
}

.purchases-list-section,
.purchases-scan,
.purchases-vendors,
.purchases-vendors-list-section {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 18px 20px;
  background: #fff;
  border: 1px solid #e5e8ee;
  border-radius: 12px;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
}

.purchases-vendors__header,
.purchases-vendors-list-section__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.purchases-list-section__filters {
  display: flex;
  gap: 8px;
  align-items: flex-end;
}

.purchases-row__actions {
  display: flex;
  gap: 6px;
  justify-content: flex-end;
}

.purchases-row__action-btn {
  border: 1px solid #d6dae3;
  background: #fff;
  border-radius: 6px;
  padding: 4px 8px;
  cursor: pointer;
  font-size: 12px;
  color: #4b5160;
}

.purchases-row__action-btn:hover {
  border-color: #6b7280;
}

.purchases-row__action-btn--danger:hover {
  border-color: #ef4444;
  color: #ef4444;
}

.purchases-supplier-field {
  display: grid;
  grid-template-columns: minmax(140px, 200px) minmax(0, 1fr);
  gap: 8px;
}

.purchases-supplier-field > .table-input {
  min-width: 0;
  width: 100%;
}

.purchases-vendor-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

body.is-office-mobile .purchases-supplier-field {
  grid-template-columns: 1fr;
}

/* ---------- AI 비서 위젯 ---------- */
.assistant-widget {
  position: fixed;
  right: 24px;
  top: 24px;
  z-index: 1200;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 12px;
  pointer-events: none;
}

body.is-delivery-mobile .assistant-widget {
  display: none !important;
}
/* 알림/확인 등 모달이 열려 있을 때는 AI 비서 위젯을 모달 아래로 내려, 모달이 항상 최상단에 보이게 한다. */
body.is-modal-open .assistant-widget,
body.has-modal-open .assistant-widget,
body.has-delivery-modal-open .assistant-widget,
body.has-product-modal-open .assistant-widget {
  z-index: 5;
  pointer-events: none;
}
.assistant-widget > * { pointer-events: auto; }
.assistant-widget__toggle {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 18px;
  border: none;
  border-radius: 999px;
  background: #111827;
  color: #fff;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  box-shadow: 0 12px 32px rgba(15, 23, 42, 0.25);
  transition: transform 120ms ease, box-shadow 120ms ease, background 120ms ease;
}
.assistant-widget__toggle:hover {
  background: #1f2937;
  transform: translateY(-1px);
  box-shadow: 0 14px 36px rgba(15, 23, 42, 0.3);
}
.assistant-widget__toggle-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  border-radius: 999px;
  background: linear-gradient(135deg, #6366f1, #ec4899);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.5px;
}
.assistant-widget__panel {
  width: min(380px, calc(100vw - 48px));
  height: min(540px, calc(100vh - 140px));
  background: #ffffff;
  border-radius: 18px;
  box-shadow: 0 24px 64px rgba(15, 23, 42, 0.28);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid rgba(15, 23, 42, 0.08);
  transform-origin: top right;
  transition: opacity 180ms ease, transform 180ms cubic-bezier(0.2, 0.9, 0.3, 1.2);
  opacity: 1;
  transform: translateY(0) scale(1);
}
.assistant-widget__panel.is-closed {
  opacity: 0;
  transform: translateY(-10px) scale(0.94);
  pointer-events: none;
  visibility: hidden;
  transition: opacity 140ms ease, transform 140ms ease, visibility 0s linear 140ms;
}
.assistant-widget__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 16px;
  background: linear-gradient(135deg, #111827, #1f2937);
  color: #fff;
}
.assistant-widget__title { display: flex; flex-direction: column; gap: 2px; }
.assistant-widget__title strong { font-size: 14px; font-weight: 700; }
.assistant-widget__status { font-size: 11px; color: rgba(255, 255, 255, 0.7); }
.assistant-widget__header-actions { display: inline-flex; gap: 4px; }
.assistant-widget__icon-button {
  width: 28px; height: 28px;
  border: none;
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
  border-radius: 8px;
  cursor: pointer;
  font-size: 14px;
  line-height: 1;
}
.assistant-widget__icon-button:hover { background: rgba(255, 255, 255, 0.16); }
.assistant-widget__messages {
  flex: 1 1 auto;
  overflow-y: auto;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  background: #f8fafc;
}
.assistant-message {
  max-width: 85%;
  padding: 10px 12px;
  border-radius: 12px;
  font-size: 13.5px;
  line-height: 1.5;
  white-space: pre-wrap;
  word-break: break-word;
}
.assistant-message--user {
  align-self: flex-end;
  background: #111827;
  color: #fff;
  border-bottom-right-radius: 4px;
}
.assistant-message--assistant {
  align-self: flex-start;
  background: #ffffff;
  color: #111827;
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-bottom-left-radius: 4px;
}
.assistant-message--error {
  align-self: stretch;
  background: #fef2f2;
  color: #b91c1c;
  border: 1px solid #fecaca;
  text-align: center;
  font-size: 12px;
}
.assistant-message--system {
  align-self: center;
  background: transparent;
  color: #6b7280;
  font-size: 12px;
  text-align: center;
}
.assistant-message__tools {
  margin-top: 6px;
  font-size: 11px;
  color: #6b7280;
  font-style: italic;
}
/* 비서 응답 마크다운 렌더 */
.assistant-message__md { white-space: normal; }
.assistant-message__md > :first-child { margin-top: 0; }
.assistant-message__md > :last-child { margin-bottom: 0; }
.assistant-message__md p { margin: 0 0 8px; }
.assistant-message__md strong { font-weight: 700; }
.assistant-message__md .assistant-md__h {
  font-weight: 700;
  font-size: 14px;
  margin: 12px 0 6px;
  color: #0f172a;
}
.assistant-message__md code {
  background: rgba(15, 23, 42, 0.06);
  padding: 1px 5px;
  border-radius: 4px;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 12px;
}
.assistant-md__code {
  background: #0f172a;
  color: #e2e8f0;
  padding: 10px 12px;
  border-radius: 8px;
  overflow-x: auto;
  margin: 8px 0;
  font-size: 12px;
  line-height: 1.5;
}
.assistant-md__code code { background: none; color: inherit; padding: 0; }
.assistant-md__hr { border: 0; border-top: 1px solid rgba(15, 23, 42, 0.14); margin: 10px 0; }
.assistant-md__list { margin: 6px 0; padding-left: 18px; }
.assistant-md__list li { margin: 2px 0; }
.assistant-md__table {
  border-collapse: collapse;
  width: 100%;
  margin: 8px 0;
  font-size: 12.5px;
  display: block;
  overflow-x: auto;
}
.assistant-md__table th,
.assistant-md__table td {
  border: 1px solid rgba(15, 23, 42, 0.12);
  padding: 5px 8px;
  text-align: left;
  white-space: nowrap;
}
.assistant-md__table th { background: #f8fafc; font-weight: 700; }
.assistant-typing {
  align-self: flex-start;
  display: inline-flex;
  gap: 4px;
  padding: 10px 14px;
  background: #ffffff;
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 12px;
}
.assistant-typing span {
  width: 6px; height: 6px; border-radius: 999px; background: #94a3b8;
  animation: assistantBlink 1.2s infinite ease-in-out;
}
.assistant-typing span:nth-child(2) { animation-delay: 0.15s; }
.assistant-typing span:nth-child(3) { animation-delay: 0.3s; }
@keyframes assistantBlink {
  0%, 60%, 100% { opacity: 0.3; }
  30% { opacity: 1; }
}
.assistant-widget__form {
  display: flex;
  gap: 8px;
  padding: 10px 12px;
  background: #ffffff;
  border-top: 1px solid rgba(15, 23, 42, 0.06);
}
.assistant-widget__input {
  flex: 1 1 auto;
  resize: none;
  border: 1px solid rgba(15, 23, 42, 0.12);
  border-radius: 10px;
  padding: 8px 10px;
  font-size: 13.5px;
  font-family: inherit;
  line-height: 1.45;
  outline: none;
  transition: border-color 120ms ease;
}
.assistant-widget__input:focus { border-color: #111827; }
.assistant-widget__send {
  align-self: flex-end;
  padding: 9px 14px;
  border: none;
  border-radius: 10px;
  background: #111827;
  color: #fff;
  font-weight: 600;
  font-size: 13px;
  cursor: pointer;
}
.assistant-widget__send:disabled { background: #94a3b8; cursor: not-allowed; }
.assistant-widget__hint {
  margin: 0;
  padding: 6px 12px 10px;
  background: #ffffff;
  font-size: 11px;
  color: #94a3b8;
  text-align: center;
}
.assistant-widget--disabled .assistant-widget__toggle { background: #6b7280; }
.assistant-pending {
  align-self: stretch;
  border: 1px solid rgba(15, 23, 42, 0.12);
  border-left: 4px solid #f59e0b;
  background: #fffbeb;
  border-radius: 12px;
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-size: 13px;
}
.assistant-pending__badge-row { display: block; }
.assistant-pending__badge {
  display: inline-block;
  background: #f59e0b;
  color: #fff;
  padding: 3px 10px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.02em;
  white-space: nowrap;
  line-height: 1.4;
}
.assistant-pending__summary {
  color: #111827;
  font-weight: 600;
  font-size: 13.5px;
  line-height: 1.45;
  word-break: keep-all;
}
.assistant-pending__details-body {
  padding: 10px 12px;
  background: rgba(255, 255, 255, 0.85);
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 8px;
}
.assistant-pending__details-list {
  display: grid;
  grid-template-columns: max-content 1fr;
  column-gap: 12px;
  row-gap: 4px;
  margin: 0;
  font-size: 12px;
  line-height: 1.5;
}
.assistant-pending__details-list dt {
  color: #6b7280;
  font-weight: 500;
  white-space: nowrap;
}
.assistant-pending__details-list dd {
  margin: 0;
  color: #1f2937;
  word-break: break-word;
}
.assistant-pending__actions { display: flex; gap: 8px; justify-content: flex-end; }
.assistant-pending__btn {
  border: none;
  border-radius: 8px;
  padding: 6px 14px;
  font-size: 12.5px;
  font-weight: 600;
  cursor: pointer;
  transition: opacity 120ms ease;
}
.assistant-pending__btn:disabled { opacity: 0.5; cursor: not-allowed; }
.assistant-pending__btn--cancel { background: #e5e7eb; color: #1f2937; }
.assistant-pending__btn--exec { background: #111827; color: #fff; }
.assistant-pending__btn--exec:hover:not(:disabled) { background: #000; }
.assistant-pending__status { font-size: 11.5px; color: #6b7280; min-height: 14px; }
.assistant-pending--done { border-left-color: #16a34a; background: #f0fdf4; }
.assistant-pending--cancelled { border-left-color: #94a3b8; background: #f1f5f9; }
.assistant-pending--error { border-left-color: #dc2626; background: #fef2f2; }
.assistant-pending--undone { border-left-color: #6366f1; background: #eef2ff; }
.assistant-pending__undo { display: flex; justify-content: flex-end; }
.assistant-pending__btn--undo {
  background: transparent;
  color: #4338ca;
  border: 1px dashed #6366f1;
  padding: 5px 10px;
  font-size: 12px;
}
.assistant-pending__btn--undo:hover:not(:disabled) { background: #eef2ff; }
@media (max-width: 640px) {
  .assistant-widget { right: 12px; top: 12px; }
  .assistant-widget__panel {
    width: calc(100vw - 24px);
    height: calc(100vh - 100px);
  }
}

/* ----------------------------------------------------------------------- */
/* 교환/반품 (Exchanges & Returns)                                         */
/* ----------------------------------------------------------------------- */

.panel--exchanges-returns .order-toolbar {
  margin-bottom: 12px;
}

.exchange-return-table {
  table-layout: fixed;
  width: 100%;
  min-width: 0;
}

.exchange-return-table__col--platform { width: 78px; }
.exchange-return-table__col--order { width: 32%; }
.exchange-return-table__col--product { width: 36%; }
.exchange-return-table__col--qty { width: 56px; }
.exchange-return-table__col--amount { width: 110px; }
.exchange-return-table__col--actions { width: 152px; }

.exchange-return-table th,
.exchange-return-table td {
  padding: 8px 10px;
  vertical-align: top;
  font-size: 0.84rem;
}

.exchange-return-row--has-record > td {
  background: rgba(255, 184, 92, 0.08);
}

.exchange-return-platform-badge {
  min-width: 0;
  width: 100%;
  padding: 4px 8px;
  font-size: 0.7rem;
  border-radius: 8px;
  letter-spacing: -0.01em;
}

.exchange-return-customer-cell {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.exchange-return-customer-cell__main {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 6px;
  min-width: 0;
}

.exchange-return-customer-cell__main strong {
  font-size: 0.86rem;
  font-weight: 800;
  color: #1f2937;
  word-break: break-all;
}

.exchange-return-customer-cell__name {
  font-size: 0.86rem;
  font-weight: 700;
  color: #1f2937;
}

.exchange-return-customer-cell__sub {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  font-size: 0.76rem;
  color: #6b7280;
}

.exchange-return-customer-cell__date {
  color: #9ca3af;
}

.exchange-return-cell-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}

.exchange-return-product-cell {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.exchange-return-product-cell__name {
  font-size: 0.84rem;
  font-weight: 700;
  color: #1f2937;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.exchange-return-product-cell__options {
  font-size: 0.74rem;
  color: #6b7280;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.exchange-return-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  align-items: center;
  justify-content: flex-start;
}

.exchange-return-actions .mini-button {
  padding: 4px 10px;
  font-size: 0.74rem;
  min-height: 28px;
}

.exchange-return-status-pill {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 10px;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 700;
  line-height: 1.4;
  border: 1px solid transparent;
}

.exchange-return-status-pill--exchange {
  background: rgba(56, 116, 255, 0.12);
  border-color: rgba(56, 116, 255, 0.32);
  color: #1f4ed8;
}

.exchange-return-status-pill--return {
  background: rgba(220, 80, 70, 0.12);
  border-color: rgba(220, 80, 70, 0.32);
  color: #c0382c;
}

.exchange-return-phone-badge {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 999px;
  background: rgba(155, 95, 38, 0.14);
  color: #8a4f1c;
  font-size: 0.7rem;
  font-weight: 700;
  white-space: nowrap;
}

.exchange-return-modal__dialog {
  width: min(96vw, 920px);
}

.exchange-return-modal__body {
  display: grid;
  gap: 18px;
}

.exchange-return-modal__section-title {
  margin: 0 0 10px;
  font-size: 0.96rem;
  font-weight: 800;
  color: #1f2937;
}

.exchange-return-modal__order {
  border: 1px solid #e3ddd5;
  border-radius: 16px;
  background: #fbf8f2;
  padding: 16px 18px;
}

.exchange-return-modal__order-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px 18px;
  margin: 0;
}

.exchange-return-modal__order-grid > div {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.exchange-return-modal__order-grid dt {
  font-size: 0.74rem;
  font-weight: 700;
  color: #6b5b46;
}

.exchange-return-modal__order-grid dd {
  margin: 0;
  font-size: 0.92rem;
  font-weight: 600;
  color: #1f2937;
  word-break: break-word;
  white-space: normal;
}

.exchange-return-modal__history {
  margin: 12px 0 0;
  padding: 10px 14px;
  border-radius: 12px;
  background: rgba(56, 116, 255, 0.08);
  color: #1f3a8a;
  font-size: 0.86rem;
  line-height: 1.5;
}

.exchange-return-modal__form {
  display: grid;
  gap: 14px;
  border: 1px solid #e6e6e6;
  border-radius: 16px;
  background: #ffffff;
  padding: 18px 20px;
}

.exchange-return-modal__field {
  display: grid;
  gap: 6px;
}

.exchange-return-modal__field--checkbox {
  grid-template-columns: max-content;
  align-items: center;
}

.exchange-return-modal__field--checkbox span {
  font-size: 0.92rem;
  font-weight: 700;
  color: #1f2937;
}

.exchange-return-modal__field--inline {
  grid-template-columns: max-content minmax(0, 200px) max-content;
  align-items: center;
  gap: 8px;
}

.exchange-return-modal__field-label {
  font-size: 0.84rem;
  font-weight: 700;
  color: #1f2937;
}

.exchange-return-modal__radio-group {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.exchange-return-modal__radio {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  border: 1px solid #d9d9d9;
  border-radius: 999px;
  background: #ffffff;
  font-size: 0.9rem;
  font-weight: 600;
  color: #374151;
  cursor: pointer;
}

.exchange-return-modal__radio input {
  accent-color: #2563eb;
}

.exchange-return-modal__radio:has(input:checked) {
  border-color: #2563eb;
  background: rgba(37, 99, 235, 0.08);
  color: #1d4ed8;
}

.exchange-return-modal__row {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  align-items: center;
}

.exchange-return-modal__suffix {
  font-size: 0.84rem;
  color: #6b7280;
}

.exchange-return-modal__form .table-input[type="number"] {
  max-width: 200px;
}

.exchange-return-modal__form textarea.table-input {
  width: 100%;
  resize: vertical;
}

@media (max-width: 720px) {
  .exchange-return-modal__order-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .exchange-return-modal__field--inline {
    grid-template-columns: 1fr;
  }
}

.settlement-toolbar__filters {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  align-items: end;
}

.settlement-filter {
  display: inline-flex;
  flex-direction: column;
  gap: 4px;
  font-size: 0.82rem;
  color: #5a534b;
}

.settlement-filter__label {
  font-size: 0.78rem;
  font-weight: 700;
  color: #2c2925;
}

.section-hero--settlement .section-hero__summary {
  min-width: 0;
  grid-template-columns: repeat(4, minmax(132px, 1fr));
}

.settlement-summary-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 12px;
  margin: 12px 0 18px;
}

.settlement-summary-grid__empty {
  grid-column: 1 / -1;
  margin: 0;
  padding: 16px;
  border: 1px dashed rgba(255, 255, 255, 0.14);
  border-radius: 10px;
  text-align: center;
  color: rgba(255, 255, 255, 0.6);
}

.settlement-summary-card {
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  padding: 12px 14px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.04) 0%, rgba(255, 255, 255, 0) 100%), #1d2022;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.settlement-summary-card__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.settlement-summary-card__name {
  font-size: 1rem;
  color: #f3f4f5;
}

.settlement-summary-card__rate {
  font-size: 0.78rem;
  color: rgba(255, 255, 255, 0.62);
}

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

.settlement-summary-card__metrics dt {
  font-size: 0.74rem;
  color: rgba(255, 255, 255, 0.55);
  margin-bottom: 4px;
}

.settlement-summary-card__metrics dd {
  margin: 0;
  font-size: 0.96rem;
  font-weight: 600;
  color: #fbbf24;
}

.settlement-summary-card__metrics div:first-child dd {
  color: #f3f4f5;
}

.settlement-table-wrap {
  overflow-x: auto;
}

.settlement-table {
  width: 100%;
  min-width: 720px;
}

.settlement-col-photo {
  width: 88px;
}

.settlement-col-amount {
  text-align: right;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.settlement-table__placeholder {
  font-size: 0.82rem;
  color: rgba(255, 255, 255, 0.4);
}

.settlement-table__footer td {
  font-weight: 700;
  background: rgba(255, 255, 255, 0.04);
}

.settlement-rates-modal__dialog {
  max-width: 640px;
}

.settlement-rates-modal__body {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.settlement-rates-default {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.settlement-rates-table-wrap {
  overflow-x: auto;
  max-height: 60vh;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
}

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

.settlement-rates-table th,
.settlement-rates-table td {
  padding: 10px 12px;
  font-size: 0.86rem;
  text-align: left;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.settlement-rates-table tr:last-child td {
  border-bottom: none;
}

.settlement-rates-table th {
  background: rgba(255, 255, 255, 0.04);
  color: rgba(255, 255, 255, 0.7);
  font-weight: 600;
}

.settlement-rates-table__empty {
  text-align: center;
  color: rgba(255, 255, 255, 0.55);
}

.settlement-rates-table input.table-input {
  width: 100%;
  max-width: 160px;
}

body.is-delivery-mobile [data-panel="settlement"] .section-hero__summary {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

body.is-delivery-mobile [data-panel="settlement"] .settlement-toolbar {
  flex-direction: column;
  align-items: stretch;
  gap: 10px;
}

body.is-delivery-mobile [data-panel="settlement"] .settlement-toolbar__filters {
  flex-direction: column;
  align-items: stretch;
  gap: 8px;
}

body.is-delivery-mobile [data-panel="settlement"] .settlement-table {
  min-width: 0;
}

body.is-delivery-mobile [data-panel="settlement"] .settlement-table thead {
  display: none;
}

body.is-delivery-mobile [data-panel="settlement"] .settlement-table,
body.is-delivery-mobile [data-panel="settlement"] .settlement-table tbody,
body.is-delivery-mobile [data-panel="settlement"] .settlement-table tfoot,
body.is-delivery-mobile [data-panel="settlement"] .settlement-table tr,
body.is-delivery-mobile [data-panel="settlement"] .settlement-table td {
  display: block;
  width: 100%;
}

body.is-delivery-mobile [data-panel="settlement"] .settlement-table tbody tr {
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  margin-bottom: 10px;
  padding: 10px 12px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.04) 0%, rgba(255, 255, 255, 0) 100%), #1d2022;
}

body.is-delivery-mobile [data-panel="settlement"] .settlement-table tbody td {
  border: none;
  padding: 4px 0;
  font-size: 0.86rem;
}

body.is-delivery-mobile [data-panel="settlement"] .settlement-table tbody td.settlement-col-amount {
  text-align: right;
  font-weight: 700;
  color: #fbbf24;
}

body.is-delivery-mobile [data-panel="settlement"] .settlement-table tbody td.settlement-col-photo {
  text-align: left;
}

body.is-delivery-mobile [data-panel="settlement"] .settlement-table tfoot tr {
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 10px;
  margin-top: 10px;
  padding: 10px 12px;
  background: rgba(255, 255, 255, 0.04);
}

body.is-delivery-mobile [data-panel="settlement"] .settlement-table tfoot td {
  border: none;
  padding: 4px 0;
  text-align: right;
  font-weight: 700;
}

/* ===========================================================
   사무용 모바일 모드 (is-office-mobile)
   외근 환경의 관리자/사무 사용자가 휴대폰에서 접근할 때 적용.
   기본적으로 off — 뷰포트가 좁고 택배 파트너가 아닐 때만 on.
   =========================================================== */

.office-mobile-topbar { display: none; }
.office-mobile-bottomnav { display: none; }

body.is-office-mobile .sidebar { display: none; }
body.is-office-mobile .dashboard-content__topbar { display: none; }
body.is-office-mobile .dashboard-shell { grid-template-columns: 1fr; }
body.is-office-mobile .dashboard-content {
  grid-column: 1;
  min-height: auto;
  padding: 8px 9px calc(78px + env(safe-area-inset-bottom));
}

body.is-office-mobile .delivery-mobile-topbar { display: none !important; }

body.is-office-mobile .office-mobile-topbar {
  display: block;
  margin: 0 0 8px;
  border-radius: 9px;
  background: linear-gradient(180deg, #2b2d2d 0%, #181b1d 100%);
  color: #f1eee7;
  box-shadow: 0 16px 34px rgba(21, 24, 25, 0.22);
}

body.is-office-mobile .office-mobile-topbar__row {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  padding: 8px 12px;
}

body.is-office-mobile .office-mobile-topbar__brand {
  display: inline-flex;
  align-items: center;
}

body.is-office-mobile .office-mobile-topbar__logo {
  height: 1.2rem;
  width: auto;
  display: block;
  object-fit: contain;
  filter: brightness(0) invert(1);
}

body.is-office-mobile .office-mobile-topbar__user {
  min-width: 0;
  font-size: 0.82rem;
  color: rgba(255, 255, 255, 0.86);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body.is-office-mobile .office-mobile-topbar__logout {
  min-height: 32px;
  padding: 0 12px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.08);
  color: #f1eee7;
  font-size: 0.78rem;
  font-weight: 700;
  white-space: nowrap;
  cursor: pointer;
}

/* AI 비서 위젯은 사무 모바일에서 본문을 가리니 숨김 */
body.is-office-mobile .assistant-widget {
  display: none !important;
}

/* 토스트/플로팅 액션을 하단 탭바보다 위로 띄움 (탭바 높이 ~64px + safe-area) */
body.is-office-mobile .order-floating-action,
body.is-office-mobile .quick-notification-stack {
  bottom: calc(78px + env(safe-area-inset-bottom));
}

body.is-office-mobile .office-mobile-bottomnav {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 2px;
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 230;
  padding: 6px 6px calc(6px + env(safe-area-inset-bottom));
  background: #181b1d;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

body.is-office-mobile .office-mobile-bottomnav__item {
  min-height: 44px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: rgba(255, 255, 255, 0.68);
  font-size: 0.74rem;
  font-weight: 700;
  cursor: pointer;
  padding: 0 4px;
}

body.is-office-mobile .office-mobile-bottomnav__item.is-active {
  background: #ffffff;
  color: #182233;
}

body.is-office-mobile .office-mobile-bottomnav__item[hidden] {
  display: none;
}

@media (max-width: 380px) {
  body.is-office-mobile .office-mobile-bottomnav {
    grid-auto-flow: column;
    grid-auto-columns: 25%;
    grid-template-columns: none;
    overflow-x: auto;
    scrollbar-width: none;
  }
  body.is-office-mobile .office-mobile-bottomnav::-webkit-scrollbar {
    display: none;
  }
}

/* 모든 대상 패널의 section-hero 축소 */
body.is-office-mobile .section-hero {
  padding: 4px 4px 6px;
  gap: 4px;
}
body.is-office-mobile .section-hero__title {
  font-size: 1.05rem;
  margin: 0;
}
body.is-office-mobile .section-hero__eyebrow {
  display: none;
}
body.is-office-mobile .section-hero__subtitle {
  display: none;
}
body.is-office-mobile .section-hero__summary {
  display: none;
}

/* 패널 본문 패딩 축소 */
body.is-office-mobile .panel,
body.is-office-mobile .panel__body {
  padding: 0;
  background: transparent;
  box-shadow: none;
  border: 0;
}

body.is-office-mobile .order-toolbar,
body.is-office-mobile .active-orders-toolbar,
body.is-office-mobile .order-toolbar__top,
body.is-office-mobile .delivery-toolbar,
body.is-office-mobile .sales-toolbar,
body.is-office-mobile .purchases-toolbar {
  flex-wrap: wrap;
  gap: 6px;
  padding: 8px;
  margin: 0 0 8px;
}

body.is-office-mobile .toolbar-field {
  min-width: 0;
}

body.is-office-mobile .toolbar-button {
  min-height: 36px;
  padding: 0 8px;
  font-size: 0.78rem;
}

body.is-office-mobile .toolbar-icon-button {
  min-height: 36px;
  min-width: 36px;
}

body.is-office-mobile .table-input,
body.is-office-mobile .table-select {
  min-height: 36px;
  font-size: 0.86rem;
}

/* 도구막대 액션 버튼들을 2열 그리드로 묶음 */
body.is-office-mobile .order-toolbar__actions,
body.is-office-mobile .active-orders-toolbar__actions,
body.is-office-mobile .delivery-toolbar__actions,
body.is-office-mobile .purchases-form__actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px;
  width: 100%;
}

body.is-office-mobile .order-toolbar__actions > .toolbar-button,
body.is-office-mobile .order-toolbar__actions > .toolbar-icon-button,
body.is-office-mobile .active-orders-toolbar__actions > .toolbar-button,
body.is-office-mobile .delivery-toolbar__actions > .toolbar-button,
body.is-office-mobile .purchases-form__actions > .toolbar-button {
  width: 100%;
  min-height: 36px;
  padding: 0 8px;
  font-size: 0.78rem;
}

/* 필터 그룹 2열 그리드 */
body.is-office-mobile .order-toolbar__filters,
body.is-office-mobile .active-orders-toolbar__filters,
body.is-office-mobile .delivery-toolbar__filters,
body.is-office-mobile .sales-toolbar__group--filters,
body.is-office-mobile .sales-toolbar__group {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px;
}

body.is-office-mobile .order-toolbar__filters .toolbar-field,
body.is-office-mobile .active-orders-toolbar__filters .toolbar-field,
body.is-office-mobile .delivery-toolbar__filters .toolbar-field {
  min-width: 0;
}

/* 검색 영역은 한 줄 전체 차지 */
body.is-office-mobile .order-toolbar__filters .order-toolbar__search,
body.is-office-mobile .order-toolbar__filters .order-toolbar__search-query,
body.is-office-mobile .order-toolbar__filters .order-toolbar__right {
  grid-column: 1 / -1;
}

body.is-office-mobile .order-toolbar__search-input {
  display: flex;
  gap: 6px;
}

body.is-office-mobile .order-toolbar__search-input .table-input {
  flex: 1 1 auto;
  min-width: 0;
}

/* 페이지네이션: 가로 정렬 + 한 줄 강제, 표 바로 위에 위치 */
body.is-office-mobile .order-toolbar__right {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  margin-top: 4px;
}

body.is-office-mobile .order-toolbar__pagination {
  flex: 1 1 auto;
  min-width: 0;
  justify-content: flex-start;
}

body.is-office-mobile .order-toolbar__pagination .order-pagination {
  flex-wrap: nowrap;
  gap: 4px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  width: 100%;
  scrollbar-width: none;
}

body.is-office-mobile .order-toolbar__pagination .order-pagination::-webkit-scrollbar {
  display: none;
}

body.is-office-mobile .order-toolbar__pagination .page-button-group {
  display: inline-flex;
  flex-wrap: nowrap;
  gap: 4px;
}

body.is-office-mobile .order-toolbar__pagination .page-button {
  width: auto;
  min-width: 32px;
  min-height: 32px;
  padding: 0 8px;
  font-size: 0.78rem;
  flex: 0 0 auto;
}

body.is-office-mobile .order-toolbar__pagination .order-pagination__summary {
  font-size: 0.74rem;
  white-space: nowrap;
  flex: 0 0 auto;
}

/* 하단 중복 페이지네이션 블록 숨김 (모바일에서는 표 위 페이지네이션만 사용) */
body.is-office-mobile .order-toolbar__bottom {
  display: none;
}

/* 새로고침 버튼은 페이지네이션 옆이 아닌, 도구막대 우측 상단에 작은 아이콘으로 띄움 */
body.is-office-mobile [data-history-order-refresh],
body.is-office-mobile [data-order-list-refresh] {
  position: absolute;
  top: 8px;
  right: 8px;
  z-index: 5;
  margin: 0;
  width: 32px;
  height: 32px;
  min-height: 32px;
  min-width: 32px;
  padding: 0;
  font-size: 0.86rem;
}

body.is-office-mobile .panel--orders,
body.is-office-mobile .panel--orders-history {
  position: relative;
}

body.is-office-mobile .order-toolbar__right [data-history-order-refresh],
body.is-office-mobile .order-toolbar__right [data-order-list-refresh] {
  /* .order-toolbar__right 내부에 들어있는 인라인 형태도 위 absolute 규칙으로 떠 있게 됨 */
}

/* 압축 표 유틸리티: 카드 변환 대신 한 줄 강제 + 가로 스크롤 */
body.is-office-mobile .compact-table-wrap {
  overflow-x: auto;
  overflow-y: visible;
  -webkit-overflow-scrolling: touch;
  border: 1px solid #e6dfd2;
  border-radius: 8px;
  background: #ffffff;
  margin: 0 0 8px;
}

body.is-office-mobile .compact-table {
  width: max-content;
  min-width: 100%;
  max-width: none;
  border-collapse: collapse;
  font-size: 0.72rem;
  line-height: 1.15;
  table-layout: auto;
}

/* PC 표의 colgroup col 폭이 fixed-layout으로 남아있어 가로 스크롤 빈공간이 생김 — 모바일에선 무력화 */
body.is-office-mobile .compact-table > colgroup,
body.is-office-mobile .compact-table > colgroup > col {
  width: auto !important;
}

body.is-office-mobile .compact-table thead th {
  position: sticky;
  top: 0;
  background: #f5efe2;
  color: #3a3025;
  padding: 6px 8px;
  font-size: 0.7rem;
  font-weight: 700;
  text-align: left;
  border-bottom: 1px solid #e6dfd2;
  white-space: nowrap;
  z-index: 1;
}

body.is-office-mobile .compact-table tbody td {
  padding: 3px 8px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  border-bottom: 1px solid #f1ece2;
  vertical-align: middle;
  max-width: 22ch;
}

/* 셀 내부 자식 요소들도 강제로 nowrap (줄바꿈 방지) */
body.is-office-mobile .compact-table tbody td * {
  white-space: nowrap;
  display: inline;
  margin: 0;
  padding: 0;
}

body.is-office-mobile .compact-table tbody td button,
body.is-office-mobile .compact-table tbody td .order-status-badge,
body.is-office-mobile .compact-table tbody td .order-group-toggle,
body.is-office-mobile .compact-table tbody td .order-group-toggle__detail,
body.is-office-mobile .compact-table tbody td .order-group-toggle__body,
body.is-office-mobile .compact-table tbody td .order-group-expand {
  display: inline-flex;
  align-items: center;
  vertical-align: middle;
}

body.is-office-mobile .compact-table tbody tr:last-child td {
  border-bottom: 0;
}

body.is-office-mobile .compact-table .compact-table__col--num,
body.is-office-mobile .compact-table th.sales-table__cell--num,
body.is-office-mobile .compact-table td.sales-table__cell--num {
  text-align: right;
  font-variant-numeric: tabular-nums;
}

body.is-office-mobile .compact-table .compact-table__col--narrow {
  max-width: 12ch;
  overflow: hidden;
  text-overflow: ellipsis;
}

body.is-office-mobile .compact-table tbody td:first-child {
  font-weight: 700;
  color: #2c231b;
}

body.is-office-mobile .compact-table .order-status-badge,
body.is-office-mobile .compact-table .delivery-status-badge {
  font-size: 0.66rem;
  padding: 1px 5px;
  border-radius: 999px;
  white-space: nowrap;
}

/* 모바일 한정 셀 숨김 — TH/TD 모두 적용 */
body.is-office-mobile .compact-table [data-mobile-hide] {
  display: none;
}

/* 행 높이 압축: 부가 메타(단일 주문, 묶음 상품 N건, 전화번호 등)는 모바일에서 숨김 */
body.is-office-mobile .compact-table .order-cell__submeta,
body.is-office-mobile .compact-table .order-group-toggle__badge,
body.is-office-mobile .compact-table .order-cell__meta,
body.is-office-mobile .compact-table .order-cell__phone,
body.is-office-mobile .compact-table .order-cell__shipping-info {
  display: none;
}

/* expand 토글 버튼은 모바일에서 작게 */
body.is-office-mobile .compact-table .order-group-expand {
  width: 16px;
  height: 16px;
  min-width: 16px;
  flex: 0 0 16px;
}

body.is-office-mobile .compact-table .order-group-toggle {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

body.is-office-mobile .compact-table .order-group-toggle__body,
body.is-office-mobile .compact-table .order-group-toggle__detail {
  padding: 0;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

body.is-office-mobile .compact-table .order-cell__order-code,
body.is-office-mobile .compact-table .order-cell__order-label {
  display: inline;
  font-size: 0.78rem;
  line-height: 1.2;
}

/* TD에 data-mobile-hide를 부여하지 못한 경우(렌더러 미수정 상태) nth-child로 컬럼 단위 숨김 */
/* 활성주문(data-orders-tbody): 1=select, 5=상품구분, 7=규격, 8=색상, 9=옵션, 12=ERP번호, 14=수령인, 15=연락처, 16=배송주소, 17=요청사항 숨김 */
body.is-office-mobile [data-orders-tbody] > tr > td:nth-child(1),
body.is-office-mobile [data-orders-tbody] > tr > td:nth-child(5),
body.is-office-mobile [data-orders-tbody] > tr > td:nth-child(7),
body.is-office-mobile [data-orders-tbody] > tr > td:nth-child(8),
body.is-office-mobile [data-orders-tbody] > tr > td:nth-child(9),
body.is-office-mobile [data-orders-tbody] > tr > td:nth-child(12),
body.is-office-mobile [data-orders-tbody] > tr > td:nth-child(14),
body.is-office-mobile [data-orders-tbody] > tr > td:nth-child(15),
body.is-office-mobile [data-orders-tbody] > tr > td:nth-child(16),
body.is-office-mobile [data-orders-tbody] > tr > td:nth-child(17) {
  display: none;
}

/* 이전주문(data-history-orders-tbody): 위와 동일한 컬럼 셋 — 단 select 컬럼 없음 */
/* 컬럼: 1=주문자, 2=플랫폼, 3=상태, 4=상품구분, 5=상품, 6=규격, 7=색상, 8=옵션, 9=수량, 10=금액, 11=ERP, 12=주문일, 13=수령인, 14=연락처, 15=주소, 16=요청사항 */
body.is-office-mobile [data-history-orders-tbody] > tr > td:nth-child(2),
body.is-office-mobile [data-history-orders-tbody] > tr > td:nth-child(4),
body.is-office-mobile [data-history-orders-tbody] > tr > td:nth-child(6),
body.is-office-mobile [data-history-orders-tbody] > tr > td:nth-child(7),
body.is-office-mobile [data-history-orders-tbody] > tr > td:nth-child(8),
body.is-office-mobile [data-history-orders-tbody] > tr > td:nth-child(9),
body.is-office-mobile [data-history-orders-tbody] > tr > td:nth-child(11),
body.is-office-mobile [data-history-orders-tbody] > tr > td:nth-child(13),
body.is-office-mobile [data-history-orders-tbody] > tr > td:nth-child(14),
body.is-office-mobile [data-history-orders-tbody] > tr > td:nth-child(15),
body.is-office-mobile [data-history-orders-tbody] > tr > td:nth-child(16) {
  display: none;
}

/* 제작목록(data-active-orders-tbody): 1=완료, 2=상품, 3=고객, 4=규격, 5=색상, 6=옵션, 7=고객연락, 8=요청사항 — 5,7,8 숨김 */
body.is-office-mobile [data-active-orders-tbody] > tr > td:nth-child(5),
body.is-office-mobile [data-active-orders-tbody] > tr > td:nth-child(7),
body.is-office-mobile [data-active-orders-tbody] > tr > td:nth-child(8) {
  display: none;
}

/* 매출 플랫폼별(data-sales-breakdown-body): 1=구분, 2=매출, 3=주문, 4=수량, 5=미상세 — 4,5 숨김 */
body.is-office-mobile [data-sales-breakdown-body] > tr > td:nth-child(4),
body.is-office-mobile [data-sales-breakdown-body] > tr > td:nth-child(5) {
  display: none;
}

/* 매입 기록(data-purchases-list-body): 1=거래일, 2=매입처, 3=증빙, 4=공급가, 5=세액, 6=합계, 7=동작 — 3,4,5,7 숨김 */
body.is-office-mobile [data-purchases-list-body] > tr > td:nth-child(3),
body.is-office-mobile [data-purchases-list-body] > tr > td:nth-child(4),
body.is-office-mobile [data-purchases-list-body] > tr > td:nth-child(5),
body.is-office-mobile [data-purchases-list-body] > tr > td:nth-child(7) {
  display: none;
}

/* 설치목록(data-delivery-installation-tbody): 1=배정취소, 2=고객연락, 3=수령인, 4=배송원, 5=상태, 6=상품, 7=연락처, 8=주소, 9=사진 */
/* 모바일: 3=수령인, 5=상태, 6=상품, 8=주소만 노출 → 1,2,4,7,9 숨김 */
body.is-office-mobile [data-delivery-installation-tbody] > tr > td:nth-child(1),
body.is-office-mobile [data-delivery-installation-tbody] > tr > td:nth-child(2),
body.is-office-mobile [data-delivery-installation-tbody] > tr > td:nth-child(4),
body.is-office-mobile [data-delivery-installation-tbody] > tr > td:nth-child(7),
body.is-office-mobile [data-delivery-installation-tbody] > tr > td:nth-child(9) {
  display: none;
}

/* 빈 상태 메시지 가독성 */
body.is-office-mobile .active-order-empty,
body.is-office-mobile .delivery-empty,
body.is-office-mobile .order-empty {
  margin: 8px 0;
  padding: 14px;
  border-radius: 12px;
  background: #ffffff;
  text-align: center;
  font-size: 0.9rem;
  color: #6b6258;
}

/* ----- 활성주문 (orders): 일괄변경 막대는 모바일에서 위험하니 숨김 유지 ----- */
body.is-office-mobile [data-panel="orders"] .order-bulk-bar {
  display: none;
}

/* ----- 매출 (sales): 요약 카드는 2열, 원천 주문 섹션은 숨김 ----- */
body.is-office-mobile [data-panel="sales"] .sales-summary-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px;
}

body.is-office-mobile [data-panel="sales"] [data-sales-orders-section],
body.is-office-mobile [data-panel="sales"] .sales-orders,
body.is-office-mobile [data-panel="sales"] .sales-orders-section {
  display: none;
}

/* ----- 매입 (purchases) ----- */
body.is-office-mobile [data-panel="purchases"] .purchases-form__grid {
  grid-template-columns: 1fr !important;
  gap: 8px;
}

body.is-office-mobile [data-panel="purchases"] .purchases-dropzone {
  aspect-ratio: 1 / 1;
  min-height: 60vw;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 16px;
}

body.is-office-mobile [data-panel="purchases"] .purchases-toolbar,
body.is-office-mobile [data-panel="purchases"] .purchases-form__row {
  flex-wrap: wrap;
  gap: 6px;
}


/* ----- 모달을 풀스크린 시트로 ----- */
body.is-office-mobile .option-modal {
  padding: 0;
}

body.is-office-mobile .option-modal__dialog {
  width: 100vw;
  max-width: 100vw;
  height: 100vh;
  max-height: 100vh;
  border-radius: 0;
  margin: 0;
  border: 0;
}

body.is-office-mobile .option-modal__header {
  padding: 14px 14px 12px;
  position: sticky;
  top: 0;
  background: #ffffff;
  z-index: 2;
}

body.is-office-mobile .option-modal__close {
  min-width: 44px;
  min-height: 44px;
  font-size: 1.4rem;
}

body.is-office-mobile .option-modal__body,
body.is-office-mobile .option-modal__footer {
  padding-left: 14px;
  padding-right: 14px;
}

/* 주문 상세 모달도 풀스크린 시트로 (모바일) */
body.is-office-mobile .order-detail-modal {
  padding: 0;
}

body.is-office-mobile .order-detail-modal__dialog {
  width: 100vw;
  max-width: 100vw;
  height: 100vh;
  max-height: 100vh;
  border-radius: 0;
  margin: 0;
  padding: 14px;
  gap: 12px;
  /* 다이얼로그 전체를 하나의 스크롤 영역으로 만든다 — 묶음 항목이 많아도 헤더 아래 모든 콘텐츠를 함께 내려서 볼 수 있다. */
  display: flex;
  flex-direction: column;
  overflow-y: auto;
  overflow-x: hidden;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
}

body.is-office-mobile .order-detail-modal__header {
  position: sticky;
  top: 0;
  background: #ffffff;
  z-index: 2;
  padding-top: 4px;
  padding-bottom: 6px;
  flex: 0 0 auto;
}

body.is-office-mobile .order-detail-modal__stage-track,
body.is-office-mobile .order-detail-modal__group {
  flex: 0 0 auto;
}

body.is-office-mobile .order-detail-modal__close {
  min-width: 44px;
  min-height: 44px;
}

/* 모바일에서는 본문이 자체 스크롤을 가지지 않고 다이얼로그 전체와 함께 흐른다. */
body.is-office-mobile .order-detail-modal__body {
  flex: 0 0 auto;
  min-height: 0;
  overflow: visible;
  padding-right: 0;
  padding-bottom: 24px;
}

/* 묶음 항목 목록도 자체 스크롤 없이 다이얼로그와 함께 흐르도록 한다. */
body.is-office-mobile .order-detail-modal__group-list {
  overflow: visible;
  max-height: none;
}

/* 설치목록·출발대기 상세 모달 — 모바일에서 다이얼로그 전체가 스크롤되도록.
   기본 옵션 모달은 본문만 내부 스크롤을 하지만, 이 모달은 내부에 자체 overflow를 가진
   표가 있어서 본문 스크롤이 활성화되지 않는 경우가 있다. 다이얼로그 전체를 흐르게 만든다. */
body.is-office-mobile .delivery-detail-modal__dialog,
body.is-office-mobile [data-delivery-detail-modal] .option-modal__dialog,
body.is-office-mobile [data-delivery-route-detail-modal] .option-modal__dialog {
  overflow-y: auto;
  overflow-x: hidden;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
}

body.is-office-mobile [data-delivery-detail-modal] .option-modal__header,
body.is-office-mobile [data-delivery-route-detail-modal] .option-modal__header {
  position: sticky;
  top: 0;
  background: #ffffff;
  z-index: 2;
}

body.is-office-mobile [data-delivery-detail-modal] .option-modal__footer,
body.is-office-mobile [data-delivery-route-detail-modal] .option-modal__footer {
  position: sticky;
  bottom: 0;
  background: #ffffff;
  z-index: 2;
}

/* 본문은 자체 스크롤을 꺼서 다이얼로그와 함께 흐르게 한다. */
body.is-office-mobile [data-delivery-detail-modal] .option-modal__body,
body.is-office-mobile [data-delivery-route-detail-modal] .option-modal__body,
body.is-office-mobile .delivery-detail-modal__body {
  flex: 0 0 auto;
  min-height: 0;
  overflow: visible;
  display: block;
}

/* 표 컨테이너의 세로 스크롤은 끄고 가로 스크롤만 허용 — 세로 터치는 다이얼로그로 흘러간다. */
body.is-office-mobile .delivery-detail-table-wrap {
  overflow-x: auto;
  overflow-y: visible;
  min-height: 0;
}

/* 토글식 도구막대 — <details> 패턴 */
.mobile-filter-collapse > summary {
  display: none;
}
body.is-office-mobile .mobile-filter-collapse > summary {
  display: list-item;
  list-style: none;
  cursor: pointer;
  padding: 6px 10px;
  border: 1px solid #d4cabb;
  border-radius: 8px;
  background: #f2ece1;
  font-size: 0.78rem;
  font-weight: 700;
  color: #3a3025;
  user-select: none;
}
body.is-office-mobile .mobile-filter-collapse[open] > summary {
  background: #ffffff;
}
body.is-office-mobile .mobile-filter-collapse {
  width: 100%;
  margin-top: 4px;
}
body.is-office-mobile .mobile-filter-collapse__body {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  padding: 8px 0 0;
}

/* PC에서 details summary 자동 펼침 + 본문 노출 */
.mobile-filter-collapse {
  display: contents;
}
body.is-office-mobile .mobile-filter-collapse {
  display: block;
}

/* 주문 병합 UI */
.order-merge-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin: 0 0 14px;
  padding: 14px 16px;
  border: 1px solid #d6b48a;
  background: #fdf3e1;
}

.order-merge-bar[hidden] {
  display: none;
}

.order-row.is-merge-target,
tr.order-row--summary.is-merge-target,
tr.order-row--detail.is-merge-target {
  outline: 2px solid #c98a3b;
  outline-offset: -2px;
  background: #fff8ec;
}

.order-merge-modal__dialog {
  width: min(100%, 760px);
}

.order-merge-modal__body {
  display: grid;
  gap: 18px;
}

.order-merge-modal__notice {
  padding: 16px 18px;
  border: 1px solid #e2b078;
  border-radius: 14px;
  background: #fff7e6;
  display: grid;
  gap: 6px;
}

.order-merge-modal__notice strong {
  color: #8a4d12;
  font-size: 1rem;
}

.order-merge-modal__notice p {
  margin: 0;
  color: #6b4a1a;
  font-size: 0.92rem;
  line-height: 1.55;
}

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

.order-merge-modal__section-title {
  margin: 0;
  font-size: 1rem;
  font-weight: 700;
  color: #2c241b;
}

.order-merge-modal__list {
  display: grid;
  gap: 10px;
  padding: 14px;
  border: 1px solid #e6e0d6;
  border-radius: 14px;
  background: #ffffff;
}

.order-merge-modal__list-row {
  padding: 10px 12px;
  border: 1px solid #ede5d8;
  border-radius: 10px;
  background: #fbf7ee;
  font-size: 0.92rem;
}

.order-merge-modal__list-row strong {
  display: block;
  color: #2c241b;
  margin-bottom: 4px;
}

.order-merge-modal__list-row dl {
  margin: 4px 0 0;
  display: grid;
  grid-template-columns: 80px minmax(0, 1fr);
  row-gap: 4px;
  column-gap: 8px;
}

.order-merge-modal__list-row dt {
  color: #6b6053;
  font-weight: 600;
}

.order-merge-modal__list-row dd {
  margin: 0;
  color: #2c241b;
}

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

.order-merge-modal__choice {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 12px 14px;
  border: 1px solid #e0d6c6;
  border-radius: 12px;
  background: #ffffff;
  cursor: pointer;
}

.order-merge-modal__choice input[type="radio"] {
  margin-top: 4px;
  flex: 0 0 auto;
}

.order-merge-modal__choice-body {
  display: grid;
  gap: 4px;
  font-size: 0.92rem;
  min-width: 0;
}

.order-merge-modal__choice-title {
  font-weight: 700;
  color: #2c241b;
}

.order-merge-modal__choice-meta {
  color: #6b6053;
  font-size: 0.88rem;
  line-height: 1.5;
}

.order-merge-modal__manual {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  padding: 14px;
  border: 1px dashed #d6c7af;
  border-radius: 12px;
  background: #fbf7ee;
}

.order-merge-modal__manual[hidden] {
  display: none;
}

.order-merge-modal__manual .toolbar-field {
  display: grid;
  gap: 6px;
}

.order-merge-modal__manual .toolbar-field span {
  font-size: 0.85rem;
  color: #6b6053;
}

.order-merge-modal__manual .toolbar-field input {
  padding: 8px 10px;
  border: 1px solid #d8cebd;
  border-radius: 8px;
  background: #ffffff;
  font-size: 0.95rem;
}

.order-merge-modal__manual-field--wide {
  grid-column: 1 / -1;
}

@media (max-width: 720px) {
  .order-merge-modal__manual {
    grid-template-columns: 1fr;
  }
}

/* 병합필요 배지 (확인 필요 배지와 동일한 모양, 주황색 톤) */
.order-merge-required-badge {
  display: inline-flex;
  width: fit-content;
  align-items: center;
  justify-content: center;
  justify-self: center;
  min-height: 24px;
  margin-top: 4px;
  padding: 0 10px;
  border: 1px solid transparent;
  border-radius: 999px;
  background: rgba(220, 132, 38, 0.16);
  color: #8a4d12;
  font-family: inherit;
  font-size: 0.72rem;
  font-weight: 700;
  line-height: 1.3;
  text-align: center;
  cursor: pointer;
  transition: background-color 0.14s ease, color 0.14s ease, opacity 0.14s ease;
}

.order-merge-required-badge:hover,
.order-merge-required-badge:focus-visible {
  background: rgba(220, 132, 38, 0.26);
  color: #6b3a05;
}

.order-merge-required-badge:focus-visible {
  outline: none;
}

.order-merge-required-badge--readonly {
  cursor: default;
}

.order-merge-required-badge--readonly:hover,
.order-merge-required-badge--readonly:focus-visible {
  background: rgba(220, 132, 38, 0.16);
  color: #8a4d12;
}

/* ===== 정산 관리 (ledger-settlement) ===== */
[data-panel="ledger-settlement"] .section-hero__summary {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  width: min(100%, 720px);
  min-width: 0;
  gap: 10px;
}

[data-panel="ledger-settlement"] .section-hero__summary .summary-chip {
  padding: 10px 12px;
  min-width: 0;
  overflow: hidden;
}

[data-panel="ledger-settlement"] .section-hero__summary .summary-chip strong {
  display: block;
  font-size: clamp(0.92rem, 1.4vw, 1.18rem);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.2;
  margin-top: 4px;
}

[data-panel="ledger-settlement"] .section-hero__summary .summary-chip span {
  font-size: 0.74rem;
  color: #6a5f53;
  white-space: nowrap;
}

.panel--ledger-settlement {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.panel__body--ledger-settlement {
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 18px;
}

.ledger-settlement-toolbar {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  padding-bottom: 8px;
  border-bottom: 1px solid #efe7d7;
}

.ledger-settlement-toolbar__filters {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: flex-end;
}

.ledger-settlement-toolbar__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: flex-end;
}

.ledger-settlement-toolbar__bulk {
  display: flex;
  align-items: flex-end;
  gap: 8px;
  flex-wrap: wrap;
}

.ledger-settlement-toolbar__bulk-input input {
  min-width: 120px;
}

.ledger-settlement-back-to-my {
  white-space: nowrap;
}

.ledger-settlement-driver-summary {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 10px;
  padding: 10px 0;
}

.ledger-settlement-driver-summary[hidden] {
  display: none;
}

.ledger-settlement-driver-card {
  border: 1px solid #e7decd;
  border-radius: 10px;
  padding: 10px 12px;
  background: #fffaf3;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.ledger-settlement-driver-card header strong {
  font-size: 0.95rem;
  color: #2d2417;
}

.ledger-settlement-driver-card dl {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px 10px;
  margin: 0;
  font-size: 0.82rem;
}

.ledger-settlement-driver-card dl > div {
  display: flex;
  flex-direction: column;
}

.ledger-settlement-driver-card dt {
  font-weight: 700;
  color: #74461f;
  font-size: 0.72rem;
}

.ledger-settlement-driver-card dd {
  margin: 0;
  color: #2d2417;
  font-weight: 600;
}

.ledger-settlement-table-wrap {
  overflow-x: auto;
}

.ledger-settlement-table {
  min-width: 920px;
}

.ledger-settlement-table th,
.ledger-settlement-table td {
  vertical-align: middle;
}

.ledger-settlement-col--select,
.ledger-settlement-cell--select {
  width: 44px;
}

.ledger-settlement-col--completed { width: 138px; }
.ledger-settlement-col--driver { width: 100px; }
.ledger-settlement-col--receiver { width: 220px; }
.ledger-settlement-col--product { width: 180px; }
.ledger-settlement-col--amount { width: 168px; }
.ledger-settlement-col--status { width: 92px; }
.ledger-settlement-col--actions { width: 220px; }

.ledger-settlement-table tbody tr {
  border-bottom: 1px solid #d6cdb8;
}

.ledger-settlement-table tbody tr:last-child {
  border-bottom: none;
}

.ledger-settlement-table tbody td {
  border-bottom: 1px solid #d6cdb8;
  border-right: 1px solid #ece5d3;
}

.ledger-settlement-table tbody td:last-child {
  border-right: none;
}

.ledger-settlement-row--unrequested td {
  background: #e6e1d5 !important;
  color: #6a6258;
}

.ledger-settlement-row--unrequested .ledger-settlement-receiver strong,
.ledger-settlement-row--unrequested .ledger-settlement-receiver .ledger-settlement-receiver__link,
.ledger-settlement-row--unrequested .ledger-settlement-amount--empty {
  color: #6a6258;
}

.ledger-settlement-row--rejected td {
  background: #fdeeee !important;
}

.ledger-settlement-row--approved td {
  background: #f1f7ef !important;
}

.ledger-settlement-receiver {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.ledger-settlement-receiver strong {
  color: #2d2417;
}

.ledger-settlement-receiver span {
  color: #6a5f53;
  font-size: 0.78rem;
}

.ledger-settlement-receiver__link {
  appearance: none;
  -webkit-appearance: none;
  border: 0;
  background: none;
  padding: 0;
  margin: 0;
  font: inherit;
  font-weight: 700;
  color: #2d2417;
  text-align: left;
  text-decoration: underline;
  text-underline-offset: 2px;
  cursor: pointer;
}

.ledger-settlement-receiver__link:hover,
.ledger-settlement-receiver__link:focus-visible {
  color: #8a5a2b;
}

.ledger-settlement-card__receiver .ledger-settlement-receiver__link {
  font-size: 0.96rem;
}

.ledger-settlement-amount {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.ledger-settlement-amount strong {
  color: #2d2417;
  font-size: 0.92rem;
}

.ledger-settlement-amount__hint {
  font-size: 0.72rem;
  color: #74461f;
}

.ledger-settlement-amount--empty {
  color: #8b7d6c;
  font-weight: 600;
}

.ledger-settlement-amount-input {
  width: 100%;
  min-width: 110px;
  text-align: right;
}

.ledger-settlement-badge {
  display: inline-flex;
  align-items: center;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 0.74rem;
  font-weight: 800;
  background: #efe7d7;
  color: #4a3f33;
  white-space: nowrap;
}

.ledger-settlement-badge--unrequested { background: #ece6d8; color: #6a5f53; }
.ledger-settlement-badge--pending { background: #fff2cf; color: #8a5a09; }
.ledger-settlement-badge--approved { background: #d8efd2; color: #2d6422; }
.ledger-settlement-badge--rejected { background: #f7d6d3; color: #8a2517; }

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

.ledger-settlement-actions__placeholder {
  font-size: 0.78rem;
  color: #8b7d6c;
}

.ledger-settlement-cards {
  display: none;
}

@media (max-width: 720px) {
  .panel__body--ledger-settlement {
    padding: 12px;
  }
  .ledger-settlement-toolbar {
    flex-direction: column;
    align-items: stretch;
  }
  .ledger-settlement-toolbar__filters {
    width: 100%;
  }
  .ledger-settlement-toolbar__filters > * {
    flex: 1 1 calc(50% - 5px);
    min-width: 0;
  }
  .ledger-settlement-toolbar__actions {
    width: 100%;
    flex-direction: column;
    align-items: stretch;
  }
  .ledger-settlement-toolbar__bulk {
    width: 100%;
    flex-direction: column;
    align-items: stretch;
  }
  .ledger-settlement-toolbar__bulk-input input {
    width: 100%;
  }
  .ledger-settlement-table-wrap {
    display: none;
  }
  .ledger-settlement-cards {
    display: flex;
    flex-direction: column;
    gap: 10px;
  }
}

.ledger-settlement-card {
  border: 1px solid #e7decd;
  border-radius: 12px;
  padding: 12px;
  background: #ffffff;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.ledger-settlement-card--unrequested { background: #f5f1ea; }
.ledger-settlement-card--rejected { background: #fdeeee; }
.ledger-settlement-card--approved { background: #f1f7ef; }

.ledger-settlement-card__header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
}

.ledger-settlement-card__date {
  font-size: 0.82rem;
  color: #6a5f53;
}

.ledger-settlement-card__driver {
  margin: 0;
  font-size: 0.88rem;
}

.ledger-settlement-card__driver strong {
  color: #74461f;
}

.ledger-settlement-card__body {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.ledger-settlement-card__receiver {
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.ledger-settlement-card__receiver strong {
  font-size: 0.96rem;
  color: #2d2417;
}

.ledger-settlement-card__receiver span {
  font-size: 0.82rem;
  color: #6a5f53;
}

.ledger-settlement-card__product {
  margin: 0;
  font-size: 0.86rem;
  color: #4a3f33;
}

.ledger-settlement-card__amount {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 8px 10px;
  background: #fffaf3;
  border: 1px solid #efe7d7;
  border-radius: 8px;
  margin-top: 4px;
}

.ledger-settlement-card__amount strong {
  font-size: 1.08rem;
  color: #2d2417;
}

.ledger-settlement-card__amount span {
  font-size: 0.74rem;
  color: #6a5f53;
}

.ledger-settlement-card__amount--empty {
  color: #8b7d6c;
  font-weight: 700;
}

.ledger-settlement-card__amount-input label {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 0.84rem;
  font-weight: 700;
  color: #4a3f33;
}

.ledger-settlement-card__amount-input input {
  font-size: 1.05rem;
  text-align: right;
  padding: 10px;
  min-height: 44px;
}

.ledger-settlement-card__footer {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.ledger-settlement-card__footer .toolbar-button {
  flex: 1 1 auto;
  min-height: 40px;
}

/* 배송원 모바일 모드의 정산 관리 화면 */
body.is-delivery-mobile [data-panel="ledger-settlement"] .section-hero {
  flex-direction: column;
  align-items: stretch;
  padding: 14px;
  gap: 10px;
}

body.is-delivery-mobile [data-panel="ledger-settlement"] .section-hero__summary {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

body.is-delivery-mobile [data-panel="ledger-settlement"] .ledger-settlement-table-wrap {
  display: none;
}

body.is-delivery-mobile [data-panel="ledger-settlement"] .ledger-settlement-cards {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

body.is-delivery-mobile [data-panel="ledger-settlement"] .ledger-settlement-toolbar {
  flex-direction: column;
  align-items: stretch;
  gap: 10px;
}

body.is-delivery-mobile [data-panel="ledger-settlement"] .ledger-settlement-toolbar__filters,
body.is-delivery-mobile [data-panel="ledger-settlement"] .ledger-settlement-toolbar__actions,
body.is-delivery-mobile [data-panel="ledger-settlement"] .ledger-settlement-toolbar__bulk {
  width: 100%;
  flex-direction: column;
  align-items: stretch;
}

body.is-delivery-mobile [data-panel="ledger-settlement"] .panel__body--ledger-settlement {
  padding: 12px;
}

body.is-delivery-mobile [data-panel="ledger-settlement"] .ledger-settlement-back-to-my {
  min-height: 44px;
  font-size: 0.96rem;
}

.remark-notification-modal {
  position: fixed;
  inset: 0;
  z-index: 12000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
}

.remark-notification-modal__scrim {
  position: absolute;
  inset: 0;
  background: rgba(20, 16, 12, 0.6);
}

.remark-notification-modal__dialog {
  position: relative;
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  max-width: 640px;
  width: 100%;
  max-height: 88vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.remark-notification-modal__header {
  padding: 20px 24px 12px;
  border-bottom: 1px solid #efe7da;
  background: #fff8ed;
}

.remark-notification-modal__header h2 {
  margin: 0 0 6px;
  font-size: 18px;
  color: #2a1d10;
}

.remark-notification-modal__header p {
  margin: 0;
  font-size: 13px;
  color: #6a5a45;
}

.remark-notification-modal__list {
  padding: 12px 24px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 12px;
  flex: 1;
}

.remark-notification-modal__item {
  border: 1px solid #e9dfcc;
  border-radius: 10px;
  padding: 12px 14px;
  background: #fdfaf3;
}

.remark-notification-modal__item-meta {
  display: flex;
  gap: 8px;
  align-items: baseline;
  font-size: 13px;
  color: #3a2a18;
  margin-bottom: 6px;
}

.remark-notification-modal__item-meta strong {
  font-size: 14px;
}

.remark-notification-modal__item-body {
  white-space: pre-wrap;
  background: #fff;
  border: 1px solid #ecdfc8;
  border-radius: 8px;
  padding: 10px 12px;
  font-size: 13.5px;
  line-height: 1.5;
  color: #2a1d10;
  min-height: 44px;
}

.remark-notification-modal__item-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 8px;
  font-size: 12px;
  color: #6e5e4a;
  gap: 12px;
}

.remark-notification-modal__item-footer button {
  background: #b8895a;
  color: #fff;
  border: none;
  border-radius: 8px;
  padding: 7px 14px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
}

.remark-notification-modal__item-footer button:hover {
  background: #a07344;
}

.remark-notification-modal__footer {
  padding: 14px 24px;
  border-top: 1px solid #efe7da;
  display: flex;
  justify-content: flex-end;
  background: #fbf5ea;
}

.remark-notification-modal__close {
  background: #2a1d10;
  color: #fff;
  border: none;
  border-radius: 10px;
  padding: 10px 18px;
  font-weight: 700;
  font-size: 14px;
  cursor: pointer;
}

.remark-notification-modal__close:hover {
  background: #1a120a;
}

.remark-notification-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #f3d189;
  color: #4b2f0c;
  border-radius: 999px;
  padding: 4px 12px;
  font-size: 12px;
  font-weight: 600;
}

.delivery-remark-editor {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-top: 8px;
  padding: 10px;
  border: 1px dashed #d6c6ac;
  border-radius: 8px;
  background: #fbf6ea;
}

.delivery-remark-editor textarea {
  width: 100%;
  min-height: 56px;
  resize: vertical;
  padding: 8px 10px;
  border: 1px solid #d6c6ac;
  border-radius: 6px;
  font-size: 13px;
  font-family: inherit;
}

.delivery-remark-editor__actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
}

.delivery-remark-editor__save {
  background: #b8895a;
  color: #fff;
  border: none;
  border-radius: 6px;
  padding: 6px 14px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
}

.delivery-remark-editor__save:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.delivery-remark-trigger {
  margin-top: 6px;
  display: inline-block;
  background: #fbeed1;
  color: #5a3d11;
  border: 1px solid #e6d3a3;
  border-radius: 6px;
  padding: 4px 10px;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
}

.delivery-remark-trigger:hover {
  background: #f0dca8;
}

.settlement-product-list {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 0.9rem;
}

.settlement-product-item {
  padding: 3px 6px;
  border-left: 2px solid #c9b48a;
  background: #fdf9ef;
  border-radius: 0 4px 4px 0;
  line-height: 1.4;
}

.settlement-col-product {
  min-width: 200px;
}
