:root {
  --navy: #052955;
  --paper: #0b2d4c;
  --orange: #ff6817;
  --muted: #52676f;
  --line: #dce3df;
  --bg: #f7f8f5;
}
* { box-sizing: border-box; }
body {
  margin: 0;
  font-family: "Segoe UI", sans-serif;
  background: var(--bg);
  color: var(--paper);
}
.login {
  min-height: 100vh;
  display: grid;
  place-items: center;
  background: var(--navy);
}
.card {
  width: min(420px, 92vw);
  background: #fff;
  padding: 2rem;
  display: grid;
  gap: 0.9rem;
}
.eyebrow, .brand {
  text-transform: uppercase;
  letter-spacing: 0.18em;
  font-size: 11px;
  font-weight: 700;
  color: var(--orange);
  margin: 0;
}
h1 { margin: 0; font-size: 1.8rem; }
label { display: grid; gap: 0.35rem; font-size: 13px; color: var(--muted); }
input, select, textarea, button {
  font: inherit;
  padding: 0.7rem 0.8rem;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--paper);
}
textarea { min-height: 110px; resize: vertical; }
button {
  background: var(--orange);
  color: #fff;
  border: 0;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  cursor: pointer;
}
button.secondary { background: var(--navy); }
button.ghost { background: transparent; color: var(--navy); border: 1px solid var(--line); }
.error { color: #9b1c1c; margin: 0; }
[hidden] { display: none !important; }
#app { display: grid; grid-template-columns: 240px 1fr; min-height: 100vh; }
aside {
  background: var(--navy);
  color: #fff;
  padding: 1.4rem 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}
aside a, aside button#logout {
  color: #fff;
  text-decoration: none;
  padding: 0.7rem 0.8rem;
  display: block;
  background: transparent;
  border: 0;
  text-align: left;
  text-transform: none;
  letter-spacing: 0;
  font-weight: 500;
}
aside a.active, aside a:hover { background: rgb(255 255 255 / 10%); }
aside button#logout { margin-top: auto; color: #ffb48a; }
main { padding: 1.5rem 2rem 3rem; }
.top { display: flex; justify-content: space-between; align-items: center; gap: 1rem; }
table { width: 100%; border-collapse: collapse; background: #fff; }
th, td { border-bottom: 1px solid var(--line); text-align: left; padding: 0.75rem; font-size: 14px; vertical-align: top; }
th { background: var(--navy); color: #fff; }
.form { display: grid; gap: 0.9rem; max-width: 760px; background: #fff; padding: 1.25rem; }
.row { display: flex; gap: 0.6rem; flex-wrap: wrap; }
.muted { color: var(--muted); font-size: 14px; }
.flash { background: #edf3f0; padding: 0.8rem 1rem; }
.preview { max-height: 72px; max-width: 140px; object-fit: contain; }
@media (max-width: 800px) {
  #app { grid-template-columns: 1fr; }
}
