:root {
  --ink: #111111;
  --muted: #686868;
  --line: #e5e5e5;
  --surface: #ffffff;
  --canvas: #f9f9f9;
  --sidebar: #000000;
  --purple: #111111;
  --purple-dark: #000000;
  --purple-soft: #fcffd7;
  --green: #137549;
  --green-soft: #eef8f2;
  --amber: #9a6b00;
  --amber-soft: #fff7db;
  --red: #b52f3e;
  --red-soft: #fff1f2;
  --accent: #f2ff58;
  --accent-soft: #fcffd7;
  --shadow: 0 8px 24px rgba(0, 0, 0, .045);
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
.sr-only { position: absolute !important; width: 1px !important; height: 1px !important; padding: 0 !important; overflow: hidden !important; clip: rect(0, 0, 0, 0) !important; white-space: nowrap !important; border: 0 !important; }
html { background: var(--canvas); }
body { margin: 0; color: var(--ink); background: var(--canvas); font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; -webkit-font-smoothing: antialiased; }
button, input, select { font: inherit; }
button { cursor: pointer; }

.app-shell { min-height: 100vh; display: grid; grid-template-columns: 246px 1fr; }
.sidebar { position: sticky; top: 0; height: 100vh; display: flex; flex-direction: column; padding: 30px 20px 22px; color: #d8d8d8; background: #000; }
.brand { display: grid; align-content: start; gap: 11px; min-height: 74px; padding: 0 12px 24px; color: white; }
.brand-logo { width: 118px; height: auto; display: block; }
.brand small { color: #7e7e7e; font-size: 8px; font-weight: 700; letter-spacing: 3px; }
.nav { display: grid; gap: 6px; }
.nav-section { margin: 17px 12px 4px; color: #5d5d5d; font-size: 8px; font-weight: 700; letter-spacing: 1.6px; }
.nav-section:first-child { margin-top: 0; }
.nav-item { width: 100%; display: grid; grid-template-columns: 24px 1fr auto; align-items: center; gap: 9px; padding: 10px 12px; color: #929292; border: 0; border-radius: 2px; background: transparent; text-align: left; transition: .16s ease; }
.nav-item:hover { color: white; background: #171717; }
.nav-item.active { color: #000; background: var(--accent); }
.nav-icon { font-size: 15px; text-align: center; }
.nav-count { min-width: 22px; padding: 2px 6px; border-radius: 1px; color: inherit; background: rgba(255,255,255,.12); font-size: 9px; text-align: center; }
.nav-item.active .nav-count { background: rgba(0,0,0,.08); }
.sidebar-foot { margin-top: auto; padding: 16px 10px 0; border-top: 1px solid rgba(255,255,255,.08); }
.mini-status { display: flex; align-items: center; gap: 8px; margin-bottom: 9px; color: #aeb5c8; font-size: 12px; }
.status-dot { width: 7px; height: 7px; border-radius: 50%; background: #d69a4b; box-shadow: 0 0 0 4px rgba(214,154,75,.1); }
.status-dot.ok { background: #3cc58b; box-shadow: 0 0 0 4px rgba(60,197,139,.1); }
.sidebar .text-button { padding: 0; color: #777f98; font-size: 11px; }

.main { min-width: 0; padding: 0 42px 52px; }
.topbar { height: 112px; display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.eyebrow, .section-label { margin: 0 0 6px; color: #808080; font-size: 9px; font-weight: 700; letter-spacing: 1.65px; }
.topbar h1 { margin: 0; font-size: 28px; font-weight: 400; letter-spacing: -1px; }
.topbar-actions { display: flex; align-items: center; gap: 10px; }
.environment-pill { display: inline-flex; align-items: center; gap: 7px; height: 34px; padding: 0 12px; border: 1px solid var(--line); border-radius: 2px; color: #737373; background: white; font-size: 9px; letter-spacing: .8px; }
.environment-pill span { width: 6px; height: 6px; border-radius: 50%; background: var(--green); }
.icon-button { width: 38px; height: 38px; border: 1px solid var(--line); border-radius: 2px; color: #606060; background: white; font-size: 19px; }
.icon-button:hover { color: var(--purple); border-color: #cec8f6; }
.mobile-logout { display: none; }
.primary-button, .secondary-button, .danger-button, .light-button { min-height: 40px; display: inline-flex; align-items: center; justify-content: center; gap: 7px; padding: 0 16px; border-radius: 2px; font-size: 12px; font-weight: 700; transition: .18s ease; }
.primary-button { color: white; border: 1px solid #000; background: #000; box-shadow: none; }
.primary-button:hover { border-color: var(--purple-dark); background: var(--purple-dark); transform: translateY(-1px); }
.secondary-button { color: #586174; border: 1px solid var(--line); background: white; }
.secondary-button:hover { color: var(--purple); border-color: #cfcaf4; }
.danger-button { color: var(--red); border: 1px solid #f0cbd0; background: white; }
.danger-button:hover { border-color: #e7aab2; background: var(--red-soft); }
.secondary-button.compact { min-height: 34px; padding: 0 11px; font-size: 12px; }
.primary-button.compact { min-height: 34px; padding: 0 12px; font-size: 10px; }
.light-button { margin-top: 20px; color: var(--purple); border: 0; background: white; }
.light-button:hover { transform: translateX(2px); }
.text-button { padding: 4px; border: 0; color: var(--purple); background: none; font-size: 12px; font-weight: 650; }
.full { width: 100%; }

.view { display: none; animation: appear .22s ease; }
.view.active { display: block; }
@keyframes appear { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }

.hero-card { min-height: 238px; display: grid; grid-template-columns: minmax(320px, .9fr) minmax(450px, 1.1fr); align-items: center; gap: 40px; padding: 38px 42px; overflow: hidden; border-radius: 16px; color: white; background: radial-gradient(circle at 78% 15%, rgba(141,125,241,.45), transparent 28%), linear-gradient(120deg, #292052, #5746c9 72%, #6f5fe4); box-shadow: 0 16px 42px rgba(59, 46, 135, .18); }
.hero-kicker { color: #c5bcff; font-size: 10px; font-weight: 750; letter-spacing: 1.4px; text-transform: uppercase; }
.hero-card h2 { max-width: 480px; margin: 9px 0 10px; font-size: clamp(27px, 3vw, 38px); line-height: 1.1; letter-spacing: -1.2px; }
.hero-card p { max-width: 520px; margin: 0; color: #d9d5f4; font-size: 14px; line-height: 1.6; }
.flow-visual { display: grid; grid-template-columns: 112px 1fr 112px 1fr 112px; align-items: center; }
.flow-node { min-height: 116px; display: flex; flex-direction: column; align-items: center; justify-content: center; border: 1px solid rgba(255,255,255,.2); border-radius: 14px; background: rgba(255,255,255,.1); backdrop-filter: blur(8px); }
.flow-node > span { width: 34px; height: 34px; display: grid; place-items: center; margin-bottom: 8px; border-radius: 9px; color: #4335a6; background: white; font-size: 17px; font-weight: 800; }
.flow-node b { font-size: 13px; }
.flow-node small { margin-top: 3px; color: #cfc9ee; font-size: 10px; }
.engine-node { background: rgba(255,255,255,.17); box-shadow: inset 0 0 0 1px rgba(255,255,255,.08); }
.flow-line { position: relative; display: flex; justify-content: center; }
.flow-line i { width: 100%; height: 1px; background: rgba(255,255,255,.35); }
.flow-line i::after { content: ""; position: absolute; right: -1px; top: -3px; border-left: 5px solid rgba(255,255,255,.55); border-top: 3px solid transparent; border-bottom: 3px solid transparent; }
.flow-line span { position: absolute; top: -20px; color: #bbb4df; font-size: 8px; letter-spacing: .6px; text-transform: uppercase; }

.stats-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin: 18px 0; }
.stat-card { display: flex; align-items: center; gap: 15px; min-height: 104px; padding: 20px 22px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); box-shadow: 0 5px 18px rgba(24,32,51,.025); }
.stat-icon { flex: 0 0 42px; height: 42px; display: grid; place-items: center; border-radius: 11px; font-size: 18px; }
.stat-icon.purple { color: var(--purple); background: var(--purple-soft); }
.stat-icon.green { color: var(--green); background: var(--green-soft); }
.stat-icon.amber { color: var(--amber); background: var(--amber-soft); }
.stat-card > div:last-child { display: grid; }
.stat-card span { color: var(--muted); font-size: 11px; }
.stat-card strong { margin: 3px 0 1px; font-size: 23px; letter-spacing: -.6px; }
.stat-card small { color: #9aa1af; font-size: 10px; }

.content-grid { display: grid; grid-template-columns: minmax(0, 1.45fr) minmax(300px, .75fr); gap: 18px; }
.panel { border: 1px solid var(--line); border-radius: 3px; background: white; box-shadow: none; }
.panel-heading { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 22px 24px 17px; border-bottom: 1px solid #eff0f4; }
.panel-heading h3 { margin: 0; font-size: 15px; letter-spacing: -.2px; }
.priority-list { min-height: 190px; padding: 6px 24px 14px; }
.priority-item { display: grid; grid-template-columns: 30px minmax(0,1fr) auto; align-items: center; gap: 12px; padding: 15px 0; border-bottom: 1px solid #f0f1f4; }
.priority-item:last-child { border-bottom: 0; }
.priority-rank { width: 28px; height: 28px; display: grid; place-items: center; border-radius: 8px; color: var(--purple); background: var(--purple-soft); font-size: 11px; font-weight: 750; }
.priority-item b { display: block; overflow: hidden; font-size: 12px; text-overflow: ellipsis; white-space: nowrap; }
.priority-item small { color: #9299a8; font-size: 10px; }
.method-chip { padding: 4px 8px; border-radius: 6px; font-size: 10px; font-weight: 750; }
.method-chip.PAC { color: #3d63a9; background: #edf3ff; }
.method-chip.SEDEX { color: #bf6730; background: #fff0e7; }
.rule-action-badge { display: inline-flex; align-items: center; gap: 6px; min-height: 27px; padding: 4px 8px 4px 5px; border-radius: 7px; font-size: 9px; white-space: nowrap; }
.rule-action-badge > span { width: 20px; height: 20px; display: grid; place-items: center; border-radius: 5px; font-size: 8px; font-weight: 800; }
.rule-action-badge.restriction { color: #a83c49; background: var(--red-soft); }
.rule-action-badge.restriction > span { background: white; }
.rule-action-badge.free_shipping { color: var(--green); background: var(--green-soft); }
.rule-action-badge.free_shipping > span { background: white; }
.rule-action-badge.delivery_days { color: #8a5b11; background: var(--amber-soft); }
.rule-action-badge.delivery_days > span { background: white; }
.rule-action-badge.product_delivery_days { color: #8a5b11; background: var(--amber-soft); }
.rule-action-badge.product_delivery_days > span { background: white; }
.rule-action-badge.product_exclusive { color: #4d55a8; background: #eef0ff; }
.rule-action-badge.product_exclusive > span { background: white; }
.rule-action-badge.compact { padding-right: 6px; }
.readiness-panel .score { padding: 5px 9px; border-radius: 7px; color: var(--green); background: var(--green-soft); font-size: 11px; font-weight: 750; }
.check-list { padding: 9px 24px 16px; }
.check-row { display: grid; grid-template-columns: 22px 1fr; gap: 10px; padding: 11px 0; }
.check-row i { width: 20px; height: 20px; display: grid; place-items: center; border-radius: 50%; color: var(--green); background: var(--green-soft); font-size: 10px; font-style: normal; font-weight: 800; }
.check-row.pending i { color: var(--amber); background: var(--amber-soft); }
.check-row b { display: block; font-size: 11px; }
.check-row small { color: #969dac; font-size: 9px; }

.section-intro { min-height: 58px; display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; margin-bottom: 16px; }
.section-intro p { margin: 0; color: var(--muted); font-size: 13px; }
.filter-row { display: flex; gap: 9px; }
.search-box { width: 290px; height: 38px; display: flex; align-items: center; gap: 8px; padding: 0 12px; border: 1px solid var(--line); border-radius: 8px; background: white; }
.search-box span { color: #979ead; font-size: 18px; }
.search-box input { min-width: 0; flex: 1; border: 0; outline: 0; color: var(--ink); background: transparent; font-size: 12px; }
select, input { border: 1px solid #dfe2e9; border-radius: 7px; color: var(--ink); background: white; outline: 0; }
select:focus, input:focus { border-color: #a79bed; box-shadow: 0 0 0 3px rgba(109,92,231,.1); }
.filter-row select { height: 38px; padding: 0 30px 0 11px; color: #657084; font-size: 11px; }
.table-panel { overflow: hidden; }
.table-header { height: 58px; display: flex; align-items: center; justify-content: space-between; padding: 0 20px; border-bottom: 1px solid var(--line); }
.table-header > span { color: var(--muted); font-size: 11px; font-weight: 650; }
.rules-table-wrap { overflow-x: auto; }
.rules-table { width: 100%; border-collapse: collapse; }
.rules-table th { padding: 12px 16px; color: #9299a7; background: #fafbfc; font-size: 9px; font-weight: 750; letter-spacing: .7px; text-align: left; text-transform: uppercase; }
.rules-table td { padding: 16px; border-top: 1px solid #eff0f3; vertical-align: middle; font-size: 11px; }
.rules-table tbody tr { transition: .15s ease; }
.rules-table tbody tr:hover { background: #fcfcfe; }
.rule-name { max-width: 260px; }
.rule-name b { display: block; overflow: hidden; font-size: 12px; text-overflow: ellipsis; white-space: nowrap; }
.rule-name small { color: #9aa1ae; }
.condition-summary { max-width: 350px; color: #657084; line-height: 1.5; }
.condition-summary code { padding: 2px 5px; border-radius: 4px; color: #5647bc; background: #f2f0ff; font: 10px ui-monospace, SFMono-Regular, Menlo, monospace; }
.priority-badge { display: inline-grid; place-items: center; min-width: 32px; height: 25px; padding: 0 7px; border-radius: 6px; color: #687084; background: #f1f2f5; font-weight: 750; }
.toggle { position: relative; width: 34px; height: 19px; display: inline-block; }
.toggle input { position: absolute; opacity: 0; }
.toggle span { position: absolute; inset: 0; border-radius: 20px; background: #ccd1dc; transition: .2s; }
.toggle span::after { content: ""; position: absolute; width: 15px; height: 15px; left: 2px; top: 2px; border-radius: 50%; background: white; box-shadow: 0 1px 3px rgba(0,0,0,.2); transition: .2s; }
.toggle input:checked + span { background: var(--green); }
.toggle input:checked + span::after { transform: translateX(15px); }
.toggle input:focus-visible + span { outline: 3px solid rgba(109,92,231,.2); outline-offset: 2px; }
.row-actions { display: flex; gap: 4px; }
.row-button { min-width: 30px; height: 30px; padding: 0 8px; border: 0; border-radius: 7px; color: #858d9d; background: transparent; }
.row-button.edit-button { display: inline-flex; align-items: center; gap: 5px; color: var(--purple); background: var(--purple-soft); font-size: 10px; font-weight: 700; }
.row-button.edit-button > span:first-child { font-size: 12px; }
.row-button:hover { color: var(--purple); background: var(--purple-soft); }
.row-button.danger:hover { color: var(--red); background: var(--red-soft); }
.empty-state { display: none; padding: 65px 20px; text-align: center; }
.empty-state.show { display: block; }
.empty-state span { width: 44px; height: 44px; display: grid; place-items: center; margin: auto; border-radius: 12px; color: var(--purple); background: var(--purple-soft); }
.empty-state h3 { margin: 13px 0 5px; font-size: 14px; }
.empty-state p { margin: 0; color: var(--muted); font-size: 11px; }

.product-picker-host { min-width: 0; }
.product-picker { position: relative; min-width: 0; }
.product-picker-chips { min-height: 28px; display: flex; align-items: center; flex-wrap: wrap; gap: 6px; margin-bottom: 7px; }
.product-picker-empty-selection { color: #9aa1af; font-size: 9px; font-weight: 500; }
.product-chip { max-width: 100%; height: 29px; display: inline-flex; align-items: center; gap: 6px; padding: 3px 5px 3px 3px; border: 1px solid #ddd9fa; border-radius: 7px; color: #51449f; background: #f4f2ff; font-size: 9px; font-weight: 650; }
.product-chip > span:nth-child(2) { max-width: 175px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.product-chip button { width: 19px; height: 19px; display: grid; place-items: center; padding: 0; border: 0; border-radius: 5px; color: #8175bd; background: transparent; font-size: 14px; line-height: 1; }
.product-chip button:hover, .product-chip button:focus-visible { color: var(--red); background: white; }
.product-search-control { height: 38px; display: flex; align-items: center; gap: 8px; padding: 0 10px; border: 1px solid #dfe2e9; border-radius: 7px; background: white; transition: .15s ease; }
.product-search-control:focus-within { border-color: #a79bed; box-shadow: 0 0 0 3px rgba(109,92,231,.1); }
.product-search-control > span { color: #969dab; font-size: 16px; }
.product-search-control .product-search-input { min-width: 0; height: 34px; flex: 1; padding: 0; border: 0; border-radius: 0; box-shadow: none; background: transparent; }
.product-picker-results { position: absolute; z-index: 12; top: calc(100% - 16px); left: 0; right: 0; max-height: 270px; overflow-y: auto; padding: 5px; border: 1px solid #dcdee6; border-radius: 9px; background: white; box-shadow: 0 15px 38px rgba(24,32,51,.16); }
.product-result { width: 100%; min-height: 55px; display: grid; grid-template-columns: 40px minmax(0, 1fr) auto; align-items: center; gap: 10px; padding: 7px; border: 0; border-radius: 7px; color: var(--ink); background: white; text-align: left; }
.product-result:hover, .product-result.active { background: #f6f4ff; }
.product-result.selected { background: #f7f8fa; }
.product-result:disabled { cursor: default; opacity: 1; }
.product-result-copy { min-width: 0; display: grid; gap: 3px; }
.product-result-copy b { overflow: hidden; font-size: 10px; text-overflow: ellipsis; white-space: nowrap; }
.product-result-copy small { color: #9299a7; font-size: 8px; }
.product-result-action { color: var(--purple); font-size: 8px; font-weight: 750; }
.product-result.selected .product-result-action { color: var(--green); }
.product-picker-status { min-height: 12px; margin: 5px 1px 0; color: #949baa; font-size: 8px; font-weight: 500; line-height: 1.35; }
.product-search-message { min-height: 58px; display: flex; align-items: center; justify-content: center; gap: 8px; padding: 12px; color: #7d8595; font-size: 9px; text-align: center; }
.product-search-message.error { color: var(--red); background: var(--red-soft); border-radius: 6px; }
.product-search-message.loading i, .simulation-loading i { width: 15px; height: 15px; border: 2px solid #dedaf8; border-top-color: var(--purple); border-radius: 50%; animation: spin .75s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.product-thumbnail, .product-chip-image, .simulation-product-image { position: relative; display: grid; place-items: center; flex: 0 0 auto; overflow: hidden; color: #6355bb; background: #ece9ff; font-weight: 800; }
.product-thumbnail { width: 40px; height: 40px; border-radius: 7px; font-size: 12px; }
.product-chip-image { width: 21px; height: 21px; border-radius: 5px; font-size: 8px; }
.simulation-product-image { width: 52px; height: 52px; border-radius: 9px; font-size: 15px; }
.product-thumbnail img, .product-chip-image img, .simulation-product-image img { position: absolute; z-index: 1; inset: 0; width: 100%; height: 100%; object-fit: cover; background: white; }
.product-image-fallback { position: relative; z-index: 0; }

.simulation-badge { padding: 6px 10px; border-radius: 99px; color: var(--purple); background: var(--purple-soft); font-size: 9px; font-weight: 750; }
.simulation-layout { display: grid; grid-template-columns: minmax(0, 1.08fr) minmax(360px, .92fr); align-items: start; gap: 18px; }
.simulation-form-panel, .simulation-results-panel { overflow: visible; }
.step-badge { width: 27px; height: 27px; display: grid; place-items: center; border-radius: 8px; color: var(--purple); background: var(--purple-soft); font-size: 10px; font-weight: 800; }
.simulation-form { display: grid; gap: 19px; padding: 21px 23px 23px; }
.simulation-field { display: grid; gap: 6px; min-width: 0; color: #626b7c; font-size: 10px; font-weight: 700; }
.simulation-field > input, .simulation-field > select { width: 100%; height: 40px; padding: 0 11px; font-size: 12px; }
.simulation-field > small { color: #959cab; font-size: 8px; font-weight: 500; }
.simulation-cart-items { display: grid; gap: 8px; }
.simulation-cart-empty { min-height: 72px; display: flex; align-items: center; justify-content: center; gap: 10px; padding: 14px; border: 1px dashed #dfe2ea; border-radius: 9px; color: #8d94a3; background: #fafbfc; }
.simulation-cart-empty span { width: 26px; height: 26px; display: grid; place-items: center; flex: 0 0 auto; border-radius: 7px; color: var(--purple); background: var(--purple-soft); }
.simulation-cart-empty p { max-width: 340px; margin: 0; font-size: 9px; line-height: 1.45; }
.simulation-cart-line { display: grid; grid-template-columns: 52px minmax(0, 1fr) 74px 26px; align-items: start; gap: 10px; padding: 10px; border: 1px solid #e7e9ef; border-radius: 10px; background: #fafbfc; }
.simulation-product-copy { min-width: 0; }
.simulation-product-copy > b { display: block; overflow: hidden; margin-bottom: 6px; font-size: 10px; text-overflow: ellipsis; white-space: nowrap; }
.simulation-product-copy label, .quantity-field { display: grid; gap: 4px; color: #8a91a0; font-size: 8px; font-weight: 650; }
.simulation-product-copy select, .simulation-product-copy input { width: 100%; height: 31px; min-width: 0; padding: 0 25px 0 8px; font-size: 9px; }
.platform-id-field { margin-top: 7px; }
.add-variant-button { min-height: 26px; margin-top: 6px; padding: 0; border: 0; color: var(--purple); background: transparent; font-size: 8px; font-weight: 750; text-align: left; }
.add-variant-button:hover { color: var(--purple-dark); text-decoration: underline; }
.quantity-field input { width: 100%; height: 31px; min-width: 0; padding: 0 7px; font-size: 10px; }
.simulation-line-error { margin: 0; color: var(--red); font-size: 8px; }
.remove-cart-item { width: 26px; height: 26px; padding: 0; border: 0; border-radius: 6px; color: #9da3ae; background: transparent; font-size: 16px; }
.remove-cart-item:hover { color: var(--red); background: var(--red-soft); }
.simulation-submit-row { display: flex; align-items: center; justify-content: space-between; gap: 15px; padding-top: 17px; border-top: 1px solid var(--line); }
.simulation-submit-row > span { color: #8991a1; font-size: 9px; }
.simulation-submit-row button:disabled { cursor: not-allowed; opacity: .55; }
.simulation-results { min-height: 440px; padding: 20px 22px 22px; }
.simulation-placeholder, .simulation-loading, .simulation-error-state, .no-quotes { min-height: 310px; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 35px 20px; text-align: center; }
.simulation-placeholder > span, .simulation-error-state > span, .no-quotes > span { width: 48px; height: 48px; display: grid; place-items: center; border-radius: 13px; color: var(--purple); background: var(--purple-soft); font-size: 18px; }
.simulation-placeholder h3, .simulation-loading h3, .simulation-error-state h3, .no-quotes h3 { margin: 13px 0 5px; font-size: 14px; }
.simulation-placeholder p, .simulation-loading p, .simulation-error-state p, .no-quotes p { max-width: 330px; margin: 0; color: var(--muted); font-size: 10px; line-height: 1.5; }
.simulation-loading { min-height: 380px; }
.simulation-loading i { width: 28px; height: 28px; border-width: 3px; }
.simulation-error-state > span { color: var(--red); background: var(--red-soft); }
.quote-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.quote-card { padding: 16px; border: 1px solid #e3e6ed; border-radius: 11px; background: #fafbfc; }
.quote-card.PAC { border-top: 3px solid #4e7ac2; }
.quote-card.SEDEX { border-top: 3px solid #e18a4d; }
.quote-service { display: flex; align-items: center; gap: 8px; }
.quote-service > span { width: 29px; height: 29px; display: grid; place-items: center; border-radius: 8px; color: #4e6ba8; background: #edf3ff; font-size: 12px; }
.quote-service small { display: block; color: #9aa1ae; font-size: 7px; letter-spacing: .8px; }
.quote-service b { font-size: 10px; }
.checkout-price-label { display: block; margin-top: 13px; color: #9aa1ae; font-size: 6px; font-weight: 750; letter-spacing: .65px; }
.quote-card > strong { display: block; margin: 2px 0 3px; font-size: 20px; letter-spacing: -.5px; }
.quote-card > p { margin: 0 0 12px; color: #757e8f; font-size: 9px; }
.allowed-badge { color: var(--green); font-size: 8px; font-weight: 750; }
.quote-cost-breakdown { display: grid; gap: 5px; margin: 0 0 12px; padding: 9px; border-radius: 8px; background: white; }
.quote-cost-breakdown > div { display: flex; justify-content: space-between; gap: 10px; color: #7b8392; font-size: 7px; }
.quote-cost-breakdown dt, .quote-cost-breakdown dd { margin: 0; }
.quote-cost-breakdown dd { color: #4f586a; font-weight: 750; }
.quote-cost-breakdown .operational-total { margin-top: 2px; padding-top: 6px; border-top: 1px solid #eceef2; color: var(--ink); font-size: 8px; font-weight: 750; }
.quote-cost-breakdown .checkout-total { color: var(--green); font-size: 8px; font-weight: 750; }
.quote-pricing-weight { margin: 0 0 9px; padding: 9px; border: 1px solid #e6e3f7; border-radius: 8px; background: #faf9ff; }
.pricing-weight-heading { display: flex; align-items: center; gap: 7px; }
.pricing-weight-heading > span { width: 25px; height: 25px; display: grid; place-items: center; flex: 0 0 auto; border-radius: 7px; color: var(--purple); background: white; font-size: 7px; font-weight: 850; }
.pricing-weight-heading p { display: grid; gap: 1px; margin: 0; }
.pricing-weight-heading small { color: #9891b5; font-size: 6px; font-weight: 750; letter-spacing: .55px; }
.pricing-weight-heading b { color: #4f476f; font-size: 9px; }
.quote-pricing-weight dl { display: grid; grid-template-columns: repeat(3, 1fr); gap: 5px; margin: 8px 0 0; }
.quote-pricing-weight dl div { display: grid; gap: 2px; min-width: 0; }
.quote-pricing-weight dt, .quote-pricing-weight dd { margin: 0; }
.quote-pricing-weight dt { color: #9992ae; font-size: 6px; }
.quote-pricing-weight dd { overflow: hidden; color: #5d557a; font-size: 7px; font-weight: 750; text-overflow: ellipsis; white-space: nowrap; }
.simulation-package-summary { display: grid; grid-template-columns: 34px minmax(0, 1fr) auto; align-items: center; gap: 10px; margin-bottom: 12px; padding: 10px 12px; border: 1px solid #e6e3f7; border-radius: 9px; background: #faf9ff; }
.simulation-package-summary > span { width: 34px; height: 34px; display: grid; place-items: center; border-radius: 8px; color: var(--purple); background: var(--purple-soft); font-size: 13px; }
.simulation-package-summary p { min-width: 0; display: grid; gap: 3px; margin: 0; }
.simulation-package-summary b { overflow: hidden; font-size: 9px; text-overflow: ellipsis; white-space: nowrap; }
.simulation-package-summary small { color: #858d9d; font-size: 7px; line-height: 1.4; }
.simulation-package-summary > strong { color: var(--purple); font-size: 10px; }
.simulation-package-summary.none { border-color: #e7e9ef; background: #fafbfc; }
.simulation-package-comparison { margin-top: 16px; padding-top: 16px; border-top: 1px solid var(--line); }
.simulation-package-comparison h3 { margin: 2px 0 11px; font-size: 12px; }
.simulation-comparison-table-wrap { overflow-x: auto; }
.simulation-package-comparison table { min-width: 690px; width: 100%; border-collapse: collapse; }
.simulation-package-comparison th, .simulation-package-comparison td { padding: 10px; border-top: 1px solid #eceef2; color: #5d6677; font-size: 8px; text-align: left; vertical-align: top; }
.simulation-package-comparison thead th { border-top: 0; color: #8b93a2; background: #fafbfc; font-size: 7px; text-transform: uppercase; }
.simulation-package-comparison thead th:first-child { width: 28%; }
.simulation-package-comparison tbody th b, .simulation-package-comparison tbody th small { display: block; }
.simulation-package-comparison tbody th b { color: var(--ink); font-size: 8px; }
.simulation-package-comparison tbody th small { margin-top: 4px; color: #939aa8; font-size: 6px; font-weight: 500; line-height: 1.65; }
.comparison-service-cell { display: grid; gap: 2px; min-width: 190px; }
.comparison-price-label { color: #9a91b9; font-size: 6px; font-weight: 800; letter-spacing: .45px; }
.comparison-service-cell > strong { color: var(--ink); font-size: 11px; }
.comparison-deadline { color: #7d8594; font-size: 7px; }
.comparison-service-cell dl { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 5px; margin: 7px 0 0; }
.comparison-service-cell dl div { min-width: 0; padding: 6px; border-radius: 6px; background: #faf9ff; }
.comparison-service-cell dt, .comparison-service-cell dd { margin: 0; }
.comparison-service-cell dt { color: #9992ae; font-size: 6px; }
.comparison-service-cell dd { margin-top: 2px; overflow: hidden; color: #5d557a; font-size: 7px; font-weight: 750; text-overflow: ellipsis; white-space: nowrap; }
.comparison-service-cell .comparison-weight-band { grid-column: 1 / -1; }
.comparison-unavailable { display: inline-block; padding: 6px 8px; border-radius: 6px; color: #8e96a5; background: #f5f6f8; font-size: 7px; font-weight: 700; }
.comparison-error { color: var(--red) !important; }
.no-quotes { min-height: 190px; padding-block: 20px; }
.simulation-audit { margin-top: 16px; padding-top: 16px; border-top: 1px solid var(--line); }
.audit-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.audit-heading h3 { margin: 2px 0 0; font-size: 13px; }
.audit-heading > span { min-width: 25px; height: 25px; display: grid; place-items: center; border-radius: 7px; color: var(--purple); background: var(--purple-soft); font-size: 9px; font-weight: 750; }
.applied-rule-list { display: grid; gap: 6px; margin: 12px 0; padding: 0; list-style: none; }
.applied-rule-list li { display: flex; align-items: center; gap: 8px; padding: 9px; border-radius: 8px; color: #50596b; background: #f7f7fa; font-size: 9px; }
.applied-rule-list li span { color: var(--purple); }
.audit-empty { margin: 12px 0; color: #8d94a3; font-size: 9px; }
.audit-metrics { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; margin-top: 11px; }
.audit-metrics span { display: grid; gap: 2px; padding: 8px; border-radius: 7px; color: #8991a0; background: #fafbfc; font-size: 7px; text-align: center; }
.audit-metrics b { color: var(--ink); font-size: 12px; }
.removed-services { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; margin-top: 11px; color: #8b92a0; font-size: 8px; }
.simulation-warnings { margin-top: 12px; padding: 10px; border-radius: 8px; color: #7c6545; background: #fff8e9; font-size: 8px; }
.simulation-warnings > b { display: block; margin-bottom: 6px; }
.simulation-warnings p { display: flex; gap: 7px; margin: 4px 0; line-height: 1.4; }
.simulation-warnings p span { font-weight: 800; }

.packages-intro { align-items: center; }
.package-stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin-bottom: 18px; }
.package-stats .stat-card { min-width: 0; }
.package-stats #defaultPackageName { max-width: 210px; overflow: hidden; font-size: 15px; text-overflow: ellipsis; white-space: nowrap; }
.quotation-settings-panel { margin-bottom: 18px; overflow: hidden; }
.configuration-badge { padding: 5px 9px; border-radius: 99px; color: var(--green); background: var(--green-soft); font-size: 9px; font-weight: 750; }
.quotation-settings-copy { display: grid; grid-template-columns: 42px minmax(0, 1fr) minmax(250px, .75fr); align-items: center; gap: 13px; padding: 18px 22px; }
.quotation-settings-copy > div:nth-child(2) > b { display: block; margin-bottom: 4px; font-size: 11px; }
.quotation-settings-copy > div:nth-child(2) > p { margin: 0; color: var(--muted); font-size: 9px; line-height: 1.55; }
.cost-separation-note { display: flex; align-items: center; gap: 9px; padding: 11px 12px; border-radius: 9px; color: #6f5c38; background: #fff8e9; }
.cost-separation-note > span { width: 28px; height: 28px; display: grid; place-items: center; flex: 0 0 auto; border-radius: 8px; color: var(--amber); background: white; font-size: 9px; font-weight: 800; }
.cost-separation-note p { display: grid; gap: 2px; margin: 0; }
.cost-separation-note b { font-size: 9px; }
.cost-separation-note small { color: #8c7956; font-size: 8px; line-height: 1.4; }
.packaging-cost-option { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 12px; padding: 0 22px 20px; }
.packaging-cost-option .shipping-option-card { border-color: #e6e3f7; background: #faf9ff; }
.packaging-cost-option > button { min-height: 38px; font-size: 10px; }
.packages-layout { display: grid; grid-template-columns: minmax(0, 1.55fr) minmax(315px, .7fr); align-items: start; gap: 18px; }
.package-catalog-panel, .shipping-options-panel, .package-comparison-panel { overflow: hidden; }
.comparison-counter { padding: 5px 8px; border-radius: 7px; color: var(--purple); background: var(--purple-soft); font-size: 9px; font-weight: 750; }
.package-list { padding: 5px 21px 13px; }
.package-row { display: grid; grid-template-columns: 24px 46px minmax(0, 1fr) auto; align-items: center; gap: 12px; padding: 15px 2px; border-bottom: 1px solid #eff0f4; transition: .16s ease; }
.package-row:last-child { border-bottom: 0; }
.package-row.disabled { opacity: .66; }
.package-compare-check { position: relative; width: 20px; height: 20px; cursor: pointer; }
.package-compare-check input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.package-compare-check > span:not(.sr-only) { width: 20px; height: 20px; display: grid; place-items: center; border: 1px solid #d8dbe4; border-radius: 6px; color: transparent; background: white; font-size: 9px; font-weight: 800; }
.package-compare-check input:checked + span { color: white; border-color: var(--purple); background: var(--purple); }
.package-compare-check input:focus-visible + span { outline: 3px solid rgba(109,92,231,.16); outline-offset: 2px; }
.package-visual { position: relative; width: 46px; height: 46px; display: grid; place-items: center; overflow: hidden; border-radius: 11px; color: #6658c0; background: linear-gradient(145deg, #f2efff, #e6e2ff); }
.package-visual i { position: absolute; width: 24px; height: 18px; border: 1px solid rgba(100,84,190,.22); transform: skewY(-12deg); }
.package-visual b { position: relative; font-size: 17px; }
.package-row-copy { min-width: 0; }
.package-name-line { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; }
.package-name-line > b { overflow: hidden; font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.default-badge, .inactive-badge { padding: 3px 6px; border-radius: 99px; font-size: 7px; font-weight: 800; text-transform: uppercase; }
.default-badge { color: #9b671a; background: var(--amber-soft); }
.inactive-badge { color: #777f8f; background: #eef0f3; }
.package-specs { display: flex; flex-wrap: wrap; gap: 15px; margin-top: 7px; }
.package-specs span { display: grid; gap: 2px; }
.package-specs small { color: #9ba2af; font-size: 7px; }
.package-specs b { color: #596275; font-size: 8px; font-weight: 700; }
.package-row-controls { display: flex; align-items: center; justify-content: flex-end; flex-wrap: wrap; gap: 5px; }
.package-row-controls .default-button { display: inline-flex; align-items: center; gap: 5px; color: #986418; background: var(--amber-soft); font-size: 8px; font-weight: 750; }
.package-empty { padding-block: 46px; }
.package-empty button { margin-top: 15px; }
.shipping-options-form { display: grid; gap: 10px; padding: 17px 19px 19px; }
.shipping-option-card { min-width: 0; display: grid !important; grid-template-columns: 38px minmax(0, 1fr) 38px; align-items: center; gap: 11px !important; padding: 13px !important; border: 1px solid #e6e8ee; border-radius: 10px; color: inherit !important; background: #fafbfc; cursor: pointer; }
.shipping-option-icon { width: 38px; height: 38px; display: grid; place-items: center; border-radius: 10px; color: var(--purple); background: var(--purple-soft); font-size: 14px; font-weight: 800; }
.shipping-option-icon.correios { color: #2863a0; background: #eaf3ff; font-size: 10px; }
.shipping-option-card > span:nth-child(2) { min-width: 0; display: grid; gap: 4px; }
.shipping-option-card b { font-size: 10px; }
.shipping-option-card small { color: var(--muted); font-size: 8px; font-weight: 500; line-height: 1.45; }
.shipping-option-card em { width: fit-content; padding: 3px 6px; border-radius: 99px; color: #647087; background: white; font-size: 7px; font-style: normal; font-weight: 700; }
.option-toggle { position: relative; width: 34px; height: 19px; }
.option-toggle .switch { display: block; }
.option-toggle input { position: absolute; width: 1px !important; height: 1px !important; opacity: 0; }
.option-toggle input:checked + .switch { background: var(--green); }
.option-toggle input:checked + .switch::after { transform: translateX(15px); }
.option-toggle input:focus-visible + .switch { outline: 3px solid rgba(109,92,231,.16); outline-offset: 2px; }
.shipping-options-actions { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding-top: 6px; }
.shipping-options-actions small { color: #8e96a5; font-size: 8px; line-height: 1.4; }
.shipping-options-actions button { min-height: 36px; flex: 0 0 auto; font-size: 10px; }
.package-comparison-panel { margin-top: 18px; }
.package-comparison { min-height: 145px; }
.comparison-placeholder { min-height: 145px; display: flex; align-items: center; justify-content: center; gap: 10px; padding: 24px; color: #8a92a1; text-align: center; }
.comparison-placeholder span { width: 34px; height: 34px; display: grid; place-items: center; flex: 0 0 auto; border-radius: 9px; color: var(--purple); background: var(--purple-soft); font-size: 14px; }
.comparison-placeholder p { margin: 0; font-size: 9px; }
.comparison-table-wrap { overflow-x: auto; }
.comparison-table { min-width: 640px; width: 100%; border-collapse: collapse; }
.comparison-table th, .comparison-table td { padding: 12px 16px; border-top: 1px solid #eff0f4; color: #596275; font-size: 9px; text-align: left; }
.comparison-table thead th { border-top: 0; color: var(--ink); background: #fafbfc; font-size: 10px; }
.comparison-table th:first-child { width: 190px; color: #8b93a2; font-weight: 650; }
.comparison-table thead th small { display: block; margin-top: 3px; color: var(--amber); font-size: 7px; }
.comparison-quote-note { display: flex; align-items: center; gap: 8px; padding: 10px 16px; color: #5c6290; background: #f6f5ff; }
.comparison-quote-note span { width: 24px; height: 24px; display: grid; place-items: center; flex: 0 0 auto; border-radius: 7px; color: var(--purple); background: white; }
.comparison-quote-note p { margin: 0; font-size: 8px; }
.package-modal { width: min(94vw, 650px); }
.package-modal form { padding: 0 28px 24px; }
.package-form-intro { margin: 17px 0 0; color: var(--muted); font-size: 10px; line-height: 1.5; }
.package-form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; padding: 18px 0; }
.package-form-grid .wide { grid-column: 1 / -1; }
.package-form-grid label > small { color: #959cab; font-size: 8px; font-weight: 500; }
.package-weight-band-field select { color: var(--ink); background-color: #fbfaff; border-color: #dcd7f6; font-weight: 700; }
.package-weight-band-field select:invalid { color: #9399a7; font-weight: 500; }
.package-weight-band-field select option { color: var(--ink); font-weight: 500; }
.package-weight-band-field select optgroup { color: #6557bf; font-weight: 750; }
.package-weight-band-field small { line-height: 1.45; }
.package-form-options { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin-bottom: 19px; }
.package-form-options .switch-label { padding: 12px; border: 1px solid #e4e6ec; border-radius: 9px; background: #fafbfc; }
.package-form-options .switch-label > span:last-child { display: grid; gap: 2px; }
.package-form-options small { color: #8d95a4; font-size: 7px; font-weight: 500; line-height: 1.35; }
.package-form-footer > span { color: #9299a8; font-size: 8px; }

.integration-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px; }
.integration-card { min-height: 250px; display: grid; grid-template-columns: 62px 1fr; gap: 18px; padding: 26px; border: 1px solid var(--line); border-radius: 13px; background: white; box-shadow: var(--shadow); }
.integration-logo { width: 56px; height: 56px; display: grid; place-items: center; border-radius: 14px; font-size: 22px; font-weight: 850; }
.yampi-logo { color: #6453d7; background: #eeeaff; }
.correios-logo { color: #2665a8; background: #e8f3ff; }
.integration-copy > div:first-child { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.integration-copy h3 { margin: 2px 0; font-size: 17px; }
.integration-copy p { min-height: 45px; margin: 13px 0 20px; color: var(--muted); font-size: 11px; line-height: 1.55; }
.connection-badge { padding: 4px 8px; border-radius: 99px; color: var(--amber); background: var(--amber-soft); font-size: 9px; font-weight: 750; }
.connection-badge.ok { color: var(--green); background: var(--green-soft); }
.connection-badge.error { color: #a33d4f; background: #fff0f3; }
.vault-pill { padding: 6px 10px; border-radius: 99px; color: var(--amber); background: var(--amber-soft); font-size: 9px; font-weight: 750; }
.vault-pill.ok { color: var(--green); background: var(--green-soft); }
.integration-copy dl { margin: 0; border-top: 1px solid #edf0f4; }
.integration-copy dl div { display: flex; justify-content: space-between; gap: 20px; padding: 11px 0; border-bottom: 1px solid #edf0f4; }
.integration-copy dt { color: #9299a8; font-size: 10px; }
.integration-copy dd { margin: 0; color: #4e5769; font-size: 10px; font-weight: 650; }
.credentials-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; margin-top: 18px; }
.credentials-panel { overflow: hidden; }
.credentials-heading { min-height: 96px; display: flex; align-items: center; gap: 15px; padding: 20px 22px; border-bottom: 1px solid var(--line); }
.credentials-heading .integration-logo { flex: 0 0 46px; width: 46px; height: 46px; font-size: 18px; }
.credentials-heading h3 { margin: 2px 0 3px; font-size: 15px; }
.credentials-heading p { margin: 0; color: var(--muted); font-size: 9px; }
.credentials-form { padding: 21px 22px 22px; }
.credential-fields { display: grid; gap: 13px; }
.credential-fields.two-columns { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.credential-fields .wide { grid-column: 1 / -1; }
.credential-fields label { display: grid; gap: 6px; min-width: 0; color: #626b7c; font-size: 9px; font-weight: 700; }
.credential-fields input, .credential-fields select { width: 100%; height: 38px; min-width: 0; padding: 0 10px; font-size: 10px; }
.credential-fields label > small { color: #959cab; font-size: 8px; font-weight: 500; line-height: 1.4; }
.service-code-pair { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.advanced-fields { margin-top: 15px; padding: 12px 13px; border: 1px solid #e6e8ee; border-radius: 9px; background: #fafbfc; }
.advanced-fields summary { color: #677084; font-size: 9px; font-weight: 700; cursor: pointer; }
.advanced-fields[open] summary { margin-bottom: 12px; }
.contract-note { display: flex; align-items: flex-start; gap: 9px; margin-top: 14px; padding: 11px 12px; border-radius: 8px; color: #6e6549; background: #fff9e9; }
.contract-note span { flex: 0 0 18px; height: 18px; display: grid; place-items: center; border-radius: 50%; color: var(--amber); background: white; font-size: 8px; font-weight: 800; }
.contract-note p { margin: 1px 0 0; font-size: 8px; line-height: 1.45; }
.credential-test-result { margin-top: 14px; padding: 11px 12px; border: 1px solid #e1e4eb; border-radius: 8px; color: #586174; background: #f7f8fa; font-size: 9px; font-weight: 650; line-height: 1.5; }
.credential-test-result.success { border-color: #cce9d9; color: #157348; background: #effaf4; }
.credential-test-result.error { border-color: #f1ccd4; color: #9e3045; background: #fff3f5; }
.credential-test-result.pending { border-color: #e5defb; color: #6557bf; background: #f7f4ff; }
.credentials-actions { display: flex; justify-content: flex-end; flex-wrap: wrap; gap: 8px; margin-top: 18px; padding-top: 17px; border-top: 1px solid var(--line); }
.credentials-actions button { min-height: 36px; padding-inline: 12px; font-size: 10px; }
.credentials-actions .danger-button { margin-right: auto; }
.security-note { display: flex; gap: 13px; margin-top: 18px; padding: 18px 20px; }
.security-note > span { width: 26px; height: 26px; display: grid; place-items: center; border-radius: 50%; color: var(--purple); background: var(--purple-soft); font-size: 12px; font-weight: 800; }
.security-note h3 { margin: 1px 0 3px; font-size: 12px; }
.security-note p { margin: 0; color: var(--muted); font-size: 10px; }

.modal { width: min(94vw, 680px); max-height: 90vh; padding: 0; overflow-x: hidden; overflow-y: auto; border: 0; border-radius: 15px; color: var(--ink); background: white; box-shadow: 0 28px 90px rgba(17,24,39,.25); }
.modal::backdrop { background: rgba(17,24,39,.55); backdrop-filter: blur(3px); }
.auth-modal { width: min(92vw, 430px); text-align: center; }
.auth-modal form { padding: 38px; }
.modal-symbol { width: 50px; height: 50px; display: grid; place-items: center; margin: 0 auto 18px; border-radius: 14px; color: white; background: linear-gradient(145deg,#7b69ef,#5543c7); font-size: 21px; }
.auth-modal h2 { margin: 8px 0; font-size: 22px; }
.auth-modal p { margin: 0 0 22px; color: var(--muted); font-size: 11px; line-height: 1.55; }
.auth-modal code { color: var(--purple); }
.auth-modal label + label { margin-top: 12px; }

body.auth-pending .app-shell, body.auth-required .app-shell { display: none; }
.auth-screen[hidden] { display: none; }
.auth-screen { min-height: 100vh; display: grid; grid-template-columns: minmax(360px, .82fr) minmax(520px, 1.18fr); color: #17191e; background: #f4f4f1; }
.auth-brand-panel { min-height: 100vh; display: flex; flex-direction: column; justify-content: space-between; padding: clamp(38px, 5vw, 72px); color: #fff; background: #05070b; position: relative; overflow: hidden; }
.auth-brand-panel::after { content: ""; position: absolute; right: -180px; bottom: 14%; width: 420px; height: 420px; border: 1px solid rgba(235,255,64,.14); border-radius: 50%; box-shadow: 0 0 0 70px rgba(235,255,64,.025), 0 0 0 140px rgba(235,255,64,.018); }
.auth-brand-panel > * { position: relative; z-index: 1; }
.auth-brand-panel > img { width: min(190px, 48%); height: auto; }
.auth-brand-panel > div { max-width: 470px; display: grid; gap: 18px; }
.auth-brand-panel > div > span, .auth-brand-panel > small { color: #ddec45; font-size: 9px; font-weight: 800; letter-spacing: 2.4px; }
.auth-brand-panel h1 { margin: 0; font-size: clamp(34px, 4.2vw, 64px); font-weight: 350; letter-spacing: -2.4px; line-height: 1.02; }
.auth-brand-panel p { max-width: 420px; margin: 0; color: #9ca1aa; font-size: 13px; line-height: 1.65; }
.auth-main-panel { min-height: 100vh; display: grid; grid-template-rows: 1fr auto; place-items: center; padding: 46px clamp(28px, 7vw, 110px) 28px; }
.auth-card { width: min(100%, 470px); }
.auth-mobile-brand { display: none; }
.auth-tabs { display: grid; grid-template-columns: 1fr 1fr; margin-bottom: 42px; border-bottom: 1px solid #d9d9d4; }
.auth-tabs button { min-height: 46px; border: 0; border-bottom: 2px solid transparent; color: #8b8d91; background: transparent; font: inherit; font-size: 10px; font-weight: 800; letter-spacing: 1px; text-transform: uppercase; cursor: pointer; }
.auth-tabs button.active { color: #111; border-bottom-color: #111; }
.auth-page-form { display: grid; gap: 15px; }
.auth-page-form[hidden] { display: none; }
.auth-page-form h2 { margin: 0; font-size: 32px; font-weight: 450; letter-spacing: -1.1px; }
.auth-page-form > p:not(.form-error) { margin: -6px 0 16px; color: #74777f; font-size: 11px; line-height: 1.6; }
.auth-page-form label { display: grid; gap: 7px; color: #555a65; font-size: 9px; font-weight: 750; letter-spacing: .2px; }
.auth-page-form input { min-height: 50px; border: 1px solid #d7d8d4; background: #fff; padding: 0 15px; color: #15171b; font: inherit; outline: none; transition: border-color .2s, box-shadow .2s; }
.auth-page-form input:focus { border-color: #111; box-shadow: 0 0 0 3px rgba(0,0,0,.05); }
.auth-page-form .primary-button { min-height: 50px; margin-top: 4px; }
.auth-page-form .form-error { min-height: 16px; margin: -2px 0; color: var(--red); font-size: 9px; text-align: left; }
.auth-help { margin-top: 6px; color: #898c92; font-size: 9px; line-height: 1.5; text-align: center; }
.auth-main-panel footer { color: #999b9f; font-size: 8px; letter-spacing: .8px; text-transform: uppercase; }

.sidebar-user { min-width: 0; display: flex; align-items: center; gap: 10px; }
.sidebar-user-avatar, .team-user-avatar { flex: 0 0 auto; display: grid; place-items: center; color: #111; background: var(--accent); border: 1px solid rgba(255,255,255,.18); font-weight: 800; letter-spacing: .4px; }
.sidebar-user-avatar { width: 30px; height: 30px; font-size: 9px; }
.sidebar-user > span:last-child { min-width: 0; display: grid; gap: 2px; }
.sidebar-user b { overflow: hidden; color: #fff; font-size: 10px; text-overflow: ellipsis; white-space: nowrap; }
.sidebar-user small { color: #818181; font-size: 8px; }

.team-access-panel { margin-bottom: 18px; padding: 22px; }
.team-access-panel .panel-heading p { margin: 5px 0 0; color: var(--muted); font-size: 10px; }
.team-user-form { display: grid; grid-template-columns: minmax(180px,1.2fr) minmax(150px,1fr) 150px minmax(190px,1fr) auto; align-items: end; gap: 10px; padding: 18px 0; border-bottom: 1px solid var(--line); }
.team-user-form label { display: grid; gap: 6px; color: #626b7c; font-size: 9px; font-weight: 700; }
.team-user-form input, .team-user-form select, .team-user-row select { min-height: 38px; border: 1px solid var(--line); background: #fff; padding: 0 11px; color: #1a1d24; font: inherit; }
.team-user-list { display: grid; }
.team-user-row { display: grid; grid-template-columns: 38px minmax(180px,1fr) 160px 100px; align-items: center; gap: 12px; min-height: 68px; border-bottom: 1px solid var(--line); }
.team-user-row:last-child { border-bottom: 0; }
.team-user-row.inactive { opacity: .48; }
.team-user-avatar { width: 34px; height: 34px; font-size: 9px; }
.team-user-identity { display: grid; gap: 4px; }
.team-user-identity b { font-size: 11px; }
.team-user-identity small { color: var(--muted); font-size: 9px; }
.modal label { display: grid; gap: 7px; color: #626b7c; font-size: 10px; font-weight: 650; text-align: left; }
.modal input, .modal select { width: 100%; height: 40px; padding: 0 11px; font-size: 12px; }
.manual-label-modal { width: min(94vw, 760px); border-radius: 0; }
.manual-label-modal form { padding: 0 28px 24px; }
.manual-label-intro { margin: 20px 0; color: #6e7178; font-size: 11px; line-height: 1.6; }
.manual-label-search-row { display: grid; grid-template-columns: minmax(0,1fr) auto; align-items: end; gap: 10px; }
.manual-label-search-row button { min-height: 40px; }
.manual-label-results { max-height: 260px; margin-top: 14px; overflow-y: auto; border: 1px solid #e3e3df; }
.manual-label-results > p { margin: 0; padding: 24px; color: #85878c; font-size: 10px; text-align: center; }
.manual-label-result { width: 100%; min-height: 64px; display: grid; grid-template-columns: 1fr minmax(140px,.55fr); gap: 14px; padding: 12px 14px; border: 0; border-bottom: 1px solid #ecece8; color: #171717; background: #fff; font: inherit; text-align: left; cursor: pointer; }
.manual-label-result:last-child { border-bottom: 0; }
.manual-label-result:hover, .manual-label-result.active { background: #fbffd7; box-shadow: inset 3px 0 #111; }
.manual-label-result span { min-width: 0; display: grid; gap: 4px; }
.manual-label-result b { overflow: hidden; font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.manual-label-result small { overflow: hidden; color: #85878c; font-size: 9px; text-overflow: ellipsis; white-space: nowrap; }
.manual-label-selection { margin-top: 16px; border: 1px solid #deded9; }
.manual-label-selected-order { display: grid; grid-template-columns: 1fr 1fr; background: #f4f4f1; }
.manual-label-selected-order > div { display: grid; gap: 4px; padding: 15px; border-right: 1px solid #deded9; }
.manual-label-selected-order > div:last-child { border-right: 0; }
.manual-label-selected-order span { color: #87898d; font-size: 8px; font-weight: 800; letter-spacing: 1.2px; }
.manual-label-selected-order strong { font-size: 13px; }
.manual-label-selected-order small { color: #73767c; font-size: 9px; }
.manual-label-pieces-section { border-top: 1px solid #deded9; background: #fff; }
.manual-label-pieces-section > header { display: flex; align-items: end; justify-content: space-between; gap: 16px; padding: 15px 16px 10px; }
.manual-label-pieces-section > header > div { display: grid; gap: 4px; }
.manual-label-pieces-section > header span { color: #777a7f; font-size: 8px; font-weight: 800; letter-spacing: 1.2px; }
.manual-label-pieces-section > header strong { font-size: 10px; }
.manual-label-pieces-section > header small { color: #62656a; font-size: 9px; white-space: nowrap; }
.manual-label-pieces { max-height: 250px; display: grid; gap: 7px; overflow-y: auto; padding: 0 16px 16px; }
.manual-label-piece { position: relative; min-height: 62px; display: grid !important; grid-template-columns: 22px 42px minmax(0,1fr); align-items: center; gap: 10px !important; padding: 8px 10px !important; border: 1px solid #deded9; background: #f8f8f6; cursor: pointer; }
.manual-label-piece.is-selected { border-color: #171717; background: #fbffd7; }
.manual-label-piece > input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.manual-label-piece-check { width: 20px; height: 20px; display: grid; place-items: center; border: 1px solid #aaa; color: transparent; background: #fff; font-size: 10px; font-weight: 900; }
.manual-label-piece.is-selected .manual-label-piece-check { border-color: #111; color: #fff; background: #111; }
.manual-label-piece-thumb { width: 42px; height: 46px; display: grid; place-items: center; overflow: hidden; border: 1px solid #e3e3df; color: #777; background: #fff; font-size: 9px; font-weight: 800; }
.manual-label-piece-thumb img { width: 100%; height: 100%; object-fit: contain; }
.manual-label-piece-copy { min-width: 0; display: grid; gap: 3px; }
.manual-label-piece-copy b { overflow: hidden; color: #171717; font-size: 10px; text-overflow: ellipsis; white-space: nowrap; }
.manual-label-piece-copy small { color: #62656a; font-size: 9px; }
.manual-label-piece-copy em { color: #777a7f; font-size: 8px; font-style: normal; }
.manual-label-pieces-empty { margin: 0; padding: 18px; color: #85878c; background: #f6f6f3; font-size: 9px; text-align: center; }
.manual-label-route { display: grid; grid-template-columns: 1fr auto 1fr; gap: 12px; align-items: stretch; padding: 16px; border-top: 1px solid #deded9; background: #fff; }
.manual-label-route-card { min-width: 0; display: grid; align-content: start; gap: 4px; padding: 12px; border: 1px solid #deded9; }
.manual-label-route-card span { color: #777a7f; font-size: 8px; font-weight: 800; letter-spacing: 1.2px; }
.manual-label-route-card strong { font-size: 11px; }
.manual-label-route-card small { color: #62656a; font-size: 9px; line-height: 1.5; }
.manual-label-route-arrow { align-self: center; color: #151515; font-size: 20px; font-weight: 800; }
.manual-label-options { display: grid; grid-template-columns: 1fr 1.5fr; gap: 12px; padding: 16px; }
.reverse-label-options { display: grid; grid-template-columns: .75fr 1.25fr .85fr; gap: 12px; padding: 16px; }
.reverse-label-options label small { display: block; margin-top: 5px; color: #85878c; font-size: 8px; }
.reverse-label-issued { margin-top: 16px; padding: 18px; border: 1px solid #171717; background: #fbffd7; }
.reverse-label-issued span { display: block; margin-bottom: 6px; color: #777a7f; font-size: 8px; font-weight: 800; letter-spacing: 1.2px; }
.reverse-label-issued strong { display: block; font-size: 20px; }
.reverse-label-issued small { display: block; margin: 6px 0 14px; color: #62656a; font-size: 9px; }
.reverse-label-history { padding: 0 16px 16px; }
.reverse-label-history > span { display: block; margin-bottom: 8px; color: #777a7f; font-size: 8px; font-weight: 800; letter-spacing: 1.2px; }
.reverse-label-history-empty { margin: 0; padding: 12px; color: #85878c; background: #f6f6f3; font-size: 9px; }
.reverse-label-history-list { display: grid; gap: 8px; }
.reverse-label-history-item { display: grid; grid-template-columns: minmax(0,1fr) auto; gap: 12px; align-items: center; padding: 12px; border: 1px solid #deded9; background: #fff; }
.reverse-label-history-item strong, .reverse-label-history-item small { display: block; }
.reverse-label-history-item strong { font-size: 13px; }
.reverse-label-history-item small { margin-top: 4px; color: #73767c; font-size: 8px; }
.reverse-label-history-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 6px; }
.reverse-label-history-actions button, .reverse-label-history-actions a { min-height: 32px; padding: 8px 10px; font-size: 8px; }
.manual-label-warning { margin: 0 16px 16px; padding: 12px; border: 1px solid #e2df9a; color: #615c18; background: #fffedb; font-size: 9px; line-height: 1.55; }
.manual-label-footer { margin-top: 18px; }
@media (max-width: 680px) {
  .manual-label-modal { width: 100vw; max-height: 100vh; margin: 0; }
  .manual-label-modal form { padding-inline: 18px; }
  .manual-label-search-row, .manual-label-options, .reverse-label-options, .manual-label-selected-order { grid-template-columns: 1fr; }
  .manual-label-route { grid-template-columns: 1fr; }
  .manual-label-route-arrow { justify-self: center; transform: rotate(90deg); }
  .manual-label-selected-order > div { border-right: 0; border-bottom: 1px solid #deded9; }
  .manual-label-result { grid-template-columns: 1fr; }
  .manual-label-pieces-section > header { align-items: start; flex-direction: column; gap: 7px; }
  .reverse-label-history-item { grid-template-columns: 1fr; }
  .reverse-label-history-actions { justify-content: flex-start; }
}
.form-error { min-height: 18px; margin: 8px 0 !important; color: var(--red) !important; }
.rule-modal { width: min(94vw, 760px); }
.rule-modal form { padding: 0 28px 24px; }
.modal-header { position: sticky; top: 0; z-index: 2; display: flex; align-items: center; justify-content: space-between; padding: 24px 0 18px; border-bottom: 1px solid var(--line); background: white; }
.modal-header h2 { margin: 3px 0 0; font-size: 20px; }
.close-button { width: 34px; height: 34px; border: 0; border-radius: 8px; color: #7a8292; background: #f3f4f7; font-size: 23px; }
.rule-type-section { padding: 20px 0 4px; }
.rule-type-section h3 { margin: 2px 0 13px; font-size: 14px; }
.rule-type-options { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.rule-type-card { position: relative; min-height: 94px; display: grid !important; grid-template-columns: 34px minmax(0, 1fr) 16px; align-items: start; gap: 9px !important; padding: 12px !important; border: 1px solid #e1e4eb; border-radius: 10px; background: #fafbfc; cursor: pointer; transition: .16s ease; }
.rule-type-card:hover { border-color: #c9c3f4; background: #fbfaff; }
.rule-type-card:has(input:checked) { border-color: #9f92ec; background: #f5f3ff; box-shadow: inset 0 0 0 1px #9f92ec; }
.rule-type-card > input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.rule-type-card:has(input:focus-visible) { outline: 3px solid rgba(109,92,231,.16); outline-offset: 2px; }
.rule-type-card > span:nth-of-type(2) { min-width: 0; }
.rule-type-card b { display: block; color: var(--ink); font-size: 10px; line-height: 1.3; }
.rule-type-card small { display: block; margin-top: 5px; color: #858d9c; font-size: 8px; font-weight: 500; line-height: 1.4; }
.rule-type-card > i { width: 16px; height: 16px; display: none; place-items: center; border-radius: 50%; color: white; background: var(--purple); font-size: 8px; font-style: normal; }
.rule-type-card:has(input:checked) > i { display: grid; }
.rule-type-icon, .specific-action-icon { display: grid; place-items: center; border-radius: 8px; font-weight: 800; }
.rule-type-icon { width: 34px; height: 34px; font-size: 11px; }
.rule-type-icon.restriction { color: var(--red); background: var(--red-soft); }
.rule-type-icon.free, .specific-action-icon.free { color: var(--green); background: var(--green-soft); }
.rule-type-icon.deadline, .specific-action-icon.deadline { color: var(--amber); background: var(--amber-soft); }
.rule-type-icon.product-deadline, .specific-action-icon.product-deadline { color: #a2610d; background: #fff1d5; }
.rule-type-icon.exclusive, .specific-action-icon.exclusive { color: #5862bd; background: #eef0ff; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; padding: 21px 0; }
.form-grid .wide { grid-column: 1 / -1; }
.form-section { padding: 19px 0; border-top: 1px solid var(--line); }
.form-section-head { display: flex; align-items: center; justify-content: space-between; }
.form-section h3 { margin: 2px 0; font-size: 14px; }
.condition-list { display: grid; gap: 8px; margin-top: 13px; }
.condition-row { display: grid; grid-template-columns: 1.2fr 1fr 1.4fr 30px; gap: 7px; padding: 9px; border: 1px solid #e5e7ed; border-radius: 9px; background: #fafbfc; }
.condition-row select, .condition-row input { height: 34px; min-width: 0; font-size: 10px; }
.condition-value-slot { min-width: 0; }
.condition-value-slot > input { width: 100%; }
.condition-row.product-condition-row { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) 30px; align-items: start; }
.condition-row.product-condition-row .condition-value-slot { grid-column: 1 / -1; }
.condition-row.product-condition-row .remove-condition { grid-column: 3; grid-row: 1; }
.condition-row.product-condition-row .product-picker-results { top: calc(100% - 16px); }
.condition-row .remove-condition { border: 0; border-radius: 6px; color: #a0a6b2; background: transparent; font-size: 17px; }
.condition-row .remove-condition:hover { color: var(--red); background: var(--red-soft); }
.action-row { display: flex; align-items: center; gap: 9px; margin-top: 11px; padding: 13px; border-radius: 9px; color: #5e6778; background: #f8f8fb; font-size: 11px; }
.action-row .action-icon { width: 25px; height: 25px; display: grid; place-items: center; border-radius: 7px; color: var(--red); background: var(--red-soft); font-weight: 800; }
.action-row select { width: 100px; height: 32px; margin-left: auto; font-size: 10px; }
.rule-fields-group[hidden], #ruleMatchField[hidden] { display: none !important; }
.rule-specific-section { padding-bottom: 23px; }
.specific-action-card { display: grid; grid-template-columns: 42px repeat(3, minmax(0, 1fr)); align-items: end; gap: 12px; margin-top: 11px; padding: 16px; border: 1px solid #e4e6ed; border-radius: 11px; background: #fafbfc; }
.specific-action-icon { width: 42px; height: 42px; grid-row: 1; font-size: 13px; }
.specific-action-card > div:nth-child(2) { grid-column: 2 / -1; align-self: center; }
.specific-action-card h3 { margin: 0 0 3px; font-size: 13px; }
.specific-action-card p { margin: 0; color: #858d9d; font-size: 8px; line-height: 1.45; }
.specific-action-card label { align-self: end; }
.specific-action-card label input, .specific-action-card label select { height: 37px; min-width: 0; font-size: 10px; }
.free-shipping-config > label:nth-of-type(1) { grid-column: 2 / 4; }
.free-shipping-config > label:nth-of-type(2) { grid-column: 4; }
.delivery-days-config > label:nth-of-type(1) { grid-column: 2; }
.delivery-days-config > label:nth-of-type(2) { grid-column: 3; }
.delivery-days-config > label:nth-of-type(3) { grid-column: 4; }
.product-delivery-days-config > label:nth-of-type(1) { grid-column: 2; }
.product-delivery-days-config > label:nth-of-type(2) { grid-column: 3 / -1; }
.product-delivery-products-field { min-width: 0; display: grid; grid-column: 2 / -1; gap: 7px; color: #626b7c; font-size: 10px; font-weight: 650; text-align: left; }
.product-delivery-days-config .product-picker-chips { margin-top: 4px; }
.exclusive-config > label:nth-of-type(1) { grid-column: 2; }
.exclusive-products-field { min-width: 0; display: grid; grid-column: 3 / -1; gap: 7px; color: #626b7c; font-size: 10px; font-weight: 650; text-align: left; }
.exclusive-config .product-picker-chips { margin-top: 4px; }
.money-input { height: 37px; display: flex; align-items: center; overflow: hidden; border: 1px solid #dfe2e9; border-radius: 7px; background: white; }
.money-input:focus-within { border-color: #a79bed; box-shadow: 0 0 0 3px rgba(109,92,231,.1); }
.money-input > span { padding-left: 10px; color: #8a92a1; font-size: 9px; font-weight: 700; }
.money-input > input { height: 35px !important; min-width: 0; border: 0; box-shadow: none !important; }
.form-footer { display: flex; align-items: center; justify-content: space-between; gap: 18px; padding-top: 20px; border-top: 1px solid var(--line); }
.form-footer > div { display: flex; gap: 8px; }
.switch-label { display: flex !important; grid: none !important; flex-direction: row; align-items: center; gap: 8px !important; cursor: pointer; }
.switch-label input { position: absolute; opacity: 0; pointer-events: none; }
.switch { position: relative; width: 34px; height: 19px; border-radius: 20px; background: #ccd1dc; }
.switch::after { content: ""; position: absolute; width: 15px; height: 15px; left: 2px; top: 2px; border-radius: 50%; background: white; box-shadow: 0 1px 3px rgba(0,0,0,.2); transition: .2s; }
.switch-label input:checked + .switch { background: var(--green); }
.switch-label input:checked + .switch::after { transform: translateX(15px); }
.toast { position: fixed; right: 24px; bottom: 24px; z-index: 20; max-width: min(560px, calc(100vw - 48px)); padding: 12px 17px; border-radius: 9px; color: white; background: #202839; box-shadow: 0 12px 30px rgba(0,0,0,.18); font-size: 11px; line-height: 1.45; opacity: 0; transform: translateY(12px); pointer-events: none; transition: .25s ease; }
.toast.show { opacity: 1; transform: none; }
.toast.error { background: #b73a48; }

/* Fiozato Logistics — operação */
.operation-lead { min-height: 58px; display: flex; align-items: flex-start; justify-content: space-between; gap: 24px; margin-bottom: 18px; }
.operation-lead p { max-width: 720px; margin: 0; color: var(--muted); font-size: 13px; line-height: 1.55; }
.sync-state, .data-window { min-height: 30px; display: inline-flex; align-items: center; gap: 8px; padding: 0 10px; border: 1px solid var(--line); border-radius: 2px; color: #717171; background: #fff; font-size: 9px; font-weight: 700; letter-spacing: .55px; white-space: nowrap; }
.sync-state i { width: 6px; height: 6px; border-radius: 50%; background: #aaa; }
.sync-state.ok i { background: var(--green); }
.sync-state.loading i { background: var(--amber); animation: pulse 1s infinite alternate; }
.sync-state.error { color: var(--red); border-color: #efd2d6; background: var(--red-soft); }
.sync-state.error i { background: var(--red); }
@keyframes pulse { to { opacity: .25; } }

.operations-stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-bottom: 18px; }
.orders-operations-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.labels-operations-stats { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.metric-card { position: relative; min-height: 112px; display: grid; align-content: center; padding: 20px; overflow: hidden; border: 1px solid var(--line); border-radius: 3px; background: #fff; }
.metric-card.accent { background: var(--accent-soft); border-color: #e5e9aa; }
.metric-card > span { color: #777; font-size: 8px; font-weight: 700; letter-spacing: 1.35px; }
.metric-card > strong { margin: 7px 0 4px; overflow: hidden; font-size: 24px; font-weight: 400; letter-spacing: -.8px; text-overflow: ellipsis; white-space: nowrap; }
.metric-card > small { color: #979797; font-size: 9px; }

.operations-panel { overflow: hidden; }
.operations-toolbar { min-height: 76px; display: flex; align-items: center; justify-content: space-between; gap: 18px; padding: 16px 20px; border-bottom: 1px solid var(--line); }
.operations-toolbar > div:first-child { display: grid; }
.operations-toolbar > div:first-child strong { font-size: 12px; font-weight: 700; }
.operations-filters { display: flex; align-items: center; gap: 8px; }
.operations-filters .search-box { width: 300px; }
.operations-filters select { height: 38px; padding: 0 30px 0 10px; font-size: 10px; }
.bulk-action-bar { min-height: 58px; display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 10px 16px; border-bottom: 1px solid #e7e39d; background: var(--accent-soft); }
.bulk-selection-copy { display: flex; align-items: center; gap: 10px; }
.bulk-selection-copy strong { font-size: 10px; }
.bulk-selection-copy .text-button { color: #5c590e; font-size: 9px; text-decoration: underline; text-underline-offset: 3px; }
.bulk-action-controls { display: flex; align-items: center; justify-content: flex-end; flex-wrap: wrap; gap: 8px; }
.bulk-action-controls > label { color: #716d36; font-size: 8px; font-weight: 700; letter-spacing: .55px; text-transform: uppercase; }
.bulk-action-controls select { min-width: 155px; height: 34px; padding: 0 28px 0 9px; border-color: #d9d590; font-size: 9px; }
.operations-table-wrap { max-width: 100%; min-height: 310px; overflow-x: auto; overscroll-behavior-inline: contain; scrollbar-gutter: stable; }
.operations-table { width: 100%; border-collapse: collapse; }
#ordersTable { min-width: 1320px; }
.labels-table { min-width: 1280px; }
.operations-table .order-reference-column, .operations-table .label-reference-column { min-width: 150px; }
.operations-table .order-customer-column, .operations-table .label-customer-column { min-width: 180px; }
.operations-table .order-products-column, .operations-table .label-products-column { min-width: 320px; }
.operations-table .order-shipping-column, .operations-table .label-shipping-column { min-width: 140px; }
.operations-table .order-operation-column { min-width: 155px; }
.operations-table .order-label-column, .operations-table .label-state-column { min-width: 165px; }
.operations-table .label-package-column { min-width: 170px; }
.operations-table .order-actions-column { width: 132px; min-width: 132px; }
.operations-table .label-actions-column { width: 148px; min-width: 148px; }
.operations-table th { padding: 12px 14px; color: #848484; background: #fafafa; font-size: 8px; font-weight: 700; letter-spacing: .85px; text-align: left; text-transform: uppercase; white-space: nowrap; }
.operations-table td { padding: 15px 14px; border-top: 1px solid #ededed; vertical-align: middle; font-size: 11px; }
.operations-table th:last-child, .operations-table td:last-child { position: sticky; right: 0; z-index: 1; min-width: 112px; background: #fff; box-shadow: -8px 0 14px rgba(0,0,0,.025); }
.operations-table th:last-child { z-index: 2; background: #fafafa; }
.operations-table tbody tr:hover td:last-child { background: #fffef2; }
.operations-table tbody tr.selected-row td:last-child { background: var(--accent-soft); }
.operations-table tbody tr { transition: background .14s ease; }
.operations-table tbody tr:hover { background: #fffef2; }
.operations-table tbody tr.selected-row { background: var(--accent-soft); }
.operations-table .selection-column { width: 44px; min-width: 44px; padding-inline: 12px; text-align: center; }
.table-checkbox { position: relative; width: 18px; height: 18px; display: inline-grid; place-items: center; cursor: pointer; }
.table-checkbox input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.table-checkbox span { width: 17px; height: 17px; display: grid; place-items: center; border: 1px solid #cfcfcf; color: transparent; background: #fff; font-size: 8px; font-weight: 800; }
.table-checkbox input:checked + span, .table-checkbox input:indeterminate + span { border-color: #000; color: #000; background: var(--accent); }
.table-checkbox input:indeterminate + span { color: transparent; }
.table-checkbox input:indeterminate + span::after { content: "−"; color: #000; font-size: 10px; }
.table-checkbox input:focus-visible + span { outline: 2px solid #000; outline-offset: 2px; }
.table-checkbox input:disabled + span { cursor: not-allowed; opacity: .45; }
.operations-table .order-reference { display: grid; gap: 3px; }
.order-reference b, .customer-cell b, .product-cell b { color: #111; font-size: 11px; }
.order-reference small, .customer-cell small, .product-cell small { color: #8b8b8b; font-size: 9px; }
.customer-cell, .product-cell { min-width: 145px; display: grid; gap: 3px; }
.product-cell { max-width: 220px; }
.product-cell b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.order-products-list { min-width: 285px; display: grid; gap: 9px; }
.order-product-row { display: grid; grid-template-columns: 38px minmax(0, 1fr); align-items: center; gap: 9px; }
.order-product-row + .order-product-row { padding-top: 9px; border-top: 1px solid #eee; }
.order-product-thumb { width: 38px; height: 48px; display: grid; place-items: center; overflow: hidden; color: #777; background: #f1f1f1; font-size: 8px; font-weight: 700; }
.order-product-thumb img { width: 100%; height: 100%; object-fit: cover; }
.order-product-copy { min-width: 0; display: grid; gap: 2px; }
.order-product-copy b { overflow: hidden; color: #111; font-size: 10px; text-overflow: ellipsis; white-space: nowrap; }
.order-product-copy small { overflow: hidden; color: #686868; font-size: 8px; text-overflow: ellipsis; white-space: nowrap; }
.order-product-copy em { color: #969696; font-size: 7px; font-style: normal; font-weight: 600; letter-spacing: .15px; }
.order-products-missing { color: #8b8b8b; font-size: 9px; }
.shipping-cell { min-width: 120px; display: grid; gap: 4px; }
.shipping-service { width: fit-content; padding: 4px 6px; border-radius: 1px; color: #111; background: var(--accent-soft); font-size: 9px; font-weight: 700; }
.shipping-cell small { color: #888; font-size: 8px; }
.operation-stage { width: fit-content; display: inline-flex; align-items: center; gap: 6px; padding: 5px 7px; border: 1px solid #e1e1e1; border-radius: 2px; color: #555; background: #fafafa; font-size: 9px; font-weight: 700; white-space: nowrap; }
.operation-stage::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: #aaa; }
.operation-stage.picking::before, .operation-stage.packed::before, .operation-stage.ready_to_ship::before { background: var(--amber); }
.operation-stage.shipped::before { background: #3372b8; }
.operation-stage.delivered::before { background: var(--green); }
.operation-stage.exception::before, .operation-stage.cancelled::before { background: var(--red); }
.label-cell { min-width: 135px; display: grid; gap: 3px; }
.label-cell b { font-size: 10px; }
.label-cell small { color: #888; font-size: 8px; }
.order-open-button { min-height: 32px; padding: 0 10px; border: 1px solid #dcdcdc; border-radius: 2px; color: #111; background: #fff; font-size: 9px; font-weight: 700; white-space: nowrap; }
.order-open-button:hover { border-color: #111; background: #111; color: #fff; }
.order-open-button.primary-row-action { border-color: #000; color: #fff; background: #000; }
.label-row-actions { display: grid; gap: 4px; }
.label-row-actions .order-open-button { width: 100%; }
.operations-placeholder { min-height: 310px; display: none; align-content: center; justify-items: center; padding: 45px 20px; text-align: center; }
.operations-placeholder.show { display: grid; }
.operations-placeholder > span { width: 44px; height: 44px; display: grid; place-items: center; margin-bottom: 13px; color: #111; background: var(--accent-soft); font-size: 18px; }
.operations-placeholder h3 { margin: 0 0 6px; font-size: 14px; font-weight: 400; }
.operations-placeholder p { max-width: 420px; margin: 0; color: #858585; font-size: 10px; line-height: 1.55; }
.operations-pagination { display: flex; align-items: center; justify-content: flex-end; gap: 12px; padding: 12px 18px; border-top: 1px solid var(--line); }
.operations-pagination span { color: #777; font-size: 9px; }
.labels-pagination { flex-wrap: wrap; }
.labels-pagination label { display: inline-flex; align-items: center; gap: 7px; color: #555; font-size: 11px; font-weight: 700; }
.labels-pagination input { width: 68px; min-height: 34px; padding: 6px 8px; border: 1px solid var(--line); background: #fff; color: var(--ink); text-align: center; font: inherit; }
.labels-pagination select { min-height: 34px; padding: 6px 30px 6px 9px; border: 1px solid var(--line); background-color: #fff; color: var(--ink); font: inherit; }
.labels-pagination #labelsPageTotal { font-size: 11px; }

.segmented-control { display: inline-flex; padding: 3px; border: 1px solid var(--line); background: #fafafa; }
.segmented-control button { min-height: 30px; padding: 0 12px; border: 0; color: #777; background: transparent; font-size: 9px; font-weight: 700; }
.segmented-control button.active { color: #000; background: var(--accent); }
.labels-search { width: min(360px, 42vw); }
.labels-filters { display: flex; align-items: center; justify-content: flex-end; gap: 8px; }
.label-provider-filter { display: block; }
.label-provider-filter select { min-width: 190px; height: 38px; padding: 0 32px 0 11px; border: 1px solid var(--line); color: #333; background-color: #fff; font-size: 10px; }
.label-queue-tabs { width: 100%; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); padding: 8px; border-width: 0 0 1px; background: #fff; }
.label-queue-tabs button { min-height: 38px; border: 1px solid transparent; text-align: center; }
.label-queue-tabs button + button { border-left-color: #ededed; }
.label-queue-tabs button.active { border-color: #e7e39d; }
.label-queue-tabs button span { min-width: 20px; display: inline-grid; place-items: center; margin-left: 5px; padding: 2px 5px; background: rgba(0,0,0,.06); font-size: 7px; }
.label-queue-state { width: fit-content; display: inline-flex; align-items: center; gap: 5px; padding: 5px 7px; border: 1px solid #dedede; color: #555; background: #fafafa; font-size: 8px; font-weight: 700; white-space: nowrap; }
.label-queue-state::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: #999; }
.label-queue-state.ready { color: #665d00; border-color: #ded889; background: var(--accent-soft); }
.label-queue-state.ready::before { background: #817800; }
.label-queue-state.issued { color: var(--green); border-color: #cfe7d9; background: var(--green-soft); }
.label-queue-state.issued::before { background: var(--green); }
.label-queue-state.problem { color: var(--red); border-color: #efd2d6; background: var(--red-soft); }
.label-queue-state.problem::before { background: var(--red); }
.tracking-table a, .label-cell a { color: #111; text-decoration: underline; text-underline-offset: 3px; }

.modal { border-radius: 3px; }
.close-button { border-radius: 2px; color: #111; background: #f3f3f3; }
.auth-logo { width: 52px; height: 52px; display: block; margin: 0 auto 18px; }
.auth-modal h2 { font-weight: 400; letter-spacing: -.5px; }
.order-modal { width: min(96vw, 1120px); max-height: 94vh; }
.order-dialog-shell { min-height: 540px; padding: 0 28px 28px; }
.order-dialog-header { position: sticky; top: 0; z-index: 3; min-height: 94px; display: flex; align-items: center; justify-content: space-between; gap: 20px; border-bottom: 1px solid var(--line); background: #fff; }
.order-dialog-header h2 { margin: 2px 0 3px; font-size: 22px; font-weight: 400; letter-spacing: -.5px; }
.order-dialog-header p { margin: 0; color: #858585; font-size: 10px; }
.order-dialog-loading { min-height: 430px; display: grid; align-content: center; justify-items: center; gap: 14px; }
.order-dialog-loading > span { width: 30px; height: 30px; border: 2px solid #eee; border-top-color: #111; border-radius: 50%; animation: spin .8s linear infinite; }
.order-dialog-loading p { margin: 0; color: #888; font-size: 10px; }
@keyframes spin { to { transform: rotate(360deg); } }
.order-summary-band { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1px; margin: 20px 0; border: 1px solid var(--line); background: var(--line); }
.summary-cell { min-height: 76px; display: grid; align-content: center; gap: 4px; padding: 13px 16px; background: #fff; }
.summary-cell span { color: #858585; font-size: 8px; font-weight: 700; letter-spacing: .8px; }
.summary-cell b { overflow: hidden; font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.summary-cell small { color: #999; font-size: 8px; }
.order-detail-grid { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(300px, .72fr); gap: 20px; align-items: start; }
.order-detail-main { display: grid; gap: 14px; }
.order-detail-section { border: 1px solid var(--line); background: #fff; }
.order-section-heading { min-height: 48px; display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 0 15px; border-bottom: 1px solid var(--line); }
.order-section-heading .section-label { margin: 0; }
.order-section-heading > strong { color: #777; font-size: 9px; }
.immutable-pill { padding: 4px 6px; color: #6c6200; background: var(--accent-soft); font-size: 7px; font-weight: 700; letter-spacing: .6px; }
.order-item-list { display: grid; padding: 4px 15px; }
.order-item { display: grid; grid-template-columns: 48px minmax(0, 1fr) minmax(185px, .62fr); align-items: center; gap: 12px; padding: 11px 0; border-bottom: 1px solid #eee; }
.order-item.order-item-readonly { grid-template-columns: 48px minmax(0, 1fr); }
.order-item:last-child { border-bottom: 0; }
.order-item-image { width: 48px; height: 58px; display: grid; place-items: center; overflow: hidden; color: #777; background: #f3f3f3; font-size: 10px; }
.order-item-image img { width: 100%; height: 100%; object-fit: cover; }
.order-item-copy { min-width: 0; display: grid; gap: 3px; }
.order-item-copy b { overflow: hidden; display: block; font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.order-item-copy small { display: block; color: #666; font-size: 8px; }
.order-item-copy em { color: #949494; font-size: 8px; font-style: normal; }
.order-item-production { min-width: 0; display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: end; gap: 3px 8px; color: #777; font-size: 7px; font-weight: 700; letter-spacing: .45px; text-transform: uppercase; }
.order-item-production > b { color: #555; font-size: 8px; font-weight: 600; letter-spacing: 0; text-transform: none; }
.order-item-production select { width: 100%; height: 34px; grid-column: 1 / -1; padding: 0 27px 0 8px; font-size: 9px; text-transform: none; }
.order-item-production select.saving { opacity: .55; }
.original-shipping-card, .label-detail-card { display: grid; grid-template-columns: minmax(0, 1fr) repeat(3, auto); align-items: center; gap: 22px; padding: 16px; }
.original-shipping-card > div, .label-detail-card > div { display: grid; gap: 4px; }
.original-shipping-card span, .label-detail-card span { color: #888; font-size: 8px; }
.original-shipping-card b, .label-detail-card b { font-size: 11px; }
.order-operation-card { position: sticky; top: 114px; padding: 18px; border: 1px solid #111; background: #fafafa; }
.order-operation-card h3 { margin: 3px 0 7px; font-size: 16px; font-weight: 400; }
.order-operation-card > div:first-child > p { margin: 0 0 17px; color: #777; font-size: 9px; line-height: 1.55; }
.order-operation-card form { display: grid; gap: 12px; }
.order-operation-card label { display: grid; gap: 6px; color: #5f5f5f; font-size: 9px; font-weight: 700; }
.order-operation-card input, .order-operation-card select, .order-operation-card textarea { width: 100%; padding: 0 10px; border: 1px solid #d7d7d7; border-radius: 1px; color: #111; background: #fff; font: inherit; outline: none; }
.order-operation-card input, .order-operation-card select { height: 38px; }
.order-operation-card textarea { min-height: 68px; padding-block: 9px; resize: vertical; }
.external-sync-check { display: grid !important; grid-template-columns: 16px 1fr; align-items: start; gap: 9px !important; padding: 10px; background: var(--accent-soft); cursor: pointer; }
.external-sync-check input { width: 15px; height: 15px; margin: 1px 0 0; }
.external-sync-check b, .external-sync-check small { display: block; }
.external-sync-check small { margin-top: 4px; color: #817c50; font-size: 8px; font-weight: 400; line-height: 1.4; }
.label-action-card { display: grid; grid-template-columns: 34px 1fr; gap: 10px; margin-top: 16px; padding-top: 16px; border-top: 1px solid #ddd; }
.label-action-card .label-action-icon { width: 34px; height: 34px; display: grid; place-items: center; background: #111; color: #fff; }
.label-action-card b { font-size: 10px; }
.label-action-card p { margin: 4px 0 10px; color: #858585; font-size: 8px; line-height: 1.45; }
.label-action-card button { grid-column: 1 / -1; }
.label-action-card button:disabled { cursor: not-allowed; opacity: .55; }
.label-readiness-control { grid-column: 1 / -1; display: grid; gap: 10px; padding: 12px; border: 1px solid #ddd88d; background: #fffff3; }
.label-readiness-control > div { display: grid; gap: 4px; }
.label-readiness-control span { color: #696424; font-size: 7px; font-weight: 800; letter-spacing: .75px; }
.label-readiness-control small { color: #777249; font-size: 8px; line-height: 1.5; }
.label-readiness-control .label-readiness-button { min-height: 40px; border-color: #111; color: #111; background: var(--accent); }
.label-readiness-control .label-readiness-button:hover { color: #fff; background: #111; }
.status-chip { padding: 4px 6px; border: 1px solid #ddd; color: #666; background: #fafafa; font-size: 8px; font-weight: 700; }
.status-chip.ok { color: var(--green); border-color: #cfe7d9; background: var(--green-soft); }

.sync-pending-pill { padding: 5px 7px; border: 1px solid #ded889; color: #665d00; background: var(--accent-soft); font-size: 7px; font-weight: 700; letter-spacing: .55px; white-space: nowrap; }
.sync-active-pill { border-color: #b7d8c2; color: #17633b; background: #effaf2; }
.label-order-editor-notice { display: grid; grid-template-columns: 28px minmax(0, 1fr); align-items: start; gap: 10px; margin: 14px; padding: 12px; border: 1px solid #e4df95; background: #fffff3; }
.label-order-editor-notice > span { width: 28px; height: 28px; display: grid; place-items: center; color: #111; background: var(--accent); font-size: 10px; font-weight: 700; }
.label-order-editor-notice p { margin: 1px 0 0; color: #69653f; font-size: 9px; line-height: 1.55; }
.label-order-editor { min-width: 0; display: grid; gap: 1px; margin: 0; padding: 0 14px 14px; border: 0; background: var(--line); }
.label-order-editor > section { min-width: 0; padding: 14px; background: #fff; }
.label-order-editor:disabled { opacity: .72; }
.label-editor-heading { min-height: 36px; display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin-bottom: 10px; }
.label-editor-heading h3 { margin: 0 0 3px; font-size: 12px; font-weight: 500; }
.label-editor-heading small { color: #8a8a8a; font-size: 8px; }
.label-editor-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.label-editor-grid label { min-width: 0; display: grid; gap: 5px; color: #6f6f6f; font-size: 8px; font-weight: 700; }
.label-editor-grid label.wide { grid-column: 1 / -1; }
.label-editor-grid input, .label-editor-grid select { width: 100%; height: 36px; padding: 0 9px; border: 1px solid #dedede; background: #fafafa; font-size: 9px; }
.label-edit-items-list { display: grid; gap: 8px; }
.label-edit-item { min-width: 0; display: grid; grid-template-columns: 38px minmax(0, 1fr) 78px 30px; align-items: center; gap: 10px; padding: 9px; border: 1px solid #e7e7e7; background: #fcfcfc; }
.label-edit-item-image { width: 38px; height: 46px; display: grid; place-items: center; overflow: hidden; color: #777; background: #eee; font-size: 8px; font-weight: 700; }
.label-edit-item-image img { width: 100%; height: 100%; object-fit: cover; }
.label-edit-item-copy { min-width: 0; display: grid; gap: 3px; }
.label-edit-item-copy b { overflow: hidden; font-size: 10px; text-overflow: ellipsis; white-space: nowrap; }
.label-edit-item-copy small { overflow: hidden; color: #858585; font-size: 8px; text-overflow: ellipsis; white-space: nowrap; }
.label-edit-item label { display: grid; gap: 4px; color: #858585; font-size: 7px; font-weight: 700; }
.label-edit-item input { width: 100%; height: 32px; padding: 0 7px; border: 1px solid #ddd; background: #fff; }
.label-editor-empty { margin: 0; color: #888; font-size: 9px; }
.label-editor-footer { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 0 14px 14px; }
.label-editor-footer p { max-width: 420px; margin: 0; color: #858585; font-size: 8px; line-height: 1.45; }
.label-editor-footer button:disabled { cursor: not-allowed; opacity: .5; }
.label-order-history-list { display: grid; padding: 4px 15px; }
.label-order-history-entry { display: grid; grid-template-columns: 10px minmax(0, 1fr) auto; align-items: start; gap: 9px; padding: 12px 0; border-bottom: 1px solid #eee; }
.label-order-history-entry:last-child { border-bottom: 0; }
.history-dot { width: 7px; height: 7px; margin-top: 3px; border: 1px solid #111; border-radius: 50%; background: var(--accent); }
.label-order-history-entry > div { min-width: 0; display: grid; gap: 3px; }
.label-order-history-entry b { font-size: 10px; }
.label-order-history-entry small, .label-order-history-entry time { color: #8a8a8a; font-size: 8px; }
.label-order-history-entry p { margin: 2px 0 0; color: #666; font-size: 8px; line-height: 1.45; }
.label-history-empty { display: grid; grid-template-columns: 34px minmax(0, 1fr); gap: 11px; padding: 15px 0; }
.label-history-empty > span { width: 34px; height: 34px; display: grid; place-items: center; background: #f3f3f3; color: #777; }
.label-history-empty b { font-size: 10px; }
.label-history-empty p { margin: 4px 0 0; color: #888; font-size: 8px; line-height: 1.5; }

/* Pedido · gestão para etiqueta — layout aprovado 9a */
.order-modal.label-context { width: min(96vw, 1180px); border: 1px solid #e0e0e0; border-radius: 0; }
.order-modal.label-context .order-dialog-shell { padding: 0; }
.order-modal.label-context .order-dialog-header { min-height: 128px; padding: 24px 30px 20px; position: static; }
.order-modal.label-context .order-dialog-header h2 { margin: 7px 0 5px; font-size: 28px; letter-spacing: -1px; }
.order-modal.label-context .close-button { width: 40px; height: 40px; border: 0; border-radius: 0; }
.order-modal.label-context .order-summary-band { margin: 0; border: 0; border-bottom: 1px solid #efefef; background: #efefef; }
.order-modal.label-context .summary-cell { min-height: 82px; padding: 16px 22px; }
.order-modal.label-context .summary-cell:first-child { padding-left: 30px; }
.order-modal.label-context .summary-cell span { font-size: 8px; letter-spacing: 1.4px; }
.order-modal.label-context .summary-cell b { font-size: 13px; }
.order-redesign-section { padding: 20px 30px; border-bottom: 1px solid #efefef; }
.order-redesign-section .order-section-heading { min-height: auto; padding: 0 0 8px; border: 0; }
.order-redesign-section .order-item-list { padding: 0; }
.order-redesign-section .order-item { grid-template-columns: 56px minmax(0, 1fr) 220px; gap: 16px; padding: 10px 0; }
.order-redesign-section .order-item-image { width: 56px; height: 66px; border: 1px solid #efefef; background: #fafafa; }
.order-redesign-section .order-item-image img { object-fit: contain; }
.order-redesign-section .order-item-copy b { font-size: 13px; }
.order-redesign-section .order-item-copy small, .order-redesign-section .order-item-copy em { font-size: 10px; }
.order-redesign-section .order-item-production > span, .order-redesign-section .production-status-current { display: none; }
.order-redesign-section .order-item-production select { height: 34px; border-left: 3px solid #2a5ca8; border-radius: 0; background: #fbfbfb; font-size: 9px; font-weight: 700; letter-spacing: .4px; text-transform: uppercase; }
.order-redesign-section select[data-production-tone="so_tecido"] { border-left-color: #7a4a26; }
.order-redesign-section select[data-production-tone="separado"] { border-left-color: #5b4bb2; }
.order-redesign-section select[data-production-tone="cortada"] { border-left-color: #c2560c; }
.order-redesign-section select[data-production-tone="na_costura"] { border-left-color: #1f4fbf; }
.order-redesign-section select[data-production-tone="pronta"] { border-left-color: #137549; }
.order-redesign-section select[data-production-tone="enviada"] { border-left-color: #a3a3a3; }
.order-redesign-section select[data-production-tone="falta_molde"],
.order-redesign-section select[data-production-tone="esperando_estamparia"],
.order-redesign-section select[data-production-tone="falta_tecido"],
.order-redesign-section select[data-production-tone="falta_aviamento"] { border-color: #efd2d6; border-left-color: #b52f3e; background: #fff1f2; color: #9c2634; }
.order-freight-layout { display: grid; grid-template-columns: 300px minmax(0, 1fr); border-bottom: 1px solid #efefef; }
.order-customer-freight { padding: 20px 30px; border-right: 1px solid #f0f0f0; background: #fbfbfb; }
.order-customer-freight > div > b { display: block; margin: 12px 0 10px; font-size: 18px; }
.order-customer-freight > div > div { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.order-customer-freight span { display: grid; gap: 2px; }
.order-customer-freight small { color: #9a9a9a; font-size: 9px; }
.order-customer-freight strong { font-size: 11px; }
.order-operational-freight { padding: 20px 30px; }
.order-freight-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 12px; }
.freight-changed-badge { padding: 3px 8px; border: 1px solid #ded889; background: #fcffd7; color: #5f5800; font-size: 9px; font-weight: 700; }
.order-carrier-choices { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 10px; }
.order-carrier-choices button { height: 32px; padding: 0 14px; border: 1px solid #e5e5e5; border-radius: 0; background: #fff; color: #6b6b6b; font-size: 11px; font-weight: 700; }
.order-carrier-choices button.selected { border-color: #111; background: #111; color: #fff; }
.order-service-choices { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.order-service-choices button { display: grid; gap: 5px; padding: 12px 14px; border: 1px solid #e5e5e5; border-radius: 0; background: #fff; text-align: left; }
.order-service-choices button.selected { border-color: #111; background: #fcffd7; }
.order-service-choices b { font-size: 14px; }
.order-service-choices small, .order-service-empty { color: #6b6b6b; font-size: 10px; }
.order-delivery-section { min-width: 0; padding: 20px 30px; border: 0; border-bottom: 1px solid #efefef; }
.order-delivery-section:disabled { opacity: .72; }
.order-delivery-primary, .order-delivery-address { display: grid; gap: 12px; margin-top: 12px; }
.order-delivery-primary { grid-template-columns: 2fr 1.4fr 2fr; }
.order-delivery-address { grid-template-columns: 120px 2.4fr 90px 1.4fr 1.4fr 70px; }
.order-delivery-section label { display: grid; gap: 5px; color: #6b6b6b; font-size: 10px; font-weight: 600; }
.order-delivery-section input { width: 100%; min-width: 0; height: 38px; padding: 0 12px; border: 1px solid #e5e5e5; border-radius: 0; background: #fafafa; color: #111; font-size: 12px; font-weight: 600; }
.order-delivery-section input:focus { border-color: #111; background: #fff; outline: none; }
.order-history-section { padding: 16px 30px; border-bottom: 1px solid #efefef; }
.order-history-section .order-section-heading { min-height: auto; padding: 0 0 8px; border: 0; }
.order-history-section .label-order-history-list { padding: 0; }
.label-history-empty-copy { margin: 0; color: #9a9a9a; font-size: 11px; }
.order-action-bar { position: sticky; bottom: 0; z-index: 4; display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 14px 30px; border-top: 1px solid #efefef; background: #fafafa; }
.order-action-bar > small { font-size: 11px; font-weight: 600; }
.order-action-bar > small.warning { color: #9a6b00; }
.order-action-bar > small.problem { color: #b52f3e; }
.order-action-bar > div { display: flex; gap: 8px; }
.order-save-button { height: 40px; padding: 0 18px; border-radius: 0; font-size: 12px; font-weight: 700; }
.order-save-button { border: 1px solid #e0e0e0; background: #fff; color: #9a9a9a; }
.order-save-button.dirty { border-color: #111; color: #111; }

@media (max-width: 900px) {
  .order-modal.label-context { width: 100vw; max-height: 100vh; margin: 0; }
  .order-modal.label-context .order-summary-band { grid-template-columns: 1fr 1fr; }
  .order-freight-layout { grid-template-columns: 1fr; }
  .order-customer-freight { border-right: 0; border-bottom: 1px solid #f0f0f0; }
  .order-redesign-section .order-item { grid-template-columns: 56px minmax(0, 1fr); }
  .order-redesign-section .order-item-production { grid-column: 1 / -1; }
  .order-delivery-primary { grid-template-columns: 1fr; }
  .order-delivery-address { grid-template-columns: 1fr 1fr; }
  .order-action-bar { align-items: stretch; flex-direction: column; }
  .order-action-bar > div { flex-direction: column; }
}

.integration-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.integration-logo, .provider-logo { border-radius: 1px; }
.connection-badge { border-radius: 1px; }
.rule-type-card, .specific-action-card, .condition-row, .action-row, .money-input, .search-box, select, input { border-radius: 2px; }
.rule-type-card:has(input:checked) { border-color: #111; background: var(--accent-soft); box-shadow: inset 0 0 0 1px #111; }
.rule-type-card:hover { border-color: #111; background: #fffef2; }

@media (max-width: 1050px) {
  .app-shell { grid-template-columns: 78px 1fr; }
  .sidebar { padding-inline: 11px; }
  .brand { justify-items: center; padding-inline: 0; }
  .brand-logo { width: 46px; }
  .brand small, .nav-section, .nav-item > span:not(.nav-icon), .sidebar-foot { display: none; }
  .nav-item { grid-template-columns: 1fr; justify-items: center; }
  .mobile-logout { display: grid; place-items: center; }
  .main { padding-inline: 25px; }
  .hero-card { grid-template-columns: 1fr; }
  .flow-visual { max-width: 620px; width: 100%; }
  .credentials-grid { grid-template-columns: 1fr; }
  .simulation-layout { grid-template-columns: 1fr; }
  .packages-layout { grid-template-columns: 1fr; }
  .operations-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .labels-operations-stats { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .operations-toolbar { align-items: stretch; flex-direction: column; }
  .operations-filters { flex-wrap: wrap; }
  .operations-filters .search-box { width: 100%; }
  .order-detail-grid { grid-template-columns: 1fr; }
  .order-operation-card { position: static; }
}

@media (max-width: 760px) {
  .app-shell { display: block; }
  .sidebar { position: fixed; inset: auto 0 0; z-index: 10; width: 100%; height: 64px; flex-direction: row; padding: 8px 12px; }
  .brand, .sidebar-foot { display: none; }
  .nav { width: 100%; display: grid; grid-auto-flow: column; grid-auto-columns: minmax(76px, 1fr); overflow-x: auto; scrollbar-width: none; }
  .nav::-webkit-scrollbar { display: none; }
  .nav-section { display: none; }
  .nav-item { display: flex; flex-direction: column; justify-content: center; gap: 1px; padding: 4px; font-size: 9px; text-align: center; }
  .nav-item > span:not(.nav-count) { display: block; }
  .nav-count { display: none; }
  .main { padding: 0 14px 84px; }
  .topbar { height: 92px; }
  .topbar h1 { font-size: 22px; }
  .environment-pill, #newRuleTopButton { display: none !important; }
  .hero-card { padding: 28px 24px; }
  .flow-visual { grid-template-columns: 1fr 24px 1fr 24px 1fr; }
  .flow-node { min-height: 90px; }
  .flow-line span { display: none; }
  .stats-grid, .content-grid, .integration-grid { grid-template-columns: 1fr; }
  .credential-fields.two-columns { grid-template-columns: 1fr; }
  .credential-fields .wide { grid-column: auto; }
  .section-intro { display: block; }
  .filter-row { flex-direction: column; margin-top: 14px; }
  .search-box { width: 100%; }
  .filter-row select { width: 100%; }
  .rules-table th:nth-child(2), .rules-table td:nth-child(2), .rules-table th:nth-child(4), .rules-table td:nth-child(4) { display: none; }
  .form-grid { grid-template-columns: 1fr; }
  .form-grid .wide { grid-column: auto; }
  .rule-type-options { grid-template-columns: 1fr; }
  .rule-type-card { min-height: 72px; }
  .specific-action-card { grid-template-columns: 38px minmax(0, 1fr); align-items: start; }
  .specific-action-icon { width: 38px; height: 38px; }
  .specific-action-card > div:nth-child(2) { grid-column: 2; }
  .free-shipping-config > label:nth-of-type(1), .free-shipping-config > label:nth-of-type(2), .delivery-days-config > label:nth-of-type(1), .delivery-days-config > label:nth-of-type(2), .delivery-days-config > label:nth-of-type(3), .product-delivery-days-config > label:nth-of-type(1), .product-delivery-days-config > label:nth-of-type(2), .product-delivery-products-field, .exclusive-config > label:nth-of-type(1), .exclusive-products-field { grid-column: 1 / -1; }
  .condition-row { grid-template-columns: 1fr; }
  .condition-row.product-condition-row { grid-template-columns: 1fr; }
  .condition-row.product-condition-row .condition-value-slot, .condition-row.product-condition-row .remove-condition { grid-column: auto; grid-row: auto; }
  .condition-row .remove-condition { height: 28px; }
  .action-row { display: grid; grid-template-columns: 25px minmax(0, 1fr); align-items: center; }
  .action-row .action-icon { grid-row: 1 / span 2; }
  .action-row select { width: 100%; margin-left: 0; }
  .action-row > span:last-child { grid-column: 2; color: #8b92a0; font-size: 9px; }
  .credentials-actions .danger-button { flex-basis: 100%; margin-right: 0; }
  .form-footer { align-items: flex-start; flex-direction: column; }
  .form-footer > div { width: 100%; }
  .form-footer button { flex: 1; }
  .simulation-cart-line { grid-template-columns: 45px minmax(0, 1fr) 26px; align-items: start; }
  .simulation-product-image { width: 45px; height: 45px; }
  .quantity-field { grid-column: 2; }
  .remove-cart-item { grid-column: 3; grid-row: 1; }
  .simulation-submit-row { align-items: stretch; flex-direction: column; }
  .simulation-submit-row button { width: 100%; }
  .quote-grid { grid-template-columns: 1fr; }
  .product-result-action { display: none; }
  .package-stats { grid-template-columns: 1fr; }
  .quotation-settings-copy { grid-template-columns: 38px minmax(0, 1fr); }
  .quotation-settings-copy .cost-separation-note { grid-column: 1 / -1; }
  .packaging-cost-option { grid-template-columns: 1fr; }
  .packaging-cost-option > button { width: 100%; }
  .package-row { grid-template-columns: 22px 42px minmax(0, 1fr); align-items: start; }
  .package-visual { width: 42px; height: 42px; }
  .package-row-controls { grid-column: 2 / -1; justify-content: flex-start; padding-top: 2px; }
  .shipping-options-actions { align-items: stretch; flex-direction: column; }
  .shipping-options-actions button { width: 100%; }
  .package-form-grid, .package-form-options { grid-template-columns: 1fr; }
  .package-form-grid .wide { grid-column: auto; }
  .package-form-footer > span { display: none; }
  .operation-lead { display: grid; }
  .sync-state, .data-window { width: fit-content; }
  .operations-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .labels-operations-stats { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .metric-card { min-height: 96px; padding: 15px; }
  .metric-card > strong { font-size: 20px; }
  .operations-filters { display: grid; grid-template-columns: 1fr 1fr; }
  .operations-filters .search-box { grid-column: 1 / -1; }
  .order-shipping-column, .order-operation-column, .label-customer-column, .label-shipping-column, .label-package-column { display: none; }
  .operations-toolbar > .search-box { width: 100%; }
  .labels-filters { width: 100%; justify-content: stretch; }
  .labels-filters .labels-search { width: auto; flex: 1 1 320px; }
  .label-provider-filter { flex: 0 1 220px; }
  .label-provider-filter select { width: 100%; min-width: 0; }
  .bulk-action-bar { align-items: stretch; flex-direction: column; }
  .bulk-action-controls { justify-content: flex-start; }
  .label-queue-tabs { display: flex; overflow-x: auto; scrollbar-width: none; }
  .label-queue-tabs::-webkit-scrollbar { display: none; }
  .label-queue-tabs button { min-width: 150px; flex: 1 0 auto; }
  .order-dialog-shell { padding: 0 14px 18px; }
  .order-dialog-header { min-height: 84px; }
  .order-summary-band { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .original-shipping-card, .label-detail-card { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .order-item { grid-template-columns: 48px minmax(0, 1fr); align-items: start; }
  .order-item-production { grid-column: 2; }
  .label-editor-grid { grid-template-columns: 1fr; }
  .label-editor-grid label.wide { grid-column: auto; }
  .label-editor-heading { align-items: stretch; flex-direction: column; }
  .label-editor-heading button { width: 100%; }
  .label-editor-footer { align-items: stretch; flex-direction: column; }
  .label-editor-footer button { width: 100%; }

  .operations-table-wrap:has(#ordersTable), .operations-table-wrap:has(.labels-table) { overflow: visible; scrollbar-gutter: auto; }
  #ordersTable, .labels-table { min-width: 0; display: block !important; background: #f6f6f6; }
  #ordersTable thead, .labels-table thead { display: none; }
  #ordersTable tbody, .labels-table tbody { display: grid; gap: 10px; padding: 10px; }
  #ordersTable tr, .labels-table tr { position: relative; display: grid; grid-template-columns: 28px minmax(0, 1fr) auto; gap: 8px 10px; padding: 12px; border: 1px solid var(--line); background: #fff; }
  #ordersTable tr { grid-template-areas: "select reference action" ". customer action" "products products products" "label label label"; }
  .labels-table tr { grid-template-areas: "select reference action" "products products products" "state state state"; }
  #ordersTable td, .labels-table td { min-width: 0; padding: 0; border: 0; background: transparent; }
  #ordersTable .selection-column, .labels-table .selection-column { width: 28px; min-width: 28px; grid-area: select; padding: 0; text-align: left; }
  #ordersTable .order-reference-column { grid-area: reference; }
  #ordersTable .order-customer-column { min-width: 0; grid-area: customer; }
  #ordersTable .order-products-column { grid-area: products; padding-top: 10px; border-top: 1px solid #eee; }
  #ordersTable .order-label-column { min-width: 0; grid-area: label; padding-top: 10px; border-top: 1px solid #eee; }
  #ordersTable .order-actions-column { grid-area: action; }
  .labels-table .label-reference-column { grid-area: reference; }
  .labels-table .label-products-column { grid-area: products; padding-top: 10px; border-top: 1px solid #eee; }
  .labels-table .label-state-column { min-width: 0; grid-area: state; padding-top: 10px; border-top: 1px solid #eee; }
  .labels-table .label-actions-column { grid-area: action; }
  #ordersTable td:last-child, .labels-table td:last-child { position: static; width: auto; min-width: 0; box-shadow: none; background: transparent; }
  #ordersTable tbody tr:hover td:last-child, .labels-table tbody tr:hover td:last-child, #ordersTable tbody tr.selected-row td:last-child, .labels-table tbody tr.selected-row td:last-child { background: transparent; }
  #ordersTable .order-products-list, .labels-table .order-products-list { min-width: 0; }
  #ordersTable .customer-cell, .labels-table .customer-cell, #ordersTable .label-cell, .labels-table .label-cell { min-width: 0; }
  #ordersTable .order-open-button, .labels-table .order-open-button { min-height: 30px; padding-inline: 8px; }
  .integration-grid { grid-template-columns: 1fr; }
}

@media (max-width: 480px) {
  .rules-table { table-layout: fixed; }
  .rules-table th, .rules-table td { padding: 10px 8px; }
  .rules-table th:nth-child(3), .rules-table td:nth-child(3), .rules-table th:nth-child(5), .rules-table td:nth-child(5) { display: none; }
  .rules-table th:last-child, .rules-table td:last-child { width: 112px; }
  .rule-name { max-width: 100%; }
  .package-row-controls .default-button span, .package-row-controls .edit-button span:last-child { display: none; }
  .shipping-option-card { grid-template-columns: 34px minmax(0, 1fr) 34px; padding: 10px !important; }
  .shipping-option-icon { width: 34px; height: 34px; }
  .operations-stats { grid-template-columns: 1fr 1fr; gap: 8px; }
  .labels-operations-stats { grid-template-columns: 1fr 1fr; }
  .labels-operations-stats .metric-card:last-child { grid-column: 1 / -1; }
  .metric-card { min-height: 88px; padding: 12px; }
  .metric-card > span { font-size: 7px; }
  .metric-card > strong { font-size: 17px; }
  .metric-card > small { display: none; }
  .operations-filters { grid-template-columns: 1fr; }
  .operations-filters .search-box { grid-column: auto; }
  .labels-filters { display: grid; grid-template-columns: 1fr; }
  .labels-filters .labels-search, .label-provider-filter { width: 100%; }
  .order-customer-column, .order-label-column { display: none; }
  .bulk-action-controls { display: grid; grid-template-columns: 1fr; }
  .bulk-action-controls > label { display: none; }
  .bulk-action-controls select, .bulk-action-controls button { width: 100%; }
  .order-products-list { min-width: 225px; }
  .order-product-thumb { width: 34px; height: 43px; }
  .order-summary-band { grid-template-columns: 1fr; }
  .original-shipping-card, .label-detail-card { grid-template-columns: 1fr 1fr; gap: 12px; }
  #ordersTable tr { grid-template-areas: "select reference action" "products products products"; }
  #ordersTable .order-products-list, .labels-table .order-products-list { min-width: 0; }
  .label-edit-item { grid-template-columns: 34px minmax(0, 1fr) 30px; }
  .label-edit-item-image { width: 34px; height: 42px; }
  .label-edit-item label { grid-column: 2; }
  .label-edit-item > button { grid-column: 3; grid-row: 1; }
  .sync-pending-pill { white-space: normal; text-align: right; }
}

/* Produção — telas aprovadas */
.production-lead { align-items: center; }
.production-lead .section-label { display: none; }
.production-panel, .production-queue-panel { overflow: hidden; border-radius: 0; }
.production-kpi-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); }
.production-kpi { min-height: 106px; display: grid; align-content: center; gap: 7px; padding: 18px 22px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.production-kpi:nth-child(3n) { border-right: 0; }
.production-kpi span { color: #858585; font-size: 8px; font-weight: 700; letter-spacing: 1.25px; }
.production-kpi strong { font-size: 29px; font-weight: 500; letter-spacing: -1px; }
.production-kpi small { color: #999; font-size: 9px; }
.production-kpi.danger strong { color: var(--red); }
.production-kpi.success strong { color: var(--green); }
.production-ranking-grid { display: grid; grid-template-columns: 30px 58px minmax(170px,1fr) 145px 120px 95px 95px 200px; align-items: center; gap: 10px; }
.production-ranking-head { padding: 11px 18px; color: #9299a7; background: #fafbfc; border-bottom: 1px solid var(--line); font-size: 8px; font-weight: 700; letter-spacing: .7px; text-transform: uppercase; }
.production-ranking-row { min-height: 75px; padding: 10px 18px; border-bottom: 1px solid #f1f1f1; }
.production-position { color: #a0a0a0; font-size: 11px; }
.production-thumb { width: 44px; height: 52px; display: grid; place-items: center; overflow: hidden; border: 1px solid #ececec; color: #999; background: #f7f7f7; font-size: 8px; }
.production-thumb img, .production-print-thumb img { width: 100%; height: 100%; object-fit: contain; background: white; }
.production-model { min-width: 0; display: grid; gap: 4px; }
.production-model b { overflow: hidden; font-size: 12px; text-overflow: ellipsis; white-space: nowrap; }
.production-model small { color: #888; font-size: 10px; line-height: 1.5; }
.production-status-chip { width: fit-content; max-width: 100%; min-height: 30px; display: inline-flex; align-items: center; padding: 0 8px; border: 1px solid #e6e6e6; border-left-width: 3px; border-left-style: solid; color: #3a3a3a; background: #fbfbfb; font-size: 9px; font-weight: 700; letter-spacing: .4px; text-transform: uppercase; white-space: nowrap; }
.production-impact { display: grid; gap: 4px; }
.production-impact i { height: 4px; display: block; overflow: hidden; background: #ededed; }
.production-impact i span { height: 100%; display: block; background: #111; }
.production-impact small { color: #999; font-size: 8px; }
.production-unlocks, .production-delay, .production-modals { color: #929292; font-size: 10px; font-weight: 600; }
.production-unlocks.active { color: var(--green); }
.production-delay.late, .production-order-lines .late { color: var(--red); }
.production-action { height: 33px; display: grid; grid-template-columns: minmax(0,1fr) 34px; border: 1px solid #e6e6e6; border-left-width: 3px; border-left-style: solid; background: #fbfbfb; }
.production-action button { min-width: 0; padding: 0 10px; overflow: hidden; border: 0; background: transparent; color: #3a3a3a; font-size: 8px; font-weight: 700; text-align: left; text-overflow: ellipsis; text-transform: uppercase; white-space: nowrap; }
.production-action button:hover { background: #f2f2f2; }
.production-action .production-action-menu { width: 34px; padding: 0; border-left: 1px solid #ececec; color: #777; text-align: center; }

.production-filters { display: grid; padding: 7px 18px 0; }
.production-filter-row { min-height: 54px; display: grid; grid-template-columns: 104px minmax(0,1fr); align-items: center; gap: 12px; border-bottom: 1px solid #f2f2f2; }
.production-filter-row > span { color: #a5a5a5; font-size: 7px; font-weight: 700; letter-spacing: 1.2px; }
.production-filter-row > div { display: flex; flex-wrap: wrap; gap: 8px; }
.production-filter-chip, .production-modal-chip { min-height: 30px; padding: 0 12px; border: 1px solid #e5e5e5; border-left: 3px solid #aaa; border-radius: 0; color: #666; background: #fff; font-size: 9px; font-weight: 700; }
.production-filter-chip b { min-width: 20px; display: inline-grid; place-items: center; margin-left: 6px; padding: 2px 5px; background: #f3f3f3; font-size: 7px; }
.production-filter-chip[data-production-filter="nao_informado"] { border-left-color: #bdbdbd; }
.production-filter-chip[data-production-filter="so_tecido"] { border-left-color: #7a4a26; }
.production-filter-chip[data-production-filter="separado"] { border-left-color: #5b4bb2; }
.production-filter-chip[data-production-filter="cortada"] { border-left-color: #c2560c; }
.production-filter-chip[data-production-filter="na_costura"] { border-left-color: #1f4fbf; }
.production-filter-chip[data-production-filter="falta_molde"] { border-left-color: #b52f3e; }
.production-filter-chip[data-production-filter="esperando_estamparia"] { border-left-color: #b52f3e; }
.production-filter-chip[data-production-filter="falta_tecido"] { border-left-color: #b52f3e; }
.production-filter-chip[data-production-filter="falta_aviamento"] { border-left-color: #b52f3e; }
.production-filter-chip.active, .production-modal-chip.active { border-color: #111; color: #fff; background: #111; }
.production-filter-search { min-height: 58px; display: flex; align-items: center; gap: 8px; }
.production-filter-search .search-box { width: 280px; height: 36px; border-radius: 0; }
.production-modal-chip { border-left-width: 1px; }
.production-modal-chip#productionLateFilter.active { border-color: var(--red); background: var(--red); }
.production-selection-bar { min-height: 52px; display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 9px 18px; border-block: 1px solid #ece9ae; background: var(--accent-soft); }
.production-selection-bar strong { font-size: 10px; }
.production-selection-bar > div { display: flex; gap: 7px; }
.production-queue-group { border-bottom: 1px solid #ededed; }
.production-queue-group.selected { background: #fcfcf3; }
.production-queue-main { min-height: 76px; display: grid; grid-template-columns: 25px 30px 48px minmax(220px,1fr) 76px 150px 130px 120px 120px; align-items: center; gap: 10px; padding: 10px 18px; }
.production-quantity { display: flex; align-items: baseline; gap: 5px; }
.production-quantity b { font-size: 21px; font-weight: 500; }
.production-quantity small { color: #888; font-size: 8px; }
.production-order-lines { padding: 0 18px 10px 167px; }
.production-order-lines > div { min-height: 29px; display: grid; grid-template-columns: 150px minmax(140px,1fr) 140px 85px 105px; align-items: center; gap: 10px; border-top: 1px solid #f3f3f3; font-size: 10px; }
.production-order-lines b { font-size: 11px; }
.production-order-lines span { overflow: hidden; color: #777; text-overflow: ellipsis; white-space: nowrap; }

.labels-table { min-width: 1500px; }
.operations-table .label-production-column { min-width: 215px; }
.label-production-list { display: grid; gap: 9px; }
.label-production-control { min-height: 48px; display: grid; align-content: center; gap: 3px; }
.label-production-control > small { padding-left: 8px; color: #888; font-size: 7px; }
.production-status-trigger { width: 100%; height: 30px; display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 0 9px; overflow: hidden; border: 1px solid #e6e6e6; border-left-width: 3px; border-left-style: solid; border-radius: 0; color: #3a3a3a; background: #fbfbfb; font-size: 9px; font-weight: 700; letter-spacing: .4px; text-align: left; text-transform: uppercase; }
.production-status-trigger:hover { filter: brightness(.97); }
.production-status-trigger span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.production-status-trigger i { flex: 0 0 auto; font-size: 7px; font-style: normal; opacity: .6; }
.production-status-trigger.saving { opacity: .55; }
.label-production-control .split-production-button { width: fit-content; margin-left: 8px; padding: 2px 0; border: 0; color: #686868; background: transparent; font-size: 7px; text-decoration: underline; text-underline-offset: 2px; }
.production-status-menu { position: fixed; z-index: 300; width: 210px; padding: 6px; border: 1px solid #dcdcdc; background: #fff; box-shadow: 0 12px 30px rgba(0,0,0,.12); }
.production-status-menu[hidden] { display: none; }
.production-status-menu button { width: 100%; min-height: 34px; display: flex; align-items: center; padding: 7px 10px; border: 0; border-left: 3px solid #999; color: #333; background: transparent; font-size: 10px; font-weight: 600; text-align: left; }
.production-status-menu button:hover { background: #f5f5f5; }
.production-status-menu button.current { background: #f6f6f6; }
.production-progress { min-width: 150px; display: grid; gap: 7px; }
.production-progress > div { display: flex; align-items: baseline; gap: 6px; }
.production-progress > div b { font-size: 17px; }
.production-progress > div small { color: #888; font-size: 8px; }
.production-progress > i { height: 3px; display: block; background: #ededed; }
.production-progress > i span { height: 100%; display: block; background: #111; }
.production-progress > strong { color: #555; font-size: 8px; letter-spacing: .35px; text-transform: uppercase; }
.production-progress.problem > i span { background: var(--red); }
.production-progress.problem > strong { color: var(--red); }
.production-progress.ready > i span { background: var(--green); }
.production-progress.ready > strong { color: var(--green); }
.production-progress em { width: fit-content; padding: 3px 5px; color: #655d00; background: var(--accent-soft); font-size: 7px; font-style: normal; font-weight: 700; }
.production-progress > small { color: var(--red); font-size: 8px; line-height: 1.4; }

.production-print-sheet { display: none; }
.shipment-checklist-toolbar { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 12px; padding: 16px 20px; border-bottom: 1px solid #ddd; }
.shipment-checklist-toolbar small { display: block; margin-top: 4px; color: #666; }
.shipment-checklist-toolbar button { white-space: normal; }
.shipment-checklist-note { margin: 8px 0; font-size: 10px; color: #444; }
.shipment-checklist-table { width: 100%; border-collapse: collapse; table-layout: fixed; font-size: 11px; }
.shipment-checklist-table thead { display: table-header-group; }
.shipment-checklist-table tr { break-inside: avoid; page-break-inside: avoid; }
.shipment-checklist-table th, .shipment-checklist-table td { padding: 6px 5px; border: 1px solid #bbb; text-align: left; vertical-align: top; overflow-wrap: anywhere; }
.shipment-checklist-table th { background: #eee; }
.shipment-checklist-table small { display: block; margin-top: 3px; font-size: 9px; }
.shipment-checklist-box { display: inline-block; width: 11px; height: 11px; border: 1px solid #111; }
/* Folha de corte: as regras valem fora do @media print para o JS medir cada bloco antes de paginar (ver productionPrintPages). */
.production-print-sheet, .production-print-measure { color: #111; font-family: Inter, Arial, sans-serif; }
.production-print-measure { position: absolute; top: 0; left: -10000px; width: 194mm; visibility: hidden; pointer-events: none; }
.production-print-measure > div { display: flow-root; }
.production-print-page { min-height: 279mm; display: flex; flex-direction: column; break-inside: avoid; break-after: page; }
.production-print-page:last-child { break-after: auto; }
.production-print-page main { flex: 1; }
.production-print-header { display: flex; align-items: end; justify-content: space-between; padding-bottom: 7px; border-bottom: 2px solid #111; }
.production-print-header > div:first-child { display: grid; gap: 4px; }
.production-print-header > div:last-child { display: grid; gap: 4px; text-align: right; }
.production-print-header span { font-size: 10px; font-weight: 700; letter-spacing: 1.8px; }
.production-print-header h1 { margin: 0; font-size: 22px; font-weight: 500; letter-spacing: -.5px; }
.production-print-header p { margin: 0; font-size: 10px; }
.production-print-header b { font-size: 14px; }
.production-print-header-continued { min-height: 28px; align-items: center; padding-bottom: 4px; }
.production-print-header-continued h1 { font-size: 14px; font-weight: 600; }
.production-print-fabric { break-inside: auto; }
.production-print-band { display: flex; align-items: center; justify-content: space-between; margin-top: 6px; padding: 4px 8px; break-after: avoid; background: #111 !important; color: #fff !important; }
.production-print-band b { font-size: 11px; letter-spacing: .6px; text-transform: uppercase; }
.production-print-band span { font-size: 10px; }
.production-print-model { display: grid; grid-template-columns: 22px 52px minmax(0, 1fr); gap: 0 7px; padding: 6px 0; border-bottom: 1px solid #d6d6d6; break-inside: avoid; }
.production-print-staged-model { break-inside: avoid; }
.production-print-stage { margin-top: 5px; padding: 3px 6px; border: 1px solid #aaa; background: #eee !important; color: #111; font-size: 11px; font-weight: 700; }
.shipment-checklist-actions { display: grid; gap: 8px; flex-shrink: 0; }
.production-print-position { padding-top: 3px; color: #444; font-size: 13px; }
.production-print-image { width: 52px; height: 60px; display: grid; place-items: center; overflow: hidden; border: 1px solid #ececec; color: #777; font-size: 12px; font-weight: 700; }
.production-print-image img { width: 100%; height: 100%; object-fit: contain; }
.production-print-model-content { min-width: 0; }
.production-print-model-top { display: grid; grid-template-columns: minmax(0, 1fr) auto 20px; align-items: center; gap: 8px; margin-bottom: 4px; }
.production-print-model-top > strong { overflow: hidden; font-size: 13px; text-overflow: ellipsis; white-space: nowrap; }
.production-print-model-top > span { white-space: nowrap; }
.production-print-model-top > span b { font-size: 18px; }
.production-print-model-top > span small { color: #555; font-size: 10px; }
.production-print-box-large { width: 18px; height: 18px; border: 1.5px solid #111; }
.production-print-color { display: flex; align-items: center; gap: 5px; overflow: hidden; font-size: 10px; font-weight: 700; white-space: nowrap; }
.production-print-color > svg { flex: none; width: 12px; height: 12px; overflow: visible; }
.production-print-grid { border-top: 1px solid #ddd; border-left: 1px solid #ddd; }
.production-print-grid-head, .production-print-grid-row { display: grid; grid-template-columns: minmax(105px,1fr) repeat(var(--production-print-sizes, 5),36px) 42px; }
.production-print-grid-head > *, .production-print-grid-row > * { height: 19px; display: flex; align-items: center; justify-content: center; border-right: 1px solid #ddd; border-bottom: 1px solid #ddd; font-size: 10px; }
.production-print-grid-head > * { height: 16px; font-size: 9px; }
.production-print-grid-head > :first-child, .production-print-grid-row > :first-child { justify-content: flex-start; padding-left: 8px; }
.production-print-grid-head { background: #eee !important; }
.production-print-orders { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); column-gap: 10px; margin-top: 3px; }
.production-print-orders > div { display: grid; grid-template-columns: 10px 48px minmax(0, 1fr) 42px 24px; gap: 4px; align-items: center; height: 17px; border-bottom: 1px solid #eee; font-size: 10px; }
.production-print-orders > div > span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.production-print-orders i { width: 10px; height: 10px; border: 1px solid #111; }
.production-print-orders strong { display: inline-flex; justify-content: center; border: 1px solid #333; padding: 1px 2px; font-size: 9px; }
.production-print-orders > .production-print-order-priority,
.production-print-orders > .production-print-order-batch { height: auto; min-height: 30px; padding: 3px 2px; align-content: start; }
.production-print-orders > .production-print-order-priority { background: #f5f7c5 !important; border: 1px solid #555; print-color-adjust: exact; -webkit-print-color-adjust: exact; }
.production-print-order-purpose { grid-column: 2 / -1; color: #111; font-size: 8px; font-weight: 700; white-space: normal; }
.production-print-header .production-print-priority-legend { max-width: 520px; font-size: 9px; line-height: 1.3; }
.production-print-locked-row { display: grid; grid-template-columns: 72px minmax(0,1fr) 170px; align-items: center; gap: 16px; padding: 14px 0; border-bottom: 1px solid #ccc; break-inside: avoid; }
.production-print-locked-row > div { display: grid; gap: 5px; }
.production-print-locked-row > div > span { font-size: 11px; color: #555; }
.production-print-locked-row > strong { padding: 8px 10px; border: 2px solid #9b1c48; color: #9b1c48; text-align: center; text-transform: uppercase; }
.production-print-footer { display: grid; grid-template-columns: 1fr auto 1fr; gap: 18px; padding-top: 8px; color: #555; font-size: 9px; }
.production-print-footer span:last-child { text-align: right; }
@media print {
  @page { size: A4 portrait; margin: 8mm; }
  body.printing-production-sheet { background: #fff; }
  body.printing-production-sheet .app-shell { display: block !important; min-height: 0; }
  body.printing-production-sheet .sidebar,
  body.printing-production-sheet .main > :not(.production-print-sheet),
  body.printing-production-sheet .toast,
  body.printing-production-sheet dialog { display: none !important; }
  body.printing-production-sheet .main { width: 100%; min-width: 0; display: block; padding: 0; margin: 0; }
  body.printing-production-sheet .production-print-sheet { width: 100%; display: block; -webkit-print-color-adjust: exact; print-color-adjust: exact; }
}

@media (max-width: 1180px) {
  .production-panel, .production-queue-panel { overflow-x: auto; }
  .production-kpi-grid { min-width: 900px; }
  .production-ranking-head, .production-ranking-row { min-width: 1180px; }
  .production-queue-panel { overflow-x: hidden; }
  .production-filters, .production-selection-bar, #productionQueue { min-width: 0; max-width: 100%; }
  .team-user-form { grid-template-columns: 1fr 1fr; }
  .team-user-form button { min-height: 40px; }
}

@media (max-width: 760px) {
  .auth-screen { grid-template-columns: 1fr; }
  .auth-brand-panel { display: none; }
  .auth-main-panel { padding: 26px 22px 20px; }
  .auth-mobile-brand { display: flex; align-items: center; gap: 10px; margin-bottom: 34px; font-size: 10px; letter-spacing: 1px; }
  .auth-mobile-brand img { width: 34px; height: 34px; }
  .auth-tabs { margin-bottom: 32px; }
  .auth-page-form h2 { font-size: 28px; }
}

@media (max-width: 760px) {
  .production-lead { align-items: stretch; flex-direction: column; }
  .production-queue-lead .primary-button { width: 100%; }
  .production-panel, .production-queue-panel { overflow: visible; }
  .production-kpi-grid { min-width: 0; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .production-kpi { min-height: 112px; padding: 15px; }
  .production-kpi:nth-child(3n) { border-right: 1px solid var(--line); }
  .production-kpi:nth-child(2n) { border-right: 0; }
  .production-kpi span { line-height: 1.35; }
  .production-kpi small { line-height: 1.35; }
  .production-ranking-head { display: none; }
  .production-ranking-row { min-width: 0; grid-template-columns: 24px 44px minmax(0, 1fr); grid-template-areas: "position thumb model" "status status status" "impact unlocks delay" "action action action"; gap: 10px; padding: 14px 12px; }
  .production-ranking-row > :nth-child(1) { grid-area: position; }
  .production-ranking-row > :nth-child(2) { grid-area: thumb; }
  .production-ranking-row > :nth-child(3) { grid-area: model; }
  .production-ranking-row > :nth-child(4) { grid-area: status; }
  .production-ranking-row > :nth-child(5) { grid-area: impact; }
  .production-ranking-row > :nth-child(6) { grid-area: unlocks; }
  .production-ranking-row > :nth-child(7) { grid-area: delay; text-align: right; }
  .production-ranking-row > :nth-child(8) { grid-area: action; }
  .production-action { width: 100%; }
  .production-filters, .production-selection-bar, #productionQueue { min-width: 0; }
  .production-filters { padding-inline: 12px; }
  .production-filter-row { grid-template-columns: 1fr; gap: 7px; padding-block: 12px; }
  .production-filter-search { align-items: stretch; flex-direction: column; padding-block: 12px; }
  .production-filter-search .search-box { width: 100%; }
  .production-selection-bar { align-items: stretch; flex-direction: column; }
  .production-selection-bar > div { display: grid; grid-template-columns: 1fr; }
  .production-queue-main { grid-template-columns: 22px 24px 44px minmax(0,1fr); grid-template-areas: "position select thumb model" "quantity status status status" "impact impact delay delay" "modals modals modals modals"; gap: 9px; padding: 13px 12px; }
  .production-queue-main > :nth-child(1) { grid-area: position; }
  .production-queue-main > :nth-child(2) { grid-area: select; }
  .production-queue-main > :nth-child(3) { grid-area: thumb; }
  .production-queue-main > :nth-child(4) { grid-area: model; }
  .production-queue-main > :nth-child(5) { grid-area: quantity; }
  .production-queue-main > :nth-child(6) { grid-area: status; }
  .production-queue-main > :nth-child(7) { grid-area: impact; }
  .production-queue-main > :nth-child(8) { grid-area: delay; text-align: right; }
  .production-queue-main > :nth-child(9) { grid-area: modals; }
  .production-order-lines { padding: 0 12px 12px; }
  .production-order-lines > div { grid-template-columns: auto minmax(0, 1fr); gap: 5px 10px; padding: 9px 0; }
  .production-order-lines > div > :nth-child(n+3) { grid-column: 2; }
  .labels-table .label-production-column { display: block; grid-area: production; padding-top: 10px; border-top: 1px solid #eee; }
  .labels-table tr { grid-template-areas: "select reference action" "products products products" "production production production" "state state state"; }
  .label-production-list { grid-template-columns: 1fr; }
}
