/* Base */
* { box-sizing: border-box; }
body { margin: 0; font-family: system-ui, -apple-system, Segoe UI, Roboto, Arial; background: #0f172a; color: #e2e8f0; }
.container { max-width: 1100px; margin: 0 auto; padding: 16px; }
.hidden { display: none; }

/* Header */
.header { display: flex; align-items: center; justify-content: space-between; padding: 12px 0; }
.logo { display: flex; align-items: center; gap: 12px; }
.logo i { font-size: 26px; color: #22c55e; }
.logo h1 { font-size: 20px; margin: 0; }
.header-actions .btn { margin-left: 8px; }

/* Cards */
.card { background: #0b1220; border: 1px solid #1e293b; border-radius: 12px; padding: 16px; margin-top: 16px; }
.card h2 { margin: 0 0 12px; font-size: 18px; }

/* Form */
.form-grid { display: grid; grid-template-columns: 1fr; gap: 12px; }
.form-row { display: grid; grid-template-columns: 140px 1fr; align-items: center; gap: 10px; }
.form-row input { width: 100%; padding: 10px; border-radius: 8px; border: 1px solid #334155; background: #0f172a; color: #e2e8f0; }
.error { color: #ef4444; font-weight: 600; }

/* Topbar */
.topbar { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.btn-group .btn { margin-left: 8px; }

/* Stats */
.stats-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-bottom: 12px; }
.stat { background: #0f172a; border: 1px solid #334155; border-radius: 10px; padding: 10px; display: flex; align-items: center; justify-content: space-between; }


/* Table */
.table { width: 100%; border-collapse: collapse; table-layout: fixed; }
.table th, .table td { border: 1px solid #334155; padding: 8px; text-align: left; font-size: clamp(12px, 1.6vw, 14px); }

/* Filters */
.filters-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.filter .btn { margin-right: 8px; }

/* Buttons */
.btn { display: inline-flex; align-items: center; gap: 8px; padding: 12px; border-radius: 8px; border: 1px solid transparent; cursor: pointer; font-weight: 600; justify-content: center; }
.btn-primary { background: #22c55e; color: #052e1a; }
.btn-primary:hover { background: #16a34a; }
.btn-secondary { background: #64748b; color: #0b1220; }
.btn-danger { background: #ef4444; color: #0b1220; }

/* Icon buttons inside tables */
.icon-button { display: inline-flex; align-items: center; justify-content: center; width: 32px; height: 32px; border-radius: 8px; border: 1px solid #334155; background: transparent; color: #e2e8f0; cursor: pointer; }
.icon-button:hover { background: #1e293b; }
.icon-button i { font-size: 14px; }
.table td .icon-button { margin-right: 6px; }

/* Table layout enhancements */
.table td { vertical-align: middle; }
.table-wrap { overflow-x: auto; overflow-y: auto; max-height: 65vh; }
.table thead th { position: sticky; top: 0; background: #0b1220; z-index: 2; }
.table td:last-child { white-space: normal; display: flex; flex-wrap: wrap; gap: 6px; }

/* Responsive */
@media (max-width: 800px) {
  .form-row { grid-template-columns: 1fr; }
  .stats-grid { grid-template-columns: 1fr; }
  .filters-grid { grid-template-columns: 1fr 1fr; }
}


/* Modal */
.modal { position: fixed; inset: 0; background: rgba(2, 6, 23, 0.6); display: flex; align-items: center; justify-content: center; z-index: 1000; }
.modal.hidden { display: none; }
.modal-content { background: #0b1220; border: 1px solid #1e293b; border-radius: 12px; padding: 16px; width: 100%; max-width: 520px; }
.modal-actions { display: flex; gap: 8px; justify-content: flex-end; margin-top: 12px; }


/* Avatares */
.avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 1px solid #334155; /* slate-700 */
  background: #0f172a; /* slate-900 */
}
.avatar-cell { width: 48px; }
/* Maior preview no modal se quiser usar */
.avatar.preview { width: 64px; height: 64px; }

/* Coluna Aprovado com cores semânticas */
/* Estilo moderno da tabela */
.table.modern { border-collapse: separate; border-spacing: 0; }
.table.modern thead th { text-transform: uppercase; letter-spacing: 0.02em; font-weight: 700; background: #0b1220; }
.table.modern th, .table.modern td { border: 1px solid transparent; border-bottom-color: #1e293b; }
.table.modern tbody tr:nth-child(even) { background: #0f172a; }
.table.modern tbody tr:hover { background: #121a2a; }
.table .num { text-align: right; }
.table .center { text-align: center; }

/* Chips de estado */
.chip { display: inline-flex; align-items: center; padding: 2px 8px; border-radius: 999px; font-weight: 600; font-size: 12px; border: 1px solid #334155; }
.chip-success { background: #052e1a; color: #22c55e; border-color: #16a34a; }
.chip-danger { background: #1e0b0b; color: #ef4444; border-color: #dc2626; }

/* Ícones de ação mais discretos */
.icon-button.approve { color: #22c55e; border-color: #16a34a; }
.icon-button.reject { color: #ef4444; border-color: #dc2626; }
.icon-button.edit { color: #94a3b8; }
.icon-button.delete { color: #ef4444; }

/* Embrulho com sombra suave */
.table-wrap { overflow-x: auto; overflow-y: auto; max-height: 65vh; border: 1px solid #1e293b; border-radius: 12px; box-shadow: 0 6px 16px rgba(2,6,23,0.35); }
.table thead th { position: sticky; top: 0; background: #0b1220; z-index: 2; }