:root {
  color-scheme: light;
  --bg: #f4f1ea;
  --ink: #141414;
  --muted: #63605b;
  --line: #d9d2c4;
  --panel: #fffaf0;
  --accent: #0f766e;
  --accent-dark: #0b4f4a;
  --warn: #a23b2a;
}

* {
  box-sizing: border-box;
}

body {
  min-height: 100vh;
  margin: 0;
  background:
    linear-gradient(120deg, rgba(15, 118, 110, 0.12), transparent 35%),
    var(--bg);
  color: var(--ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

a {
  color: inherit;
}

.landing {
  width: min(1120px, calc(100% - 32px));
  min-height: 100vh;
  margin: 0 auto;
  display: grid;
  align-content: center;
  gap: 56px;
  padding: 48px 0;
}

.hero {
  max-width: 820px;
}

.eyebrow,
.label {
  margin: 0;
  color: var(--accent-dark);
  font-size: 0.8rem;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

h1 {
  max-width: 780px;
  margin: 12px 0 0;
  font-size: clamp(3rem, 8vw, 7.6rem);
  line-height: 0.92;
  letter-spacing: 0;
}

.intro {
  max-width: 600px;
  margin: 28px 0 0;
  color: var(--muted);
  font-size: 1.25rem;
  line-height: 1.6;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 32px;
}

.button {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--ink);
  border-radius: 6px;
  padding: 0 18px;
  background: transparent;
  color: var(--ink);
  font: inherit;
  font-weight: 800;
  text-decoration: none;
  cursor: pointer;
}

.button.primary {
  border-color: var(--accent);
  background: var(--accent);
  color: #ffffff;
}

.button.secondary {
  border-color: var(--line);
  background: rgba(255, 255, 255, 0.42);
}

.status {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.status div {
  min-width: 0;
  padding: 20px;
  border-right: 1px solid var(--line);
}

.status div:last-child {
  border-right: 0;
}

.status strong {
  display: block;
  margin-top: 8px;
  overflow-wrap: anywhere;
}

.admin-shell {
  width: min(1080px, calc(100% - 32px));
  margin: 0 auto;
  padding: 48px 0;
}

.admin-panel {
  max-width: 420px;
  margin: 8vh auto 0;
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
}

.admin-panel h1,
.admin-dashboard h1 {
  font-size: 2rem;
  line-height: 1.1;
}

form {
  display: grid;
  gap: 16px;
  margin-top: 24px;
}

label {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-weight: 700;
}

input {
  min-height: 44px;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 0 12px;
  background: #ffffff;
  color: var(--ink);
  font: inherit;
}

.error {
  min-height: 1.5em;
  margin: 0;
  color: var(--warn);
}

.hidden {
  display: none !important;
}

.admin-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  border-bottom: 1px solid var(--line);
  padding-bottom: 24px;
}

.metrics {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-top: 24px;
}

.metric-card {
  min-height: 108px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
}

.metric-card span {
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 800;
}

.metric-card strong {
  display: block;
  margin-top: 10px;
  overflow-wrap: anywhere;
  font-size: 1.5rem;
}

.table-wrap {
  margin-top: 24px;
  overflow-x: auto;
}

.table-wrap h2 {
  font-size: 1.25rem;
}

table {
  width: 100%;
  min-width: 760px;
  border-collapse: collapse;
  background: var(--panel);
}

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

th {
  color: var(--muted);
  font-size: 0.85rem;
  text-transform: uppercase;
}

td {
  overflow-wrap: anywhere;
}

@media (max-width: 760px) {
  .landing {
    gap: 36px;
  }

  .status,
  .metrics {
    grid-template-columns: 1fr;
  }

  .status div {
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .status div:last-child {
    border-bottom: 0;
  }

  .admin-header {
    align-items: flex-start;
    flex-direction: column;
  }
}
