/* Files block
   A data screen: sidebar plus a hero panel, a toolbar and a data table.
   Composed from sidebar, input, button, table and pagination under the console
   theme. */

.dp-files-hero {
  margin-bottom: var(--dp-space-8);
  padding: var(--dp-space-10);
  text-align: center;
  background: var(--dp-surface);
  border: 1px solid var(--dp-border);
  border-radius: var(--dp-radius-xl);
}

.dp-files-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: var(--dp-space-2);
  margin-bottom: var(--dp-space-3);
  font-size: var(--dp-text-sm);
  color: var(--dp-text-muted);
}

.dp-files-eyebrow svg {
  width: 1.1rem;
  height: 1.1rem;
}

.dp-files-title {
  margin: 0 0 var(--dp-space-3);
  font-size: var(--dp-text-3xl);
  font-weight: var(--dp-weight-extrabold);
  color: var(--dp-navy);
}

.dp-files-desc {
  max-width: 48ch;
  margin: 0 auto var(--dp-space-6);
  color: var(--dp-text-muted);
}

.dp-files-trash {
  margin: var(--dp-space-4) 0 0;
  font-size: var(--dp-text-sm);
  color: var(--dp-text-muted);
}

.dp-files-trash a {
  color: var(--dp-link);
  font-weight: var(--dp-weight-semibold);
}

.dp-files-toolbar-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--dp-space-4);
  margin-bottom: var(--dp-space-4);
}

.dp-files-count {
  font-size: var(--dp-text-lg);
  font-weight: var(--dp-weight-bold);
  color: var(--dp-navy);
}

.dp-files-count span {
  color: var(--dp-text-muted);
  font-weight: var(--dp-weight-regular);
}

.dp-files-create {
  display: inline-flex;
  align-items: center;
  gap: var(--dp-space-2);
  color: var(--dp-link);
  font-weight: var(--dp-weight-semibold);
  font-size: var(--dp-text-sm);
  text-decoration: none;
}

.dp-files-create svg {
  width: 1.1rem;
  height: 1.1rem;
}

.dp-files-toolbar {
  display: flex;
  gap: var(--dp-space-3);
  margin-bottom: var(--dp-space-4);
}

.dp-files-toolbar .dp-input-group {
  flex: 1;
}

/* Flat data list, like the console Files table (no outer card) */
.dp-files-list {
  width: 100%;
  border-collapse: collapse;
}

.dp-files-list thead th {
  text-align: left;
  padding: var(--dp-space-3) var(--dp-space-4);
  font-size: var(--dp-text-base);
  font-weight: var(--dp-weight-bold);
  color: var(--dp-navy);
  border-bottom: 1px solid var(--dp-border);
  white-space: nowrap;
}

/* Name column takes the remaining width, pushing the rest to the right */
.dp-files-list thead th.dp-col-name {
  width: 100%;
}

.dp-files-list .dp-sort {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.dp-files-list .dp-sort svg {
  width: 0.9rem;
  height: 0.9rem;
}

.dp-files-list tbody td {
  padding: var(--dp-space-4);
  border-bottom: 1px solid var(--dp-border);
  font-size: var(--dp-text-base);
  color: var(--dp-text-muted);
  vertical-align: middle;
  white-space: nowrap;
}

.dp-files-list tbody tr:hover {
  background: var(--dp-surface-subtle);
}

.dp-files-folder {
  display: flex;
  align-items: center;
  gap: var(--dp-space-4);
}

.dp-files-folder b {
  color: var(--dp-navy);
  font-weight: var(--dp-weight-bold);
  font-size: var(--dp-text-base);
}

.dp-files-folder .dp-files-count {
  color: var(--dp-text-muted);
}

/* System folder: icon in a grey rounded chip */
.dp-file-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.25rem;
  height: 2.25rem;
  flex: none;
  border-radius: var(--dp-radius-sm);
  background: var(--dp-neutral-300);
  color: var(--dp-neutral-600);
}

.dp-file-chip svg {
  width: 1.25rem;
  height: 1.25rem;
}

/* User folder: filled periwinkle folder */
.dp-file-folder {
  width: 2.25rem;
  height: 2.25rem;
  flex: none;
  color: #8b93f0;
}

/* File: document with a search badge */
.dp-file-doc {
  width: 2.25rem;
  height: 2.25rem;
  flex: none;
  color: var(--dp-text-subtle);
}

/* Stacked name + source subtitle for dataset files */
.dp-files-filetext {
  display: flex;
  flex-direction: column;
  line-height: 1.3;
}

.dp-files-sub {
  font-size: var(--dp-text-sm);
  font-weight: var(--dp-weight-regular);
  color: var(--dp-text-muted);
}

/* Right-aligned numeric column */
.dp-files-list th[data-align="end"],
.dp-files-list td[data-align="end"] {
  text-align: right;
  font-variant-numeric: tabular-nums;
}

/* The row action menu opens from the right edge */
.dp-files-list .dp-menu-list {
  right: 0;
  left: auto;
}

/* Kebab action button: a bordered square */
.dp-icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.25rem;
  height: 2.25rem;
  border: 1px solid var(--dp-border);
  border-radius: var(--dp-radius-sm);
  background: var(--dp-surface);
  color: var(--dp-text-muted);
  cursor: pointer;
}

.dp-icon-btn:hover {
  background: var(--dp-surface-soft);
  color: var(--dp-navy);
}

.dp-icon-btn svg {
  width: 1.1rem;
  height: 1.1rem;
}

.dp-files-pagination {
  display: flex;
  justify-content: flex-end;
  margin-top: var(--dp-space-5);
}
