:root {
  color-scheme: light;
  --bg: #f7f7f4;
  --ink: #202124;
  --muted: #64635f;
  --line: #d9d6cd;
  --panel: #ffffff;
  --accent: #0f766e;
  --accent-soft: #d8eee9;
  --warn: #9a3412;
  --warn-soft: #fff1df;
  --blue: #244c8a;
  --rose: #9f294c;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Sans TC", sans-serif;
  line-height: 1.5;
}

button,
input,
select,
textarea {
  font: inherit;
}

.topbar {
  align-items: center;
  background: var(--panel);
  border-bottom: 1px solid var(--line);
  display: flex;
  justify-content: space-between;
  gap: 24px;
  min-height: 96px;
  padding: 18px clamp(18px, 4vw, 48px);
}

.eyebrow {
  color: var(--accent);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0;
  margin: 0 0 4px;
  text-transform: uppercase;
}

h1,
h2,
p {
  margin-top: 0;
}

h1 {
  font-size: clamp(1.6rem, 2.2rem, 2.2rem);
  line-height: 1.1;
  margin-bottom: 0;
}

h2 {
  font-size: 1.2rem;
  line-height: 1.25;
  margin-bottom: 8px;
}

main {
  padding-bottom: 48px;
}

.run-status {
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--muted);
  flex: 0 0 auto;
  font-size: 0.9rem;
  padding: 8px 14px;
}

.run-status.ok {
  background: var(--accent-soft);
  border-color: #9fd4ca;
  color: #12534e;
}

.run-status.warn {
  background: var(--warn-soft);
  border-color: #fdba74;
  color: var(--warn);
}

.summary-band,
.rating-section {
  border-bottom: 1px solid var(--line);
  padding: 24px clamp(18px, 4vw, 48px);
}

.summary-band {
  background: #eef1ed;
}

.summary-band p,
.section-heading p {
  color: var(--muted);
  margin-bottom: 0;
}

.photo-list {
  display: grid;
  gap: 0;
}

.photo-entry {
  background: var(--panel);
  border-bottom: 1px solid var(--line);
  display: grid;
  gap: 18px;
  grid-template-columns: minmax(220px, 0.8fr) minmax(320px, 1.2fr);
  padding: 28px clamp(18px, 4vw, 48px);
}

.photo-copy {
  align-self: start;
}

.position {
  color: var(--rose);
  font-size: 0.85rem;
  font-weight: 700;
  margin-bottom: 6px;
}

.byline {
  color: var(--muted);
  margin-bottom: 0;
}

.photo-entry img {
  aspect-ratio: 3 / 2;
  background: #e6e2da;
  border: 1px solid var(--line);
  border-radius: 6px;
  display: block;
  grid-column: 2;
  grid-row: 1 / span 3;
  height: auto;
  object-fit: cover;
  width: 100%;
}

.rating-inline {
  align-self: start;
  border-left: 4px solid var(--accent);
  color: var(--muted);
  padding-left: 12px;
}

.rating-inline a {
  color: var(--blue);
  font-weight: 700;
}

.details {
  display: grid;
  gap: 10px;
  margin: 0;
}

.details dt {
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 700;
  margin: 0;
}

.details dd {
  margin: 0;
}

.details ul {
  margin: 0;
  padding-left: 18px;
}

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

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

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

th {
  background: #ece9e1;
  font-size: 0.88rem;
}

td:first-child {
  font-weight: 700;
  min-width: 180px;
}

select,
input[type="text"],
textarea {
  border: 1px solid var(--line);
  border-radius: 6px;
  min-height: 36px;
  padding: 7px 9px;
  width: 100%;
}

textarea {
  min-height: 64px;
  resize: vertical;
}

.check-cell {
  text-align: center;
}

.check-cell input {
  min-height: 20px;
  width: 20px;
}

@media (max-width: 800px) {
  .topbar {
    align-items: flex-start;
    flex-direction: column;
  }

  .photo-entry {
    grid-template-columns: 1fr;
  }

  .photo-entry img {
    grid-column: 1;
    grid-row: auto;
  }
}
