:root {
  color-scheme: light;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: #f5f7f8;
  color: #17212b;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: #f5f7f8;
}

button,
input,
select {
  font: inherit;
}

.page {
  width: min(100%, 760px);
  margin: 0 auto;
  padding: 18px 14px 28px;
}

.panel {
  background: #ffffff;
  border: 1px solid #d9e0e5;
  border-radius: 8px;
  padding: 18px;
}

.title {
  margin: 0 0 6px;
  font-size: 24px;
  line-height: 1.2;
}

.muted {
  color: #607080;
  font-size: 14px;
}

.field {
  display: grid;
  gap: 7px;
  margin-top: 16px;
}

.field span {
  font-weight: 650;
}

.input,
.select {
  width: 100%;
  min-height: 46px;
  border: 1px solid #c9d3dc;
  border-radius: 6px;
  padding: 10px 12px;
  background: #fff;
}

.input:focus,
.select:focus {
  outline: 2px solid #2f7d6b;
  outline-offset: 1px;
}

.button {
  width: 100%;
  min-height: 48px;
  border: 0;
  border-radius: 6px;
  background: #1f6f5f;
  color: #fff;
  font-weight: 750;
  cursor: pointer;
}

.button:disabled {
  cursor: not-allowed;
  opacity: 0.65;
}

.secondary {
  background: #e8eef1;
  color: #17212b;
}

.message {
  margin-top: 14px;
  padding: 10px 12px;
  border-radius: 6px;
  font-size: 14px;
}

.message.error {
  background: #ffecec;
  color: #8a1f1f;
  border: 1px solid #f5c2c2;
}

.message.ok {
  background: #eaf7ef;
  color: #16633a;
  border: 1px solid #bfe6ce;
}

.preview-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
  margin-top: 10px;
}

.preview-grid img,
.voucher-images img,
.thumb {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #f0f3f5;
  border: 1px solid #dbe3e8;
  border-radius: 6px;
}

.preview-grid img {
  aspect-ratio: 3 / 4;
  max-height: 150px;
}

.voucher {
  background: #fff;
  border: 2px solid #2f7d6b;
}

.success-mark {
  display: inline-block;
  margin-bottom: 8px;
  padding: 5px 9px;
  border-radius: 999px;
  background: #e8f6ef;
  color: #16633a;
  font-weight: 750;
  font-size: 14px;
}

.submission-no {
  margin: 10px 0 14px;
  padding: 14px;
  border-radius: 8px;
  background: #17212b;
  color: #fff;
  text-align: center;
}

.submission-no strong {
  display: block;
  margin-top: 4px;
  font-size: 28px;
  letter-spacing: 0;
  word-break: break-word;
}

.info-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.info-item {
  border: 1px solid #dce4e8;
  border-radius: 6px;
  padding: 10px;
}

.info-item span {
  display: block;
  color: #607080;
  font-size: 12px;
}

.info-item strong {
  display: block;
  margin-top: 4px;
  font-size: 16px;
  word-break: break-word;
}

.voucher-images {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
  align-items: center;
  justify-content: center;
  margin-top: 14px;
}

.voucher-images a {
  display: block;
  min-height: 92px;
}

.footer-note {
  margin-top: 14px;
  text-align: center;
  font-weight: 750;
}

.admin-shell {
  width: min(100%, 1160px);
}

.toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}

.table-wrap {
  overflow-x: auto;
}

table {
  width: 100%;
  border-collapse: collapse;
  min-width: 900px;
}

th,
td {
  border-bottom: 1px solid #e1e7eb;
  padding: 10px;
  text-align: left;
  vertical-align: middle;
  font-size: 14px;
}

th {
  color: #526272;
  background: #f8fafb;
}

.row-action {
  width: auto;
  min-height: 36px;
  padding: 0 12px;
}

.thumb {
  width: 54px;
  height: 54px;
}

.detail-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.admin-images {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 10px;
}

.admin-images img {
  width: 100%;
  max-height: 360px;
  object-fit: contain;
  border: 1px solid #dce4e8;
  border-radius: 6px;
  background: #f0f3f5;
}

@media (max-width: 560px) {
  .page {
    padding: 10px 8px 18px;
  }

  .panel {
    padding: 14px;
  }

  .title {
    font-size: 21px;
  }

  .info-grid {
    grid-template-columns: 1fr 1fr;
    gap: 7px;
  }

  .info-item {
    padding: 8px;
  }

  .info-item strong {
    font-size: 14px;
  }

  .submission-no strong {
    font-size: 22px;
  }

  .voucher-images {
    gap: 5px;
  }

  .voucher-images a {
    min-height: 72px;
  }

  .preview-grid {
    gap: 5px;
  }

  .detail-grid {
    grid-template-columns: 1fr;
  }
}
