:root {
  color-scheme: light;
  --ink: #202c5e;
  --body: #252d47;
  --muted: #5a5f6b;
  --paper: #fff;
  --surface: #f1f3f6;
  --line: #dce2ec;
  --edit: #edf2fd;
  --link: #304881;
  --focus: #4261ad;
  font-family: system-ui, sans-serif;
  color: var(--body);
  background: var(--surface);
}
* { box-sizing: border-box; }
body { margin: 0; }
a { color: var(--link); text-underline-offset: .17em; }
button, select, input, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
button:disabled { opacity: .52; cursor: default; }
:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
.intro, main { width: min(100%, 1840px); margin-inline: auto; padding-inline: clamp(14px, 3vw, 45px); }
.intro { display: flex; justify-content: space-between; gap: 18px 30px; align-items: start; padding-block: 26px 20px; }
h1 { margin: 0; font-size: clamp(1.55rem, 2.8vw, 2.35rem); line-height: 1.14; color: var(--ink); letter-spacing: -.025em; }
.intro p { margin: 5px 0 0; font-size: .9rem; line-height: 1.45; }
.intro .snapshot { color: var(--muted); margin-bottom: 9px; }
.actions { display: flex; flex-wrap: wrap; gap: 8px; justify-content: flex-end; }
.actions button, .mobile-save button, .button, .pagination button { border: 1px solid #a4b1cf; border-radius: 6px; background: var(--paper); color: var(--ink); line-height: 1.3; }
.actions button, .mobile-save button, .button { display: inline-block; padding: 10px 14px; white-space: nowrap; font-size: .88rem; font-weight: 640; }
.actions button, .mobile-save button { border-color: var(--ink); background: var(--ink); color: var(--paper); }
.button { text-decoration: none; }
#save-status { flex: 1 0 100%; min-height: 1em; font-size: .79rem; color: var(--muted); text-align: right; }
.toolbar { display: flex; flex-wrap: wrap; align-items: end; gap: 11px 15px; margin-bottom: 12px; }
.toolbar label { display: grid; gap: 4px; font-size: .83rem; font-weight: 650; }
.toolbar select, .toolbar input[type="search"] { display: block; width: min(282px, 100%); min-height: 38px; border: 1px solid #abb5ca; border-radius: 6px; padding: 7px 9px; background: var(--paper); font-size: .9rem; font-weight: 400; }
.toolbar select { text-overflow: ellipsis; }
.toolbar .check { display: flex; align-items: center; min-height: 38px; font-weight: 500; }
.check input { margin: 0 5px 0 0; width: 17px; height: 17px; accent-color: var(--ink); }
#count { margin-left: auto; padding-bottom: 8px; font-size: .86rem; color: var(--muted); white-space: nowrap; }
.pagination { display: flex; align-items: center; justify-content: flex-end; gap: 8px; font-size: .85rem; }
.pagination button { min-width: 37px; min-height: 36px; font-size: 1rem; }
.pagination .sheet { min-width: 53px; text-align: center; }
.pagination.bottom { margin: 14px 0 28px; }
.table-wrap { background: var(--paper); border: 1px solid var(--line); border-radius: 8px; }
table { width: 100%; border-spacing: 0; table-layout: fixed; font-size: .83rem; line-height: 1.43; }
col.page { width: 11%; }
col.place { width: 14%; }
col.photo { width: 6.5%; }
col.alt, col.caption { width: 14%; }
col.title { width: 6.5%; }
col.proposal { width: 8%; }
col.proposal-last { width: 9%; }
th { position: sticky; top: 0; z-index: 2; padding: 10px 8px; text-align: left; font-weight: 690; background: var(--ink); color: white; }
th { overflow-wrap: anywhere; }
.mobile-save { display: none; }
th:first-child { border-top-left-radius: 7px; }
th:last-child { border-top-right-radius: 7px; }
th.editable-head { background: #344681; }
td { padding: 10px 8px; vertical-align: top; border-bottom: 1px solid var(--line); overflow-wrap: anywhere; white-space: pre-wrap; }
td.edit { padding: 8px 5px; background: var(--edit); }
tr:nth-child(even) td:not(.edit) { background: #f8f9fb; }
tr:last-child td { border-bottom: 0; }
tr:last-child td:first-child { border-bottom-left-radius: 7px; }
tr:last-child td:last-child { border-bottom-right-radius: 7px; }
td small, .muted { display: block; color: var(--muted); font-size: .78rem; }
td small { margin-top: 3px; }
td a.thumb { display: block; }
.thumb img { display: block; width: 100%; max-width: 90px; height: 62px; border-radius: 4px; object-fit: cover; background: #e4e8ee; }
.preview-label { display: inline-block; margin-top: 4px; font-size: .76rem; }
td textarea { display: block; width: 100%; min-width: 0; min-height: 63px; border: 1px solid #a4b1cf; border-radius: 5px; background: var(--paper); padding: 6px; resize: vertical; line-height: 1.37; }
td textarea.filled { border-color: #4d63a0; background: #fbfcff; }
.caption-description { display: block; margin-top: 4px; color: var(--muted); }
#empty, noscript p { padding: 18px; margin: 0; }
@media (max-width: 1020px) {
  .intro { flex-wrap: wrap; }
  .actions { justify-content: flex-start; }
  #save-status { text-align: left; }
  .table-wrap { overflow: auto; }
  table { min-width: 1000px; }
}
@media (max-width: 650px) {
  .toolbar > label:not(.check) { flex: 1 1 125px; min-width: 0; }
  .toolbar .check { flex-basis: 100%; min-height: 24px; }
  #count { margin-left: 0; }
  .toolbar .pagination { margin-left: auto; }
  .table-wrap { overflow: visible; background: transparent; border: none; }
  table, tbody { display: block; min-width: 0; }
  colgroup { display: none; }
  thead { position: absolute; width: 1px; height: 1px; padding: 0; overflow: hidden; clip-path: inset(50%); }
  tr { display: grid; grid-template-columns: minmax(0,1fr) 85px; margin-bottom: 11px; background: var(--paper); border: 1px solid var(--line); border-radius: 7px; }
  td { display: block; grid-column: 1 / -1; padding: 8px 10px; border-bottom: 1px solid var(--line); }
  tr:last-child td { border-bottom: 1px solid var(--line); }
  td:nth-child(1), td:nth-child(2) { grid-column: 1; }
  td:nth-child(3) { grid-column: 2; grid-row: 1 / span 2; align-content: center; }
  td:nth-child(3) img { height: 75px; }
  td::before { display: block; margin-bottom: 2px; font-weight: 650; color: var(--ink); content: attr(data-column); }
  td:nth-child(-n+3)::before { display: none; }
  td.edit { padding: 7px 10px; }
  td textarea { font-size: 16px; }
  .has-mobile-save main { padding-bottom: calc(64px + env(safe-area-inset-bottom)); }
  .mobile-save {
    display: flex;
    position: fixed;
    z-index: 3;
    bottom: 0;
    left: 0;
    right: 0;
    justify-content: space-between;
    align-items: center;
    gap: 8px;
    background: var(--paper);
    border-top: 1px solid var(--line);
    padding: 8px 14px calc(8px + env(safe-area-inset-bottom));
    font-size: .84rem;
  }
  td:last-child, tr:last-child td:last-child { border-bottom: 0; border-radius: 0 0 7px 7px; }
  tr:nth-child(even) td:not(.edit) { background: transparent; }
}

[hidden] { display: none !important; }
@media (min-width: 651px) {
  .toolbar > label:first-child { width: 282px; }
  .toolbar > label:nth-child(2) { width: 244px; }
}

#editor-form { display: grid; gap: 4px; font-size: .83rem; font-weight: 650; }
.key-controls { display: flex; flex-wrap: wrap; align-items: stretch; gap: 6px; }
#editor-key { width: min(170px, 100%); padding: 7px 9px; border: 1px solid #abb5ca; border-radius: 6px; background: var(--paper); }
td.edit .saved-value { min-height: 43px; margin: 0; }
@media (max-width: 650px) {
  #editor-key { font-size: 16px; }
}
