* { box-sizing: border-box; }
body { margin: 0; font-family: system-ui, -apple-system, Segoe UI, sans-serif; background: #f8fafc; color: #0f172a; }
a { color: inherit; text-decoration: none; }
.topbar { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 16px 24px; background: #fff; border-bottom: 1px solid #e2e8f0; position: sticky; top: 0; z-index: 10; }
.brand { font-weight: 800; font-size: 20px; margin-right: 12px; }
.topbar nav { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.user { color: #475569; font-size: 14px; }
.container { max-width: 1180px; margin: 0 auto; padding: 24px; }
.footer { text-align: center; color: #64748b; padding: 24px; }
.card { background: #fff; border: 1px solid #e2e8f0; border-radius: 18px; padding: 20px; box-shadow: 0 1px 2px rgba(15,23,42,.04); margin-bottom: 18px; }
.narrow { max-width: 460px; margin: 48px auto; }
.toolbar { display: flex; justify-content: space-between; align-items: center; gap: 16px; margin-bottom: 18px; }
.toolbar.compact { margin-bottom: 12px; }
h1, h2, h3 { margin-top: 0; }
.muted { color: #64748b; }
.form label { display: block; font-weight: 650; color: #334155; margin-bottom: 14px; }
input, textarea, select { width: 100%; margin-top: 6px; border: 1px solid #cbd5e1; border-radius: 12px; padding: 11px 12px; font: inherit; background: #fff; }
textarea { resize: vertical; }
input:focus, textarea:focus { outline: 2px solid #bfdbfe; border-color: #60a5fa; }
.grid { display: grid; gap: 16px; }
.grid.two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid.no-card { margin: 0; }
.full { grid-column: 1 / -1; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; border: 1px solid #cbd5e1; border-radius: 999px; padding: 10px 14px; background: #fff; cursor: pointer; font-weight: 700; font-size: 14px; }
.btn.primary { background: #0f172a; color: #fff; border-color: #0f172a; }
.btn.danger { color: #991b1b; border-color: #fecaca; background: #fff7f7; }
.btn.small { padding: 7px 10px; font-size: 13px; }
.actions { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.table-wrap { overflow-x: auto; }
table { border-collapse: collapse; width: 100%; }
th, td { text-align: left; padding: 12px; border-bottom: 1px solid #e2e8f0; vertical-align: top; }
th { color: #475569; font-size: 13px; background: #f8fafc; }
.pill { display: inline-flex; border-radius: 999px; padding: 4px 9px; font-size: 12px; font-weight: 800; background: #e2e8f0; color: #334155; }
.pill.sent { background: #dcfce7; color: #166534; }
.pill.draft { background: #fef9c3; color: #854d0e; }
.pill.archived { background: #e0e7ff; color: #3730a3; }
.alert { border-radius: 12px; padding: 12px; margin-bottom: 14px; background: #eff6ff; border: 1px solid #bfdbfe; }
.alert.error { background: #fef2f2; border-color: #fecaca; color: #991b1b; }
.agenda-list { display: grid; gap: 16px; }
.agenda-row { border: 1px solid #e2e8f0; border-radius: 16px; padding: 16px; background: #f8fafc; }
.protocol-item { border-top: 1px solid #e2e8f0; padding-top: 14px; margin-top: 14px; }
.meta-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-bottom: 14px; }
@media (max-width: 760px) {
  .topbar, .toolbar { flex-direction: column; align-items: flex-start; }
  .grid.two, .meta-grid { grid-template-columns: 1fr; }
  .container { padding: 14px; }
}
