/* MyCode brand, applied to ELS. See docs/design/brand-for-web.md.
 *
 * Inter Tight is NOT self-hosted yet — the font files are not in the repo and
 * the brand notes are explicit that loading them from a third-party CDN is the
 * wrong answer for an internal tool holding HR data. So the stack falls back to
 * the system UI face until the real files arrive. Flagged in the phase report.
 */

:root {
  --mc-cream: #f4eee9;
  --mc-dark-green: #1d4537;
  --mc-dark: #212121;
  --mc-light-green: #badd7f; /* accent only — fails contrast on cream */
  --mc-pink: #efaca4; /* accent only — fails contrast on cream */

  /* Functional palette. A documented exception: the brand has no red, and an
   * SLA breach cannot be indicated in Pink. */
  --mc-warning: #8a6a00;
  --mc-danger: #a32e20;
  --mc-neutral: #6b6b6b;

  --bg: var(--mc-cream);
  --surface: #ffffff;
  --text: var(--mc-dark-green);
  --text-muted: var(--mc-neutral);
  --border: #ddd5ce;
  --header-bg: var(--mc-dark-green);
  --header-text: var(--mc-cream);

  --font: "Inter Tight", system-ui, -apple-system, "Segoe UI", Arial, sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 15px;
  line-height: 1.5;
}

h1,
h2,
h3 {
  font-weight: 700;
  letter-spacing: -0.01em;
  margin: 0 0 0.5rem;
}

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

a {
  color: var(--text);
}

.site-header {
  background: var(--header-bg);
  color: var(--header-text);
  padding: 0.75rem 1.5rem;
  display: flex;
  align-items: center;
  gap: 2rem;
}

/* Clearspace equal to the mark's own height, per the brand rules. The monogram
 * SVG is not in the repo yet, so this is the wordmark set in type. */
.site-header .brand {
  font-weight: 700;
  letter-spacing: 0.02em;
  padding: 0 1rem;
  color: var(--header-text);
  text-decoration: none;
}

.site-header nav {
  display: flex;
  gap: 1.25rem;
  flex: 1;
}

.site-header nav a {
  color: var(--header-text);
  text-decoration: none;
  opacity: 0.85;
}

.site-header nav a:hover,
.site-header nav a[aria-current="page"] {
  opacity: 1;
  text-decoration: underline;
}

.site-header .viewer {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 0.9rem;
}

.site-header form {
  margin: 0;
}

main {
  max-width: 68rem;
  margin: 0 auto;
  padding: 2rem 1.5rem 4rem;
}

.lede {
  color: var(--text-muted);
  margin-top: 0;
}

/* Tables, not cards — density is the usability requirement in a work queue. */
table {
  width: 100%;
  border-collapse: collapse;
  background: var(--surface);
  border: 1px solid var(--border);
}

th,
td {
  text-align: left;
  padding: 0.5rem 0.75rem;
  border-bottom: 1px solid var(--border);
  vertical-align: top;
}

th {
  font-weight: 700;
  font-size: 0.8rem;
  text-transform: none;
  background: var(--bg);
}

tbody tr:last-child td {
  border-bottom: none;
}

.empty-state {
  background: var(--surface);
  border: 1px solid var(--border);
  padding: 2rem;
}

.empty-state h2 {
  margin-top: 0;
}

/* Status never relies on colour alone — every state carries its label. */
.status {
  font-size: 0.8rem;
  font-weight: 700;
  white-space: nowrap;
}
.status--active {
  color: var(--mc-dark-green);
}
.status--revoked {
  color: var(--mc-neutral);
}
.status--danger {
  color: var(--mc-danger);
}

.button {
  display: inline-block;
  background: var(--mc-dark-green);
  color: var(--mc-cream);
  border: 1px solid var(--mc-dark-green);
  padding: 0.6rem 1.1rem;
  font: inherit;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
}

.button--quiet {
  background: transparent;
  color: var(--header-text);
  border-color: currentColor;
  padding: 0.3rem 0.7rem;
  font-weight: 400;
}

.sign-in {
  max-width: 26rem;
  margin: 6rem auto;
  background: var(--surface);
  border: 1px solid var(--border);
  padding: 2rem;
}

.notice {
  border-left: 3px solid var(--mc-danger);
  padding: 0.75rem 1rem;
  background: var(--surface);
  margin-bottom: 1.5rem;
}

.muted {
  color: var(--text-muted);
}

code {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 0.85em;
}
