/* Site-specific layout helpers only. Colors, fonts, and controls come from the Radzen theme. */

/* Simple login shells: fill the viewport with the active Radzen portal theme. */
.portal-auth {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  box-sizing: border-box;
  background: var(--rz-body-background-color, var(--rz-base-100, #f5f5f5));
  color: var(--rz-text-color, inherit);
}

.portal-auth__card {
  width: min(420px, 100%);
}

.admin-content {
  padding: 1.25rem 1.5rem 2rem;
}

/* Center page shells that set their own max-width (dashboard, properties, etc.).
   Full-width pages stay full-width; phones are unchanged. */
.admin-content > * {
  margin-inline: auto;
  width: 100%;
}

@media (max-width: 640px) {
  .admin-content {
    padding: 1rem;
  }

  /* Keep Radzen dialogs inside the iPhone viewport. */
  .rz-dialog {
    width: min(96vw, 100%) !important;
    max-width: 96vw !important;
    margin: 0.5rem !important;
  }

  .rz-dialog-wrapper {
    padding: 0.5rem !important;
    align-items: flex-start !important;
  }
}

/* Clickable document / attachment names open in a new tab. */
a.file-view-link {
  color: inherit;
  text-decoration: underline;
  text-underline-offset: 0.15em;
  cursor: pointer;
}

a.file-view-link:hover {
  opacity: 0.8;
}

/* Header brand/user text: RadzenText H6 uses body text color (dark), which is
   unreadable on the primary-colored header. Follow the theme's header contrast. */
.rz-header .app-header-brand,
.rz-header .app-header-brand.rz-text-h6,
.rz-header .app-header-subtitle,
.rz-header .app-header-user {
  color: var(--rz-header-color, var(--rz-on-primary, #fff)) !important;
}
