/* The Command Post — Green Zone Academy operator cockpit.
   Warm field-desk feel: deep zone green, canvas paper, gold "waiting" signal,
   status chips styled like sewn uniform name tapes. */

:root {
  --ink: #22301f;
  --ink-soft: #4a5544;
  --paper: #f2f0e6;
  --card: #fbfaf4;
  --zone: #2e4b34;
  --zone-deep: #223a28;
  --sage: #4f7a46;
  --gold: #c99a2c;
  --gold-soft: #f3e2b8;
  --rust: #a8503c;
  --tape-bg: #e9e4d2;
  --tape-edge: #c9c2a8;
  --radius: 10px;
  --shadow: 0 1px 3px rgba(34, 48, 31, 0.12);
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: "Public Sans", -apple-system, "Segoe UI", sans-serif;
  font-size: 18px;
  line-height: 1.55;
}

h1, h2, h3, .brand-text, .tape {
  font-family: "Zilla Slab", Georgia, serif;
}

/* --- Masthead --- */
.masthead { background: var(--zone-deep); color: #f4f2e8; }
.masthead-inner {
  max-width: 920px; margin: 0 auto; padding: 14px 20px;
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
}
.brand { display: flex; align-items: center; gap: 12px; color: inherit; text-decoration: none; }
.brand-mark {
  width: 38px; height: 38px; border-radius: 9px; flex: none;
  background: radial-gradient(circle at 50% 45%, var(--gold) 0 8px, transparent 9px), var(--zone);
  border: 2px solid rgba(244, 242, 232, 0.35);
}
.brand-text { display: flex; flex-direction: column; line-height: 1.15; }
.brand-text strong { font-size: 19px; font-weight: 700; letter-spacing: 0.2px; }
.brand-text em { font-style: normal; font-size: 13.5px; opacity: 0.85; letter-spacing: 0.6px; text-transform: uppercase; }
.who { display: flex; align-items: center; gap: 10px; font-size: 16px; }
.linklike {
  background: none; border: none; color: #f4f2e8; text-decoration: underline;
  font: inherit; font-size: 15px; cursor: pointer; padding: 6px; opacity: 0.9;
  white-space: nowrap;
}
.who { white-space: nowrap; }
.linklike:hover { opacity: 1; }

/* --- Mission strip (the signature) --- */
.strip {
  background: var(--zone); color: #f6f4ea;
  font-family: "Zilla Slab", Georgia, serif; font-size: 20px; font-weight: 600;
  padding: 14px 20px; text-align: center;
  border-bottom: 3px solid var(--sage);
}
.strip.busy { border-bottom-color: var(--gold); }
.strip-dot {
  display: inline-block; width: 11px; height: 11px; border-radius: 50%;
  background: #8fd07f; margin-right: 10px; vertical-align: baseline;
  animation: breathe 3s ease-in-out infinite;
}
.strip.busy .strip-dot { background: var(--gold); }
@keyframes breathe { 0%, 100% { opacity: 1; } 50% { opacity: 0.45; } }
@media (prefers-reduced-motion: reduce) { .strip-dot { animation: none; } }

/* --- Tabs --- */
.tabs {
  max-width: 920px; margin: 18px auto 0; padding: 0 20px;
  display: flex; gap: 8px; flex-wrap: wrap;
}
.tab {
  flex: 1 1 160px; text-align: center; text-decoration: none;
  background: var(--card); color: var(--ink);
  border: 1.5px solid var(--tape-edge); border-radius: var(--radius);
  padding: 12px 10px; font-weight: 600; font-size: 16.5px; box-shadow: var(--shadow);
}
.tab:hover { border-color: var(--zone); }
.tab.active { background: var(--zone); border-color: var(--zone); color: #f6f4ea; }

/* --- Page + cards --- */
.page { max-width: 920px; margin: 0 auto; padding: 10px 20px 40px; }
.page-title { font-size: 30px; margin: 22px 0 14px; }
.card {
  background: var(--card); border: 1.5px solid var(--tape-edge);
  border-radius: var(--radius); box-shadow: var(--shadow);
  padding: 20px 22px; margin-bottom: 16px;
}
.card h2 { margin: 0 0 6px; font-size: 22px; }
.card p { margin: 8px 0; }
.card-actions { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; margin-top: 12px; }
.when { color: var(--ink-soft); font-size: 15px; }
.empty { text-align: center; padding: 34px 22px; }
.empty h2 { font-size: 24px; }

/* --- Name-tape status chips --- */
.tape {
  display: inline-block; padding: 3px 12px; font-size: 14.5px; font-weight: 600;
  letter-spacing: 0.4px; text-transform: uppercase; color: var(--ink);
  background: var(--tape-bg);
  border: 1px solid var(--tape-edge);
  outline: 1px dashed rgba(74, 85, 68, 0.5); outline-offset: -4px; /* the stitch */
}
.tape.ok { background: #dcead4; border-color: #a9c49b; }
.tape.busy { background: var(--gold-soft); border-color: #d8bd7d; }
.tape.warn { background: #f0d8cf; border-color: #cf9a87; }
.tape.quiet { color: var(--ink-soft); }

/* --- Veterans --- */
.vet-head, .sys-head {
  display: flex; align-items: center; justify-content: space-between;
  gap: 12px; flex-wrap: wrap;
}
.flags { margin: 10px 0 0; padding-left: 22px; }
.flags li { margin: 4px 0; color: var(--ink-soft); }

/* --- Buttons --- */
.btn {
  display: inline-block; border: none; border-radius: var(--radius);
  padding: 12px 22px; font: inherit; font-weight: 700; font-size: 17px;
  cursor: pointer; text-decoration: none; text-align: center;
  box-shadow: var(--shadow);
}
.btn.big { padding: 16px 28px; font-size: 18px; }
.btn.primary { background: var(--zone); color: #f6f4ea; }
.btn.primary:hover { background: var(--zone-deep); }
.btn.approve { background: var(--sage); color: #fbfaf2; }
.btn.approve:hover { background: #40673a; }
.btn.reject { background: var(--card); color: var(--rust); border: 2px solid var(--rust); }
.btn.reject:hover { background: #f6e8e3; }

/* --- Messages --- */
.msg-kind { font-family: "Zilla Slab", Georgia, serif; font-weight: 600; font-size: 20px; margin: 0; }
.msg-to, .msg-subject { color: var(--ink-soft); margin: 4px 0; font-size: 16px; }
.msg-body {
  margin: 14px 0; padding: 14px 18px; background: #f4f1e4;
  border-left: 4px solid var(--gold); border-radius: 6px;
  white-space: pre-wrap; font-size: 17.5px;
}
.decide-buttons { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 10px; }
.note-field textarea {
  width: 100%; border: 1.5px solid var(--tape-edge); border-radius: 8px;
  padding: 10px 12px; font: inherit; font-size: 16px; background: #fff;
}
.note-field span { display: block; font-size: 15px; color: var(--ink-soft); margin-bottom: 4px; }

/* --- Activity feed --- */
.feed { list-style: none; margin: 0; padding: 0; }
.feed-item {
  background: var(--card); border: 1.5px solid var(--tape-edge); border-radius: var(--radius);
  box-shadow: var(--shadow); padding: 14px 18px; margin-bottom: 10px;
}
.feed-item.alert { border-color: var(--rust); background: #faf1ec; }
.feed-msg { display: block; }
.feed-meta { display: block; color: var(--ink-soft); font-size: 14.5px; margin-top: 4px; }

/* --- Login --- */
.login-card { max-width: 460px; margin: 48px auto; }
.picks { border: none; margin: 14px 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.pick {
  display: flex; align-items: center; gap: 12px; font-size: 18px; font-weight: 600;
  background: #f4f1e4; border: 1.5px solid var(--tape-edge); border-radius: var(--radius);
  padding: 12px 16px; cursor: pointer;
}
.pick:hover { border-color: var(--zone); }
.pick input { width: 20px; height: 20px; accent-color: var(--zone); }
.field { display: block; margin: 14px 0; }
.field > span { display: block; font-weight: 600; margin-bottom: 6px; }
.field input {
  width: 100%; padding: 12px 14px; font: inherit; font-size: 18px;
  border: 1.5px solid var(--tape-edge); border-radius: var(--radius); background: #fff;
}
.problem {
  background: #faf1ec; border: 1.5px solid var(--rust); color: #6f3325;
  border-radius: var(--radius); padding: 12px 16px;
}
.notice {
  background: #e3eedb; border: 1.5px solid var(--sage); color: #2c4526;
  border-radius: var(--radius); padding: 12px 16px;
}

/* --- Footer + a11y --- */
.foot {
  max-width: 920px; margin: 0 auto; padding: 18px 20px 34px;
  color: var(--ink-soft); font-size: 15px; text-align: center;
}
.visually-hidden {
  position: absolute; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap;
}
a:focus-visible, button:focus-visible, input:focus-visible, textarea:focus-visible, .pick:focus-within {
  outline: 3px solid var(--gold); outline-offset: 2px;
}

@media (max-width: 560px) {
  body { font-size: 17px; }
  .tabs { gap: 6px; }
  .tab { flex-basis: 46%; font-size: 15px; padding: 10px 6px; }
  .decide-buttons .btn { flex: 1 1 100%; }
  .strip { font-size: 17.5px; }
}
