/* Minimal admin stylesheet — keeps the same look-and-feel hierarchy as the
   Thymeleaf templates without the Tailwind toolchain. */
* { box-sizing: border-box; }
body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  background: #f6f7fb;
  color: #1f2937;
}
body.public { padding: 4rem; max-width: 720px; margin: 0 auto; }

.topbar {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  padding: 0 1.5rem;
  height: 56px;
  background: #111827;
  color: #f9fafb;
  position: sticky;
  top: 0;
  z-index: 10;
}
.topbar .logo { color: #f9fafb; font-weight: 600; text-decoration: none; }
.topbar .project-selector { margin-left: auto; }
.topbar .user { color: #9ca3af; }
.topbar .logout { color: #93c5fd; margin-left: 1rem; }

.sidenav {
  position: fixed;
  top: 56px;
  left: 0;
  width: 200px;
  bottom: 0;
  background: #ffffff;
  border-right: 1px solid #e5e7eb;
  padding: 1rem 0;
  display: flex;
  flex-direction: column;
}
.sidenav a {
  padding: 0.5rem 1.5rem;
  color: #374151;
  text-decoration: none;
}
.sidenav a:hover, .sidenav a.active {
  background: #eef2ff;
  color: #4338ca;
}

main {
  margin-left: 200px;
  padding: 1.5rem 2rem;
}

h1 { font-size: 1.5rem; margin-top: 0; }
h2 { font-size: 1.15rem; margin-top: 1.5rem; }

.flash { padding: 0.75rem 1rem; border-radius: 6px; margin-bottom: 1rem; }
.flash.success { background: #dcfce7; color: #14532d; }
.flash.error { background: #fee2e2; color: #7f1d1d; }
.note { color: #6b7280; }
.muted { color: #9ca3af; }

table.data { width: 100%; border-collapse: collapse; background: white; border-radius: 6px; overflow: hidden; }
table.data th, table.data td { padding: 0.6rem 0.8rem; text-align: left; border-bottom: 1px solid #e5e7eb; }
table.data th { background: #f3f4f6; font-weight: 600; }

form.form { display: flex; flex-direction: column; gap: 0.6rem; max-width: 480px; }
form.form label { display: flex; flex-direction: column; gap: 0.25rem; }
form.form input, form.form select, form.form textarea { padding: 0.4rem 0.6rem; border: 1px solid #d1d5db; border-radius: 4px; font: inherit; }
form.inline { display: inline-block; margin-right: 0.5rem; }
form.danger { margin-top: 1.5rem; }
form.danger button { background: #dc2626; color: white; border: none; padding: 0.5rem 1rem; border-radius: 4px; }

.filters { display: flex; gap: 0.5rem; align-items: center; margin-bottom: 1rem; }
.filters input, .filters select, .filters button, .filters a { padding: 0.4rem 0.7rem; border: 1px solid #d1d5db; border-radius: 4px; font: inherit; background: white; color: inherit; text-decoration: none; }
.filters .primary, a.primary { background: #4338ca; color: white; border-color: #4338ca; }

button { cursor: pointer; padding: 0.4rem 0.8rem; border-radius: 4px; border: 1px solid #d1d5db; background: white; }
button:hover { background: #f3f4f6; }

.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 1rem; }
.card { background: white; padding: 1rem; border-radius: 6px; border: 1px solid #e5e7eb; }
.card h3 { margin: 0 0 0.5rem 0; font-size: 0.9rem; color: #6b7280; }
.card p.big { font-size: 1.75rem; margin: 0; font-weight: 600; }

fieldset { border: 1px solid #d1d5db; border-radius: 6px; padding: 1rem; }
fieldset .row { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 0.5rem; margin-bottom: 0.4rem; }
