/* Action bars on the public pages of the homepage host (form links, booking, Vonovia forms).
   The host never loads dist/styles.css, so the management bar styling (_actionbar.scss) is not
   here: until 2026-11-10 "Zurück", "Absenden" and "Neues Formular" stood on the page as bare
   text and nobody saw a button in them, least of all on a phone. This sheet gives the bar plain
   buttons in the tenant's colour — classic themes name it --color-primary, templates and the
   SiteBuilder --accent-color. The last button of the bar is the step's main action. */

.varuna-actionbar {
  --form-action-color: var(--color-primary, var(--accent-color, var(--bs-primary, #0d6efd)));
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 0;
  margin-bottom: 1.5rem;
}

.varuna-actionbar .actionbar-main,
.varuna-actionbar .actionbar-tools {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem;
}

.varuna-actionbar .actionbar-main {
  flex: 1 1 auto;
}

.varuna-actionbar .actionbar-main > .btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.375rem;
  min-height: 2.75rem; /* a comfortable touch target */
  padding: 0.5rem 1.25rem;
  margin: 0;
  border: 1px solid var(--form-action-color);
  border-radius: 0.5rem;
  background: transparent;
  color: var(--form-action-color);
  font-weight: 500;
  text-decoration: none;
  white-space: normal;
}

.varuna-actionbar .actionbar-main > .btn:last-child {
  background: var(--form-action-color);
  color: #fff;
}

.varuna-actionbar .actionbar-main > .btn:last-child i {
  color: inherit !important;
}

.varuna-actionbar .actionbar-main > .btn:not(:disabled):hover {
  filter: brightness(0.92);
}

.varuna-actionbar .actionbar-main > .btn:focus-visible {
  outline: 2px solid var(--form-action-color);
  outline-offset: 2px;
}

.varuna-actionbar .actionbar-main > .btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

/* The bar mirrors every label into title for the icon-only collapse; on touch screens the host's
   form theme turns a focused [title] into a boxed tooltip, which hung over the buttons. */
.varuna-actionbar [title]::after {
  content: none !important;
}

@media (max-width: 575.98px) {
  .varuna-actionbar .actionbar-main > .btn {
    flex: 1 1 100%;
  }

  /* On a phone the main action comes first, right under the last field. */
  .varuna-actionbar .actionbar-main > .btn:last-child {
    order: -1;
  }
}
