.download-error-dialog {
  box-sizing: border-box;
  width: min(480px, calc(100vw - 32px));
  max-height: calc(100dvh - 32px);
  overflow: auto;
  padding: 28px;
  border: 1px solid #3f3f46;
  border-radius: 20px;
  background: #18181b;
  color: #fafafa;
  font: inherit;
}
.download-error-dialog::backdrop { background: rgba(0, 0, 0, .65); }
.download-error-dialog h2 { margin: 0 0 16px; font-size: 24px; color: inherit; }
.download-error-dialog p { margin: 0 0 24px; line-height: 1.6; overflow-wrap: anywhere; }
.download-error-actions { display: flex; flex-wrap: wrap; gap: 12px; }
.download-error-actions button, .download-error-actions a {
  padding: 12px 18px;
  border: 1px solid #71717a;
  border-radius: 10px;
  font: inherit;
  text-decoration: none;
  cursor: pointer;
  background: transparent;
  color: inherit;
}
.download-error-actions button:not([data-report-problem]) { background: #fafafa; color: #18181b; }
.download-error-actions :focus-visible { outline: 3px solid #86efac; outline-offset: 3px; }
html[data-theme="light"] .download-error-dialog { background: #fff; color: #18181b; border-color: #d4d4d8; }

.download-error-actions [hidden] { display: none !important; }

.download-error-dialog { position: relative; }
.download-error-dialog h2 { padding-right: 24px; }
.download-error-close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 32px;
  height: 32px;
  padding: 0;
  display: grid;
  place-items: center;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: inherit;
  opacity: .65;
  font: inherit;
  font-size: 24px;
  cursor: pointer;
}
.download-error-close:hover { opacity: 1; background: rgba(128,128,128,.12); }
.download-error-actions { flex-wrap: nowrap; gap: 10px; }
.download-error-actions button, .download-error-actions a {
  flex: 1;
  padding: 12px 10px;
  text-align: center;
  font-weight: 600;
  font-size: 14px;
  line-height: 1.4;
}
.download-error-actions button[data-network-retry] { background: #347e2a; color: #fff; border-color: #347e2a; }
.download-error-actions a { border-color: rgba(128,128,128,.35); }
.download-error-support { margin-top: 20px; font-size: 12px; line-height: 1.7; color: #a1a1aa; }
.download-error-support button {
  display: inline;
  border: 0;
  padding: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  text-decoration: underline;
  text-underline-offset: 3px;
  cursor: pointer;
}
.download-error-dialog :focus-visible { outline: 3px solid #86efac; outline-offset: 3px; }
html[data-theme="light"] .download-error-support { color: #64646e; }
@media (max-width: 480px) {
  .download-error-dialog { padding: 24px; }
  .download-error-dialog h2 { font-size: 22px; }
}
