/* Shtypi: toast, drop overlay and dialogs. Loaded before styles.css. */

.toast {
  position: fixed;
  bottom: 24px;
  left: 50%;
  z-index: 40;
  max-width: min(480px, calc(100% - 32px));
  margin: 0;
  padding: 12px 18px;
  font-size: 15px;
  line-height: 1.45;
  color: var(--white);
  background: var(--ink);
  transform: translateX(-50%);
  animation: rise 0.25s ease-out both;
}

/* While a file is dragged over the page */
.drop-veil {
  position: fixed;
  inset: 0;
  z-index: 50;
  pointer-events: none;
  background: rgba(255, 255, 255, 0.85);
}

.drop-veil::after {
  content: "";
  position: absolute;
  inset: 24px;
  border: 1px dashed var(--ink);
}

.sheet {
  width: min(540px, calc(100% - 32px));
  padding: 0;
  color: var(--ink);
  background: var(--white);
  border: 1px solid var(--ink);
  border-radius: 0;
}

.sheet::backdrop {
  background: rgba(17, 17, 17, 0.3);
}

.sheet-inner {
  display: grid;
  gap: 16px;
  padding: 32px;
}

.sheet-title {
  margin: 0;
  font: 500 22px/1.3 var(--font-ui);
}

.sheet-text {
  margin: 0;
  color: var(--text-body);
}

.sheet-error {
  margin: 0;
  font-size: 14px;
  color: var(--error);
}

.field {
  width: 100%;
  min-width: 0;
  height: 40px;
  padding: 0 12px;
  font: 15px var(--font-ui);
  color: var(--ink);
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 0;
}

.field:focus-visible {
  border-color: var(--ink);
  outline-offset: 2px;
}

.link-row {
  display: flex;
  gap: 8px;
  margin-top: 8px;
}

.link-row .btn {
  height: 40px;
}

.sheet-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 8px;
}

@media (max-width: 760px) {
  .sheet-inner {
    padding: 24px;
  }

  .sheet-title {
    font-size: 20px;
  }
}
