/* qzcal.com landing page. External on purpose: the server's CSP
   (default-src 'self', no style-src) blocks inline <style>. */
:root {
  --paper: #fafbfd;
  --grid: #dde3ee;
  --ink: #1b2a4a;
  --ink-soft: #5a6a8c;
  --card: #ffffff;
  --amber: #e8a13d;
  --amber-ink: #7a4d08;
  --amber-soft: #fdf3e2;
}
@media (prefers-color-scheme: dark) {
  :root {
    --paper: #0e1526;
    --grid: #1d2740;
    --ink: #e6eaf2;
    --ink-soft: #8d9ab8;
    --card: #141d33;
    --amber: #e8a13d;
    --amber-ink: #f3c47c;
    --amber-soft: #2b2210;
  }
}
* { margin: 0; padding: 0; box-sizing: border-box; }
html, body { height: 100%; }
body {
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  color: var(--ink);
  background-color: var(--paper);
  /* empty spreadsheet: faint cell grid */
  background-image:
    linear-gradient(var(--grid) 1px, transparent 1px),
    linear-gradient(90deg, var(--grid) 1px, transparent 1px);
  background-size: 56px 32px;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}
.mono { font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace; }

header {
  padding: 1.5rem 2rem;
  display: flex;
  align-items: baseline;
  gap: 1.5rem;
}
.nav-link { color: var(--ink-soft); text-decoration: none; font-size: .95rem; }
.nav-link:hover { color: var(--ink); }
.wordmark {
  display: inline-flex;
  align-items: baseline;
  gap: .5rem;
  font-weight: 800;
  font-size: 1.25rem;
  letter-spacing: -0.02em;
  color: var(--ink);
  text-decoration: none;
}
.wordmark .tld { color: var(--ink-soft); font-weight: 400; font-size: 1rem; }

main {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 2rem 1.25rem 4rem;
  text-align: center;
}
h1 {
  font-size: clamp(2.4rem, 6vw, 4rem);
  font-weight: 800;
  letter-spacing: -0.035em;
  line-height: 1.05;
}
.lede {
  margin-top: 1rem;
  max-width: 34rem;
  font-size: 1.06rem;
  line-height: 1.6;
  color: var(--ink-soft);
}

/* ——— the record card: this page, as a QZCal record ——— */
.record {
  margin-top: 2.75rem;
  width: min(100%, 26.5rem);
  text-align: left;
  background: var(--card);
  border: 1px solid var(--grid);
  border-radius: 10px;
  box-shadow: 0 8px 28px -12px rgba(27, 42, 74, .25);
  overflow: hidden;
}
.record-head {
  padding: .8rem 1.1rem;
  border-bottom: 1px solid var(--grid);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
}
.record-head .table-name { font-size: .75rem; color: var(--ink-soft); letter-spacing: .08em; text-transform: uppercase; }
.record-head .record-id { font-size: .75rem; color: var(--ink-soft); }
.field {
  display: grid;
  grid-template-columns: 8.5rem 1fr;
  align-items: center;
  padding: .7rem 1.1rem;
  border-bottom: 1px solid var(--grid);
  animation: rise .45s ease-out backwards;
}
.field:last-child { border-bottom: none; }
.field:nth-child(2) { animation-delay: .1s; }
.field:nth-child(3) { animation-delay: .22s; }
.field:nth-child(4) { animation-delay: .34s; }
@keyframes rise {
  from { opacity: 0; transform: translateY(6px); }
  to   { opacity: 1; transform: none; }
}
.field dt { font-size: .8rem; color: var(--ink-soft); }
.field dd { font-size: .92rem; }

/* the selected cell: status */
.cell-selected {
  display: inline-block;
  padding: .25rem .55rem;
  border: 2px solid var(--amber);
  border-radius: 4px;
  background: var(--amber-soft);
  color: var(--amber-ink);
  font-weight: 600;
  position: relative;
}
.cell-selected::after {
  content: "";
  display: inline-block;
  width: 1px;
  height: .95em;
  margin-left: .3em;
  vertical-align: -0.15em;
  background: var(--amber-ink);
  animation: blink 1.1s steps(1) infinite;
}
@keyframes blink { 50% { opacity: 0; } }

.wordmark:focus-visible {
  outline: 2px solid var(--amber);
  outline-offset: 3px;
  border-radius: 3px;
}

footer {
  padding: 1.25rem 2rem;
  text-align: center;
  font-size: .8rem;
  color: var(--ink-soft);
}

@media (prefers-reduced-motion: reduce) {
  .field { animation: none; }
  .cell-selected::after { animation: none; }
}
@media (max-width: 480px) {
  .field { grid-template-columns: 1fr; row-gap: .25rem; }
}
