:root {
  color-scheme: light;
  --blue-950: #102a43;
  --blue-900: #123b62;
  --blue-800: #15548c;
  --blue-700: #1269ad;
  --blue-600: #187bc5;
  --blue-100: #e8f3fb;
  --blue-50: #f3f8fc;
  --ink: #1d2939;
  --muted: #78889a;
  --border: #e8edf2;
  --surface: #fff;
  --canvas: #f7f9fc;
  --green: #14866d;
  --orange: #bf7415;
  --red: #c34c51;
  font-family: 'Segoe UI', Arial, sans-serif;
  color: var(--ink);
  background: var(--canvas);
  font-synthesis: none;
  text-rendering: optimizeLegibility;
}

* { box-sizing: border-box; }
body { margin: 0; min-width: 320px; min-height: 100vh; background: var(--canvas); }
button, input, select, textarea { font: inherit; }
button { cursor: pointer; }
button:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible { outline: 3px solid #78b9ea; outline-offset: 2px; }
.app-shell { min-height: 100vh; }

.sidebar {
  position: fixed; inset: 0 auto 0 0; z-index: 20; display: flex; flex-direction: column;
  width: 252px; padding: 21px 16px 16px; color: #eaf5ff;
  overflow-y: auto; background: linear-gradient(175deg, #123f69 0%, #0e3456 70%, #102d49 100%);
}
.brand { display: flex; flex-direction: column; align-items: flex-start; gap: 10px; padding: 0 8px 24px; text-decoration: none; }
.brand img { width: 146px; height: 110px; object-fit: cover; object-position: center; border: 2px solid rgba(255,255,255,.82); border-radius: 12px; }
.brand-caption, .nav-caption { font-size: 9px; font-weight: 700; letter-spacing: 1.45px; }
.brand-caption { color: #b7d7f0; }
.nav-caption { padding: 7px 12px 4px; color: #88adc9; font-size: 8px; letter-spacing: 1.2px; }
.navigation { display: grid; flex: 0 0 auto; align-content: start; gap: 5px; overflow: visible; }
.nav-group { display: grid; gap: 4px; padding: 4px 0 8px; }
.nav-link { position: relative; display: flex; align-items: center; gap: 12px; min-height: 44px; padding: 0 12px; color: #d3e2ef; border: 0; border-radius: 8px; background: transparent; text-align: left; font-size: 13px; font-weight: 500; transition: background .16s ease, color .16s ease; }
.nav-link:hover { color: #fff; background: rgba(255,255,255,.09); }
.nav-link.active { color: #fff; background: #1c70af; box-shadow: inset 3px 0 #83d0ff; }
.nav-icon { display: inline-flex; align-items: center; justify-content: center; width: 21px; color: #b5d5ef; font-size: 17px; font-weight: 700; }
.nav-link.active .nav-icon { color: #fff; }
.nav-count { margin-left: auto; min-width: 22px; padding: 3px 6px; border-radius: 20px; color: #d5ebfb; background: rgba(255,255,255,.13); text-align: center; font-size: 10px; }
.nav-count.alert-count:not(:empty) { color: #ffe8c8; }
.cloud-online { background: #59d19a; box-shadow: 0 0 0 3px rgba(89,209,154,.16); }
.sidebar-bottom { margin-top: auto; }
.local-status { display: flex; align-items: center; gap: 8px; padding: 12px; color: #b8d2e7; font-size: 10px; border-bottom: 1px solid rgba(255,255,255,.1); }
.online-dot { width: 7px; height: 7px; border-radius: 50%; background: #59d19a; box-shadow: 0 0 0 3px rgba(89,209,154,.15); }
.backup-link { width: 100%; margin-top: 9px; }
.sidebar-version { padding: 14px 12px 0; color: #87a7c0; font-size: 10px; line-height: 1.7; }

.main-content { min-height: 100vh; margin-left: 252px; }
.topbar { position: sticky; top: 0; z-index: 10; display: flex; align-items: center; justify-content: space-between; height: 64px; padding: 0 38px; border-bottom: 1px solid var(--border); background: rgba(255,255,255,.94); backdrop-filter: blur(12px); }
.breadcrumb { display: flex; align-items: center; gap: 11px; font-size: 12px; }
.breadcrumb > span:first-child { color: #98a6b5; font-size: 10px; font-weight: 700; letter-spacing: .9px; }
.breadcrumb-separator { color: #c6d0d9; }
.breadcrumb strong { color: var(--blue-900); font-weight: 600; }
.topbar-right { display: flex; align-items: center; gap: 16px; }
.today-label { color: var(--muted); font-size: 11px; }
.profile-trigger { display: flex; align-items: center; gap: 10px; padding: 3px 4px 3px 10px; border: 0; border-radius: 24px; background: transparent; text-align: right; }
.profile-trigger:hover { background: var(--blue-50); }
.profile-trigger-copy { display: grid; gap: 3px; }
.profile-trigger-copy strong { max-width: 180px; overflow: hidden; color: var(--blue-900); font-size: 10px; font-weight: 650; text-overflow: ellipsis; white-space: nowrap; }
.profile-trigger-copy > span { color: #98a6b3; font-size: 9px; }
.avatar { display: grid; width: 37px; height: 37px; flex: 0 0 37px; overflow: hidden; place-items: center; border: 1px solid #d5e6f2; border-radius: 50%; color: #fff; background: var(--blue-700); font-size: 11px; font-weight: 700; }
.avatar img { width: 100%; height: 100%; object-fit: cover; }
.mobile-menu { display: none; padding: 6px; border: 0; color: var(--blue-900); background: transparent; font-size: 19px; }
.page-content { max-width: 1450px; margin: 0 auto; padding: 31px 38px 48px; }

.page-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 18px; margin-bottom: 25px; }
.page-heading h1 { margin: 0 0 5px; color: var(--blue-950); font-family: 'Segoe UI', Arial, sans-serif; font-size: 23px; font-weight: 750; letter-spacing: -.6px; }
.page-heading p { margin: 0; color: var(--muted); font-size: 12px; }
.heading-actions { display: flex; align-items: center; gap: 9px; }
.button { display: inline-flex; align-items: center; justify-content: center; gap: 7px; min-height: 37px; padding: 0 14px; border: 1px solid transparent; border-radius: 7px; font-size: 11px; font-weight: 600; transition: .15s ease; }
.button-primary { color: #fff; background: var(--blue-700); box-shadow: 0 3px 8px rgba(18,105,173,.14); }
.button-primary:hover { background: var(--blue-800); }
.button-secondary { color: #41576d; border-color: var(--border); background: #fff; }
.button-secondary:hover { color: var(--blue-700); border-color: #b5d5ed; background: var(--blue-50); }
.button-danger { color: var(--red); border-color: #f0d7d9; background: #fff; }
.button-small { min-height: 29px; padding: 0 10px; font-size: 10px; }

.metrics-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 15px; margin-bottom: 20px; }
.metric-card { position: relative; min-height: 115px; padding: 17px 18px 15px; overflow: hidden; border: 1px solid var(--border); border-radius: 10px; background: var(--surface); }
.metric-card::after { position: absolute; top: -25px; right: -24px; width: 82px; height: 82px; border-radius: 50%; background: var(--blue-50); content: ''; }
.metric-top { position: relative; z-index: 1; display: flex; align-items: center; justify-content: space-between; margin-bottom: 11px; }
.metric-label { color: #6d7e90; font-size: 10px; font-weight: 600; }
.metric-icon { display: grid; width: 29px; height: 29px; place-items: center; border-radius: 8px; color: var(--blue-700); background: var(--blue-100); font-size: 13px; font-weight: 700; }
.metric-value { color: var(--blue-950); font-family: 'Segoe UI', Arial, sans-serif; font-size: 23px; font-weight: 750; letter-spacing: -.7px; line-height: 1.1; }
.metric-note { margin-top: 5px; color: #97a4b1; font-size: 9px; }
.metric-card.warning .metric-icon { color: var(--orange); background: #fff4e2; }
.metric-card.positive .metric-icon { color: var(--green); background: #e3f5ef; }

.content-grid { display: grid; grid-template-columns: minmax(0, 1.55fr) minmax(250px, .85fr); gap: 16px; margin-bottom: 17px; }
.panel { overflow: hidden; border: 1px solid var(--border); border-radius: 10px; background: var(--surface); }
.panel-header { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 58px; padding: 0 18px; border-bottom: 1px solid #edf1f4; }
.panel-title { color: var(--blue-950); font-family: 'Segoe UI', Arial, sans-serif; font-size: 12px; font-weight: 700; }
.panel-subtitle { margin-top: 3px; color: #9aa8b5; font-size: 9px; }
.text-button { padding: 5px 0; border: 0; color: var(--blue-700); background: transparent; font-size: 10px; font-weight: 600; }
.text-button:hover { color: var(--blue-900); text-decoration: underline; }
.table-wrap { width: 100%; overflow-x: auto; }
table { width: 100%; border-collapse: collapse; text-align: left; }
th { padding: 11px 15px; color: #91a0ad; background: #fcfdfe; font-size: 9px; font-weight: 600; white-space: nowrap; }
td { padding: 12px 15px; border-top: 1px solid #f0f3f6; color: #526477; font-size: 10px; vertical-align: middle; }
tbody tr:hover { background: #fbfdff; }
.table-primary { color: var(--blue-950); font-weight: 600; }
.table-secondary { margin-top: 3px; color: #98a5b1; font-size: 9px; }
.order-code { color: var(--blue-700); font-size: 10px; font-weight: 700; white-space: nowrap; }
.status-pill { display: inline-flex; align-items: center; gap: 5px; padding: 4px 8px; border-radius: 20px; color: #657587; background: #f0f3f6; font-size: 9px; font-weight: 600; white-space: nowrap; }
.status-pill::before { width: 5px; height: 5px; border-radius: 50%; background: currentColor; content: ''; }
.status-aguardando-avaliacao { color: #8272bc; background: #f1eef9; }
.status-aguardando-aprovacao { color: #ab761f; background: #fff5e3; }
.status-aguardando-pecas { color: #bc7315; background: #fff2df; }
.status-em-reparo { color: #3479b7; background: #eaf4fc; }
.status-pronto-para-retirada { color: #16846b; background: #e4f5ef; }
.status-entregue { color: #268252; background: #e7f5eb; }
.status-cancelado { color: #a85054; background: #f9ebec; }
.empty-state { padding: 30px 18px; color: #9aa6b2; text-align: center; font-size: 11px; }
.empty-state strong { display: block; margin-bottom: 5px; color: #61758a; font-size: 12px; }
.empty-state-compact { padding: 22px 15px; }
.stock-alert-list { display: grid; gap: 0; padding: 3px 17px 7px; }
.stock-alert-item { display: flex; align-items: center; justify-content: space-between; gap: 9px; padding: 12px 0; border-bottom: 1px solid #f1f3f5; }
.stock-alert-item:last-child { border-bottom: 0; }
.alert-item-name { color: #465a6e; font-size: 10px; font-weight: 600; }
.alert-item-code { margin-top: 3px; color: #a0acb7; font-size: 9px; }
.stock-quantity { color: var(--orange); font-size: 10px; font-weight: 700; white-space: nowrap; }
.quick-actions { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-top: 14px; }
.quick-action { display: flex; align-items: center; gap: 12px; min-height: 67px; padding: 10px 14px; border: 1px solid var(--border); border-radius: 9px; color: inherit; background: #fff; text-align: left; transition: .15s ease; }
.quick-action:hover { border-color: #b4d7ef; background: var(--blue-50); transform: translateY(-1px); }
.quick-icon { display: grid; width: 33px; height: 33px; flex: 0 0 33px; place-items: center; border-radius: 9px; color: var(--blue-700); background: var(--blue-100); font-size: 14px; font-weight: 700; }
.quick-text strong { display: block; color: #334d64; font-size: 10px; }
.quick-text span { display: block; margin-top: 3px; color: #94a1ae; font-size: 9px; }

.toolbar { display: flex; align-items: center; gap: 9px; margin-bottom: 13px; }
.search-field { position: relative; flex: 1; max-width: 340px; }
.search-field::before { position: absolute; top: 9px; left: 12px; color: #9eacb9; content: '⌕'; font-size: 19px; line-height: 1; }
.search-input, .filter-select { width: 100%; height: 36px; border: 1px solid var(--border); border-radius: 7px; outline: 0; color: #43586b; background: #fff; font-size: 10px; }
.search-input { padding: 0 12px 0 34px; }
.filter-select { width: auto; min-width: 145px; padding: 0 28px 0 11px; }
.search-input::placeholder { color: #a8b3bd; }
.results-label { margin-left: auto; color: #92a0ad; font-size: 10px; white-space: nowrap; }
.data-panel { min-height: 150px; }
.row-actions { display: flex; align-items: center; gap: 6px; }
.icon-button { display: inline-grid; width: 29px; height: 29px; place-items: center; border: 1px solid #edf1f4; border-radius: 6px; color: #6c8194; background: #fff; font-size: 12px; }
.icon-button:hover { border-color: #bad8ee; color: var(--blue-700); background: var(--blue-50); }
.inline-select { max-width: 176px; padding: 5px 7px; border: 1px solid #e8edf2; border-radius: 6px; color: #5e7183; background: #fff; font-size: 9px; }
.form-hint { margin-top: 5px; color: #91a0ae; font-size: 9px; line-height: 1.5; }
.customer-contact { color: #597187; font-size: 10px; white-space: nowrap; }
.stock-good { color: var(--green); font-weight: 700; }
.stock-low { color: var(--orange); font-weight: 700; }
.stock-empty { color: var(--red); font-weight: 700; }
.finance-positive { color: var(--green); font-weight: 700; }
.finance-negative { color: var(--red); font-weight: 700; }
.finance-source { color: var(--blue-700); }
.section-spacer { margin-top: 20px; }
.banner { display: flex; align-items: flex-start; gap: 11px; margin-bottom: 16px; padding: 13px 15px; border: 1px solid #d5e9f7; border-radius: 8px; color: #54718a; background: #eff8fe; font-size: 10px; line-height: 1.55; }
.banner-icon { color: var(--blue-700); font-size: 14px; font-weight: 700; }
.finance-summary { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 13px; margin-bottom: 18px; }
.finance-summary .metric-card { min-height: 95px; }
.finance-summary .metric-value { font-size: 21px; }
.pagination-note { padding: 12px 15px; color: #9ba8b5; font-size: 9px; }
.metrics-grid-extra { margin-top: -6px; }
.product-intro { display: flex; align-items: center; gap: 12px; margin: -5px 0 17px; color: #697d8f; font-size: 10px; }
.product-intro strong { color: var(--blue-900); font-size: 11px; }
.product-intro .button { margin-left: auto; }
.product-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 13px; }
.product-card { overflow: hidden; border: 1px solid var(--border); border-radius: 9px; background: #fff; transition: box-shadow .15s ease, transform .15s ease; }
.product-card:hover { box-shadow: 0 7px 19px rgba(24,60,90,.08); transform: translateY(-2px); }
.product-photo { position: relative; display: grid; height: 160px; place-items: center; overflow: hidden; color: #8eabc0; background: linear-gradient(140deg, #eef5fa, #f8fafc); font-family: 'Segoe UI', sans-serif; font-size: 31px; font-weight: 750; }
.product-photo img { width: 100%; height: 100%; object-fit: cover; }
.product-kind { position: absolute; right: 9px; bottom: 9px; padding: 4px 8px; border: 1px solid rgba(255,255,255,.7); border-radius: 20px; color: #294d6a; background: rgba(255,255,255,.9); font-size: 9px; font-weight: 650; }
.product-card-body { padding: 12px; }
.product-name { min-height: 15px; color: var(--blue-950); font-size: 11px; }
.product-prices { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin: 11px 0; font-size: 10px; }
.product-prices > span:first-child { color: var(--blue-800); font-size: 13px; font-weight: 700; }
.product-actions { padding-top: 9px; border-top: 1px solid #f0f3f5; }
.product-actions .icon-button:last-child { margin-left: auto; }
.product-empty { grid-column: 1 / -1; }
.product-image-upload { display: flex; align-items: center; gap: 10px; min-height: 92px; margin: 0 0 16px; padding: 9px; border: 1px dashed #c9d9e5; border-radius: 8px; color: #8293a1; background: #f9fbfd; font-size: 10px; }
.product-image-upload img { width: 74px; height: 74px; border-radius: 6px; object-fit: cover; background: #edf3f7; }
.product-image-upload label { margin-left: auto; }
.product-image-upload .text-button { color: #9a6b6b; font-size: 9px; }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; clip-path: inset(50%); }
.checklist-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 7px; }
.checklist-option { display: flex; align-items: center; gap: 8px; min-height: 32px; padding: 6px 8px; border: 1px solid #e8edf2; border-radius: 6px; color: #586e81; background: #fff; font-size: 9px; cursor: pointer; }
.checklist-option:has(input:checked) { color: #226b51; border-color: #c9e8d8; background: #f2faf5; }
.checklist-option input { width: 14px; height: 14px; margin: 0; accent-color: var(--green); }
.order-checklist-details { margin-top: 17px; padding-top: 14px; border-top: 1px solid #edf1f4; }
.order-checklist-details .checklist-option { min-height: 30px; }
.cart-list { display: grid; gap: 7px; max-height: 190px; overflow-y: auto; }
.cart-row { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; align-items: center; gap: 10px; padding: 9px; border: 1px solid #e9eef2; border-radius: 7px; color: #4a6074; font-size: 10px; }
.cart-row > div:first-child { min-width: 0; }
.cart-row > div:first-child strong, .cart-row > div:first-child span { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cart-row > div:first-child span { margin-top: 3px; color: #94a1ac; font-size: 9px; }
.cart-row > strong { color: var(--blue-800); white-space: nowrap; }
.cart-controls { display: flex; align-items: center; gap: 5px; }
.cart-controls input { width: 52px; height: 29px; padding: 4px; border: 1px solid #e3eaf0; border-radius: 5px; color: #506477; font-size: 10px; }
.cart-total { padding: 9px; color: var(--blue-900); text-align: right; font-size: 12px; font-weight: 700; }
.pos-overview { display: flex; align-items: flex-start; gap: 12px; }
.pos-overview .banner { flex: 1; }
.cloud-auth-section { margin-top: 16px; padding-top: 2px; border-top: 1px solid #edf1f4; }
.cloud-connected { display: flex; align-items: center; gap: 9px; margin-top: 16px; padding: 11px; border: 1px solid #d5ecdd; border-radius: 7px; color: #42715c; background: #f3fbf5; font-size: 10px; }
.cloud-note { margin-top: 13px; padding-top: 11px; border-top: 1px solid #eff2f5; color: #8997a4; font-size: 9px; line-height: 1.6; }
.fiscal-banner { color: #7a633e; border-color: #f0e2c9; background: #fff9ee; }
.fiscal-banner .banner-icon { color: #b57d2e; }
.settings-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 15px; }
.staff-panel { margin-top: 15px; }
.staff-name-cell { display: flex; align-items: center; gap: 8px; }
.staff-name-cell > img, .staff-initials { display: grid; width: 30px; height: 30px; flex: 0 0 30px; place-items: center; overflow: hidden; border-radius: 50%; color: var(--blue-800); background: var(--blue-100); font-size: 9px; font-weight: 700; object-fit: cover; }
.staff-panel .panel-header { padding-top: 8px; padding-bottom: 8px; }
.settings-panel-body { padding: 17px; }
.seller-photo-picker { display: flex; align-items: center; gap: 10px; min-height: 74px; margin-bottom: 16px; padding: 9px; border: 1px dashed #cbd9e4; border-radius: 8px; color: #8b9ba8; background: #fafcfd; font-size: 10px; }
.seller-photo-picker img { width: 56px; height: 56px; border-radius: 50%; object-fit: cover; }
.seller-photo-picker label { margin-left: auto; }
.seller-photo-picker .text-button { color: #9c7373; font-size: 9px; }
.printer-auto-setting { grid-column: 1 / -1; display: flex; align-items: flex-start; gap: 9px; padding: 12px; border: 1px solid #dceaf3; border-radius: 7px; color: #4a6378; background: #f5fafe; cursor: pointer; }
.printer-auto-setting input { width: 15px; height: 15px; flex: 0 0 15px; accent-color: var(--blue-700); }
.printer-auto-setting strong, .printer-auto-setting small { display: block; font-size: 10px; }
.printer-auto-setting small { margin-top: 4px; color: #8696a4; font-size: 9px; line-height: 1.45; }
.printer-info-panel { margin-top: 16px; }
.printer-instructions ol { margin: 0 0 16px; padding-left: 19px; color: #52677b; font-size: 10px; line-height: 1.8; }

.app-dialog { width: min(540px, calc(100vw - 28px)); max-width: 540px; max-height: min(88vh, 850px); padding: 0; overflow-x: hidden; overflow-y: auto; border: 0; border-radius: 13px; color: var(--ink); background: #fff; box-shadow: 0 20px 70px rgba(18,42,66,.23); }
.app-dialog::backdrop { background: rgba(13,31,49,.46); backdrop-filter: blur(2px); }
.dialog-close-form { position: sticky; top: 0; z-index: 2; display: flex; justify-content: flex-end; height: 0; }
.dialog-close { display: grid; width: 30px; height: 30px; margin: 13px 13px 0 0; place-items: center; border: 1px solid #edf0f3; border-radius: 50%; color: #728396; background: #fff; font-size: 18px; line-height: 1; }
.dialog-content { padding: 26px 26px 23px; }
.dialog-eyebrow { margin-bottom: 7px; color: var(--blue-700); font-size: 9px; font-weight: 700; letter-spacing: 1.1px; }
.dialog-title { margin: 0 34px 5px 0; color: var(--blue-950); font-family: 'Segoe UI', Arial, sans-serif; font-size: 19px; letter-spacing: -.35px; }
.dialog-description { margin: 0 0 20px; color: #8493a1; font-size: 10px; line-height: 1.5; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 13px 12px; }
.form-field { display: flex; flex-direction: column; gap: 6px; }
.form-field.full { grid-column: 1 / -1; }
.form-field label { color: #53687b; font-size: 10px; font-weight: 600; }
.form-field input, .form-field select, .form-field textarea { width: 100%; min-height: 37px; padding: 9px 10px; border: 1px solid #e4eaf0; border-radius: 6px; outline: 0; color: #354a5e; background: #fff; font-size: 11px; }
.form-field textarea { min-height: 82px; resize: vertical; }
.form-field input::placeholder, .form-field textarea::placeholder { color: #abb6c0; }
.part-picker { display: grid; grid-template-columns: minmax(0, 1fr) 78px auto; gap: 7px; }
.part-picker select, .part-picker input { min-width: 0; min-height: 36px; padding: 8px; border: 1px solid #e4eaf0; border-radius: 6px; color: #354a5e; background: #fff; font-size: 10px; }
.selected-parts { display: grid; gap: 5px; }
.selected-parts-empty { padding: 8px 0 1px; color: #99a6b1; font-size: 9px; }
.selected-part { display: flex; align-items: center; justify-content: space-between; gap: 9px; padding: 5px 8px; border: 1px solid #e8eff4; border-radius: 6px; color: #536b80; background: #f8fbfd; font-size: 10px; }
.selected-part strong { margin-left: 4px; color: var(--blue-700); }
.form-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 20px; padding-top: 15px; border-top: 1px solid #eff2f5; }
.detail-code { display: inline-flex; margin-bottom: 9px; padding: 5px 8px; border-radius: 5px; color: var(--blue-700); background: var(--blue-50); font-size: 10px; font-weight: 700; }
.detail-meta { display: grid; grid-template-columns: 1fr 1fr; gap: 13px; margin: 17px 0; padding: 14px; border: 1px solid #eef2f5; border-radius: 8px; }
.detail-label { color: #94a1ad; font-size: 9px; }
.detail-value { margin-top: 4px; color: #3a5268; font-size: 11px; font-weight: 600; }
.detail-section-title { margin: 19px 0 9px; color: #324c63; font-family: 'Segoe UI', Arial, sans-serif; font-size: 11px; font-weight: 700; }
.history-list { display: grid; gap: 0; }
.history-entry { position: relative; display: grid; grid-template-columns: 12px 1fr; gap: 10px; min-height: 43px; }
.history-entry:not(:last-child)::after { position: absolute; top: 13px; bottom: -3px; left: 5px; width: 1px; background: #dfeaf2; content: ''; }
.history-dot { position: relative; z-index: 1; width: 11px; height: 11px; margin-top: 2px; border: 2px solid #78b9e5; border-radius: 50%; background: #fff; }
.history-text { color: #556b7e; font-size: 10px; }
.history-date { margin-top: 3px; color: #9ba7b2; font-size: 9px; }
.toast-region { position: fixed; right: 22px; bottom: 20px; z-index: 50; display: grid; gap: 8px; }
.toast { max-width: min(390px, calc(100vw - 32px)); padding: 11px 15px; border: 1px solid #d7ecdf; border-radius: 8px; color: #286d50; background: #f0faf4; box-shadow: 0 8px 24px rgba(25,49,68,.1); font-size: 11px; animation: toast-in .18s ease-out; }
.toast.error { border-color: #f0dadd; color: #a23f4a; background: #fff6f6; }
@keyframes toast-in { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: translateY(0); } }

@media (min-width: 1440px) { .page-content { padding-right: 52px; padding-left: 52px; } }
@media (max-width: 1100px) {
  .sidebar { width: 220px; }
  .main-content { margin-left: 220px; }
  .page-content { padding-right: 24px; padding-left: 24px; }
  .topbar { padding-right: 24px; padding-left: 24px; }
  .metrics-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .content-grid { grid-template-columns: minmax(0, 1.25fr) minmax(230px, .8fr); }
  .product-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 760px) {
  .sidebar { width: 252px; transform: translateX(-105%); transition: transform .2s ease; box-shadow: 14px 0 35px rgba(13,40,64,.18); }
  .sidebar.open { transform: translateX(0); }
  .main-content { margin-left: 0; }
  .topbar { height: 58px; padding: 0 16px; }
  .mobile-menu { display: inline-grid; place-items: center; }
  .breadcrumb { margin-right: auto; margin-left: 10px; }
  .breadcrumb > span:first-child, .breadcrumb-separator { display: none; }
  .today-label { display: none; }
  .profile-trigger { padding-right: 0; padding-left: 0; }
  .profile-trigger-copy { display: none; }
  .page-content { padding: 24px 16px 36px; }
  .page-heading { align-items: flex-start; flex-direction: column; margin-bottom: 20px; }
  .heading-actions { width: 100%; }
  .heading-actions .button { flex: 1; }
  .content-grid { grid-template-columns: 1fr; }
  .quick-actions { grid-template-columns: 1fr; gap: 8px; }
  .quick-action { min-height: 59px; }
  .toolbar { flex-wrap: wrap; }
  .search-field { flex-basis: 100%; max-width: none; }
  .filter-select { flex: 1; }
  .results-label { margin-left: 0; }
  .finance-summary { gap: 8px; }
  .product-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 9px; }
  .product-photo { height: 128px; }
  .product-intro { flex-wrap: wrap; }
  .pos-overview { flex-direction: column; }
  .pos-overview .button { width: 100%; }
  .settings-grid { grid-template-columns: 1fr; }
  .finance-summary .metric-card { padding: 12px; }
  .finance-summary .metric-value { font-size: 16px; }
}
@media (max-width: 430px) {
  .metrics-grid { gap: 9px; }
  .metric-card { min-height: 106px; padding: 13px 12px; }
  .metric-label { font-size: 9px; }
  .metric-value { font-size: 19px; }
  .finance-summary .metric-label { font-size: 8px; }
  .product-grid { grid-template-columns: 1fr; }
  .product-photo { height: 185px; }
  .cart-row { grid-template-columns: minmax(0, 1fr) auto; }
  .cart-row > strong { grid-column: 1 / -1; text-align: right; }
  .product-image-upload { flex-wrap: wrap; }
  .product-image-upload label { margin-left: 0; }
  .app-dialog { border-radius: 11px; }
  .dialog-content { padding: 23px 17px 18px; }
  .form-grid { grid-template-columns: 1fr; }
  .form-field.full { grid-column: auto; }
  .detail-meta { gap: 10px; padding: 11px; }
}
