:root {
  color-scheme: light;
  --ink: #20282b;
  --muted: #5c6568;
  --line: #e4dfcb;
  --paper: #f7f6f3;
  --orange: #fa4614;
  --orange-dark: #d63a10;
  --white: #fff;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  background: #fff;
  color: var(--ink);
}

body {
  font-family: "Avenir Next", Avenir, "Segoe UI", Helvetica, Arial, sans-serif;
  color: var(--ink);
  font-size: 16px;
  line-height: 1.45;
}

.lookup-wrap {
  max-width: 50rem;
  margin: 0 auto;
  padding: 4px 2px 8px;
}

html.standalone body {
  background: var(--paper);
  min-height: 100vh;
}

html.standalone .lookup-wrap {
  padding: 48px 20px 64px;
}

.only-standalone { display: none; }

html.standalone .only-standalone { display: block; }

.brand {
  margin: 0 0 8px;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--orange);
}

h1 {
  margin: 0 0 8px;
  font-size: 1.8rem;
  line-height: 1.15;
  font-weight: 700;
}

.lede {
  margin: 0 0 24px;
  color: var(--muted);
}

.lede a { color: var(--orange); }

label {
  display: block;
  margin-bottom: 6px;
  font-size: 0.92rem;
  font-weight: 600;
}

.search-row {
  display: flex;
  gap: 8px;
  align-items: stretch;
}

input[type="text"],
input[type="search"] {
  flex: 1;
  min-width: 0;
  height: 48px;
  border: 1px solid #cfc8b4;
  border-radius: 4px;
  padding: 0 12px;
  background: var(--white);
  color: var(--ink);
  font: inherit;
}

button {
  height: 48px;
  padding: 0 18px;
  border: 0;
  border-radius: 4px;
  background: var(--orange);
  color: var(--white);
  font: inherit;
  font-weight: 600;
  cursor: pointer;
}

button:hover { background: var(--orange-dark); }

:focus-visible {
  outline: 2px solid var(--orange);
  border-radius: 2px;
}

.message, .empty {
  margin: 16px 0 0;
  color: var(--ink);
}

.results { margin-top: 18px; }

.results-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: baseline;
  margin-bottom: 4px;
}

.results-head h2 {
  margin: 0;
  font-size: 1.15rem;
  letter-spacing: 0.02em;
}

.count {
  margin: 0;
  color: var(--muted);
  font-size: 0.92rem;
}

.result {
  padding: 14px 0;
  border-top: 1px solid var(--line);
}

.result time,
.date-missing {
  display: block;
  margin: 0 0 4px;
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.04em;
}

.date-missing {
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.result p {
  margin: 0;
  overflow-wrap: anywhere;
}

@media (max-width: 520px) {
  .search-row { flex-direction: column; }
  .search-row button { width: 100%; }
  html.standalone .lookup-wrap { padding: 28px 16px 48px; }
  h1 { font-size: 1.5rem; }
}
