/* Merchant workspace: neutral surfaces, restrained green, compact operating controls. */
:root {
  --ink: #252d29;
  --muted: #737d77;
  --green: #245e48;
  --green-dark: #184331;
  --cream: #fff;
  --paper: #fff;
  --line: #e8ece9;
  --soft: #edf4ef;
  --danger: #ad453b;
  --warning: #8b672e;
  font-size: 14px;
  background: #fff;
  -webkit-font-smoothing: antialiased;
}
body { min-width: 320px; }
h1 { font-family: var(--ui-font-title); font-size: 27px; font-weight: 700; letter-spacing:0; }
h2 { font-family: var(--ui-font-title); font-size: 17px; font-weight: 700; letter-spacing:0; }
h3 { font-weight: 500; }
.ui-icon {
  display: inline-block;
  flex-shrink: 0;
  width: 20px;
  height: 20px;
  background: currentColor;
  -webkit-mask: var(--icon) center / contain no-repeat;
  mask: var(--icon) center / contain no-repeat;
}
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-height: 38px;
  padding: 9px 16px;
  border-radius: var(--ui-radius-control);
  font-size: 13px;
  font-weight: 500;
  line-height: 1.4;
  white-space: nowrap;
}
.button .ui-icon { width: 16px; height: 16px; }
.button.secondary { border-color: #dce3de; background: white; }
.button.secondary:hover { background: #f6f8f6; border-color: #b9c8be; }
.button.small { min-height: 32px; padding: 6px 11px; font-size: 12px; }
.button.subtle:hover { background: #eef2ef; }
button:disabled { cursor: not-allowed; }
.button.full { width: 100%; }
.badge { font-size: 11px; padding: 5px 8px; border-radius: 4px; }
.badge.neutral { color: #737b75; background: #f0f2f0; }
.badge.warning { background: #faf3e6; color: var(--warning); }
.notice { padding: 12px 16px; border-left-width: 2px; border-radius: 0 5px 5px 0; }
.notice.warning { background: #fcf7ec; }
.field { font-size: 13px; gap: 8px; }
.field-label { font-weight: 500; }
.field input,.field select,.field textarea,input.control,select.control {
  border-color: #dce3de;
  border-radius: 8px;
  padding: 11px 12px;
  font-size: 13px;
  transition: border-color .15s, box-shadow .15s;
}
.field input:hover,.field select:hover,.field textarea:hover { border-color: #b8c5bd; }
.field input:focus,.field select:focus,.field textarea:focus,input.control:focus {
  border-color: #438164;
  outline: none;
  box-shadow: 0 0 0 3px #245e4812;
}
.field input::placeholder,.field textarea::placeholder,input.control::placeholder { color: #909991; }
.form-grid { gap: 24px; }
.form-stack { gap: 20px; }
.checkbox,.content-toggle { font-size: 13px; }
.checkbox input { width: 16px; height: 16px; }
.skip-link { position: fixed; top: -80px; left: 16px; z-index: 120; padding: 12px 16px; background: var(--green); color: white; border-radius: 6px; }
.skip-link:focus { top: 12px; }
.shell { display: grid; grid-template-columns: 224px minmax(0,1fr); min-height: 100vh; }
.sidebar {
  width: 224px;
  position: fixed;
  inset: 0 auto 0 0;
  background: #f7f9f7;
  border-right: 1px solid var(--line);
  padding: 28px 18px 20px;
  display: flex;
  flex-direction: column;
  z-index: 5;
}
.brand-lockup { display: flex; align-items: center; gap: 11px; padding: 0 7px; }
.brand-mark { width: 43px; height: 43px; object-fit: contain; flex-shrink: 0; }
.brand { font-family: var(--ui-font-title); font-weight: 700; font-size: 22px; letter-spacing: -.6px; color: #214c3b; }
.brand-caption { font-size: 10px; margin-top: 4px; letter-spacing: 1.3px; color: #7c8980; }
.nav { display: flex; flex-direction: column; gap: 5px; margin-top: 32px; }
.nav-group-label { color: #879188; font-size: 10px; letter-spacing: 1px; padding: 0 13px 9px; }
.nav-group-label:not(:first-child) { margin-top: 29px; }
.nav button {
  border: 0;
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 44px;
  padding: 11px 13px;
  text-align: left;
  color: #68756c;
  background: transparent;
  border-radius: 6px;
  font-size: 14px;
  transition: color .15s, background .15s;
}
.nav button:hover { background: #ecf0ec; color: var(--green); }
.nav button.active { color: var(--green); background: #e6eee7; font-weight: 500; }
.nav button .ui-icon { width: 19px; height: 19px; }
.sidebar-footer { margin-top: auto; display: flex; flex-direction: column; gap: 14px; padding: 24px 8px 0; }
.sidebar-footer .button { justify-content: flex-start; padding: 10px 0; min-height: 40px; }
.store-sign { display: flex; align-items: center; gap: 9px; border-top: 1px solid var(--line); padding-top: 19px; font-size: 12px; color: var(--muted); }
.store-sign .ui-icon { width: 16px; height: 16px; }
.workspace { grid-column: 2; padding: 0 34px 44px; min-width: 0; }
.topbar { height: 64px; display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid var(--line); gap: 20px; font-size: 12px; }
.breadcrumb { display: flex; gap: 12px; color: #8b958f; }
.breadcrumb [data-current-page] { color: #4d5b52; }
.topbar-right { display: flex; align-items: center; gap: 22px; }
.topbar .badge { font-size: 10px; background: #faf7ef; }
.preview-link { display: inline-flex; align-items: center; gap: 5px; color: #65766a; font-size: 12px; }
.preview-link .ui-icon { width: 14px; height: 14px; }
.page-heading { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 31px 0 26px; }
.page-heading p { margin-top: 8px; font-size: 13px; color: var(--muted); line-height: 1.6; }
.metrics { display: grid; grid-template-columns: repeat(4,1fr); padding: 9px 0 29px; margin-bottom: 27px; border-bottom: 1px solid var(--line); }
.metric { padding-left: 28px; border-left: 1px solid var(--line); }
.metric:first-child { padding-left: 0; border: 0; }
.metric span { display: block; font-size: 13px; color: var(--muted); }
.metric strong { font-family: var(--ui-font-number); display: block; margin-top: 14px; font-size: 30px; line-height: 1; font-weight: 700; letter-spacing: -.9px; font-variant-numeric: tabular-nums; }
.metric:first-child strong { color: var(--green); }
.section-heading { margin-bottom: 19px; }
.list-title { display: flex; align-items: center; gap: 10px; }
.list-count { font-size: 11px; color: var(--muted); border: 1px solid var(--line); border-radius: 4px; padding: 2px 6px; }
.auto-refresh { font-size: 11px; color: #8c9690; }
.toolbar { display: flex; justify-content: space-between; gap: 18px; align-items: center; margin-bottom: 18px; }
.tabs { display: flex; align-items: center; gap: 4px; flex-wrap: wrap; }
.tabs button { background: transparent; color: #778279; border: 0; border-radius: 5px; padding: 8px 12px; font-size: 12px; min-height: 35px; transition: background .15s; }
.tabs button:hover { background: #f3f6f3; }
.tabs button.active { color: var(--green); background: var(--soft); font-weight: 500; }
.search-wrap { display: flex; align-items: center; position: relative; max-width: 100%; }
.search-wrap .ui-icon { width: 15px; height: 15px; color: #8f9a92; position: absolute; left: 12px; pointer-events: none; }
input.control.search { width: 258px; padding: 9px 12px 9px 35px; font-size: 11px; background: #fff; }
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: 8px; scrollbar-width: thin; }
.data-table { width: 100%; border-collapse: collapse; white-space: nowrap; font-size: 13px; text-align: left; }
.data-table th { font-weight: 500; color: #78837b; font-size: 12px; background: #f7f9f7; padding: 13px 15px; border-bottom: 1px solid var(--line); }
.data-table td { padding: 18px 15px; border-bottom: 1px solid #eef1ee; }
.data-table td:first-child,.data-table th:first-child { padding-left: 18px; }
.data-table tbody tr:last-child td { border-bottom: 0; }
.data-table tbody tr { transition: background .12s; }
.data-table tbody tr:hover { background: #fafcf9; }
.table-secondary { font-size: 12px; color: #78837b; margin-top: 6px; line-height: 1.5; }
.number { font-family: var(--ui-font-number); font-weight: 700; font-size: 14px; font-variant-numeric: tabular-nums; }
.data-table .amount { font-family: var(--ui-font-number); font-weight: 700; font-size: 14px; }
.status-stack { display: flex; gap: 7px; align-items: center; }
.order-destination { min-width: 205px; max-width: 280px; white-space: normal!important; }
.order-destination strong { font-size: 12px; font-weight: 500; }
.order-destination .table-secondary { overflow-wrap: anywhere; }
.view { animation: enter .16s ease; }
.view>.notice { margin-bottom: 20px; }
.product-cell { display: flex; align-items: center; gap: 15px; }
.product-cell img { width: 58px; height: 64px; object-fit: contain; border-radius: 5px; background: #f9faf7; }
.product-name { font-size: 14px; font-weight: 500; }
.product-description { font-size: 12px; color: var(--muted); margin-top: 7px; white-space: normal; max-width: 330px; line-height: 1.5; }
.settings-form { max-width: 960px; padding-bottom: 16px; }
.form-section { padding: 28px 0 30px; border-bottom: 1px solid var(--line); }
.form-section:first-child { padding-top: 0; }
.form-section h2 { font-size: 16px; margin-bottom: 24px; }
.form-section>p { font-size: 12px; color: var(--muted); margin: -12px 0 23px; }
.form-save { position: sticky; bottom: 0; padding: 18px 0; background: #fffffff5; display: flex; align-items: center; gap: 16px; border-top: 1px solid var(--line); z-index: 2; }
.form-save small { font-size: 11px; }
.zone-row,.choice-row { display: flex; align-items: flex-end; gap: 10px; margin-top: 12px; }
.zone-row .field { flex: 1; }
.zone-row .field:first-child { max-width: 180px; }
.choice-row .field:first-child { flex: 1; }
.choice-row .field:nth-child(2) { width: 110px; }
.option-group { padding: 22px 0; border-top: 1px solid var(--line); }
.option-title { display: flex; gap: 12px; align-items: flex-end; margin-bottom: 18px; }
.option-title>.field { flex: 1; }
.option-heading { display: flex; align-items: center; justify-content: space-between; }
.option-group .checks { padding: 2px 0 6px; }
.dialog { border: 1px solid #e0e6e1; border-radius: 10px; box-shadow: 0 24px 100px #13291a28; }
.dialog::backdrop { background: #17271d47; backdrop-filter: blur(2px); }
.dialog-header { padding: 18px 24px; }
.dialog-header h2 { font-size: 16px; overflow-wrap: anywhere; }
.dialog-header .button { min-height: 32px; flex-shrink: 0; }
.dialog-body { padding: 24px; }
.order-summary { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; margin: 0; padding: 2px 0 23px; }
.order-summary dt { font-size: 11px; color: var(--muted); margin-bottom: 7px; }
.order-summary dd { margin: 0; font-size: 13px; line-height: 1.6; }
.order-items { border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); margin: 18px 0; }
.order-item { padding: 18px 0; display: flex; justify-content: space-between; gap: 18px; font-size: 13px; }
.order-item+.order-item { border-top: 1px dashed var(--line); }
.order-totals { display: flex; flex-direction: column; gap: 10px; font-size: 12px; margin-bottom: 22px; }
.order-totals .grand-total { font-family: var(--ui-font-number); font-size: 18px; font-weight: 700; margin-top: 8px; }
.order-actions { padding-top: 20px; border-top: 1px solid var(--line); }
.refund-row { padding: 14px 0; border-bottom: 1px solid var(--line); font-size: 13px; }
.readiness-list { margin-top: 24px; }
.readiness-row { display: grid; grid-template-columns: 170px 1fr auto; align-items: center; gap: 24px; border-bottom: 1px solid var(--line); padding: 24px 0; }
.readiness-row strong { font-size: 13px; font-weight: 500; }
.readiness-row p { font-size: 12px; color: var(--muted); }
.map-config-section { margin-top: 34px; padding: 0 0 24px; max-width: 880px; }
.map-config-section>p { font-size: 12px; line-height: 1.8; }
.form-section .map-location-result p { margin: 6px 0 0; font-size: 12px; }
.form-section .map-location-result small { display: block; margin-top: 8px; }
.location-tools .button { display: inline-flex; }
.empty { padding: 76px 24px; border-top: 1px solid var(--line); }
.empty-symbol { display: flex; justify-content: center; color: #90a496; }
.empty-symbol .ui-icon { width: 32px; height: 32px; }
.empty strong { font-size: 16px; font-weight: 500; }
.empty p { font-size: 12px; }
.login-page { min-height: 100svh; display: grid; grid-template-columns: 45% 55%; }
.login-brand { position: relative; overflow: hidden; min-height: 100svh; background: #f1f2e9; padding: 48px; display: flex; flex-direction: column; justify-content: space-between; }
.login-brand .brand-lockup { position: relative; z-index: 1; align-self: flex-start; }
.login-photo { position: absolute; width: 100%; height: 100%; object-fit: cover; object-position: center; inset: 0; }
.login-main { padding: 60px 10%; display: flex; align-items: center; justify-content: center; }
.login-form { width: 100%; max-width: 355px; }
.login-form h1 { font-size: 28px; margin-bottom: 12px; }
.login-form .eyebrow { font-size: 10px; letter-spacing: 1.5px; color: var(--green); }
.login-form>p { font-size: 12px; color: var(--muted); margin-bottom: 30px; }
.login-form .field { margin: 22px 0; }
.login-form .field input { height: 46px; }
.login-form>.button { height: 44px; }
.login-form .login-footer { font-size: 11px; color: #929b95; line-height: 1.8; margin: 22px 0; }
.login-form .login-error { font-size: 12px; line-height: 1.6; color: var(--danger); margin: 12px 0; }
.login-error:empty { display: none; }
.login-form .quiet-link { font-size: 12px; }
@media(min-width:1600px) {
  .workspace { padding-left: 48px; padding-right: 48px; }
  .page-heading,.view { max-width: 1392px; margin-left: auto; margin-right: auto; }
}
@media(max-width:1180px) {
  .shell { grid-template-columns: 196px minmax(0,1fr); }
  .sidebar { width: 196px; padding-left: 14px; padding-right: 14px; }
  .workspace { padding-left: 25px; padding-right: 25px; }
  .toolbar { align-items: flex-start; flex-direction: column; gap: 13px; }
  .metric { padding-left: 20px; }
  .metric strong { font-weight: 700; font-family: var(--ui-font-number); font-size: 27px; }
  .brand-mark { width: 37px; height: 37px; }
  .brand { font-weight: 700; font-family: var(--ui-font-title); font-size: 20px; }
}
@media(max-width:760px) {
  .shell { display: block; }
  .sidebar { position: static; width: 100%; padding: 15px 16px 10px; border-right: 0; border-bottom: 1px solid var(--line); display: grid; grid-template-columns: 1fr auto; }
  .brand-lockup { gap: 8px; padding: 0; }
  .brand-mark { width: 33px; height: 33px; }
  .brand { font-weight: 700; font-family: var(--ui-font-title); font-size: 19px; }
  .brand-caption { font-size: 9px; margin-top: 2px; }
  .nav { grid-column: 1/-1; grid-row: 2; margin-top: 16px; flex-direction: row; gap: 5px; overflow-x: auto; scrollbar-width: none; }
  .nav button { flex-shrink: 0; padding: 10px 12px; min-height: 42px; font-size: 12px; gap: 7px; }
  .nav button .ui-icon { width: 17px; height: 17px; }
  .nav-group-label { display: none; }
  .sidebar-footer { grid-row: 1; grid-column: 2; padding: 0; margin: 0; }
  .sidebar-footer .store-sign { display: none; }
  .sidebar-footer .button { font-size: 11px; padding: 9px 0 9px 12px; }
  .sidebar-footer .button .ui-icon { width: 15px; height: 15px; }
  .workspace { padding: 0 18px 30px; }
  .topbar { height: 48px; gap: 10px; }
  .breadcrumb { display: none; }
  .topbar-right { justify-content: space-between; gap: 12px; width: 100%; }
  .topbar .badge { font-size: 9px; padding: 4px 6px; }
  .preview-link { font-size: 10px; }
  .page-heading { padding: 24px 0 22px; gap: 12px; align-items: flex-start; }
  h1 { font-weight: 700; font-family: var(--ui-font-title); font-size: 23px; }
  .page-heading p { font-size: 11px; margin-top: 7px; max-width: 250px; }
  .page-heading .button { min-height: 34px; padding: 7px 10px; font-size: 11px; }
  .page-heading .button .ui-icon { width: 14px; height: 14px; }
  .metrics { grid-template-columns: repeat(2,1fr); padding: 2px 0 24px; gap: 25px 0; margin-bottom: 24px; }
  .metric:nth-child(3) { border: 0; padding-left: 0; }
  .metric span { font-size: 11px; }
  .metric strong { font-weight: 700; font-family: var(--ui-font-number); font-size: 27px; margin-top: 10px; }
  .auto-refresh { font-size: 10px; }
  .list-title h2 { font-size: 16px; }
  .tabs { flex-wrap: nowrap; gap: 1px; width: 100%; justify-content: space-between; }
  .tabs button { font-size: 11px; padding: 9px 8px; white-space: nowrap; }
  .toolbar { gap: 14px; }
  .search-wrap,input.control.search { width: 100%; }
  .data-table th,.data-table td { padding-left: 13px; padding-right: 13px; }
  .form-grid { gap: 18px; }
  .form-section h2 { font-size: 16px; }
  .form-section>p { line-height: 1.8; }
  .form-save { padding: 16px 0; gap: 12px; }
  .form-save small { font-size: 10px; }
  .readiness-row { grid-template-columns: 1fr auto; gap: 9px; padding: 22px 0; }
  .readiness-row p { grid-row: 2; grid-column: 1/-1; }
  .zone-row .field:first-child { max-width: 100px; }
  .zone-row { gap: 7px; }
  .zone-row .button { padding: 10px 3px; }
  .dialog-header { padding: 16px 18px; }
  .dialog-body { padding: 20px 18px; }
  .dialog-header h2 { font-size: 15px; }
  .order-summary { gap: 18px 10px; }
  .login-page { display: block; }
  .login-brand { min-height: 0; padding: 24px; background: #f3f6ef; }
  .login-photo { display: none; }
  .login-main { padding: 48px 26px; }
  .login-form { max-width: 430px; }
}
@media(max-width:370px) {
  .workspace { padding-left: 14px; padding-right: 14px; }
  .tabs button { padding-left: 6px; padding-right: 6px; font-size: 10px; }
}

.map-picker-frame { width: 100%; height: min(62vh, 540px); min-height: 340px; border: 1px solid var(--line, #e4e8e3); border-radius: 12px; }
@media (max-width: 640px) { .map-picker-frame { height: 58vh; min-height: 300px; } }
