/* ============================================
   MARCENARIA PRO - Sistema de Gestão
   CSS Principal
   ============================================ */

:root {
  --primary: #8B4513;
  --primary-dark: #5C2D0A;
  --primary-light: #C4742E;
  --primary-xlight: #F5E6D3;
  --secondary: #2C3E50;
  --secondary-light: #34495E;
  --accent: #E67E22;
  --accent-light: #F39C12;
  --success: #27AE60;
  --success-light: #2ECC71;
  --warning: #F39C12;
  --danger: #E74C3C;
  --danger-light: #C0392B;
  --info: #2980B9;
  --info-light: #3498DB;
  --bg: #F5F1EC;
  --bg-card: #FFFFFF;
  --text-primary: #2C3E50;
  --text-secondary: #7F8C8D;
  --text-muted: #95A5A6;
  --border: #E0D5C9;
  --border-light: #F0EBE4;
  --sidebar-width: 260px;
  --header-height: 64px;
  --radius: 10px;
  --radius-sm: 6px;
  --radius-lg: 16px;
  --shadow: 0 2px 8px rgba(139,69,19,0.10);
  --shadow-md: 0 4px 16px rgba(139,69,19,0.14);
  --shadow-lg: 0 8px 32px rgba(139,69,19,0.18);
  --transition: 0.2s ease;
}

/* ============ RESET & BASE ============ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 15px; scroll-behavior: smooth; }
body {
  font-family: 'Inter', 'Segoe UI', system-ui, sans-serif;
  background: var(--bg);
  color: var(--text-primary);
  min-height: 100vh;
  overflow-x: hidden;
}
a { color: var(--primary); text-decoration: none; }
a:hover { color: var(--primary-dark); }
img { max-width: 100%; }
button { cursor: pointer; font-family: inherit; }
input, select, textarea { font-family: inherit; }

/* ============ SCROLLBAR ============ */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb { background: var(--border); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: var(--primary-light); }

/* ============ LAYOUT ============ */
#app { display: flex; min-height: 100vh; }

/* ============ SIDEBAR ============ */
#sidebar {
  width: var(--sidebar-width);
  background: var(--secondary);
  min-height: 100vh;
  position: fixed;
  left: 0; top: 0;
  display: flex;
  flex-direction: column;
  z-index: 100;
  transition: transform var(--transition);
  box-shadow: 3px 0 12px rgba(0,0,0,0.15);
}

.sidebar-logo {
  padding: 20px 24px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
  display: flex;
  align-items: center;
  gap: 12px;
  background: var(--primary-dark);
}
.sidebar-logo .logo-icon {
  width: 42px; height: 42px;
  background: var(--primary);
  border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  font-size: 20px;
}
.sidebar-logo .logo-text {
  color: white;
  font-size: 1.1rem;
  font-weight: 700;
  line-height: 1.2;
}
.sidebar-logo .logo-sub {
  color: rgba(255,255,255,0.5);
  font-size: 0.72rem;
  font-weight: 400;
}

.sidebar-nav {
  flex: 1;
  padding: 16px 0;
  overflow-y: auto;
}

.nav-section-title {
  color: rgba(255,255,255,0.35);
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 12px 24px 6px;
  margin-top: 4px;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 11px 24px;
  color: rgba(255,255,255,0.7);
  font-size: 0.9rem;
  font-weight: 500;
  cursor: pointer;
  transition: all var(--transition);
  border-left: 3px solid transparent;
  margin: 1px 0;
}
.nav-item:hover {
  background: rgba(255,255,255,0.07);
  color: white;
}
.nav-item.active {
  background: rgba(139,69,19,0.25);
  color: white;
  border-left-color: var(--primary-light);
}
.nav-item .nav-icon { font-size: 1rem; width: 20px; text-align: center; opacity: 0.85; }
.nav-item .nav-badge {
  margin-left: auto;
  background: var(--danger);
  color: white;
  font-size: 0.7rem;
  padding: 1px 7px;
  border-radius: 10px;
  font-weight: 600;
}

.sidebar-footer {
  padding: 16px 24px;
  border-top: 1px solid rgba(255,255,255,0.08);
  color: rgba(255,255,255,0.4);
  font-size: 0.75rem;
}

/* ============ MAIN CONTENT ============ */
#main-content {
  margin-left: var(--sidebar-width);
  flex: 1;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

/* ============ TOPBAR ============ */
#topbar {
  height: var(--header-height);
  background: white;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  padding: 0 28px;
  gap: 16px;
  position: sticky;
  top: 0;
  z-index: 50;
  box-shadow: 0 1px 4px rgba(0,0,0,0.06);
}
.topbar-title {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text-primary);
  flex: 1;
}
.topbar-actions { display: flex; align-items: center; gap: 10px; }
.topbar-date {
  font-size: 0.82rem;
  color: var(--text-secondary);
  background: var(--bg);
  padding: 6px 14px;
  border-radius: 20px;
}

/* ============ PAGE CONTENT ============ */
#page-content {
  flex: 1;
  padding: 28px;
  overflow-y: auto;
}

/* ============ BUTTONS ============ */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 9px 18px;
  border-radius: var(--radius-sm);
  border: none;
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition);
  white-space: nowrap;
}
.btn:active { transform: scale(0.97); }
.btn-primary { background: var(--primary); color: white; }
.btn-primary:hover { background: var(--primary-dark); box-shadow: var(--shadow); }
.btn-secondary { background: var(--secondary); color: white; }
.btn-secondary:hover { background: var(--secondary-light); }
.btn-success { background: var(--success); color: white; }
.btn-success:hover { background: var(--success-light); }
.btn-warning { background: var(--warning); color: white; }
.btn-warning:hover { background: var(--accent-light); }
.btn-danger { background: var(--danger); color: white; }
.btn-danger:hover { background: var(--danger-light); }
.btn-info { background: var(--info); color: white; }
.btn-info:hover { background: var(--info-light); }
.btn-outline {
  background: transparent;
  border: 2px solid var(--primary);
  color: var(--primary);
}
.btn-outline:hover { background: var(--primary); color: white; }
.btn-ghost {
  background: transparent;
  color: var(--text-secondary);
  border: 1px solid var(--border);
}
.btn-ghost:hover { background: var(--bg); color: var(--text-primary); }
.btn-sm { padding: 5px 12px; font-size: 0.8rem; }
.btn-lg { padding: 12px 24px; font-size: 1rem; }
.btn-icon { padding: 8px; border-radius: var(--radius-sm); }
.btn-full { width: 100%; justify-content: center; }

/* ============ CARDS ============ */
.card {
  background: var(--bg-card);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  border: 1px solid var(--border-light);
  padding: 24px;
}
.card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
}
.card-title {
  font-size: 1rem;
  font-weight: 700;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: 8px;
}
.card-title .card-icon {
  width: 32px; height: 32px;
  border-radius: 8px;
  display: flex; align-items: center; justify-content: center;
  font-size: 15px;
  background: var(--primary-xlight);
  color: var(--primary);
}

/* ============ STAT CARDS ============ */
.stat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 20px;
  margin-bottom: 28px;
}
.stat-card {
  background: white;
  border-radius: var(--radius);
  padding: 22px;
  box-shadow: var(--shadow);
  border: 1px solid var(--border-light);
  display: flex;
  align-items: center;
  gap: 16px;
  transition: transform var(--transition), box-shadow var(--transition);
}
.stat-card:hover { transform: translateY(-2px); box-shadow: var(--shadow-md); }
.stat-icon {
  width: 52px; height: 52px;
  border-radius: 14px;
  display: flex; align-items: center; justify-content: center;
  font-size: 22px;
  flex-shrink: 0;
}
.stat-icon.brown { background: var(--primary-xlight); color: var(--primary); }
.stat-icon.blue { background: #E3F2FD; color: #1976D2; }
.stat-icon.green { background: #E8F5E9; color: #388E3C; }
.stat-icon.orange { background: #FFF3E0; color: #F57C00; }
.stat-icon.red { background: #FFEBEE; color: #D32F2F; }
.stat-icon.purple { background: #F3E5F5; color: #7B1FA2; }
.stat-info .stat-label { font-size: 0.78rem; color: var(--text-secondary); font-weight: 500; }
.stat-info .stat-value { font-size: 1.7rem; font-weight: 800; color: var(--text-primary); line-height: 1.2; margin: 2px 0; }
.stat-info .stat-sub { font-size: 0.75rem; color: var(--text-muted); }

/* ============ TABLES ============ */
.table-wrapper {
  overflow-x: auto;
  border-radius: var(--radius);
}
table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.875rem;
}
thead th {
  background: var(--bg);
  color: var(--text-secondary);
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 12px 16px;
  text-align: left;
  white-space: nowrap;
  border-bottom: 2px solid var(--border);
}
tbody tr {
  border-bottom: 1px solid var(--border-light);
  transition: background var(--transition);
}
tbody tr:last-child { border-bottom: none; }
tbody tr:hover { background: var(--bg); }
tbody td {
  padding: 13px 16px;
  color: var(--text-primary);
  vertical-align: middle;
}
.td-actions { display: flex; gap: 6px; }

/* ============ BADGES / PILLS ============ */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 10px;
  border-radius: 20px;
  font-size: 0.72rem;
  font-weight: 700;
  white-space: nowrap;
}
.badge-success { background: #E8F5E9; color: #2E7D32; }
.badge-warning { background: #FFF8E1; color: #F57F17; }
.badge-danger { background: #FFEBEE; color: #C62828; }
.badge-info { background: #E3F2FD; color: #1565C0; }
.badge-secondary { background: #ECEFF1; color: #546E7A; }
.badge-primary { background: var(--primary-xlight); color: var(--primary-dark); }
.badge-orange { background: #FFF3E0; color: #E65100; }
.badge-purple { background: #F3E5F5; color: #6A1B9A; }

/* ============ FORMS ============ */
.form-group {
  margin-bottom: 18px;
}
.form-label {
  display: block;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 6px;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}
.form-control {
  width: 100%;
  padding: 10px 14px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
  color: var(--text-primary);
  background: white;
  transition: border-color var(--transition), box-shadow var(--transition);
  outline: none;
}
.form-control:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(139,69,19,0.1);
}
.form-control::placeholder { color: var(--text-muted); }
textarea.form-control { resize: vertical; min-height: 90px; }
.form-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
}
.form-grid-2 { grid-template-columns: 1fr 1fr; }
.form-grid-3 { grid-template-columns: 1fr 1fr 1fr; }

/* ============ MODAL ============ */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.55);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  backdrop-filter: blur(3px);
  animation: fadeIn 0.15s ease;
}
.modal {
  background: white;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  width: 100%;
  max-width: 640px;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  animation: slideUp 0.2s ease;
}
.modal-lg { max-width: 860px; }
.modal-sm { max-width: 400px; }
.modal-header {
  padding: 22px 28px 18px;
  border-bottom: 1px solid var(--border-light);
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.modal-title { font-size: 1.1rem; font-weight: 700; color: var(--text-primary); }
.modal-close {
  width: 32px; height: 32px;
  border-radius: 8px;
  border: none;
  background: var(--bg);
  color: var(--text-secondary);
  font-size: 1.1rem;
  cursor: pointer;
  transition: all var(--transition);
  display: flex; align-items: center; justify-content: center;
}
.modal-close:hover { background: var(--danger); color: white; }
.modal-body { padding: 24px 28px; overflow-y: auto; flex: 1; }
.modal-footer {
  padding: 18px 28px;
  border-top: 1px solid var(--border-light);
  display: flex;
  justify-content: flex-end;
  gap: 10px;
}

/* ============ SEARCH & FILTER BAR ============ */
.filter-bar {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 20px;
  flex-wrap: wrap;
}
.search-input {
  flex: 1;
  min-width: 200px;
  display: flex;
  align-items: center;
  gap: 8px;
  background: white;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 8px 14px;
  transition: border-color var(--transition);
}
.search-input:focus-within { border-color: var(--primary); }
.search-input input {
  border: none;
  outline: none;
  font-size: 0.9rem;
  flex: 1;
  color: var(--text-primary);
  background: transparent;
}
.search-input .search-icon { color: var(--text-muted); font-size: 0.9rem; }

/* ============ KANBAN BOARD ============ */
.kanban-board {
  display: flex;
  gap: 16px;
  overflow-x: auto;
  padding-bottom: 16px;
}
.kanban-col {
  min-width: 260px;
  max-width: 280px;
  background: var(--bg);
  border-radius: var(--radius);
  padding: 14px;
  border: 1px solid var(--border);
}
.kanban-col-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
  padding-bottom: 10px;
  border-bottom: 2px solid var(--border);
}
.kanban-col-title {
  font-size: 0.82rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.kanban-count {
  background: var(--border);
  color: var(--text-secondary);
  font-size: 0.72rem;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 10px;
}
.kanban-card {
  background: white;
  border-radius: var(--radius-sm);
  padding: 14px;
  margin-bottom: 10px;
  box-shadow: var(--shadow);
  border: 1px solid var(--border-light);
  cursor: pointer;
  transition: all var(--transition);
  border-left: 4px solid var(--border);
}
.kanban-card:hover { transform: translateY(-1px); box-shadow: var(--shadow-md); }
.kanban-card.priority-alta { border-left-color: var(--danger); }
.kanban-card.priority-urgente { border-left-color: #9B59B6; }
.kanban-card.priority-normal { border-left-color: var(--info); }
.kanban-card.priority-baixa { border-left-color: var(--success); }
.kanban-card-title { font-size: 0.88rem; font-weight: 700; margin-bottom: 4px; }
.kanban-card-sub { font-size: 0.78rem; color: var(--text-secondary); margin-bottom: 10px; }
.kanban-card-meta { display: flex; align-items: center; justify-content: space-between; }

/* ============ TIMELINE / PONTO ============ */
.ponto-display {
  text-align: center;
  padding: 40px 20px;
}
.ponto-clock {
  font-size: 4rem;
  font-weight: 800;
  color: var(--primary);
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.02em;
  line-height: 1;
  margin-bottom: 8px;
}
.ponto-date {
  font-size: 1rem;
  color: var(--text-secondary);
  margin-bottom: 32px;
}
.ponto-func-card {
  background: var(--primary-xlight);
  border-radius: var(--radius);
  padding: 20px;
  margin: 20px 0;
  border: 2px solid var(--primary);
  text-align: center;
}
.ponto-func-name { font-size: 1.4rem; font-weight: 800; color: var(--primary-dark); }
.ponto-func-cargo { font-size: 0.88rem; color: var(--primary); margin-top: 4px; }

/* ============ PIN PAD ============ */
.pin-display {
  background: var(--bg);
  border-radius: var(--radius-sm);
  padding: 14px;
  text-align: center;
  font-size: 1.6rem;
  font-weight: 800;
  letter-spacing: 0.3em;
  margin-bottom: 16px;
  border: 1.5px solid var(--border);
  color: var(--text-primary);
  min-height: 54px;
}
.pin-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  max-width: 260px;
  margin: 0 auto;
}
.pin-btn {
  padding: 16px;
  border-radius: var(--radius-sm);
  border: 1.5px solid var(--border);
  background: white;
  font-size: 1.2rem;
  font-weight: 700;
  cursor: pointer;
  transition: all var(--transition);
  box-shadow: var(--shadow);
}
.pin-btn:hover { background: var(--primary); color: white; border-color: var(--primary); }
.pin-btn:active { transform: scale(0.95); }
.pin-btn.danger { border-color: var(--danger); color: var(--danger); }
.pin-btn.danger:hover { background: var(--danger); color: white; }
.pin-btn.confirm { border-color: var(--success); color: var(--success); background: #E8F5E9; }
.pin-btn.confirm:hover { background: var(--success); color: white; }

/* ============ PROGRESS BARS ============ */
.progress-bar {
  background: var(--border);
  border-radius: 20px;
  height: 8px;
  overflow: hidden;
}
.progress-fill {
  height: 100%;
  border-radius: 20px;
  background: var(--primary);
  transition: width 0.5s ease;
}
.progress-fill.success { background: var(--success); }
.progress-fill.warning { background: var(--warning); }
.progress-fill.danger { background: var(--danger); }
.progress-fill.info { background: var(--info); }

/* ============ ALERTS ============ */
.alert {
  padding: 14px 18px;
  border-radius: var(--radius-sm);
  font-size: 0.88rem;
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 16px;
  border-left: 4px solid;
}
.alert-success { background: #E8F5E9; color: #2E7D32; border-color: var(--success); }
.alert-warning { background: #FFF8E1; color: #F57F17; border-color: var(--warning); }
.alert-danger { background: #FFEBEE; color: #C62828; border-color: var(--danger); }
.alert-info { background: #E3F2FD; color: #1565C0; border-color: var(--info); }

/* ============ TOAST NOTIFICATIONS ============ */
#toast-container {
  position: fixed;
  top: 24px;
  right: 24px;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 10px;
  pointer-events: none;
}
.toast {
  background: white;
  border-radius: var(--radius);
  padding: 14px 20px;
  box-shadow: var(--shadow-lg);
  border-left: 4px solid var(--primary);
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.88rem;
  font-weight: 500;
  max-width: 360px;
  animation: slideInRight 0.3s ease;
  pointer-events: all;
}
.toast.success { border-color: var(--success); }
.toast.error { border-color: var(--danger); }
.toast.warning { border-color: var(--warning); }
.toast.info { border-color: var(--info); }
.toast-icon { font-size: 1.1rem; }
.toast.success .toast-icon { color: var(--success); }
.toast.error .toast-icon { color: var(--danger); }
.toast.warning .toast-icon { color: var(--warning); }
.toast.info .toast-icon { color: var(--info); }

/* ============ EMPTY STATE ============ */
.empty-state {
  text-align: center;
  padding: 60px 20px;
  color: var(--text-muted);
}
.empty-state .empty-icon { font-size: 3.5rem; margin-bottom: 16px; opacity: 0.4; }
.empty-state .empty-title { font-size: 1.1rem; font-weight: 700; color: var(--text-secondary); margin-bottom: 8px; }
.empty-state .empty-sub { font-size: 0.88rem; margin-bottom: 20px; }

/* ============ LOADING ============ */
.spinner {
  width: 36px; height: 36px;
  border: 3px solid var(--border);
  border-top-color: var(--primary);
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
  margin: 40px auto;
}
.loading-overlay {
  position: absolute;
  inset: 0;
  background: rgba(255,255,255,0.8);
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius);
  z-index: 10;
}

/* ============ TABS ============ */
.tabs {
  display: flex;
  gap: 4px;
  border-bottom: 2px solid var(--border);
  margin-bottom: 24px;
}
.tab-btn {
  padding: 10px 20px;
  border: none;
  background: transparent;
  color: var(--text-secondary);
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  border-bottom: 2px solid transparent;
  margin-bottom: -2px;
  transition: all var(--transition);
  border-radius: var(--radius-sm) var(--radius-sm) 0 0;
}
.tab-btn:hover { color: var(--primary); background: var(--primary-xlight); }
.tab-btn.active { color: var(--primary); border-bottom-color: var(--primary); }

/* ============ CHART CONTAINERS ============ */
.chart-container {
  position: relative;
  height: 280px;
}

/* ============ ANIMATIONS ============ */
@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}
@keyframes slideUp {
  from { transform: translateY(30px); opacity: 0; }
  to { transform: translateY(0); opacity: 1; }
}
@keyframes slideInRight {
  from { transform: translateX(40px); opacity: 0; }
  to { transform: translateX(0); opacity: 1; }
}
@keyframes spin {
  to { transform: rotate(360deg); }
}
@keyframes fadeOut {
  from { opacity: 1; transform: translateX(0); }
  to { opacity: 0; transform: translateX(30px); }
}

/* ============ PAGE HEADER ============ */
.page-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 24px;
  flex-wrap: wrap;
  gap: 12px;
}
.page-header-info .page-title {
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--text-primary);
  margin-bottom: 2px;
}
.page-header-info .page-subtitle {
  font-size: 0.85rem;
  color: var(--text-secondary);
}
.page-header-actions { display: flex; gap: 10px; flex-wrap: wrap; }

/* ============ GRID LAYOUTS ============ */
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.grid-3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 20px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.col-span-2 { grid-column: span 2; }
.col-span-3 { grid-column: span 3; }

/* ============ MOBILE HAMBURGER ============ */
#mobile-toggle {
  display: none;
  background: none;
  border: none;
  font-size: 1.4rem;
  cursor: pointer;
  color: var(--text-primary);
}

/* ============ MOBILE OVERLAY ============ */
#sidebar-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.5);
  z-index: 99;
}

/* ============ RESPONSIVE ============ */
@media (max-width: 1024px) {
  .grid-4 { grid-template-columns: 1fr 1fr; }
  .grid-3 { grid-template-columns: 1fr 1fr; }
  .col-span-3 { grid-column: span 2; }
}

@media (max-width: 768px) {
  :root { --sidebar-width: 260px; }
  #sidebar {
    transform: translateX(-100%);
  }
  #sidebar.open {
    transform: translateX(0);
  }
  #sidebar-overlay.show { display: block; }
  #main-content { margin-left: 0; }
  #mobile-toggle { display: flex; }
  #page-content { padding: 16px; }
  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
  .col-span-2, .col-span-3 { grid-column: span 1; }
  .stat-grid { grid-template-columns: 1fr 1fr; }
  .form-grid-2, .form-grid-3 { grid-template-columns: 1fr; }
  .kanban-board { padding-bottom: 20px; }
  .ponto-clock { font-size: 2.8rem; }
}

@media (max-width: 480px) {
  .stat-grid { grid-template-columns: 1fr; }
  .topbar-date { display: none; }
}

/* ============ MISC ============ */
.text-right { text-align: right; }
.text-center { text-align: center; }
.text-muted { color: var(--text-muted); }
.text-secondary { color: var(--text-secondary); }
.text-primary-color { color: var(--primary); }
.text-success { color: var(--success); }
.text-danger { color: var(--danger); }
.text-warning { color: var(--warning); }
.font-bold { font-weight: 700; }
.font-extrabold { font-weight: 800; }
.mt-1 { margin-top: 8px; }
.mt-2 { margin-top: 16px; }
.mt-3 { margin-top: 24px; }
.mb-1 { margin-bottom: 8px; }
.mb-2 { margin-bottom: 16px; }
.mb-3 { margin-bottom: 24px; }
.gap-1 { gap: 8px; }
.gap-2 { gap: 16px; }
.d-flex { display: flex; }
.align-center { align-items: center; }
.justify-between { justify-content: space-between; }
.flex-wrap { flex-wrap: wrap; }
.w-full { width: 100%; }
.hidden { display: none !important; }
hr.divider { border: none; border-top: 1px solid var(--border-light); margin: 20px 0; }

/* Estoque warning */
.estoque-baixo { color: var(--danger); font-weight: 700; }
.estoque-ok { color: var(--success); }

/* Sidebar mobile menu toggle animation */
.hamburger-icon span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--text-primary);
  margin: 5px 0;
  border-radius: 2px;
  transition: all var(--transition);
}
