/* Nemo file manager */
.nemo { display: flex; flex-direction: column; height: 100%; min-height: 0; }

.nemo-toolbar {
  display: flex; align-items: center; gap: 4px;
  padding: 5px 8px;
  border-bottom: 1px solid var(--separator);
  flex: none;
}
.nemo-pathbar {
  flex: 1 1 auto;
  min-width: 0;
  display: flex; align-items: center; gap: 2px;
  background: var(--entry-bg);
  border: 1px solid var(--entry-border);
  border-radius: var(--r-entry);
  height: 30px;
  padding: 0 6px;
  overflow: hidden;
}
.nemo-pathbar .crumb {
  padding: 3px 7px;
  border-radius: 4px;
  display: flex; align-items: center; gap: 5px;
  white-space: nowrap;
  font-size: var(--fs-small);
  flex: 0 1 auto;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 140px;
}
.nemo-pathbar .crumb:hover { background: var(--hover-fill); }
.nemo-pathbar .crumb.current { background: var(--hover-fill); font-weight: 700; }
.nemo-pathbar .crumb-sep { color: var(--text-insensitive); display: grid; place-items: center; }
.nemo-pathbar input {
  flex: 1; border: none; outline: none; background: transparent;
  font-size: var(--fs-small); min-width: 60px;
}

.nemo-main { flex: 1; display: flex; min-height: 0; }
.nemo-sidebar {
  width: 175px; flex: none;
  background: var(--sidebar-bg);
  border-right: 1px solid var(--separator);
  overflow-y: auto;
  padding: 8px 6px;
}
.nb-section {
  font-size: 10.5px; font-weight: 700; letter-spacing: .4px;
  color: var(--text-secondary);
  text-transform: uppercase;
  padding: 10px 10px 4px;
}
.nb-item {
  display: flex; align-items: center; gap: 9px;
  width: 100%;
  padding: 5px 9px;
  border-radius: var(--r-item);
  font-size: var(--fs-ui);
  text-align: left;
}
.nb-item svg { color: var(--text-secondary); flex: none; }
.nb-item:hover { background: rgba(48, 48, 48, .08); }
.nb-item.selected { background: var(--hover-fill); font-weight: 700; }
.nb-item.selected svg { color: var(--accent); }
.nb-item .nb-count { margin-left: auto; font-size: 10.5px; color: var(--text-insensitive); }

.nemo-view { flex: 1; overflow-y: auto; position: relative; background: var(--base-bg); outline: none; }

/* icon view */
.nemo-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, 104px);
  gap: 6px;
  padding: 12px;
  align-content: start;
}
.nv-cell {
  width: 104px;
  padding: 8px 4px 7px;
  border-radius: var(--r-item);
  display: flex; flex-direction: column; align-items: center; gap: 6px;
  border: 1px solid transparent;
}
.nv-cell:hover { background: rgba(48, 48, 48, .07); }
.nv-cell.selected { background: var(--accent-tint); border-color: var(--accent); }
.nv-cell .nv-icon { width: 50px; height: 50px; display: grid; place-items: center; }
.nv-cell .nv-icon img { max-width: 46px; max-height: 46px; border-radius: 3px; box-shadow: 0 1px 3px rgba(0,0,0,.25); }
.nv-cell .nv-label {
  font-size: var(--fs-xsmall);
  text-align: center;
  line-height: 1.25;
  max-width: 98px;
  overflow-wrap: break-word;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.nv-cell.renaming .nv-label { display: none; }
.nv-rename-input {
  font-size: var(--fs-xsmall);
  width: 96px;
  text-align: center;
  border: 1px solid var(--accent);
  border-radius: 3px;
  padding: 1px 3px;
  outline: none;
}

/* list view */
.nemo-list { width: 100%; border-collapse: collapse; font-size: var(--fs-ui); }
.nemo-list th {
  position: sticky; top: 0;
  background: var(--window-bg);
  text-align: left;
  font-weight: 700; font-size: var(--fs-small);
  padding: 6px 12px;
  border-bottom: 1px solid var(--separator);
  z-index: 2;
}
.nemo-list th.sortable:hover { color: var(--accent); }
.nemo-list td { padding: 4px 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 340px; }
.nemo-list tr.row { cursor: default; }
.nemo-list tr.row:hover td { background: rgba(48, 48, 48, .06); }
.nemo-list tr.row.selected td { background: var(--accent-tint); }
.nemo-list .cell-name { display: flex; align-items: center; gap: 9px; }
.nemo-list .cell-name img { width: 22px; height: 22px; object-fit: cover; border-radius: 2px; }
.nemo-list td.dimtd { color: var(--text-secondary); font-size: var(--fs-small); }

/* trash banner + empty state */
.nemo-trashbar {
  display: flex; align-items: center; justify-content: space-between;
  padding: 8px 14px;
  background: var(--hover-fill);
  border-bottom: 1px solid var(--separator);
  font-size: var(--fs-small);
  flex: none;
}
.nemo-drop-target { outline: 2px dashed var(--accent); outline-offset: -4px; }

@media (max-width: 760px) {
  .nemo-sidebar { display: none; }
}
@media (max-width: 520px) {
  .nemo-toolbar .opt-nav,
  .headerbar .opt-nav { display: none; }
}
