/* --- manutenção ----------------------------------------------------------------- */
.timeline {
  position: relative;
  margin: 0;
  padding: 0;
  list-style: none;
}
.timeline::before {
  content: "";
  position: absolute;
  left: 104px;
  top: 6px;
  bottom: 6px;
  width: 2px;
  background: var(--line);
}
.tl-item {
  position: relative;
  display: grid;
  grid-template-columns: 90px 1fr;
  gap: var(--s-7);
  padding-bottom: var(--s-4);
}
.tl-item::before {
  content: "";
  position: absolute;
  left: 99px;
  top: 16px;
  width: 12px;
  height: 12px;
  border: 2px solid var(--accent);
  border-radius: 50%;
  background: var(--bg);
}
.tl-item time {
  padding-top: var(--s-4);
  font: var(--fs-1) var(--mono);
  color: var(--muted);
  text-align: right;
}
.tl-card {
  display: flex;
  flex-direction: column;
  gap: var(--s-3);
  padding: var(--s-4) var(--s-4);
  border: 1px solid var(--line);
  border-radius: var(--r-2);
  background: var(--surface);
  cursor: pointer;
  min-width: 0;
}
.tl-card:hover {
  border-color: var(--line-2);
}
.tl-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-3);
}
.tl-actions {
  display: flex;
  gap: var(--s-1);
}
.tl-actions .icon-btn {
  width: var(--h-2);
  min-height: var(--h-2);
  border-color: transparent;
  background: none;
}
.tl-card p {
  color: var(--muted);
}
.chips-bar {
  display: flex;
  gap: var(--s-3);
  margin-bottom: var(--s-5);
  overflow-x: auto;
  scrollbar-width: none;
}
.chips-bar .chip {
  flex: none;
}
.journal-month + .journal-month {
  margin-top: var(--s-6);
}
.journal-month h2 {
  display: flex;
  align-items: baseline;
  gap: var(--s-3);
  margin-bottom: var(--s-3);
  font-size: var(--fs-2);
  font-weight: 650;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.07em;
}
.journal-month h2 span {
  font: var(--fs-1) var(--mono);
  color: var(--faint);
}
.journal {
  border: 1px solid var(--line);
  border-radius: var(--r-3);
  background: var(--surface);
}
.journal-row {
  display: grid;
  grid-template-columns: 110px minmax(0, 1fr) minmax(0, auto) auto;
  align-items: center;
  gap: var(--s-5);
  padding: var(--s-4) var(--s-5);
  border-top: 1px solid var(--line);
  cursor: pointer;
}
.journal-row:first-child {
  border-top: 0;
}
.journal-row:hover {
  background: var(--surface-2);
}
.journal-row time {
  display: flex;
  align-items: baseline;
  gap: var(--s-3);
}
.journal-row time b {
  font: 750 var(--fs-6) var(--mono);
  color: var(--ink);
}
.journal-row time small {
  font: var(--fs-2) var(--sans);
  color: var(--muted);
}
.j-main {
  display: flex;
  flex-direction: column;
  min-width: 0;
}
/* v5.28.0 (X2): a linha abre a manutenção com o rato; pelo teclado e nos leitores de ecrã é este
   botão (o equipamento e o tipo), com o botão dos anexos ao lado e não dentro dele. */
.j-open {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  min-width: 0;
  max-width: 100%;
  padding: 0;
  border: 0;
  background: none;
  text-align: left;
  white-space: normal;
}
.j-open:hover {
  background: none;
}
.j-main p {
  color: var(--muted);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.report {
  display: grid;
  grid-template-columns: minmax(260px, 340px) minmax(0, 1fr);
  gap: var(--s-5);
  align-items: start;
}
.report > *,
.dash > * {
  min-width: 0;
}
.report-side .panel + .panel,
.report-main .panel + .panel {
  margin-top: var(--s-5);
}
.prose {
  white-space: pre-wrap;
}
.checklist {
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
  margin: 0;
  padding: 0;
  list-style: none;
}
.checklist li {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  color: var(--faint);
}
.checklist li i {
  width: 16px;
  height: 16px;
  border: 1.5px solid var(--line-2);
  border-radius: var(--r-1);
}
.checklist li.done {
  color: var(--ink);
}
.checklist li.done .ico {
  color: var(--good);
}
.diag + .diag {
  margin-top: var(--s-5);
}
.diag h3 {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  margin-bottom: var(--s-3);
  font-size: var(--fs-2);
}
.table-scroll {
  max-width: 100%;
  overflow-x: auto;
}
table {
  width: 100%;
  border-collapse: collapse;
  font-size: var(--fs-2);
}
th {
  padding: var(--s-2) var(--s-3);
  border-bottom: 1px solid var(--line-2);
  color: var(--faint);
  font-size: var(--fs-1);
  font-weight: 650;
  text-align: left;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  white-space: nowrap;
}
td {
  padding: var(--s-3) var(--s-3);
  border-bottom: 1px solid var(--line);
  font-size: var(--fs-2);
}
tr:last-child td {
  border-bottom: 0;
}
/* v5.15.0 (ponto 10): a pesquisa no diário e os chips por tipo */
.journal-filters {
  display: flex;
  flex-direction: column;
  gap: var(--s-3);
  margin: calc(var(--s-2) * -1) 0 var(--s-5);
}
.journal-filters .search-field {
  max-width: 520px;
}
.journal-filters .chips-bar {
  align-items: center;
  flex-wrap: wrap;
  margin-bottom: 0;
}
.chips-label {
  color: var(--muted);
  font-size: var(--fs-2);
}
/* v6.41.0 (proposta 9.17): os filtros de equipamento e período da linha do tempo de todo o homelab */
.crono-selects {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-4);
  color: var(--muted);
  font-size: var(--fs-2);
}
.crono-selects select {
  margin-left: var(--s-2);
  max-width: 100%;
}
.crono-eq {
  font-size: inherit;
}

.calendar-scroll {
  overflow-x: auto;
}
.calendar-grid {
  width: 100%;
  min-width: 38rem;
  table-layout: fixed;
  border-collapse: collapse;
}
.calendar-grid th,
.calendar-grid td {
  border: 1px solid var(--line);
  padding: var(--s-2);
}
.calendar-grid th {
  text-align: left;
}
.calendar-grid abbr {
  text-decoration: none;
}
.calendar-grid td {
  height: 3rem;
  vertical-align: top;
}
.calendar-blank {
  background: var(--surface-2);
}
.calendar-grid time[aria-current="date"] {
  color: var(--accent);
  font-weight: 650;
}
.calendar-grid ul {
  margin: var(--s-2) 0 0;
  padding: 0;
  list-style: none;
}
.calendar-grid li {
  overflow-wrap: anywhere;
  margin-bottom: var(--s-2);
  padding: var(--s-1) var(--s-2);
  border-radius: var(--r-1);
  background: var(--surface-2);
  font-size: var(--fs-1);
}
