﻿/* Local working copies alongside the form lists. */
.drafts-panel { margin: 22px 0 8px; }
.draft-heading { margin: 0 0 12px; font-size: 1.15rem; font-weight: 700; }
.draft-rows {
  margin: 0;
  padding: 0;
  list-style: none;
  border: 1px solid var(--line);
  border-radius: var(--radius-card);
  background: var(--card);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}
.draft-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px 20px;
  padding: 18px;
}
.draft-row + .draft-row { border-top: 1px solid var(--line); }
.draft-info { min-width: 0; }
.draft-title { margin: 0; font-size: 1rem; line-height: 1.4; font-weight: 700; overflow-wrap: anywhere; }
.draft-meta { margin: 5px 0 0; color: var(--muted); font-size: 0.85rem; line-height: 1.5; overflow-wrap: anywhere; }
.draft-permit-note { margin: 7px 0 0; color: var(--warnTx); font-size: 0.88rem; line-height: 1.4; }
.draft-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.draft-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 12px 16px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  color: var(--text);
  font: inherit;
  font-size: 0.92rem;
  font-weight: 600;
  line-height: 1.3;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
}
.draft-action-primary { background: var(--charcoal); border-color: #27272c; color: #fff; }
@media (hover: hover) {
  .draft-action:hover { border-color: #92929b; }
  .draft-action-primary:hover { border-color: #27272c; filter: brightness(1.2); }
}
.draft-recovery { margin-top: 14px; }
.draft-recovery-title {
  min-height: 48px;
  padding: 13px 4px;
  color: var(--muted);
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
}
.draft-recovery[open] .draft-recovery-title { color: var(--text); }
.draft-recovery-note { margin: 0 0 12px; color: var(--muted); font-size: 0.9rem; line-height: 1.5; }
.draft-error { grid-column: 1 / -1; margin: 0; color: var(--badTx); font-size: 0.9rem; line-height: 1.5; }
.drafts-panel > .draft-error { padding: 14px; border: 1px solid var(--badBd); border-radius: 12px; background: var(--badBg); }
@media (max-width: 640px) {
  .draft-row { grid-template-columns: minmax(0, 1fr); padding: 16px; }
  .draft-actions { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .draft-action { min-width: 0; padding: 12px 10px; }
  .draft-recovery-row .draft-actions { grid-template-columns: minmax(0, 1fr); }
}
