.sync-center {
  margin: 0 0 1rem;
  padding: .85rem 1rem;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--panel);
}

.sync-center > header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: .7rem;
}

.sync-center h2 {
  margin: 0;
  font-size: 1rem;
  letter-spacing: -.02em;
}

.sync-center header p {
  margin: .12rem 0 0;
  color: var(--muted);
  font-size: .78rem;
}

.sync-center-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: .5rem;
}

.sync-center-actions button { padding: .38rem .6rem; font-size: .76rem; white-space: nowrap; }

.sync-error-badge {
  padding: .28rem .55rem;
  border-radius: 999px;
  background: #522724;
  color: #ffc4bf;
  font-size: .75rem;
  font-weight: 750;
}

.sync-error-badge.due {
  background: #4b3919;
  color: #ffd98c;
}

.sync-status-rows {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: .65rem;
}

.sync-status-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: .7rem;
  min-width: 0;
  padding: .65rem .7rem;
  border-radius: 10px;
  background: #091722;
}

.sync-status-copy {
  min-width: 0;
  flex: 1;
}

.sync-status-row strong,
.sync-status-row span {
  display: block;
}

.sync-status-row strong { font-size: .86rem; }
.sync-status-row span {
  overflow: hidden;
  color: var(--muted);
  font-size: .74rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.sync-status-row .sync-state {
  flex: 0 0 auto;
  color: var(--text);
  font-weight: 750;
}

.sync-status-row.error .sync-state,
.sync-status-row.partial .sync-state { color: var(--red); }
.sync-status-row.success .sync-state { color: var(--green); }

.sync-progress {
  height: 3px;
  margin-top: .45rem;
  overflow: hidden;
  border-radius: 3px;
  background: #203440;
}

.sync-progress span {
  height: 100%;
  border-radius: inherit;
  background: var(--green);
  transition: width .35s ease-out;
}

.sync-status-row.error .sync-progress span,
.sync-status-row.partial .sync-progress span { background: var(--red); }

@media (max-width: 820px) {
  .sync-center { margin: .2rem 0 .85rem; padding: .75rem; }
  .sync-center > header { align-items: flex-start; }
  .sync-center-actions { align-items: flex-end; flex-direction: column; }
  .sync-status-rows { grid-template-columns: 1fr; gap: .45rem; }
  .sync-status-row { padding: .58rem .65rem; }
  .app-toolbar #state { display: none; }
}
