:root {
  color-scheme: light;
  --page: #F3F4F6;
  --sidebar: #F8F9FA;
  --paper: #FFFFFF;
  --paper-soft: #F7F8FA;
  --paper-hover: #F1F3F5;
  --ink: #262626;
  --ink-pure: #000000;
  --text-secondary: #4B5563;
  --muted: #6B7280;
  --soft: #9CA3AF;
  --line: #E5E7EB;
  --brand: #F26B21;
  --brand-hover: #F26B21;
  --brand-soft: #F1F3F5;
  --brand-dark: #262626;
  --brand-line: #E5E7EB;
  --green: #198B5B;
  --green-dark: #176C45;
  --green-soft: #EAF7F0;
  --green-line: #CFE5D8;
  --warning: #F26B21;
  --warning-dark: #262626;
  --warning-soft: #F1F3F5;
  --warning-line: #E5E7EB;
  --info: #5987C6;
  --info-dark: #315F99;
  --info-soft: #EDF4FF;
  --info-line: #CFE0F6;
  --danger: #D91525;
  --danger-soft: #FFF0F1;
  --offline: #737373;
  --offline-soft: #F1F3F5;
  --courier-accent-purple: #6E40C9;
  --courier-accent-pink: #B8326C;
  --courier-accent-turquoise: #0F766E;
  --courier-accent-cyan: #0B7185;
  --courier-accent-indigo: #4F46A5;
  --shadow-color: rgb(0 0 0 / 7%);
  --shadow: 0 12px 35px var(--shadow-color);
  --brand-ring: rgb(242 107 33 / 24%);
  --acceptance: #F4C542;
  --acceptance-dark: #262626;
  --acceptance-soft: #FFF7D6;
  --badge-delivery-bg: #EAF1F8;
  --badge-delivery-fg: #315F99;
  --badge-delivery-line: #D6E3F0;
  --badge-pickup-bg: #FFF5DC;
  --badge-pickup-fg: #745500;
  --badge-pickup-line: #EBDDAD;
  --badge-paid-bg: #E9F5EE;
  --badge-paid-fg: #176C45;
  --badge-paid-line: #CFE5D8;
  --badge-due-bg: #FBEAEC;
  --badge-due-fg: #A92732;
  --badge-due-line: #F0CDD1;
  --green-ring: rgb(25 139 91 / 18%);
  --scrim: rgb(0 0 0 / 30%);
  --overlay: rgb(0 0 0 / 42%);
  --paper-glass: rgb(255 255 255 / 94%);
  font-family: "DM Sans", "Segoe UI", sans-serif;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

* { box-sizing: border-box; }
body { margin: 0; min-width: 320px; min-height: 100vh; background: var(--page); color: var(--ink); }
button { color: inherit; font: inherit; }
svg { fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.app-shell { display: grid; grid-template-columns: 236px minmax(0, 1fr); min-height: 100vh; padding: 0 8px 8px 0; }
.app-shell[hidden], .login-screen[hidden] { display: none !important; }

.login-screen { display: grid; min-height: 100vh; place-items: center; align-content: center; gap: 14px; padding: 28px 16px; background: #F4F4F4; }
.login-card { width: min(100%, 402px); overflow: hidden; border: 1px solid #E8E8E8; border-radius: 24px; background: #fff; }
.login-card-content { padding: 25px 24px 24px; text-align: center; }
.login-brand-mark { display: block; width: 76px; height: 76px; margin: 0 auto 12px; object-fit: contain; }
.login-card h1 { margin: 0 0 11px; color: #161616; font-size: 19px; font-weight: 700; letter-spacing: -.025em; }
.login-account-caption { margin: -6px 0 14px; color: #696969; font-size: 12px; text-align: center; }
.login-step { display: grid; gap: 16px; }
.login-step[hidden] { display: none !important; }
.login-field { display: grid; gap: 3px; min-height: 54px; padding: 8px 11px 7px; border: 1px solid #272727; border-radius: 12px; background: #fff; text-align: center; }
.login-field:focus-within { border-color: var(--brand); box-shadow: 0 0 0 3px var(--brand-ring); }
.login-field > span { color: #505050; font-size: 10px; font-weight: 500; }
.login-field input { width: 100%; min-width: 0; padding: 0; border: 0; outline: 0; color: #171717; background: transparent; font: inherit; font-size: 13px; text-align: center; }
.login-field input::placeholder { color: #A1A1A1; }
.login-primary { min-height: 48px; border: 0; border-radius: 12px; color: #fff; background: var(--brand); font-size: 14px; font-weight: 700; cursor: pointer; transition: background .15s ease, transform .15s ease; }
.login-primary:hover { background: #E85E15; }
.login-primary:disabled { opacity: .65; cursor: wait; }
.login-primary:active { transform: translateY(1px); }
.login-back, .login-help, .login-preview-return { border: 0; color: #252525; background: transparent; font: inherit; cursor: pointer; }
.login-back { justify-self: center; padding: 1px 8px; color: #676767; font-size: 12px; }
.login-back:hover, .login-help:hover, .login-preview-return:hover { color: var(--brand-dark); text-decoration: underline; }
.login-card-footer { display: grid; min-height: 60px; place-items: center; padding: 10px 16px; border-top: 1px solid #E8E8E8; }
.login-help { min-height: 38px; padding: 4px 10px; font-size: 12px; font-weight: 600; }
.login-message { margin: 14px 0 0; padding: 10px 11px; border-radius: 9px; color: #454545; background: #F5F5F5; font-size: 11px; line-height: 1.5; text-align: center; }
.login-message[hidden] { display: none !important; }
.login-preview-return { padding: 6px 10px; color: #737373; font-size: 11px; }
.login-primary:focus-visible, .login-back:focus-visible, .login-help:focus-visible, .login-preview-return:focus-visible { outline: 3px solid var(--brand-ring); outline-offset: 3px; }

.sidebar { position: sticky; top: 0; display: flex; flex-direction: column; height: 100vh; min-height: 600px; padding: 10px 8px 12px; background: var(--sidebar); border-right: 1px solid var(--line); z-index: 10; }
.brand-row { display: flex; align-items: center; gap: 10px; min-height: 40px; padding: 0 9px; margin-bottom: 5px; }
.brand-mark { width: 29px; height: 29px; border-radius: 9px; object-fit: cover; }
.brand-copy { display: grid; gap: 1px; min-width: 0; }
.brand-copy strong { font-size: 13px; line-height: 1.2; letter-spacing: -.025em; }
.brand-copy span { color: var(--brand-dark); font-size: 10px; font-weight: 700; }
.icon-button { display: inline-grid; place-items: center; width: 36px; height: 36px; padding: 0; border: 0; border-radius: 11px; color: var(--text-secondary); background: transparent; cursor: pointer; transition: color .16s ease, background .16s ease, transform .16s ease; }
.icon-button:hover { color: var(--ink); background: var(--page); }
.icon-button:active { transform: scale(.96); }
.icon-button svg { width: 19px; height: 19px; }
.sidebar-close { display: none; margin-left: auto; }
.sidebar-collapse-row { display: flex; justify-content: flex-end; padding: 0 3px; margin: 0 0 7px; }
.sidebar-collapse-toggle { display: inline-flex; align-items: center; justify-content: center; gap: 7px; min-height: 31px; padding: 0 9px; border: 1px solid var(--line); border-radius: 9px; color: var(--text-secondary); background: var(--paper); font: inherit; font-size: 10px; font-weight: 650; cursor: pointer; transition: color .16s ease, border-color .16s ease, background .16s ease; }
.sidebar-collapse-toggle:hover { color: var(--ink); border-color: var(--brand-line); background: var(--paper-soft); }
.sidebar-collapse-toggle:focus-visible { outline: 3px solid var(--brand-ring); outline-offset: 2px; }
.sidebar-collapse-toggle svg { flex: 0 0 15px; width: 15px; height: 15px; }
.sidebar-collapse-toggle span { white-space: nowrap; }
.sidebar-collapse-toggle[aria-expanded="false"] svg { transform: rotate(180deg); }

.store-status { width: 100%; padding: 12px 12px 11px; margin: 3px 0 11px; border: 1px solid var(--line); border-radius: 15px; color: var(--ink); background: var(--paper); box-shadow: 0 2px 8px var(--shadow-color); text-align: left; font: inherit; cursor: pointer; transition: border-color .16s ease, background .16s ease; }
.store-status:hover { border-color: var(--brand-line); }
.store-status:focus-visible { outline: 3px solid var(--brand-ring); outline-offset: 2px; }
.store-status-top { display: flex; align-items: center; gap: 8px; }
.status-indicator { width: 9px; height: 9px; border-radius: 50%; background: var(--brand); box-shadow: 0 0 0 4px var(--brand-soft); }
.store-status-top strong { font-size: 12px; font-weight: 700; }
.store-status p { margin: 5px 0 8px; color: var(--muted); font-size: 11px; }
.store-status p:last-child { margin-bottom: 0; }
.store-status.is-open .status-indicator { background: var(--green); box-shadow: 0 0 0 4px var(--green-soft); }
.store-status.is-open .store-status-top strong { color: var(--green-dark); }
.store-status.is-closed { border-color: var(--danger-soft); background: var(--danger-soft); }
.store-status.is-closed .status-indicator { background: var(--danger); box-shadow: 0 0 0 4px #FDE1E3; }
.store-status.is-closed .store-status-top strong { color: var(--danger); }

.navigation { display: flex; flex-direction: column; gap: 3px; min-height: 0; }
.nav-label { margin: 12px 10px 6px; color: var(--text-secondary); font-size: 9px; font-weight: 800; letter-spacing: .12em; }
.nav-item { display: flex; align-items: center; gap: 11px; min-height: 40px; width: 100%; padding: 0 10px; border: 0; border-radius: 10px; color: var(--ink); background: transparent; text-align: left; font-size: 12px; font-weight: 600; cursor: pointer; transition: background .16s ease, color .16s ease, transform .16s ease; }
.nav-item svg, .nav-item img { flex: 0 0 18px; width: 18px; height: 18px; color: var(--text-secondary); object-fit: contain; }
.nav-item span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.nav-item:hover { color: var(--ink); background: var(--page); }
.nav-item:active { transform: scale(.985); }
.nav-item.is-active { color: var(--ink); background: var(--paper); box-shadow: 0 2px 7px var(--shadow-color); }
.nav-item.is-active svg { color: var(--brand-dark); }
.preferences-label { margin-top: 17px; }

.sidebar-bottom { margin-top: auto; padding: 12px 0 0; }
.account-row { position: relative; display: flex; align-items: center; gap: 9px; padding: 12px 6px 9px; margin-top: 8px; border-top: 1px solid var(--line); }
.account-avatar, .profile-avatar { display: grid; place-items: center; border-radius: 50%; color: var(--paper); background: var(--brand); font-weight: 800; }
.account-avatar { width: 30px; height: 30px; font-size: 12px; }
.account-copy { display: grid; min-width: 0; gap: 2px; }
.account-copy strong { overflow: hidden; font-size: 10px; text-overflow: ellipsis; white-space: nowrap; }
.account-copy small { color: var(--muted); font-size: 9px; }
.account-more { width: 28px; height: 28px; margin-left: auto; }
.account-more svg { width: 17px; height: 17px; }
.sidebar-account-popover { position: absolute; right: 0; bottom: calc(100% + 8px); z-index: 40; display: grid; gap: 6px; width: min(230px, calc(100vw - 28px)); padding: 12px; border: 1px solid var(--line); border-radius: 12px; background: var(--paper); box-shadow: 0 12px 30px var(--shadow-color); }
.sidebar-account-popover[hidden] { display: none !important; }
.sidebar-account-popover > strong { margin-top: -4px; font-size: 11px; }
.sign-out { display: flex; align-items: center; gap: 9px; width: 100%; min-height: 35px; padding: 0 7px; border: 0; border-radius: 9px; color: var(--text-secondary); background: transparent; text-align: left; font-size: 11px; cursor: pointer; }
.sign-out:hover { color: var(--brand-dark); background: var(--paper-soft); }
.sign-out svg { width: 17px; height: 17px; }

.main-column { display: flex; flex-direction: column; min-width: 0; min-height: calc(100vh - 8px); }
.topbar { position: relative; z-index: 12; display: flex; align-items: center; justify-content: space-between; min-height: 44px; padding: 3px 15px 3px 18px; }
.menu-trigger { display: none; }
.header-popover-wrap { position: relative; display: flex; flex: 0 0 auto; align-items: center; }
.location-switcher-wrap { min-width: 0; margin-right: auto; }
.location-switcher { display: flex; align-items: center; gap: 9px; min-width: 0; padding: 3px 6px 3px 0; border: 0; border-radius: 10px; color: inherit; background: transparent; text-align: left; cursor: pointer; transition: background .16s ease; }
.location-switcher:hover, .location-switcher[aria-expanded="true"] { background: var(--paper-soft); }
.location-switcher:focus-visible, .environment-pill:focus-visible, .notification:focus-visible, .profile-pill:focus-visible { outline: 3px solid var(--brand-ring); outline-offset: 2px; }
.location-mark { display: grid; place-items: center; width: 25px; height: 25px; border-radius: 8px; color: #fff; background: var(--brand); }
.location-mark svg { width: 16px; height: 16px; }
.location-switcher > span:nth-child(2), .profile-pill > span:nth-child(2) { display: grid; gap: 2px; }
.location-switcher strong { font-size: 11px; }
.location-switcher small { color: var(--muted); font-size: 9px; }
.chevron { width: 14px; height: 14px; color: var(--text-secondary); }
.topbar-right { display: flex; align-items: center; gap: 9px; }
.environment-pill { display: inline-flex; align-items: center; gap: 7px; min-height: 29px; padding: 0 10px; border: 1px solid var(--line); border-radius: 999px; color: var(--ink); background: var(--paper-glass); font-size: 10px; font-weight: 700; white-space: nowrap; cursor: pointer; transition: border-color .16s ease, color .16s ease, background .16s ease; }
.environment-pill .store-status-dot, .workspace-badge span { width: 7px; height: 7px; border-radius: 50%; background: var(--brand); }
.store-status-trigger.is-open { border-color: #BFE4D2; color: var(--green-dark); background: var(--green-soft); }
.store-status-trigger.is-open .store-status-dot { background: var(--green); }
.store-status-trigger.is-closed { border-color: var(--danger-soft); color: var(--danger); background: var(--danger-soft); }
.store-status-trigger.is-closed .store-status-dot { background: var(--danger); }
.store-status-trigger .chevron { width: 12px; height: 12px; }
.notification { position: relative; width: 31px; height: 31px; border: 1px solid var(--line); border-radius: 50%; background: var(--paper); cursor: pointer; }
.notification:hover, .notification[aria-expanded="true"] { color: var(--brand-dark); border-color: var(--brand-line); background: var(--brand-soft); }
.notification svg { width: 15px; height: 15px; }
.notification-count { position: absolute; top: -4px; right: -5px; display: grid; min-width: 15px; height: 15px; place-items: center; padding: 0 3px; border: 1px solid var(--paper); border-radius: 99px; color: #fff; background: var(--danger); font-size: 8px; font-weight: 800; }
.notification-count[hidden] { display: none !important; }
.profile-pill { display: inline-flex; align-items: center; gap: 8px; min-height: 34px; padding: 3px 9px 3px 4px; border: 1px solid var(--line); border-radius: 999px; color: inherit; background: var(--paper); text-align: left; font: inherit; cursor: pointer; transition: border-color .16s ease, background .16s ease; }
.profile-pill:hover, .profile-pill[aria-expanded="true"] { border-color: var(--brand-line); background: var(--paper-soft); }
.profile-avatar { width: 25px; height: 25px; font-size: 10px; }
.profile-pill strong { font-size: 9px; }
.profile-pill small { color: var(--muted); font-size: 8px; }

.header-popover { position: absolute; top: calc(100% + 9px); right: 0; z-index: 40; display: grid; gap: 8px; width: min(290px, calc(100vw - 24px)); padding: 13px; border: 1px solid var(--line); border-radius: 13px; color: var(--ink); background: var(--paper); box-shadow: 0 14px 34px var(--shadow-color); }
.header-popover[hidden] { display: none !important; }
.location-popover { right: auto; left: 0; width: 245px; }
.store-status-popover { width: 286px; }
.notification-popover { width: 320px; }
.profile-popover { width: 240px; }
.header-popover-kicker { margin: 0; color: var(--muted); font-size: 8px; font-weight: 800; letter-spacing: .1em; }
.header-popover > strong { margin-top: -5px; font-size: 12px; }
.header-popover > small, .header-popover-note { margin: -4px 0 1px; color: var(--text-secondary); font-size: 9px; line-height: 1.5; }
.header-popover-note { padding-top: 7px; border-top: 1px solid var(--line); }
.header-popover-action, .store-status-choice, .notification-item { display: flex; align-items: center; gap: 9px; width: 100%; min-width: 0; padding: 9px; border: 1px solid transparent; border-radius: 9px; color: var(--ink); background: transparent; text-align: left; font: inherit; cursor: pointer; }
.header-popover-action { justify-content: space-between; min-height: 35px; font-size: 10px; font-weight: 650; }
.header-popover-action:hover, .store-status-choice:hover, .notification-item:hover { border-color: var(--line); background: var(--paper-soft); }
.header-popover-action span { color: var(--muted); font-size: 14px; }
.header-popover-action.is-muted { color: var(--text-secondary); }
.store-status-choice { border-color: var(--line); background: var(--paper); }
.store-status-choice[aria-pressed="true"] { border-color: var(--brand-line); background: var(--brand-soft); }
.store-status-choice[data-store-status-choice="open"][aria-pressed="true"] { border-color: #BFE4D2; background: var(--green-soft); }
.store-status-choice[data-store-status-choice="closed"][aria-pressed="true"] { border-color: var(--danger); background: var(--danger-soft); }
.store-status-choice > span:nth-child(2), .notification-item > span:nth-child(2), .profile-popover-identity > span:nth-child(2) { display: grid; flex: 1; min-width: 0; gap: 3px; }
.store-status-choice strong, .notification-item strong, .profile-popover-identity strong { font-size: 10px; }
.store-status-choice small, .notification-item small, .profile-popover-identity small { color: var(--text-secondary); font-size: 9px; font-weight: 400; }
.store-status-choice-dot, .notification-item-dot { flex: 0 0 8px; width: 8px; height: 8px; border-radius: 50%; background: var(--muted); }
.store-status-choice-dot.is-open { background: var(--green); }
.store-status-choice-dot.is-closed { background: var(--danger); }
.store-status-check { visibility: hidden; color: var(--green-dark); font-size: 12px; font-weight: 800; }
.store-status-choice[data-store-status-choice="closed"] .store-status-check { color: var(--danger); }
.store-status-choice[aria-pressed="true"] .store-status-check { visibility: visible; }
.notification-popover > header { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; padding: 2px 2px 7px; border-bottom: 1px solid var(--line); }
.notification-popover > header > div { display: grid; gap: 3px; }
.notification-popover > header strong { font-size: 12px; }
.notification-popover > header small { color: var(--text-secondary); font-size: 9px; }
.header-text-action { padding: 3px 0; border: 0; color: var(--brand-dark); background: transparent; font: inherit; font-size: 9px; font-weight: 700; cursor: pointer; }
.header-text-action:disabled { color: var(--muted); cursor: default; }
.notification-item { border-bottom: 1px solid var(--line); border-radius: 0; }
.notification-item:last-child { border-bottom: 0; }
.notification-item-dot.is-orange { background: var(--brand); }
.notification-item-dot.is-green { background: var(--green); }
.notification-item-arrow { color: var(--muted); }
.profile-popover-identity { display: flex; align-items: center; gap: 9px; padding: 2px 3px 10px; border-bottom: 1px solid var(--line); }
.profile-popover-identity > span:nth-child(2) { flex: 1; }
.profile-popover-identity .profile-avatar { display: grid; flex: 0 0 30px; width: 30px; height: 30px; place-items: center; }

.workspace { display: flex; flex: 1; flex-direction: column; min-height: 0; margin: 1px 0 0 0; padding: 30px 32px; border: 1px solid var(--line); border-radius: 23px; background: var(--paper); box-shadow: var(--shadow); }
.page-heading { display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.page-heading[hidden] { display: none !important; }
.eyebrow { margin: 0 0 8px; color: var(--brand-dark); font-size: 9px; font-weight: 800; letter-spacing: .1em; }
.page-heading h1 { margin: 0; font-size: 20px; font-weight: 700; letter-spacing: -.035em; }
.page-description { margin: 5px 0 0; color: var(--text-secondary); font-size: 12px; }
.workspace-badge { display: inline-flex; align-items: center; gap: 7px; padding: 8px 10px; border: 1px solid var(--line); border-radius: 999px; color: var(--text-secondary); font-size: 10px; white-space: nowrap; }
.demo-badge[hidden] { display: none; }
.workspace-badge span { background: var(--green); }
.courier-add-trigger { flex: 0 0 auto; gap: 8px; min-height: 40px; }
.courier-add-trigger[hidden] { display: none; }
.courier-add-trigger svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-linecap: round; stroke-width: 2; }
.courier-add-trigger:focus-visible { outline: 3px solid var(--brand-ring); outline-offset: 2px; }
.courier-heading-actions { display: flex; flex: 0 1 auto; align-items: center; justify-content: flex-end; gap: 8px; min-width: 0; }
.courier-heading-actions[hidden] { display: none !important; }
.courier-add-form-row { grid-template-columns: .85fr 1.15fr; }
.heading-divider { height: 1px; margin-top: 23px; background: var(--line); }
.empty-workspace { display: grid; flex: 1; place-content: center; justify-items: center; max-width: 440px; align-self: center; padding: 34px 20px; text-align: center; }
.empty-illustration { position: relative; display: grid; width: 114px; height: 114px; place-items: center; margin-bottom: 18px; }
.illustration-orbit { position: absolute; inset: 7px; border: 1px solid var(--brand-line); border-radius: 50%; }
.orbit-two { inset: 18px; border-color: var(--brand-line); }
.illustration-center { display: grid; place-items: center; width: 64px; height: 64px; border: 1px solid var(--brand-line); border-radius: 22px; color: var(--brand-dark); background: var(--brand-soft); transform: rotate(-5deg); }
.illustration-center svg { width: 34px; height: 34px; stroke-width: 1.5; }
.empty-kicker { margin: 0 0 7px; color: var(--brand-dark); font-size: 9px; font-weight: 800; letter-spacing: .13em; }
.empty-workspace h2 { margin: 0; font-size: 18px; letter-spacing: -.025em; }
.empty-copy { max-width: 360px; margin: 8px 0 0; color: var(--text-secondary); font-size: 12px; line-height: 1.65; }
.mobile-scrim { display: none; }

@media (min-width: 1500px) {
  .workspace { margin-left: 0; }
}

@media (max-width: 1050px) {
  .app-shell { grid-template-columns: 220px minmax(0, 1fr); }
  .sidebar { padding-right: 7px; padding-left: 7px; }
  .workspace { padding: 26px 25px; }
  .profile-pill small { display: none; }
}

@media (max-width: 760px) {
  .app-shell { display: block; padding: 0; }
  .sidebar { position: fixed; inset: 0 auto 0 0; width: min(284px, calc(100vw - 50px)); min-height: 100vh; height: 100dvh; padding: 12px 10px 14px; transform: translateX(-105%); transition: transform .24s ease; box-shadow: 12px 0 36px var(--shadow-color); }
  .sidebar.is-open { transform: translateX(0); }
  .sidebar-close { display: inline-grid; }
  .sidebar-collapse-row { display: none; }
  .mobile-scrim.is-visible { position: fixed; inset: 0; display: block; z-index: 9; background: var(--scrim); backdrop-filter: blur(2px); }
  .main-column { min-height: 100vh; padding: 0 7px 7px; }
  .topbar { min-height: 49px; padding: 3px 8px; }
  .menu-trigger { display: inline-grid; margin-left: -3px; }
  .location-switcher-wrap { margin-left: 5px; }
  .topbar-right { gap: 5px; }
  .environment-pill { gap: 5px; min-height: 28px; padding: 0 7px; font-size: 9px; }
  .notification { display: grid; width: 29px; height: 29px; }
  .profile-pill { min-height: 31px; padding-right: 5px; gap: 5px; }
  .profile-pill > span:nth-child(2), .profile-pill .chevron { display: none; }
  .profile-avatar { width: 25px; height: 25px; }
  .workspace { min-height: calc(100vh - 56px); min-height: calc(100dvh - 56px); padding: 23px 18px; border-radius: 18px; }
  .page-heading { align-items: flex-start; }
  .page-heading h1 { font-size: 19px; }
  .page-description { max-width: 310px; font-size: 11px; line-height: 1.55; }
  .workspace-badge { display: none; }
  .heading-divider { margin-top: 18px; }
}

@media (max-height: 690px) and (min-width: 761px) {
  .sidebar { min-height: 0; }
  .nav-item { min-height: 35px; }
  .store-status { padding: 10px 12px; }
  .nav-label { margin-top: 8px; }
  .preferences-label { margin-top: 10px; }
  .sidebar-bottom { padding-top: 8px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; animation-duration: .01ms !important; }
}

/* Visão geral: leitura operacional no mesmo sistema visual de Pedidos e Cardápio. */
.overview-workspace { padding: 27px 30px 20px; }
.overview-heading { align-items: center; }
.overview-heading .eyebrow { margin-bottom: 6px; }
.overview-heading h1 { font-size: 23px; }
.overview-heading .page-description { margin-top: 4px; font-size: 13px; }
.demo-badge { color: var(--text-secondary); background: var(--brand-soft); border-color: var(--brand-line); }
.demo-badge span { background: var(--brand); }
.overview-screen { display: flex; flex: 1; flex-direction: column; gap: 14px; min-width: 0; padding-top: 18px; }
.overview-screen[hidden] { display: none !important; }
.overview-welcome { display: flex; align-items: center; justify-content: space-between; gap: 20px; min-width: 0; padding: 18px 20px; border: 1px solid var(--line); border-radius: 15px; background: var(--page); }
.welcome-copy { min-width: 0; }
.overview-kicker { margin: 0; color: var(--brand); font-size: 10px; font-weight: 800; letter-spacing: .1em; }
.welcome-copy h2 { margin: 5px 0 3px; color: var(--ink); font-size: 24px; font-weight: 800; letter-spacing: -.04em; }
.welcome-copy h2 #greeting { color: var(--brand); }
.welcome-copy h2 #greeting-name { color: var(--ink); }
.welcome-copy > p:last-child { margin: 0; color: var(--text-secondary); font-size: 13px; }
.welcome-actions { display: flex; flex: 0 0 auto; flex-wrap: wrap; gap: 8px; }
.overview-button { display: inline-flex; align-items: center; justify-content: center; gap: 7px; min-height: 38px; padding: 0 13px; border: 1px solid var(--line); border-radius: 10px; font-size: 12px; font-weight: 700; cursor: pointer; transition: border-color .16s ease, background .16s ease, transform .16s ease; }
.overview-button svg { width: 16px; height: 16px; }
.overview-button:hover { transform: translateY(-1px); }
.overview-button:active { transform: scale(.98); }
.overview-button:focus-visible, .overview-stage:focus-visible, .overview-inline-action:focus-visible { outline: 3px solid var(--brand-ring); outline-offset: 2px; }
.overview-button-primary { border-color: var(--brand); color: var(--paper); background: var(--brand); }
.overview-button-primary:hover { border-color: var(--brand-hover); background: var(--brand-hover); }
.overview-button-secondary { color: var(--ink); background: var(--paper); }
.overview-button-secondary:hover { border-color: var(--brand-line); background: var(--brand-soft); }
.overview-metrics { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 9px; }
.overview-metric { display: grid; align-content: center; gap: 5px; min-width: 0; min-height: 92px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 13px; background: var(--paper); }
.overview-metric.metric-revenue { border-top: 3px solid var(--brand); }
.metric-label { overflow: hidden; color: var(--text-secondary); font-size: 12px; font-weight: 600; text-overflow: ellipsis; white-space: nowrap; }
.overview-metric > strong { color: var(--ink); font-size: 22px; font-weight: 800; letter-spacing: -.035em; line-height: 1.1; }
.overview-metric > strong small { color: var(--text-secondary); font-size: 13px; font-weight: 600; letter-spacing: 0; }
.metric-detail { color: var(--text-secondary); font-size: 11px; }
.overview-flow-section { min-width: 0; }
.overview-section-heading, .overview-card-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.overview-section-heading h2, .overview-card-heading h2 { margin: 4px 0 0; color: var(--ink); font-size: 16px; font-weight: 800; letter-spacing: -.025em; }
.overview-inline-action { display: inline-flex; align-items: center; gap: 6px; min-height: 32px; padding: 0 2px 0 8px; border: 0; color: var(--brand-dark); background: transparent; font-size: 12px; font-weight: 700; white-space: nowrap; cursor: pointer; }
.overview-inline-action:hover { color: var(--brand-dark); }
.overview-inline-action span { font-size: 16px; transition: transform .16s ease; }
.overview-inline-action:hover span { transform: translateX(2px); }
.overview-stage-grid { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 8px; margin-top: 9px; }
.overview-stage { display: grid; gap: 5px; min-width: 0; min-height: 100px; padding: 10px 11px; border: 1px solid var(--line); border-top: 3px solid var(--stage-color); border-radius: 12px; color: var(--ink-pure); background: var(--paper); text-align: left; cursor: pointer; transition: border-color .16s ease, background .16s ease, transform .16s ease, box-shadow .16s ease; }
.overview-stage:hover { border-color: var(--line); border-top-color: var(--stage-color); background: var(--paper); box-shadow: 0 5px 14px var(--shadow-color); transform: translateY(-1px); }
.stage-topline { display: flex; align-items: center; gap: 6px; overflow: hidden; color: var(--ink-pure); font-size: 11px; font-weight: 700; text-overflow: ellipsis; white-space: nowrap; }
.stage-dot { flex: 0 0 7px; width: 7px; height: 7px; border-radius: 50%; background: var(--stage-color); }
.overview-stage > strong { color: var(--ink-pure); font-size: 24px; font-weight: 800; letter-spacing: -.04em; line-height: 1; }
.overview-stage > small { color: var(--ink-pure); font-size: 11px; }
.stage-waiting { --stage-color: var(--acceptance); --stage-deep: var(--acceptance-dark); }
.stage-preparing { --stage-color: var(--brand); --stage-deep: var(--brand-dark); }
.stage-ready { --stage-color: var(--green); --stage-deep: var(--green-dark); }
.stage-delivery { --stage-color: var(--info); --stage-deep: var(--info-dark); }
.stage-done { --stage-color: var(--green-dark); --stage-deep: var(--green-dark); }
.overview-lower-grid { display: grid; grid-template-columns: 1fr; gap: 10px; }
.overview-card { min-width: 0; overflow: hidden; border: 1px solid var(--line); border-radius: 14px; background: var(--paper); }
.overview-card-heading { min-height: 58px; padding: 9px 14px; border-bottom: 1px solid var(--line); }
.overview-card-heading h2 { font-size: 14px; }
.overview-order-list { padding: 0 13px; }
.overview-order-row { display: grid; grid-template-columns: 46px minmax(110px, 1fr) auto 76px; align-items: center; gap: 9px; min-height: 57px; border-bottom: 1px solid var(--line); }
.overview-order-row:last-child { border-bottom: 0; }
.overview-order-id { display: grid; width: 42px; height: 31px; place-items: center; border-radius: 9px; color: #fff; background: var(--brand); font-size: 11px; font-weight: 800; }
.overview-order-copy { display: grid; min-width: 0; gap: 3px; }
.overview-order-copy strong { overflow: hidden; color: var(--ink); font-size: 12px; font-weight: 700; text-overflow: ellipsis; white-space: nowrap; }
.overview-order-copy small { overflow: hidden; color: var(--text-secondary); font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.overview-order-state { justify-self: start; padding: 5px 7px; border-radius: 7px; font-size: 10px; font-weight: 700; white-space: nowrap; }
.state-preparing { color: #fff; background: var(--brand); }
.state-ready { color: var(--green-dark); background: var(--green-soft); }
.state-waiting { color: #fff; background: var(--acceptance); }
.state-delivery { color: var(--info-dark); background: var(--info-soft); }
.state-returned { color: var(--ink); background: var(--paper-soft); }
.state-cancelled { color: var(--danger); background: var(--danger-soft); }
.state-delivered { color: var(--green-dark); background: var(--green-soft); }
.overview-order-total { color: var(--ink); font-size: 12px; font-weight: 800; text-align: right; white-space: nowrap; }
.overview-demo-note { display: flex; align-items: center; gap: 7px; margin: -2px 1px 0; color: var(--text-secondary); font-size: 11px; line-height: 1.45; }
.overview-demo-note > span { display: grid; flex: 0 0 17px; width: 17px; height: 17px; place-items: center; border: 1px solid var(--warning-line); border-radius: 50%; color: var(--text-secondary); font-size: 11px; font-weight: 700; }
.overview-screen[hidden], .catalog-screen[hidden], .orders-screen[hidden], .routes-screen[hidden], .couriers-screen[hidden], .customers-screen[hidden], .reports-screen[hidden], .settings-screen[hidden], .coming-soon[hidden] { display: none !important; }

/* Cardápio: categorias e produtos em uma lista editorial, inspirada no fluxo da referência. */
.catalog-screen { display: flex; flex: 1; flex-direction: column; min-width: 0; padding-top: 18px; }
.catalog-toolbar { position: sticky; top: 8px; z-index: 4; display: grid; grid-template-columns: minmax(190px, 1fr) minmax(185px, 1fr) 42px auto; align-items: center; gap: 8px; padding: 7px; border: 1px solid var(--line); border-radius: 16px; background: var(--paper-glass); box-shadow: 0 5px 18px var(--shadow-color); backdrop-filter: blur(12px); }
.catalog-search, .category-select-wrap { display: flex; align-items: center; min-width: 0; height: 43px; border: 1px solid var(--line); border-radius: 12px; background: var(--paper); transition: border-color .16s ease, box-shadow .16s ease; }
.catalog-search { gap: 10px; padding: 0 12px; }
.catalog-search:focus-within, .category-select-wrap:focus-within { border-color: var(--brand-line); box-shadow: 0 0 0 3px var(--brand-ring); }
.catalog-search svg { flex: 0 0 17px; width: 17px; height: 17px; color: var(--text-secondary); }
.catalog-search input { width: 100%; min-width: 0; padding: 0; border: 0; outline: 0; color: var(--ink); background: transparent; font: inherit; font-size: 13px; }
.catalog-search input::placeholder { color: var(--text-secondary); }
.catalog-search kbd { padding: 3px 5px; border: 1px solid var(--line); border-radius: 5px; color: var(--text-secondary); background: var(--warning-soft); font: 10px "DM Sans", sans-serif; white-space: nowrap; }
.category-select-wrap { position: relative; }
.category-select-wrap select { width: 100%; height: 100%; padding: 0 37px 0 12px; appearance: none; border: 0; outline: 0; border-radius: inherit; color: var(--ink); background: transparent; font: inherit; font-size: 13px; cursor: pointer; }
.category-select-wrap > svg { position: absolute; right: 12px; width: 16px; height: 16px; color: var(--ink); pointer-events: none; }
.catalog-icon-button, .catalog-secondary-button { display: inline-flex; align-items: center; justify-content: center; height: 41px; border: 1px solid var(--line); border-radius: 11px; color: var(--ink); background: var(--paper); cursor: pointer; transition: background .16s ease, border-color .16s ease, transform .16s ease; }
.catalog-icon-button { width: 42px; padding: 0; }
.catalog-icon-button svg { width: 18px; height: 18px; }
.catalog-secondary-button { gap: 8px; padding: 0 13px; font-size: 11px; font-weight: 700; white-space: nowrap; }
.catalog-secondary-button svg { width: 16px; height: 16px; }
.catalog-icon-button:hover, .catalog-secondary-button:hover { border-color: var(--line); background: var(--warning-soft); }
.catalog-icon-button:active, .catalog-secondary-button:active { transform: scale(.97); }
.catalog-create-category-wrap { margin: 15px 0 16px; padding: 6px; border: 1px solid var(--line); border-radius: 15px; background: var(--paper-soft); }
.catalog-create-category { display: flex; align-items: center; justify-content: center; gap: 8px; width: 100%; min-height: 41px; border: 1px solid var(--line); border-radius: 10px; color: var(--ink); background: var(--paper); font-size: 13px; font-weight: 700; cursor: pointer; transition: background .16s ease, border-color .16s ease; }
.catalog-create-category:hover { border-color: var(--brand-line); color: var(--brand-dark); background: var(--brand-soft); }
.catalog-create-category svg { width: 16px; height: 16px; }
.catalog-list-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 0 3px 9px; color: var(--text-secondary); font-size: 11px; }
.catalog-list-heading > div { display: flex; align-items: center; gap: 7px; color: var(--ink); font-weight: 700; }
.catalog-list-heading > span { text-align: right; }
.catalog-live-dot, .save-status-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--green); }
.catalog-categories { display: grid; gap: 13px; padding-bottom: 14px; }
.catalog-category { overflow: hidden; border: 1px solid var(--line); border-radius: 15px; background: var(--paper); box-shadow: 0 3px 12px var(--shadow-color); }
.catalog-category.has-open-product-menu { position: relative; z-index: 2; overflow: visible; }
.catalog-category-header { display: flex; align-items: center; gap: 11px; min-height: 53px; padding: 0 12px 0 15px; border-radius: 14px 14px 0 0; background: var(--sidebar); }
.category-edit-icon { display: grid; flex: 0 0 26px; width: 26px; height: 26px; place-items: center; border: 0; border-radius: 7px; color: var(--ink); background: transparent; cursor: pointer; }
.category-edit-icon:hover { color: var(--brand-dark); background: var(--paper); }
.category-edit-icon svg { width: 16px; height: 16px; }
.catalog-category-title { display: flex; align-items: baseline; gap: 8px; min-width: 0; margin: 0; font-size: 15px; font-weight: 700; letter-spacing: -.02em; }
.catalog-category-title button { overflow: hidden; padding: 2px 0; border: 0; color: var(--ink); background: transparent; font: inherit; text-decoration: underline; text-decoration-color: var(--soft); text-underline-offset: 3px; text-overflow: ellipsis; white-space: nowrap; cursor: pointer; }
.catalog-category-title span { color: var(--text-secondary); font-size: 11px; font-weight: 500; white-space: nowrap; }
.category-header-actions { display: flex; align-items: center; gap: 5px; margin-left: auto; }
.category-header-actions .catalog-icon-button { width: 32px; height: 32px; border-color: var(--line); border-radius: 9px; }
.category-header-actions .catalog-icon-button svg { width: 16px; height: 16px; }
.category-collapse svg { transition: transform .18s ease; }
.catalog-category.is-collapsed .category-collapse svg { transform: rotate(180deg); }
.catalog-add-product { display: flex; align-items: center; justify-content: center; gap: 8px; width: calc(100% - 28px); min-height: 38px; margin: 8px 14px; border: 1px solid var(--line); border-radius: 9px; color: var(--ink); background: var(--paper); font-size: 12px; font-weight: 700; cursor: pointer; transition: color .16s ease, border-color .16s ease, background .16s ease; }
.catalog-add-product:hover { border-color: var(--brand-line); color: var(--brand-dark); background: var(--brand-soft); }
.catalog-add-product svg { width: 16px; height: 16px; }
.catalog-product-list { border-top: 1px solid var(--line); }
.catalog-category.is-collapsed .catalog-product-list, .catalog-category.is-collapsed .catalog-add-product { display: none; }
.catalog-product-row { display: grid; grid-template-columns: 56px minmax(0, 1fr) auto 34px; align-items: center; gap: 12px; min-height: 74px; padding: 8px 12px 8px 14px; border-bottom: 1px solid var(--line); transition: background .14s ease; }
.catalog-product-row:last-child { border-bottom: 0; }
.catalog-product-row:hover { background: var(--warning-soft); }
.catalog-product-row:last-child:hover { border-radius: 0 0 14px 14px; }
.catalog-product-image { display: grid; width: 56px; height: 56px; overflow: hidden; place-items: center; border-radius: 10px; color: var(--ink); background: var(--paper-soft); }
.catalog-product-image img { width: 100%; height: 100%; object-fit: cover; }
.catalog-product-image svg { width: 23px; height: 23px; stroke-width: 1.8; }
.catalog-product-copy { display: grid; min-width: 0; gap: 3px; }
.catalog-product-copy strong { overflow: hidden; color: var(--ink); font-size: 13px; font-weight: 700; text-overflow: ellipsis; white-space: nowrap; }
.catalog-product-copy > span { display: -webkit-box; overflow: hidden; color: var(--text-secondary); font-size: 12px; line-height: 1.4; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.catalog-product-row.is-paused .catalog-product-image { opacity: .55; }
.catalog-product-row.is-paused .catalog-product-copy strong::after { content: "Pausado"; display: inline-flex; margin-left: 7px; padding: 2px 6px; border-radius: 999px; color: var(--brand-dark); background: var(--warning-soft); font-size: 9px; font-weight: 700; vertical-align: 1px; }
.catalog-price { display: inline-flex; align-items: center; gap: 0; overflow: hidden; min-height: 36px; border: 1px solid var(--line); border-radius: 11px; color: var(--ink); background: var(--paper); white-space: nowrap; }
.catalog-price > strong { padding: 0 11px; font-size: 12px; font-weight: 600; }
.catalog-price button { display: grid; width: 34px; height: 34px; place-items: center; border: 0; border-left: 1px solid var(--line); color: var(--text-secondary); background: transparent; cursor: pointer; }
.catalog-price button:hover { color: var(--brand-dark); background: var(--brand-soft); }
.catalog-price button svg { width: 15px; height: 15px; fill: currentColor; stroke: none; }
.catalog-row-actions { position: relative; }
.catalog-row-actions > .catalog-icon-button { width: 32px; height: 34px; border-color: transparent; }
.catalog-row-actions > .catalog-icon-button svg { width: 17px; height: 17px; }
.catalog-action-menu { position: absolute; top: calc(100% + 5px); right: 0; z-index: 5; display: grid; min-width: 145px; padding: 5px; border: 1px solid var(--line); border-radius: 11px; background: var(--paper); box-shadow: 0 10px 26px var(--shadow-color); }
.catalog-action-menu[hidden] { display: none; }
.catalog-action-menu button { padding: 9px 10px; border: 0; border-radius: 7px; color: var(--ink); background: transparent; text-align: left; font: inherit; font-size: 11px; cursor: pointer; }
.catalog-action-menu button:hover { background: var(--warning-soft); }
.catalog-action-menu button[data-product-action="delete"] { color: var(--danger); }
.catalog-action-menu button[data-product-action="delete"]:hover { background: var(--danger-soft); }
.catalog-empty { display: grid; justify-items: center; gap: 7px; padding: 48px 18px; color: var(--muted); text-align: center; }
.catalog-empty[hidden] { display: none; }
.catalog-empty strong { color: var(--ink); font-size: 14px; }
.catalog-empty > span:last-child { font-size: 11px; }
.catalog-empty-icon { display: grid; width: 42px; height: 42px; place-items: center; margin-bottom: 5px; border-radius: 13px; color: var(--brand-dark); background: var(--brand-soft); }
.catalog-empty-icon svg { width: 20px; height: 20px; }
.catalog-savebar { position: sticky; bottom: 0; z-index: 3; display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 58px; margin: auto -30px -20px; padding: 8px 30px; border-top: 1px solid var(--line); background: var(--paper-glass); backdrop-filter: blur(12px); }
.catalog-savebar > span { display: inline-flex; align-items: center; gap: 8px; color: var(--muted); font-size: 11px; }
.catalog-save-button { min-height: 38px; padding: 0 15px; border: 0; border-radius: 10px; color: var(--paper); background: var(--ink); font-size: 12px; font-weight: 700; cursor: pointer; transition: background .16s ease, transform .16s ease; }
.catalog-save-button:hover:not(:disabled) { color: var(--paper); background: var(--ink-pure); }
.catalog-save-button:active { transform: scale(.97); }
.catalog-dialog { width: min(480px, calc(100vw - 28px)); max-width: 100%; max-height: calc(100dvh - 24px); overflow-y: auto; padding: 0; border: 1px solid var(--line); border-radius: 18px; color: var(--ink); background: var(--paper); box-shadow: 0 24px 70px var(--shadow-color); }
.catalog-dialog::backdrop { background: var(--overlay); backdrop-filter: blur(3px); }
.catalog-dialog form { padding: 22px; }
.order-detail-dialog { width: min(740px, calc(100vw - 28px)); max-height: calc(100dvh - 28px); overflow-y: auto; }
.courier-detail-dialog { width: min(620px, calc(100vw - 28px)); }
.route-start-dialog { width: min(680px, calc(100vw - 28px)); }
.order-detail-shell { padding: 16px; }
.order-detail-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 14px; margin-bottom: 10px; }
.order-detail-heading .section-kicker { margin: 0; color: var(--brand-dark); font-size: 10px; font-weight: 800; letter-spacing: .12em; }
.order-detail-heading h2 { margin: 5px 0 0; color: var(--ink); font-size: 23px; letter-spacing: -.04em; }
.order-detail-close { flex: 0 0 36px; width: 36px; height: 36px; border: 1px solid var(--line); border-radius: 11px; color: var(--ink); background: var(--paper); font-size: 24px; line-height: 1; cursor: pointer; }
.order-detail-close:hover { color: var(--ink); background: var(--warning-soft); }
.order-detail-summary { display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 6px 12px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 13px; background: var(--paper); }
.order-detail-status { display: flex; align-items: center; gap: 8px; color: var(--stage-deep); font-size: 14px; }
.order-detail-status > span { width: 9px; height: 9px; border-radius: 50%; background: var(--stage-color); }
.order-detail-received { color: var(--text-secondary); font-size: 12px; }
.order-detail-total { grid-column: 1 / -1; display: flex; align-items: baseline; justify-content: space-between; gap: 10px; padding-top: 6px; border-top: 1px solid var(--line); }
.order-detail-total-copy { display: grid; gap: 3px; }
.order-detail-total .order-detail-discount { color: var(--green); font-size: 11px; font-weight: 700; }
.order-detail-total small { color: var(--ink); font-size: 12px; }
.order-detail-total strong { color: var(--ink); font-size: 20px; font-variant-numeric: tabular-nums; }
.order-detail-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; margin-top: 8px; }
.order-detail-card { display: grid; align-content: start; gap: 5px; min-width: 0; padding: 10px; border: 1px solid var(--line); border-radius: 12px; background: var(--paper); }
.order-detail-card > p { margin: 0 0 2px; color: var(--text-secondary); font-size: 10px; font-weight: 800; letter-spacing: .08em; }
.order-detail-card > strong { color: var(--ink); font-size: 13px; line-height: 1.45; overflow-wrap: anywhere; }
.order-detail-card > small { color: var(--text-secondary); font-size: 11px; line-height: 1.45; }
.order-detail-wide { grid-column: 1 / -1; }
.order-return-history { gap: 8px; }
.order-return-history-row { display: grid; gap: 3px; padding-top: 8px; border-top: 1px solid var(--line); }
.order-return-history-row strong { color: var(--ink); font-size: 12px; }
.order-return-history-row small { color: var(--text-secondary); font-size: 11px; line-height: 1.4; }
.order-return-actions-inline { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px; width: 100%; margin-top: 7px; }
.order-return-actions-inline button { min-width: 0; min-height: 32px; padding: 0 9px; border: 1px solid var(--line); border-radius: 8px; color: var(--ink); background: var(--paper); font: inherit; font-size: 10px; font-weight: 750; cursor: pointer; }
.order-return-actions-inline button:hover { border-color: var(--brand-line); background: var(--brand-soft); }
.order-return-actions-inline button.is-cancel { color: var(--danger); border-color: var(--danger-soft); background: var(--danger-soft); }
.order-return-actions-inline button.is-cancel:hover { border-color: var(--danger); }
.order-return-actions-inline button.is-redeliver { color: #fff; border-color: var(--brand); background: var(--brand); }
.order-return-actions-inline button.is-redeliver:hover { border-color: var(--brand-hover); background: var(--brand-hover); }
.order-return-actions-inline button:focus-visible { outline: 3px solid var(--brand-ring); outline-offset: 2px; }
.order-detail-items { grid-column: auto; }
.order-detail-items > strong { font-size: 13px; }
.order-detail-contact { grid-column: auto; grid-template-columns: minmax(0, 1fr) auto; align-items: center; }
.order-detail-contact-copy { display: grid; align-content: start; gap: 4px; min-width: 0; }
.order-detail-contact-copy > p { margin: 0 0 2px; color: var(--text-secondary); font-size: 10px; font-weight: 800; letter-spacing: .08em; }
.order-detail-contact-copy > strong { color: var(--ink); font-size: 13px; line-height: 1.45; }
.order-detail-contact-copy > small { color: var(--text-secondary); font-size: 11px; line-height: 1.45; overflow-wrap: anywhere; }
.order-whatsapp-link { width: fit-content; margin-top: 2px; color: var(--green-dark); font-size: 11px; font-weight: 750; text-decoration: none; }
.order-whatsapp-link:hover { text-decoration: underline; text-underline-offset: 2px; }
.order-whatsapp-qr { display: grid; justify-items: center; gap: 3px; padding: 5px; border: 1px solid var(--line); border-radius: 9px; color: var(--ink); background: var(--paper); font-size: 9px; line-height: 1.2; text-align: center; text-decoration: none; }
.order-whatsapp-qr:hover { border-color: var(--green-line); }
.whatsapp-qr-code { display: block; width: 88px; height: 88px; shape-rendering: crispEdges; image-rendering: pixelated; }
.route-start-layout { display: grid; grid-template-columns: minmax(0, 1fr) 210px; gap: 13px; }
.route-start-details { min-width: 0; }
.route-start-intro { margin: 0; color: var(--ink); font-size: 13px; line-height: 1.5; }
.route-start-intro strong { font-weight: 800; }
.route-start-origin { margin: 6px 0 10px; color: var(--text-secondary); font-size: 11px; line-height: 1.45; }
.route-start-stops { display: grid; max-height: min(330px, 40dvh); gap: 6px; overflow-y: auto; margin: 0; padding: 0 3px 0 0; list-style: none; }
.route-start-stops li { display: grid; grid-template-columns: 28px minmax(0, 1fr); align-items: start; gap: 8px; padding: 8px; border: 1px solid var(--line); border-radius: 9px; }
.route-start-stops li > span { display: grid; width: 25px; height: 25px; place-items: center; border-radius: 50%; color: var(--info-dark); background: var(--info-soft); font-size: 9px; font-weight: 800; }
.route-start-stops li > div { display: grid; gap: 3px; min-width: 0; }
.route-start-stops li strong { color: var(--ink); font-size: 11px; }
.route-start-stops li small { color: var(--text-secondary); font-size: 10px; line-height: 1.4; overflow-wrap: anywhere; }
.route-start-whatsapp-column { display: grid; align-content: start; gap: 7px; min-width: 0; }
.route-start-qr { display: grid; justify-items: center; gap: 6px; padding: 9px; border: 1px solid var(--line); border-radius: 12px; color: var(--ink); background: var(--paper); font-size: 10px; line-height: 1.35; text-align: center; text-decoration: none; }
.route-start-qr:hover { border-color: var(--info-line); }
.route-start-qr .whatsapp-qr-code { width: 176px; height: 176px; }
.route-start-whatsapp-link { display: flex; align-items: center; justify-content: space-between; gap: 8px; min-height: 37px; padding: 7px 10px; border: 1px solid var(--green-line); border-radius: 9px; color: var(--green-dark); background: var(--green-soft); font-size: 10px; font-weight: 750; line-height: 1.35; text-decoration: none; }
.route-start-whatsapp-link:hover { border-color: var(--green-dark); }
.route-start-whatsapp-link span { flex: 0 0 auto; font-size: 14px; }
.route-start-send-note, .route-start-phone-note, .route-start-qr-fallback { margin: 0; color: var(--text-secondary); font-size: 10px; line-height: 1.45; }
.route-start-footer { margin-top: 12px; }
.route-start-footer .catalog-secondary-button { min-height: 36px; padding: 0 13px; border: 1px solid var(--line); border-radius: 9px; color: var(--ink); background: var(--paper); font: inherit; font-size: 12px; font-weight: 700; cursor: pointer; }
.order-detail-payment { gap: 7px; }
.payment-receive-button, .payment-receivable-button { width: fit-content; min-height: 34px; padding: 0 11px; border: 0; border-radius: 8px; color: var(--paper); background: var(--green); font: inherit; font-size: 11px; font-weight: 750; cursor: pointer; }
.payment-receive-button:hover { background: var(--green-dark); }
.payment-receivable-button { border: 1px solid var(--line); color: var(--ink); background: var(--paper); }
.payment-receivable-button:hover { border-color: var(--brand-line); color: var(--brand-dark); background: var(--brand-soft); }
.payment-method-options { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 2px; }
.payment-method-options[hidden] { display: none; }
.payment-method-options button { min-height: 31px; padding: 0 10px; border: 1px solid var(--green-line); border-radius: 8px; color: var(--green-dark); background: var(--green-soft); font: inherit; font-size: 11px; font-weight: 700; cursor: pointer; }
.payment-method-options button:hover, .payment-method-options button:focus-visible { border-color: var(--green-line); background: var(--green-soft); }
.payment-receive-button:focus-visible, .payment-receivable-button:focus-visible, .payment-method-options button:focus-visible, .order-whatsapp-link:focus-visible, .order-whatsapp-qr:focus-visible { outline: 3px solid var(--green-ring); outline-offset: 2px; }
.detail-payment-state { width: fit-content; padding: 4px 8px; border-radius: 999px; font-size: 11px !important; font-weight: 750; }
.detail-payment-state.is-paid { color: var(--badge-paid-fg); background: var(--badge-paid-bg); }
.detail-payment-state.is-due { color: var(--badge-due-fg); background: var(--badge-due-bg); }
.order-detail-actions { margin-top: 8px; }
.order-detail-actions .ticket-action, .order-detail-actions .ticket-complete { min-height: 42px; margin-top: 0; font-size: 13px; }
.order-detail-action-group { display: flex; flex-wrap: wrap; gap: 8px; }
.order-detail-action-group .ticket-action { width: auto; flex: 1 1 180px; }
.ticket-return-action { min-height: 42px; padding: 0 14px; border: 1px solid var(--line-strong); border-radius: 8px; color: var(--ink); background: var(--paper); font: inherit; font-size: 12px; font-weight: 750; cursor: pointer; }
.ticket-return-action:hover { border-color: var(--line-strong); background: var(--paper-soft); }
.ticket-return-action:focus-visible { outline: 3px solid var(--brand-ring); outline-offset: 2px; }
.order-detail-footer { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: 10px; padding-top: 8px; border-top: 1px solid var(--line); }
.order-detail-footer > span { color: var(--text-secondary); font-size: 11px; }
.order-detail-footer-actions { display: flex; align-items: center; gap: 8px; }
.order-detail-footer-actions [hidden] { display: none !important; }
.order-detail-footer .catalog-secondary-button { min-height: 36px; padding: 0 13px; border: 1px solid var(--line); border-radius: 9px; color: var(--ink); background: var(--paper); font: inherit; font-size: 12px; font-weight: 700; cursor: pointer; }
.order-detail-footer .catalog-secondary-button:hover { background: var(--warning-soft); }
.order-detail-footer .order-detail-cancel { color: #fff; border-color: var(--danger); background: var(--danger); }
.order-detail-footer .order-detail-cancel:hover { border-color: var(--danger-dark, #b42318); background: var(--danger-dark, #b42318); }
.order-detail-footer-actions .catalog-secondary-button:focus-visible { outline: 3px solid var(--brand-ring); outline-offset: 2px; }
.courier-detail-banner { display: flex; align-items: center; gap: 11px; padding: 13px; border: 1px solid var(--line); border-radius: 12px; background: var(--paper-soft); }
.courier-detail-banner .route-courier-avatar { flex: 0 0 44px; width: 44px; height: 44px; }
.courier-detail-banner > div { display: grid; flex: 1; min-width: 0; gap: 4px; }
.courier-detail-banner > div > strong { color: var(--ink); font-size: 15px; font-weight: 800; }
.courier-detail-banner > div > small { color: var(--text-secondary); font-size: 11px; }
.courier-detail-banner > .courier-status { margin-left: auto; }
.courier-detail-grid { margin-top: 10px; }
.courier-detail-grid .order-detail-card { gap: 8px; padding: 14px; }
.courier-detail-grid .order-detail-card > p { color: var(--text-secondary); font-weight: 800; }
.courier-detail-grid .order-detail-card > strong { font-size: 15px; font-weight: 800; }
.courier-detail-grid .order-detail-card > .courier-detail-fee-total { color: var(--brand-dark); font-size: 21px; font-variant-numeric: tabular-nums; line-height: 1.15; }
.courier-detail-grid .order-detail-card > small > strong { color: var(--ink); font-weight: 800; }
.courier-detail-grid .order-detail-card > .courier-detail-period { margin-top: 2px; padding-top: 6px; border-top: 1px solid var(--line); color: var(--text-secondary); font-size: 10px; }
.courier-detail-deliveries { display: grid; gap: 9px; margin-top: 16px; }
.courier-detail-deliveries h3 { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin: 0; color: var(--ink); font-size: 10px; font-weight: 800; letter-spacing: .08em; }
.courier-detail-deliveries h3 span { display: grid; min-width: 24px; height: 24px; place-items: center; padding: 0 7px; border-radius: 999px; color: #fff; background: var(--brand); font-size: 11px; font-weight: 800; letter-spacing: 0; }
.courier-delivered-list { display: grid; max-height: 280px; gap: 7px; overflow-y: auto; padding: 1px 3px 1px 0; }
.courier-delivered-order { display: grid; gap: 6px; padding: 11px 12px; border: 1px solid var(--line); border-radius: 11px; background: var(--paper); }
.courier-delivered-order > header { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; }
.courier-delivered-order > header > strong { color: var(--brand-dark); font-size: 15px; font-weight: 800; font-variant-numeric: tabular-nums; }
.courier-delivered-order > header > time { color: var(--text-secondary); font-size: 10px; font-weight: 600; white-space: nowrap; }
.courier-delivered-order > .courier-delivered-location { color: var(--text-secondary); font-size: 11px; line-height: 1.4; }
.courier-delivered-order > footer { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: 1px; padding: 7px 9px; border-radius: 8px; color: var(--brand-dark); background: var(--paper-soft); font-size: 10px; }
.courier-delivered-order > footer > span { padding: 0; color: var(--text-secondary); background: transparent; font-weight: 700; }
.courier-delivered-order > footer > strong { color: var(--brand-dark); font-size: 13px; font-weight: 800; font-variant-numeric: tabular-nums; }
.courier-detail-empty { margin: 0; padding: 13px; border: 1px dashed var(--line-strong); border-radius: 10px; color: var(--text-secondary); font-size: 11px; line-height: 1.45; }
.courier-detail-footer { justify-content: flex-end; }
.courier-detail-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 8px; margin-top: 14px; }
.courier-detail-actions > button { min-height: 36px; padding: 0 13px; border: 1px solid var(--line); border-radius: 9px; color: var(--ink); background: var(--paper); font: inherit; font-size: 12px; font-weight: 700; cursor: pointer; }
.courier-detail-actions > button:hover { border-color: var(--brand-line); background: var(--brand-soft); }

/* Clientes: lista compacta de contatos no mesmo sistema visual da nova prévia. */
.customers-screen { display: flex; flex: 1; flex-direction: column; min-width: 0; gap: 13px; padding-top: 18px; }
.customers-toolbar { display: grid; grid-template-columns: minmax(220px, 1fr) auto auto; align-items: center; gap: 8px; }
.customers-search { display: flex; align-items: center; gap: 10px; min-width: 0; height: 43px; padding: 0 12px; border: 1px solid var(--line); border-radius: 12px; background: var(--paper); transition: border-color .16s ease, box-shadow .16s ease; }
.customers-search:focus-within { border-color: var(--brand-line); box-shadow: 0 0 0 3px var(--brand-ring); }
.customers-search svg { flex: 0 0 17px; width: 17px; height: 17px; fill: none; stroke: var(--text-secondary); stroke-linecap: round; stroke-width: 1.8; }
.customers-search input { width: 100%; min-width: 0; padding: 0; border: 0; outline: 0; color: var(--ink); background: transparent; font: inherit; font-size: 12px; }
.customers-search input::placeholder { color: var(--text-secondary); }
.customer-export-button svg { fill: none; stroke: currentColor; stroke-linecap: round; stroke-linejoin: round; stroke-width: 1.8; }
.customer-primary-button { display: inline-flex; align-items: center; justify-content: center; gap: 7px; min-height: 41px; padding: 0 14px; border: 1px solid var(--brand); border-radius: 11px; color: var(--paper); background: var(--brand); font: inherit; font-size: 11px; font-weight: 750; white-space: nowrap; cursor: pointer; transition: background .16s ease, transform .16s ease; }
.customer-primary-button:hover { background: var(--brand-dark); }
.customer-primary-button:active { transform: scale(.98); }
.customer-primary-button:focus-visible, .customer-row-actions button:focus-visible { outline: 3px solid var(--brand-ring); outline-offset: 2px; }
.customer-primary-button svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-linecap: round; stroke-width: 2; }
.customer-directory { overflow: hidden; border: 1px solid var(--line); border-radius: 16px; background: var(--paper); box-shadow: 0 3px 12px var(--shadow-color); }
.customer-directory-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 65px; padding: 12px 16px; border-bottom: 1px solid var(--line); }
.customer-directory-heading > div { display: flex; align-items: center; gap: 10px; min-width: 0; }
.customer-directory-icon { display: grid; flex: 0 0 34px; width: 34px; height: 34px; place-items: center; border: 1px solid var(--brand-line); border-radius: 10px; color: var(--brand-dark); background: var(--brand-soft); }
.customer-directory-icon svg { width: 19px; height: 19px; }
.customer-directory-heading h2 { margin: 0; color: var(--ink); font-size: 13px; font-weight: 750; }
.customer-directory-heading p { margin: 3px 0 0; color: var(--text-secondary); font-size: 10px; }
.customer-result-count { flex: 0 0 auto; padding: 5px 9px; border: 1px solid var(--line); border-radius: 999px; color: var(--text-secondary); background: var(--paper-soft); font-size: 10px; font-weight: 700; }
.customer-list { display: grid; gap: 0; padding: 0 12px; }
.customer-row { display: grid; grid-template-columns: 40px minmax(135px, 1.1fr) minmax(170px, 1fr) 92px auto; align-items: center; gap: 11px; min-height: 69px; padding: 10px 5px; border-bottom: 1px solid var(--line); }
.customer-row:last-child { border-bottom: 0; }
.customer-avatar { display: grid; width: 38px; height: 38px; place-items: center; border: 1px solid var(--brand-line); border-radius: 50%; color: var(--brand-dark); background: var(--brand-soft); font-size: 11px; font-weight: 800; }
.customer-main-copy, .customer-address-copy { display: grid; min-width: 0; gap: 3px; }
.customer-main-copy strong { overflow: hidden; color: var(--ink); font-size: 12px; font-weight: 750; text-overflow: ellipsis; white-space: nowrap; }
.customer-main-copy span, .customer-address-copy span, .customer-address-copy small { overflow: hidden; color: var(--text-secondary); font-size: 10px; line-height: 1.35; text-overflow: ellipsis; white-space: nowrap; }
.customer-address-copy span { color: var(--ink); }
.customer-address-copy small { min-height: 13px; }
.customer-orders-badge { justify-self: start; padding: 5px 8px; border: 1px solid var(--line); border-radius: 999px; color: var(--text-secondary); background: var(--paper-soft); font-size: 9px; font-weight: 700; white-space: nowrap; }
.customer-row-actions { display: flex; justify-content: flex-end; gap: 5px; }
.customer-row-actions button { min-height: 31px; padding: 0 9px; border: 1px solid var(--line); border-radius: 8px; color: var(--ink); background: var(--paper); font: inherit; font-size: 10px; font-weight: 700; cursor: pointer; }
.customer-row-actions button:hover { border-color: var(--brand-line); color: var(--brand-dark); background: var(--brand-soft); }
.customer-row-actions .customer-delete-button { color: var(--text-secondary); }
.customer-row-actions .customer-delete-button:hover { border-color: var(--danger); color: var(--danger); background: var(--danger-soft); }
.customer-empty { display: grid; justify-items: center; gap: 6px; padding: 36px 18px; color: var(--text-secondary); text-align: center; }
.customer-empty svg { width: 25px; height: 25px; margin-bottom: 3px; fill: none; stroke: currentColor; stroke-linecap: round; stroke-linejoin: round; stroke-width: 1.6; }
.customer-empty strong { color: var(--ink); font-size: 12px; }
.customer-empty span { font-size: 10px; line-height: 1.45; }
.customer-dialog { width: min(460px, calc(100vw - 28px)); }
.customer-dialog .dialog-fields { gap: 11px; }
.customer-dialog .dialog-fields label { gap: 5px; }
.customer-dialog input, .customer-dialog textarea { width: 100%; min-height: 38px; padding: 9px 10px; border: 1px solid var(--line); border-radius: 9px; outline: 0; color: var(--ink); background: var(--paper); font: inherit; font-size: 12px; font-weight: 500; resize: vertical; }
.customer-dialog textarea { min-height: 72px; }
.customer-dialog input:focus, .customer-dialog textarea:focus { border-color: var(--brand-line); box-shadow: 0 0 0 3px var(--brand-ring); }
.customer-form-error { margin: 10px 0 0; color: var(--danger); font-size: 11px; font-weight: 650; }
.customer-form-error[hidden] { display: none; }

/* Relatórios: filtros, indicadores e recortes operacionais da prévia. */
.reports-screen { display: flex; flex: 1; flex-direction: column; min-width: 0; gap: 13px; padding-top: 16px; }
.reports-filter-panel, .report-data-panel { min-width: 0; border: 1px solid var(--line); border-radius: 15px; background: var(--paper); box-shadow: 0 3px 12px var(--shadow-color); }
.reports-filter-panel { padding: 12px; }
.reports-filter-panel > .reports-filter-bottom { margin-top: 0; padding-top: 0; border-top: 0; }
.reports-filter-top, .reports-filter-actions, .reports-filter-bottom { display: flex; align-items: center; }
.reports-filter-top { justify-content: space-between; gap: 12px; }
.reports-filter-actions { justify-content: flex-end; gap: 9px; }
.report-export-button svg { fill: none; stroke: currentColor; stroke-linecap: round; stroke-linejoin: round; stroke-width: 1.8; }
.report-custom-period { display: flex; align-items: end; gap: 8px; margin-top: 11px; padding: 10px; border: 1px solid var(--line); border-radius: 11px; background: var(--paper-soft); }
.report-custom-period[hidden] { display: none; }
.report-custom-period label, .reports-filter-bottom label { display: grid; gap: 5px; color: var(--text-secondary); font-size: 9px; font-weight: 700; }
.report-custom-period input, .reports-filter-bottom select { min-height: 34px; padding: 0 9px; border: 1px solid var(--line); border-radius: 8px; outline: 0; color: var(--ink); background: var(--paper); font: inherit; font-size: 10px; }
.report-custom-period input:focus, .reports-filter-bottom select:focus { border-color: var(--brand-line); box-shadow: 0 0 0 3px var(--brand-ring); }
.report-custom-period .customer-primary-button { min-height: 34px; border-radius: 8px; font-size: 10px; }
.report-period-control { position: relative; z-index: 9; min-width: 0; }
.report-period-trigger { max-width: min(100%, 440px); }
.report-period-picker { position: absolute; top: calc(100% + 7px); left: 0; z-index: 10; display: grid; gap: 8px; width: min(340px, calc(100vw - 32px)); max-height: min(520px, calc(100vh - 100px)); overflow-y: auto; padding: 8px; border: 1px solid var(--line); border-radius: 12px; background: var(--paper); box-shadow: 0 14px 38px rgb(18 25 38 / 18%); }
.report-period-picker[hidden] { display: none !important; }
.report-period-presets { overflow: visible; padding: 6px; border: 0; }
.report-period-presets > p { margin: 0 0 7px; color: var(--text-secondary); font-size: 10px; font-weight: 800; }
.report-period-options { display: grid; gap: 2px; }
.report-period-custom { align-items: end; flex-wrap: wrap; margin: 0; padding: 8px; }
.report-period-custom label { flex: 1 1 125px; min-width: 0; }
.report-period-custom button { flex: 1 0 100%; }
.reports-filter-bottom { flex-wrap: wrap; gap: 9px; margin-top: 11px; padding-top: 10px; border-top: 1px solid var(--line); }
.reports-filter-bottom label { min-width: 160px; }
.reports-filter-bottom select { width: 100%; }
.report-kpi-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 9px; }
.report-kpi-card { display: grid; align-content: space-between; gap: 7px; min-height: 96px; padding: 12px 13px; border: 1px solid var(--line); border-radius: 13px; background: var(--paper); box-shadow: 0 2px 9px var(--shadow-color); }
.report-kpi-label { color: var(--text-secondary); font-size: 10px; font-weight: 700; }
.report-kpi-card > strong { color: var(--ink); font-size: 20px; font-weight: 800; letter-spacing: -.035em; font-variant-numeric: tabular-nums; line-height: 1.1; }
.report-kpi-card > small { overflow: hidden; color: var(--text-secondary); font-size: 9px; line-height: 1.35; text-overflow: ellipsis; }
.report-kpi-sales > strong, .report-kpi-received > strong { color: var(--brand-dark); }
.report-kpi-cancelled > strong { color: var(--danger); }
.report-data-panel { padding: 13px 15px; }
.report-panel-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-width: 0; }
.report-panel-heading h2 { margin: 0; color: var(--ink); font-size: 12px; font-weight: 800; }
.report-panel-heading p { margin: 3px 0 0; color: var(--text-secondary); font-size: 9px; line-height: 1.4; }
.report-panel-heading > strong { color: var(--ink); font-size: 17px; font-weight: 800; font-variant-numeric: tabular-nums; white-space: nowrap; }
.report-content-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.report-data-panel { min-height: 152px; }
.report-breakdown-list, .report-product-list { display: grid; margin-top: 9px; }
.report-breakdown-row, .report-product-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; min-height: 39px; padding: 7px 0; border-top: 1px solid var(--line); }
.report-breakdown-name, .report-breakdown-value { display: grid; min-width: 0; gap: 3px; }
.report-breakdown-name strong, .report-breakdown-value strong { overflow: hidden; color: var(--ink); font-size: 10px; font-weight: 750; text-overflow: ellipsis; white-space: nowrap; }
.report-breakdown-name small, .report-breakdown-value small { color: var(--text-secondary); font-size: 8px; }
.report-breakdown-value { text-align: right; }
.report-breakdown-value strong { font-size: 11px; font-variant-numeric: tabular-nums; }
.report-product-row { justify-content: flex-start; }
.report-product-rank { display: grid; flex: 0 0 24px; width: 24px; height: 24px; place-items: center; border-radius: 7px; color: var(--brand-dark); background: var(--brand-soft); font-size: 9px; font-weight: 800; }
.report-product-name { overflow: hidden; flex: 1; color: var(--ink); font-size: 10px; font-weight: 650; text-overflow: ellipsis; white-space: nowrap; }
.report-product-row > strong { color: var(--text-secondary); font-size: 9px; white-space: nowrap; }
.report-customer-metrics { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; margin-top: 11px; }
.report-customer-metrics > div { display: flex; align-items: baseline; gap: 6px; padding: 10px; border: 1px solid var(--line); border-radius: 9px; background: var(--paper-soft); }
.report-customer-metrics strong { color: var(--ink); font-size: 18px; font-weight: 800; }
.report-customer-metrics span { color: var(--text-secondary); font-size: 9px; }
.report-demo-note, .report-calculation-note { margin: 10px 0 0; color: var(--text-secondary); font-size: 9px; line-height: 1.45; }
.report-calculation-note { padding: 0 2px; }
.report-panel-empty { padding: 17px 8px; color: var(--text-secondary); font-size: 10px; text-align: center; }

@media (max-width: 1000px) {
  .report-kpi-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (max-width: 760px) {
  .customers-screen { gap: 10px; padding-top: 13px; }
  .customers-toolbar { grid-template-columns: 1fr 1fr; }
  .customers-search { grid-column: 1 / -1; }
  .customers-toolbar > button { width: 100%; }
  .customer-directory-heading { min-height: 59px; padding: 10px; }
  .customer-directory-heading p { display: none; }
  .customer-list { padding: 0 9px; }
  .customer-row { grid-template-columns: 36px minmax(0, 1fr) auto; gap: 7px 9px; padding: 10px 3px; }
  .customer-avatar { width: 35px; height: 35px; grid-row: 1; }
  .customer-main-copy { grid-column: 2; grid-row: 1; }
  .customer-address-copy { grid-column: 2 / 4; grid-row: 2; }
  .customer-orders-badge { grid-column: 3; grid-row: 1; }
  .customer-row-actions { grid-column: 2 / 4; grid-row: 3; justify-content: flex-start; }
  .reports-screen { gap: 10px; padding-top: 13px; }
  .reports-filter-panel { padding: 9px; }
  .reports-filter-top { align-items: stretch; flex-direction: column; gap: 9px; }
  .reports-filter-actions { justify-content: space-between; }
  .report-period-picker { position: fixed; top: 80px; right: 10px; left: 10px; width: auto; max-height: calc(100dvh - 92px); }
  .reports-filter-bottom { align-items: stretch; }
  .reports-filter-bottom label { flex: 1 1 135px; min-width: 0; }
  .report-custom-period { align-items: stretch; flex-wrap: wrap; }
  .report-custom-period label { flex: 1 1 120px; }
  .report-custom-period button { flex: 1 1 100%; }
  .report-kpi-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 7px; }
  .report-kpi-card { min-height: 84px; padding: 10px; }
  .report-kpi-card > strong { font-size: 17px; }
  .report-content-grid { grid-template-columns: minmax(0, 1fr); gap: 8px; }
  .report-data-panel { min-height: 0; padding: 11px 12px; }
}
.dialog-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin-bottom: 18px; }
.dialog-heading h2 { margin: 5px 0 0; font-size: 19px; letter-spacing: -.03em; }
.dialog-close { width: 30px; height: 30px; border: 1px solid var(--line); border-radius: 9px; font-size: 20px; line-height: 1; }
.dialog-fields { display: grid; gap: 13px; }
.dialog-fields[hidden] { display: none; }
.dialog-fields label[hidden] { display: none !important; }
.dialog-fields label { display: grid; gap: 6px; color: var(--ink); font-size: 11px; font-weight: 700; }
.product-image-field { display: grid; gap: 7px; }
.product-image-field > label { display: flex; align-items: baseline; gap: 5px; color: var(--ink); font-size: 11px; font-weight: 700; }
.product-image-field > label span { color: var(--text-secondary); font-size: 10px; font-weight: 500; }
.product-image-picker { display: grid; grid-template-columns: 76px minmax(0, 1fr); align-items: center; gap: 11px; }
.product-image-preview { display: grid; width: 76px; height: 76px; overflow: hidden; place-items: center; border: 1px solid var(--line); border-radius: 11px; color: var(--text-secondary); background: var(--warning-soft); }
.product-image-preview img { width: 100%; height: 100%; object-fit: cover; }
.product-image-preview svg { width: 25px; height: 25px; fill: none; stroke: currentColor; stroke-width: 1.6; }
.product-image-controls { display: grid; justify-items: start; gap: 5px; min-width: 0; }
.product-image-controls input[type="file"] { width: 100%; min-height: 36px; padding: 4px; border: 1px solid var(--line); border-radius: 8px; color: var(--ink); background: var(--paper); font-size: 10px; }
.product-image-controls input[type="file"]::file-selector-button { min-height: 26px; margin-right: 7px; padding: 0 8px; border: 0; border-radius: 6px; color: var(--brand-dark); background: var(--brand-soft); font: inherit; font-weight: 700; cursor: pointer; }
.product-image-controls input[type="file"]:focus-visible { outline: 3px solid var(--brand-ring); outline-offset: 2px; }
.product-image-controls > small { color: var(--text-secondary); font-size: 10px; line-height: 1.4; }
.product-image-remove { padding: 0; border: 0; color: var(--brand-dark); background: transparent; font: inherit; font-size: 10px; font-weight: 700; cursor: pointer; }
.product-image-remove:hover { text-decoration: underline; text-underline-offset: 2px; }
.product-image-remove[hidden] { display: none; }
.dialog-fields input, .dialog-fields textarea, .dialog-fields select { width: 100%; min-height: 40px; padding: 9px 11px; border: 1px solid var(--line); border-radius: 9px; outline: none; color: var(--ink); background: var(--paper); font: inherit; font-size: 12px; font-weight: 400; }
.dialog-fields textarea { resize: vertical; }
.dialog-fields input:focus, .dialog-fields textarea:focus, .dialog-fields select:focus { border-color: var(--brand-line); box-shadow: 0 0 0 3px var(--brand-ring); }
.dialog-form-row { display: grid; grid-template-columns: .8fr 1.2fr; gap: 11px; }
.dialog-local-note { margin: 14px 0 0; padding: 9px 10px; border-radius: 8px; color: var(--ink); background: var(--warning-soft); font-size: 10px; line-height: 1.5; }
.dialog-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 17px; }
.dialog-actions .catalog-secondary-button { height: 38px; }
.catalog-toast { position: fixed; right: 24px; bottom: 77px; z-index: 20; max-width: min(370px, calc(100vw - 30px)); padding: 11px 15px; border: 1px solid var(--line); border-radius: 11px; color: var(--ink); background: var(--paper); box-shadow: 0 12px 32px var(--shadow-color); font-size: 11px; opacity: 0; pointer-events: none; transform: translateY(8px); transition: opacity .18s ease, transform .18s ease; }
.catalog-toast.is-visible { opacity: 1; transform: translateY(0); }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; clip-path: inset(50%); }

.coming-soon { display: grid; flex: 1; place-content: center; justify-items: center; max-width: 450px; align-self: center; padding: 36px 20px; text-align: center; }
.coming-soon[hidden] { display: none; }
.coming-icon { display: grid; width: 70px; height: 70px; place-items: center; margin-bottom: 17px; border: 1px solid var(--brand-line); border-radius: 22px; color: var(--brand-dark); background: var(--brand-soft); }
.coming-icon svg { width: 37px; height: 37px; }
.coming-soon h2 { margin: 0; font-size: 19px; letter-spacing: -.025em; }
.coming-soon .empty-copy { max-width: 370px; }

@media (max-width: 1050px) {
  .overview-workspace { padding: 23px 22px 17px; }
  .overview-screen { gap: 12px; padding-top: 15px; }
  .overview-metrics { gap: 8px; }
  .overview-stage-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .overview-lower-grid { grid-template-columns: 1fr; gap: 9px; }
  .overview-order-row { grid-template-columns: 42px minmax(90px, 1fr) auto 70px; gap: 7px; }
}

@media (max-width: 760px) {
  .overview-workspace { padding: 20px 15px 17px; }
  .overview-heading { align-items: flex-start; }
  .overview-heading h1 { font-size: 21px; }
  .overview-heading .page-description { font-size: 12px; }
  .overview-screen { gap: 11px; padding-top: 14px; }
  .overview-welcome { align-items: flex-start; flex-direction: column; gap: 13px; padding: 15px; }
  .welcome-copy h2 { font-size: 22px; }
  .welcome-copy > p:last-child { font-size: 12px; }
  .welcome-actions { width: 100%; }
  .overview-button { flex: 1; min-height: 38px; padding: 0 9px; font-size: 11px; }
  .overview-metrics { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 7px; }
  .overview-metric { min-height: 84px; padding: 10px; }
  .metric-label { min-height: 28px; font-size: 11px; white-space: normal; }
  .overview-metric > strong { font-size: 19px; }
  .metric-detail { font-size: 11px; }
  .overview-section-heading h2, .overview-card-heading h2 { font-size: 14px; }
  .overview-inline-action { font-size: 11px; }
  .overview-stage-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 7px; }
  .overview-stage { min-height: 92px; padding: 9px; }
  .overview-stage:last-child { grid-column: 1 / -1; }
  .stage-topline { font-size: 11px; }
  .overview-stage > strong { font-size: 22px; }
  .overview-lower-grid { grid-template-columns: 1fr; gap: 10px; }
  .overview-card-heading { min-height: 55px; padding: 8px 11px; }
  .overview-order-list { padding-right: 10px; padding-left: 10px; }
  .overview-order-row { grid-template-columns: 42px minmax(0, 1fr) auto; grid-template-rows: auto auto; gap: 4px 7px; min-height: 62px; padding: 6px 0; }
  .overview-order-id { grid-row: 1 / 3; }
  .overview-order-copy { grid-column: 2; grid-row: 1; }
  .overview-order-state { grid-column: 3; grid-row: 1; font-size: 10px; }
  .overview-order-total { grid-column: 2; grid-row: 2; text-align: left; font-size: 11px; }
  .overview-order-copy strong { font-size: 11px; }
  .overview-order-copy small { font-size: 11px; }
  .overview-demo-note { align-items: flex-start; font-size: 11px; line-height: 1.5; }
  .catalog-screen { padding-top: 14px; }
  .catalog-toolbar { top: 3px; grid-template-columns: minmax(0, 1fr) 40px; gap: 6px; padding: 6px; }
  .catalog-search { grid-column: 1 / 2; height: 40px; }
  .catalog-search kbd { display: none; }
  .category-select-wrap { grid-column: 1 / 2; grid-row: 2; height: 39px; }
  .catalog-toolbar > .catalog-icon-button { grid-column: 2; grid-row: 1; }
  .catalog-toolbar > .catalog-secondary-button { grid-column: 2; grid-row: 2; height: 39px; padding: 0 9px; font-size: 10px; }
  .catalog-toolbar > .catalog-secondary-button svg { display: none; }
  .catalog-create-category-wrap { margin: 11px 0 13px; }
  .catalog-create-category { min-height: 39px; }
  .catalog-list-heading { align-items: flex-start; font-size: 9px; }
  .catalog-list-heading > span { max-width: 155px; }
  .catalog-categories { gap: 10px; }
  .catalog-category-header { min-height: 49px; gap: 6px; padding-right: 7px; padding-left: 9px; }
  .category-edit-icon { flex-basis: 23px; width: 23px; }
  .catalog-category-title { gap: 5px; font-size: 12px; }
  .catalog-category-title span { font-size: 9px; }
  .category-header-actions { gap: 2px; }
  .category-header-actions .catalog-icon-button { width: 29px; height: 29px; }
  .catalog-add-product { width: calc(100% - 20px); min-height: 36px; margin: 7px 10px; }
  .catalog-product-row { grid-template-columns: 48px minmax(0, 1fr) auto 27px; gap: 8px; min-height: 68px; padding: 7px 5px 7px 9px; }
  .catalog-product-image { width: 48px; height: 48px; border-radius: 9px; }
  .catalog-product-copy strong { font-size: 12px; }
  .catalog-product-copy > span { font-size: 11px; }
  .catalog-price { min-height: 32px; border-radius: 9px; }
  .catalog-price > strong { padding: 0 7px; font-size: 11px; }
  .catalog-price button { width: 27px; height: 30px; }
  .catalog-row-actions > .catalog-icon-button { width: 27px; }
  .catalog-savebar { bottom: -17px; margin-right: -15px; margin-left: -15px; padding-right: 14px; padding-left: 14px; }
  .catalog-savebar > span { max-width: 55%; font-size: 9px; }
  .catalog-save-button { min-height: 36px; padding: 0 11px; font-size: 10px; white-space: nowrap; }
  .catalog-dialog form { padding: 18px; }
  .catalog-toast { right: 14px; bottom: 68px; }
}

@media (max-width: 420px) {
  .overview-workspace { padding-right: 12px; padding-left: 12px; }
  .overview-metrics { grid-template-columns: 1fr; }
  .overview-metric { min-height: 76px; }
  .overview-stage-grid { grid-template-columns: 1fr; }
  .overview-stage:last-child { grid-column: auto; }
  .overview-section-heading, .overview-card-heading { align-items: flex-start; }
  .overview-inline-action { padding-left: 0; }
}

/* Pedidos: quadro compacto, com todas as etapas visíveis sem rolagem lateral. */
.orders-screen { display: flex; flex: 1; flex-direction: column; min-width: 0; max-width: 100%; padding-top: 14px; }
.orders-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 14px; margin-bottom: 15px; }
.orders-search { display: flex; align-items: center; gap: 10px; width: min(420px, 100%); height: 44px; padding: 0 14px; border: 1px solid var(--line); border-radius: 999px; background: var(--paper); transition: border-color .16s ease, box-shadow .16s ease; }
.orders-search:focus-within { border-color: var(--brand-line); box-shadow: 0 0 0 3px var(--brand-ring); }
.orders-search svg { flex: 0 0 18px; width: 18px; height: 18px; color: var(--text-secondary); }
.orders-search input { width: 100%; min-width: 0; padding: 0; border: 0; outline: 0; color: var(--ink); background: transparent; font: inherit; font-size: 14px; }
.orders-search input::placeholder { color: var(--text-secondary); }
.orders-demo-state { display: inline-flex; align-items: center; gap: 7px; color: var(--muted); font-size: 12px; }
.orders-demo-state strong { color: var(--ink); font-weight: 700; }
.orders-demo-state > span { width: 8px; height: 8px; border-radius: 50%; background: var(--green); box-shadow: 0 0 0 3px var(--green-ring); }
.orders-board { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); align-items: stretch; gap: 10px; width: 100%; min-width: 0; }
.orders-lane { min-width: 0; overflow: hidden; border: 1px solid var(--line); border-radius: 15px; background: var(--page); }
.orders-lane-header { display: flex; align-items: center; gap: 7px; min-height: 48px; padding: 9px 10px; border-bottom: 1px solid var(--line); }
.lane-stage-dot { flex: 0 0 8px; width: 8px; height: 8px; border-radius: 50%; background: var(--stage-color); }
.orders-lane-header h3 { flex: 1 1 auto; min-width: 0; margin: 0; color: var(--ink); font-size: 12px; font-weight: 750; line-height: 1.25; }
.orders-lane-count { display: grid; flex: 0 0 23px; width: 23px; height: 23px; place-items: center; border-radius: 50%; color: var(--stage-deep); background: var(--stage-tint); font-size: 11px; font-weight: 800; }
.orders-lane.lane-waiting .orders-lane-count { color: #fff; background: var(--acceptance); }
.orders-lane.lane-preparing .orders-lane-count { color: #fff; background: var(--brand); }
.orders-lane-content { display: grid; align-content: start; gap: 8px; min-height: 260px; padding: 8px; }
.lane-empty { display: grid; min-height: 76px; place-items: center; margin: 0; padding: 13px 7px; color: var(--text-secondary); font-size: 12px; text-align: center; }
.order-ticket { min-width: 0; padding: 11px; border: 1px solid var(--line); border-radius: 12px; background: var(--paper); box-shadow: 0 2px 7px var(--shadow-color); cursor: pointer; transition: border-color .16s ease, box-shadow .16s ease, transform .16s ease; }
.order-ticket:hover { border-color: var(--stage-color); box-shadow: 0 6px 15px var(--shadow-color); transform: translateY(-1px); }
.order-ticket:focus-visible { outline: 3px solid var(--stage-color); outline-offset: 2px; }
.ticket-heading { display: flex; align-items: center; justify-content: space-between; gap: 7px; margin-bottom: 5px; }
.ticket-number { color: var(--ink); font-size: 20px; font-weight: 800; line-height: 1; letter-spacing: -.035em; }
.ticket-time { color: var(--text-secondary); font-size: 11px; font-variant-numeric: tabular-nums; }
.ticket-print-action { display: inline-flex; flex: 0 0 auto; align-items: center; justify-content: center; gap: 4px; min-height: 26px; margin-left: auto; padding: 0 7px; border: 1px solid var(--line); border-radius: 7px; color: var(--text-secondary); background: var(--paper); font: inherit; font-size: 10px; font-weight: 700; cursor: pointer; }
.ticket-print-action svg { width: 13px; height: 13px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.ticket-print-action:hover, .ticket-print-action:focus-visible { border-color: var(--brand-line); color: var(--brand-dark); background: var(--brand-soft); }
.ticket-print-action:focus-visible { outline: 3px solid var(--brand-ring); outline-offset: 2px; }
.ticket-customer { display: block; overflow: hidden; margin-bottom: 3px; color: var(--ink); font-size: 13px; font-weight: 750; text-overflow: ellipsis; white-space: nowrap; }
.ticket-items { display: -webkit-box; min-height: 34px; overflow: hidden; margin: 0; color: var(--ink); font-size: 12px; line-height: 1.4; overflow-wrap: anywhere; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.ticket-details { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 8px; }
.ticket-channel, .ticket-payment { display: inline-flex; align-items: center; min-height: 23px; max-width: 100%; padding: 2px 7px; border: 1px solid transparent; border-radius: 7px; color: var(--ink); background: var(--paper-soft); font: inherit; font-size: 10.5px; font-weight: 700; line-height: 1.25; overflow-wrap: anywhere; }
.ticket-channel { gap: 4px; border: 1px solid transparent; }
.ticket-channel svg { flex: 0 0 13px; width: 13px; height: 13px; }
.ticket-channel.is-pickup svg, .ticket-channel.is-other svg { fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.ticket-channel.is-delivery svg { fill: currentColor; stroke: none; }
.ticket-channel.is-delivery { color: var(--badge-delivery-fg); background: var(--badge-delivery-bg); border-color: var(--badge-delivery-line); }
.ticket-channel.is-pickup { color: var(--badge-pickup-fg); background: var(--badge-pickup-bg); border-color: var(--badge-pickup-line); }
.ticket-channel.is-dine-in { color: var(--green-dark); background: var(--green-soft); border-color: var(--green-line); }
.ticket-channel.is-other { color: var(--text-secondary); background: var(--paper-soft); border-color: var(--line); }
.ticket-payment.is-paid { color: var(--badge-paid-fg); background: var(--badge-paid-bg); border-color: var(--badge-paid-line); }
.ticket-payment.is-review { color: var(--text-secondary); background: var(--paper-soft); border-color: var(--line); }
.ticket-payment.is-due { color: var(--badge-due-fg); background: var(--badge-due-bg); border-color: var(--badge-due-line); }
button.ticket-payment.is-due { cursor: pointer; }
button.ticket-payment.is-due:hover, button.ticket-payment.is-due:focus-visible { border-color: var(--badge-due-line); background: var(--badge-due-bg); }
button.ticket-payment.is-due:focus-visible { outline: 3px solid var(--brand-ring); outline-offset: 2px; }
.ticket-payment-options-wrap { display: grid; justify-items: start; gap: 6px; margin-top: 7px; padding: 8px 9px; border: 1px solid var(--green-line); border-radius: 9px; background: var(--green-soft); }
.ticket-payment-options-wrap[hidden] { display: none; }
.ticket-payment-options-wrap > span { color: var(--green-dark); font-size: 10px; font-weight: 750; }
.ticket-payment-options-wrap .payment-method-options { margin-top: 0; }
.ticket-total { display: flex; align-items: center; justify-content: space-between; gap: 6px; margin-top: 8px; padding-top: 7px; border-top: 1px solid var(--line); }
.ticket-total > span { color: var(--text-secondary); font-size: 11px; }
.ticket-total > strong { color: var(--ink); font-size: 14px; font-weight: 800; white-space: nowrap; }
.ticket-detail-button { flex: 0 0 auto; min-height: 29px; padding: 0 9px; border: 1px solid var(--warning-line); border-radius: 8px; color: var(--ink); background: var(--paper); font: inherit; font-size: 11px; font-weight: 700; cursor: pointer; }
.ticket-detail-button:hover, .ticket-detail-button:focus-visible { border-color: var(--brand-line); color: var(--brand-dark); background: var(--brand-soft); }
.ticket-detail-button:focus-visible, .order-detail-close:focus-visible, .order-detail-footer .catalog-secondary-button:focus-visible { outline: 3px solid var(--brand-ring); outline-offset: 2px; }
.ticket-action { display: flex; align-items: center; justify-content: center; gap: 6px; width: 100%; min-height: 34px; margin-top: 9px; padding: 0 8px; border: 0; border-radius: 8px; color: var(--paper); background: var(--stage-color); font: inherit; font-size: 11px; font-weight: 750; cursor: pointer; transition: box-shadow .16s ease, transform .16s ease; }
.ticket-action.is-accept { color: #fff; background: var(--acceptance); }
.ticket-action:hover { box-shadow: 0 4px 10px var(--shadow-color); transform: translateY(-1px); }
.ticket-action:active { transform: scale(.98); }
.ticket-action:focus-visible { outline: 3px solid var(--brand-ring); outline-offset: 2px; }
.ticket-action svg, .ticket-complete svg { flex: 0 0 14px; width: 14px; height: 14px; fill: none; stroke: currentColor; stroke-width: 2; }
.ticket-complete { display: flex; align-items: center; justify-content: center; gap: 6px; min-height: 34px; margin-top: 9px; border-radius: 8px; color: var(--green-dark); background: var(--green-soft); font-size: 11px; font-weight: 750; }
.ticket-complete.is-returned { color: var(--text-secondary); background: var(--paper-soft); }
.ticket-complete.is-cancelled { color: var(--danger); background: var(--danger-soft); }
.orders-empty { display: grid; justify-items: center; gap: 7px; padding: 35px 16px 12px; color: var(--muted); text-align: center; }
.orders-empty[hidden] { display: none; }
.orders-empty strong { color: var(--ink); font-size: 14px; }
.orders-empty > span:last-child { font-size: 12px; }
.orders-demo-note { display: flex; align-items: center; gap: 7px; margin: 10px 1px 0; color: var(--text-secondary); font-size: 11px; line-height: 1.45; }
.orders-demo-note > span { display: grid; flex: 0 0 17px; width: 17px; height: 17px; place-items: center; border: 1px solid var(--warning-line); border-radius: 50%; color: var(--text-secondary); font-size: 11px; font-weight: 700; }

@media (max-width: 1160px) {
  .orders-board { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (max-width: 760px) {
  .orders-screen { padding-top: 12px; }
  .orders-toolbar { align-items: stretch; flex-direction: column; gap: 9px; }
  .orders-search { width: 100%; }
  .orders-demo-state { font-size: 12px; }
  .orders-board { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
  .orders-lane-header { min-height: 46px; padding-right: 8px; padding-left: 8px; }
  .orders-lane-header h3 { font-size: 11px; }
  .orders-lane-content { gap: 7px; padding: 7px; }
  .order-ticket { padding: 9px; }
  .ticket-number { font-size: 18px; }
  .ticket-customer { font-size: 12px; }
  .ticket-items { font-size: 11px; }
  .ticket-channel, .ticket-payment { font-size: 10px; }
  .ticket-action { font-size: 10px; }
}

@media (max-width: 480px) {
  .orders-board { grid-template-columns: 1fr; gap: 9px; }
  .orders-lane-header { min-height: 48px; padding-right: 11px; padding-left: 11px; }
  .orders-lane-header h3 { font-size: 13px; }
  .orders-lane-content { grid-template-columns: 1fr; padding: 8px; }
  .order-ticket { padding: 11px; }
  .ticket-customer { font-size: 13px; }
  .ticket-items { font-size: 12px; }
  .ticket-channel, .ticket-payment { font-size: 11px; }
  .ticket-action { font-size: 11px; }
}

@media (max-width: 560px) {
  .order-detail-shell { padding: 17px; }
  .order-detail-heading { margin-bottom: 13px; }
  .order-detail-heading h2 { font-size: 21px; }
  .order-detail-summary { grid-template-columns: 1fr; gap: 7px; padding: 13px; }
  .order-detail-received { grid-row: 2; }
  .order-detail-total { grid-row: 3; }
  .order-detail-grid { grid-template-columns: 1fr; gap: 8px; margin-top: 9px; }
  .order-detail-items { grid-column: auto; }
  .order-detail-card { padding: 11px; }
  .order-detail-contact { grid-template-columns: minmax(0, 1fr) auto; }
  .whatsapp-qr-code { width: 128px; height: 128px; }
  .order-detail-actions { margin-top: 9px; }
  .order-detail-footer { margin-top: 12px; }
  .route-start-layout { grid-template-columns: 1fr; }
  .route-start-whatsapp-column { grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: start; }
  .route-start-qr { grid-column: 1 / -1; width: min(240px, 100%); justify-self: center; }
  .route-start-qr .whatsapp-qr-code { width: 184px; height: 184px; }
  .route-start-send-note, .route-start-phone-note, .route-start-qr-fallback { grid-column: 1 / -1; }
  .route-start-footer { align-items: flex-start; }
}

/* Pedidos: quadro de expedição com uma fila ampla e etapas empilhadas. */
body[data-active-section="Pedidos"] .page-heading,
body[data-active-section="Pedidos"] .heading-divider { display: none; }
body[data-active-section="Pedidos"] .workspace { padding: 12px; }
body[data-active-section="Pedidos"] .orders-screen { gap: 10px; padding-top: 0; }
.orders-toolbar { align-items: center; gap: 12px; margin: 0; }
.orders-toolbar-main { display: flex; flex: 1 1 auto; align-items: center; gap: 8px; min-width: 0; }
.orders-search { width: min(390px, 100%); height: 42px; border-radius: 11px; }
.orders-filter { position: relative; flex: 0 0 auto; }
.orders-filter-button { display: inline-flex; align-items: center; justify-content: center; gap: 7px; min-height: 42px; padding: 0 14px; border: 1px solid var(--line); border-radius: 11px; color: var(--ink); background: var(--paper); font-size: 13px; font-weight: 700; cursor: pointer; list-style: none; }
.orders-filter-button::-webkit-details-marker { display: none; }
.orders-filter-button::marker { content: ""; }
.orders-filter-button:hover, .orders-filter[open] .orders-filter-button { border-color: var(--brand-line); background: var(--brand-soft); }
.orders-filter-button svg { width: 17px; height: 17px; }
.orders-filter-panel { position: absolute; top: calc(100% + 7px); left: 0; z-index: 12; display: grid; gap: 12px; width: 260px; padding: 14px; border: 1px solid var(--line); border-radius: 13px; background: var(--paper); box-shadow: 0 12px 30px var(--shadow-color); }
.orders-filter-panel[hidden] { display: none; }
.orders-filter-panel label { display: grid; gap: 6px; color: var(--ink); font-size: 12px; font-weight: 700; }
.orders-filter-panel select { width: 100%; min-height: 38px; padding: 0 9px; border: 1px solid var(--line); border-radius: 8px; color: var(--ink); background: var(--paper); font: inherit; font-size: 12px; }
.orders-filter-clear { justify-self: start; min-height: 30px; padding: 0; border: 0; color: var(--brand-dark); background: transparent; font: inherit; font-size: 12px; font-weight: 700; cursor: pointer; }
.orders-filter-clear:hover { color: var(--brand-dark); text-decoration: underline; }
.orders-demo-state { flex: 0 0 auto; min-height: 36px; padding: 0 11px; border: 1px solid var(--line); border-radius: 10px; background: var(--paper); white-space: nowrap; }
.orders-demo-state > .orders-demo-label { width: auto; height: auto; border-radius: 0; color: var(--text-secondary); background: transparent; box-shadow: none; }
.orders-board { grid-template-columns: minmax(0, 1.06fr) minmax(0, 1fr); grid-template-areas: "preparing waiting" "preparing ready" "preparing delivery" "preparing delivered"; grid-template-rows: repeat(4, minmax(115px, auto)); align-items: stretch; gap: 9px; }
.orders-board.has-returned { grid-template-areas: "preparing waiting" "preparing ready" "preparing delivery" "preparing returned" "preparing delivered"; grid-template-rows: repeat(5, minmax(92px, auto)); }
.orders-board:not(.has-waiting) { grid-template-areas: "preparing ready" "preparing delivery" "preparing delivered"; grid-template-rows: repeat(3, minmax(115px, auto)); }
.orders-board.has-returned:not(.has-waiting) { grid-template-areas: "preparing ready" "preparing delivery" "preparing returned" "preparing delivered"; grid-template-rows: repeat(4, minmax(92px, auto)); }
.orders-board[hidden] { display: none; }
.orders-lane { display: flex; flex-direction: column; min-height: 0; overflow: hidden; border: 1px solid var(--line); border-radius: 14px; background: var(--page); }
.orders-lane.lane-waiting { grid-area: waiting; }
.orders-lane.lane-preparing { grid-area: preparing; }
.orders-lane.lane-ready { grid-area: ready; }
.orders-lane.lane-delivery { grid-area: delivery; }
.orders-lane.lane-returned { grid-area: returned; }
.orders-lane.lane-delivered { grid-area: delivered; }
.orders-lane-header { flex: 0 0 auto; min-height: 34px; padding: 5px 12px; border-bottom: 0; }
.orders-lane-header h3 { font-size: 12px; }
.orders-lane-count { width: auto; min-width: 22px; height: 20px; padding: 0 6px; border-radius: 999px; }
.orders-lane-content { flex: 1 1 auto; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); align-content: start; gap: 7px; min-height: 0; padding: 8px 9px 6px; }
.orders-lane.is-empty .orders-lane-content { display: flex; align-items: center; justify-content: center; min-height: 76px; padding: 0 14px 12px; }
.orders-lane.lane-preparing.is-empty .orders-lane-content { min-height: 340px; }
.lane-empty-state { display: grid; justify-items: center; gap: 7px; max-width: 300px; padding: 16px; color: var(--text-secondary); text-align: center; }
.lane-empty-icon { display: grid; width: 36px; height: 36px; place-items: center; color: var(--muted); }
.lane-empty-icon svg { width: 27px; height: 27px; stroke-width: 1.8; }
.lane-empty-state strong { color: var(--ink); font-size: 13px; font-weight: 700; }
.lane-empty-state small { max-width: 260px; color: var(--text-secondary); font-size: 12px; line-height: 1.35; }
.lane-empty-search { color: var(--text-secondary); font-size: 12px; text-align: center; }
.order-ticket { display: grid; align-content: start; gap: 2px; padding: 7px; }
.ticket-heading { margin-bottom: 0; }
.ticket-number { font-size: 18px; }
.ticket-customer { margin: 0; font-size: 12px; }
.ticket-items { display: block; min-height: 0; overflow: hidden; font-size: 11px; line-height: 1.25; text-overflow: ellipsis; white-space: nowrap; }
.ticket-details { gap: 4px; margin-top: 1px; }
.ticket-channel, .ticket-payment { min-height: 20px; padding: 2px 6px; font-size: 10px; }
.ticket-footer { display: flex; align-items: center; justify-content: space-between; gap: 6px; min-width: 0; margin-top: 2px; padding-top: 4px; border-top: 1px solid var(--line); }
.ticket-total { display: grid; flex: 0 0 auto; justify-content: start; gap: 1px; margin: 0; padding: 0; border: 0; }
.ticket-total > span { font-size: 9px; line-height: 1; }
.ticket-total > strong { font-size: 12px; }
.ticket-action { width: auto; flex: 0 1 auto; min-width: 0; min-height: 28px; margin: 0; padding: 0 7px; font-size: 10px; }
.ticket-action svg { width: 12px; height: 12px; flex-basis: 12px; }
.ticket-complete { flex: 0 1 auto; min-height: 28px; margin: 0; padding: 0 7px; font-size: 10px; }
.orders-demo-note { margin-top: 0; }

@media (min-width: 761px) {
  body.sidebar-collapsed .app-shell { grid-template-columns: 64px minmax(0, 1fr); padding-bottom: 0; }
  body.sidebar-collapsed .sidebar { align-items: center; padding-right: 5px; padding-left: 5px; }
  body.sidebar-collapsed .brand-row { justify-content: center; padding: 0; margin: 3px 0 12px; }
  body.sidebar-collapsed .brand-copy,
  body.sidebar-collapsed .store-status,
  body.sidebar-collapsed .nav-label,
  body.sidebar-collapsed .account-copy,
  body.sidebar-collapsed .account-more,
  body.sidebar-collapsed .sign-out > span { display: none; }
  body.sidebar-collapsed .sidebar-collapse-row { justify-content: center; width: 100%; padding: 0; margin-bottom: 9px; }
  body.sidebar-collapsed .sidebar-collapse-toggle { width: 40px; min-height: 36px; padding: 0; }
  body.sidebar-collapsed .sidebar-collapse-toggle span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; }
  body.sidebar-collapsed .navigation { align-items: center; width: 100%; gap: 7px; }
  body.sidebar-collapsed .nav-item { justify-content: center; width: 44px; min-height: 42px; padding: 0; }
  body.sidebar-collapsed .nav-item > span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; }
  body.sidebar-collapsed .nav-item svg,
  body.sidebar-collapsed .nav-item img { flex-basis: 19px; width: 19px; height: 19px; }
  body.sidebar-collapsed .sidebar-bottom { width: 100%; }
  body.sidebar-collapsed .account-row { justify-content: center; padding: 10px 0 8px; }
  body.sidebar-collapsed .sign-out { justify-content: center; padding: 0; }
  body.sidebar-collapsed .main-column { min-width: 0; }
  body.sidebar-collapsed .topbar { min-height: 48px; }
}

@media (max-width: 1160px) {
  .orders-board { grid-template-columns: repeat(2, minmax(0, 1fr)); grid-template-areas: "waiting waiting" "preparing ready" "delivery delivered"; grid-template-rows: repeat(3, minmax(150px, auto)); }
  .orders-board.has-returned { grid-template-areas: "waiting waiting" "preparing ready" "delivery returned" "delivered delivered"; grid-template-rows: repeat(4, minmax(150px, auto)); }
  .orders-board:not(.has-waiting) { grid-template-areas: "preparing ready" "delivery delivered"; grid-template-rows: repeat(2, minmax(150px, auto)); }
  .orders-board.has-returned:not(.has-waiting) { grid-template-areas: "preparing ready" "delivery returned" "delivered delivered"; grid-template-rows: repeat(3, minmax(150px, auto)); }
  .orders-lane.lane-preparing { grid-area: preparing; }
  .orders-lane.lane-preparing.is-empty .orders-lane-content { min-height: 76px; }
}

@media (max-width: 760px) {
  body[data-active-section="Pedidos"] .workspace { padding: 14px 10px; }
  .orders-toolbar { align-items: stretch; flex-direction: column; gap: 8px; }
  .orders-toolbar-main { width: 100%; }
  .orders-search { flex: 1 1 auto; width: auto; }
  .orders-demo-state { align-self: flex-start; }
  .orders-board, .orders-board.has-returned { grid-template-columns: 1fr; grid-template-areas: none; grid-template-rows: auto; gap: 8px; }
  .orders-board:not(.has-waiting), .orders-board.has-returned:not(.has-waiting) { grid-template-columns: 1fr; grid-template-areas: none; grid-template-rows: auto; }
  .orders-lane.lane-waiting,
  .orders-lane.lane-preparing,
  .orders-lane.lane-ready,
  .orders-lane.lane-delivery,
  .orders-lane.lane-returned,
  .orders-lane.lane-delivered { grid-area: auto; }
  .orders-lane.lane-preparing.is-empty .orders-lane-content { min-height: 110px; }
  .orders-lane-content { grid-template-columns: 1fr; }
}

@media (max-width: 420px) {
  .orders-filter-button { padding: 0 10px; }
  .orders-demo-label { display: none; }
}


/* Rotas: fila para a próxima saída e acompanhamento das entregas. */
.routes-screen { display: flex; flex: 1; flex-direction: column; min-width: 0; gap: 12px; padding-top: 14px; }
.route-summary-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 9px; }
.route-summary-card { display: flex; align-items: center; gap: 10px; min-width: 0; min-height: 78px; padding: 11px 12px; border: 1px solid var(--line); border-radius: 13px; background: var(--paper); box-shadow: 0 2px 8px var(--shadow-color); }
.route-summary-icon { display: grid; flex: 0 0 34px; width: 34px; height: 34px; place-items: center; border-radius: 11px; }
.route-summary-icon svg { width: 18px; height: 18px; }
.route-summary-icon.is-ready { color: var(--green-dark); background: var(--green-soft); }
.route-summary-icon.is-preparing { color: var(--brand-dark); background: var(--warning-soft); }
.route-summary-icon.is-active { color: var(--info-dark); background: var(--info-soft); }
.route-summary-card > span:nth-child(2) { display: grid; min-width: 0; gap: 3px; }
.route-summary-card small { color: var(--text-secondary); font-size: 11px; font-weight: 600; white-space: nowrap; }
.route-summary-card strong { color: var(--ink); font-size: 21px; line-height: 1; }
.route-summary-card em { overflow: hidden; margin-left: auto; color: var(--text-secondary); font-size: 11px; font-style: normal; text-align: right; text-overflow: ellipsis; }
.route-workspace-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.04fr); align-items: start; gap: 11px; min-width: 0; }
.route-panel { min-width: 0; overflow: hidden; border: 1px solid var(--line); border-radius: 15px; background: var(--paper); box-shadow: 0 3px 12px var(--shadow-color); }
.route-panel-heading, .route-activity-heading { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 15px 16px 13px; border-bottom: 1px solid var(--line); }
.route-panel-heading h2, .route-activity-heading h2 { margin: 0; color: var(--ink); font-size: 16px; font-weight: 800; letter-spacing: -.025em; }
.route-panel-heading p:last-child { margin: 5px 0 0; color: var(--muted); font-size: 12px; }
.route-heading-icon { display: grid; flex: 0 0 38px; width: 38px; height: 38px; place-items: center; border: 1px solid var(--brand-line); border-radius: 12px; color: var(--brand-dark); background: var(--brand-soft); }
.route-heading-icon svg { width: 19px; height: 19px; }
.route-planner-controls { display: grid; grid-template-columns: 1fr; gap: 9px; padding: 12px 15px 3px; }
.route-planner-controls label { display: grid; gap: 6px; color: var(--ink); font-size: 11px; font-weight: 700; }
.route-planner-controls select { width: 100%; min-width: 0; height: 39px; padding: 0 10px; border: 1px solid var(--line); border-radius: 9px; color: var(--ink); background: var(--paper); font: inherit; font-size: 12px; }
.route-courier-selector { margin: 9px 12px 2px; padding: 11px; border: 1px solid var(--brand-line); border-radius: 13px; background: var(--brand-soft); }
.route-courier-selector > header { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 0 1px 10px; }
.route-courier-selector h3 { margin: 0; color: var(--ink); font-size: 13px; font-weight: 800; }
.route-courier-selector > header span:not(.route-courier-count) { display: block; margin-top: 3px; color: var(--muted); font-size: 11px; }
.route-queue-heading { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 13px 15px 8px; }
.route-queue-heading h3 { margin: 0; color: var(--ink); font-size: 13px; font-weight: 800; }
.route-queue-heading span { display: block; margin-top: 3px; color: var(--text-secondary); font-size: 11px; }
.route-queue-count { display: inline-grid !important; flex: 0 0 25px; width: 25px; height: 25px; place-items: center; margin: 0 !important; border-radius: 50%; color: #fff; background: var(--brand); font-size: 11px !important; font-weight: 800; }
.route-order-list { display: grid; gap: 6px; padding: 0 12px 10px; }
.route-order-option { display: grid; grid-template-columns: 17px 42px minmax(0, 1fr) auto; align-items: center; gap: 9px; min-width: 0; padding: 9px 10px; border: 1px solid var(--line); border-radius: 11px; background: var(--paper); cursor: pointer; transition: border-color .16s ease, background .16s ease, box-shadow .16s ease; }
.route-order-option:hover { border-color: var(--brand-line); background: var(--paper-hover); }
.route-order-option.is-selected { border-color: var(--brand-line); background: var(--brand-soft); box-shadow: inset 3px 0 var(--brand); }
.route-order-option input { width: 16px; height: 16px; margin: 0; accent-color: var(--brand); cursor: pointer; }
.route-order-number { display: grid; width: 40px; height: 31px; place-items: center; border-radius: 8px; color: #fff; background: var(--brand); font-size: 11px; font-weight: 800; }
.route-order-copy { display: grid; min-width: 0; gap: 2px; }
.route-order-copy strong { overflow: hidden; color: var(--ink); font-size: 12px; text-overflow: ellipsis; white-space: nowrap; }
.route-order-copy small, .route-order-copy > span { overflow: hidden; color: var(--muted); font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.route-order-meta { display: grid; justify-items: end; gap: 3px; color: var(--ink); font-size: 12px; white-space: nowrap; }
.route-order-meta > small { color: var(--text-secondary); font-size: 11px; }
.route-order-meta .is-paid, .route-stop-side .is-paid { color: var(--green-dark); }
.route-order-meta .is-due, .route-stop-side .is-due { color: var(--warning-dark); }
.route-ready-estimate { color: var(--warning-dark) !important; }
.route-prep-disclosure { margin: 0 12px 8px; border: 1px solid var(--line); border-radius: 11px; background: var(--warning-soft); }
.route-prep-disclosure > summary { display: flex; align-items: center; gap: 10px; min-height: 48px; padding: 7px 10px; cursor: pointer; list-style: none; }
.route-prep-disclosure > summary::-webkit-details-marker { display: none; }
.route-prep-disclosure > summary::marker { content: ""; }
.route-prep-disclosure > summary > span:first-child { display: grid; flex: 1; gap: 2px; min-width: 0; }
.route-prep-disclosure > summary strong { color: var(--ink); font-size: 12px; }
.route-prep-disclosure > summary small { overflow: hidden; color: var(--text-secondary); font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.route-prep-disclosure > summary > svg { width: 16px; height: 16px; color: var(--text-secondary); transition: transform .16s ease; }
.route-prep-disclosure[open] > summary > svg { transform: rotate(180deg); }
.route-prep-list { padding-top: 0; }
.route-queue-empty { display: grid; gap: 3px; padding: 15px 12px; border: 1px dashed var(--line); border-radius: 10px; color: var(--text-secondary); text-align: center; }
.route-queue-empty strong { color: var(--ink); font-size: 12px; }
.route-queue-empty span { font-size: 11px; }
.route-planner-footer { display: flex; align-items: center; justify-content: space-between; gap: 10px; min-height: 58px; padding: 9px 15px; border-top: 1px solid var(--line); background: var(--paper-soft); }
.route-planner-footer > span { color: var(--ink); font-size: 11px; font-weight: 600; }
.route-primary-button, .route-release-button, .route-stop-action { display: inline-flex; align-items: center; justify-content: center; min-height: 36px; padding: 0 13px; border: 0; border-radius: 9px; color: var(--paper); background: var(--brand); font: inherit; font-size: 11px; font-weight: 800; cursor: pointer; transition: background .16s ease, transform .16s ease, box-shadow .16s ease; }
.route-primary-button:hover:not(:disabled), .route-release-button:hover:not(:disabled), .route-stop-action:hover { background: var(--brand-hover); box-shadow: 0 4px 10px var(--brand-ring); }
.route-primary-button:active:not(:disabled), .route-release-button:active:not(:disabled), .route-stop-action:active { transform: scale(.98); }
.route-primary-button:disabled, .route-release-button:disabled { color: var(--text-secondary); background: var(--page); cursor: not-allowed; box-shadow: none; }
.route-activity-heading { min-height: 76px; }
.route-activity-heading h2 { font-size: 16px; }
.route-live-label { display: inline-flex; align-items: center; gap: 7px; padding: 7px 9px; border: 1px solid var(--green-line); border-radius: 999px; color: var(--green-dark); background: var(--green-soft); font-size: 11px; font-weight: 700; white-space: nowrap; }
.route-live-label[hidden] { display: none !important; }
.route-live-label > span:first-child { width: 7px; height: 7px; border-radius: 50%; background: var(--green); box-shadow: 0 0 0 3px var(--green-ring); }
.route-card-list { display: grid; gap: 9px; padding: 11px; }
.route-card { min-width: 0; overflow: hidden; border: 1px solid var(--line); border-radius: 12px; background: var(--paper); }
.route-card.is-completed { background: var(--paper); }
.route-card.is-active { border-left: 3px solid var(--info-line); }
.route-card.is-reserved-card { border-left: 3px solid var(--warning-line); }
.route-card-heading { display: flex; align-items: center; justify-content: space-between; gap: 10px; min-height: 56px; padding: 9px 11px; border-bottom: 1px solid var(--line); }
.route-card-id { display: flex; align-items: center; gap: 9px; min-width: 0; }
.route-driver-avatar { display: grid; flex: 0 0 34px; width: 34px; height: 34px; place-items: center; border-radius: 10px; color: var(--paper); background: var(--brand); font-size: 10px; font-weight: 800; }
.route-card-id > span:last-child { display: grid; gap: 2px; min-width: 0; }
.route-card-id small { color: var(--brand-dark); font-size: 11px; font-weight: 800; letter-spacing: .05em; }
.route-card-id strong { overflow: hidden; color: var(--ink); font-size: 12px; text-overflow: ellipsis; white-space: nowrap; }
.route-status { display: inline-flex; align-items: center; gap: 6px; padding: 6px 8px; border-radius: 999px; font-size: 11px; font-weight: 800; white-space: nowrap; }
.route-status > span { width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.route-status.is-on-road { color: var(--info-dark); background: var(--info-soft); }
.route-status.is-reserved { color: #fff; background: var(--brand); }
.route-status.is-complete { color: var(--green-dark); background: var(--green-soft); }
.route-card-facts { display: flex; align-items: center; flex-wrap: wrap; gap: 12px; min-height: 36px; padding: 6px 12px; color: var(--muted); background: var(--paper-soft); }
.route-card-facts > span { display: inline-flex; align-items: center; gap: 5px; font-size: 11px; font-weight: 600; }
.route-card-facts svg { width: 14px; height: 14px; color: var(--text-secondary); }
.route-card-facts .route-capacity-copy { margin-left: auto; color: var(--text-secondary); }
.route-stops { display: grid; padding: 2px 11px; }
.route-stop { position: relative; display: grid; grid-template-columns: 26px minmax(0, 1fr) auto; align-items: start; gap: 8px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.route-stop:last-child { border-bottom: 0; }
.route-stop-index { position: relative; display: grid; width: 24px; height: 24px; place-items: center; border: 1px solid var(--info-line); border-radius: 50%; color: var(--info-dark); background: var(--info-soft); font-size: 10px; font-weight: 800; }
.route-stop:not(:last-child) .route-stop-index::after { position: absolute; top: 24px; left: 10px; width: 1px; height: calc(100% + 17px); background: var(--page); content: ""; }
.route-stop.is-done .route-stop-index { border-color: var(--green-line); color: var(--green-dark); background: var(--green-soft); }
.route-stop.is-returned .route-stop-index { border-color: var(--line-strong); color: var(--ink); background: var(--paper-soft); }
.route-stop.is-cancelled .route-stop-index { border-color: var(--danger); color: var(--danger); background: var(--danger-soft); }
.route-stop.is-waiting .route-stop-index { border-color: var(--brand); color: #fff; background: var(--brand); }
.route-stop-copy { display: grid; min-width: 0; gap: 3px; }
.route-stop-copy strong { overflow: hidden; color: var(--ink); font-size: 12px; text-overflow: ellipsis; white-space: nowrap; }
.route-stop-copy small, .route-stop-copy > span { overflow: hidden; color: var(--muted); font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.route-stop-side { display: grid; justify-items: end; gap: 3px; color: var(--ink); font-size: 11px; white-space: nowrap; }
.route-stop-status { padding: 3px 6px; border-radius: 6px; color: var(--info-dark); background: var(--info-soft); font-size: 10px; font-weight: 800; }
.route-stop.is-waiting .route-stop-status { color: #fff; background: var(--brand); }
.route-stop.is-ready .route-stop-status, .route-stop.is-done .route-stop-status { color: var(--green-dark); background: var(--green-soft); }
.route-stop.is-returned .route-stop-status { color: var(--ink); background: var(--paper-soft); }
.route-stop.is-cancelled .route-stop-status { color: var(--danger); background: var(--danger-soft); }
.route-stop-action { min-height: 29px; margin-top: 2px; padding: 0 9px; border: 1px solid var(--line); color: var(--ink); background: var(--paper); font-size: 11px; }
.route-stop-action:hover { border-color: var(--brand-line); color: var(--brand-dark); background: var(--brand-soft); box-shadow: none; }
.route-stop-action.is-return { color: var(--text-secondary); }
.route-stop-action.is-return:hover { border-color: var(--line-strong); color: var(--ink); background: var(--paper-soft); }
.route-stop-action.is-payment { border-color: var(--green); color: var(--paper); background: var(--green); font-weight: 750; }
.route-stop-action.is-payment:hover { border-color: var(--green-dark); color: var(--paper); background: var(--green-dark); }
.route-stop > .order-return-actions-inline { grid-column: 2 / -1; margin-top: 0; }
.route-payment-options-wrap { grid-column: 2 / -1; display: grid; justify-items: start; gap: 6px; min-width: 0; padding: 8px 10px; border: 1px solid var(--green-line); border-radius: 9px; background: var(--green-soft); }
.route-payment-options-wrap[hidden] { display: none; }
.route-payment-options-wrap > span { color: var(--green-dark); font-size: 10px; font-weight: 750; }
.route-payment-options-wrap .payment-method-options { margin-top: 0; }
.route-card-footer { display: flex; align-items: center; justify-content: space-between; gap: 10px; min-height: 48px; padding: 8px 11px; border-top: 1px solid var(--line); background: var(--paper-soft); }
.route-card-footer > span:first-child { color: var(--muted); font-size: 11px; }
.route-progress-track { flex: 0 0 75px; height: 6px; overflow: hidden; border-radius: 99px; background: var(--page); }
.route-progress-track > span { display: block; height: 100%; border-radius: inherit; background: var(--green); transition: width .2s ease; }
.route-complete-stamp { color: var(--green-dark); font-size: 11px; font-weight: 800; }
.route-release-button { min-height: 32px; padding: 0 10px; font-size: 11px; }
.route-activity-empty { display: grid; justify-items: center; gap: 7px; min-height: 220px; place-content: center; padding: 20px; color: var(--muted); text-align: center; }
.route-activity-empty > span { display: grid; width: 42px; height: 42px; place-items: center; border-radius: 14px; color: var(--brand-dark); background: var(--brand-soft); }
.route-activity-empty svg { width: 21px; height: 21px; }
.route-activity-empty strong { color: var(--ink); font-size: 13px; }
.route-activity-empty small { max-width: 280px; font-size: 11px; line-height: 1.5; }
.route-empty-state { padding: 14px; color: var(--muted); font-size: 11px; text-align: center; }
.route-demo-note { display: flex; align-items: center; gap: 7px; margin: 0 1px; color: var(--text-secondary); font-size: 11px; line-height: 1.45; }
.route-demo-note > span { display: grid; flex: 0 0 17px; width: 17px; height: 17px; place-items: center; border: 1px solid var(--warning-line); border-radius: 50%; color: var(--text-secondary); font-size: 11px; font-weight: 700; }

.couriers-screen { display: flex; flex: 1; min-width: 0; padding-top: 14px; }
.courier-team-panel { width: 100%; align-self: start; overflow: hidden; border: 1px solid var(--line); border-radius: 16px; background: var(--paper); box-shadow: 0 3px 12px var(--shadow-color); }
.courier-route-report { position: relative; margin: 14px 16px 0; padding: 15px; border: 1px solid var(--line); border-radius: 13px; background: var(--paper); }
.courier-route-report-heading { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.courier-route-report-heading h3 { margin: 0; color: var(--ink); font-size: 15px; font-weight: 800; }
.courier-route-report-heading p:last-child { margin: 4px 0 0; color: var(--muted); font-size: 11px; }
.courier-period-control { position: relative; z-index: 8; flex: 0 1 auto; min-width: 0; }
.courier-period-trigger { display: inline-flex; align-items: center; gap: 8px; min-height: 40px; max-width: min(100%, 440px); padding: 0 11px; border: 1px solid var(--line-strong); border-radius: 8px; color: var(--ink); background: var(--paper); font: inherit; font-size: 11px; font-weight: 700; text-align: left; cursor: pointer; }
.courier-period-trigger:hover, .courier-period-trigger[aria-expanded="true"] { border-color: var(--brand-line); background: var(--paper-soft); }
.courier-period-trigger > svg:first-child { flex: 0 0 16px; width: 16px; height: 16px; color: var(--text-secondary); }
.courier-period-trigger > span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.courier-period-chevron { flex: 0 0 14px; width: 14px; height: 14px; margin-left: auto; color: var(--text-secondary); }
.courier-period-picker { position: absolute; top: calc(100% + 8px); right: 0; display: grid; grid-template-columns: 172px minmax(0, 1fr); width: min(700px, calc(100vw - 34px)); max-height: min(540px, calc(100vh - 100px)); overflow: hidden; border: 1px solid var(--line); border-radius: 12px; background: var(--paper); box-shadow: 0 14px 38px rgb(18 25 38 / 18%); }
.courier-period-picker[hidden] { display: none !important; }
.courier-period-presets { overflow-y: auto; padding: 12px 10px; border-right: 1px solid var(--line); background: var(--paper); }
.courier-period-presets > p { margin: 0 0 7px; color: var(--text-secondary); font-size: 10px; font-weight: 800; }
.courier-period-presets hr { height: 1px; margin: 10px 0; border: 0; background: var(--line); }
#courier-period-recent, #courier-period-preset-list { display: grid; gap: 2px; }
.courier-period-option { display: flex; align-items: center; gap: 8px; min-height: 29px; padding: 4px 6px; border: 0; border-radius: 6px; color: var(--ink); background: transparent; font: inherit; font-size: 11px; text-align: left; cursor: pointer; }
.courier-period-option:hover { background: var(--paper-soft); }
.courier-period-option.is-active { color: var(--brand-dark); background: var(--brand-soft); font-weight: 750; }
.courier-period-radio { display: grid; flex: 0 0 16px; width: 16px; height: 16px; place-items: center; border: 1px solid var(--line-strong); border-radius: 50%; background: var(--paper); }
.courier-period-option.is-active .courier-period-radio { border-color: var(--brand); }
.courier-period-option.is-active .courier-period-radio::after { width: 8px; height: 8px; border-radius: 50%; background: var(--brand); content: ""; }
.courier-period-main { display: grid; grid-template-rows: auto auto auto auto; align-content: start; gap: 8px; min-width: 0; padding: 10px; }
.courier-calendar-heading { display: grid; grid-template-columns: 28px 1fr 28px; align-items: center; min-height: 32px; }
.courier-calendar-heading > button { display: grid; width: 28px; height: 28px; place-items: center; border: 0; border-radius: 6px; color: var(--ink); background: transparent; cursor: pointer; }
.courier-calendar-heading > button:hover { background: var(--paper-soft); }
.courier-calendar-heading > button svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.8; }
#courier-calendar-month-labels { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; color: var(--ink); font-size: 12px; font-weight: 750; text-align: center; }
.courier-calendar-pair { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; padding: 3px 1px 8px; }
.courier-calendar-month { min-width: 0; }
.courier-calendar-weekdays, .courier-calendar-days { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 2px; }
.courier-calendar-weekdays { margin-bottom: 3px; color: var(--muted); font-size: 9px; text-align: center; }
.courier-calendar-days button, .courier-calendar-empty { display: grid; min-width: 0; height: 25px; place-items: center; border: 0; border-radius: 5px; color: var(--ink); background: transparent; font: inherit; font-size: 10px; cursor: pointer; }
.courier-calendar-days button:hover { outline: 1px solid var(--brand-line); }
.courier-calendar-days button.is-in-range { border-radius: 0; background: var(--brand-soft); }
.courier-calendar-days button.is-range-start, .courier-calendar-days button.is-range-end { border-radius: 5px; color: #fff; background: var(--brand); font-weight: 800; }
.courier-calendar-days button.is-today:not(.is-range-start):not(.is-range-end) { box-shadow: inset 0 0 0 1px var(--brand-line); }
.courier-period-edit { display: grid; grid-template-columns: 7px auto minmax(125px, 1fr) minmax(116px, auto) minmax(116px, auto); align-items: center; gap: 6px; padding: 9px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); color: var(--ink); font-size: 10px; }
.courier-period-swatch { width: 7px; height: 7px; border-radius: 50%; background: var(--brand); }
.courier-period-edit select, .courier-date-field input { width: 100%; min-width: 0; height: 32px; padding: 0 7px; border: 1px solid var(--line-strong); border-radius: 6px; color: var(--ink); background: var(--paper); font: inherit; font-size: 10px; }
.courier-date-field { display: grid; grid-template-columns: auto minmax(0, 1fr); align-items: center; gap: 5px; color: var(--muted); }
.courier-period-footer { display: flex; align-items: center; justify-content: space-between; gap: 9px; padding-top: 9px; }
.courier-period-footer small { color: var(--muted); font-size: 9px; }
.courier-period-footer > div { display: flex; gap: 6px; }
.courier-period-footer button { min-height: 32px; padding: 0 10px; border: 1px solid var(--line-strong); border-radius: 7px; color: var(--ink); background: var(--paper); font: inherit; font-size: 10px; font-weight: 700; cursor: pointer; }
.courier-period-footer button[data-period-apply] { border-color: var(--brand); color: #fff; background: var(--brand); }
.courier-period-footer button[data-period-apply]:hover { background: var(--brand-hover); }
.courier-route-report-totals { display: grid; grid-template-columns: 1.4fr repeat(2, minmax(0, 1fr)); gap: 8px; margin-top: 12px; }
.courier-route-report-totals article { display: grid; gap: 4px; min-height: 53px; padding: 9px 11px; border-radius: 9px; background: var(--paper-soft); }
.courier-route-report-totals article span { color: var(--muted); font-size: 10px; font-weight: 650; }
.courier-route-report-totals article strong { color: var(--ink); font-size: 17px; line-height: 1.1; }
.courier-route-report-totals article:first-child { border-left: 3px solid var(--brand); }
.courier-team-card .courier-team-route-value { display: grid; gap: 4px; padding: 9px 10px; border: 1px solid var(--line); border-radius: 9px; background: var(--paper); }
.courier-team-route-value span { color: var(--muted); font-size: 10px; }
.courier-team-route-value strong { color: var(--ink); font-size: 16px; }
.courier-team-route-value small { color: var(--text-secondary); font-size: 9px; }
.courier-team-summary { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 9px; padding: 14px 16px 4px; }
.courier-team-summary article { display: flex; align-items: center; justify-content: space-between; gap: 10px; min-height: 60px; padding: 10px 13px; border: 1px solid var(--line); border-radius: 11px; color: var(--ink); background: var(--paper-soft); font-size: 12px; font-weight: 650; }
.courier-team-summary article strong { color: var(--ink); font-size: 21px; }
.courier-team-summary article.is-available { border-color: var(--green-line); background: var(--green-soft); }
.courier-team-summary article.is-available strong { color: var(--green-dark); }
.courier-team-summary article.is-working { border-color: var(--info-line); background: var(--info-soft); }
.courier-team-summary article.is-working strong { color: var(--info-dark); }
.courier-team-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; padding: 12px 16px 16px; }
.courier-team-card { display: grid; align-content: start; gap: 14px; min-width: 0; padding: 15px; border: 1px solid var(--line); border-radius: 13px; background: var(--paper); cursor: pointer; transition: border-color .16s ease, box-shadow .16s ease; }
.courier-team-card:hover, .courier-team-card:focus-within { border-color: var(--brand-line); box-shadow: 0 3px 10px var(--brand-ring); }
.courier-team-card:focus-visible { outline: 3px solid var(--brand-ring); outline-offset: 2px; }
.courier-team-card.is-offline-card { background: var(--paper-soft); }
.courier-team-card > header { display: flex; align-items: center; gap: 10px; min-width: 0; }
.courier-team-card-actions { display: flex; align-items: center; gap: 6px; flex: 0 0 auto; }
.courier-more-wrap { position: relative; }
.courier-more-button { display: grid; width: 30px; height: 30px; place-items: center; padding: 0; border: 1px solid transparent; border-radius: 8px; color: var(--text-secondary); background: transparent; cursor: pointer; transition: border-color .16s ease, background .16s ease, color .16s ease; }
.courier-more-button:hover, .courier-more-button[aria-expanded="true"] { border-color: var(--line); color: var(--ink); background: var(--paper-soft); }
.courier-more-button:focus-visible { outline: 2px solid var(--brand-line); outline-offset: 1px; }
.courier-more-button svg { width: 17px; height: 17px; fill: currentColor; }
.courier-more-menu { position: absolute; top: calc(100% + 5px); right: 0; z-index: 20; display: grid; width: 195px; padding: 5px; border: 1px solid var(--line); border-radius: 10px; background: var(--paper); box-shadow: 0 10px 28px var(--shadow-color); }
.courier-more-menu[hidden] { display: none; }
.courier-more-menu button { min-height: 33px; padding: 0 9px; border: 0; border-radius: 7px; color: var(--ink); background: transparent; font: inherit; font-size: 11px; text-align: left; cursor: pointer; }
.courier-more-menu button:hover, .courier-more-menu button:focus-visible { outline: none; background: var(--paper-soft); }
.courier-more-divider { height: 1px; margin: 4px 2px; background: var(--line); }
.courier-team-copy { display: grid; flex: 1; min-width: 0; gap: 4px; }
.courier-team-copy strong { overflow: hidden; color: var(--ink); font-size: 14px; text-overflow: ellipsis; white-space: nowrap; }
.courier-team-copy small { overflow: hidden; color: var(--muted); font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.courier-team-capacity { display: flex; align-items: center; justify-content: space-between; min-height: 39px; padding: 0 10px; border-radius: 9px; color: var(--ink); background: var(--paper-soft); font-size: 11px; }
.courier-team-capacity strong { color: var(--ink); font-size: 13px; }
.courier-team-card .route-courier-toggle { justify-self: stretch; min-height: 36px; }
.courier-password-content { padding: 22px; }
.courier-password-content > p { margin: 0; color: var(--text-secondary); font-size: 12px; line-height: 1.6; }
.courier-team-note { padding: 0 16px 14px; }
.route-courier-empty { justify-items: start; grid-column: 1 / -1; padding: 11px 2px 3px; }
.route-courier-empty strong { font-size: 12px; }
.route-courier-empty span { font-size: 11px; }
.route-courier-manage { min-height: 32px; margin-top: 3px; padding: 0 10px; border: 1px solid var(--brand-line); border-radius: 8px; color: var(--brand-dark); background: var(--paper); font: inherit; font-size: 11px; font-weight: 750; cursor: pointer; }
.route-courier-manage:hover { background: var(--brand-soft); }

.route-courier-count { flex: 0 0 auto; padding: 6px 9px; border: 1px solid var(--green-line); border-radius: 999px; color: var(--green-dark); background: var(--green-soft); font-size: 10px; font-weight: 800; white-space: nowrap; }
.route-courier-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 7px; }
.route-courier-card { display: grid; min-width: 0; gap: 10px; padding: 10px; border: 1px solid var(--line); border-radius: 11px; background: var(--paper); transition: border-color .16s ease, box-shadow .16s ease, background .16s ease; }
.route-courier-card:hover { border-color: var(--brand-line); box-shadow: 0 4px 12px var(--brand-ring); }
.route-courier-card.is-selected { border-color: var(--brand-line); background: var(--brand-soft); box-shadow: inset 0 0 0 1px var(--brand), 0 3px 10px var(--brand-ring); }
.route-courier-card.is-offline-card { background: var(--paper-soft); }
.route-courier-main { display: flex; align-items: center; gap: 9px; min-width: 0; }
.route-courier-avatar { position: relative; display: grid; flex: 0 0 40px; width: 40px; height: 40px; place-items: center; border-radius: 12px; color: var(--paper); background: var(--brand); font-size: 12px; font-weight: 800; }
.route-courier-avatar.avatar-2 { background: var(--info-dark); }
.route-courier-avatar.avatar-3 { background: var(--green); }
.route-courier-avatar.is-custom-accent { background: var(--courier-avatar-color); }
.route-courier-avatar i { position: absolute; right: -2px; bottom: -2px; width: 11px; height: 11px; border: 2px solid var(--paper); border-radius: 50%; background: var(--green); }
.courier-team-card.is-offline-card .route-courier-avatar i { background: var(--page); }
.route-courier-card.is-offline-card .route-courier-avatar i { background: var(--page); }
.route-courier-copy { display: grid; flex: 1; min-width: 0; gap: 3px; }
.route-courier-copy strong { overflow: hidden; color: var(--ink); font-size: 13px; text-overflow: ellipsis; white-space: nowrap; }
.route-courier-copy small { overflow: hidden; color: var(--muted); font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.courier-status { display: inline-flex; align-items: center; gap: 5px; flex: 0 0 auto; padding: 5px 7px; border-radius: 7px; font-size: 10px; font-weight: 800; white-space: nowrap; }
.courier-status i { width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.courier-status.is-free { color: var(--green-dark); background: var(--green-soft); }
.courier-status.is-driving { color: var(--info-dark); background: var(--info-soft); }
.courier-status.is-assigned { color: #A84B14; background: #FFF1E8; }
.courier-status.is-offline { color: var(--offline); background: var(--offline-soft); }
.route-courier-actions { display: flex; align-items: center; gap: 6px; }
.route-courier-choose, .route-courier-toggle { min-height: 32px; padding: 0 9px; border: 1px solid var(--line); border-radius: 8px; color: var(--ink); background: var(--paper); font: inherit; font-size: 10px; font-weight: 800; cursor: pointer; transition: border-color .16s ease, color .16s ease, background .16s ease, transform .16s ease; }
.route-courier-choose { flex: 1; border-color: var(--brand); color: var(--paper); background: var(--brand); }
.route-courier-choose:hover:not(:disabled) { border-color: var(--brand-hover); background: var(--brand-hover); }
.route-courier-choose[aria-pressed="true"] { border-color: var(--brand); background: var(--brand); }
.route-courier-choose:disabled { border-color: var(--line); color: var(--text-secondary); background: var(--paper-soft); cursor: not-allowed; }
.route-courier-toggle:hover:not(:disabled) { border-color: var(--brand-line); color: var(--brand-dark); background: var(--brand-soft); }
.route-courier-toggle:disabled { color: var(--text-secondary); background: var(--paper-soft); cursor: not-allowed; }
.route-courier-choose:active:not(:disabled), .route-courier-toggle:active:not(:disabled) { transform: scale(.98); }
.route-courier-choose:focus-visible, .route-courier-toggle:focus-visible { outline: 3px solid var(--brand-ring); outline-offset: 2px; }
.route-courier-empty { display: grid; gap: 4px; padding: 14px 16px; color: var(--muted); }
.route-courier-empty strong { color: var(--ink); font-size: 12px; }
.route-courier-empty span { font-size: 11px; }

@media (max-width: 1160px) {
  .route-workspace-grid { grid-template-columns: 1fr; }
  .route-summary-card { flex-wrap: wrap; }
  .route-summary-card em { width: 100%; margin-left: 44px; text-align: left; }
  .courier-team-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 760px) {
  .page-heading { flex-wrap: wrap; gap: 12px; }
  .courier-heading-actions { width: 100%; flex-wrap: wrap; justify-content: flex-start; }
  .courier-heading-actions .courier-period-control { flex: 1 1 220px; }
  .courier-heading-actions .courier-period-trigger { width: 100%; max-width: none; }
  .courier-heading-actions .courier-add-trigger { flex: 0 0 auto; }
  .routes-screen { gap: 9px; padding-top: 12px; }
  .route-summary-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 7px; }
  .route-summary-card { min-height: 75px; padding: 9px; gap: 8px; }
  .route-summary-icon { flex-basis: 30px; width: 30px; height: 30px; }
  .route-summary-card em { margin-left: 38px; font-size: 10px; }
  .route-workspace-grid { gap: 9px; }
  .route-panel-heading, .route-activity-heading { padding-right: 12px; padding-left: 12px; }
  .route-planner-controls { padding-right: 11px; padding-left: 11px; }
  .route-queue-heading { padding-right: 11px; padding-left: 11px; }
  .route-order-list { padding-right: 9px; padding-left: 9px; }
  .route-prep-disclosure { margin-right: 9px; margin-left: 9px; }
  .route-planner-footer { padding-right: 11px; padding-left: 11px; }
  .route-card-list { padding: 8px; }
  .route-courier-selector { margin-right: 9px; margin-left: 9px; padding: 9px; }
  .route-courier-grid { grid-template-columns: 1fr; gap: 7px; }
  .courier-route-report { margin: 10px 10px 0; padding: 11px; }
  .courier-route-report-heading { align-items: stretch; flex-direction: column; gap: 10px; }
  .courier-route-report-heading .courier-period-trigger { width: 100%; max-width: none; }
  .courier-period-picker { position: fixed; top: 80px; right: 10px; left: 10px; grid-template-columns: minmax(0, 1fr); width: auto; max-height: calc(100dvh - 92px); overflow-y: auto; }
  .courier-period-presets { max-height: 150px; border-right: 0; border-bottom: 1px solid var(--line); }
  #courier-period-recent, #courier-period-preset-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .courier-period-edit { grid-template-columns: 7px auto minmax(0, 1fr); }
  .courier-period-edit select { grid-column: 3; }
  .courier-date-field { grid-column: span 1; }
  .courier-period-footer { align-items: flex-start; flex-direction: column; }
  .courier-route-report-totals { grid-template-columns: 1fr; }
  .courier-team-summary { grid-template-columns: 1fr; padding-right: 10px; padding-left: 10px; }
  .courier-team-grid { grid-template-columns: 1fr; padding-right: 10px; padding-left: 10px; }
}

@media (max-width: 480px) {
  .route-planner-controls { grid-template-columns: 1fr; }
  .route-order-option { grid-template-columns: 17px 38px minmax(0, 1fr); gap: 7px; padding: 8px; }
  .route-order-number { width: 36px; }
  .route-order-meta { grid-column: 3; display: flex; flex-wrap: wrap; justify-content: flex-start; justify-items: start; gap: 8px; padding-top: 2px; }
  .route-order-copy > span { display: none; }
  .route-stop { grid-template-columns: 24px minmax(0, 1fr); }
  .route-stop-side { grid-column: 2; grid-template-columns: auto auto; justify-content: start; justify-items: start; align-items: center; gap: 6px 9px; }
  .route-stop-action { grid-column: 1 / -1; }
  .route-card-facts { gap: 8px; }
  .route-card-facts .route-capacity-copy { margin-left: 0; }
}

.routes-screen { gap: 12px; padding-top: 14px; }
.route-command-bar { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.route-kpi-strip { display: grid; grid-template-columns: repeat(2, minmax(190px, 1fr)); gap: 9px; min-width: 0; flex: 1; }
.route-kpi-card { display: flex; align-items: center; gap: 11px; min-height: 72px; padding: 10px 13px; border: 1px solid var(--line); border-radius: 13px; background: var(--paper); box-shadow: 0 2px 8px var(--shadow-color); }
.route-kpi-card > span:last-child { display: grid; gap: 3px; }
.route-kpi-card small { color: var(--text-secondary); font-size: 11px; font-weight: 650; }
.route-kpi-card strong { color: var(--ink-pure); font-size: 22px; line-height: 1; }
.route-kpi-icon { display: grid; flex: 0 0 34px; width: 34px; height: 34px; place-items: center; border-radius: 10px; }
.route-kpi-icon svg { width: 17px; height: 17px; }
.route-kpi-icon.is-on-road { color: var(--info-dark); background: var(--info-soft); }
.route-kpi-icon.is-preparing { color: var(--brand-dark); background: var(--brand-soft); }
.route-recalculate-button { display: inline-flex; flex: 0 0 auto; align-items: center; justify-content: center; gap: 8px; min-width: 180px; min-height: 46px; padding: 0 16px; border: 1px solid var(--brand); border-radius: 10px; color: #fff; background: var(--brand); font-size: 12px; font-weight: 800; white-space: nowrap; cursor: pointer; }
.route-recalculate-button:hover { background: var(--brand-hover); }
.route-recalculate-button svg { width: 17px; height: 17px; }
.route-board-panel { min-width: 0; overflow: visible; border: 1px solid var(--line); border-radius: 15px; background: var(--paper); box-shadow: 0 3px 12px var(--shadow-color); }
.route-columns { display: grid; grid-template-columns: repeat(auto-fit, minmax(245px, 1fr)); align-items: start; gap: 11px; padding: 12px; }
.route-column { position: relative; min-width: 0; overflow: visible; border: 1px solid var(--line); border-radius: 13px; background: var(--paper); }
.route-column-heading { position: relative; display: flex; align-items: center; gap: 9px; min-height: 69px; padding: 9px 10px; border-bottom: 1px solid var(--line); }
.route-column-heading.has-notification { padding-left: 50px; border-bottom-color: var(--danger); }
.route-driver-avatar { display: grid; flex: 0 0 36px; width: 36px; height: 36px; place-items: center; border-radius: 50%; color: #fff; background: var(--brand); font-size: 11px; font-weight: 800; }
.route-driver-copy { display: grid; flex: 1; min-width: 0; gap: 3px; }
.route-driver-copy strong { overflow: hidden; color: var(--ink); font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.route-driver-copy small { color: var(--muted); font-size: 10px; }
.route-courier-state { display: inline-flex; align-items: center; gap: 5px; flex: 0 0 auto; padding: 5px 7px; border-radius: 999px; font-size: 9px; font-weight: 800; white-space: nowrap; }
.route-courier-state i { width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.route-courier-state.is-free { color: var(--green-dark); background: var(--green-soft); }
.route-courier-state.is-assigned { color: #A84B14; background: #FFF1E8; }
.route-courier-state.is-driving { color: var(--info-dark); background: var(--info-soft); }
.route-alert-wrap { position: absolute; z-index: 5; top: 13px; left: 10px; }
.route-alert-bell { position: relative; display: grid; width: 29px; height: 29px; place-items: center; padding: 0; border: 0; border-radius: 50%; color: #fff; background: var(--danger); box-shadow: 0 2px 8px rgb(217 21 37 / 24%); cursor: pointer; }
.route-alert-bell svg { width: 15px; height: 15px; }
.route-alert-bell > span { position: absolute; top: -4px; right: -5px; display: grid; min-width: 15px; height: 15px; place-items: center; padding: 0 3px; border: 1px solid #fff; border-radius: 99px; color: #fff; background: #A90012; font-size: 8px; font-weight: 900; }
.route-alert-bell:focus-visible { outline: 3px solid rgb(217 21 37 / 26%); outline-offset: 2px; }
.route-alert-popover { position: absolute; top: 36px; left: 0; z-index: 8; width: min(315px, calc(100vw - 36px)); padding: 11px; border: 1px solid var(--line); border-radius: 12px; background: var(--paper); box-shadow: 0 14px 35px rgb(0 0 0 / 18%); }
.route-alert-popover > header { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 8px; color: var(--ink); font-size: 12px; }
.route-alert-popover > header button { width: 24px; height: 24px; border: 0; border-radius: 6px; color: var(--muted); background: var(--paper-soft); font-size: 17px; cursor: pointer; }
.route-alert-order { display: grid; gap: 5px; padding: 9px 0; border-top: 1px solid var(--line); }
.route-alert-order-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 8px; }
.route-alert-order-heading strong { color: var(--ink); font-size: 11px; }
.route-alert-order-heading span, .route-alert-order > small { color: var(--muted); font-size: 9px; }
.route-alert-order p { margin: 0; color: var(--text-secondary); font-size: 10px; }
.route-demo-metric { display: grid; gap: 2px; padding: 7px 8px; border-radius: 8px; color: var(--text-secondary); background: var(--paper-soft); }
.route-demo-metric span { color: var(--muted); font-size: 8px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; }
.route-demo-metric strong { color: var(--ink); font-size: 10px; }
.route-alert-actions { display: flex; gap: 6px; margin-top: 3px; }
.route-alert-actions button { flex: 1; min-height: 31px; padding: 0 8px; border: 1px solid var(--line); border-radius: 7px; color: var(--ink); background: var(--paper); font-size: 10px; font-weight: 800; cursor: pointer; }
.route-alert-actions button:first-child { border-color: var(--brand); color: #fff; background: var(--brand); }
.route-alert-actions button:last-child { color: var(--danger); }
.route-column-body { padding: 10px; }
.route-trip { overflow: hidden; border: 1px solid var(--line); border-radius: 10px; background: var(--paper); }
.route-return-review { margin-top: 8px; overflow: hidden; border: 1px solid var(--line); border-radius: 10px; background: var(--paper); }
.route-return-review > header { padding: 9px 10px; border-bottom: 1px solid var(--line); color: var(--ink); background: var(--paper-soft); font-size: 11px; }
.route-return-review .route-stops { padding: 1px 10px; }
.route-trip-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 7px; padding: 9px 10px; border-bottom: 1px solid var(--line); background: var(--paper-soft); }
.route-trip-heading > div { display: grid; gap: 3px; }
.route-trip-heading > div > span { color: var(--muted); font-size: 8px; font-weight: 800; letter-spacing: .08em; }
.route-trip-heading > div > strong { color: var(--ink); font-size: 11px; }
.route-trip-status { max-width: 140px; padding: 5px 7px; border-radius: 999px; font-size: 8px; font-weight: 800; text-align: center; }
.route-trip-status.is-ready, .route-trip-status.is-complete { color: var(--green-dark); background: var(--green-soft); }
.route-trip-status.is-waiting, .route-trip-status.is-payment-pending { color: #fff; background: var(--brand); }
.route-trip-status.is-on-road { color: var(--info-dark); background: var(--info-soft); }
.route-trip .route-stops { padding: 1px 10px; }
.route-trip .route-stop { grid-template-columns: 24px minmax(0, 1fr); gap: 7px; padding: 9px 0; }
.route-trip .route-stop-side { grid-column: 2; display: flex; align-items: center; justify-items: start; flex-wrap: wrap; gap: 5px 8px; white-space: normal; }
.route-trip .route-stop-copy strong { font-size: 11px; }
.route-trip .route-stop-copy small, .route-trip .route-stop-copy > span { font-size: 10px; }
.route-trip .route-stop-copy .route-stop-order-number { color: var(--ink-pure); font-size: 19px; font-weight: 850; letter-spacing: -.045em; line-height: 1; }
.route-trip .route-stop-copy .route-stop-customer { color: var(--ink); font-size: 11px; font-weight: 750; }
.route-trip .route-stop-copy .route-stop-items { color: var(--muted); font-size: 10px; font-weight: 500; }
.route-trip .route-stop-status { font-size: 9px; }
.route-trip .route-stop-action { min-height: 27px; margin-left: auto; padding: 0 8px; font-size: 9px; }
.route-trip-footer { display: flex; justify-content: flex-end; padding: 9px 10px; border-top: 1px solid var(--line); background: var(--paper-soft); }
.route-start-button { min-height: 33px; padding: 0 10px; border: 0; border-radius: 8px; color: #fff; background: var(--brand); font-size: 10px; font-weight: 800; cursor: pointer; }
.route-start-button:disabled { color: var(--muted); background: var(--page); cursor: not-allowed; }
.route-on-road-note { color: var(--text-secondary); font-size: 9px; font-weight: 650; }
.route-column-empty { display: grid; justify-items: center; gap: 7px; min-height: 205px; padding: 23px 15px; color: var(--muted); text-align: center; }
.route-column-empty > span { display: grid; width: 36px; height: 36px; place-items: center; border-radius: 11px; color: var(--brand-dark); background: var(--brand-soft); }
.route-column-empty svg { width: 20px; height: 20px; }
.route-column-empty strong { color: var(--ink); font-size: 11px; }
.route-column-empty small { max-width: 220px; font-size: 10px; line-height: 1.4; }
.route-last-complete { padding: 8px 10px; border-top: 1px solid var(--line); color: var(--muted); font-size: 9px; }
.route-board-empty { grid-column: 1 / -1; display: grid; justify-items: center; gap: 5px; min-height: 160px; place-content: center; color: var(--muted); text-align: center; }
.route-board-empty strong { color: var(--ink); font-size: 13px; }
.route-board-empty span { font-size: 11px; }
.route-unassigned-panel { padding: 12px 14px; border: 1px solid var(--warning-line); border-radius: 12px; background: var(--paper); }
.route-unassigned-panel[hidden] { display: none; }
.route-unassigned-panel > header { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 8px; }
.route-unassigned-panel h3 { margin: 0; color: var(--ink); font-size: 12px; }
.route-unassigned-panel p { margin: 3px 0 0; color: var(--muted); font-size: 10px; }
.route-unassigned-panel > header > span { display: grid; min-width: 24px; height: 24px; place-items: center; border-radius: 99px; color: var(--ink); background: var(--warning-soft); font-size: 10px; font-weight: 800; }
.route-unassigned-order { display: grid; grid-template-columns: minmax(130px, 1fr) minmax(160px, 2fr) auto; align-items: center; gap: 9px; padding: 8px 0; border-top: 1px solid var(--line); font-size: 10px; }
.route-unassigned-order > span { color: var(--muted); }
.route-demo-note { margin-top: 0; }

@media (max-width: 760px) {
  body[data-active-section="Rotas"] .workspace { padding: 14px 10px; }
  .route-command-bar { align-items: stretch; flex-direction: column; }
  .route-kpi-strip { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .route-recalculate-button { align-self: stretch; min-height: 40px; }
  .route-columns { grid-template-columns: 1fr; padding: 9px; }
  .route-alert-popover { position: fixed; top: 118px; left: 17px; width: min(340px, calc(100vw - 34px)); }
  .route-unassigned-order { grid-template-columns: 1fr auto; }
  .route-unassigned-order > span { grid-column: 1 / -1; grid-row: 2; }
}

/* Relatórios: leitura direta, com poucos agrupamentos e menos molduras. */
.reports-screen { gap: 11px; padding-top: 10px; }
.reports-filter-panel, .report-summary-panel, .report-data-panel, .report-overview-panel { border-color: var(--line); border-radius: 12px; box-shadow: none; }
.reports-filter-panel { padding: 10px 12px; }
.reports-filter-bottom { margin-top: 8px; padding-top: 8px; }
.report-summary-panel { overflow: hidden; padding: 0 14px; }
.report-kpi-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0; }
.report-kpi-card { display: flex; flex-direction: column; justify-content: center; gap: 5px; min-height: 80px; padding: 11px 14px; border: 0; border-right: 1px solid var(--line); border-radius: 0; background: transparent; box-shadow: none; }
.report-kpi-card:first-child { padding-left: 0; }
.report-kpi-card:last-child { padding-right: 0; border-right: 0; }
.report-kpi-label { font-size: 10px; }
.report-kpi-card > strong { font-size: 23px; }
.report-kpi-card > small { font-size: 9px; }
.report-kpi-sales > strong, .report-kpi-pending > strong { color: var(--brand-dark); }
.report-kpi-delivery > strong, .report-kpi-received > strong { color: var(--ink); }
.report-data-panel, .report-overview-panel { padding: 12px 14px; }
.report-panel-heading h2 { font-size: 13px; }
.report-panel-heading p { font-size: 9px; }
.report-breakdown-list, .report-product-list { margin-top: 6px; }
.report-product-row, .report-breakdown-row { min-height: 34px; padding: 5px 0; }
.report-overview-columns { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.report-overview-group h3 { margin: 10px 0 0; color: var(--text-secondary); font-size: 9px; font-weight: 750; letter-spacing: .04em; text-transform: uppercase; }
.report-overview-group .report-breakdown-list { margin-top: 3px; }
.report-demo-note { margin-top: 7px; font-size: 8px; }

@media (max-width: 760px) {
  .report-summary-panel { padding: 0 10px; }
  .report-kpi-grid { grid-template-columns: minmax(0, 1fr); }
  .report-kpi-card { min-height: 70px; padding: 9px 8px; border-bottom: 1px solid var(--line); }
  .report-kpi-card { border-right: 0; }
  .report-kpi-card:last-child { border-bottom: 0; }
  .report-overview-columns { grid-template-columns: minmax(0, 1fr); gap: 6px; }
  .report-overview-group h3 { margin-top: 7px; }
}

/* Ajustes: categorias simples à esquerda e um formulário por vez. */
.settings-screen { display: grid; flex: 1; grid-template-columns: 190px minmax(0, 1fr); align-content: start; gap: 16px; min-width: 0; padding-top: 15px; }
.settings-nav { display: grid; align-content: start; gap: 3px; padding: 5px; border: 1px solid var(--line); border-radius: 12px; background: var(--paper); }
.settings-nav-item { display: flex; align-items: center; width: 100%; min-height: 37px; padding: 0 10px; border: 0; border-radius: 8px; color: var(--text-secondary); background: transparent; text-align: left; font: inherit; font-size: 11px; font-weight: 650; cursor: pointer; }
.settings-nav-item:hover { color: var(--ink); background: var(--paper-soft); }
.settings-nav-item.is-active { color: var(--brand-dark); background: var(--brand-soft); }
.settings-nav-item:focus-visible, .settings-secondary-button:focus-visible, .settings-savebar button:focus-visible { outline: 3px solid var(--brand-ring); outline-offset: 2px; }
.settings-content { display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.settings-panel { min-height: 270px; padding: 17px 18px; border: 1px solid var(--line); border-radius: 12px; background: var(--paper); }
.settings-panel[hidden] { display: none !important; }
.settings-panel-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin-bottom: 17px; }
.settings-panel-heading h2 { margin: 0; color: var(--ink); font-size: 14px; font-weight: 750; letter-spacing: -.015em; }
.settings-panel-heading p { margin: 4px 0 0; color: var(--text-secondary); font-size: 10px; line-height: 1.45; }
.settings-fields { display: grid; gap: 13px; min-width: 0; }
.settings-fields-two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.settings-fields label { display: grid; align-content: start; gap: 6px; min-width: 0; color: var(--ink); font-size: 10px; font-weight: 700; }
.settings-fields input, .settings-fields select { width: 100%; min-width: 0; min-height: 37px; padding: 0 10px; border: 1px solid var(--line); border-radius: 8px; outline: 0; color: var(--ink); background: var(--paper); font: inherit; font-size: 11px; font-weight: 500; }
.settings-fields input:focus, .settings-fields select:focus { border-color: var(--brand-line); box-shadow: 0 0 0 3px var(--brand-ring); }
.settings-field-wide { grid-column: 1 / -1; }
.settings-toggle-row { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 61px; padding: 11px 0; border-bottom: 1px solid var(--line); cursor: pointer; }
.settings-toggle-row > span { display: grid; gap: 4px; }
.settings-toggle-row strong { color: var(--ink); font-size: 11px; font-weight: 700; }
.settings-toggle-row small, .settings-field-hint { color: var(--text-secondary); font-size: 10px; line-height: 1.4; }
.settings-toggle-row input { flex: 0 0 auto; width: 17px; height: 17px; margin: 0 2px 0 0; accent-color: var(--brand); cursor: pointer; }
.settings-toggle-row input[role="switch"] { appearance: none; width: 48px; height: 26px; margin: 0 1px 0 0; border: 0; border-radius: 999px; background-color: var(--line); background-image: radial-gradient(circle, #fff 0 10px, transparent 10.5px); background-repeat: no-repeat; background-position: 2px center; background-size: 22px 22px; cursor: pointer; transition: background-color .16s ease, background-position .16s ease; }
.settings-toggle-row input[role="switch"]:checked { background-color: var(--brand); background-position: 24px center; }
.settings-toggle-row input[role="switch"]:focus-visible { outline: 3px solid var(--brand-ring); outline-offset: 2px; }
.settings-sound-row { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 61px; padding: 11px 0; border-bottom: 1px solid var(--line); }
.settings-sound-row > span { display: grid; gap: 4px; }
.settings-sound-row strong { color: var(--ink); font-size: 11px; font-weight: 700; }
.settings-sound-row small { color: var(--text-secondary); font-size: 10px; line-height: 1.4; }
.settings-sound-row select { width: min(210px, 44%); min-height: 38px; padding: 0 10px; border: 1px solid var(--line); border-radius: 8px; outline: 0; color: var(--ink); background: var(--paper); font: inherit; font-size: 11px; }
.settings-sound-row select:focus { border-color: var(--brand); box-shadow: 0 0 0 3px var(--brand-ring); }
.settings-volume-row { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 61px; padding: 11px 0; border-bottom: 1px solid var(--line); }
.settings-volume-row > span { display: grid; gap: 4px; }
.settings-volume-row strong { color: var(--ink); font-size: 11px; font-weight: 700; }
.settings-volume-row small { color: var(--text-secondary); font-size: 10px; line-height: 1.4; }
.settings-volume-controls { display: flex; flex: 0 0 auto; align-items: center; gap: 14px; }
.settings-volume-controls input[type="range"] { width: clamp(110px, 16vw, 190px); height: 22px; margin: 0; accent-color: var(--brand); cursor: pointer; }
.settings-volume-controls input[type="range"]:focus-visible { outline: 3px solid var(--brand-ring); outline-offset: 2px; }
.settings-sound-preview { display: grid; width: 32px; height: 32px; flex: 0 0 32px; place-items: center; padding: 0; border: 1px solid var(--line); border-radius: 50%; color: var(--brand); background: var(--paper); cursor: pointer; }
.settings-sound-preview:hover { border-color: var(--brand); background: var(--brand-soft); }
.settings-sound-preview:focus-visible { outline: 3px solid var(--brand-ring); outline-offset: 2px; }
.settings-sound-preview svg { width: 14px; height: 14px; fill: currentColor; }
.settings-inline-status { display: flex; align-items: center; gap: 10px; margin-bottom: 4px; padding: 10px 11px; border: 1px solid var(--line); border-radius: 9px; background: var(--paper-soft); }
.settings-inline-status > div, .settings-provider-copy { display: grid; gap: 3px; }
.settings-inline-status strong, .settings-provider-copy strong { color: var(--ink); font-size: 11px; }
.settings-inline-status span:last-child, .settings-provider-copy span { color: var(--text-secondary); font-size: 10px; }
.settings-status-dot { width: 8px; height: 8px; flex: 0 0 8px; border-radius: 50%; background: var(--muted); }
.settings-status-dot.is-on { background: var(--green); }
.settings-fee-card { display: flex; align-items: center; justify-content: space-between; gap: 18px; margin-top: 13px; padding: 12px; border: 1px solid var(--line); border-radius: 9px; }
.settings-fee-card > div:first-child { display: grid; gap: 4px; }
.settings-fee-card strong { color: var(--ink); font-size: 11px; }
.settings-fee-card > div:first-child span { color: var(--text-secondary); font-size: 9px; line-height: 1.4; }
.settings-fee-fields { display: flex; gap: 10px; }
.settings-fee-fields label { display: grid; gap: 5px; color: var(--text-secondary); font-size: 9px; font-weight: 700; }
.settings-currency-field { display: flex; align-items: center; min-height: 34px; border: 1px solid var(--line); border-radius: 7px; color: var(--text-secondary); background: var(--paper); font-size: 10px; }
.settings-currency-field > span { padding-left: 8px; }
.settings-currency-field input { width: 64px; min-height: 30px; padding: 0 6px; border: 0; box-shadow: none !important; font-size: 11px; }
.settings-provider-card { display: flex; align-items: center; gap: 11px; padding: 12px; border: 1px solid var(--line); border-radius: 9px; }
.settings-provider-mark { display: grid; width: 34px; height: 34px; place-items: center; border-radius: 10px; color: #fff; background: #3179d5; font-size: 11px; font-weight: 800; }
.settings-provider-copy { flex: 1; min-width: 0; }
.settings-secondary-button { min-height: 34px; padding: 0 11px; border: 1px solid var(--line); border-radius: 8px; color: var(--ink); background: var(--paper); font: inherit; font-size: 10px; font-weight: 700; white-space: nowrap; cursor: pointer; }
.settings-secondary-button:hover { border-color: var(--brand-line); background: var(--paper-soft); }
.local-password-dialog .catalog-save-button { border-color: var(--brand); color: #fff; background: var(--brand); }
.local-password-dialog .catalog-save-button:hover { background: #E85E15; }
.settings-credential-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 16px; padding: 11px; border: 1px solid var(--line); border-radius: 9px; }
.settings-credential-row > div { display: grid; gap: 4px; }
.settings-credential-row strong { color: var(--ink); font-size: 11px; }
.settings-credential-row small { color: var(--text-secondary); font-size: 10px; }
.settings-info-row { display: flex; align-items: flex-start; gap: 9px; margin-top: 14px; }
.settings-info-icon { display: grid; width: 17px; height: 17px; flex: 0 0 17px; place-items: center; border: 1px solid var(--line); border-radius: 50%; color: var(--text-secondary); font-size: 10px; font-weight: 700; }
.settings-info-row p { margin: 0; color: var(--text-secondary); font-size: 10px; line-height: 1.5; }
.settings-setup-note { margin-top: 13px; padding: 9px 10px; border-radius: 8px; color: var(--text-secondary); background: var(--paper-soft); font-size: 9px; line-height: 1.5; }
.settings-order-delay { grid-template-columns: minmax(200px, .6fr) minmax(0, 1fr); align-items: end; padding: 14px 0; border-bottom: 1px solid var(--line); }
.settings-input-suffix { display: flex; align-items: center; gap: 8px; color: var(--text-secondary); font-size: 10px; font-weight: 500; }
.settings-order-delay .settings-input-suffix input { max-width: 100px; }
.settings-field-hint { padding-bottom: 10px; }
.settings-printer-actions { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 17px; }
.settings-printer-status { display: inline-flex; align-items: center; gap: 7px; color: var(--text-secondary); font-size: 10px; }
.settings-printer-picker { display: grid; grid-template-columns: 38px minmax(0, 1fr); align-items: center; gap: 11px; padding: 13px; border: 1px solid var(--line); border-radius: 10px; }
.settings-printer-icon { display: grid; width: 36px; height: 36px; place-items: center; border-radius: 9px; color: var(--text-secondary); background: var(--paper-soft); }
.settings-printer-icon svg { width: 19px; height: 19px; fill: none; stroke: currentColor; stroke-linecap: round; stroke-linejoin: round; stroke-width: 1.7; }
.settings-printer-picker > div { min-width: 0; }
.settings-printer-picker strong { color: var(--ink); font-size: 11px; }
.settings-printer-picker p { margin: 4px 0 0; color: var(--text-secondary); font-size: 10px; line-height: 1.45; }
.settings-print-trigger { min-height: 36px; border-radius: 8px; font-size: 10px; }
.settings-printer-options { display: grid; grid-template-columns: 120px auto; justify-content: start; align-items: end; gap: 10px; margin-top: 14px; }
.settings-printer-options > label { display: grid; gap: 5px; min-width: 0; color: var(--ink); font-size: 10px; font-weight: 700; }
.settings-printer-options select { width: 100%; min-width: 0; min-height: 36px; padding: 0 9px; border: 1px solid var(--line); border-radius: 8px; outline: 0; color: var(--ink); background: var(--paper); font: inherit; font-size: 10px; }
.settings-printer-options select:focus { border-color: var(--brand-line); box-shadow: 0 0 0 3px var(--brand-ring); }
.settings-printer-options select:disabled { color: var(--text-secondary); background: var(--paper-soft); }
.settings-print-trigger { min-height: 36px; border-radius: 8px; font-size: 10px; white-space: nowrap; }
.settings-print-trigger:disabled { opacity: .55; cursor: not-allowed; }
.settings-users-form { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); align-items: end; gap: 10px; }
.settings-users-form label { display: grid; gap: 6px; min-width: 0; color: var(--ink); font-size: 10px; font-weight: 700; }
.settings-users-form input, .settings-users-form select { width: 100%; min-width: 0; min-height: 37px; padding: 0 10px; border: 1px solid var(--line); border-radius: 8px; outline: 0; color: var(--ink); background: var(--paper); font: inherit; font-size: 11px; font-weight: 500; }
.settings-users-form input:focus, .settings-users-form select:focus { border-color: var(--brand-line); box-shadow: 0 0 0 3px var(--brand-ring); }
.settings-users-form button { min-height: 37px; padding: 0 13px; white-space: nowrap; }
.settings-users-note { margin: 12px 0 0; color: var(--text-secondary); font-size: 9px; line-height: 1.45; }
.settings-users-list { display: grid; margin-top: 15px; border-top: 1px solid var(--line); }
.settings-users-empty { padding: 18px 0; color: var(--text-secondary); font-size: 10px; }
.settings-user-row { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) auto; align-items: center; gap: 12px; padding: 11px 0; border-bottom: 1px solid var(--line); }
.settings-user-identity { display: grid; min-width: 0; gap: 3px; }
.settings-user-identity strong { overflow: hidden; color: var(--ink); font-size: 10px; text-overflow: ellipsis; white-space: nowrap; }
.settings-user-identity small { overflow: hidden; color: var(--text-secondary); font-size: 9px; text-overflow: ellipsis; white-space: nowrap; }
.settings-user-role { justify-self: start; padding: 4px 8px; border-radius: 999px; color: var(--brand-dark); background: var(--brand-soft); font-size: 9px; font-weight: 700; }
.settings-user-role.is-courier { color: var(--green-dark, #147548); background: var(--green-soft); }
.settings-savebar { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 49px; padding: 4px 2px; }
.settings-savebar > span { color: var(--text-secondary); font-size: 10px; }
.settings-savebar .customer-primary-button { min-height: 36px; border-radius: 8px; font-size: 10px; }

@media (max-width: 760px) {
  .settings-screen { grid-template-columns: minmax(0, 1fr); gap: 10px; padding-top: 12px; }
  .settings-nav { display: flex; overflow-x: auto; gap: 3px; padding: 4px; scrollbar-width: thin; }
  .settings-nav-item { flex: 0 0 auto; width: auto; min-height: 34px; padding: 0 10px; white-space: nowrap; }
  .settings-panel { min-height: 0; padding: 14px 12px; }
  .settings-fee-card { align-items: stretch; flex-direction: column; gap: 12px; }
  .settings-fee-fields { flex-wrap: wrap; }
  .settings-order-delay { grid-template-columns: minmax(0, 1fr); gap: 7px; }
  .settings-field-hint { padding: 0; }
  .settings-sound-row { align-items: flex-start; flex-direction: column; }
  .settings-sound-row select { width: 100%; }
  .settings-volume-row { align-items: flex-start; flex-direction: column; }
  .settings-volume-controls { width: 100%; gap: 12px; }
  .settings-volume-controls input[type="range"] { width: auto; flex: 1; }
  .settings-printer-picker { grid-template-columns: 36px minmax(0, 1fr); }
  .settings-printer-options { grid-template-columns: minmax(0, 1fr); }
  .settings-printer-options > label { width: 100%; }
  .settings-printer-options .settings-print-trigger { width: 100%; }
  .settings-users-form { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .settings-users-form button { width: 100%; }
  .settings-user-row { grid-template-columns: minmax(0, 1fr) auto; }
  .settings-user-role { grid-column: 2; grid-row: 1; }
  .settings-user-identity { grid-column: 1; grid-row: 1; }
}

@media (max-width: 440px) {
  .location-switcher small { display: none; }
  .location-switcher strong { font-size: 10px; }
  .header-popover { width: min(286px, calc(100vw - 20px)); }
  .settings-fields-two { grid-template-columns: minmax(0, 1fr); }
  .settings-field-wide { grid-column: auto; }
  .settings-provider-card { flex-wrap: wrap; }
  .settings-provider-copy { flex-basis: calc(100% - 50px); }
  .settings-provider-card .settings-secondary-button { width: 100%; }
  .settings-credential-row { align-items: flex-start; flex-direction: column; }
  .settings-credential-row .settings-secondary-button { width: 100%; }
  .settings-users-form { grid-template-columns: minmax(0, 1fr); }
  .settings-users-form button { width: 100%; }
  .settings-savebar { align-items: flex-start; flex-direction: column; padding: 5px 0; }
  .settings-savebar .customer-primary-button { align-self: stretch; }
}



