:root{
  --sidebar:#0F1338;
  --sidebar-2:#151a4a;
  --bg:#f4f7fb;
  --card:#ffffff;
  --text:#172033;
  --muted:#6b7280;
  --line:#e7ecf4;
  --blue:#2563eb;
  --cyan:#06b6d4;
  --green:#10b981;
  --amber:#f59e0b;
  --red:#ef4444;
  --purple:#8b5cf6;
  --pink:#ec4899;
  --shadow:0 18px 45px rgba(15,23,42,.08);
  --radius:22px;
}
*{box-sizing:border-box}body{margin:0;font-family:Inter,Segoe UI,system-ui,-apple-system,sans-serif;background:var(--bg);color:var(--text);min-height:100vh;overflow-x:hidden}.sidebar{position:fixed;inset:0 auto 0 0;width:310px;background:radial-gradient(circle at 30% 0%,rgba(37,99,235,.18),transparent 30%),linear-gradient(180deg,var(--sidebar),#07091d 100%);color:#fff;display:flex;flex-direction:column;padding:22px 16px;z-index:20}.brand{display:flex;align-items:center;gap:14px;padding:10px 10px 22px}.brand img{width:68px;height:48px;object-fit:contain;border-radius:12px;background:#0b0e2b}.brand strong{display:block;font-size:16px;letter-spacing:.4px}.brand span{font-size:12px;color:#aab3df}.side-nav{overflow:auto;padding-right:4px}.nav-group{margin:8px 0;border:1px solid rgba(255,255,255,.06);border-radius:18px;background:rgba(255,255,255,.03)}.group-head{width:100%;border:0;background:transparent;color:#fff;display:flex;align-items:center;gap:12px;padding:14px 13px;cursor:pointer;font-weight:700;text-align:left}.group-head i:first-child{width:22px;color:#9fb5ff}.group-head .chev{margin-left:auto;transition:.28s}.nav-group.open .chev{transform:rotate(90deg)}.group-items{display:none;padding:2px 8px 12px}.nav-group.open .group-items{display:block}.nav-item,.sub-head{width:100%;border:0;background:transparent;color:#ccd4ff;display:flex;align-items:center;gap:10px;padding:11px 12px;border-radius:13px;cursor:pointer;text-align:left;font-size:13px;transition:.25s}.nav-item:hover,.sub-head:hover,.nav-item.active{background:rgba(255,255,255,.09);color:#fff;transform:translateX(2px)}.nav-item.active{box-shadow:inset 3px 0 0 #68e1fd}.sub-section{margin-top:5px}.sub-head{font-weight:700;color:#fff;background:rgba(255,255,255,.04)}.sub-items{margin-left:14px;border-left:1px solid rgba(255,255,255,.08);padding-left:8px;display:block}.side-footer{margin-top:auto;padding:16px 10px;color:#b9c2ee}.system-status{display:flex;align-items:center;gap:8px;font-size:13px;margin-bottom:8px}.system-status span{width:9px;height:9px;border-radius:50%;background:var(--green);box-shadow:0 0 0 6px rgba(16,185,129,.15)}.app-shell{margin-left:310px;min-height:100vh;padding:28px 32px 150px}.topbar{height:82px;display:flex;align-items:center;justify-content:space-between;gap:20px}.eyebrow{margin:0 0 5px;color:var(--muted);font-size:13px;font-weight:700;text-transform:uppercase;letter-spacing:.08em}.topbar h1{margin:0;font-size:30px;line-height:1.1}.top-actions{display:flex;align-items:center;gap:12px}.ghost-btn,.icon-btn,.user-btn,.primary-btn,.secondary-btn,.danger-btn{border:0;border-radius:16px;background:#fff;color:var(--text);box-shadow:0 8px 20px rgba(15,23,42,.06);height:44px;padding:0 16px;display:inline-flex;align-items:center;gap:9px;cursor:pointer;font-weight:800;transition:.25s}.ghost-btn:hover,.icon-btn:hover,.user-btn:hover,.primary-btn:hover,.secondary-btn:hover{transform:translateY(-2px);box-shadow:var(--shadow)}.primary-btn{background:linear-gradient(135deg,var(--blue),var(--cyan));color:#fff}.secondary-btn{background:#eef4ff;color:#1d4ed8}.danger-btn{background:#fee2e2;color:#991b1b}.icon-btn{width:44px;padding:0;justify-content:center;position:relative}.badge{position:absolute;top:-6px;right:-7px;background:var(--red);color:#fff;border-radius:999px;font-size:11px;min-width:20px;height:20px;display:grid;place-items:center;border:2px solid #fff}.avatar{width:32px;height:32px;border-radius:50%;display:grid;place-items:center;background:linear-gradient(135deg,#0f1338,#2563eb);color:#fff;font-weight:900}.notification-wrap,.user-wrap{position:relative}.dropdown-panel{position:absolute;right:0;top:54px;width:340px;background:#fff;border:1px solid var(--line);border-radius:20px;box-shadow:var(--shadow);padding:12px;display:none;z-index:40}.dropdown-panel.open{display:block;animation:pop .18s ease}.user-menu{width:220px}.user-menu button,.notif-item{width:100%;border:0;background:transparent;text-align:left;padding:12px;border-radius:12px;display:flex;gap:10px;align-items:flex-start;cursor:pointer}.user-menu button:hover,.notif-item:hover{background:#f5f7fb}.danger{color:var(--red)}.notif-item.unread{background:#eef6ff}.notif-item strong{font-size:13px}.notif-item small{display:block;color:var(--muted);margin-top:3px}.page-content{animation:fadeUp .35s ease}.grid{display:grid;gap:18px}.kpi-grid{grid-template-columns:repeat(4,minmax(0,1fr));margin:22px 0}.two-col{grid-template-columns:1.45fr .85fr}.three-col{grid-template-columns:repeat(3,minmax(0,1fr))}.card{background:var(--card);border:1px solid var(--line);border-radius:var(--radius);box-shadow:0 12px 30px rgba(15,23,42,.045);padding:20px;position:relative;overflow:hidden}.card h3{margin:0 0 14px}.card-sub{color:var(--muted);font-size:13px;margin-top:-7px;margin-bottom:16px}.kpi{min-height:142px}.kpi:after{content:"";position:absolute;right:-28px;top:-28px;width:98px;height:98px;border-radius:50%;background:var(--accent,rgba(37,99,235,.12));opacity:.55}.kpi-label{color:var(--muted);font-weight:800;font-size:13px}.kpi-value{font-size:30px;font-weight:900;margin:10px 0 4px}.trend{font-size:12px;font-weight:800}.trend.up{color:var(--green)}.trend.warn{color:var(--amber)}.table-wrap{overflow:auto}.data-table{width:100%;border-collapse:separate;border-spacing:0 10px}.data-table th{text-align:left;font-size:11px;color:var(--muted);text-transform:uppercase;letter-spacing:.06em;padding:0 10px}.data-table td{background:#f9fbff;padding:13px 10px;border-top:1px solid #edf2fb;border-bottom:1px solid #edf2fb;font-size:13px}.data-table td:first-child{border-left:1px solid #edf2fb;border-radius:14px 0 0 14px}.data-table td:last-child{border-right:1px solid #edf2fb;border-radius:0 14px 14px 0}.pill{display:inline-flex;align-items:center;gap:6px;padding:6px 10px;border-radius:999px;font-size:12px;font-weight:900}.pill.blue{background:#dbeafe;color:#1d4ed8}.pill.green{background:#dcfce7;color:#166534}.pill.amber{background:#fef3c7;color:#92400e}.pill.red{background:#fee2e2;color:#991b1b}.pill.purple{background:#ede9fe;color:#6d28d9}.row-actions{display:flex;gap:8px}.mini-btn{border:0;border-radius:10px;background:#eef2ff;color:#293b8f;width:34px;height:34px;cursor:pointer}.mini-btn.red{background:#fee2e2;color:#b91c1c}.form-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:14px}.field{display:flex;flex-direction:column;gap:7px}.field label{font-size:12px;color:var(--muted);font-weight:900;text-transform:uppercase;letter-spacing:.04em}.field input,.field select,.field textarea{border:1px solid var(--line);background:#fbfdff;border-radius:14px;min-height:44px;padding:10px 12px;font:inherit;outline:none;transition:.2s}.field textarea{min-height:96px;resize:vertical}.field input:focus,.field select:focus,.field textarea:focus{border-color:#8ab4ff;box-shadow:0 0 0 4px rgba(37,99,235,.08)}.section-actions{display:flex;gap:10px;flex-wrap:wrap;margin-top:16px}.flow-strip{display:flex;gap:10px;overflow:auto;padding:12px 0}.flow-node{min-width:135px;background:#fff;border:1px solid var(--line);border-radius:18px;padding:13px;box-shadow:0 8px 18px rgba(15,23,42,.04);position:relative}.flow-node:after{content:"";position:absolute;right:-8px;top:37px;width:16px;height:2px;background:#cbd5e1}.flow-node:last-child:after{display:none}.flow-node strong{display:block;font-size:13px}.flow-node small{display:block;color:var(--muted);margin-top:5px}.flow-node.active{background:linear-gradient(135deg,#0f1338,#1d4ed8);color:#fff;transform:translateY(-5px)}.flow-node.active small{color:#dce7ff}.kanban-week{display:grid;grid-template-columns:repeat(7,minmax(190px,1fr));gap:14px;overflow:auto}.day-col{background:#f7faff;border:1px solid var(--line);border-radius:20px;padding:12px;min-height:410px}.day-col h4{margin:0 0 10px;display:flex;justify-content:space-between}.job-card{background:#fff;border:1px solid #e5edfb;border-radius:16px;padding:12px;margin-bottom:10px;box-shadow:0 8px 18px rgba(15,23,42,.04);cursor:grab}.job-card strong{display:block;font-size:13px}.job-card span{display:block;color:var(--muted);font-size:12px;margin:5px 0}.job-card .bar{height:7px;border-radius:999px;background:linear-gradient(90deg,var(--blue),var(--green));margin-top:10px}.timeline{display:grid;gap:12px}.step-card{display:grid;grid-template-columns:44px 1fr auto;gap:14px;align-items:center;background:#fff;border:1px solid var(--line);border-radius:18px;padding:14px}.step-icon{width:44px;height:44px;border-radius:14px;display:grid;place-items:center;background:#eef4ff;color:#1d4ed8}.progress{height:10px;background:#edf2f7;border-radius:999px;overflow:hidden}.progress span{display:block;height:100%;background:linear-gradient(90deg,var(--green),var(--cyan));border-radius:999px}.chat-page{display:grid;grid-template-columns:1fr 360px;gap:18px}.chat-window{height:560px;overflow:auto;background:#fff;border:1px solid var(--line);border-radius:var(--radius);padding:18px}.msg{max-width:78%;padding:14px 16px;border-radius:18px;margin:12px 0;line-height:1.45}.msg.ai{background:#eef6ff;color:#173b78}.msg.human{background:#0f1338;color:#fff;margin-left:auto}.ai-dock{position:fixed;left:342px;right:32px;bottom:22px;background:rgba(255,255,255,.88);backdrop-filter:blur(14px);border:1px solid rgba(226,232,240,.9);box-shadow:var(--shadow);border-radius:24px;padding:13px;display:grid;grid-template-columns:310px 1fr;gap:12px;z-index:15}.ai-context{display:flex;align-items:center;gap:12px}.ai-avatar{width:42px;height:42px;border-radius:15px;background:linear-gradient(135deg,var(--purple),var(--blue));color:#fff;display:grid;place-items:center}.ai-context span{display:block;color:var(--muted);font-size:12px}.ai-input{display:flex;gap:8px}.ai-input input{flex:1;border:1px solid var(--line);border-radius:16px;padding:0 14px;font:inherit}.ai-input button{width:48px;border:0;border-radius:16px;background:var(--sidebar);color:#fff}.ai-response{grid-column:1/-1;background:#f7faff;border-radius:16px;padding:11px 14px;color:#475569;font-size:13px}.toast{position:fixed;right:28px;bottom:140px;background:#0f1338;color:#fff;border-radius:16px;padding:14px 18px;box-shadow:var(--shadow);opacity:0;transform:translateY(12px);transition:.25s;z-index:80}.toast.show{opacity:1;transform:translateY(0)}@keyframes fadeUp{from{opacity:0;transform:translateY(12px)}to{opacity:1;transform:translateY(0)}}@keyframes pop{from{opacity:0;transform:translateY(-6px) scale(.98)}to{opacity:1;transform:translateY(0) scale(1)}}@media(max-width:1100px){.sidebar{width:260px}.app-shell{margin-left:260px}.kpi-grid,.two-col,.three-col,.form-grid,.chat-page{grid-template-columns:1fr}.ai-dock{left:280px;grid-template-columns:1fr}.topbar{height:auto;align-items:flex-start;flex-direction:column}.top-actions{width:100%;flex-wrap:wrap}}@media(max-width:760px){.sidebar{position:relative;width:100%;height:auto}.app-shell{margin-left:0;padding:18px 16px 180px}.ai-dock{left:16px;right:16px;bottom:14px}.brand img{width:58px}.top-actions{gap:8px}.ghost-btn span,.user-btn span:not(.avatar){display:none}}


/* PATCH MIJ RESPONSIVE BRANDING */
:root {
  --nav: #0F1338;
  --nav-2: #0F1338;
  --soft-motion: cubic-bezier(.16, 1, .3, 1);
}

/* Sidebar na cor oficial */
.sidebar {
  background:
    radial-gradient(circle at 30% 0%, rgba(255,255,255,.08), transparent 22rem),
    linear-gradient(180deg, #0F1338 0%, #0F1338 100%) !important;
  transition: transform .42s var(--soft-motion), box-shadow .42s var(--soft-motion);
}

.sidebar::after {
  background: rgba(244,176,0,.12) !important;
}

/* Logo mais limpo */
.brand-logo-block {
  display: block;
  padding: 4px 8px 24px;
  text-align: left;
}

.brand-logo {
  width: 100%;
  max-width: 214px;
  display: block;
  border-radius: 14px;
  object-fit: contain;
  background: #0F1338;
  filter: drop-shadow(0 14px 20px rgba(0,0,0,.18));
}

.brand-logo-block small {
  display: block;
  margin-top: 12px;
  color: #aeb7d8;
  font-weight: 850;
  font-size: 11px;
  letter-spacing: .13em;
  text-transform: uppercase;
}

/* Movimentos mais suaves e modernos */
.page {
  animation: pageSoftIn .62s var(--soft-motion) both;
}

@keyframes pageSoftIn {
  from {
    opacity: 0;
    transform: translateY(18px) scale(.985);
    filter: blur(4px);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
    filter: blur(0);
  }
}

.card,
.kpi,
.status-panel,
.hero-card,
.stage-card,
.flow-stage,
.step,
.route-point,
.machine,
.btn,
.nav-btn,
.chip,
.avatar,
.search {
  transition:
    transform .32s var(--soft-motion),
    box-shadow .32s var(--soft-motion),
    border-color .32s var(--soft-motion),
    background .32s var(--soft-motion),
    opacity .32s var(--soft-motion);
}

.card:hover,
.status-panel:hover {
  transform: translateY(-3px);
  box-shadow: 0 24px 55px rgba(15,23,42,.08);
}

.nav-btn:hover {
  background: rgba(255,255,255,.095);
  transform: translateX(6px);
}

.nav-btn.active {
  background: linear-gradient(135deg, rgba(244,176,0,.96), rgba(255,216,106,.9)) !important;
  color: #111827 !important;
  box-shadow: 0 16px 30px rgba(244,176,0,.22);
}

.nav-btn.active span.icon {
  background: rgba(15,19,56,.12) !important;
}

.btn:active {
  transform: translateY(0) scale(.985);
}

input,
select,
textarea {
  transition: border-color .25s var(--soft-motion), box-shadow .25s var(--soft-motion), transform .25s var(--soft-motion);
}

input:focus,
select:focus,
textarea:focus {
  transform: translateY(-1px);
}

/* Animação de entrada por scroll */
.reveal-card {
  opacity: 0;
  transform: translateY(18px);
}

.reveal-card.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* Botão de menu mobile */
.mobile-menu-toggle {
  display: none;
  position: fixed;
  top: 16px;
  left: 16px;
  width: 48px;
  height: 48px;
  border: 0;
  border-radius: 16px;
  background: #0F1338;
  box-shadow: 0 18px 36px rgba(15,19,56,.22);
  z-index: 1001;
  cursor: pointer;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 5px;
}

.mobile-menu-toggle span {
  width: 22px;
  height: 2px;
  border-radius: 99px;
  background: #fff;
  transition: transform .28s var(--soft-motion), opacity .28s var(--soft-motion);
}

body.menu-open .mobile-menu-toggle span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

body.menu-open .mobile-menu-toggle span:nth-child(2) {
  opacity: 0;
}

body.menu-open .mobile-menu-toggle span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

.mobile-overlay {
  display: none;
}

/* Responsivo real: sidebar vira drawer mobile */
@media (max-width: 1180px) {
  .app {
    display: block !important;
    grid-template-columns: 1fr !important;
  }

  .mobile-menu-toggle {
    display: flex;
  }

  .mobile-overlay {
    display: block;
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, .42);
    backdrop-filter: blur(5px);
    opacity: 0;
    pointer-events: none;
    transition: opacity .32s var(--soft-motion);
    z-index: 998;
  }

  body.menu-open .mobile-overlay {
    opacity: 1;
    pointer-events: auto;
  }

  .sidebar {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    width: min(86vw, 320px) !important;
    height: 100dvh !important;
    z-index: 999 !important;
    padding: 82px 18px 24px !important;
    overflow-y: auto !important;
    transform: translateX(-108%);
    box-shadow: none;
  }

  body.menu-open .sidebar {
    transform: translateX(0);
    box-shadow: 28px 0 70px rgba(15,19,56,.34);
  }

  .sidebar-card {
    position: relative !important;
    left: auto !important;
    right: auto !important;
    bottom: auto !important;
    margin-top: 16px !important;
  }

  .nav-section {
    display: block !important;
  }

  .nav-title {
    grid-column: auto !important;
  }

  .main {
    padding: 84px 18px 44px !important;
  }

  .topbar {
    gap: 12px;
  }

  .search {
    min-width: 100% !important;
  }

  .hero,
  .grid-2 {
    grid-template-columns: 1fr !important;
  }

  .kpi-grid,
  .grid-3 {
    grid-template-columns: repeat(2, minmax(0,1fr)) !important;
  }

  .flow-board {
    grid-template-columns: 1fr !important;
  }

  .connector {
    width: 5px !important;
    height: 22px !important;
    margin: auto !important;
  }
}

@media (max-width: 720px) {
  .topbar {
    align-items: stretch !important;
    flex-direction: column !important;
  }

  .top-actions {
    justify-content: flex-start !important;
  }

  .kpi-grid,
  .grid-3,
  .form-grid {
    grid-template-columns: 1fr !important;
  }

  .hero-card {
    padding: 22px !important;
    border-radius: 26px !important;
  }

  h1 {
    font-size: 36px !important;
  }

  h2 {
    font-size: 28px !important;
  }

  .card {
    border-radius: 22px !important;
    padding: 18px !important;
  }

  table {
    display: block;
    overflow-x: auto;
    white-space: nowrap;
  }

  .ai-input {
    flex-direction: column;
  }

  .sidebar-card {
    display: block !important;
  }
}

@media (min-width: 1181px) {
  .mobile-menu-toggle,
  .mobile-overlay {
    display: none !important;
  }
}

/* Respeita usuários com redução de movimento */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
    scroll-behavior: auto !important;
  }
}


/* PATCH PEDIDOS MIJ V1 */
.erp-brand-only {
  padding: 10px 8px 30px !important;
}

.erp-brand-text {
  font-size: clamp(54px, 5vw, 82px);
  line-height: .82;
  letter-spacing: -.09em;
  font-weight: 950;
  color: #ffffff;
  text-shadow: 0 22px 45px rgba(0,0,0,.28);
}

.erp-brand-only small {
  max-width: 210px;
  line-height: 1.35;
}

.page-head-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 22px;
  margin-bottom: 22px;
}

.section-title.compact {
  margin-bottom: 0;
}

.page-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 10px;
  padding-top: 8px;
}

.orders-filter-card {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr .9fr;
  gap: 14px;
  background: #ffffff;
  border: 1px solid #e5e7eb;
  border-radius: 26px;
  padding: 18px;
  box-shadow: 0 18px 42px rgba(15, 23, 42, .05);
  margin-bottom: 22px;
}

.filter-group {
  display: grid;
  gap: 8px;
}

.filter-group label {
  font-size: 12px;
  font-weight: 900;
  color: #64748b;
  text-transform: uppercase;
  letter-spacing: .08em;
}

.orders-kpi-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
  margin-bottom: 22px;
}

.order-kpi .value {
  font-size: clamp(26px, 3vw, 38px);
}

.orders-insights {
  margin-bottom: 22px;
}

.mini-horizontal-chart {
  display: grid;
  gap: 16px;
  padding-top: 8px;
}

.chart-row {
  display: grid;
  grid-template-columns: 92px 1fr 44px;
  align-items: center;
  gap: 12px;
  font-size: 13px;
  font-weight: 850;
  color: #334155;
}

.chart-row > div {
  height: 13px;
  border-radius: 99px;
  background: #eef2f7;
  overflow: hidden;
}

.chart-row i {
  display: block;
  height: 100%;
  border-radius: 99px;
  animation: mijBarIn .7s cubic-bezier(.16, 1, .3, 1) both;
}

@keyframes mijBarIn {
  from { width: 0; }
}

.chart-row b {
  text-align: right;
  color: #0f172a;
}

.ai-summary-box {
  background: linear-gradient(135deg, #f8fafc, #eff6ff);
  border: 1px solid #dbeafe;
  border-radius: 22px;
  padding: 18px;
}

.ai-summary-box b {
  display: block;
  color: #1d4ed8;
  margin-bottom: 8px;
}

.ai-summary-box p {
  color: #475569;
  line-height: 1.58;
  font-size: 14px;
  font-weight: 650;
}

.ai-tags {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 14px;
}

.ai-tags span {
  background: #ffffff;
  border: 1px solid #dbeafe;
  color: #1e3a8a;
  border-radius: 99px;
  padding: 7px 10px;
  font-size: 11px;
  font-weight: 900;
}

.orders-table-card {
  margin-top: 0;
}

.table-responsive {
  width: 100%;
  overflow-x: auto;
  border-radius: 18px;
}

.orders-table {
  min-width: 980px;
}

.orders-table td b {
  color: #0f172a;
}

.action-buttons {
  display: flex;
  gap: 7px;
  white-space: nowrap;
}

.mini-action {
  border: 1px solid #e5e7eb;
  background: #ffffff;
  color: #334155;
  border-radius: 11px;
  padding: 8px 10px;
  cursor: pointer;
  font-size: 12px;
  font-weight: 900;
  transition: transform .25s cubic-bezier(.16, 1, .3, 1), background .25s cubic-bezier(.16, 1, .3, 1), border-color .25s cubic-bezier(.16, 1, .3, 1);
}

.mini-action:hover {
  transform: translateY(-2px);
  background: #f8fafc;
  border-color: #cbd5e1;
}

.mini-action.danger {
  color: #b91c1c;
}

.order-form-card {
  max-width: 1180px;
}

.order-create-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.order-form-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.page-ai-footer {
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  gap: 14px;
  align-items: center;
  margin-top: 22px;
  background: #0F1338;
  color: #ffffff;
  border-radius: 26px;
  padding: 18px;
  box-shadow: 0 24px 60px rgba(15, 19, 56, .16);
}

.page-ai-footer b {
  display: block;
  margin-bottom: 5px;
}

.page-ai-footer p {
  color: #cbd5e1;
  font-size: 13px;
  line-height: 1.5;
  margin: 0;
}

.page-ai-input {
  display: flex;
  gap: 10px;
}

.page-ai-input input {
  width: 100%;
  background: rgba(255,255,255,.08);
  color: #fff;
  border-color: rgba(255,255,255,.16);
}

.page-ai-input input::placeholder {
  color: #aeb7d8;
}

.page-ai-answer {
  grid-column: 1 / -1;
  display: none;
  background: rgba(255,255,255,.08);
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 18px;
  padding: 14px;
  color: #e5e7eb;
  font-size: 13px;
  font-weight: 750;
  line-height: 1.5;
}

.page-ai-answer.show {
  display: block;
  animation: pageSoftIn .35s cubic-bezier(.16, 1, .3, 1) both;
}

@media (max-width: 1180px) {
  .page-head-row {
    flex-direction: column;
  }

  .page-actions {
    justify-content: flex-start;
    width: 100%;
  }

  .page-actions .btn {
    width: 100%;
  }

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

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

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

  .page-ai-footer {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 720px) {
  .erp-brand-text {
    font-size: 54px;
  }

  .orders-filter-card,
  .orders-kpi-grid,
  .order-create-grid {
    grid-template-columns: 1fr;
  }

  .orders-filter-card {
    border-radius: 22px;
    padding: 14px;
  }

  .page-actions .btn,
  .order-form-actions .btn {
    width: 100%;
  }

  .page-ai-input {
    flex-direction: column;
  }

  .chart-row {
    grid-template-columns: 82px 1fr 38px;
    gap: 8px;
  }

  .orders-table {
    min-width: 920px;
  }
}


/* PATCH PEDIDOS LÓGICA SEM MUDAR LAYOUT */
.orders-top-actions{
  justify-content:flex-end;
  margin-bottom:18px;
}
.orders-filter-card{
  margin-bottom:18px;
}
.orders-kpi-row{
  margin-bottom:18px;
}
.mini-chart-list{
  display:grid;
  gap:14px;
  margin-top:12px;
}
.mini-chart-row{
  display:grid;
  grid-template-columns:120px 1fr 48px;
  gap:12px;
  align-items:center;
  font-weight:800;
  color:#334155;
  font-size:13px;
}
.mini-chart-row b{
  height:12px;
  border-radius:99px;
  background:#eef2f7;
  overflow:hidden;
  display:block;
}
.mini-chart-row i{
  display:block;
  height:100%;
  border-radius:99px;
  background:linear-gradient(90deg,#2563eb,#22c55e);
}
.mini-chart-row strong{
  text-align:right;
}
@media(max-width:720px){
  .orders-top-actions{
    justify-content:stretch;
  }
  .orders-top-actions button{
    width:100%;
  }
  .mini-chart-row{
    grid-template-columns:90px 1fr 40px;
  }
}


/* PATCH FLUXO PEDIDO IB COMPANY */
.flow-sim-panel{
  overflow:hidden;
}
.flow-sim-strip{
  display:grid;
  grid-template-columns:repeat(9,minmax(120px,1fr));
  gap:10px;
  overflow-x:auto;
  padding:8px 0 14px;
}
.flow-sim-step{
  min-width:120px;
  border:1px solid #e5e7eb;
  background:#fff;
  border-radius:16px;
  padding:12px;
  display:grid;
  gap:8px;
  transition:.25s ease;
}
.flow-sim-step span{
  width:28px;
  height:28px;
  border-radius:50%;
  display:grid;
  place-items:center;
  background:#eef2ff;
  color:#1e40af;
  font-weight:900;
  font-size:12px;
}
.flow-sim-step b{
  font-size:12px;
  line-height:1.25;
  color:#334155;
}
.flow-sim-step.active{
  border-color:#2563eb;
  background:linear-gradient(135deg,#eff6ff,#ffffff);
  box-shadow:0 16px 32px rgba(37,99,235,.12);
}
.flow-sim-step.done{
  border-color:#bbf7d0;
  background:#f0fdf4;
}
.flow-sim-step.done span{
  background:#22c55e;
  color:#fff;
}
@media(max-width:720px){
  .flow-sim-strip{
    grid-template-columns:1fr;
    overflow-x:visible;
  }
  .flow-sim-step{
    min-width:0;
  }
}


/* PATCH LOGO + FILTROS PEDIDOS */
.brand,
.brand-logo-block,
.logo-area,
.sidebar-logo,
.app-logo {
  min-height: auto;
}

/* Mantém o logo real maior no desktop */
.brand img,
.brand-logo,
.sidebar-logo img,
.logo-area img,
.app-logo img {
  width: 78px !important;
  max-width: 78px !important;
  height: auto !important;
  object-fit: contain !important;
  display: block !important;
}

/* Texto ao lado/baixo do logo: apenas ERP, pequeno */
.brand strong,
.brand-title,
.logo-title,
.sidebar-logo-title,
.brand-name {
  font-size: 13px !important;
  line-height: 1.1 !important;
  font-weight: 900 !important;
  letter-spacing: .04em !important;
}

.brand small,
.brand-subtitle,
.logo-subtitle,
.sidebar-logo-subtitle,
.brand p,
.logo-area p,
.app-logo p {
  font-size: 10px !important;
  line-height: 1.1 !important;
  font-weight: 800 !important;
  letter-spacing: .08em !important;
  text-transform: uppercase !important;
  opacity: .78 !important;
}

/* Se o HTML usa texto puro Factory ERP, força visual pequeno */
.brand {
  gap: 10px !important;
}

/* Mobile: usa o ícone mobile quando houver imagem padrão */
@media (max-width: 1180px) {
  .brand img,
  .brand-logo,
  .sidebar-logo img,
  .logo-area img,
  .app-logo img {
    content: url("../img/made-in-japa-logo-mobile.png");
    width: 54px !important;
    max-width: 54px !important;
  }

  .brand strong,
  .brand-title,
  .logo-title,
  .sidebar-logo-title,
  .brand-name {
    font-size: 12px !important;
  }

  .brand small,
  .brand-subtitle,
  .logo-subtitle,
  .sidebar-logo-subtitle,
  .brand p,
  .logo-area p,
  .app-logo p {
    font-size: 9px !important;
  }
}

/* ---------------------------------------------------------
   FILTROS DA PÁGINA PEDIDOS
   Mantém o layout atual, mas deixa a área mais bonita,
   proporcional e responsiva.
--------------------------------------------------------- */

.orders-filter-card {
  padding: 18px !important;
  border-radius: 22px !important;
  background:
    linear-gradient(180deg, rgba(255,255,255,.98), rgba(248,250,252,.98)) !important;
  border: 1px solid rgba(226,232,240,.95) !important;
  box-shadow: 0 18px 42px rgba(15,23,42,.045) !important;
}

.orders-filter-card .form-grid {
  display: grid !important;
  grid-template-columns: minmax(260px, 1.45fr) repeat(3, minmax(170px, 1fr)) !important;
  gap: 14px !important;
  align-items: end !important;
}

.orders-filter-card .field {
  display: flex !important;
  flex-direction: column !important;
  gap: 7px !important;
  min-width: 0 !important;
}

.orders-filter-card label {
  font-size: 10.5px !important;
  letter-spacing: .12em !important;
  text-transform: uppercase !important;
  color: #64748b !important;
  font-weight: 950 !important;
  margin: 0 !important;
}

.orders-filter-card input,
.orders-filter-card select {
  width: 100% !important;
  height: 44px !important;
  border-radius: 14px !important;
  background: #fff !important;
  border: 1px solid #e2e8f0 !important;
  padding: 0 14px !important;
  font-size: 13px !important;
  font-weight: 700 !important;
  color: #0f172a !important;
  box-shadow: inset 0 1px 0 rgba(15,23,42,.02) !important;
}

.orders-filter-card input:focus,
.orders-filter-card select:focus {
  border-color: #2563eb !important;
  box-shadow: 0 0 0 4px rgba(37,99,235,.10) !important;
  outline: none !important;
}

/* Corrige o botão Fazer pedido quando aparece pequeno */
.orders-top-actions {
  display: flex !important;
  justify-content: flex-end !important;
  align-items: center !important;
  gap: 10px !important;
  margin: -2px 0 18px !important;
}

.orders-top-actions .primary-btn,
.orders-top-actions .secondary-btn {
  min-height: 42px !important;
  border-radius: 14px !important;
  padding: 0 16px !important;
  font-size: 13px !important;
  font-weight: 900 !important;
}

/* Responsivo real dos filtros */
@media (max-width: 1180px) {
  .orders-filter-card .form-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }

  .orders-top-actions {
    justify-content: stretch !important;
  }

  .orders-top-actions .primary-btn,
  .orders-top-actions .secondary-btn {
    flex: 1 !important;
  }
}

@media (max-width: 720px) {
  .orders-filter-card {
    padding: 14px !important;
    border-radius: 20px !important;
  }

  .orders-filter-card .form-grid {
    grid-template-columns: 1fr !important;
    gap: 12px !important;
  }

  .orders-filter-card input,
  .orders-filter-card select {
    height: 46px !important;
    font-size: 14px !important;
  }

  .orders-top-actions {
    flex-direction: column !important;
    align-items: stretch !important;
  }

  .orders-top-actions .primary-btn,
  .orders-top-actions .secondary-btn {
    width: 100% !important;
  }
}


/* PATCH LOGO REAL SEM FUNDO */
.brand img,
.brand-logo,
.sidebar-logo img,
.logo-area img,
.app-logo img {
  content: url("../img/made-in-japan-logo.png") !important;
  width: 96px !important;
  max-width: 96px !important;
  height: auto !important;
  object-fit: contain !important;
  background: transparent !important;
  border: 0 !important;
  border-radius: 0 !important;
  box-shadow: none !important;
  filter: drop-shadow(0 10px 16px rgba(0,0,0,.18)) !important;
}

.brand,
.brand-logo-block,
.logo-area,
.sidebar-logo,
.app-logo {
  background: transparent !important;
  box-shadow: none !important;
}

.brand strong,
.brand-title,
.logo-title,
.sidebar-logo-title,
.brand-name {
  font-size: 12px !important;
  line-height: 1.1 !important;
  font-weight: 900 !important;
  letter-spacing: .05em !important;
}

.brand small,
.brand-subtitle,
.logo-subtitle,
.sidebar-logo-subtitle,
.brand p,
.logo-area p,
.app-logo p {
  font-size: 9px !important;
  line-height: 1.1 !important;
  font-weight: 800 !important;
  letter-spacing: .08em !important;
  text-transform: uppercase !important;
  opacity: .72 !important;
}

/* texto pequeno, só ERP */
.brand small::before,
.brand-subtitle::before,
.logo-subtitle::before {
  content: "ERP";
}

.brand small,
.brand-subtitle,
.logo-subtitle {
  font-size: 0 !important;
}

.brand small::before,
.brand-subtitle::before,
.logo-subtitle::before {
  font-size: 9px !important;
}

@media (max-width: 1180px) {
  .brand img,
  .brand-logo,
  .sidebar-logo img,
  .logo-area img,
  .app-logo img {
    content: url("../img/made-in-japa-logo-mobile.png") !important;
    width: 64px !important;
    max-width: 64px !important;
    background: transparent !important;
    border: 0 !important;
    border-radius: 0 !important;
    box-shadow: none !important;
  }
}


/* PATCH DASHBOARD FILTROS + MERCADOS */
.dashboard-filters {
  margin-bottom: 18px !important;
  padding: 16px !important;
  border-radius: 24px !important;
  background: linear-gradient(180deg, #ffffff, #f8fafc) !important;
}

.dashboard-filters .form-grid {
  display: grid !important;
  grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
  gap: 14px !important;
}

.dashboard-filters .field {
  display: flex !important;
  flex-direction: column !important;
  gap: 7px !important;
}

.dashboard-filters label {
  font-size: 10.5px !important;
  letter-spacing: .12em !important;
  text-transform: uppercase !important;
  color: #64748b !important;
  font-weight: 950 !important;
}

.dashboard-filters select,
.dashboard-filters input {
  height: 44px !important;
  border-radius: 14px !important;
  border: 1px solid #e2e8f0 !important;
  background: #fff !important;
  padding: 0 14px !important;
  font-size: 13px !important;
  font-weight: 750 !important;
  color: #0f172a !important;
}

.market-chart {
  display: grid;
  gap: 18px;
  margin-top: 12px;
}

.market-row {
  display: grid;
  grid-template-columns: minmax(180px, 1fr) 1.2fr 54px;
  gap: 14px;
  align-items: center;
}

.market-row strong {
  display: block;
  color: #0f172a;
  font-size: 14px;
  font-weight: 950;
}

.market-row small {
  display: block;
  margin-top: 3px;
  color: #64748b;
  font-size: 12px;
  line-height: 1.35;
}

.market-row b {
  height: 15px;
  border-radius: 99px;
  background: #eef2f7;
  overflow: hidden;
  display: block;
}

.market-row i {
  height: 100%;
  display: block;
  border-radius: 99px;
  background: linear-gradient(90deg, #2563eb, #22c55e);
  animation: marketBarIn .7s cubic-bezier(.16,1,.3,1) both;
}

.market-row.japanese i {
  background: linear-gradient(90deg, #f59e0b, #ef4444);
}

.market-row span {
  text-align: right;
  color: #0f172a;
  font-weight: 950;
}

@keyframes marketBarIn {
  from { width: 0; }
}

@media (max-width: 1180px) {
  .dashboard-filters .form-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }

  .market-row {
    grid-template-columns: 1fr;
    gap: 8px;
  }

  .market-row span {
    text-align: left;
  }
}

@media (max-width: 720px) {
  .dashboard-filters .form-grid {
    grid-template-columns: 1fr !important;
  }
}


/* PATCH PEDIDOS REALFLOW + LOCALSTORAGE */
.orders-filter-card {
  padding: 18px 20px !important;
  border-radius: 24px !important;
  background: linear-gradient(180deg, #ffffff, #f8fafc) !important;
  border: 1px solid #dfe7f2 !important;
  box-shadow: 0 16px 42px rgba(15,23,42,.045) !important;
}

.orders-filter-card .form-grid {
  width: 100% !important;
  display: grid !important;
  grid-template-columns: minmax(320px, 2fr) minmax(220px, 1.15fr) minmax(220px, 1.15fr) minmax(220px, 1.15fr) !important;
  gap: 16px !important;
  align-items: end !important;
}

.orders-filter-card .field {
  min-width: 0 !important;
}

.orders-filter-card label {
  display: block !important;
  margin-bottom: 8px !important;
  font-size: 11px !important;
  letter-spacing: .13em !important;
  text-transform: uppercase !important;
  color: #64748b !important;
  font-weight: 950 !important;
}

.orders-filter-card input,
.orders-filter-card select {
  width: 100% !important;
  height: 52px !important;
  border-radius: 16px !important;
  border: 1px solid #d8e1ee !important;
  background: #ffffff !important;
  padding: 0 16px !important;
  font-size: 14px !important;
  font-weight: 800 !important;
  color: #0f172a !important;
  box-shadow: inset 0 1px 0 rgba(15,23,42,.025) !important;
}

.orders-filter-card input:focus,
.orders-filter-card select:focus {
  border-color: #2563eb !important;
  box-shadow: 0 0 0 4px rgba(37,99,235,.10) !important;
  outline: none !important;
}

.order-form-clean {
  grid-template-columns: repeat(3, minmax(0,1fr)) !important;
  gap: 16px !important;
}

.order-form-clean .field label {
  font-size: 11px !important;
  letter-spacing: .11em !important;
  text-transform: uppercase !important;
  color: #64748b !important;
  font-weight: 950 !important;
}

.order-form-clean input,
.order-form-clean select {
  height: 50px !important;
  border-radius: 15px !important;
  font-size: 14px !important;
  font-weight: 750 !important;
}

.flow-sim-panel .card-sub,
.flow-sim-panel .ai-response {
  font-size: 14px !important;
}

@media(max-width:1180px){
  .orders-filter-card .form-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }

  .order-form-clean {
    grid-template-columns: repeat(2, minmax(0,1fr)) !important;
  }
}

@media(max-width:720px){
  .orders-filter-card {
    padding: 14px !important;
  }

  .orders-filter-card .form-grid,
  .order-form-clean {
    grid-template-columns: 1fr !important;
  }

  .orders-filter-card input,
  .orders-filter-card select,
  .order-form-clean input,
  .order-form-clean select {
    height: 48px !important;
  }
}


/* PATCH LOGO MAIOR + FAVICON */
.mij-logo-forced picture {
  width: 126px !important;
  min-width: 126px !important;
  max-width: 126px !important;
}

.mij-logo-forced img {
  width: 126px !important;
  max-width: 126px !important;
}

.mij-logo-forced span {
  font-size: 13px !important;
  letter-spacing: .12em !important;
}

/* versão mobile do logo */
@media (max-width: 1180px) {
  .mij-logo-forced picture,
  .mij-logo-forced img {
    width: 84px !important;
    min-width: 84px !important;
    max-width: 84px !important;
  }

  .mij-logo-forced span {
    font-size: 12px !important;
  }
}


/* PATCH MOBILE MENU DEFINITIVO */

/* Desliga botões antigos que foram testados antes */
#mobileMenuDots,
.mobile-menu-dots,
.mobile-menu-toggle,
#mobileMenuToggle {
  display: none !important;
}

#mijMobileMenuBtn,
#mijMobileMenuOverlay {
  display: none;
}

@media (max-width: 1180px) {
  body {
    overflow-x: hidden !important;
  }

  #mijMobileMenuBtn {
    display: flex !important;
    position: fixed !important;
    top: 16px !important;
    left: 16px !important;
    z-index: 10050 !important;
    width: 50px !important;
    height: 50px !important;
    border: none !important;
    border-radius: 16px !important;
    background: #0F1338 !important;
    box-shadow: 0 18px 42px rgba(15, 19, 56, .34) !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 4px !important;
    padding: 0 !important;
    cursor: pointer !important;
  }

  #mijMobileMenuBtn span {
    display: block !important;
    width: 6px !important;
    height: 6px !important;
    border-radius: 999px !important;
    background: #ffffff !important;
    transition: transform .25s ease, opacity .25s ease, background .25s ease !important;
  }

  body.mij-mobile-menu-open #mijMobileMenuBtn span:nth-child(1) {
    transform: translateX(10px) scale(.75);
    opacity: .55;
  }

  body.mij-mobile-menu-open #mijMobileMenuBtn span:nth-child(2) {
    background: #facc15 !important;
    transform: scale(1.28);
  }

  body.mij-mobile-menu-open #mijMobileMenuBtn span:nth-child(3) {
    transform: translateX(-10px) scale(.75);
    opacity: .55;
  }

  #mijMobileMenuOverlay {
    display: block !important;
    position: fixed !important;
    inset: 0 !important;
    z-index: 10020 !important;
    background: rgba(15, 23, 42, .46) !important;
    backdrop-filter: blur(5px) !important;
    opacity: 0 !important;
    pointer-events: none !important;
    transition: opacity .3s cubic-bezier(.16, 1, .3, 1) !important;
  }

  body.mij-mobile-menu-open #mijMobileMenuOverlay {
    opacity: 1 !important;
    pointer-events: auto !important;
  }

  /* Sidebar/drawer mobile */
  aside,
  .sidebar {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    width: min(88vw, 330px) !important;
    height: 100dvh !important;
    z-index: 10030 !important;
    transform: translateX(-112%) !important;
    transition: transform .36s cubic-bezier(.16, 1, .3, 1), box-shadow .36s cubic-bezier(.16, 1, .3, 1) !important;
    overflow-y: auto !important;
    overflow-x: hidden !important;
    box-shadow: none !important;
    padding-top: 72px !important;
  }

  body.mij-mobile-menu-open aside,
  body.mij-mobile-menu-open .sidebar {
    transform: translateX(0) !important;
    box-shadow: 28px 0 70px rgba(15, 19, 56, .40) !important;
  }

  /* Conteúdo ocupa tela toda no mobile */
  .app,
  .layout,
  body > .app {
    display: block !important;
    grid-template-columns: 1fr !important;
  }

  main,
  .main,
  .main-content,
  .content {
    width: 100% !important;
    margin-left: 0 !important;
  }

  .topbar,
  header.topbar,
  .page-header {
    padding-left: 68px !important;
  }
}

@media (min-width: 1181px) {
  #mijMobileMenuBtn,
  #mijMobileMenuOverlay {
    display: none !important;
  }

  body.mij-mobile-menu-open aside,
  body.mij-mobile-menu-open .sidebar {
    transform: none !important;
  }
}


/* PATCH PREPARAÇÃO LISTA + FORMS */
.prep-top-actions{
  justify-content:flex-end;
  margin-bottom:18px;
}
.prep-kpi-row{
  margin-bottom:18px;
}
.prep-filter-card{
  margin-bottom:18px;
  padding:18px 20px !important;
  border-radius:24px !important;
  background:linear-gradient(180deg,#ffffff,#f8fafc) !important;
  border:1px solid #dfe7f2 !important;
  box-shadow:0 16px 42px rgba(15,23,42,.045) !important;
}
.prep-filter-card .form-grid{
  width:100% !important;
  display:grid !important;
  grid-template-columns:minmax(320px,2fr) minmax(220px,1.15fr) minmax(220px,1.15fr) minmax(220px,1.15fr) !important;
  gap:16px !important;
  align-items:end !important;
}
.prep-filter-card label{
  display:block !important;
  margin-bottom:8px !important;
  font-size:11px !important;
  letter-spacing:.13em !important;
  text-transform:uppercase !important;
  color:#64748b !important;
  font-weight:950 !important;
}
.prep-filter-card input,
.prep-filter-card select{
  width:100% !important;
  height:52px !important;
  border-radius:16px !important;
  border:1px solid #d8e1ee !important;
  background:#fff !important;
  padding:0 16px !important;
  font-size:14px !important;
  font-weight:800 !important;
  color:#0f172a !important;
}
.prep-form-grid{
  grid-template-columns:repeat(3,minmax(0,1fr)) !important;
  gap:16px !important;
}
.prep-form-grid input,
.prep-form-grid select,
.prep-form-grid textarea{
  height:50px !important;
  border-radius:15px !important;
  font-size:14px !important;
  font-weight:750 !important;
}
.prep-form-grid label{
  font-size:11px !important;
  letter-spacing:.11em !important;
  text-transform:uppercase !important;
  color:#64748b !important;
  font-weight:950 !important;
}
@media(max-width:1180px){
  .prep-filter-card .form-grid,
  .prep-form-grid{
    grid-template-columns:repeat(2,minmax(0,1fr)) !important;
  }
}
@media(max-width:720px){
  .prep-top-actions{
    flex-direction:column;
    align-items:stretch;
  }
  .prep-top-actions button{
    width:100%;
  }
  .prep-filter-card .form-grid,
  .prep-form-grid{
    grid-template-columns:1fr !important;
  }
}


/* PATCH PLANEJAMENTO IA + JUNBI */
.flow-explain{
  display:grid;
  gap:12px;
  margin-top:12px;
}
.flow-explain div{
  display:grid;
  grid-template-columns:34px 1fr;
  gap:8px 12px;
  align-items:center;
  padding:12px;
  border:1px solid #e5e7eb;
  border-radius:16px;
  background:#fff;
}
.flow-explain span{
  grid-row:span 2;
  width:34px;
  height:34px;
  border-radius:50%;
  background:#eff6ff;
  color:#1d4ed8;
  display:grid;
  place-items:center;
  font-weight:950;
}
.flow-explain b{
  color:#0f172a;
}
.flow-explain small{
  color:#64748b;
  line-height:1.35;
}
.planning-table td[contenteditable="true"]{
  background:#fff;
  outline:none;
  cursor:text;
}
.planning-table td[contenteditable="true"]:focus{
  box-shadow: inset 0 0 0 2px rgba(37,99,235,.18);
  border-radius:8px;
}
.junbi-checklist{
  display:grid;
  gap:10px;
  margin:14px 0;
}
.junbi-checklist label{
  display:flex;
  align-items:center;
  gap:10px;
  padding:12px;
  border:1px solid #e5e7eb;
  background:#fff;
  border-radius:14px;
  font-weight:800;
  color:#334155;
}
.junbi-checklist input{
  width:18px;
  height:18px;
}
@media(max-width:720px){
  .flow-explain div{
    grid-template-columns:30px 1fr;
  }
}


/* PATCH JUNBI LISTA -> DETALHE */
.junbi-list-note{
  margin-top:10px;
}
@media(max-width:720px){
  .junbi-checklist label{
    align-items:flex-start;
  }
}


/* PATCH PRÉ-PRODUÇÃO BOARD DRAG + DETALHE */
.preprod-board{
  display:grid;
  grid-template-columns:repeat(7,minmax(180px,1fr));
  gap:14px;
  overflow-x:auto;
  padding-bottom:4px;
}
.preprod-day{
  min-width:180px;
  background:#f8fafc;
  border:1px solid #e5e7eb;
  border-radius:22px;
  padding:12px;
}
.preprod-day h4{
  display:flex;
  align-items:center;
  justify-content:space-between;
  margin:0 0 12px;
  color:#0f172a;
}
.preprod-dropzone{
  display:grid;
  gap:10px;
  min-height:160px;
}
.preprod-card{
  background:#fff;
  border:1px solid #e5e7eb;
  border-radius:16px;
  padding:12px;
  cursor:grab;
  display:grid;
  gap:5px;
  box-shadow:0 10px 22px rgba(15,23,42,.045);
  transition:transform .22s ease, box-shadow .22s ease, border-color .22s ease;
}
.preprod-card:hover{
  transform:translateY(-2px);
  border-color:#bfdbfe;
  box-shadow:0 16px 32px rgba(37,99,235,.10);
}
.preprod-card:active{
  cursor:grabbing;
}
.preprod-card strong{
  color:#0f172a;
  font-size:12px;
}
.preprod-card span{
  color:#334155;
  font-weight:900;
  font-size:13px;
}
.preprod-card small,
.preprod-card em{
  color:#64748b;
  font-size:11px;
  font-style:normal;
}
.preprod-card .bar{
  height:6px;
  border-radius:99px;
  background:linear-gradient(90deg,#2563eb,#22c55e);
  margin-top:4px;
}
@media(max-width:1180px){
  .preprod-board{
    grid-template-columns:repeat(4,minmax(180px,1fr));
  }
}
@media(max-width:720px){
  .preprod-board{
    grid-template-columns:1fr;
    overflow-x:visible;
  }
  .preprod-day{
    min-width:0;
  }
}


/* PATCH PRÉ-PRODUÇÃO BOARD VISUAL CORRETO */
.preproduction-kanban {
  align-items: stretch !important;
}

.preproduction-day {
  transition: border-color .25s ease, background .25s ease, transform .25s ease !important;
}

.preproduction-day:hover {
  border-color: #bfdbfe !important;
}

.preproduction-dropzone {
  display: grid !important;
  gap: 12px !important;
  min-height: 210px !important;
}

.preproduction-card {
  cursor: grab !important;
  user-select: none !important;
}

.preproduction-card:active,
.preproduction-card.dragging {
  cursor: grabbing !important;
}

.preproduction-card.dragging {
  opacity: .58 !important;
  transform: rotate(1deg) scale(.98) !important;
  border-color: #2563eb !important;
  box-shadow: 0 18px 40px rgba(37,99,235,.18) !important;
}

.preproduction-card small + small {
  margin-top: -2px !important;
}

.preproduction-card:hover {
  border-color: #bfdbfe !important;
  transform: translateY(-2px) !important;
  box-shadow: 0 16px 32px rgba(37,99,235,.10) !important;
}

/* remove/neutraliza visual anterior ruim caso tenha ficado no CSS */
.preprod-board,
.preprod-day,
.preprod-dropzone,
.preprod-card {
  all: unset;
}

@media(max-width:1180px){
  .preproduction-kanban {
    grid-template-columns: repeat(4, minmax(180px,1fr)) !important;
    overflow-x: auto !important;
  }
}

@media(max-width:720px){
  .preproduction-kanban {
    grid-template-columns: 1fr !important;
    overflow-x: visible !important;
  }
}


/* PATCH SEGURO - DETALHE PRÉ-PRODUÇÃO EDITÁVEL */
.editable-table td[contenteditable="true"] {
  background: #ffffff !important;
  cursor: text !important;
  outline: none !important;
  transition: box-shadow .2s ease, background .2s ease !important;
}

.editable-table td[contenteditable="true"]:hover {
  background: #f8fafc !important;
}

.editable-table td[contenteditable="true"]:focus {
  background: #eff6ff !important;
  box-shadow: inset 0 0 0 2px rgba(37,99,235,.20) !important;
  border-radius: 8px !important;
}

.field.full {
  grid-column: 1 / -1 !important;
}

.field textarea {
  min-height: 96px !important;
  resize: vertical !important;
  padding: 14px 16px !important;
  border-radius: 15px !important;
  border: 1px solid #d8e1ee !important;
  font-size: 14px !important;
  font-weight: 700 !important;
  color: #0f172a !important;
  background: #fff !important;
}

.preprod-save-footer {
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  gap: 18px !important;
}

.preprod-save-footer h3 {
  margin-bottom: 4px !important;
}

@media(max-width:720px){
  .preprod-save-footer {
    flex-direction: column !important;
    align-items: stretch !important;
  }

  .preprod-save-footer .primary-btn {
    width: 100% !important;
  }
}


/* PATCH PEDIDOS DOCUMENTOS -> PRODUTOS */
.orders-document-note {
  margin-top: 10px;
}

@media(max-width:720px){
  .orders-top-actions{
    flex-direction: column !important;
    align-items: stretch !important;
  }

  .orders-top-actions button{
    width: 100% !important;
  }
}


/* PATCH EDITAR DOCUMENTO DO PEDIDO */
.order-document-form-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
  gap: 16px !important;
}

.order-document-form-grid input,
.order-document-form-grid select,
.order-document-form-grid textarea {
  width: 100% !important;
  min-height: 50px !important;
  border-radius: 15px !important;
  font-size: 14px !important;
  font-weight: 750 !important;
}

.order-document-form-grid label {
  font-size: 11px !important;
  letter-spacing: .11em !important;
  text-transform: uppercase !important;
  color: #64748b !important;
  font-weight: 950 !important;
}

@media(max-width:1180px){
  .order-document-form-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }
}

@media(max-width:720px){
  .order-document-form-grid {
    grid-template-columns: 1fr !important;
  }
}


/* PATCH FINAL PEDIDOS: HIERARQUIA + PRAZO COMERCIAL */
.deadline-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 16px 18px;
  border-radius: 22px;
  margin-bottom: 18px;
  border: 1px solid #dbeafe;
  background: linear-gradient(135deg, #eff6ff, #ffffff);
  box-shadow: 0 16px 42px rgba(15,23,42,.045);
}

.deadline-card div {
  display: grid;
  gap: 4px;
}

.deadline-card span {
  font-size: 11px;
  font-weight: 950;
  color: #1d4ed8;
  text-transform: uppercase;
  letter-spacing: .12em;
}

.deadline-card strong {
  font-size: clamp(24px, 3vw, 38px);
  color: #0f172a;
  line-height: 1;
}

.deadline-card small {
  color: #64748b;
  font-weight: 800;
}

.deadline-card p {
  max-width: 520px;
  margin: 0;
  color: #475569;
  font-size: 13px;
  line-height: 1.5;
  font-weight: 700;
}

.deadline-card.closed {
  border-color: #fecaca;
  background: linear-gradient(135deg, #fff1f2, #ffffff);
}

.deadline-card.closed span {
  color: #b91c1c;
}

button[disabled] {
  opacity: .45 !important;
  cursor: not-allowed !important;
}

@media(max-width:720px){
  .deadline-card {
    flex-direction: column;
    align-items: flex-start;
  }
}


/* PATCH PEDIDOS - FORMULÁRIO DO PRODUTO DESBLOQUEADO PARA DEMONSTRAÇÃO */
.order-form-clean {
  grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
  gap: 16px !important;
}

.order-form-clean input,
.order-form-clean select,
.order-form-clean textarea {
  width: 100% !important;
  min-height: 50px !important;
  border-radius: 15px !important;
  font-size: 14px !important;
  font-weight: 750 !important;
}

.order-form-clean label {
  font-size: 11px !important;
  letter-spacing: .11em !important;
  text-transform: uppercase !important;
  color: #64748b !important;
  font-weight: 950 !important;
}

.order-form-clean textarea {
  min-height: 110px !important;
  padding: 14px 16px !important;
}

@media(max-width:1180px){
  .order-form-clean {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }
}

@media(max-width:720px){
  .order-form-clean {
    grid-template-columns: 1fr !important;
  }
}


/* PATCH PLANEJAMENTO IA - MESMA HIERARQUIA DE PEDIDOS */
.ai-planning-note {
  margin-top: 10px;
}

@media(max-width:720px){
  .prep-top-actions{
    flex-direction: column !important;
    align-items: stretch !important;
  }

  .prep-top-actions button{
    width: 100% !important;
  }
}


/* PATCH PLANEJAMENTO IA - ADICIONAR E DELETAR PRODUTO */
.ai-planning-product-form {
  grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
  gap: 16px !important;
}

.ai-planning-product-form input,
.ai-planning-product-form select,
.ai-planning-product-form textarea {
  width: 100% !important;
  min-height: 50px !important;
  border-radius: 15px !important;
  font-size: 14px !important;
  font-weight: 750 !important;
}

.ai-planning-product-form label {
  font-size: 11px !important;
  letter-spacing: .11em !important;
  text-transform: uppercase !important;
  color: #64748b !important;
  font-weight: 950 !important;
}

.ai-planning-product-form textarea {
  min-height: 110px !important;
  padding: 14px 16px !important;
}

@media(max-width:1180px){
  .ai-planning-product-form {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }
}

@media(max-width:720px){
  .ai-planning-product-form {
    grid-template-columns: 1fr !important;
  }
}


/* PATCH JUNBI - HIERARQUIA DOCUMENTAL */
.junbi-document-note {
  margin-top: 10px;
}

@media(max-width:720px){
  .prep-top-actions{
    flex-direction: column !important;
    align-items: stretch !important;
  }

  .prep-top-actions button{
    width: 100% !important;
  }
}


/* PATCH JUNBI DETALHE PREMIUM + SIMULAÇÃO CÓDIGO DE BARRAS */
.junbi-seasoning-premium {
  display: grid !important;
  gap: 12px !important;
  margin-top: 12px !important;
}

.junbi-seasoning-item {
  display: grid !important;
  grid-template-columns: 20px 42px 1fr auto !important;
  align-items: center !important;
  gap: 14px !important;
  padding: 14px !important;
  border: 1px solid #e2e8f0 !important;
  border-radius: 18px !important;
  background: linear-gradient(180deg, #ffffff, #f8fafc) !important;
  box-shadow: 0 12px 26px rgba(15,23,42,.045) !important;
  cursor: pointer !important;
  transition: transform .2s ease, border-color .2s ease, box-shadow .2s ease !important;
}

.junbi-seasoning-item:hover {
  transform: translateY(-2px) !important;
  border-color: #bfdbfe !important;
  box-shadow: 0 18px 36px rgba(37,99,235,.10) !important;
}

.junbi-seasoning-item input {
  width: 18px !important;
  height: 18px !important;
  accent-color: #2563eb !important;
}

.seasoning-index {
  width: 42px !important;
  height: 42px !important;
  border-radius: 14px !important;
  display: grid !important;
  place-items: center !important;
  background: #eff6ff !important;
  color: #1d4ed8 !important;
  font-weight: 950 !important;
  font-size: 12px !important;
}

.seasoning-info {
  display: grid !important;
  gap: 3px !important;
}

.seasoning-info strong {
  color: #0f172a !important;
  font-size: 14px !important;
  font-weight: 950 !important;
}

.seasoning-info span {
  color: #64748b !important;
  font-size: 12px !important;
  font-weight: 700 !important;
}

.seasoning-qty {
  min-width: 78px !important;
  display: grid !important;
  justify-items: end !important;
  gap: 2px !important;
  padding: 8px 10px !important;
  border-radius: 14px !important;
  background: #0f1338 !important;
  color: #fff !important;
}

.seasoning-qty b {
  font-size: 16px !important;
  line-height: 1 !important;
}

.seasoning-qty small {
  color: rgba(255,255,255,.74) !important;
  font-size: 10px !important;
  font-weight: 900 !important;
  text-transform: uppercase !important;
}

.junbi-seasoning-footer,
.junbi-barcode-note {
  display: flex !important;
  gap: 12px !important;
  align-items: flex-start !important;
  margin-top: 14px !important;
  padding: 14px !important;
  border-radius: 18px !important;
  border: 1px solid #dbeafe !important;
  background: #eff6ff !important;
}

.junbi-seasoning-footer i,
.junbi-barcode-note i {
  width: 34px !important;
  height: 34px !important;
  border-radius: 12px !important;
  display: grid !important;
  place-items: center !important;
  background: #2563eb !important;
  color: #fff !important;
  flex: 0 0 auto !important;
}

.junbi-seasoning-footer strong,
.junbi-barcode-note strong {
  display: block !important;
  color: #0f172a !important;
  font-size: 13px !important;
  font-weight: 950 !important;
  margin-bottom: 3px !important;
}

.junbi-seasoning-footer p,
.junbi-barcode-note p {
  margin: 0 !important;
  color: #475569 !important;
  font-size: 12px !important;
  line-height: 1.5 !important;
  font-weight: 700 !important;
}

.junbi-weight-panel {
  display: grid !important;
  grid-template-columns: repeat(3, minmax(0,1fr)) !important;
  gap: 12px !important;
  margin-bottom: 12px !important;
}

.junbi-weight-panel div {
  padding: 14px !important;
  border-radius: 18px !important;
  border: 1px solid #e2e8f0 !important;
  background: linear-gradient(180deg,#ffffff,#f8fafc) !important;
}

.junbi-weight-panel span {
  display: block !important;
  color: #64748b !important;
  font-size: 10px !important;
  font-weight: 950 !important;
  text-transform: uppercase !important;
  letter-spacing: .12em !important;
  margin-bottom: 6px !important;
}

.junbi-weight-panel strong {
  display: block !important;
  color: #0f172a !important;
  font-size: 24px !important;
  line-height: 1 !important;
  font-weight: 950 !important;
}

.junbi-progress {
  height: 12px !important;
  border-radius: 999px !important;
  background: #eef2f7 !important;
  overflow: hidden !important;
  margin-bottom: 14px !important;
}

.junbi-progress b {
  display: block !important;
  height: 100% !important;
  border-radius: 999px !important;
  background: linear-gradient(90deg, #2563eb, #22c55e) !important;
  transition: width .28s ease !important;
}

.junbi-pallet-table tr.is-read {
  background: #f0fdf4 !important;
}

.junbi-pallet-table tr.is-read td {
  color: #166534 !important;
}

@media(max-width:720px){
  .junbi-seasoning-item {
    grid-template-columns: 20px 36px 1fr !important;
  }

  .seasoning-qty {
    grid-column: 3 / 4 !important;
    justify-self: start !important;
    margin-top: 6px !important;
  }

  .junbi-weight-panel {
    grid-template-columns: 1fr !important;
  }
}


/* PATCH JUNBI TEMPEROS - QUANTIDADE EM UMA LINHA */
.seasoning-qty {
  min-width: 104px !important;
  height: 62px !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 6px !important;
  padding: 0 14px !important;
  white-space: nowrap !important;
}

.seasoning-qty b,
.seasoning-qty small {
  display: inline !important;
  line-height: 1 !important;
  white-space: nowrap !important;
}

.seasoning-qty b {
  font-size: 24px !important;
  font-weight: 950 !important;
}

.seasoning-qty small {
  font-size: 12px !important;
  font-weight: 950 !important;
  text-transform: lowercase !important;
  margin-top: 4px !important;
}

@media(max-width:720px){
  .seasoning-qty {
    min-width: 96px !important;
    height: 54px !important;
    justify-self: start !important;
  }

  .seasoning-qty b {
    font-size: 20px !important;
  }
}


/* PATCH PRODUÇÃO - HIERARQUIA + BOARD TRELLO + TOTEM */
.production-kanban {
  align-items: stretch !important;
}

.production-day {
  transition: border-color .25s ease, background .25s ease, transform .25s ease !important;
}

.production-day:hover {
  border-color: #bfdbfe !important;
}

.production-dropzone {
  display: grid !important;
  gap: 12px !important;
  min-height: 210px !important;
}

.production-card {
  cursor: grab !important;
  user-select: none !important;
}

.production-card:active,
.production-card.dragging {
  cursor: grabbing !important;
}

.production-card.dragging {
  opacity: .58 !important;
  transform: rotate(1deg) scale(.98) !important;
  border-color: #2563eb !important;
  box-shadow: 0 18px 40px rgba(37,99,235,.18) !important;
}

.production-card-head {
  display: flex !important;
  justify-content: space-between !important;
  align-items: center !important;
  gap: 8px !important;
}

.prod-status {
  display: inline-flex !important;
  align-items: center !important;
  gap: 6px !important;
  border-radius: 999px !important;
  padding: 6px 10px !important;
  font-size: 11px !important;
  font-weight: 950 !important;
  white-space: nowrap !important;
}

.prod-status::before {
  content: "" !important;
  width: 7px !important;
  height: 7px !important;
  border-radius: 50% !important;
  display: inline-block !important;
}

.prod-status.st-start {
  background: #eff6ff !important;
  color: #1d4ed8 !important;
}

.prod-status.st-start::before {
  background: #2563eb !important;
}

.prod-status.st-running {
  background: #ecfdf5 !important;
  color: #047857 !important;
}

.prod-status.st-running::before {
  background: #22c55e !important;
}

.prod-status.st-done {
  background: #f0fdf4 !important;
  color: #166534 !important;
}

.prod-status.st-done::before {
  background: #16a34a !important;
}

.prod-status.st-stopped {
  background: #fff1f2 !important;
  color: #be123c !important;
}

.prod-status.st-stopped::before {
  background: #e11d48 !important;
}

.status-legend {
  display: flex !important;
  flex-wrap: wrap !important;
  gap: 10px !important;
  margin-top: 16px !important;
}

.production-stage-list {
  display: grid !important;
  gap: 10px !important;
}

.production-stage-list div {
  display: flex !important;
  align-items: center !important;
  gap: 12px !important;
  padding: 12px !important;
  border: 1px solid #e2e8f0 !important;
  border-radius: 16px !important;
  background: #fff !important;
}

.production-stage-list div.active {
  border-color: #2563eb !important;
  background: #eff6ff !important;
}

.production-stage-list div.done {
  border-color: #bbf7d0 !important;
  background: #f0fdf4 !important;
}

.production-stage-list span {
  width: 30px !important;
  height: 30px !important;
  border-radius: 50% !important;
  display: grid !important;
  place-items: center !important;
  background: #eef2ff !important;
  color: #1d4ed8 !important;
  font-weight: 950 !important;
}

.production-totem-layout {
  align-items: start !important;
}

.totem-product-list {
  display: grid !important;
  gap: 10px !important;
  margin-top: 14px !important;
}

.totem-product-list button {
  display: grid !important;
  grid-template-columns: 1fr auto !important;
  gap: 4px 12px !important;
  align-items: center !important;
  width: 100% !important;
  text-align: left !important;
  border: 1px solid #e2e8f0 !important;
  background: #fff !important;
  border-radius: 18px !important;
  padding: 14px !important;
  cursor: pointer !important;
  transition: .22s ease !important;
}

.totem-product-list button:hover,
.totem-product-list button.active {
  border-color: #2563eb !important;
  background: #eff6ff !important;
}

.totem-product-list strong {
  color: #0f172a !important;
  font-size: 14px !important;
}

.totem-product-list span {
  color: #64748b !important;
  font-size: 12px !important;
  font-weight: 700 !important;
}

.totem-product-list .prod-status {
  grid-row: span 2 !important;
}

.totem-header {
  display: flex !important;
  justify-content: space-between !important;
  gap: 14px !important;
  align-items: flex-start !important;
  margin-bottom: 18px !important;
}

.totem-header h3 {
  margin-bottom: 4px !important;
}

.totem-header p {
  margin: 0 !important;
  color: #64748b !important;
  font-weight: 700 !important;
}

.totem-timer {
  padding: 22px !important;
  border-radius: 24px !important;
  background: #0F1338 !important;
  color: #fff !important;
  display: grid !important;
  gap: 8px !important;
  margin-bottom: 18px !important;
}

.totem-timer span {
  color: rgba(255,255,255,.72) !important;
  font-size: 11px !important;
  text-transform: uppercase !important;
  letter-spacing: .12em !important;
  font-weight: 950 !important;
}

.totem-timer strong {
  font-size: 28px !important;
  line-height: 1 !important;
}

.totem-timer b {
  font-size: clamp(34px, 6vw, 64px) !important;
  line-height: 1 !important;
  letter-spacing: .04em !important;
}

.totem-buttons {
  display: grid !important;
  grid-template-columns: repeat(2,minmax(0,1fr)) !important;
  gap: 10px !important;
  margin-top: 18px !important;
}

.live-production-list {
  display: grid !important;
  gap: 12px !important;
  margin-top: 14px !important;
}

.live-production-item {
  display: grid !important;
  grid-template-columns: 1fr 180px auto !important;
  gap: 16px !important;
  align-items: center !important;
  padding: 14px !important;
  border-radius: 18px !important;
  border: 1px solid #e2e8f0 !important;
  background: #fff !important;
}

.live-production-item strong {
  display: block !important;
  color: #0f172a !important;
  font-weight: 950 !important;
}

.live-production-item span,
.live-production-item small {
  color: #64748b !important;
  font-weight: 700 !important;
}

.live-production-item b {
  display: block !important;
  color: #0f172a !important;
}

@media(max-width:1180px){
  .production-kanban {
    grid-template-columns: repeat(4, minmax(190px,1fr)) !important;
    overflow-x: auto !important;
  }

  .live-production-item {
    grid-template-columns: 1fr !important;
  }
}

@media(max-width:720px){
  .production-kanban {
    grid-template-columns: 1fr !important;
    overflow-x: visible !important;
  }

  .production-day {
    min-width: 0 !important;
  }

  .totem-buttons {
    grid-template-columns: 1fr !important;
  }

  .totem-header {
    flex-direction: column !important;
  }
}


/* PATCH PRODUÇÃO - TABELA AJUSTÁVEL HIERARQUIA + PRODUÇÃO EXTRA */
.production-adjustable-table td[contenteditable="true"] {
  background: #ffffff !important;
  cursor: text !important;
  outline: none !important;
}

.production-adjustable-table td[contenteditable="true"]:focus {
  background: #eff6ff !important;
  box-shadow: inset 0 0 0 2px rgba(37,99,235,.20) !important;
  border-radius: 8px !important;
}

.production-extra-form {
  grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
  gap: 16px !important;
}

.production-extra-form input,
.production-extra-form select,
.production-extra-form textarea {
  width: 100% !important;
  min-height: 50px !important;
  border-radius: 15px !important;
  font-size: 14px !important;
  font-weight: 750 !important;
}

.production-extra-form label {
  font-size: 11px !important;
  letter-spacing: .11em !important;
  text-transform: uppercase !important;
  color: #64748b !important;
  font-weight: 950 !important;
}

.production-extra-form textarea {
  min-height: 110px !important;
  padding: 14px 16px !important;
}

@media(max-width:1180px){
  .production-extra-form {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }
}

@media(max-width:720px){
  .production-extra-form {
    grid-template-columns: 1fr !important;
  }
}


/* PATCH TOTEM - HIERARQUIA + MÚLTIPLOS PROCESSOS + CRONÔMETRO */
.totem-day-product-grid {
  display: grid !important;
  grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  gap: 14px !important;
  margin-top: 16px !important;
}

.totem-day-card {
  width: 100% !important;
  text-align: left !important;
  border: 1px solid #e2e8f0 !important;
  background: linear-gradient(180deg,#ffffff,#f8fafc) !important;
  border-radius: 22px !important;
  padding: 16px !important;
  cursor: pointer !important;
  display: grid !important;
  gap: 8px !important;
  box-shadow: 0 14px 32px rgba(15,23,42,.045) !important;
  transition: transform .22s ease, border-color .22s ease, box-shadow .22s ease !important;
}

.totem-day-card:hover {
  transform: translateY(-2px) !important;
  border-color: #bfdbfe !important;
  box-shadow: 0 20px 40px rgba(37,99,235,.10) !important;
}

.totem-day-card-top {
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  gap: 12px !important;
}

.totem-day-card strong {
  color: #0f172a !important;
  font-size: 16px !important;
  font-weight: 950 !important;
}

.totem-day-card span,
.totem-day-card small,
.totem-day-card em {
  color: #64748b !important;
  font-size: 12px !important;
  font-weight: 750 !important;
  font-style: normal !important;
}

.totem-day-card b {
  color: #0F1338 !important;
  font-size: 28px !important;
  line-height: 1 !important;
  letter-spacing: .04em !important;
  margin-top: 4px !important;
}

.totem-day-card.is-running {
  border-color: #bbf7d0 !important;
  background: linear-gradient(180deg,#ffffff,#f0fdf4) !important;
}

.totem-day-card.is-stopped {
  border-color: #fecdd3 !important;
  background: linear-gradient(180deg,#ffffff,#fff1f2) !important;
}

.totem-day-card.is-done {
  border-color: #bbf7d0 !important;
  opacity: .82 !important;
}

.totem-live-mini {
  display: grid !important;
  gap: 12px !important;
  margin-top: 16px !important;
}

.totem-live-mini > div {
  display: grid !important;
  grid-template-columns: 1fr auto !important;
  align-items: center !important;
  gap: 8px 14px !important;
  padding: 14px !important;
  border-radius: 18px !important;
  border: 1px solid #e2e8f0 !important;
  background: #fff !important;
}

.totem-live-mini > div.running {
  border-color: #bbf7d0 !important;
  background: #f0fdf4 !important;
}

.totem-live-mini > div.stopped {
  border-color: #fecdd3 !important;
  background: #fff1f2 !important;
}

.totem-live-mini strong {
  color: #0f172a !important;
  font-weight: 950 !important;
}

.totem-live-mini span {
  color: #64748b !important;
  font-size: 12px !important;
  font-weight: 800 !important;
}

.empty-mini {
  margin: 0 !important;
  color: #64748b !important;
  font-weight: 750 !important;
}

.totem-stages div {
  grid-template-columns: 30px 1fr auto !important;
}

.totem-stages small {
  color: #64748b !important;
  font-size: 11px !important;
  font-weight: 850 !important;
}

@media(max-width:1180px){
  .totem-day-product-grid {
    grid-template-columns: 1fr !important;
  }
}

@media(max-width:720px){
  .totem-day-card-top {
    flex-direction: column !important;
    align-items: flex-start !important;
  }

  .totem-day-card b {
    font-size: 24px !important;
  }
}


/* PATCH FLUXO AO VIVO - TELÃO DE PRODUÇÃO */
.live-wall-page {
  min-height: calc(100vh - 160px) !important;
  display: grid !important;
  gap: 18px !important;
}

.live-wall-hero {
  display: flex !important;
  align-items: stretch !important;
  justify-content: space-between !important;
  gap: 18px !important;
  padding: 22px !important;
  border-radius: 28px !important;
  background:
    radial-gradient(circle at top left, rgba(37,99,235,.18), transparent 34%),
    radial-gradient(circle at top right, rgba(34,197,94,.14), transparent 28%),
    linear-gradient(135deg, #ffffff, #f8fafc) !important;
  border: 1px solid #dbeafe !important;
  box-shadow: 0 22px 60px rgba(15,23,42,.08) !important;
}

.live-wall-hero h2 {
  margin: 6px 0 6px !important;
  color: #0f172a !important;
  font-size: clamp(30px, 4vw, 52px) !important;
  line-height: 1 !important;
  letter-spacing: -.04em !important;
}

.live-wall-hero p {
  margin: 0 !important;
  color: #475569 !important;
  font-weight: 750 !important;
  max-width: 780px !important;
  font-size: 15px !important;
}

.live-wall-clock {
  min-width: 210px !important;
  padding: 18px !important;
  border-radius: 24px !important;
  background: #0F1338 !important;
  color: #fff !important;
  display: grid !important;
  align-content: center !important;
  gap: 6px !important;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.08) !important;
}

.live-wall-clock span {
  color: rgba(255,255,255,.65) !important;
  font-size: 11px !important;
  text-transform: uppercase !important;
  letter-spacing: .14em !important;
  font-weight: 950 !important;
}

.live-wall-clock strong {
  font-size: 54px !important;
  line-height: 1 !important;
}

.live-wall-clock small {
  color: rgba(255,255,255,.7) !important;
  font-weight: 800 !important;
}

.live-wall-kpis {
  display: grid !important;
  grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
  gap: 14px !important;
}

.live-wall-kpi {
  padding: 18px !important;
  border-radius: 24px !important;
  color: #fff !important;
  position: relative !important;
  overflow: hidden !important;
  box-shadow: 0 18px 42px rgba(15,23,42,.12) !important;
}

.live-wall-kpi::after {
  content: "" !important;
  position: absolute !important;
  right: -26px !important;
  top: -26px !important;
  width: 92px !important;
  height: 92px !important;
  border-radius: 50% !important;
  background: rgba(255,255,255,.18) !important;
}

.live-wall-kpi.blue { background: linear-gradient(135deg,#2563eb,#06b6d4) !important; }
.live-wall-kpi.green { background: linear-gradient(135deg,#16a34a,#22c55e) !important; }
.live-wall-kpi.gold { background: linear-gradient(135deg,#f59e0b,#f97316) !important; }
.live-wall-kpi.red { background: linear-gradient(135deg,#e11d48,#ef4444) !important; }

.live-wall-kpi span,
.live-wall-kpi small {
  display: block !important;
  color: rgba(255,255,255,.78) !important;
  font-weight: 900 !important;
}

.live-wall-kpi span {
  font-size: 11px !important;
  text-transform: uppercase !important;
  letter-spacing: .13em !important;
}

.live-wall-kpi strong {
  display: block !important;
  font-size: 42px !important;
  line-height: 1 !important;
  margin: 10px 0 6px !important;
}

.live-wall-actions {
  display: flex !important;
  justify-content: flex-end !important;
  gap: 10px !important;
}

.live-wall-board {
  display: grid !important;
  gap: 18px !important;
}

.live-product-row {
  padding: 18px !important;
  border-radius: 28px !important;
  border: 1px solid #e2e8f0 !important;
  background: #fff !important;
  box-shadow: 0 20px 48px rgba(15,23,42,.065) !important;
  position: relative !important;
  overflow: hidden !important;
}

.live-product-row::before {
  content: "" !important;
  position: absolute !important;
  inset: 0 auto 0 0 !important;
  width: 7px !important;
  background: #94a3b8 !important;
}

.live-product-row.is-running::before { background: linear-gradient(180deg,#2563eb,#22c55e) !important; }
.live-product-row.is-done::before { background: #22c55e !important; }
.live-product-row.is-stopped::before { background: #e11d48 !important; }
.live-product-row.is-start::before { background: #60a5fa !important; }

.live-product-head {
  display: flex !important;
  justify-content: space-between !important;
  align-items: center !important;
  gap: 16px !important;
  margin-bottom: 16px !important;
}

.live-product-head strong {
  display: block !important;
  color: #0f172a !important;
  font-size: clamp(20px, 2vw, 30px) !important;
  font-weight: 950 !important;
  letter-spacing: -.03em !important;
}

.live-product-head span {
  display: block !important;
  color: #64748b !important;
  font-size: 13px !important;
  font-weight: 800 !important;
  margin-top: 4px !important;
}

.live-stop-reason{display:flex;align-items:flex-start;gap:10px;margin:-4px 0 14px;padding:11px 14px;border:1px solid #fb7185;border-left:4px solid #e11d48;background:#fff1f2;color:#881337;font-size:13px;line-height:1.45}
.live-stop-reason>i{margin-top:2px;color:#e11d48}
.live-stop-reason span{display:grid;gap:2px}
.live-stop-reason strong{font-size:11px;letter-spacing:.04em;text-transform:uppercase}

.live-product-meta {
  display: flex !important;
  align-items: center !important;
  gap: 12px !important;
}

.live-product-meta > b {
  padding: 12px 14px !important;
  border-radius: 16px !important;
  background: #0F1338 !important;
  color: #fff !important;
  font-size: 18px !important;
  letter-spacing: .04em !important;
}

.live-stage-line {
  display: grid !important;
  grid-template-columns: repeat(8, minmax(110px, 1fr)) !important;
  gap: 10px !important;
}

.live-stage-box {
  min-height: 132px !important;
  padding: 14px !important;
  border-radius: 22px !important;
  border: 1px solid #e2e8f0 !important;
  background: linear-gradient(180deg,#ffffff,#f8fafc) !important;
  display: grid !important;
  align-content: start !important;
  gap: 6px !important;
  position: relative !important;
  overflow: hidden !important;
  transition: transform .25s ease, border-color .25s ease, box-shadow .25s ease !important;
}

.live-stage-box span {
  width: 34px !important;
  height: 34px !important;
  border-radius: 12px !important;
  display: grid !important;
  place-items: center !important;
  background: #eff6ff !important;
  color: #1d4ed8 !important;
  font-size: 12px !important;
  font-weight: 950 !important;
}

.live-stage-box strong {
  color: #0f172a !important;
  font-size: 14px !important;
  font-weight: 950 !important;
  line-height: 1.15 !important;
}

.live-stage-box small {
  color: #64748b !important;
  font-size: 11px !important;
  font-weight: 850 !important;
}

.live-stage-box > b {
  margin-top: 4px !important;
  padding: 7px 9px !important;
  border-radius: 12px !important;
  background: #0F1338 !important;
  color: #fff !important;
  width: fit-content !important;
  font-size: 12px !important;
  letter-spacing: .04em !important;
}

.live-stage-box.done {
  border-color: #bbf7d0 !important;
  background: linear-gradient(180deg,#ffffff,#f0fdf4) !important;
}

.live-stage-box.done span {
  background: #dcfce7 !important;
  color: #15803d !important;
}

.live-stage-box.next {
  border-color: #bfdbfe !important;
  background: linear-gradient(180deg,#ffffff,#eff6ff) !important;
}

.live-stage-box.active {
  border-color: rgba(37,99,235,.55) !important;
  background:
    radial-gradient(circle at 20% 0%, rgba(37,99,235,.28), transparent 34%),
    linear-gradient(180deg,#ffffff,#eff6ff) !important;
  box-shadow: 0 18px 40px rgba(37,99,235,.16) !important;
  transform: translateY(-3px) !important;
}

.live-stage-box.active .live-stage-glow {
  position: absolute !important;
  inset: -40% !important;
  background: conic-gradient(from 0deg, transparent, rgba(37,99,235,.28), transparent, rgba(34,197,94,.25), transparent) !important;
  animation: liveSpin 3s linear infinite !important;
  opacity: .55 !important;
}

.live-stage-box.active::after {
  content: "" !important;
  position: absolute !important;
  right: 12px !important;
  top: 12px !important;
  width: 12px !important;
  height: 12px !important;
  border-radius: 50% !important;
  background: #22c55e !important;
  box-shadow: 0 0 0 0 rgba(34,197,94,.55) !important;
  animation: livePulse 1.2s ease-in-out infinite !important;
}

.live-stage-box.stopped {
  border-color: #fecdd3 !important;
  background: linear-gradient(180deg,#ffffff,#fff1f2) !important;
  box-shadow: 0 18px 40px rgba(225,29,72,.12) !important;
}

.live-stage-box.stopped span {
  background: #ffe4e6 !important;
  color: #be123c !important;
}

.live-stage-box > *:not(.live-stage-glow) {
  position: relative !important;
  z-index: 2 !important;
}

.live-wall-footer {
  display: flex !important;
  align-items: center !important;
  gap: 12px !important;
  padding: 16px 18px !important;
  border-radius: 22px !important;
  background: #0F1338 !important;
  color: #fff !important;
}

.live-wall-footer strong {
  font-weight: 950 !important;
}

.live-wall-footer span {
  color: rgba(255,255,255,.68) !important;
  font-weight: 750 !important;
}

.live-pulse-dot {
  width: 14px !important;
  height: 14px !important;
  border-radius: 50% !important;
  background: #22c55e !important;
  box-shadow: 0 0 0 0 rgba(34,197,94,.58) !important;
  animation: livePulse 1.3s ease-in-out infinite !important;
}

@keyframes livePulse {
  0% { box-shadow: 0 0 0 0 rgba(34,197,94,.58); transform: scale(1); }
  70% { box-shadow: 0 0 0 12px rgba(34,197,94,0); transform: scale(1.08); }
  100% { box-shadow: 0 0 0 0 rgba(34,197,94,0); transform: scale(1); }
}

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

/* Telão: prioriza visual amplo. Não precisa quebrar tanto quanto páginas administrativas. */
@media(max-width:1300px){
  .live-stage-line {
    grid-template-columns: repeat(4, minmax(130px, 1fr)) !important;
  }
}

@media(max-width:900px){
  .live-wall-hero,
  .live-product-head {
    flex-direction: column !important;
    align-items: flex-start !important;
  }

  .live-wall-kpis {
    grid-template-columns: repeat(2, minmax(0,1fr)) !important;
  }

  .live-stage-line {
    grid-template-columns: repeat(2, minmax(130px, 1fr)) !important;
  }
}


/* PATCH SEGURO - FLUXO AO VIVO DESTAQUE + TIMER */
.live-stage-box.active,
.live-stage-box.demo-active {
  border: 2px solid rgba(37, 99, 235, .95) !important;
  background:
    radial-gradient(circle at 20% 0%, rgba(34,197,94,.36), transparent 32%),
    radial-gradient(circle at 90% 10%, rgba(59,130,246,.38), transparent 34%),
    linear-gradient(135deg, #0F1338, #1d4ed8 48%, #0891b2) !important;
  box-shadow:
    0 0 0 4px rgba(37,99,235,.12),
    0 22px 52px rgba(37,99,235,.35),
    inset 0 0 0 1px rgba(255,255,255,.16) !important;
  transform: translateY(-5px) scale(1.025) !important;
  animation: activeStageFloatSafe 1.8s ease-in-out infinite !important;
}

.live-stage-box.active span,
.live-stage-box.demo-active span {
  background: rgba(255,255,255,.18) !important;
  color: #ffffff !important;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.22) !important;
}

.live-stage-box.active strong,
.live-stage-box.active small,
.live-stage-box.demo-active strong,
.live-stage-box.demo-active small {
  color: #ffffff !important;
}

.live-stage-box.active > b,
.live-stage-box.demo-active > b {
  background: rgba(255,255,255,.96) !important;
  color: #0F1338 !important;
  font-size: 13px !important;
  font-weight: 950 !important;
  box-shadow: 0 10px 24px rgba(0,0,0,.18) !important;
}

.live-stage-box.active::before,
.live-stage-box.demo-active::before {
  content: "AGORA" !important;
  position: absolute !important;
  right: 12px !important;
  bottom: 12px !important;
  z-index: 3 !important;
  padding: 5px 8px !important;
  border-radius: 999px !important;
  background: #22c55e !important;
  color: #ffffff !important;
  font-size: 9px !important;
  font-weight: 950 !important;
  letter-spacing: .12em !important;
  box-shadow: 0 0 0 0 rgba(34,197,94,.55) !important;
  animation: livePulse 1.2s ease-in-out infinite !important;
}

.live-stage-box.active::after,
.live-stage-box.demo-active::after {
  content: "" !important;
  position: absolute !important;
  right: 14px !important;
  top: 14px !important;
  width: 14px !important;
  height: 14px !important;
  border-radius: 50% !important;
  background: #22c55e !important;
  box-shadow: 0 0 0 0 rgba(34,197,94,.65) !important;
  animation: livePulse 1.1s ease-in-out infinite !important;
  z-index: 3 !important;
}

.live-product-row.is-running {
  border-color: rgba(37,99,235,.34) !important;
  background:
    radial-gradient(circle at 0% 0%, rgba(37,99,235,.08), transparent 28%),
    #ffffff !important;
}

.live-product-row.is-running::before {
  width: 10px !important;
  background: linear-gradient(180deg, #22c55e, #2563eb, #06b6d4) !important;
  animation: liveBarMoveSafe 1.4s ease-in-out infinite !important;
}

.live-product-row.is-running .live-product-meta > b {
  background: linear-gradient(135deg, #0F1338, #2563eb) !important;
  box-shadow: 0 12px 30px rgba(37,99,235,.28) !important;
}

@keyframes activeStageFloatSafe {
  0%, 100% {
    transform: translateY(-5px) scale(1.025);
  }
  50% {
    transform: translateY(-9px) scale(1.035);
  }
}

@keyframes liveBarMoveSafe {
  0%, 100% {
    filter: brightness(1);
  }
  50% {
    filter: brightness(1.35);
  }
}


/* PATCH FLUXO AO VIVO - SOMENTE COR NO QUADRO ATIVO */
.live-stage-box.live-current-colored,
.live-stage-box.next,
.live-stage-box.active {
  border: 2px solid #2563eb !important;
  background: linear-gradient(135deg, #0F1338 0%, #1d4ed8 55%, #06b6d4 100%) !important;
  box-shadow: 0 18px 42px rgba(37, 99, 235, .32) !important;
}

.live-stage-box.live-current-colored span,
.live-stage-box.live-current-colored strong,
.live-stage-box.live-current-colored small,
.live-stage-box.next span,
.live-stage-box.next strong,
.live-stage-box.next small,
.live-stage-box.active span,
.live-stage-box.active strong,
.live-stage-box.active small {
  color: #ffffff !important;
}

.live-stage-box.live-current-colored span,
.live-stage-box.next span,
.live-stage-box.active span {
  background: rgba(255,255,255,.18) !important;
}

.live-stage-box.live-current-colored > b,
.live-stage-box.next > b,
.live-stage-box.active > b {
  background: #ffffff !important;
  color: #0F1338 !important;
}


/* PATCH FLUXO AO VIVO - EFEITO DE FLUXO ESQUERDA PARA DIREITA */
.live-stage-box.active .live-stage-glow,
.live-stage-box.demo-active .live-stage-glow {
  position: absolute !important;
  inset: 0 !important;
  background: linear-gradient(
    90deg,
    transparent 0%,
    rgba(255,255,255,0) 18%,
    rgba(255,255,255,.34) 42%,
    rgba(34,197,94,.28) 50%,
    rgba(255,255,255,.34) 58%,
    rgba(255,255,255,0) 82%,
    transparent 100%
  ) !important;
  animation: liveFlowLeftRight 1.75s linear infinite !important;
  opacity: .9 !important;
  transform: translateX(-120%) !important;
}

.live-stage-box.active,
.live-stage-box.demo-active {
  overflow: hidden !important;
}

@keyframes liveFlowLeftRight {
  0% {
    transform: translateX(-120%);
  }
  100% {
    transform: translateX(120%);
  }
}

/* neutraliza o giro antigo apenas no fluxo ao vivo */
.live-stage-box.active .live-stage-glow,
.live-stage-box.demo-active .live-stage-glow {
  animation-name: liveFlowLeftRight !important;
}


/* PATCH CORRIGIDO - FLUXO AO VIVO COM MOVIMENTO HORIZONTAL */
.live-stage-box.active,
.live-stage-box.demo-active,
.live-stage-box.live-current-colored {
  position: relative !important;
  overflow: hidden !important;
}

/* Mantém a camada de brilho, mas tira o giro antigo */
.live-stage-box.active .live-stage-glow,
.live-stage-box.demo-active .live-stage-glow,
.live-stage-box.live-current-colored .live-stage-glow {
  position: absolute !important;
  inset: 0 !important;
  opacity: 1 !important;
  background: transparent !important;
  animation: none !important;
  transform: none !important;
  z-index: 1 !important;
  pointer-events: none !important;
}

/* Cria a faixa luminosa que corre da esquerda para a direita */
.live-stage-box.active .live-stage-glow::before,
.live-stage-box.demo-active .live-stage-glow::before,
.live-stage-box.live-current-colored .live-stage-glow::before {
  content: "" !important;
  position: absolute !important;
  top: -35% !important;
  bottom: -35% !important;
  left: -75% !important;
  width: 55% !important;
  background: linear-gradient(
    90deg,
    transparent 0%,
    rgba(255,255,255,0) 10%,
    rgba(255,255,255,.42) 45%,
    rgba(34,197,94,.38) 52%,
    rgba(255,255,255,.42) 58%,
    rgba(255,255,255,0) 90%,
    transparent 100%
  ) !important;
  transform: skewX(-18deg) !important;
  animation: liveFlowSweepHorizontal 1.45s linear infinite !important;
}

/* Garante que textos fiquem acima da luz */
.live-stage-box.active > *:not(.live-stage-glow),
.live-stage-box.demo-active > *:not(.live-stage-glow),
.live-stage-box.live-current-colored > *:not(.live-stage-glow) {
  position: relative !important;
  z-index: 3 !important;
}

/* Movimento real de fluxo */
@keyframes liveFlowSweepHorizontal {
  0% {
    left: -75%;
  }
  100% {
    left: 125%;
  }
}


/* PATCH FLUXO AO VIVO - MOVIMENTO REAL + CONCLUÍDO VERDE */

/* etapa em andamento: azul com faixa luminosa correndo da esquerda para direita */
.live-stage-box.flow-moving,
.live-stage-box.active.flow-moving {
  position: relative !important;
  overflow: hidden !important;
  border: 2px solid #38bdf8 !important;
  background: linear-gradient(135deg, #0F1338 0%, #1d4ed8 48%, #0891b2 100%) !important;
  box-shadow:
    0 0 0 4px rgba(56,189,248,.16),
    0 22px 52px rgba(37,99,235,.36) !important;
  transform: translateY(-4px) scale(1.02) !important;
}

.live-stage-box.flow-moving::before {
  content: "" !important;
  position: absolute !important;
  top: -40% !important;
  left: -85% !important;
  width: 62% !important;
  height: 180% !important;
  background: linear-gradient(
    90deg,
    transparent 0%,
    rgba(255,255,255,0) 18%,
    rgba(255,255,255,.58) 48%,
    rgba(34,197,94,.42) 55%,
    rgba(255,255,255,.58) 62%,
    rgba(255,255,255,0) 86%,
    transparent 100%
  ) !important;
  transform: skewX(-20deg) !important;
  animation: mijFlowSweep 1.25s linear infinite !important;
  z-index: 1 !important;
  pointer-events: none !important;
}

.live-stage-box.flow-moving::after {
  content: "AGORA" !important;
  position: absolute !important;
  right: 12px !important;
  bottom: 12px !important;
  z-index: 4 !important;
  padding: 5px 9px !important;
  border-radius: 999px !important;
  background: #22c55e !important;
  color: #fff !important;
  font-size: 9px !important;
  font-weight: 950 !important;
  letter-spacing: .12em !important;
}

.live-stage-box.flow-moving > * {
  position: relative !important;
  z-index: 3 !important;
}

.live-stage-box.flow-moving span,
.live-stage-box.flow-moving strong,
.live-stage-box.flow-moving small {
  color: #ffffff !important;
}

.live-stage-box.flow-moving span {
  background: rgba(255,255,255,.20) !important;
}

.live-stage-box.flow-moving > b {
  background: #ffffff !important;
  color: #0F1338 !important;
  font-weight: 950 !important;
}

/* finalizado: somente o quadro Concluído fica verde forte */
.live-stage-box.completed-active.final-green {
  position: relative !important;
  overflow: hidden !important;
  border: 2px solid #22c55e !important;
  background: linear-gradient(135deg, #064e3b 0%, #16a34a 48%, #4ade80 100%) !important;
  box-shadow:
    0 0 0 4px rgba(34,197,94,.18),
    0 22px 52px rgba(22,163,74,.30) !important;
  transform: translateY(-4px) scale(1.02) !important;
}

.live-stage-box.completed-active.final-green::after {
  content: "FINALIZADO" !important;
  position: absolute !important;
  right: 12px !important;
  bottom: 12px !important;
  z-index: 4 !important;
  padding: 5px 9px !important;
  border-radius: 999px !important;
  background: #ffffff !important;
  color: #15803d !important;
  font-size: 9px !important;
  font-weight: 950 !important;
  letter-spacing: .12em !important;
}

.live-stage-box.completed-active.final-green span,
.live-stage-box.completed-active.final-green strong,
.live-stage-box.completed-active.final-green small {
  color: #ffffff !important;
}

.live-stage-box.completed-active.final-green span {
  background: rgba(255,255,255,.22) !important;
}

.live-stage-box.completed-active.final-green > * {
  position: relative !important;
  z-index: 3 !important;
}

/* remove destaque azul indevido em cards finalizados */
.live-product-row.is-done .live-stage-box.next,
.live-product-row.is-done .live-stage-box.demo-current,
.live-product-row.is-done .live-stage-box.live-current-colored {
  border: 1px solid #bbf7d0 !important;
  background: linear-gradient(180deg,#ffffff,#f0fdf4) !important;
  box-shadow: none !important;
  transform: none !important;
}

.live-product-row.is-done .live-stage-box.next span,
.live-product-row.is-done .live-stage-box.demo-current span,
.live-product-row.is-done .live-stage-box.live-current-colored span {
  background: #dcfce7 !important;
  color: #15803d !important;
}

.live-product-row.is-done .live-stage-box.next strong,
.live-product-row.is-done .live-stage-box.next small,
.live-product-row.is-done .live-stage-box.demo-current strong,
.live-product-row.is-done .live-stage-box.demo-current small,
.live-product-row.is-done .live-stage-box.live-current-colored strong,
.live-product-row.is-done .live-stage-box.live-current-colored small {
  color: #0f172a !important;
}

@keyframes mijFlowSweep {
  0% {
    left: -85%;
  }
  100% {
    left: 130%;
  }
}


/* PATCH FLUXO AO VIVO - PARADO VERMELHO + AJUSTE DO SELO AGORA */

/* Corrige o selo AGORA para não sair do quadro */
.live-stage-box.flow-moving::after,
.live-stage-box.active::before,
.live-stage-box.demo-active::before,
.live-stage-box.live-current-colored::before {
  max-width: calc(100% - 18px) !important;
  white-space: nowrap !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  right: 8px !important;
  bottom: 8px !important;
  padding: 4px 7px !important;
  font-size: 8px !important;
  line-height: 1 !important;
  letter-spacing: .08em !important;
}

/* Produto parado: etapa atual precisa ficar vermelha, não azul */
.live-stage-box.stopped,
.live-stage-box.stopped.live-current-colored,
.live-product-row.is-stopped .live-stage-box.stopped,
.live-product-row.is-stopped .live-stage-box.live-current-colored.stopped {
  position: relative !important;
  overflow: hidden !important;
  border: 2px solid #ef4444 !important;
  background:
    radial-gradient(circle at 20% 0%, rgba(239,68,68,.34), transparent 32%),
    linear-gradient(135deg, #7f1d1d 0%, #dc2626 52%, #fb7185 100%) !important;
  box-shadow:
    0 0 0 4px rgba(239,68,68,.16),
    0 22px 52px rgba(220,38,38,.32) !important;
  transform: translateY(-4px) scale(1.02) !important;
}

/* brilho vermelho leve no parado */
.live-stage-box.stopped::before,
.live-stage-box.stopped.live-current-colored::before,
.live-product-row.is-stopped .live-stage-box.stopped::before {
  content: "" !important;
  position: absolute !important;
  top: -40% !important;
  left: -85% !important;
  width: 62% !important;
  height: 180% !important;
  background: linear-gradient(
    90deg,
    transparent 0%,
    rgba(255,255,255,0) 18%,
    rgba(255,255,255,.46) 48%,
    rgba(254,202,202,.42) 55%,
    rgba(255,255,255,.46) 62%,
    rgba(255,255,255,0) 86%,
    transparent 100%
  ) !important;
  transform: skewX(-20deg) !important;
  animation: mijFlowStoppedSweep 1.6s linear infinite !important;
  z-index: 1 !important;
  pointer-events: none !important;
}

/* selo do parado */
.live-stage-box.stopped::after,
.live-stage-box.stopped.live-current-colored::after,
.live-product-row.is-stopped .live-stage-box.stopped::after {
  content: "PARADO" !important;
  position: absolute !important;
  right: 8px !important;
  bottom: 8px !important;
  z-index: 4 !important;
  padding: 4px 7px !important;
  border-radius: 999px !important;
  background: #ffffff !important;
  color: #b91c1c !important;
  font-size: 8px !important;
  line-height: 1 !important;
  font-weight: 950 !important;
  letter-spacing: .08em !important;
  white-space: nowrap !important;
  max-width: calc(100% - 18px) !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
}

/* texto branco no quadro parado */
.live-stage-box.stopped span,
.live-stage-box.stopped strong,
.live-stage-box.stopped small,
.live-stage-box.stopped.live-current-colored span,
.live-stage-box.stopped.live-current-colored strong,
.live-stage-box.stopped.live-current-colored small,
.live-product-row.is-stopped .live-stage-box.stopped span,
.live-product-row.is-stopped .live-stage-box.stopped strong,
.live-product-row.is-stopped .live-stage-box.stopped small {
  color: #ffffff !important;
}

.live-stage-box.stopped span,
.live-stage-box.stopped.live-current-colored span,
.live-product-row.is-stopped .live-stage-box.stopped span {
  background: rgba(255,255,255,.20) !important;
}

/* mantém o conteúdo acima do brilho vermelho */
.live-stage-box.stopped > *:not(.live-stage-glow),
.live-stage-box.stopped.live-current-colored > *:not(.live-stage-glow),
.live-product-row.is-stopped .live-stage-box.stopped > *:not(.live-stage-glow) {
  position: relative !important;
  z-index: 3 !important;
}

/* linha do produto parado também ganha lateral vermelha */
.live-product-row.is-stopped::before {
  width: 10px !important;
  background: linear-gradient(180deg, #7f1d1d, #dc2626, #fb7185) !important;
}

.live-product-row.is-stopped {
  border-color: rgba(239,68,68,.36) !important;
  background:
    radial-gradient(circle at 0% 0%, rgba(239,68,68,.08), transparent 28%),
    #ffffff !important;
}

@keyframes mijFlowStoppedSweep {
  0% {
    left: -85%;
  }
  100% {
    left: 130%;
  }
}


/* PATCH FLUXO AO VIVO - CORRIGIR SELO AGORA */
.live-stage-box.flow-moving::after,
.live-stage-box.active::after,
.live-stage-box.demo-active::after,
.live-stage-box.live-current-colored::after {
  content: "AGORA" !important;
  position: absolute !important;
  top: 18px !important;
  right: 18px !important;
  bottom: auto !important;
  z-index: 10 !important;

  width: auto !important;
  min-width: 68px !important;
  max-width: none !important;
  height: 34px !important;

  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;

  padding: 0 13px !important;
  border-radius: 999px !important;

  background: #22c55e !important;
  color: #ffffff !important;

  font-size: 11px !important;
  line-height: 1 !important;
  font-weight: 950 !important;
  letter-spacing: .08em !important;

  white-space: nowrap !important;
  overflow: visible !important;
  text-overflow: unset !important;

  box-shadow: 0 10px 22px rgba(34,197,94,.35) !important;
}

/* Parado mantém selo próprio vermelho/branco */
.live-stage-box.stopped::after,
.live-stage-box.stopped.live-current-colored::after,
.live-product-row.is-stopped .live-stage-box.stopped::after {
  content: "PARADO" !important;
  top: 18px !important;
  right: 18px !important;
  bottom: auto !important;

  width: auto !important;
  min-width: 76px !important;
  max-width: none !important;
  height: 34px !important;

  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;

  padding: 0 13px !important;
  border-radius: 999px !important;

  background: #ffffff !important;
  color: #b91c1c !important;

  font-size: 11px !important;
  line-height: 1 !important;
  font-weight: 950 !important;
  letter-spacing: .08em !important;

  white-space: nowrap !important;
  overflow: visible !important;
  text-overflow: unset !important;

  box-shadow: 0 10px 22px rgba(185,28,28,.22) !important;
}

/* Finalizado mantém selo próprio */
.live-stage-box.completed-active.final-green::after {
  content: "FINALIZADO" !important;
  top: 18px !important;
  right: 18px !important;
  bottom: auto !important;

  width: auto !important;
  min-width: 108px !important;
  max-width: none !important;
  height: 34px !important;

  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;

  padding: 0 13px !important;
  border-radius: 999px !important;

  font-size: 11px !important;
  line-height: 1 !important;
  font-weight: 950 !important;
  letter-spacing: .08em !important;

  white-space: nowrap !important;
  overflow: visible !important;
  text-overflow: unset !important;
}

/* dá respiro interno no quadro ativo para o selo não brigar com o conteúdo */
.live-stage-box.flow-moving,
.live-stage-box.active.flow-moving,
.live-stage-box.completed-active.final-green,
.live-stage-box.stopped {
  padding-top: 22px !important;
}


/* PATCH TOTEM - BOTÕES E CRONÔMETRO FUNCIONAIS */
.totem-timer.is-stopped {
  background: linear-gradient(135deg, #7f1d1d, #dc2626) !important;
}

.totem-timer.is-done {
  background: linear-gradient(135deg, #064e3b, #16a34a) !important;
}

.totem-buttons button {
  min-height: 54px !important;
  font-weight: 950 !important;
}

.totem-live-mini b {
  color: inherit !important;
  font-weight: 950 !important;
}


/* PATCH EMBALAGEM - REGISTRO PRODUZIDO COM HIERARQUIA DOCUMENTAL */
.packaging-produced-form {
  grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
  gap: 16px !important;
}

.packaging-produced-form input,
.packaging-produced-form select,
.packaging-produced-form textarea {
  width: 100% !important;
  min-height: 50px !important;
  border-radius: 15px !important;
  font-size: 14px !important;
  font-weight: 750 !important;
}

.packaging-produced-form label {
  font-size: 11px !important;
  letter-spacing: .11em !important;
  text-transform: uppercase !important;
  color: #64748b !important;
  font-weight: 950 !important;
}

.packaging-produced-form textarea {
  min-height: 110px !important;
  padding: 14px 16px !important;
}

@media(max-width:1180px){
  .packaging-produced-form {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }
}

@media(max-width:720px){
  .packaging-produced-form {
    grid-template-columns: 1fr !important;
  }
}


/* PATCH EMBALAGEM - CAIXAS E LOTES COM HIERARQUIA DOCUMENTAL */
.packaging-lots-form {
  grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
  gap: 16px !important;
}

.packaging-lots-form input,
.packaging-lots-form select,
.packaging-lots-form textarea {
  width: 100% !important;
  min-height: 50px !important;
  border-radius: 15px !important;
  font-size: 14px !important;
  font-weight: 750 !important;
}

.packaging-lots-form label {
  font-size: 11px !important;
  letter-spacing: .11em !important;
  text-transform: uppercase !important;
  color: #64748b !important;
  font-weight: 950 !important;
}

.packaging-lots-form textarea {
  min-height: 110px !important;
  padding: 14px 16px !important;
}

@media(max-width:1180px){
  .packaging-lots-form {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }
}

@media(max-width:720px){
  .packaging-lots-form {
    grid-template-columns: 1fr !important;
  }
}


/* PATCH EMBALAGEM - KENSA E QUALIDADE COM HIERARQUIA DOCUMENTAL */
.kensa-quality-form {
  grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
  gap: 16px !important;
}

.kensa-quality-form input,
.kensa-quality-form select,
.kensa-quality-form textarea {
  width: 100% !important;
  min-height: 50px !important;
  border-radius: 15px !important;
  font-size: 14px !important;
  font-weight: 750 !important;
}

.kensa-quality-form label {
  font-size: 11px !important;
  letter-spacing: .11em !important;
  text-transform: uppercase !important;
  color: #64748b !important;
  font-weight: 950 !important;
}

.kensa-quality-form textarea {
  min-height: 110px !important;
  padding: 14px 16px !important;
}

.kensa-alert-card {
  border-color: #fbbf24 !important;
  background:
    radial-gradient(circle at top right, rgba(251,191,36,.18), transparent 28%),
    #ffffff !important;
}

@media(max-width:1180px){
  .kensa-quality-form {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }
}

@media(max-width:720px){
  .kensa-quality-form {
    grid-template-columns: 1fr !important;
  }
}


/* PATCH INSUMOS - PRODUTO GENÉRICO + LOTES */
.insumos-form {
  grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
  gap: 16px !important;
}

.insumos-form input,
.insumos-form select,
.insumos-form textarea {
  width: 100% !important;
  min-height: 50px !important;
  border-radius: 15px !important;
  font-size: 14px !important;
  font-weight: 750 !important;
}

.insumos-form label {
  font-size: 11px !important;
  letter-spacing: .11em !important;
  text-transform: uppercase !important;
  color: #64748b !important;
  font-weight: 950 !important;
}

@media(max-width:1180px){
  .insumos-form {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }
}

@media(max-width:720px){
  .insumos-form {
    grid-template-columns: 1fr !important;
  }
}


/* PATCH INSUMOS FINAL - ajustes específicos, sem alterar layout global */
.insumos-form{align-items:end}.insumos-form .field input,.insumos-form .field select{width:100%}

/* JUNBI — conferência rastreável por leitura de código de barras */
.junbi-scan-workspace .card,
.junbi-scan-workspace .kpi-card,
.junbi-scan-workspace .pill,
.junbi-scan-workspace .prep-approval-stamp,
.junbi-scan-workspace .prep-empty-state,
.junbi-scan-workspace .prep-document-banner,
.junbi-scan-workspace .prep-flow-note,
.junbi-scan-workspace input,
.junbi-scan-workspace select,
.junbi-scan-workspace button,
.junbi-scan-workspace .junbi-scan-feedback{border-radius:0!important}
.junbi-scan-grid,.junbi-department-grid,.junbi-reader-grid{align-items:start}
.junbi-department-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:18px}
.junbi-department-card{min-width:0}
.junbi-department-card .card-head{align-items:flex-start}
.junbi-department-card .card-head h3{margin:4px 0 0}
.junbi-department-operator{margin:16px 0}
.junbi-department-operator select{min-height:46px;width:100%}
.junbi-department-card .table-wrap{overflow-x:auto}
.junbi-department-card .data-table{width:100%;min-width:0;table-layout:fixed}
.junbi-department-card .data-table th,.junbi-department-card .data-table td{padding-left:8px;padding-right:8px;overflow-wrap:anywhere}
.junbi-department-card .data-table th:nth-child(1),.junbi-department-card .data-table td:nth-child(1){width:25%}
.junbi-department-card .data-table th:nth-child(2),.junbi-department-card .data-table td:nth-child(2){width:15%}
.junbi-department-card .data-table th:nth-child(3),.junbi-department-card .data-table td:nth-child(3){width:23%}
.junbi-department-card .data-table th:nth-child(4),.junbi-department-card .data-table td:nth-child(4){width:14%}
.junbi-department-card .data-table th:nth-child(5),.junbi-department-card .data-table td:nth-child(5){width:23%}
.junbi-department-card .data-table td{vertical-align:middle}
.junbi-department-card .data-table .junbi-item-complete{background:#f0fdf4}
.junbi-item-complete td:first-child{border-left:4px solid #10b981}
.junbi-row-scan{min-height:40px;width:100%;min-width:0;justify-content:center;padding:8px 6px;white-space:normal;font-size:12px;gap:6px}
.junbi-department-foot{display:flex;gap:9px;align-items:flex-start;margin-top:14px;padding-top:12px;border-top:1px solid #e5eaf1;color:#64748b;font-size:12px;line-height:1.5}
.junbi-department-foot i{color:#2563eb;margin-top:2px}
.junbi-global-release{display:flex;align-items:center;justify-content:space-between;gap:24px;margin:18px 0;padding:20px 22px}
.junbi-global-release h3{margin:0 0 5px}
.junbi-global-release .card-sub{margin:0;max-width:760px}
.junbi-global-release .junbi-release-btn{width:auto;min-width:300px;margin:0}
.junbi-reader-page .junbi-reader-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:18px}
.junbi-reader-page .prep-kpi-row{grid-template-columns:repeat(3,minmax(0,1fr))}
.junbi-reader-page .junbi-return-btn{margin-top:16px}
.junbi-reader-page .prep-flow-note.is-success{margin-top:14px;background:#ecfdf5;border-left:4px solid #10b981;color:#047857}
.junbi-reader-page .prep-flow-note.is-success i{color:#059669}
.junbi-barcode-entry{margin-top:18px}
.junbi-barcode-row{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:10px;align-items:stretch}
.junbi-barcode-row input,.junbi-scan-workspace .field select{min-height:48px;width:100%;font-size:14px}
.junbi-barcode-row .primary-btn{white-space:nowrap}
.junbi-release-btn{width:100%;margin-top:16px;min-height:48px}
.junbi-release-hint{display:block;margin-top:10px;color:#64748b;line-height:1.5}
.junbi-recipe-source{display:flex;gap:10px;align-items:flex-start;margin-top:16px;padding:13px 14px;background:#f7f9fc;border-left:4px solid #2563eb;color:#526176;font-size:12px;line-height:1.55}
.junbi-recipe-source i{color:#2563eb;margin-top:2px}
.junbi-recipe-source a{color:#1d4ed8;font-weight:800;white-space:nowrap}
.junbi-scan-feedback{display:flex;align-items:flex-start;gap:10px;margin-top:14px;padding:12px 14px;font-size:13px;font-weight:750;line-height:1.45}
.junbi-scan-feedback.is-ok{background:#ecfdf5;color:#047857;border-left:4px solid #10b981}
.junbi-scan-feedback.is-error{background:#fff7ed;color:#b45309;border-left:4px solid #f59e0b}
.junbi-scan-workspace .data-table th,.junbi-scan-workspace .data-table td{vertical-align:top}
.junbi-scan-workspace .prep-empty-state{border-radius:0!important}
@media(max-width:1100px){.junbi-department-grid,.junbi-reader-page .junbi-reader-grid{grid-template-columns:1fr}.junbi-global-release{align-items:stretch;flex-direction:column}.junbi-global-release .junbi-release-btn{width:100%;min-width:0}}
@media(max-width:720px){.junbi-barcode-row{grid-template-columns:1fr}.junbi-barcode-row .primary-btn{min-height:46px}.junbi-department-card .data-table{min-width:0}.junbi-department-card .data-table th,.junbi-department-card .data-table td{padding-left:5px;padding-right:5px;font-size:11px}.junbi-row-scan{padding:8px 6px;font-size:11px}.junbi-reader-page .prep-kpi-row{grid-template-columns:1fr}}

/* PRODUÇÃO — sequência lista > semana > tablet > monitor, com geometria reta */
.page-content.production-page *,.page-content.production-page *::before,.page-content.production-page *::after{border-radius:0!important}
.production-page-heading{display:flex;justify-content:space-between;align-items:center;gap:20px;margin:4px 0 12px;padding:24px 26px;background:#fff;border:1px solid #e2e8f0;border-left:5px solid #2563eb}
.production-page-heading h2{margin:5px 0 7px;font-size:26px;color:#172033}
.production-page-heading p{margin:0;color:#64748b;font-size:14px}
.production-page-heading>.pill{flex:none}
.production-list-page .prep-kpi-row{margin-top:16px}
.production-queue-table{min-width:900px}
.production-queue-table td{vertical-align:middle}
.production-source-note{display:flex;gap:10px;align-items:flex-start;margin-top:16px;padding:13px 15px;background:#eff6ff;border-left:4px solid #2563eb;color:#334155;font-size:13px;line-height:1.5}
.production-source-note i{color:#2563eb;margin-top:2px}
.production-empty-gate{display:flex;align-items:center;gap:14px;margin:12px 0;padding:16px;background:#f8fafc;border:1px solid #dbe3ef;border-left:4px solid #64748b;color:#334155}
.production-empty-gate>i{font-size:20px;color:#64748b}
.production-empty-gate>div{display:grid;gap:4px;flex:1}
.production-empty-gate strong{font-size:13px}
.production-empty-gate span{font-size:12px;line-height:1.45;color:#64748b}
.production-ai-schedule-alert{display:grid;grid-template-columns:46px minmax(0,1fr) auto;gap:16px;align-items:start;margin:16px 0;padding:18px 20px;border:1px solid #f59e0b;border-left:5px solid #f59e0b;background:#fffbeb}
.production-ai-schedule-alert.high{border-color:#ef4444;background:#fff1f2}
.production-ai-schedule-alert.good{border-color:#10b981;background:#ecfdf5}
.production-ai-alert-icon{display:grid;place-items:center;width:42px;height:42px;background:#fef3c7;color:#b45309;font-size:19px}
.production-ai-schedule-alert.high .production-ai-alert-icon{background:#fee2e2;color:#b91c1c}
.production-ai-schedule-alert.good .production-ai-alert-icon{background:#d1fae5;color:#047857}
.production-ai-alert-copy>span{font-size:10px;letter-spacing:.12em;font-weight:900;color:#64748b}
.production-ai-alert-copy h3{margin:5px 0;font-size:17px}
.production-ai-alert-copy p{margin:0 0 12px;color:#475569;line-height:1.5;font-size:13px}
.production-ai-alert-copy label{display:block;margin-bottom:5px;font-size:11px;font-weight:900;text-transform:uppercase;color:#475569}
.production-ai-alert-copy select{width:min(100%,380px);min-height:42px;padding:8px 10px;border:1px solid #cbd5e1;background:#fff;font:inherit}
.production-ai-alert-actions{display:grid;gap:8px;min-width:190px}
.production-ai-alert-actions button{justify-content:center}
.production-totem-presentation{width:100%}
.totem-presentation-bar{display:flex;justify-content:space-between;align-items:center;gap:16px;max-width:760px;margin:0 auto 10px}
.totem-presentation-bar strong,.totem-presentation-bar span{display:block}
.totem-presentation-bar strong{font-size:14px;color:#1e293b}
.totem-presentation-bar span{margin-top:3px;color:#64748b;font-size:11px;text-transform:uppercase;letter-spacing:.08em}
.totem-tablet-frame{width:min(100%,760px);height:min(860px,calc(100vh - 250px));min-height:600px;margin:0 auto;padding:12px;overflow:auto;scrollbar-gutter:stable;border:1px solid #cbd5e1;background:#fff;box-shadow:0 8px 28px rgba(15,23,42,.09)}
.totem-tablet-frame:fullscreen{width:min(100vw,760px);height:100vh;max-width:760px;max-height:100vh;margin:0 auto;padding:14px;overflow:auto;border:1px solid #cbd5e1;background:#fff;box-shadow:0 8px 28px rgba(15,23,42,.09)}
.totem-tablet-frame .prep-top-actions{margin-top:0}
.totem-tablet-frame .kpi-grid{margin-top:14px}
.totem-tablet-frame .flow-explain{grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}
.totem-tablet-frame .flow-explain div{padding:9px}
.totem-tablet-frame .flow-explain small{font-size:11px}
.live-wall-toolbar{display:flex;align-items:center;gap:10px;flex-wrap:wrap;margin:14px 0 18px;padding:12px 14px;background:#fff;border:1px solid #dbe3ef}
.live-wall-toolbar label{display:flex;align-items:center;gap:8px;font-size:12px;font-weight:900;color:#334155}
.live-wall-toolbar label i{color:#2563eb}
.live-wall-toolbar select{min-height:40px;min-width:180px;padding:7px 10px;background:#fff;border:1px solid #cbd5e1;font:inherit}
.live-wall-toolbar>span{margin-left:auto;color:#64748b;font-size:11px}
.live-wall-empty{padding:32px;text-align:center;background:#fff;border:1px solid #cbd5e1;color:#64748b;font-weight:700}
.live-wall-page:fullscreen{width:100vw;height:100vh;overflow:auto;padding:28px 34px;background:#f1f5f9}
.production-kanban{grid-template-columns:repeat(7,minmax(205px,1fr))!important;gap:12px!important}
.production-day{min-width:205px!important;background:#f8fafc!important}
.production-dropzone{min-height:230px!important}
.production-card{border-left:4px solid #2563eb!important}
.production-card.is-running{border-left-color:#10b981!important}
.production-card.is-done{border-left-color:#16a34a!important}
.production-card.is-stopped{border-left-color:#e11d48!important}
.production-stage-list div.active{border:2px solid #2563eb!important;background:#eff6ff!important}
.production-stage-list div.done{border-left:4px solid #10b981!important;background:#ecfdf5!important}
.totem-timer{background:#111827!important;color:#fff!important}
.totem-timer.is-stopped{background:#9f1239!important}
.totem-timer.is-done{background:#047857!important}
.live-stage-box.active{border:3px solid #2563eb!important;box-shadow:0 0 0 3px rgba(37,99,235,.13)!important}
.live-stage-box.done{border-left:4px solid #10b981!important}
@media(max-width:1150px){.production-ai-schedule-alert{grid-template-columns:42px minmax(0,1fr)}.production-ai-alert-actions{grid-column:2;display:flex;flex-wrap:wrap}.production-ai-alert-actions button{flex:1}.totem-tablet-frame{height:calc(100vh - 250px);min-height:560px}}
@media(max-width:720px){.production-page-heading{align-items:flex-start;flex-direction:column;padding:18px}.production-page-heading h2{font-size:21px}.production-ai-schedule-alert{grid-template-columns:36px minmax(0,1fr);padding:14px}.production-ai-alert-icon{width:34px;height:34px}.production-ai-alert-actions{grid-column:1/-1}.totem-presentation-bar{align-items:flex-start}.totem-presentation-bar>div{max-width:60%}.totem-tablet-frame{width:min(100%,520px);height:calc(100vh - 300px);min-height:480px;padding:10px;border:1px solid #cbd5e1}.live-wall-toolbar>span{width:100%;margin-left:0}.production-kanban{grid-template-columns:repeat(7,minmax(210px,1fr))!important;overflow-x:auto!important}.production-day{min-width:210px!important}}

/* EMBALAGEM — fluxo contínuo, rastreável e com geometria quadrada */
.page-content.packaging-flow-page *,.page-content.packaging-flow-page *::before,.page-content.packaging-flow-page *::after{border-radius:0!important}
.pack-page-head{display:flex;justify-content:space-between;align-items:flex-start;gap:22px;margin:4px 0 16px;padding:22px 24px;background:#fff;border:1px solid #dfe6ef;border-left:5px solid #2563eb}
.pack-page-head>div>span,.pack-eyebrow{color:#64748b;font-size:10px;font-weight:900;letter-spacing:.13em;text-transform:uppercase}
.pack-page-head h2{margin:5px 0 7px;color:#172033;font-size:24px}.pack-page-head p{max-width:850px;margin:0;color:#64748b;font-size:13px;line-height:1.55}
.pack-live,.pack-step-counter,.pack-tag{display:inline-flex;align-items:center;gap:8px;min-height:34px;padding:0 11px;background:#eff6ff;color:#1d4ed8;font-size:11px;font-weight:900;white-space:nowrap}
.pack-live i,.vision-connection i{width:8px;height:8px;background:#10b981;box-shadow:0 0 0 3px #d1fae5}
.pack-kpis{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px;margin:0 0 16px}
.pack-kpis>div{display:grid;gap:6px;padding:14px 16px;background:#fff;border:1px solid #e2e8f0;border-top:3px solid #2563eb}
.pack-kpis>div:nth-child(2){border-top-color:#f59e0b}.pack-kpis>div:nth-child(3){border-top-color:#10b981}
.pack-kpis small,.pack-record-meta small,.pack-lot-summary small{color:#64748b;font-size:10px;font-weight:900;letter-spacing:.06em;text-transform:uppercase}
.pack-kpis strong{font-size:24px;color:#172033}
.pack-card{min-width:0;margin:0 0 14px;padding:18px 20px;background:#fff;border:1px solid #dfe6ef;box-shadow:0 5px 18px rgba(15,23,42,.035)}
.pack-card h3{margin:0 0 5px;color:#1e293b;font-size:17px}.pack-card-head{display:flex;justify-content:space-between;align-items:flex-start;gap:16px;margin-bottom:14px}
.pack-card-head p{margin:0;color:#64748b;font-size:12px}.pack-record-list,.pack-quality-list,.pack-case-create-list{display:grid;gap:12px}
.pack-record{padding:16px;background:#fff;border:1px solid #dfe6ef;border-left:5px solid #94a3b8}
.pack-record.active{border-left-color:#2563eb}.pack-record.ready{border-left-color:#f59e0b;background:#fffdf7}.pack-record.done{border-left-color:#10b981}.pack-record-main{display:flex;justify-content:space-between;align-items:center;gap:16px}
.pack-record-title{display:flex;align-items:center;gap:12px;min-width:0}.pack-step-icon{display:grid;place-items:center;flex:none;width:42px;height:42px;background:#eff6ff;color:#2563eb;font-size:17px}
.pack-record-title>div{min-width:0}.pack-record-title small{color:#64748b;font-size:10px;font-weight:900;letter-spacing:.07em}.pack-record-title h4{margin:3px 0;font-size:17px;color:#172033}.pack-record-title span:last-child{color:#64748b;font-size:12px}
.pack-state{display:inline-flex;align-items:center;gap:7px;padding:7px 10px;font-size:11px;font-weight:900;white-space:nowrap}.pack-state.pending{background:#f1f5f9;color:#475569}.pack-state.active{background:#dbeafe;color:#1d4ed8}.pack-state.ready{background:#ffedd5;color:#c2410c}.pack-state.done{background:#d1fae5;color:#047857}.pack-state.blocked{background:#ffe4e6;color:#be123c}
.pack-record-meta{display:grid;grid-template-columns:1fr 1.35fr 1.35fr minmax(145px,.75fr);gap:10px;margin:14px 0 0;padding:12px 0;border-top:1px solid #e8edf3;border-bottom:1px solid #e8edf3}
.pack-record-meta>div{display:grid;align-content:center;gap:4px}.pack-record-meta b{font-size:12px;color:#263449}.pack-record-meta span{font-size:11px;color:#64748b}
.pack-countdown{display:grid!important;place-items:center;padding:8px 10px;background:#f1f5f9;color:#64748b;font-size:13px;font-weight:950;letter-spacing:.08em}.pack-countdown.active{background:#1d4ed8;color:#fff;font-variant-numeric:tabular-nums;font-size:18px}.pack-countdown.ready{background:#fef3c7;color:#b45309}.pack-countdown.done{background:#d1fae5;color:#047857}
.pack-action-row,.pack-line-form,.pack-quality-form,.pack-case-create-row{display:flex;align-items:flex-end;gap:10px;flex-wrap:wrap;margin-top:13px}
.pack-inline-field{display:grid;gap:6px;min-width:150px;flex:1}.pack-inline-field>span{color:#64748b;font-size:10px;font-weight:900;letter-spacing:.04em;text-transform:uppercase}
.pack-inline-field input,.pack-inline-field select{width:100%;min-width:0;height:41px;padding:8px 10px;border:1px solid #cbd5e1;background:#fff;color:#172033;font:inherit;font-size:12px}
.pack-action-row button,.pack-line-card>.primary-btn,.vision-controls button,.pack-case-create-row button{min-height:41px;white-space:nowrap}
.pack-alert-ready{display:flex;align-items:center;gap:12px;flex-wrap:wrap;margin-top:13px;padding:12px 14px;background:#fffbeb;border-left:4px solid #f59e0b;color:#92400e}
.pack-alert-ready>i{font-size:18px}.pack-alert-ready>div{display:grid;gap:3px;flex:1;min-width:200px}.pack-alert-ready strong{font-size:12px}.pack-alert-ready span{font-size:11px}.pack-alert-ready .pack-inline-field{flex:0 1 210px}.pack-alert-ready.is-blocked{background:#fff1f2;border-color:#e11d48;color:#9f1239}
.pack-record-foot{display:flex;align-items:center;gap:9px;flex-wrap:wrap;margin-top:13px;padding:10px 12px;background:#f0fdf4;color:#047857;font-size:12px;font-weight:750}.pack-record-foot button{margin-left:auto}
.pack-muted{align-self:center;color:#64748b;font-size:11px}.pack-empty{display:grid;justify-items:center;gap:10px;padding:34px 20px;text-align:center;background:#f8fafc;border:1px solid #dfe6ef;color:#64748b}.pack-empty>i{font-size:28px;color:#2563eb}.pack-empty strong{color:#172033;font-size:15px}.pack-empty span{max-width:560px;font-size:12px;line-height:1.5}.pack-empty .primary-btn,.pack-empty .secondary-btn{margin-top:5px}
.pack-note{display:flex;align-items:flex-start;gap:10px;margin:14px 0;padding:12px 14px;background:#eff6ff;border-left:4px solid #2563eb;color:#475569;font-size:11px;line-height:1.55}.pack-note i{color:#2563eb;margin-top:2px}
.pack-process-ribbon{display:flex;align-items:center;gap:9px;overflow:auto;margin:0 0 15px;padding:11px 13px;background:#fff;border:1px solid #dfe6ef;white-space:nowrap}.pack-process-ribbon span{display:inline-flex;align-items:center;gap:7px;padding:8px 10px;background:#f1f5f9;color:#64748b;font-size:11px;font-weight:850}.pack-process-ribbon span.done{background:#d1fae5;color:#047857}.pack-process-ribbon span.active{background:#dbeafe;color:#1d4ed8}.pack-process-ribbon>b{color:#94a3b8}
.pack-line-grid{display:grid;gap:12px}.pack-line-card{margin:0}.pack-line-card>.primary-btn{margin-top:14px}.pack-line-form{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));margin:8px 0 12px}
.pack-lot-summary{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:1px;background:#dfe6ef;border:1px solid #dfe6ef}.pack-lot-summary>div{display:grid;gap:5px;min-width:0;padding:10px;background:#f8fafc}.pack-lot-summary b{overflow-wrap:anywhere;font-size:11px;color:#263449}
.pack-step-counter{background:#eef2ff;color:#4338ca}
.pack-counter-context{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:1px;margin-bottom:14px;background:#dfe6ef;border:1px solid #dfe6ef}.pack-counter-context>div{display:grid;align-content:center;gap:5px;min-width:0;padding:12px;background:#fff}.pack-counter-context small{color:#64748b;font-size:9px;font-weight:900;letter-spacing:.06em;text-transform:uppercase}.pack-counter-context strong{overflow-wrap:anywhere;color:#1e293b;font-size:12px}.pack-counter-context strong span{display:block;color:#64748b;font-size:10px;font-weight:700}
.vision-layout{display:grid;grid-template-columns:minmax(0,1.65fr) minmax(240px,.75fr);gap:14px;align-items:stretch}.vision-monitor{min-width:0;padding:14px;background:#101827;border:1px solid #1e293b;color:#fff}.vision-monitor-head{display:flex;justify-content:space-between;align-items:center;gap:12px;margin-bottom:10px}.vision-monitor-head>div{display:flex;align-items:center;gap:8px;color:#cbd5e1;font-size:10px;font-weight:900;letter-spacing:.08em}.vision-monitor-head>div i{color:#60a5fa;font-size:15px}.vision-connection{display:inline-flex;align-items:center;gap:8px;color:#94a3b8;font-size:9px;font-weight:900;letter-spacing:.08em}.vision-connection i{width:7px;height:7px;background:#f59e0b;box-shadow:0 0 0 3px #78350f}
.vision-scene{position:relative;height:330px;overflow:hidden;background:linear-gradient(180deg,#172235,#0b1220);border:1px solid #334155}.vision-grid-overlay{position:absolute;inset:0;opacity:.18;background-image:linear-gradient(rgba(148,163,184,.35) 1px,transparent 1px),linear-gradient(90deg,rgba(148,163,184,.35) 1px,transparent 1px);background-size:28px 28px}.vision-lane{position:absolute;top:25%;left:-3%;width:106%;height:53%;overflow:hidden;background:repeating-linear-gradient(90deg,#475569 0 36px,#334155 36px 39px);border-top:5px solid #64748b;border-bottom:5px solid #64748b}.vision-lane-mark{position:absolute;top:47%;left:0;width:100%;height:2px;background:repeating-linear-gradient(90deg,#cbd5e1 0 34px,transparent 34px 58px);opacity:.35}.vision-product{position:absolute;top:25%;display:grid;place-items:center;width:54px;height:90px;background:linear-gradient(135deg,#e2e8f0,#94a3b8);border:2px solid #f8fafc;box-shadow:0 6px 18px #02061780;color:#475569;font-size:12px;font-weight:950;animation:packBelt 9s linear infinite}.vision-product::after{content:'';position:absolute;inset:7px;border:1px solid #64748b}.vision-product span{z-index:1;padding:4px;background:#fff}.product-a{left:110%;animation-delay:-1s}.product-b{left:110%;animation-delay:-3.1s}.product-c{left:110%;animation-delay:-5.2s}.product-d{left:110%;animation-delay:-7.3s}.vision-scene:not(.is-running) .vision-product{animation-play-state:paused;left:calc(15% + var(--position,0px))}.product-a{--position:0px}.product-b{--position:120px}.product-c{--position:240px}.product-d{--position:360px}.vision-scene.is-running .vision-product{animation-play-state:running}
.vision-canvas{position:absolute;inset:0;display:block;width:100%;height:100%}
@keyframes packBelt{0%{transform:translateX(0)}100%{transform:translateX(-130vw)}}
.vision-scan-line{position:absolute;top:15%;bottom:12%;left:72%;width:2px;background:#22d3ee;box-shadow:0 0 14px #22d3ee;opacity:.8;pointer-events:none}.vision-detection{position:absolute;z-index:3;top:30%;left:35%;padding:4px 6px;border:2px solid #22c55e;color:#86efac;background:#052e1688;font:800 8px ui-monospace,monospace}.detection-b{top:61%;left:64%;border-color:#38bdf8;color:#bae6fd;background:#082f4988}.vision-overlay-timestamp{position:absolute;right:12px;bottom:10px;color:#cbd5e1;font:700 9px ui-monospace,monospace}.vision-overlay-timestamp i{color:#f59e0b}.vision-scene.is-running .vision-overlay-timestamp i{color:#fb7185;animation:visionBlink 1s steps(2,end) infinite}@keyframes visionBlink{to{opacity:.25}}
.vision-camera-corner{position:absolute;width:20px;height:20px;border-color:#38bdf8;border-style:solid}.vision-camera-corner.top-left{top:9px;left:9px;border-width:2px 0 0 2px}.vision-camera-corner.top-right{top:9px;right:9px;border-width:2px 2px 0 0}.vision-camera-corner.bottom-left{bottom:9px;left:9px;border-width:0 0 2px 2px}.vision-camera-corner.bottom-right{right:9px;bottom:9px;border-width:0 2px 2px 0}.vision-scene-caption{display:flex;gap:7px;align-items:flex-start;padding:9px 2px 0;color:#94a3b8;font-size:10px;line-height:1.45}.vision-scene-caption i{color:#fbbf24;margin-top:1px}
.vision-controls{display:flex;align-items:flex-end;gap:8px;flex-wrap:wrap;margin-top:12px}.vision-controls .pack-inline-field{flex:1 1 190px}.vision-controls button{padding:0 11px;font-size:11px}.vision-counter-card{display:flex;flex-direction:column;align-items:flex-start;min-width:0;padding:20px;background:#fff;border:1px solid #dfe6ef;border-top:4px solid #2563eb}.vision-counter-label{display:flex;align-items:center;gap:7px;color:#64748b;font-size:10px;font-weight:950;letter-spacing:.08em}.vision-counter-label i{color:#2563eb}.vision-counter-card>strong{margin:20px 0 3px;color:#172033;font-size:clamp(42px,5vw,66px);line-height:1;font-variant-numeric:tabular-nums}.vision-counter-card>span:nth-of-type(2){color:#64748b;font-size:12px}.vision-progress{width:100%;height:12px;margin:18px 0;background:#e2e8f0}.vision-progress i{display:block;height:100%;background:linear-gradient(90deg,#2563eb,#06b6d4);transition:width .3s}.vision-counter-stats{display:grid;grid-template-columns:1fr 1fr;gap:10px;width:100%;padding:12px 0;border-top:1px solid #e2e8f0}.vision-counter-stats div{display:grid;gap:5px}.vision-counter-stats small{color:#64748b;font-size:9px;font-weight:900;text-transform:uppercase}.vision-counter-stats b{color:#334155;font-size:11px}.vision-counter-stats b.is-online{color:#059669}.vision-counter-stats b.is-paused{color:#b45309}.vision-finish{justify-content:center;width:100%;margin-top:auto}.vision-finish:disabled,.vision-controls button:disabled{opacity:.45;cursor:not-allowed;transform:none}
.pack-history-row{display:grid;grid-template-columns:1.2fr 1fr auto auto;align-items:center;gap:12px;padding:12px 0;border-bottom:1px solid #e2e8f0}.pack-history-row:last-child{border-bottom:0}.pack-history-row>span:nth-child(2){color:#64748b;font-size:11px}.pack-history-row>b{color:#1e293b;font-size:12px;white-space:nowrap}
.pack-quality-form{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));margin-top:14px;padding-top:14px;border-top:1px solid #e2e8f0}.pack-quality-form .pack-wide{grid-column:1/-1}.pack-quality-form .pack-action-row{margin-top:0}
.pack-qa-section{margin-top:14px;padding-top:14px;border-top:1px solid #dfe6ef}.pack-qa-section>h4{margin:0;color:#253249;font-size:13px;font-weight:900}.pack-qa-summary{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:1px;margin-top:12px;background:#dfe6ef;border:1px solid #dfe6ef}.pack-qa-summary>div{display:grid;align-content:start;gap:5px;min-width:0;padding:10px;background:#f8fafc}.pack-qa-summary small{color:#64748b;font-size:9px;font-weight:900;text-transform:uppercase}.pack-qa-summary strong{overflow-wrap:anywhere;color:#334155;font-size:11px}.pack-quality-card .pack-inline-field input[readonly]{background:#f8fafc;color:#475569}
.control-page-shell{display:grid;gap:14px;min-width:0}.control-page-head{display:flex;align-items:center;gap:14px;min-width:0;padding:16px 18px;background:#fff;border:1px solid #dfe5ed;border-left:4px solid #2563eb}.control-page-icon{display:grid;place-items:center;flex:0 0 42px;width:42px;height:42px;background:#eff6ff;color:#2563eb;font-size:18px}.control-page-head>div:nth-child(2){min-width:0}.control-page-head>div:nth-child(2)>span,.control-section-head>div>span{color:#64748b;font-size:9px;font-weight:950;letter-spacing:.12em}.control-page-head h2{margin:3px 0;color:#172033;font-size:21px;font-weight:900}.control-page-head p{margin:0;color:#64748b;font-size:12px}.control-page-context{display:flex;align-items:center;gap:8px;margin-left:auto;padding:8px 10px;background:#f8fafc;border:1px solid #e2e8f0;color:#64748b;font-size:9px;font-weight:900;letter-spacing:.06em;line-height:1.35}.control-page-context i{color:#2563eb;font-size:15px}.control-stats{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:1px;background:#dfe5ed;border:1px solid #dfe5ed}.control-stats>div{display:grid;align-content:center;gap:5px;min-width:0;min-height:92px;padding:13px 15px;background:#fff;border-top:3px solid #2563eb}.control-stats>div:nth-child(2){border-top-color:#f59e0b}.control-stats>div:nth-child(3){border-top-color:#10b981}.control-stats>div:nth-child(4){border-top-color:#7c3aed}.control-stats small{color:#64748b;font-size:9px;font-weight:950;letter-spacing:.08em}.control-stats strong{color:#172033;font-size:22px;font-weight:950;line-height:1.1}.control-stats strong.is-alert{color:#d97706}.control-stats strong i{color:#2563eb;font-size:17px}.control-stats span{color:#64748b;font-size:10px}.control-section{min-width:0;padding:16px;background:#fff;border:1px solid #dfe5ed}.control-section-head{display:flex;align-items:center;justify-content:space-between;gap:14px;margin-bottom:12px}.control-section-head h3{margin:4px 0;color:#172033;font-size:15px;font-weight:900}.control-section-head p{margin:0;color:#64748b;font-size:11px}.control-actions{display:flex;align-items:center;gap:8px;flex-wrap:wrap}.control-actions .primary-btn,.control-actions .secondary-btn{border-radius:0}.control-page-shell .card,.control-page-shell .prep-filter-card,.control-page-shell .data-table,.control-page-shell .mini-btn{border-radius:0}.control-page-shell .card{border-color:#dfe5ed;box-shadow:none}
.pack-legacy{margin:16px 0;background:#fff;border:1px solid #dfe6ef}.pack-legacy>summary{padding:13px 16px;color:#334155;font-size:12px;font-weight:850;cursor:pointer;list-style-position:inside}.pack-legacy[open]{padding-bottom:12px}.pack-legacy[open]>summary{margin-bottom:12px;border-bottom:1px solid #e2e8f0;background:#f8fafc}
.pack-case-create-list{margin-bottom:14px}.pack-case-create-row{display:grid;grid-template-columns:minmax(150px,.55fr) minmax(220px,1fr) auto}.pack-case-table{min-width:850px}.pack-case-table td small{display:block;margin-top:4px;color:#64748b;font-size:10px}.pack-case-table td{vertical-align:top}
@media(max-width:1050px){.pack-record-meta{grid-template-columns:repeat(2,minmax(0,1fr))}.pack-line-form{grid-template-columns:repeat(3,minmax(0,1fr))}.pack-qa-summary{grid-template-columns:repeat(3,minmax(0,1fr))}.vision-layout{grid-template-columns:1fr}.vision-counter-card{min-height:280px}.pack-counter-context{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:700px){.pack-page-head{flex-direction:column;padding:17px}.pack-page-head h2{font-size:21px}.pack-kpis{grid-template-columns:1fr}.pack-record-main{align-items:flex-start;flex-direction:column}.pack-record-meta{grid-template-columns:1fr 1fr}.pack-action-row,.pack-alert-ready{align-items:stretch;flex-direction:column}.pack-action-row>.pack-inline-field,.pack-alert-ready>.pack-inline-field{width:100%;flex:1}.pack-action-row button,.pack-alert-ready button{width:100%;justify-content:center}.pack-line-form{grid-template-columns:1fr 1fr}.pack-lot-summary{grid-template-columns:1fr 1fr}.pack-counter-context{grid-template-columns:1fr 1fr}.vision-scene{height:250px}.vision-controls{align-items:stretch}.vision-controls .pack-inline-field{flex-basis:100%}.vision-controls button{flex:1 1 42%;justify-content:center}.pack-quality-form{grid-template-columns:1fr 1fr}.pack-qa-summary{grid-template-columns:1fr 1fr}.pack-case-create-row{grid-template-columns:1fr}.pack-history-row{grid-template-columns:1fr auto}.pack-history-row>span:nth-child(2){grid-column:1}.pack-history-row>b{grid-column:2;grid-row:1}.pack-state{font-size:10px}}
@media(max-width:700px){.control-page-shell{gap:10px}.control-page-head{align-items:flex-start;padding:13px}.control-page-icon{flex-basis:36px;width:36px;height:36px}.control-page-head h2{font-size:18px}.control-page-context{display:none}.control-stats{grid-template-columns:1fr 1fr}.control-stats>div{min-height:78px;padding:10px}.control-section{padding:12px}.control-section-head{align-items:flex-start;flex-direction:column}.control-actions{width:100%}.control-actions button{flex:1 1 45%;justify-content:center}}
.employee-list-table{min-width:920px}.employee-list-link{display:flex;align-items:center;gap:10px;min-width:190px;padding:0;border:0;background:transparent;text-align:left;color:#1e293b;cursor:pointer}.employee-list-link>span:nth-child(2){display:grid;gap:3px}.employee-list-link strong{font-size:12px}.employee-list-link small{color:#64748b;font-size:10px}.employee-list-link>i{margin-left:auto;color:#2563eb;font-size:11px}.employee-mini-photo,.employee-photo{display:block;flex:none;background-image:url('../img/employee-portraits-contact-sheet.png');background-repeat:no-repeat;background-size:200% 200%;border:1px solid #dbe3ec}.employee-mini-photo{width:38px;height:44px}.employee-photo{width:112px;height:142px;background-size:200% 200%;border:3px solid #fff;box-shadow:0 0 0 1px #dbe3ec}.employee-portrait-a{background-position:0 0}.employee-portrait-b{background-position:100% 0}.employee-portrait-c{background-position:0 100%}.employee-portrait-d{background-position:100% 100%}.employee-profile-toolbar{display:flex;justify-content:space-between;align-items:center;gap:10px;margin-bottom:12px}.employee-profile-toolbar button{border-radius:0}.employee-profile-card{display:grid;grid-template-columns:minmax(0,1fr) minmax(390px,.85fr);gap:18px;align-items:center;padding:20px;background:#fff;border:1px solid #dfe5ed;border-left:4px solid #2563eb}.employee-profile-identity{display:flex;align-items:center;gap:18px;min-width:0}.employee-profile-identity h3{margin:4px 0;color:#172033;font-size:23px}.employee-profile-identity p{display:flex;align-items:center;gap:12px;margin:0;color:#64748b;font-size:13px}.employee-profile-eyebrow,.employee-panel-head>div>span{color:#64748b;font-size:9px;font-weight:950;letter-spacing:.12em}.employee-role-line{display:flex;gap:8px;margin-top:12px;flex-wrap:wrap}.employee-role-line span{padding:6px 9px;background:#eff6ff;color:#1d4ed8;font-size:10px;font-weight:850}.employee-status{display:inline-flex;align-items:center;padding:5px 8px;background:#dcfce7;color:#15803d;font-size:10px;font-weight:900;white-space:nowrap}.employee-profile-quick{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:1px;background:#dfe5ed;border:1px solid #dfe5ed}.employee-profile-quick>div{display:grid;align-content:center;gap:7px;min-height:76px;padding:10px;background:#f8fafc}.employee-profile-quick small,.employee-field small{color:#64748b;font-size:9px;font-weight:900;letter-spacing:.06em;text-transform:uppercase}.employee-profile-quick strong{color:#172033;font-size:12px;line-height:1.4}.employee-profile-grid{display:grid;grid-template-columns:1.35fr .9fr;gap:12px}.employee-data-panel{min-width:0;padding:16px;background:#fff;border:1px solid #dfe5ed}.employee-panel-head{display:flex;justify-content:space-between;align-items:flex-start;gap:12px;margin-bottom:12px;padding-bottom:10px;border-bottom:1px solid #e5eaf1}.employee-panel-head h4{margin:4px 0 0;color:#172033;font-size:15px}.employee-panel-head p{margin:4px 0 0;color:#64748b;font-size:11px}.employee-panel-head>i{display:grid;place-items:center;width:34px;height:34px;background:#eff6ff;color:#2563eb}.employee-fields{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:1px;background:#e2e8f0;border:1px solid #e2e8f0}.employee-fields-single{grid-template-columns:1fr}.employee-field{display:grid;align-content:start;gap:5px;min-width:0;min-height:60px;padding:10px;background:#fff}.employee-field strong{color:#263449;font-size:11px;line-height:1.45;overflow-wrap:anywhere}.employee-note{display:flex;gap:9px;align-items:flex-start;padding:11px;background:#eff6ff;color:#1e40af;font-size:10px;line-height:1.45}.employee-note i{margin-top:2px}.employee-documents-panel{margin-top:0}.employee-document-warning{margin:0 0 12px;padding:10px 12px;background:#fff7ed;border-left:4px solid #f97316;color:#9a3412;font-size:10px;font-weight:950;letter-spacing:.025em}.employee-document-warning i{margin-right:6px}.employee-documents{display:grid;grid-template-columns:1fr 1fr;gap:12px}.employee-documents figure{position:relative;min-width:0;margin:0;overflow:hidden;background:#f1f5f9;border:1px solid #dbe3ec}.employee-documents figure img{display:block;width:200%;height:180px;max-width:none;object-fit:cover}.employee-documents figure:nth-child(2) img{transform:translateX(-50%)}.employee-documents figcaption{display:grid;gap:4px;padding:10px 11px;background:#fff;border-top:1px solid #e2e8f0}.employee-documents figcaption strong{color:#263449;font-size:11px}.employee-documents figcaption span,.employee-docs-foot{color:#64748b;font-size:10px}.employee-docs-foot{margin:10px 0 0}.employee-docs-foot i{margin-right:5px;color:#2563eb}
@media(max-width:1000px){.employee-profile-card{grid-template-columns:1fr}.employee-profile-grid{grid-template-columns:1fr}.employee-profile-quick{max-width:none}}
@media(max-width:700px){.employee-profile-toolbar{align-items:stretch;flex-direction:column}.employee-profile-toolbar button{justify-content:center}.employee-profile-identity{align-items:flex-start;gap:12px}.employee-photo{width:82px;height:108px}.employee-profile-identity h3{font-size:18px}.employee-profile-quick{grid-template-columns:1fr}.employee-profile-quick>div{min-height:56px}.employee-fields{grid-template-columns:1fr 1fr}.employee-documents{grid-template-columns:1fr}.employee-documents figure img{height:170px}}
.employee-data-validation{display:flex;gap:8px;align-items:center;padding:9px 11px;background:#fff7ed;border-left:4px solid #f59e0b;color:#9a3412;font-size:10px;font-weight:800}.employee-data-validation i{flex:none}
.employee-mini-photo,.employee-photo{background-size:auto 200%!important}.employee-photo{width:96px;height:128px}.employee-mini-photo{width:34px;height:42px}
.employee-documents-preview{width:min(100%,560px);margin:0;background:#f8fafc;border:1px solid #dbe3ec}.employee-documents-preview>img{display:block;width:100%;height:auto;max-height:316px;object-fit:contain}.employee-documents-preview figcaption{display:grid;grid-template-columns:1fr 1fr;gap:10px;padding:10px 12px;background:#fff;border-top:1px solid #e2e8f0}.employee-documents-preview figcaption span{display:grid;gap:4px}.employee-documents-preview figcaption strong{color:#263449;font-size:11px}.employee-documents-preview figcaption small{color:#64748b;font-size:10px}
@media(max-width:700px){.employee-photo{width:78px;height:104px}.employee-documents-preview{width:100%}.employee-documents-preview figcaption{grid-template-columns:1fr}}
.vision-scene{height:auto;aspect-ratio:16/9;min-height:300px;max-height:600px;background:#080d15}
.vision-video{position:absolute;inset:0;display:block;width:100%;height:100%;object-fit:contain;background:#080d15}
.vision-canvas{position:absolute;inset:0;z-index:2;display:block;width:100%;height:100%;pointer-events:none}
.vision-scan-line{z-index:3;pointer-events:none}
.vision-overlay-timestamp,.vision-camera-corner{z-index:4}
@media(max-width:700px){.vision-scene{height:auto;aspect-ratio:16/9;min-height:220px;max-height:none}}

/* Navegação: ícones sempre na mesma coluna e níveis internos recolhíveis */
.side-nav .group-head,.side-nav .sub-head,.side-nav .nav-item{display:grid;grid-template-columns:22px minmax(0,1fr) 14px;align-items:center;gap:10px;width:100%;min-height:42px;padding:8px 11px;text-align:left;transform:none!important}
.side-nav .group-head>i.nav-icon,.side-nav .sub-head>i.nav-icon,.side-nav .nav-item>i.nav-icon{display:grid;place-items:center;width:22px;min-width:22px;margin:0;color:#9fb5ff;font-size:14px}
.side-nav .nav-item>i.nav-icon{color:#aebcf0}.side-nav .nav-item.active>i.nav-icon,.side-nav .sub-section.open>.sub-head>i.nav-icon{color:#68e1fd}
.side-nav .nav-label{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.side-nav .nav-chevron{display:grid;place-items:center;width:14px;margin:0 0 0 auto;font-size:10px;transition:transform .18s ease;opacity:.68}
.side-nav .nav-group.open>.group-head>.nav-chevron,.side-nav .sub-section.open>.sub-head>.nav-chevron{transform:rotate(90deg)}
.side-nav .group-items{padding:3px 5px 8px}.side-nav .sub-section{margin:2px 0}.side-nav .sub-head{color:#e5eaff;background:rgba(255,255,255,.035);font-size:12px;font-weight:800}
.side-nav .sub-items{display:none;margin:0;padding:2px 0 4px;border:0}.side-nav .sub-section.open>.sub-items{display:grid;gap:2px}
.side-nav .nav-item{padding-left:11px;color:#cbd5f5}.side-nav .nav-item.active{background:rgba(255,255,255,.1);box-shadow:inset 3px 0 0 #68e1fd}
.side-nav .nav-item:hover,.side-nav .sub-head:hover,.side-nav .group-head:hover{transform:none!important;background-color:rgba(255,255,255,.09)}
.sidebar-collapsed .side-nav .nav-label,.sidebar-collapsed .side-nav .nav-chevron,.sidebar-collapsed .side-nav .nav-item-spacer,.sidebar.collapsed .side-nav .nav-label,.sidebar.collapsed .side-nav .nav-chevron,.sidebar.collapsed .side-nav .nav-item-spacer,.sidebar.is-collapsed .side-nav .nav-label,.sidebar.is-collapsed .side-nav .nav-chevron,.sidebar.is-collapsed .side-nav .nav-item-spacer{display:none!important}
.sidebar-collapsed .side-nav .group-head,.sidebar-collapsed .side-nav .sub-head,.sidebar-collapsed .side-nav .nav-item,.sidebar.collapsed .side-nav .group-head,.sidebar.collapsed .side-nav .sub-head,.sidebar.collapsed .side-nav .nav-item,.sidebar.is-collapsed .side-nav .group-head,.sidebar.is-collapsed .side-nav .sub-head,.sidebar.is-collapsed .side-nav .nav-item{grid-template-columns:22px 0 0;justify-content:center;padding:8px 0}
.sidebar-collapsed .side-nav .group-head>i.nav-icon,.sidebar-collapsed .side-nav .sub-head>i.nav-icon,.sidebar-collapsed .side-nav .nav-item>i.nav-icon,.sidebar.collapsed .side-nav .group-head>i.nav-icon,.sidebar.collapsed .side-nav .sub-head>i.nav-icon,.sidebar.collapsed .side-nav .nav-item>i.nav-icon,.sidebar.is-collapsed .side-nav .group-head>i.nav-icon,.sidebar.is-collapsed .side-nav .sub-head>i.nav-icon,.sidebar.is-collapsed .side-nav .nav-item>i.nav-icon{grid-column:1;justify-self:center}
/* Sidebar behavior: one icon rail, with real accordion sections. */
.side-nav>.nav-group:not(.open)>.group-items{display:none!important}
.side-nav .nav-group.open>.group-items{display:block!important}
.side-nav .sub-section:not(.open)>.sub-items{display:none!important}
.side-nav .sub-section.open>.sub-items{display:block!important}
.side-nav .group-items,.side-nav .sub-items{margin:0!important;padding-left:0!important;padding-right:0!important}
.side-nav .nav-item,.side-nav .group-head,.side-nav .sub-head{display:grid!important;grid-template-columns:22px minmax(0,1fr) 14px!important;align-items:center!important;column-gap:10px!important;padding-left:10px!important;padding-right:10px!important}
.side-nav .nav-item>i.nav-icon,.side-nav .group-head>i.nav-icon,.side-nav .sub-head>i.nav-icon,.side-nav .nav-item>i.ib-nav-icon,.side-nav .group-head>i.ib-nav-icon,.side-nav .sub-head>i.ib-nav-icon{width:22px!important;min-width:22px!important;justify-self:center!important;text-align:center!important}
.side-nav .nav-item>i.nav-icon,.side-nav .group-head>i.nav-icon,.side-nav .sub-head>i.nav-icon,.side-nav .nav-item>i.ib-nav-icon,.side-nav .group-head>i.ib-nav-icon,.side-nav .sub-head>i.ib-nav-icon{display:flex!important;align-items:center!important;justify-content:center!important}
body.ib-sidebar-collapsed .side-nav>.nav-group>.group-items{display:none!important}
body.ib-sidebar-collapsed .side-nav .nav-label,body.ib-sidebar-collapsed .side-nav .nav-item-spacer,body.ib-sidebar-collapsed .side-nav .nav-chevron{display:none!important}
body.ib-sidebar-collapsed .side-nav .nav-item,body.ib-sidebar-collapsed .side-nav .group-head,body.ib-sidebar-collapsed .side-nav .sub-head{grid-template-columns:1fr!important;justify-items:center!important;column-gap:0!important;padding-left:0!important;padding-right:0!important}
body.ib-sidebar-collapsed .side-nav .nav-item>i,body.ib-sidebar-collapsed .side-nav .group-head>i.nav-icon,body.ib-sidebar-collapsed .side-nav .sub-head>i.nav-icon,body.ib-sidebar-collapsed .side-nav .group-head>i.ib-nav-icon,body.ib-sidebar-collapsed .side-nav .sub-head>i.ib-nav-icon{justify-self:center!important}
/* Chat IA operacional — interface conectada ao endpoint seguro do servidor. */
body.chat-ai-active #aiDock{display:none!important}
.operational-chat-layout{display:grid;grid-template-columns:minmax(0,1fr) 320px;gap:16px;align-items:stretch;max-width:1500px;margin:18px auto 30px;min-height:min(760px,calc(100vh - 170px))}
.operational-chat-panel,.chat-context-card,.chat-prompts-card{background:#fff;border:1px solid #dce3ee;border-radius:0;box-shadow:0 4px 18px rgba(15,23,42,.04)}
.operational-chat-panel{display:flex;flex-direction:column;min-height:620px;overflow:hidden}
.operational-chat-head{display:flex;justify-content:space-between;align-items:center;gap:18px;padding:20px 24px;border-bottom:1px solid #e4e9f1;background:#fff}
.operational-chat-head h2{margin:4px 0;font-size:25px;line-height:1.2}
.operational-chat-head p{margin:0;color:#64748b;font-size:14px}
.chat-kicker{display:block;color:#64748b;font-size:11px;font-weight:800;letter-spacing:.12em}
.chat-head-actions{display:flex;align-items:center;gap:8px;flex-wrap:wrap;justify-content:flex-end}
.chat-api-status{display:inline-flex;align-items:center;gap:7px;min-height:34px;padding:0 10px;background:#f1f5f9;color:#475569;font-size:12px;font-weight:700;white-space:nowrap}
.chat-api-status i{width:8px;height:8px;background:#94a3b8;display:inline-block}
.chat-api-status.ready{background:#e9f8f0;color:#087443}.chat-api-status.ready i{background:#12a76a}
.chat-api-status.busy{background:#fff7e8;color:#9a5b00}.chat-api-status.busy i{background:#f59e0b;animation:chatPulse 1s infinite}
.chat-api-status.error{background:#fff0f0;color:#b42318}.chat-api-status.error i{background:#dc2626}
.chat-head-actions select,.chat-clear-btn{height:36px;border:1px solid #d8e0eb;border-radius:0;background:#fff;color:#243146;padding:0 10px;font:inherit;font-size:12px;font-weight:700}
.chat-clear-btn{display:inline-flex;align-items:center;gap:7px;cursor:pointer}.chat-clear-btn:hover{background:#f4f7fb}
.operational-chat-messages{flex:1;min-height:360px;max-height:calc(100vh - 410px);overflow:auto;padding:24px;display:flex;flex-direction:column;gap:14px;background:#f7f9fc}
.chat-welcome{margin:auto;max-width:540px;text-align:center;padding:34px 18px;color:#334155}
.chat-welcome-icon{width:54px;height:54px;display:grid;place-items:center;margin:0 auto 16px;background:#e9edff;color:#4f46e5;font-size:22px}
.chat-welcome h3{margin:10px 0 8px;font-size:22px;color:#172033}
.chat-welcome p{margin:0;color:#64748b;font-size:14px;line-height:1.65}
.chat-message{max-width:min(82%,780px);padding:14px 16px;border-left:4px solid #4f46e5;background:#fff;color:#1f2937;box-shadow:0 2px 8px rgba(15,23,42,.035)}
.chat-message.user{align-self:flex-end;border-left:0;border-right:4px solid #172554;background:#172554;color:#fff}
.chat-message>span{display:block;margin-bottom:5px;color:#64748b;font-size:11px;font-weight:800;letter-spacing:.04em}
.chat-message.user>span{color:#c7d2fe;text-align:right}
.chat-message p{margin:0;font-size:14px;line-height:1.65;white-space:normal;overflow-wrap:anywhere}
.chat-thinking p{color:#56657a}
.operational-chat-composer{display:flex;align-items:flex-end;gap:10px;margin:14px 18px 8px;padding:8px;border:1px solid #cfd8e5;background:#fff}
.operational-chat-composer textarea{flex:1;min-width:0;resize:vertical;min-height:48px;max-height:150px;border:0;outline:0;padding:10px;font:inherit;font-size:14px;line-height:1.5;color:#1e293b}
.operational-chat-composer button{width:42px;height:42px;border:0;border-radius:0;background:#4f46e5;color:#fff;font-size:16px;cursor:pointer}
.operational-chat-composer button:disabled{background:#94a3b8;cursor:wait}
.operational-chat-foot{display:flex;justify-content:space-between;gap:12px;flex-wrap:wrap;padding:8px 20px 16px;color:#64748b;font-size:11px}
.operational-chat-foot i{color:#16a36a;margin-right:5px}
.operational-chat-aside{display:flex;flex-direction:column;gap:14px}
.chat-context-card,.chat-prompts-card{padding:18px}
.chat-context-card h3,.chat-prompts-card h3{margin:8px 0;font-size:17px;color:#172033}
.chat-context-card p{margin:0;color:#64748b;font-size:13px;line-height:1.6}
.chat-context-tags{display:flex;gap:6px;flex-wrap:wrap;margin-top:14px}
.chat-context-tags span{padding:6px 8px;background:#f1f4f9;color:#475569;font-size:11px;font-weight:700}
.chat-prompt{display:grid;grid-template-columns:20px 1fr 14px;gap:9px;align-items:center;width:100%;margin-top:8px;padding:11px 9px;border:1px solid #e2e8f0;border-radius:0;background:#fff;color:#26364d;text-align:left;font-size:12px;font-weight:700;cursor:pointer}
.chat-prompt>i:first-child{color:#4f46e5}.chat-prompt>i:last-child{color:#94a3b8;font-size:10px}
.chat-prompt:hover{border-color:#a5b4fc;background:#f7f8ff}
.chat-human-note{margin:0;padding:13px;background:#eef7f2;color:#35634d;font-size:12px;line-height:1.55}
.chat-human-note i{margin-right:5px}
@keyframes chatPulse{50%{opacity:.35}}
@media(max-width:1100px){.operational-chat-layout{grid-template-columns:minmax(0,1fr) 280px;min-height:auto}.operational-chat-panel{min-height:570px}.operational-chat-messages{max-height:calc(100vh - 410px)}}
@media(max-width:760px){.operational-chat-layout{grid-template-columns:1fr;margin:10px auto 24px}.operational-chat-panel{min-height:600px}.operational-chat-head{align-items:flex-start;flex-direction:column;padding:16px}.chat-head-actions{justify-content:flex-start}.operational-chat-messages{min-height:330px;max-height:55vh;padding:16px}.chat-message{max-width:94%}.operational-chat-foot{padding:8px 14px 14px}.operational-chat-composer{margin:10px 12px 6px}}

/* Configurações, alternância de idioma e header/notificações. Componentes retos conforme o padrão do ERP. */
.sr-only{position:absolute!important;width:1px!important;height:1px!important;padding:0!important;margin:-1px!important;overflow:hidden!important;clip:rect(0,0,0,0)!important;white-space:nowrap!important;border:0!important}
.locale-switcher{height:42px;display:inline-flex;align-items:center;gap:8px;padding:0 10px;border:1px solid #dce3ee;background:#fff;color:#536176}
.locale-switcher>i{font-size:13px;color:#4565a8}
.locale-switcher select{height:40px;min-width:54px;border:0;background:transparent;color:#18243a;font:inherit;font-size:12px;font-weight:850;cursor:pointer;outline:0}
.locale-switcher:focus-within{outline:2px solid #6a8dff;outline-offset:2px}
.badge[hidden]{display:none!important}
.notification-wrap .badge{top:3px;right:3px;border-radius:0}
#localeLoadingOverlay{display:none}
html.i18n-pending #localeLoadingOverlay{position:fixed;inset:0;z-index:99999;display:grid;place-items:center;background:#f7f9fc;color:#18243a;text-align:center}
.locale-loading-card{width:min(420px,calc(100vw - 36px));padding:34px 28px;background:#fff;border:1px solid #dce3ee;box-shadow:0 18px 55px rgba(15,23,42,.12)}
.locale-loading-spinner{display:block;width:32px;height:32px;margin:0 auto 16px;border:3px solid #dce6f5;border-top-color:#315fbd;animation:localeSpin .75s linear infinite}
#localeLoadingMessage{margin:0;color:#34445c;font-size:14px;font-weight:750;line-height:1.6}
.locale-loading-actions{display:flex;justify-content:center;gap:8px;margin-top:16px}
.locale-loading-actions button{padding:9px 13px;border:1px solid #cbd6e6;background:#fff;color:#244c91;font:inherit;font-size:12px;font-weight:750;cursor:pointer}
.locale-loading-actions button[hidden]{display:none}
#localeLoadingOverlay[data-state="error"] .locale-loading-spinner{display:none}
@keyframes localeSpin{to{transform:rotate(360deg)}}
.dropdown-panel.notifications{width:min(430px,calc(100vw - 30px));max-height:min(72vh,620px);overflow:auto;padding:8px;border-radius:0}
.notification-panel-head{position:sticky;top:-8px;z-index:2;display:flex;align-items:center;justify-content:space-between;gap:10px;margin:-8px -8px 6px;padding:14px;background:#fff;border-bottom:1px solid #e5eaf2}
.notification-panel-head strong{font-size:14px;color:#18243a}
.notification-panel-head button{border:0;background:transparent;color:#2859c5;font-size:11px;font-weight:800;cursor:pointer;padding:6px}
.notifications .notif-item{position:relative;display:grid;grid-template-columns:20px minmax(0,1fr) auto;align-items:start;gap:10px;border-radius:0;border-bottom:1px solid #edf0f5;padding:13px 10px}
.notifications .notif-item>i{color:#5473b5;margin-top:2px}
.notifications .notif-item strong{display:block;color:#1c2940;line-height:1.4}
.notifications .notif-item small{color:#68758a;line-height:1.45}
.notifications .notif-item.unread{background:#eef5ff;box-shadow:inset 3px 0 #2870e8}
.notif-state{padding:4px 6px;background:#f0f3f8;color:#67748a;font-size:10px;font-weight:850;white-space:nowrap}
.notif-item.unread .notif-state{background:#dceaff;color:#1757b8}
.notification-empty{margin:0;padding:28px 14px;text-align:center;color:#68758a;font-size:13px}
.notification-page{padding:22px}
.notification-row{border-radius:0!important}
.notification-row.unread{border-left:4px solid #2870e8;background:#f4f8ff}
.notification-state{border:0;padding:8px 10px;font-size:11px;font-weight:850}
.notification-state.is-unread{background:#dceaff;color:#1757b8}
.notification-state.is-read{background:#edf2f7;color:#64748b}
.settings-page{display:block;max-width:1440px;margin:12px auto 36px;color:#172033}
.settings-intro{display:flex;align-items:flex-end;justify-content:space-between;gap:20px;margin:0 0 18px;padding:6px 2px}
.settings-intro h2{margin:5px 0 6px;font-size:25px;letter-spacing:-.02em}
.settings-intro p,.settings-section-head p{margin:0;color:#68758a;font-size:13px;line-height:1.5}
.settings-kicker{display:block;color:#526583;font-size:10px;font-weight:900;letter-spacing:.13em}
.settings-local-note{display:inline-flex;align-items:center;gap:8px;padding:9px 11px;background:#eef5ff;color:#335995;font-size:11px;font-weight:800;white-space:nowrap}
.settings-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:14px}
.settings-section{min-width:0;padding:19px;background:#fff;border:1px solid #dce3ee;box-shadow:0 4px 18px rgba(15,23,42,.035)}
.settings-section-head{display:flex;align-items:flex-start;gap:12px;margin-bottom:17px}
.settings-section-icon{width:36px;height:36px;flex:0 0 36px;display:grid;place-items:center;background:#edf3ff;color:#315fbd}
.settings-section-head h3{margin:0 0 5px;font-size:15px;color:#172033}
.settings-fields{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:13px}
.settings-fields .field{min-width:0}
.settings-fields .field label{font-size:10px;letter-spacing:.06em}
.settings-fields .field input,.settings-fields .field select{width:100%;min-width:0;min-height:42px;border-radius:0;background:#fbfcfe;border-color:#dce3ee;font-size:13px}
.settings-toggles{display:grid;gap:0;border-top:1px solid #edf0f5}
.settings-toggle{min-height:48px;display:flex;align-items:center;justify-content:space-between;gap:14px;padding:9px 0;border-bottom:1px solid #edf0f5;color:#29364c;font-size:13px;font-weight:700;cursor:pointer}
.settings-toggle input{position:absolute;opacity:0;width:1px;height:1px}
.settings-toggle i{position:relative;width:38px;height:21px;flex:0 0 38px;background:#cbd3df;transition:background .18s}
.settings-toggle i:after{content:"";position:absolute;left:3px;top:3px;width:15px;height:15px;background:#fff;transition:transform .18s}
.settings-toggle input:checked+i{background:#167a56}
.settings-toggle input:checked+i:after{transform:translateX(17px)}
.settings-toggle input:focus-visible+i{outline:2px solid #356de0;outline-offset:2px}
.settings-ai-row{display:flex;justify-content:space-between;align-items:center;gap:16px;padding:12px 0;border-top:1px solid #edf0f5;border-bottom:1px solid #edf0f5}
.settings-ai-row>div{display:grid;gap:5px}.settings-ai-row strong{font-size:13px}.settings-ai-row span{font-size:12px;color:#65738a}
.settings-toggle.compact{min-height:auto;border:0;padding:4px 0;white-space:nowrap}
.settings-hint{display:flex;gap:8px;margin:13px 0 0;padding:11px;background:#f2f7f4;color:#426251;font-size:11px;line-height:1.55}
.settings-hint i{margin-top:2px}
.settings-actions{display:flex;align-items:center;justify-content:flex-end;gap:10px;flex-wrap:wrap;margin-top:14px;padding:14px 0;border-top:1px solid #dce3ee}
.settings-actions .primary-btn,.settings-actions .secondary-btn{border-radius:0}
#settingsSaveState{margin-right:auto;color:#167a56;font-size:12px;font-weight:750}
@media(max-width:900px){.settings-grid{grid-template-columns:1fr}.settings-intro{align-items:flex-start;flex-direction:column}}
@media(max-width:760px){.locale-switcher{height:38px;padding:0 7px}.locale-switcher select{height:36px}.dropdown-panel.notifications{right:-46px}.settings-fields{grid-template-columns:1fr}.settings-section{padding:15px}.settings-ai-row{align-items:flex-start;flex-direction:column}.settings-actions{justify-content:stretch}.settings-actions button{flex:1}.notification-page{padding:14px}.notification-row{grid-template-columns:38px minmax(0,1fr)!important}.notification-row .notification-state{grid-column:2;justify-self:start}}
html[lang="ja"] .live-stage-box.active::before,html[lang="ja"] .live-stage-box.demo-active::before,html[lang="ja"] .live-stage-box.flow-moving::before,html[lang="ja"] .live-stage-box.live-current-colored::before,html[lang="ja"] .live-stage-box.flow-moving::after,html[lang="ja"] .live-stage-box.active::after,html[lang="ja"] .live-stage-box.demo-active::after,html[lang="ja"] .live-stage-box.live-current-colored::after{content:"現在"!important}
html[lang="ja"] .live-stage-box.stopped::before,html[lang="ja"] .live-stage-box.stopped::after,html[lang="ja"] .live-stage-box.stopped.live-current-colored::after,html[lang="ja"] .live-product-row.is-stopped .live-stage-box.stopped::after{content:"停止"!important}
html[lang="en"] .live-stage-box.active::before,html[lang="en"] .live-stage-box.demo-active::before,html[lang="en"] .live-stage-box.flow-moving::before,html[lang="en"] .live-stage-box.live-current-colored::before,html[lang="en"] .live-stage-box.flow-moving::after,html[lang="en"] .live-stage-box.active::after,html[lang="en"] .live-stage-box.demo-active::after,html[lang="en"] .live-stage-box.live-current-colored::after{content:"NOW"!important}
html[lang="en"] .live-stage-box.stopped::before,html[lang="en"] .live-stage-box.stopped::after,html[lang="en"] .live-stage-box.stopped.live-current-colored::after,html[lang="en"] .live-product-row.is-stopped .live-stage-box.stopped::after{content:"STOPPED"!important}
