:root {
  color-scheme: light;
  font-family: Arial, Helvetica, sans-serif;
  background: #f4f6f8;
  color: #20242a;
}

body {
  margin: 0;
}

.page {
  min-height: 100vh;
  padding: 28px;
}

.toolbar {
  align-items: center;
  display: flex;
  gap: 16px;
  justify-content: space-between;
  margin: 0 0 18px;
}

h1 {
  font-size: 26px;
  margin: 0;
}

h2 {
  font-size: 18px;
  margin: 0 0 12px;
}

.panel {
  background: #ffffff;
  border: 1px solid #d8dee8;
  border-radius: 8px;
  overflow: hidden;
}

.controls {
  display: grid;
  gap: 16px;
  grid-template-columns: minmax(220px, 1fr) 140px minmax(220px, 1fr) minmax(240px, 1fr);
  padding: 18px;
}

label span {
  display: block;
  font-size: 13px;
  font-weight: 700;
  margin-bottom: 6px;
}

select,
input[type="search"] {
  background: #ffffff;
  border: 1px solid #c6ced9;
  border-radius: 6px;
  box-sizing: border-box;
  color: #20242a;
  font-size: 15px;
  height: 40px;
  padding: 0 10px;
  width: 100%;
}

.selection-bar {
  align-items: center;
  background: #f8fafc;
  border-bottom: 1px solid #d8dee8;
  border-top: 1px solid #d8dee8;
  display: flex;
  gap: 14px;
  padding: 12px 18px;
}

.select-all {
  align-items: center;
  display: inline-flex;
  gap: 8px;
}

.select-all span {
  margin: 0;
}

.button {
  align-items: center;
  border-radius: 6px;
  cursor: pointer;
  display: inline-flex;
  font-size: 14px;
  font-weight: 700;
  height: 40px;
  justify-content: center;
  padding: 0 14px;
  text-decoration: none;
}

.button.primary {
  background: #2364aa;
  border: 1px solid #2364aa;
  color: #ffffff;
}

.button.secondary {
  background: #ffffff;
  border: 1px solid #b9c3d0;
  color: #20242a;
}

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

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

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

th,
td {
  border-bottom: 1px solid #e5e9ef;
  padding: 11px 12px;
  text-align: left;
  vertical-align: middle;
}

th {
  background: #eef2f6;
  font-size: 13px;
}

td {
  font-size: 14px;
}

tbody tr:hover {
  background: #f7fbff;
}

.record-row {
  background: #ffffff;
}

.row-actions {
  align-items: center;
  display: flex;
  gap: 8px;
}

.collapse-toggle {
  background: #ffffff;
  border: 1px solid #b9c3d0;
  border-radius: 6px;
  color: #20242a;
  cursor: pointer;
  font-size: 16px;
  font-weight: 700;
  height: 28px;
  line-height: 1;
  padding: 0;
  width: 28px;
}

.collapse-toggle:hover {
  background: #eef2f6;
}

.titles-row.is-collapsed {
  display: none;
}

.titles-row > td {
  background: #fbfcfe;
  padding-bottom: 16px;
  padding-top: 0;
}

.titles-table {
  border: 1px solid #dde3ec;
  border-radius: 6px;
  min-width: 980px;
  overflow: hidden;
}

.titles-table th {
  background: #f4f7fb;
}

.titles-table th,
.titles-table td {
  font-size: 13px;
  padding: 8px 10px;
}

.titles-table tr:last-child td {
  border-bottom: 0;
}

.title-row.is-disabled {
  color: #8a94a6;
}

.title-check:disabled,
.record-check:disabled {
  cursor: not-allowed;
}

.empty {
  color: #667085;
  padding: 24px;
  text-align: center;
}

.actions {
  display: flex;
  justify-content: flex-end;
  padding: 18px;
}

.alert {
  background: #fff4df;
  border: 1px solid #e6b75f;
  border-radius: 8px;
  margin-bottom: 16px;
  padding: 12px 14px;
}

.alert ul,
.results ul {
  margin: 8px 0 0;
  padding-left: 20px;
}

.results {
  background: #ecf8f1;
  border: 1px solid #91cfaa;
  border-radius: 8px;
  margin-bottom: 16px;
  padding: 14px;
}

.results a {
  color: #165c2f;
  font-weight: 700;
}

.paths {
  color: #5f6b7a;
  display: grid;
  font-size: 12px;
  gap: 6px;
  margin-top: 14px;
  overflow-wrap: anywhere;
}

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

  .toolbar,
  .selection-bar {
    align-items: stretch;
    flex-direction: column;
  }

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