/* ═══════════════════════════════════════════════════════
   bona-shared.css  —  Design tokens + layout base
   Extraído 100% do PainelLayout.tsx e globals do projeto
   ═══════════════════════════════════════════════════════ */

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --bg: #f9f9f8;
  --bg-card: #ffffff;
  --bg-muted: #f4f4f4;
  --border: #e5e5e5;
  --text: #0f0f0f;
  --text-muted: #6b7280;
  --primary: #f97316;
  --primary-10: rgba(249,115,22,.10);
  --primary-light: #fff7ed;
  --primary-border: #fdba74;
  --green: #22c55e;
  --green-dark: #15803d;
  --green-light: #f0fdf4;
  --green-border: #bbf7d0;
  --amber: #f59e0b;
  --destructive: #ef4444;
  --sidebar-w: 224px;
  --sidebar-collapsed: 56px;
  --header-h: 56px;
  --radius: 12px;
  --radius-lg: 16px;
  --shadow-sm: 0 1px 3px rgba(0,0,0,.05);
}

body {
  font-family: 'Inter', sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

/* ── HEADER ── */
.bona-header {
  position: fixed;
  inset-inline: 0;
  top: 0;
  height: var(--header-h);
  background: var(--bg-card);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 16px 0 11px;
  z-index: 40;
}

.header-left { display: flex; align-items: center; gap: 8px; min-width: 0; }
.bona-header.sidebar-open #toggle-icon-fill { fill: currentColor; }
.bona-header.sidebar-closed #toggle-icon-fill { fill: none; }
.header-sub { font-size: 12px; color: var(--text-muted); }
.header-right { display: flex; align-items: center; gap: 4px; }

.notif-badge {
  position: absolute; top: 2px; right: 2px;
  background: var(--destructive); color: #fff;
  font-size: 10px; font-weight: 700; line-height: 1;
  min-width: 16px; height: 16px; border-radius: 9999px;
  display: flex; align-items: center; justify-content: center;
  padding: 0 3px; pointer-events: none;
}
.notif-badge.hidden { display: none; }

/* ── DROPDOWN ── (antes duplicado como <style> inline em cada página) */
.header-avatar-wrap { position: relative; }
.dropdown-menu {
  position: absolute; right: 0; top: calc(100% + 4px);
  background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius);
  box-shadow: 0 8px 24px rgba(0,0,0,.12); min-width: 220px; z-index: 100; padding: 4px 0;
}
.dropdown-menu.hidden { display: none; }
.dropdown-item {
  display: flex; align-items: center; gap: 10px; padding: 9px 14px; font-size: 14px;
  cursor: pointer; transition: background .12s; text-decoration: none; color: var(--text);
  border: none; background: none; width: 100%; font-family: inherit;
}
.dropdown-item:hover { background: var(--bg-muted); }
.dropdown-item.danger { color: var(--destructive); }
.dropdown-sep { height: 1px; background: var(--border); margin: 4px 0; }
.dropdown-label {
  padding: 4px 14px; font-size: 11px; font-weight: 600; color: var(--text-muted);
  text-transform: uppercase; letter-spacing: .05em;
}

/* ── SIDEBAR ── */
.bona-sidebar {
  position: fixed;
  left: 0; top: var(--header-h); bottom: 0;
  background: var(--bg-card);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  z-index: 30;
  overflow: hidden;
  transition: width .2s;
}
.bona-sidebar.open  { width: var(--sidebar-w); }
.bona-sidebar.closed { width: var(--sidebar-collapsed); }

.plan-badge {
  display: inline-block; margin-top: 4px;
  padding: 2px 8px; border-radius: 9999px;
  font-size: 10px; font-weight: 600;
  background: var(--bg-muted); color: var(--text-muted);
}

.sidebar-nav { flex: 1; overflow-y: auto; padding: 12px; }
.bona-sidebar.closed .sidebar-nav { padding: 12px 6px; }

.nav-section-label {
  font-size: 10px; font-weight: 700;
  text-transform: uppercase; letter-spacing: .05em;
  color: var(--text-muted);
  padding: 16px 12px 4px;
}
.bona-sidebar.closed .nav-section-label { display: none; }

.nav-item {
  display: flex; align-items: center; gap: 12px;
  padding: 10px 12px;
  border-radius: var(--radius);
  text-decoration: none;
  color: var(--text-muted);
  font-size: 14px; font-weight: 500;
  transition: background .15s, color .15s;
  cursor: pointer; white-space: nowrap;
}
.nav-item:hover { background: var(--bg-muted); color: var(--text); }
.nav-item.active { background: var(--primary-10); color: var(--primary); }
.nav-item .nav-label { overflow: hidden; text-overflow: ellipsis; }
.bona-sidebar.closed .nav-item { justify-content: center; padding: 10px 0; }
.bona-sidebar.closed .nav-label,
.bona-sidebar.closed .nav-section-label { display: none; }

.sidebar-divider { height: 1px; background: var(--border); margin: 8px 0; }

.sidebar-footer { padding: 12px; border-top: 1px solid var(--border); }
.bona-sidebar.closed .sidebar-footer { padding: 12px 6px; }

.sidebar-action {
  display: flex; align-items: center; gap: 12px;
  padding: 8px 12px;
  border-radius: 8px;
  cursor: pointer;
  background: none; border: none;
  width: 100%; text-align: left;
  color: var(--text-muted); font-size: 14px;
  font-family: 'Inter', sans-serif;
  transition: background .15s;
  white-space: nowrap;
}
.sidebar-action:hover { background: var(--bg-muted); }
.bona-sidebar.closed .sidebar-action { justify-content: center; padding: 8px 0; }
.bona-sidebar.closed .sidebar-action .theme-label,
.bona-sidebar.closed .sidebar-action .lang-label { display: none; }

/* ── MAIN ── */
.bona-main {
  padding: 80px 20px 24px;
  min-height: 100vh;
  transition: margin-left .2s;
}
.bona-main.sidebar-open  { margin-left: var(--sidebar-w); }
.bona-main.sidebar-closed { margin-left: var(--sidebar-collapsed); }
.bona-main-inner { max-width: 1600px; margin: 0 auto; }

/* ── ICON BUTTONS ── */
.icon-btn {
  background: none; border: none; cursor: pointer;
  padding: 7px; border-radius: 8px; color: var(--text-muted);
  display: flex; align-items: center; position: relative;
  transition: background .15s;
}
.icon-btn:hover { background: var(--bg-muted); }

.avatar {
  width: 32px; height: 32px; border-radius: 50%;
  background: #e5e7eb;
  display: flex; align-items: center; justify-content: center;
  font-size: 12px; font-weight: 600; color: var(--text-muted);
  cursor: pointer;
}

/* ── COMMON COMPONENTS ── */
.badge {
  display: inline-flex; align-items: center;
  padding: 2px 8px; border-radius: 9999px;
  font-size: 12px; font-weight: 600;
}
.badge-muted { background: var(--bg-muted); color: var(--text-muted); }
.badge-primary { background: var(--primary-10); color: var(--primary); }
.badge-green { background: #dcfce7; color: var(--green-dark); }
.badge-amber { background: #fef9c3; color: #92400e; }
.badge-blue { background: #dbeafe; color: #1d4ed8; }
.badge-red { background: #fee2e2; color: #991b1b; }
.badge-outline { background: transparent; border: 1px solid var(--border); color: var(--text); }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  padding: 8px 16px; border-radius: 8px; border: none;
  font-size: 14px; font-weight: 500; font-family: inherit;
  cursor: pointer; transition: opacity .15s, background .15s;
  text-decoration: none;
}
.btn:disabled { opacity: .5; cursor: not-allowed; }
.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:hover:not(:disabled) { background: #ea6c0a; }
.btn-outline { background: #fff; border: 1px solid var(--border); color: var(--text); }
.btn-outline:hover:not(:disabled) { background: var(--bg-muted); }
html.dark .btn-outline, html.warm .btn-outline { background: var(--bg-card); }
.btn-ghost { background: transparent; color: var(--text-muted); }
.btn-ghost:hover:not(:disabled) { background: var(--bg-muted); color: var(--text); }
.btn-destructive { background: var(--destructive); color: #fff; }
.btn-sm { padding: 5px 10px; font-size: 12px; }
.btn-icon { padding: 7px; border-radius: 8px; }

.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
}

.input {
  width: 100%; padding: 8px 12px;
  border: 1px solid var(--border); border-radius: 8px;
  font-size: 14px; font-family: inherit;
  background: var(--bg-card); color: var(--text);
  outline: none; transition: border-color .15s;
}
.input:focus { border-color: var(--primary); }

.label { font-size: 13px; font-weight: 500; color: var(--text); margin-bottom: 4px; display: block; }

textarea.input { resize: vertical; min-height: 80px; }

.select-wrapper { position: relative; }
.select-wrapper select {
  width: 100%; padding: 8px 32px 8px 12px;
  border: 1px solid var(--border); border-radius: 8px;
  font-size: 14px; font-family: inherit;
  background: var(--bg-card); color: var(--text);
  appearance: none; outline: none; cursor: pointer;
}
.select-wrapper::after {
  content: '▾'; position: absolute; right: 10px; top: 50%;
  transform: translateY(-50%); pointer-events: none;
  color: var(--text-muted); font-size: 12px;
}

/* ── EMPTY STATE ── */
.empty-state {
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  min-height: 160px; text-align: center;
  color: var(--text-muted); gap: 8px; padding: 20px;
}
.empty-state svg { opacity: .35; }
.empty-state p { font-size: 14px; }

/* ── TOAST ── */
#toast-container {
  position: fixed; bottom: 20px; right: 20px;
  z-index: 9999; display: flex; flex-direction: column; gap: 8px;
}
/* ── Tour de boas-vindas (spotlight) ───────────────────── */
.bona-tour-overlay { position:fixed; inset:0; z-index:9999; pointer-events:none; }
.bona-tour-spotlight {
  position:fixed; border-radius:10px; pointer-events:none;
  box-shadow:0 0 0 9999px rgba(0,0,0,.6);
  transition:top .25s ease, left .25s ease, width .25s ease, height .25s ease;
}
.bona-tour-tooltip {
  position:fixed; z-index:10000; background:var(--bg-card); border:1px solid var(--border);
  border-radius:var(--radius-lg); box-shadow:0 8px 32px rgba(0,0,0,.25); padding:16px;
  max-width:280px; pointer-events:auto; transition:top .25s ease, left .25s ease;
}
.bona-tour-tooltip .step-count { font-size:11px; font-weight:700; color:var(--primary); text-transform:uppercase; letter-spacing:.05em; margin-bottom:6px; }
.bona-tour-tooltip h4 { font-size:15px; font-weight:700; margin-bottom:6px; }
.bona-tour-tooltip p { font-size:13px; color:var(--text-muted); line-height:1.5; margin-bottom:14px; }
.bona-tour-tooltip .tour-actions { display:flex; justify-content:space-between; align-items:center; gap:10px; }
.bona-tour-tooltip .tour-skip { font-size:12px; color:var(--text-muted); background:none; border:none; cursor:pointer; font-family:inherit; padding:4px; }
.bona-tour-tooltip .tour-next { font-size:13px; font-weight:600; color:#fff; background:var(--primary); border:none; border-radius:8px; padding:8px 16px; cursor:pointer; font-family:inherit; }

.mini-calendar { border:1px solid var(--border); border-radius:var(--radius); padding:12px; }
.mini-cal-header { display:flex; align-items:center; justify-content:space-between; margin-bottom:10px; font-weight:600; font-size:14px; text-transform:capitalize; }
.mini-cal-header button { background:none; border:1px solid var(--border); border-radius:6px; width:28px; height:28px; cursor:pointer; font-size:16px; color:var(--text); font-family:inherit; }
.mini-cal-header button:disabled { opacity:.3; cursor:default; }
.mini-cal-weekdays { display:grid; grid-template-columns:repeat(7,1fr); text-align:center; font-size:11px; color:var(--text-muted); margin-bottom:4px; }
.mini-cal-grid { display:grid; grid-template-columns:repeat(7,1fr); gap:3px; }
.cal-day { aspect-ratio:1; border:none; background:none; border-radius:8px; font-size:13px; cursor:pointer; color:var(--text); font-family:inherit; }
.cal-day:hover:not(:disabled) { background:var(--bg-muted); }
.cal-day.selected { background:var(--primary); color:#fff; font-weight:700; }
.cal-day:disabled { color:var(--text-muted); opacity:.35; cursor:default; text-decoration:line-through; }

.toast {
  display: flex; align-items: flex-start; gap: 10px;
  padding: 12px 14px 12px 12px; border-radius: 10px;
  font-size: 14px; font-weight: 500; color: var(--text);
  background: var(--bg-card); border: 1px solid var(--border);
  border-left: 3px solid var(--primary);
  box-shadow: 0 6px 20px rgba(0,0,0,.12);
  animation: slideIn .2s ease;
  max-width: 320px;
}
.toast svg { flex-shrink: 0; margin-top: 1px; }
.toast-success { border-left-color: var(--green); }
.toast-success svg { color: var(--green); }
.toast-error { border-left-color: var(--destructive); }
.toast-error svg { color: var(--destructive); }
.toast-info { border-left-color: var(--primary); }
.toast-info svg { color: var(--primary); }
@keyframes slideIn {
  from { transform: translateX(20px); opacity: 0; }
  to   { transform: translateX(0); opacity: 1; }
}

/* ── MODAL / OVERLAY ── */
.overlay {
  position: fixed; inset: 0;
  background: rgba(0,0,0,.5);
  z-index: 50; display: flex;
  align-items: center; justify-content: center;
  padding: 16px;
}
.overlay.hidden { display: none; }
.modal {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  max-width: 540px; width: 100%;
  max-height: 90vh; overflow-y: auto;
  box-shadow: 0 20px 60px rgba(0,0,0,.2);
}
.modal-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 16px 20px; border-bottom: 1px solid var(--border);
}
.modal-header h2 { font-size: 18px; font-weight: 700; }
.modal-body { padding: 20px; }
.modal-footer {
  display: flex; justify-content: flex-end; gap: 8px;
  padding: 16px 20px; border-top: 1px solid var(--border);
}

/* ── UTILITÁRIOS ── */
/* Genérica: esconde qualquer elemento. Antes só existia escopada como
   .dropdown-menu.hidden / .overlay.hidden — por isso loading-states e outros
   elementos com class="hidden" via JS não desapareciam de verdade. */
.hidden { display: none !important; }

/* ── SKELETON ── */
.skeleton {
  background: linear-gradient(90deg, var(--bg-muted) 25%, #e9e9e9 50%, var(--bg-muted) 75%);
  background-size: 200% 100%;
  animation: shimmer 1.2s infinite;
  border-radius: 8px;
}
@keyframes shimmer {
  from { background-position: 200% 0; }
  to   { background-position: -200% 0; }
}

/* ── TABLE ── */
table { width: 100%; border-collapse: collapse; }
th, td { text-align: left; padding: 10px 14px; font-size: 14px; }
th { font-size: 12px; font-weight: 600; color: var(--text-muted); border-bottom: 1px solid var(--border); }
tr + tr td { border-top: 1px solid var(--border); }
tr:hover td { background: var(--bg-muted); }

/* ── SWITCH ── */
.switch {
  position: relative; display: inline-block;
  width: 36px; height: 20px; flex-shrink: 0;
}
.switch input { opacity: 0; width: 0; height: 0; }
.switch-track {
  position: absolute; inset: 0;
  background: var(--border); border-radius: 20px;
  transition: background .2s; cursor: pointer;
}
.switch input:checked + .switch-track { background: var(--primary); }
.switch input:disabled + .switch-track { opacity: .5; cursor: not-allowed; }
.switch-track::after {
  content: ''; position: absolute;
  width: 14px; height: 14px; background: #fff;
  border-radius: 50%; top: 3px; left: 3px;
  transition: transform .2s;
}
.switch input:checked + .switch-track::after { transform: translateX(16px); }

/* ── TABS ── */
.tabs-list {
  display: flex; border-bottom: 1px solid var(--border);
  overflow-x: auto; gap: 0;
  scrollbar-width: none;
}
.tabs-list::-webkit-scrollbar { display: none; }
.tab-btn {
  padding: 10px 16px; font-size: 14px; font-weight: 500;
  border: none; border-bottom: 2px solid transparent;
  background: none; cursor: pointer; color: var(--text-muted);
  white-space: nowrap; transition: color .15s, border-color .15s;
  font-family: inherit;
}
.tab-btn.active { color: var(--primary); border-bottom-color: var(--primary); }
.tab-btn:hover:not(.active) { color: var(--text); }
.tab-panel { display: none; padding-top: 16px; }
.tab-panel.active { display: block; }

/* ── PROGRESS BAR ── */
.progress-bar {
  height: 8px; background: var(--bg-muted);
  border-radius: 9999px; overflow: hidden;
}
.progress-fill {
  height: 100%; background: var(--primary);
  border-radius: 9999px; transition: width .3s;
}

/* ── ANIMATIONS ── */
.bounce { animation: bounce 1s infinite; display: inline-block; }
@keyframes bounce {
  0%, 100% { transform: translateY(0); animation-timing-function: cubic-bezier(.8,0,1,1); }
  50% { transform: translateY(-6px); animation-timing-function: cubic-bezier(0,0,.2,1); }
}
.ping {
  position: absolute; inset: 0; border-radius: 50%;
  background: #86efac; opacity: 0;
  animation: ping 1.5s cubic-bezier(0,0,.2,1) infinite;
}
@keyframes ping {
  0% { transform: scale(1); opacity: .75; }
  100% { transform: scale(2); opacity: 0; }
}
.pulse { animation: pulse 1.5s cubic-bezier(.4,0,.6,1) infinite; }
@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: .4; }
}
.spin { animation: spin 1s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ── PAGE HEADER (Ao Vivo, Forno) ── */
.page-header{display:flex;align-items:flex-end;justify-content:space-between;gap:12px;margin-bottom:16px;}
.page-title{display:flex;align-items:center;gap:8px;font-size:24px;font-weight:700;}
.page-subtitle{font-size:14px;color:var(--text-muted);margin-top:2px;}

/* ── STATUS BANNER (base = chapa/verde; forno usa variante âmbar) ── */
.status-banner{display:flex;align-items:center;justify-content:space-between;padding:12px 16px;border-radius:var(--radius-lg);border:1px solid var(--green-border);background:var(--green-light);margin-bottom:16px;cursor:pointer;width:100%;font-family:inherit;transition:all .3s;}
.status-banner.closed{border-color:var(--border);background:var(--bg-muted);}
.status-dot-wrap{position:relative;width:12px;height:12px;display:flex;align-items:center;justify-content:center;}
.status-dot{width:12px;height:12px;border-radius:50%;background:var(--green);}
.status-banner.closed .status-dot{background:#9ca3af;}
.status-banner .ping{background:#86efac;}
.status-banner.closed .ping{display:none;}
.status-text-label{font-size:14px;font-weight:600;color:var(--green-dark);display:flex;align-items:center;gap:10px;}
.status-banner.closed .status-text-label{color:var(--text-muted);}
.close-hint{font-size:12px;color:var(--text-muted);}
body[data-header-sub="Modo Forno"] .status-banner{border-color:#fde68a;background:#fffbeb;}
body[data-header-sub="Modo Forno"] .status-dot{background:#f59e0b;}
body[data-header-sub="Modo Forno"] .status-banner .ping{background:#fcd34d;}
body[data-header-sub="Modo Forno"] .status-text-label{color:#92400e;}
html.dark body[data-header-sub="Modo Forno"] .status-banner{background:#3a2e13;border-color:#78350f;}
html.dark body[data-header-sub="Modo Forno"] .status-text-label{color:#fcd34d;}
html.dark .status-banner{background:#132e1d;border-color:var(--green-dark);}
html.dark .status-text-label{color:#86efac;}

/* ── Badges "ao vivo" (live=chapa / forno) ── */
.live-badge{display:inline-flex;align-items:center;gap:6px;padding:4px 12px;border-radius:9999px;border:1px solid var(--primary-border);background:var(--primary-light);color:var(--primary);font-size:13px;font-weight:500;}
.live-dot{width:8px;height:8px;border-radius:50%;background:var(--primary);}
.forno-badge{display:inline-flex;align-items:center;gap:6px;padding:4px 12px;border-radius:9999px;border:1px solid #fde68a;background:#fffbeb;color:#92400e;font-size:13px;font-weight:500;}
.forno-dot{width:8px;height:8px;border-radius:50%;background:#f59e0b;}
html.dark .forno-badge{background:#3a2e13;border-color:#78350f;color:#fcd34d;}

/* ── Metrics ── */
.metrics-grid{display:grid;grid-template-columns:repeat(4,1fr);gap:12px;margin-bottom:20px;}
.metric-card{background:var(--bg-card);border:1px solid var(--border);border-radius:var(--radius-lg);padding:16px;box-shadow:var(--shadow-sm);}
.metric-value{font-size:22px;font-weight:700;}
.metric-label{font-size:12px;color:var(--text-muted);margin-top:4px;}

/* ── Kanban ── */
.kanban-grid{display:grid;grid-template-columns:repeat(4,1fr);gap:12px;}
.kanban-col{background:#f4f4f4;border-radius:var(--radius-lg);padding:12px;min-height:320px;}
html.dark .kanban-col{background:#1e1e1e;}
.col-header{display:flex;align-items:center;justify-content:space-between;margin-bottom:12px;}
.col-title-group{display:flex;align-items:center;gap:8px;color:var(--text-muted);font-size:14px;font-weight:600;}
.col-count{display:inline-flex;align-items:center;justify-content:center;min-width:22px;height:22px;border-radius:9999px;padding:0 6px;font-size:12px;font-weight:600;background:var(--bg-muted);color:var(--text-muted);}

/* ── Card de pedido (chapa) / encomenda (forno) ── */
.pedido-card,.enc-card{background:var(--bg-card);border:1px solid var(--border);border-radius:var(--radius-lg);padding:16px;margin-bottom:12px;box-shadow:var(--shadow-sm);transition:box-shadow .15s;}
.pedido-card:hover,.enc-card:hover{box-shadow:0 4px 12px rgba(0,0,0,.1);}
.pedido-num,.enc-num{font-size:18px;font-weight:700;color:var(--primary);}
.pedido-client,.enc-client{font-size:13px;color:var(--text-muted);margin-top:2px;}
.pedido-timer{font-family:monospace;font-size:13px;font-weight:700;color:#16a34a;}
.pedido-timer.warn{color:var(--amber);}
.pedido-timer.late{color:var(--destructive);}
.pedido-tags,.enc-tags{display:flex;flex-wrap:wrap;gap:4px;margin-top:8px;}
.enc-date-badge{display:inline-flex;align-items:center;gap:4px;background:#fef3c7;color:#92400e;border-radius:9999px;padding:2px 8px;font-size:12px;font-weight:500;}
html.dark .enc-date-badge{background:#3a2e13;color:#fcd34d;}
.pedido-items,.enc-items{margin-top:10px;font-size:13px;color:var(--text);}
.enc-notes{margin-top:8px;font-size:12px;color:var(--text-muted);background:var(--bg-muted);border-radius:8px;padding:8px;font-style:italic;}
.pedido-total,.enc-total{font-size:14px;font-weight:700;margin-top:8px;}
.pedido-actions,.enc-actions{display:grid;grid-template-columns:1fr 1fr;gap:8px;margin-top:12px;}
.pedido-cancel,.enc-cancel{width:100%;background:none;border:none;font-family:inherit;font-size:12px;color:var(--destructive);cursor:pointer;padding:4px;margin-top:4px;text-align:left;}
.pedido-cancel:hover,.enc-cancel:hover{text-decoration:underline;}

/* ── Sound banner ── */
.sound-banner{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:10px 16px;border-radius:var(--radius-lg);border:1px solid #fde68a;background:#fefce8;margin-bottom:16px;}
.sound-banner p{font-size:14px;color:#92400e;}
.sound-banner-btns{display:flex;gap:8px;flex-shrink:0;}
html.dark .sound-banner{background:#3a2e13;border-color:#78350f;}
html.dark .sound-banner p{color:#fcd34d;}

/* ── Badges de status (modal de pedido/encomenda) — base chapa, forno sobrescreve ── */
.pedido-modal-badge,.enc-modal-badge{padding:4px 10px;border-radius:9999px;font-size:12px;font-weight:600;}
.status-novo{background:#dbeafe;color:#1d4ed8;}
.status-em_preparo{background:#fde68a;color:#78350f;}
.status-pronto,.status-saiu{background:var(--primary-10);color:var(--primary);}
.status-entregue{background:#dcfce7;color:#15803d;}
.status-cancelado,.status-recusado{background:#fee2e2;color:#991b1b;}
body[data-header-sub="Modo Forno"] .status-novo{background:#fef3c7;color:#92400e;}
html.dark .status-novo{background:#1e3a5f;color:#93c5fd;}
html.dark .status-em_preparo{background:#3a2e13;color:#fcd34d;}
html.dark .status-entregue{background:#0f2e1c;color:#86efac;}
html.dark .status-cancelado,html.dark .status-recusado{background:#3f1414;color:#fca5a5;}
html.dark body[data-header-sub="Modo Forno"] .status-novo{background:#3a2e13;color:#fcd34d;}
.history-dot{width:8px;height:8px;border-radius:50%;background:var(--primary);flex-shrink:0;}

@media(max-width:900px){
  .metrics-grid{grid-template-columns:repeat(2,1fr);}
  .kanban-grid{overflow-x:auto;display:flex;gap:12px;padding-bottom:8px;}
  .kanban-col{min-width:280px;flex-shrink:0;}
}
@media(max-width:600px){.metrics-grid{grid-template-columns:repeat(2,1fr);}}

/* ── RESPONSIVE ── */
@media (max-width: 768px) {
  /* No mobile a sidebar vira uma gaveta que desliza por cima do conteúdo —
     antes disso aqui era "display:none" sem nenhum outro jeito de abrir,
     deixando quem estivesse numa página sem sidebar visível (Ao Vivo, etc.)
     preso ali, sem conseguir navegar pra mais nada. */
  .bona-sidebar {
    display: flex;
    position: fixed;
    top: 0; left: 0; bottom: 0;
    width: var(--sidebar-w);
    z-index: 200;
    transform: translateX(-100%);
    transition: transform .25s ease;
    box-shadow: 4px 0 24px rgba(0,0,0,.25);
  }
  .bona-sidebar.open { transform: translateX(0); }

  .sidebar-backdrop { display: none; position: fixed; inset: 0; background: rgba(0,0,0,.5); z-index: 190; }
  .sidebar-backdrop.visible { display: block; }

  .bona-main.sidebar-open,
  .bona-main.sidebar-closed { margin-left: 0; padding-bottom: 80px; }
  .hide-mobile { display: none !important; }
}
@media (min-width: 769px) {
  .hide-desktop { display: none !important; }
}

:root { color-scheme: light; }

/* ── DARK MODE ── */
html.dark {
  color-scheme: dark;
  --bg: #111111;
  --bg-card: #1c1c1c;
  --bg-muted: #262626;
  --border: #2e2e2e;
  --text: #f5f5f5;
  --text-muted: #9ca3af;
}

html.dark .badge-green { background:#0f2e1c; color:#86efac; }
html.dark .badge-amber { background:#3a2e13; color:#fcd34d; }
html.dark .badge-blue { background:#1e3a5f; color:#93c5fd; }
html.dark .badge-red { background:#3f1414; color:#fca5a5; }

/* ── TEMA CALOROSO ── */
html.warm {
  --bg: #fdf6ec;
  --bg-card: #fffaf3;
  --bg-muted: #f5e8d3;
  --border: #e8d3ab;
  --text: #3d2b1a;
  --text-muted: #8a6a48;
  --primary-light: #fde8d3;
  --primary-border: #f3c99a;
}
