/* Give the file list the extra space on wide screens. */
html:has(.ex-main) { scrollbar-gutter: stable; }
.ex-main, .ex-header-inner { max-width: 93.75rem; }
@media (min-width: 64rem) {
  .ex-main, .ex-header-inner { width: 93%; }
}
.archive-columns { grid-template-columns: minmax(0, 1fr) clamp(15rem, 20vw, 21rem); }
.file-list .ex-table { table-layout: fixed; }
.file-list th.col-name { width: auto; }
.file-list .col-check { width: 2.75rem; padding-inline: .5rem; }
.file-list .col-date { width: 10rem; }
.file-list .col-type {
  width: 9rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.file-list .col-act { width: 9rem; padding-inline: .5rem; }
.file-list .name-cell .label {
  min-width: 0;
  white-space: normal;
  word-break: keep-all;
  overflow-wrap: anywhere;
}
@media (max-width: 60rem) {
  .archive-columns { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 40rem) {
  .file-list .ex-table, .file-list thead, .file-list tbody { display: block; }
  .file-list thead tr {
    display: flex;
    align-items: center;
    background: #f8fafc;
  }
  .file-list thead .col-name { flex: 1; }
  .file-list thead .col-date { width: auto; }
  .file-list thead .col-act { display: none; }
  .file-list .row-item {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    grid-template-areas: "name name" "date actions";
    align-items: center;
    gap: .3rem .5rem;
    padding: .65rem .7rem;
    border-top: 1px solid var(--border);
  }
  body[data-can-move="1"] .file-list .row-item {
    grid-template-columns: 1.25rem minmax(0, 1fr) auto;
    grid-template-areas: "check name name" ". date actions";
  }
  .file-list .row-item td { width: auto; padding: 0; border: 0; min-width: 0; }
  .file-list .row-item td:not([class]) { grid-area: name; }
  .file-list .row-item .col-check { grid-area: check; }
  .file-list .row-item .col-check input { margin: 0; }
  .file-list .row-item .col-date { grid-area: date; font-size: .78rem; }
  .file-list .row-item .col-act { grid-area: actions; }
  .file-list .row-parent .col-date, .file-list .row-parent .col-act { display: none; }
  .file-list .loading-cell { display: block; }
}
@media (max-width: 26rem) {
  .ex-main, .ex-header-inner { padding-inline: .625rem; }
  body[data-can-move="1"] .file-list .row-item {
    grid-template-areas: "check name name" "date date actions";
  }
}
