:root {
  --ink: #121212;
  --muted: #5d6469;
  --paper: #f4f4f1;
  --concrete: #e4e5e1;
  --line: #c9ccc7;
  --red: #d31324;
  --red-dark: #9f0f1c;
  --teal: #0f6d72;
  --white: #ffffff;
  --shadow: 0 18px 48px rgba(18, 18, 18, .12);
}

* {
  box-sizing: border-box;
}

html {
  font-size: 16px;
}

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

img {
  display: block;
  max-width: 100%;
}

a {
  color: inherit;
}

.skip-link {
  position: absolute;
  left: 1rem;
  top: -4rem;
  z-index: 10;
  background: var(--ink);
  color: var(--white);
  padding: .75rem 1rem;
  border-radius: 6px;
}

.skip-link:focus {
  top: 1rem;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 4;
  background: rgba(244, 244, 241, .94);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(10px);
}

.nav {
  width: min(1120px, calc(100% - 2rem));
  min-height: 76px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.brand {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  min-width: 168px;
}

.brand img {
  width: 190px;
  height: auto;
}

.nav-links {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: .35rem;
}

.nav-links a,
.logout-form button {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: .55rem .8rem;
  border: 1px solid transparent;
  border-radius: 6px;
  background: transparent;
  color: var(--ink);
  font: inherit;
  text-decoration: none;
  cursor: pointer;
}

.nav-links a:hover,
.logout-form button:hover,
.nav-links a:focus-visible,
.logout-form button:focus-visible {
  border-color: var(--line);
  background: var(--white);
}

.logout-form {
  margin: 0;
}

main {
  min-height: calc(100vh - 158px);
}

.hero {
  min-height: 520px;
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(260px, .8fr);
  align-items: center;
  gap: 2rem;
  padding: 5rem max(1rem, calc((100vw - 1120px) / 2)) 4rem;
  background-color: var(--concrete);
  background-image:
    linear-gradient(90deg, rgba(18, 18, 18, .05) 1px, transparent 1px),
    linear-gradient(0deg, rgba(18, 18, 18, .04) 1px, transparent 1px);
  background-size: 94px 94px, 62px 62px;
  border-bottom: 1px solid var(--line);
}

.hero-content {
  max-width: 680px;
}

.eyebrow {
  margin: 0 0 .75rem;
  color: var(--red);
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0;
}

h1,
h2,
h3,
p {
  overflow-wrap: anywhere;
}

h1,
h2,
h3 {
  line-height: 1.08;
}

h1 {
  margin: 0;
  font-size: 4rem;
}

h2 {
  margin: 0 0 1rem;
  font-size: 2rem;
}

.lead {
  max-width: 560px;
  margin: 1rem 0 0;
  color: #273036;
  font-size: 1.25rem;
}

.hero-actions,
.page-heading {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: .75rem;
}

.hero-actions {
  margin-top: 2rem;
}

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

.button-primary {
  background: var(--red);
  border-color: var(--red);
  color: var(--white);
}

.button-primary:hover,
.button-primary:focus-visible {
  background: var(--red-dark);
  border-color: var(--red-dark);
}

.button-secondary {
  background: var(--white);
  color: var(--ink);
}

.button-secondary:hover,
.button-secondary:focus-visible {
  border-color: var(--teal);
  color: var(--teal);
}

.hero-mark {
  justify-self: end;
  width: min(100%, 360px);
  aspect-ratio: 1 / 1;
  display: grid;
  place-content: center;
  border: 10px solid var(--red);
  border-radius: 8px;
  color: var(--red);
  background: rgba(244, 244, 241, .58);
  box-shadow: var(--shadow);
  transform: rotate(-2deg);
}

.hero-mark span,
.hero-mark strong {
  display: block;
  font-family: Impact, Haettenschweiler, "Arial Black", sans-serif;
  line-height: .9;
  text-align: center;
  letter-spacing: 0;
}

.hero-mark span {
  font-size: 5.5rem;
}

.hero-mark strong {
  color: var(--ink);
  font-size: 4.25rem;
}

.content-band,
.page-heading,
.log-grid,
.empty-state,
.form-layout,
.log-detail,
.table-wrap,
.pagination {
  width: min(1120px, calc(100% - 2rem));
  margin-left: auto;
  margin-right: auto;
}

.content-band {
  padding: 4rem 0;
}

.content-narrow {
  max-width: 780px;
}

.content-narrow p,
.description {
  font-size: 1.1rem;
}

.page-heading {
  justify-content: space-between;
  padding: 3rem 0 1.5rem;
}

.page-heading h1 {
  margin-right: auto;
}

.log-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1rem;
  padding-bottom: 3rem;
}

.log-card {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--white);
  box-shadow: 0 10px 24px rgba(18, 18, 18, .08);
}

.log-card a {
  display: grid;
  min-height: 100%;
  text-decoration: none;
}

.log-card img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  background: var(--concrete);
}

.log-card span {
  padding: .9rem 1rem 1rem;
  color: var(--red);
  font-family: Impact, Haettenschweiler, "Arial Black", sans-serif;
  font-size: 1.65rem;
  letter-spacing: 0;
}

.empty-state {
  margin-top: 2rem;
  margin-bottom: 4rem;
  padding: 2rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--white);
}

.empty-state h1,
.empty-state h2 {
  margin-top: 0;
}

.log-detail {
  padding: 2rem 0 4rem;
}

.log-photo {
  margin: 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
  background: var(--white);
}

.log-photo img {
  width: 100%;
  max-height: 78vh;
  object-fit: contain;
  background: #202020;
}

.log-body {
  max-width: 820px;
  padding: 2rem 0 0;
}

.metadata {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 1rem;
  margin: 2rem 0 0;
}

.metadata div {
  padding: 1rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--white);
}

.metadata dt {
  color: var(--muted);
  font-size: .9rem;
  font-weight: 700;
}

.metadata dd {
  margin: .25rem 0 0;
  font-weight: 800;
}

.detail-nav,
.pagination {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-top: 2rem;
}

.form-layout {
  display: grid;
  grid-template-columns: minmax(220px, .7fr) minmax(0, 1fr);
  gap: 2rem;
  padding: 3rem 0 4rem;
}

.form-copy {
  max-width: 360px;
}

.form-panel {
  display: grid;
  gap: 1rem;
  padding: 1.25rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--white);
  box-shadow: 0 10px 28px rgba(18, 18, 18, .08);
}

.field {
  display: grid;
  gap: .4rem;
}

label {
  font-weight: 800;
}

input,
textarea,
select {
  width: 100%;
  min-height: 44px;
  padding: .65rem .75rem;
  border: 1px solid #aeb4b8;
  border-radius: 6px;
  background: var(--white);
  color: var(--ink);
  font: inherit;
}

textarea {
  resize: vertical;
}

.help,
.errorlist {
  margin: 0;
  color: var(--muted);
  font-size: .92rem;
}

.errorlist {
  color: var(--red-dark);
  padding-left: 1rem;
}

.text-link {
  color: var(--teal);
  font-weight: 800;
}

.messages {
  width: min(1120px, calc(100% - 2rem));
  margin: 1rem auto 0;
}

.message {
  margin: 0 0 .75rem;
  padding: .8rem 1rem;
  border-radius: 8px;
  background: var(--white);
  border-left: 5px solid var(--teal);
}

.table-wrap {
  overflow-x: auto;
  margin-bottom: 4rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--white);
}

table {
  width: 100%;
  border-collapse: collapse;
}

th,
td {
  padding: .9rem 1rem;
  text-align: left;
  border-bottom: 1px solid var(--line);
  white-space: nowrap;
}

th {
  background: var(--concrete);
}

.status {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: .2rem .55rem;
  border-radius: 6px;
  font-weight: 800;
}

.status-pending {
  background: #fff4cc;
  color: #594400;
}

.status-published {
  background: #dff2ed;
  color: #075b46;
}

.status-rejected {
  background: #f8d7da;
  color: #7d1320;
}

.site-footer {
  padding: 2rem 1rem;
  border-top: 1px solid var(--line);
  color: var(--muted);
  text-align: center;
}

.site-footer p {
  margin: 0;
}

@media (max-width: 760px) {
  .nav {
    align-items: flex-start;
    flex-direction: column;
    padding: .8rem 0;
  }

  .brand img {
    width: 168px;
  }

  .nav-links {
    width: 100%;
    justify-content: flex-start;
  }

  .hero {
    min-height: auto;
    grid-template-columns: 1fr;
    padding-top: 3rem;
  }

  h1 {
    font-size: 2.6rem;
  }

  h2 {
    font-size: 1.7rem;
  }

  .lead,
  .content-narrow p,
  .description {
    font-size: 1rem;
  }

  .hero-mark {
    justify-self: start;
    width: min(100%, 280px);
  }

  .hero-mark span {
    font-size: 4.1rem;
  }

  .hero-mark strong {
    font-size: 3.2rem;
  }

  .form-layout {
    grid-template-columns: 1fr;
  }

  .detail-nav,
  .pagination {
    align-items: stretch;
    flex-direction: column;
  }

  .detail-nav .button,
  .pagination .button {
    width: 100%;
  }
}
