:root {
  color-scheme: light;
  --ink: #0f2d4f;
  --muted: #5e6d78;
  --paper: #fffaf4;
  --line: #e6dacd;
  --teal: #42c1be;
  --leaf: #38684e;
  --orange: #f58a31;
  --white: #ffffff;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: var(--paper);
  color: var(--ink);
}

.login-gate {
  position: fixed;
  inset: 0;
  z-index: 10;
  display: grid;
  place-items: center;
  padding: 24px;
  background: linear-gradient(135deg, #fffaf4, #effaf8);
}

.login-gate[hidden] {
  display: none;
}

.login-card {
  width: min(520px, 100%);
  display: grid;
  gap: 14px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--white);
  padding: 26px;
  box-shadow: 0 24px 70px rgba(15, 45, 79, 0.12);
}

.login-card h1 {
  font-size: clamp(42px, 7vw, 72px);
}

.login-card label {
  display: grid;
  gap: 8px;
  color: var(--ink);
  font-weight: 850;
}

.login-card input {
  min-height: 50px;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0 14px;
  font: inherit;
  color: var(--ink);
}

.login-card button {
  min-height: 52px;
  background: var(--ink);
  color: var(--white);
}

.login-error {
  margin: 0;
  color: #b42318;
  font-weight: 800;
}

.shell {
  width: min(1120px, calc(100vw - 32px));
  margin: 0 auto;
  padding: 40px 0 64px;
}

.hero {
  min-height: 38vh;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 260px;
  gap: 32px;
  align-items: end;
  padding: 24px 0 28px;
  border-bottom: 1px solid var(--line);
}

.eyebrow {
  margin: 0 0 14px;
  color: var(--leaf);
  font-weight: 800;
}

h1 {
  margin: 0;
  max-width: 820px;
  font-size: clamp(46px, 8vw, 92px);
  line-height: 0.92;
}

.subcopy,
.panel p,
.message {
  color: var(--muted);
  line-height: 1.5;
}

.subcopy {
  max-width: 760px;
  margin: 24px 0 0;
  font-size: 20px;
}

.rule-card {
  border: 1px solid var(--line);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.74);
  padding: 18px;
  display: grid;
  gap: 10px;
  align-self: stretch;
  align-content: end;
}

.rule-card span {
  display: block;
  color: var(--ink);
  font-size: 28px;
  font-weight: 850;
}

.workflow-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  padding: 24px 0 0;
}

button,
.request-card a,
.previous-actions a {
  border: 0;
  border-radius: 10px;
  font: inherit;
  font-weight: 850;
  text-decoration: none;
  cursor: pointer;
}

.workflow-tabs .tab {
  min-height: 46px;
  padding: 0 16px;
  border: 1px solid var(--line);
  background: var(--white);
  color: var(--ink);
}

.workflow-tabs .tab.active {
  background: var(--ink);
  color: var(--white);
}

.panel {
  margin: 28px 0 0;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--white);
  padding: 22px;
}

h2,
h3 {
  margin: 0;
}

.panel h2 {
  font-size: 32px;
}

.request-card {
  margin-top: 16px;
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 14px;
  background: #fffdf9;
}

.request-card p {
  margin: 0;
}

.request-card a,
.previous-actions a {
  display: inline-flex;
  align-items: center;
  min-height: 42px;
  padding: 0 14px;
  background: var(--ink);
  color: var(--white);
  white-space: nowrap;
}

.previous {
  margin-top: 34px;
  padding-top: 28px;
  border-top: 1px solid var(--line);
}

.section-head,
.previous-card {
  display: flex;
  justify-content: space-between;
  gap: 18px;
}

.section-head {
  align-items: center;
  margin-bottom: 18px;
}

.count-pill {
  border-radius: 999px;
  background: #edf6ef;
  color: var(--leaf);
  padding: 8px 12px;
  font-weight: 850;
}

.previous-list {
  display: grid;
  gap: 12px;
}

.previous-card {
  background: #fffdf9;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 16px;
}

.previous-date {
  margin: 0 0 6px;
  color: var(--leaf);
  font-size: 13px;
  font-weight: 850;
}

.previous-card h3 {
  font-size: 23px;
}

.previous-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-content: start;
  justify-content: flex-end;
  min-width: 220px;
}

.previous-actions a:nth-child(2) {
  background: var(--teal);
  color: #073234;
}

@media (max-width: 820px) {
  .hero,
  .request-card,
  .previous-card {
    grid-template-columns: 1fr;
    display: grid;
  }

  .rule-card {
    grid-template-columns: repeat(3, 1fr);
    align-self: auto;
  }

  .previous-actions {
    justify-content: start;
    min-width: 0;
  }
}
