* { box-sizing: border-box; }
body {
  margin: 0; font-family: system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  background: #f1f5f9; color: #1e293b;
}
header.topbar {
  display: flex; align-items: center; justify-content: space-between;
  background: #1e293b; color: #fff; padding: 0.75rem 1.25rem;
}
header.topbar h1 { font-size: 1rem; margin: 0; }
header.topbar .user-info { font-size: 0.85rem; display: flex; align-items: center; gap: 0.75rem; }
header.topbar button {
  background: #334155; color: #fff; border: none; padding: 0.4rem 0.8rem;
  border-radius: 6px; cursor: pointer; font-size: 0.8rem;
}
header.topbar button:hover { background: #475569; }

.layout { display: flex; min-height: calc(100vh - 52px); }
.sidebar {
  width: 220px; background: #fff; border-right: 1px solid #e2e8f0; padding: 1rem 0;
  overflow-y: auto;
}
.sidebar button.bab-item {
  display: block; width: 100%; text-align: left; padding: 0.55rem 1rem; border: none;
  background: none; cursor: pointer; font-size: 0.85rem; color: #334155;
}
.sidebar button.bab-item:hover { background: #f1f5f9; }
.sidebar button.bab-item.active { background: #dbeafe; color: #1d4ed8; font-weight: 600; }

.main { flex: 1; padding: 1.25rem; overflow-y: auto; }
.standar-block { background: #fff; border-radius: 10px; padding: 1rem 1.25rem; margin-bottom: 1rem; border: 1px solid #e2e8f0; }
.standar-block h3 { margin: 0 0 0.35rem; font-size: 0.95rem; color: #0f172a; }
.standar-block .standar-text { font-size: 0.85rem; color: #475569; margin-bottom: 0.75rem; }

.elemen-row {
  display: flex; align-items: center; justify-content: space-between; gap: 0.75rem;
  padding: 0.55rem 0.6rem; border-radius: 8px; cursor: pointer; font-size: 0.85rem;
}
.elemen-row:hover { background: #f8fafc; }
.elemen-row .badge {
  font-size: 0.7rem; padding: 0.15rem 0.5rem; border-radius: 999px; font-weight: 600; white-space: nowrap;
}
.badge.status-belum { background: #fee2e2; color: #b91c1c; }
.badge.status-proses { background: #fef9c3; color: #a16207; }
.badge.status-lengkap { background: #dcfce7; color: #15803d; }

.modal-backdrop {
  position: fixed; inset: 0; background: rgba(15,23,42,0.5); display: flex;
  align-items: flex-start; justify-content: center; padding: 2rem 1rem; overflow-y: auto; z-index: 50;
}
.modal { background: #fff; border-radius: 12px; padding: 1.5rem; max-width: 720px; width: 100%; }
.modal h2 { margin-top: 0; font-size: 1.05rem; }
.modal .close-btn { float: right; background: none; border: none; font-size: 1.2rem; cursor: pointer; color: #64748b; }
.modal label { display: block; font-size: 0.8rem; color: #475569; margin: 0.75rem 0 0.25rem; }
.modal textarea, .modal select, .modal input[type=text] {
  width: 100%; padding: 0.5rem; border: 1px solid #cbd5e1; border-radius: 6px; font-size: 0.85rem;
}
.file-list { list-style: none; padding: 0; margin: 0.5rem 0; }
.file-list li {
  display: flex; align-items: center; justify-content: space-between; gap: 0.5rem;
  padding: 0.4rem 0.5rem; border: 1px solid #e2e8f0; border-radius: 6px; margin-bottom: 0.4rem; font-size: 0.8rem;
}
.file-list .file-actions button {
  border: none; background: #e2e8f0; padding: 0.25rem 0.5rem; border-radius: 4px; cursor: pointer; font-size: 0.72rem; margin-left: 0.25rem;
}
.file-list .file-actions button.verify { background: #dcfce7; color: #15803d; }
.file-list .file-actions button.reject { background: #fee2e2; color: #b91c1c; }
.file-list .file-actions button.delete { background: #fef2f2; color: #ef4444; }

.discussion-list { max-height: 220px; overflow-y: auto; margin: 0.5rem 0; }
.discussion-item { padding: 0.5rem; border-bottom: 1px solid #f1f5f9; font-size: 0.8rem; }
.discussion-item .meta { color: #94a3b8; font-size: 0.7rem; margin-bottom: 0.15rem; }

.primary-btn {
  background: #2563eb; color: #fff; border: none; padding: 0.5rem 1rem; border-radius: 6px;
  cursor: pointer; font-size: 0.82rem; margin-top: 0.5rem;
}
.primary-btn:disabled { opacity: 0.6; cursor: not-allowed; }
.small-muted { font-size: 0.72rem; color: #94a3b8; }
