/* Dashboard (redesign) — page-specific layout.
   Shared primitives (btn, badge, card, eyebrow, secHead, srcChip, …)
   live in src/styles/redesign.module.css. Tokens in tokens.css. */

.wrap {
  max-width: 1120px;
  margin: 0 auto;
  padding: 8px 24px 80px;
}

/* ---- hero ---- */
.dashHero {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 26px;
  flex-wrap: wrap;
}
.dashHeroActions {
  display: flex;
  gap: 10px;
}
.quickSearch {
  display: flex;
  align-items: center;
  gap: 9px;
  height: 40px;
  padding: 0 6px 0 13px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 11px;
  color: var(--text-faint);
  transition: border-color 0.15s, box-shadow 0.15s;
  min-width: 280px;
}
.quickSearch:focus-within {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px var(--primary-soft);
}
.quickSearch input {
  flex: 1;
  min-width: 0;
  border: 0;
  outline: 0;
  background: transparent;
  font-family: var(--font-ui);
  font-size: 14px;
  color: var(--text);
}
.quickSearch input::placeholder { color: var(--text-faint); }
.qsGo {
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border: 0;
  border-radius: 8px;
  cursor: pointer;
  background: var(--primary);
  color: var(--on-primary);
}
.qsGo:hover { background: var(--primary-strong); }

/* ---- stat strip ---- */
.statGrid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
  margin-bottom: 30px;
}
.statTile {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 18px;
}
.statTop {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 30px;
}
.statIco {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 11px;
}
.statValue {
  font-family: var(--font-display);
  font-size: 32px;
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1;
  color: var(--text);
}
.statLabel {
  font-size: 13px;
  color: var(--text-dim);
}
.emptyVal {
  font-family: var(--font-display);
  font-size: 32px;
  font-weight: 600;
  line-height: 1;
  color: var(--text-faint);
}

/* ---- main split ---- */
.dashSplit {
  display: grid;
  grid-template-columns: 1fr 360px;
  gap: 26px;
  align-items: start;
}
.dashRail {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

/* ---- recent table ---- */
.tbl {
  width: 100%;
  border-collapse: collapse;
}
.tbl th {
  text-align: left;
  font-family: var(--font-mono);
  font-size: 10.5px;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-faint);
  padding: 0 14px 10px;
  border-bottom: 1px solid var(--border-soft);
}
.tbl td {
  padding: 13px 14px;
  border-bottom: 1px solid var(--border-soft);
  font-size: 13.5px;
  vertical-align: middle;
}
.tbl tbody tr {
  transition: background 0.12s;
  cursor: pointer;
}
.tbl tbody tr:hover { background: var(--surface-2); }
.tbl tbody tr:last-child td { border-bottom: 0; }
.alignRight { text-align: right; }

.docCell {
  display: flex;
  align-items: center;
  gap: 11px;
}
.docDot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
}
.docTitle {
  display: block;
  max-width: 340px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  font-size: 13.5px;
}

/* ---- projects rail ---- */
.projList {
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.projScroll {
  max-height: 416px;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 6px;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.projRow {
  display: flex;
  align-items: center;
  gap: 11px;
  width: 100%;
  text-align: left;
  background: transparent;
  border: 0;
  cursor: pointer;
  padding: 10px 11px;
  border-radius: 9px;
  transition: background 0.12s;
}
.projRow:hover { background: var(--surface-2); }
.projDot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  flex-shrink: 0;
}
.projName {
  flex: 1;
  min-width: 0;
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.projCounts {
  font-family: var(--font-mono);
  font-size: 12px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
  color: var(--text-faint);
}
.trashCount {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  color: var(--text-faint);
}
.projBar {
  margin-top: 11px;
  height: 5px;
  border-radius: 3px;
  background: var(--surface-2);
  overflow: hidden;
}
.projBar span {
  display: block;
  height: 100%;
  border-radius: 3px;
  transition: width 0.6s cubic-bezier(0.2, 0.7, 0.3, 1);
}
.projChev {
  color: var(--text-faint);
  opacity: 0;
  transition: opacity 0.12s;
  flex-shrink: 0;
}
.projRow:hover .projChev { opacity: 1; }
.projFoot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 11px 14px;
  font-family: var(--font-mono);
  font-size: 11.5px;
  color: var(--text-dim);
  background: var(--surface-2);
  border-top: 1px solid var(--border-soft);
}

/* ---- responsive ---- */
@media (max-width: 920px) {
  .statGrid { grid-template-columns: repeat(2, 1fr); }
  .dashSplit { grid-template-columns: 1fr; }
}
