:root {
  --rf-color-graphite: #292935;
  --rf-color-graphite-elevated: #343440;
  --rf-color-rose: #b59a91;
  --rf-color-rose-dark: #99867c;
  --rf-color-rose-light: #d6c2bb;
  --rf-color-app-bg: #f6f4f3;
  --rf-color-surface: #fcfbfa;
  --rf-color-text: #292935;
  --rf-color-text-muted: #77737c;
  --rf-color-border: #e4dedc;

  --rf-color-success: #2f7d5c;
  --rf-color-success-bg: #e8f4ef;
  --rf-color-success-border: #b9d9cb;
  --rf-color-warning: #a46622;
  --rf-color-warning-bg: #fbf0df;
  --rf-color-warning-border: #edc994;
  --rf-color-error: #b14343;
  --rf-color-error-bg: #f9e9e7;
  --rf-color-error-border: #e4b7b1;
  --rf-color-info: #376f96;
  --rf-color-info-bg: #e7f0f6;
  --rf-color-info-border: #b7d1e2;

  --rf-font-family-base: Inter, ui-sans-serif, system-ui, -apple-system,
    BlinkMacSystemFont, "Segoe UI", sans-serif;
  --rf-font-family-heading: var(--rf-font-family-base);
  --rf-font-family-mono: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  --rf-font-size-xs: 0.75rem;
  --rf-font-size-sm: 0.875rem;
  --rf-font-size-base: 1rem;
  --rf-font-size-lg: 1.125rem;
  --rf-font-size-xl: 1.375rem;
  --rf-font-size-2xl: 1.75rem;
  --rf-font-size-3xl: 2.25rem;
  --rf-line-height-tight: 1.2;
  --rf-line-height-base: 1.5;
  --rf-font-weight-regular: 400;
  --rf-font-weight-medium: 500;
  --rf-font-weight-semibold: 600;
  --rf-font-weight-bold: 700;

  --rf-radius-xs: 0.25rem;
  --rf-radius-sm: 0.375rem;
  --rf-radius-md: 0.5rem;
  --rf-radius-lg: 0.75rem;
  --rf-border-width: 1px;
  --rf-border-subtle: var(--rf-border-width) solid var(--rf-color-border);

  --rf-shadow-xs: 0 1px 2px rgb(41 41 53 / 0.06);
  --rf-shadow-sm: 0 4px 12px rgb(41 41 53 / 0.08);
  --rf-shadow-md: 0 12px 28px rgb(41 41 53 / 0.12);
  --rf-shadow-focus: 0 0 0 3px rgb(181 154 145 / 0.35);

  --rf-space-1: 0.25rem;
  --rf-space-2: 0.5rem;
  --rf-space-3: 0.75rem;
  --rf-space-4: 1rem;
  --rf-space-5: 1.25rem;
  --rf-space-6: 1.5rem;
  --rf-space-8: 2rem;
  --rf-space-10: 2.5rem;
  --rf-space-12: 3rem;
  --rf-space-16: 4rem;

  --rf-header-height: 4rem;
  --rf-sidebar-width: 17.5rem;
  --rf-sidebar-collapsed-width: 5rem;
  --rf-transition-duration: 160ms;
  --rf-transition-duration-slow: 240ms;
  --rf-transition-timing: ease;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  min-height: 100%;
  font-size: 100%;
}

body {
  min-height: 100%;
  margin: 0;
  background: var(--rf-color-app-bg);
  color: var(--rf-color-text);
  font-family: var(--rf-font-family-base);
  font-size: var(--rf-font-size-base);
  font-weight: var(--rf-font-weight-regular);
  line-height: var(--rf-line-height-base);
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body.rf-mobile-sidebar-open {
  overflow: hidden;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  margin-block: 0 var(--rf-space-4);
  color: var(--rf-color-text);
  font-family: var(--rf-font-family-heading);
  font-weight: var(--rf-font-weight-semibold);
  line-height: var(--rf-line-height-tight);
}

h1 {
  font-size: var(--rf-font-size-3xl);
}

h2 {
  font-size: var(--rf-font-size-2xl);
}

h3 {
  font-size: var(--rf-font-size-xl);
}

h4 {
  font-size: var(--rf-font-size-lg);
}

h5,
h6 {
  font-size: var(--rf-font-size-base);
}

p {
  margin-block: 0 var(--rf-space-4);
}

a {
  color: var(--rf-color-rose-dark);
  text-decoration-thickness: 0.08em;
  text-underline-offset: 0.18em;
  transition:
    color var(--rf-transition-duration) var(--rf-transition-timing),
    text-decoration-color var(--rf-transition-duration) var(--rf-transition-timing);
}

a:hover {
  color: var(--rf-color-graphite);
}

button,
input,
select,
textarea {
  font: inherit;
}

button,
.rf-button,
input[type="button"],
input[type="reset"],
input[type="submit"] {
  display: inline-flex;
  min-height: 2.5rem;
  align-items: center;
  justify-content: center;
  gap: var(--rf-space-2);
  border: var(--rf-border-width) solid transparent;
  border-radius: var(--rf-radius-md);
  padding: 0.625rem var(--rf-space-4);
  background: var(--rf-color-graphite);
  color: var(--rf-color-surface);
  cursor: pointer;
  font-weight: var(--rf-font-weight-medium);
  line-height: 1;
  text-decoration: none;
  transition:
    background-color var(--rf-transition-duration) var(--rf-transition-timing),
    border-color var(--rf-transition-duration) var(--rf-transition-timing),
    box-shadow var(--rf-transition-duration) var(--rf-transition-timing),
    color var(--rf-transition-duration) var(--rf-transition-timing);
}

button:hover,
.rf-button:hover,
input[type="button"]:hover,
input[type="reset"]:hover,
input[type="submit"]:hover {
  background: var(--rf-color-graphite-elevated);
  color: var(--rf-color-surface);
}

button:disabled,
.rf-button[aria-disabled="true"],
input:disabled,
select:disabled,
textarea:disabled {
  cursor: not-allowed;
  opacity: 0.62;
}

.rf-button--secondary {
  border-color: var(--rf-color-border);
  background: var(--rf-color-surface);
  color: var(--rf-color-text);
}

.rf-button--secondary:hover {
  border-color: var(--rf-color-rose);
  background: var(--rf-color-surface);
  color: var(--rf-color-text);
}

label {
  display: inline-block;
  margin-bottom: var(--rf-space-2);
  color: var(--rf-color-text);
  font-size: var(--rf-font-size-sm);
  font-weight: var(--rf-font-weight-medium);
}

input,
select,
textarea {
  width: 100%;
  border: var(--rf-border-subtle);
  border-radius: var(--rf-radius-md);
  padding: 0.625rem 0.75rem;
  background: var(--rf-color-surface);
  color: var(--rf-color-text);
  transition:
    border-color var(--rf-transition-duration) var(--rf-transition-timing),
    box-shadow var(--rf-transition-duration) var(--rf-transition-timing);
}

textarea {
  min-height: 7.5rem;
  resize: vertical;
}

input::placeholder,
textarea::placeholder {
  color: var(--rf-color-text-muted);
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--rf-color-rose);
  outline: 0;
  box-shadow: var(--rf-shadow-focus);
}

.rf-form-group {
  margin-bottom: var(--rf-space-5);
}

.rf-card {
  border: var(--rf-border-subtle);
  border-radius: var(--rf-radius-lg);
  padding: var(--rf-space-6);
  background: var(--rf-color-surface);
  box-shadow: var(--rf-shadow-xs);
  height: 100%;
}

.rf-card--interactive {
  transition:
    border-color var(--rf-transition-duration) var(--rf-transition-timing),
    box-shadow var(--rf-transition-duration) var(--rf-transition-timing),
    transform var(--rf-transition-duration) var(--rf-transition-timing);
}

.rf-card--interactive:hover {
  border-color: var(--rf-color-rose-light);
  box-shadow: var(--rf-shadow-sm);
  transform: translateY(-1px);
}

.rf-card__header,
.rf-card__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--rf-space-4);
}

.rf-card__header {
  margin-bottom: var(--rf-space-5);
}

.rf-card__footer {
  margin-top: var(--rf-space-5);
  padding-top: var(--rf-space-4);
  border-top: var(--rf-border-subtle);
}

.rf-card__title {
  margin: 0;
  font-size: var(--rf-font-size-lg);
}

.rf-card__description {
  margin: var(--rf-space-1) 0 0;
  color: var(--rf-color-text-muted);
  font-size: var(--rf-font-size-sm);
}

.rf-button--icon {
  width: 2.5rem;
  min-height: 2.5rem;
  padding: 0;
}

.rf-button--icon-sm {
  width: 2rem;
  min-height: 2rem;
  border-radius: var(--rf-radius-sm);
  padding: 0;
}

.rf-button--ghost {
  border-color: transparent;
  background: transparent;
  color: var(--rf-color-text);
}

.rf-button--ghost:hover {
  border-color: var(--rf-color-border);
  background: rgb(214 194 187 / 0.18);
  color: var(--rf-color-text);
}

.rf-action-bar,
.rf-filter-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--rf-space-4);
  border: var(--rf-border-subtle);
  border-radius: var(--rf-radius-lg);
  background: var(--rf-color-surface);
  box-shadow: var(--rf-shadow-xs);
}

.rf-action-bar {
  padding: var(--rf-space-4);
}

.rf-filter-bar {
  flex-wrap: wrap;
  padding: var(--rf-space-4);
}

.rf-action-bar__group,
.rf-filter-bar__group {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--rf-space-3);
}

.rf-filter-bar__field {
  min-width: min(14rem, 100%);
  flex: 1 1 12rem;
}

.rf-progress {
  width: min(12rem, 100%);
  height: 0.6rem;
  overflow: hidden;
  border-radius: var(--rf-radius-sm);
  background: var(--rf-color-border);
}

.rf-progress--full {
  width: 100%;
  max-width: none;
}

.rf-progress__bar {
  height: 100%;
  border-radius: inherit;
  background: var(--rf-color-success);
  transition: width 0.3s ease;
}

.rf-progress__meta {
  margin-top: var(--rf-space-1);
  color: var(--rf-color-text-muted);
  font-size: var(--rf-font-size-sm);
}

@media (prefers-reduced-motion: reduce) {
  .rf-progress__bar {
    transition-duration: 0.01ms;
  }
}

.rf-table-wrap {
  width: 100%;
  overflow-x: auto;
  border: var(--rf-border-subtle);
  border-radius: var(--rf-radius-lg);
  background: var(--rf-color-surface);
  box-shadow: var(--rf-shadow-xs);
}

.rf-table {
  min-width: 42rem;
}

.rf-table th:first-child,
.rf-table td:first-child {
  padding-left: var(--rf-space-5);
}

.rf-table th:last-child,
.rf-table td:last-child {
  padding-right: var(--rf-space-5);
}

.rf-table__actions {
  display: flex;
  justify-content: flex-end;
  gap: var(--rf-space-2);
  white-space: nowrap;
}

.rf-table__actions-header {
  text-align: right;
  white-space: nowrap;
}

.rf-table__actions form {
  margin: 0;
}

.rf-table-sort {
  display: flex;
  min-height: 2.25rem;
  align-items: center;
  justify-content: space-between;
  gap: var(--rf-space-2);
  margin: -0.625rem calc(var(--rf-space-2) * -1);
  border-radius: var(--rf-radius-sm);
  padding: 0.625rem var(--rf-space-2);
  color: inherit;
  text-decoration: none;
}

.rf-table-sort:hover,
.rf-table-sort:focus-visible {
  background: rgb(214 194 187 / 0.22);
  color: var(--rf-color-text);
  outline: 0;
}

.rf-table-sort:focus-visible {
  box-shadow: 0 0 0 0.2rem rgb(181 154 145 / 0.28);
}

.rf-table-sort__indicator {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
  color: var(--rf-color-rose-dark);
  font-size: var(--rf-font-size-lg);
  line-height: 1;
}

.rf-table-primary {
  min-width: 12rem;
  color: var(--rf-color-text);
  font-weight: var(--rf-font-weight-semibold);
}

.rf-execution-table {
  min-width: 72rem;
}

.rf-execution-table td {
  white-space: nowrap;
}

.rf-execution-table td:first-child {
  white-space: normal;
}

.rf-schedule-table {
  min-width: 64rem;
}

.rf-schedule-table td {
  white-space: nowrap;
}

.rf-schedule-table td:first-child,
.rf-schedule-table td:nth-child(2) {
  white-space: normal;
}

.rf-schedule-form {
  display: grid;
  gap: var(--rf-space-5);
}

.rf-schedule-form__report {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: start;
  gap: var(--rf-space-4);
}

.rf-schedule-form__report-icon {
  display: inline-flex;
  width: 2.75rem;
  height: 2.75rem;
  align-items: center;
  justify-content: center;
  border-radius: var(--rf-radius-md);
  background: rgb(181 154 145 / 0.16);
  color: var(--rf-color-rose-dark);
  font-size: var(--rf-font-size-xl);
}

.rf-schedule-form__grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--rf-space-4);
  align-items: start;
}

.rf-schedule-form__section {
  display: grid;
  gap: var(--rf-space-5);
}

.rf-schedule-form__fields {
  display: grid;
  gap: var(--rf-space-4);
}

.rf-schedule-form__actions {
  position: sticky;
  bottom: var(--rf-space-4);
  z-index: 10;
}

.rf-audit-filter {
  margin-bottom: var(--rf-space-5);
}

.rf-audit-table {
  min-width: 86rem;
}

.rf-audit-table td {
  vertical-align: top;
}

.rf-audit-event {
  display: inline-flex;
  min-height: 1.75rem;
  align-items: center;
  border: var(--rf-border-width) solid var(--rf-color-border);
  border-radius: 999px;
  padding: 0.1875rem 0.625rem;
  background: var(--rf-color-surface);
  color: var(--rf-color-text-muted);
  font-size: var(--rf-font-size-xs);
  font-weight: var(--rf-font-weight-semibold);
  line-height: 1.2;
  white-space: nowrap;
}

.rf-audit-event--login,
.rf-audit-event--logout {
  border-color: var(--rf-color-info-border);
  background: var(--rf-color-info-bg);
  color: var(--rf-color-info);
}

.rf-audit-event--access_denied,
.rf-audit-event--login_locked {
  border-color: var(--rf-color-error-border);
  background: var(--rf-color-error-bg);
  color: var(--rf-color-error);
}

.rf-audit-event--report_execution_created,
.rf-audit-event--report_execution_started {
  border-color: var(--rf-color-warning-border);
  background: var(--rf-color-warning-bg);
  color: var(--rf-color-warning);
}

.rf-audit-event--report_execution_completed,
.rf-audit-event--report_downloaded,
.rf-audit-event--report_permission_created,
.rf-audit-event--report_permission_updated {
  border-color: var(--rf-color-success-border);
  background: var(--rf-color-success-bg);
  color: var(--rf-color-success);
}

.rf-audit-event--report_execution_failed,
.rf-audit-event--report_email_failed {
  border-color: var(--rf-color-error-border);
  background: var(--rf-color-error-bg);
  color: var(--rf-color-error);
}

.rf-audit-object-id {
  display: block;
  margin-top: var(--rf-space-1);
  color: var(--rf-color-text-muted);
  font-size: var(--rf-font-size-xs);
}

.rf-audit-metadata {
  max-width: 20rem;
  max-height: 10rem;
  overflow: auto;
  margin: 0;
  border: var(--rf-border-subtle);
  border-radius: var(--rf-radius-sm);
  padding: var(--rf-space-2);
  background: #f0ecea;
  color: var(--rf-color-text);
  font-family: var(--rf-font-family-mono);
  font-size: var(--rf-font-size-xs);
  white-space: pre-wrap;
}

.rf-execution-detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(18rem, 0.34fr);
  gap: var(--rf-space-4);
  align-items: start;
  margin-bottom: var(--rf-space-4);
}

.rf-execution-summary,
.rf-execution-actions,
.rf-execution-parameters {
  display: grid;
  gap: var(--rf-space-5);
}

.rf-execution-summary__header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--rf-space-4);
}

.rf-execution-actions .rf-button {
  width: 100%;
}

.rf-execution-detail-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--rf-space-4);
  margin-bottom: var(--rf-space-4);
}

.rf-execution-error {
  margin-bottom: var(--rf-space-4);
}

.rf-execution-parameters .rf-detail-list dd {
  word-break: break-word;
}

.rf-department-page {
  display: grid;
  gap: var(--rf-space-6);
}

.rf-department-primary {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: start;
  gap: var(--rf-space-5);
  background:
    linear-gradient(135deg, rgb(181 154 145 / 0.16), transparent 22rem),
    var(--rf-color-surface);
}

.rf-department-primary__icon {
  display: inline-flex;
  width: 3rem;
  height: 3rem;
  align-items: center;
  justify-content: center;
  border-radius: var(--rf-radius-lg);
  background: var(--rf-color-graphite);
  color: var(--rf-color-rose-light);
  font-size: var(--rf-font-size-2xl);
}

.rf-department-primary__content {
  min-width: 0;
}

.rf-department-primary__content h2 {
  margin-bottom: var(--rf-space-2);
  font-size: var(--rf-font-size-2xl);
}

.rf-department-primary__content p:last-child {
  margin-bottom: 0;
  color: var(--rf-color-text-muted);
}

.rf-department-primary__status {
  justify-self: end;
}

.rf-department-section {
  display: grid;
  gap: var(--rf-space-4);
}

.rf-department-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--rf-space-4);
}

.rf-department-card {
  display: grid;
  gap: var(--rf-space-4);
}

.rf-department-card__header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--rf-space-3);
}

.rf-department-card__header h3 {
  margin-bottom: var(--rf-space-2);
  font-size: var(--rf-font-size-lg);
}

.rf-department-card p {
  margin: 0;
  color: var(--rf-color-text-muted);
}

.rf-profile-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(18rem, 0.38fr);
  gap: var(--rf-space-4);
  margin-bottom: var(--rf-space-4);
}

.rf-profile-card {
  display: flex;
  align-items: center;
  gap: var(--rf-space-5);
  background:
    linear-gradient(135deg, rgb(181 154 145 / 0.16), transparent 24rem),
    var(--rf-color-surface);
}

.rf-profile-card__avatar {
  display: inline-flex;
  width: 5rem;
  height: 5rem;
  flex: 0 0 5rem;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: var(--rf-color-graphite);
  color: var(--rf-color-rose-light);
  font-size: var(--rf-font-size-2xl);
  font-weight: var(--rf-font-weight-bold);
  text-transform: uppercase;
}

.rf-profile-card__content {
  display: grid;
  min-width: 0;
  gap: var(--rf-space-2);
}

.rf-profile-card__content h2 {
  margin: 0;
  font-size: var(--rf-font-size-2xl);
}

.rf-profile-card__content p {
  margin: 0;
  color: var(--rf-color-text-muted);
}

.rf-profile-actions {
  display: grid;
  gap: var(--rf-space-4);
}

.rf-profile-actions__list {
  display: grid;
  gap: var(--rf-space-3);
}

.rf-profile-actions__list .rf-button {
  width: 100%;
}

.rf-profile-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--rf-space-4);
}

.rf-notification-list {
  display: grid;
  gap: var(--rf-space-3);
}

.rf-notification-item {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: var(--rf-space-4);
  align-items: start;
  border: var(--rf-border-subtle);
  border-radius: var(--rf-radius-lg);
  padding: var(--rf-space-4);
  background: var(--rf-color-surface);
  box-shadow: var(--rf-shadow-xs);
}

.rf-notification-item.is-unread {
  border-color: var(--rf-color-rose-light);
  background:
    linear-gradient(90deg, rgb(181 154 145 / 0.14), transparent 18rem),
    var(--rf-color-surface);
}

.rf-notification-item__icon {
  display: inline-flex;
  width: 2.5rem;
  height: 2.5rem;
  align-items: center;
  justify-content: center;
  border-radius: var(--rf-radius-md);
  background: rgb(181 154 145 / 0.16);
  color: var(--rf-color-rose-dark);
  font-size: var(--rf-font-size-lg);
}

.rf-notification-item__content {
  display: grid;
  min-width: 0;
  gap: var(--rf-space-3);
}

.rf-notification-item__header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--rf-space-4);
}

.rf-notification-item__header h2 {
  margin-bottom: var(--rf-space-1);
  font-size: var(--rf-font-size-lg);
}

.rf-notification-item__header p {
  margin: 0;
  color: var(--rf-color-text-muted);
}

.rf-notification-item__badges {
  display: flex;
  flex: 0 0 auto;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: var(--rf-space-2);
}

.rf-notification-item__meta {
  display: flex;
  flex-wrap: wrap;
  gap: var(--rf-space-3);
  color: var(--rf-color-text-muted);
  font-size: var(--rf-font-size-sm);
}

.rf-notification-item__actions {
  display: flex;
  justify-content: flex-end;
}

.rf-shell {
  min-height: 100vh;
}

.rf-public-body {
  min-height: 100vh;
  background:
    linear-gradient(135deg, rgb(41 41 53 / 0.04), transparent 34rem),
    var(--rf-color-app-bg);
}

.rf-public-shell {
  display: grid;
  min-height: 100vh;
  grid-template-rows: auto 1fr auto;
}

.rf-public-header,
.rf-public-footer {
  width: min(100%, 72rem);
  margin-inline: auto;
  padding-inline: var(--rf-space-4);
}

.rf-public-header {
  display: flex;
  min-height: 5rem;
  align-items: center;
  justify-content: space-between;
}

.rf-public-brand {
  display: inline-flex;
  align-items: center;
  gap: var(--rf-space-3);
  color: var(--rf-color-graphite);
  font-size: var(--rf-font-size-lg);
  font-weight: var(--rf-font-weight-bold);
  text-decoration: none;
}

.rf-public-brand:hover {
  color: var(--rf-color-rose-dark);
}

.rf-public-main {
  display: grid;
  align-items: center;
  padding: var(--rf-space-6) var(--rf-space-4);
}

.rf-public-content {
  width: min(100%, 72rem);
  margin-inline: auto;
}

.rf-public-card {
  width: min(100%, 28rem);
  margin-inline: auto;
  border: var(--rf-border-subtle);
  border-radius: var(--rf-radius-lg);
  padding: var(--rf-space-8);
  background: var(--rf-color-surface);
  box-shadow: var(--rf-shadow-md);
}

.rf-public-card__title {
  margin-bottom: var(--rf-space-2);
  font-size: var(--rf-font-size-2xl);
}

.rf-public-card__subtitle {
  margin-bottom: var(--rf-space-6);
  color: var(--rf-color-text-muted);
}

.rf-auth-card {
  display: grid;
  gap: var(--rf-space-5);
}

.rf-auth-card__brand {
  display: inline-flex;
  align-items: center;
  gap: var(--rf-space-3);
  color: var(--rf-color-graphite);
  font-weight: var(--rf-font-weight-bold);
}

.rf-auth-card__header {
  display: grid;
  gap: var(--rf-space-2);
}

.rf-auth-card__header .rf-public-card__subtitle {
  margin-bottom: 0;
}

.rf-auth-card__messages {
  display: grid;
  gap: var(--rf-space-3);
}

.rf-auth-form {
  display: grid;
  gap: var(--rf-space-4);
}

.rf-auth-field {
  position: relative;
}

.rf-auth-field i {
  position: absolute;
  top: 50%;
  left: var(--rf-space-3);
  color: var(--rf-color-text-muted);
  font-size: var(--rf-font-size-base);
  line-height: 1;
  transform: translateY(-50%);
}

.rf-auth-field__control {
  padding-left: 2.5rem;
}

.rf-auth-field__control[aria-invalid="true"] {
  border-color: var(--rf-color-error);
}

.rf-auth-form__submit {
  width: 100%;
  margin-top: var(--rf-space-1);
}

.rf-auth-card__links {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: var(--rf-space-3);
  padding-top: var(--rf-space-2);
  font-size: var(--rf-font-size-sm);
}

.rf-auth-feedback {
  justify-items: center;
  text-align: center;
}

.rf-auth-feedback__icon {
  display: inline-flex;
  width: 3rem;
  height: 3rem;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: var(--rf-color-success-bg);
  color: var(--rf-color-success);
  font-size: var(--rf-font-size-2xl);
}

.rf-auth-panel {
  display: grid;
  max-width: 42rem;
  gap: var(--rf-space-5);
}

.rf-field-help {
  margin-top: var(--rf-space-2);
  color: var(--rf-color-text-muted);
  font-size: var(--rf-font-size-sm);
}

.rf-field-help ul {
  padding-left: var(--rf-space-5);
  margin: var(--rf-space-2) 0 0;
}

.rf-field-errors {
  display: grid;
  gap: var(--rf-space-1);
  margin-top: var(--rf-space-2);
  color: var(--rf-color-error);
  font-size: var(--rf-font-size-sm);
}

.rf-field-errors p {
  margin: 0;
}

.rf-public-footer {
  display: flex;
  min-height: 4rem;
  align-items: center;
  justify-content: center;
  color: var(--rf-color-text-muted);
  font-size: var(--rf-font-size-sm);
}

.rf-public-body--error .rf-public-main {
  align-items: center;
}

.rf-error-card {
  display: grid;
  width: min(100%, 34rem);
  justify-items: center;
  gap: var(--rf-space-4);
  margin-inline: auto;
  border: var(--rf-border-subtle);
  border-radius: var(--rf-radius-lg);
  padding: var(--rf-space-10) var(--rf-space-6);
  background: var(--rf-color-surface);
  text-align: center;
  box-shadow: var(--rf-shadow-md);
}

.rf-error-card__icon {
  display: inline-flex;
  width: 3.5rem;
  height: 3.5rem;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: rgb(181 154 145 / 0.16);
  color: var(--rf-color-rose-dark);
  font-size: var(--rf-font-size-2xl);
}

.rf-error-card__code {
  margin: 0;
  color: var(--rf-color-rose-dark);
  font-size: var(--rf-font-size-sm);
  font-weight: var(--rf-font-weight-bold);
  letter-spacing: 0;
}

.rf-error-card h1 {
  margin: 0;
  font-size: var(--rf-font-size-3xl);
}

.rf-error-card__message {
  max-width: 26rem;
  margin: 0;
  color: var(--rf-color-text-muted);
}

.rf-error-card__actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: var(--rf-space-3);
}

.rf-dashboard-greeting {
  margin-top: calc(var(--rf-space-4) * -1);
  margin-bottom: var(--rf-space-6);
  color: var(--rf-color-text-muted);
}

.rf-dashboard-metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--rf-space-4);
  margin-bottom: var(--rf-space-6);
}

.rf-dashboard-metric {
  display: flex;
  align-items: flex-start;
  gap: var(--rf-space-4);
}

.rf-dashboard-metric__icon {
  display: inline-flex;
  width: 2.75rem;
  height: 2.75rem;
  flex: 0 0 2.75rem;
  align-items: center;
  justify-content: center;
  border-radius: var(--rf-radius-md);
  background: rgb(181 154 145 / 0.16);
  color: var(--rf-color-rose-dark);
  font-size: var(--rf-font-size-xl);
}

.rf-dashboard-metric__text {
  font-size: var(--rf-font-size-lg);
}

.rf-dashboard-metric__badge {
  margin-top: var(--rf-space-2);
}

.rf-dashboard-section {
  margin-bottom: var(--rf-space-6);
}

.rf-dashboard-shortcuts {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: var(--rf-space-3);
}

.rf-dashboard-shortcut {
  position: relative;
  display: flex;
  min-height: 5rem;
  align-items: center;
  gap: var(--rf-space-3);
  border: var(--rf-border-subtle);
  border-radius: var(--rf-radius-lg);
  padding: var(--rf-space-4);
  background: var(--rf-color-surface);
  color: var(--rf-color-text);
  font-weight: var(--rf-font-weight-semibold);
  text-decoration: none;
  box-shadow: var(--rf-shadow-xs);
}

.rf-dashboard-shortcut:hover {
  border-color: var(--rf-color-rose-light);
  background: rgb(214 194 187 / 0.16);
  color: var(--rf-color-text);
}

.rf-dashboard-shortcut i {
  display: inline-flex;
  width: 2.25rem;
  height: 2.25rem;
  flex: 0 0 2.25rem;
  align-items: center;
  justify-content: center;
  border-radius: var(--rf-radius-md);
  background: var(--rf-color-graphite);
  color: var(--rf-color-rose-light);
  font-size: var(--rf-font-size-lg);
}

.rf-dashboard-shortcut__badge {
  position: absolute;
  top: var(--rf-space-3);
  right: var(--rf-space-3);
  display: inline-flex;
  min-width: 1.35rem;
  height: 1.35rem;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: var(--rf-color-rose);
  color: var(--rf-color-graphite);
  font-size: var(--rf-font-size-xs);
  font-weight: var(--rf-font-weight-bold);
}

.rf-dashboard-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--rf-space-4);
}

.rf-dashboard-panel {
  min-height: 100%;
}

.rf-dashboard-panel .rf-empty-state {
  padding: var(--rf-space-8) var(--rf-space-5);
}

.rf-management-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--rf-space-4);
}

.rf-management-card {
  display: flex;
  min-height: 14rem;
  flex-direction: column;
}

.rf-management-card--technical {
  border-color: rgb(55 111 150 / 0.28);
}

.rf-management-card__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--rf-space-3);
  margin-bottom: var(--rf-space-5);
}

.rf-management-card__icon {
  display: inline-flex;
  width: 2.75rem;
  height: 2.75rem;
  flex: 0 0 2.75rem;
  align-items: center;
  justify-content: center;
  border-radius: var(--rf-radius-md);
  background: rgb(181 154 145 / 0.16);
  color: var(--rf-color-rose-dark);
  font-size: var(--rf-font-size-xl);
}

.rf-management-card .rf-card__description {
  flex: 1;
}

.rf-management-filter {
  margin-bottom: var(--rf-space-5);
}

.rf-management-table {
  table-layout: auto;
}

.rf-management-table th:last-child,
.rf-management-table td:last-child {
  width: 1%;
  text-align: right;
  white-space: nowrap;
}

.rf-management-user-table {
  min-width: 78rem;
}

.rf-management-group-table {
  min-width: 56rem;
}

.rf-management-department-table {
  min-width: 72rem;
}

.rf-management-automation-table {
  min-width: 72rem;
}

.rf-management-user-table td {
  white-space: nowrap;
}

.rf-management-user-table td:first-child {
  white-space: normal;
}

.rf-table-secondary {
  margin-top: var(--rf-space-1);
  color: var(--rf-color-text-muted);
  font-size: var(--rf-font-size-xs);
}

.rf-management-detail,
.rf-management-form {
  display: grid;
  gap: var(--rf-space-5);
}

.rf-management-form__grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--rf-space-4);
}

.rf-management-form__actions {
  position: sticky;
  bottom: var(--rf-space-4);
  z-index: 10;
}

.rf-user-access-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--rf-space-4);
  margin-top: var(--rf-space-5);
}

.rf-user-access-grid .rf-user-access-option {
  display: flex;
  align-items: flex-start;
  gap: var(--rf-space-3);
  height: 100%;
  min-width: 0;
  margin: 0;
  border: var(--rf-border-width) solid var(--rf-color-border);
  border-radius: var(--rf-radius-lg);
  padding: 1.125rem;
  background: var(--rf-color-surface);
  color: var(--rf-color-text);
  cursor: pointer;
  text-align: left;
  transition:
    background-color var(--rf-transition-duration) var(--rf-transition-timing),
    border-color var(--rf-transition-duration) var(--rf-transition-timing),
    box-shadow var(--rf-transition-duration) var(--rf-transition-timing);
}

.rf-user-access-grid .rf-user-access-option:hover {
  border-color: var(--rf-color-rose-light);
  background: rgb(214 194 187 / 0.14);
}

.rf-user-access-grid .rf-user-access-option:has(input:checked) {
  border-color: var(--rf-color-rose-dark);
  background: rgb(214 194 187 / 0.24);
  box-shadow: inset 0 0 0 1px var(--rf-color-rose-dark);
}

.rf-user-access-grid .rf-user-access-option:has(input:focus-visible) {
  border-color: var(--rf-color-rose);
  box-shadow: var(--rf-shadow-focus);
}

.rf-user-access-grid .rf-user-access-option:has(input:disabled) {
  cursor: not-allowed;
  opacity: 0.72;
}

.rf-user-access-option__control {
  display: flex;
  flex: 0 0 auto;
  align-items: flex-start;
  padding-top: 0.125rem;
}

.rf-user-access-option__control input[type="checkbox"] {
  width: 18px;
  height: 18px;
  margin: 0;
  accent-color: var(--rf-color-rose-dark);
}

.rf-user-access-option__content {
  display: flex;
  flex: 1;
  flex-direction: column;
  align-items: flex-start;
  gap: var(--rf-space-2);
  min-width: 0;
}

.rf-user-access-option__header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--rf-space-2);
}

.rf-user-access-option__title {
  display: block;
  color: var(--rf-color-text);
  font-size: var(--rf-font-size-sm);
  font-weight: var(--rf-font-weight-semibold);
  line-height: 1.4;
}

.rf-user-access-option__description {
  display: block;
  color: var(--rf-color-text-muted);
  font-size: var(--rf-font-size-sm);
  font-weight: var(--rf-font-weight-regular);
  line-height: var(--rf-line-height-base);
}

.rf-user-access-option__badge {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 3px var(--rf-space-2);
  background: var(--rf-color-warning-bg);
  color: var(--rf-color-warning);
  font-size: var(--rf-font-size-xs);
  font-weight: var(--rf-font-weight-semibold);
  line-height: 1.2;
}

.rf-user-departments {
  display: grid;
  gap: var(--rf-space-4);
}

.rf-user-departments__controls {
  display: flex;
  align-items: flex-end;
  gap: var(--rf-space-3);
}

.rf-user-departments__field {
  flex: 1 1 auto;
  min-width: 0;
  margin-bottom: 0;
}

.rf-user-departments__select {
  min-height: 2.5rem;
}

.rf-user-departments__add {
  flex: 0 0 auto;
}

.rf-user-departments__summary {
  display: grid;
  gap: var(--rf-space-3);
}

.rf-user-departments__list {
  display: flex;
  flex-wrap: wrap;
  gap: var(--rf-space-2);
  padding: 0;
  margin: 0;
  list-style: none;
}

.rf-user-departments__item {
  display: inline-flex;
  max-width: 100%;
  min-height: 2rem;
  align-items: center;
  gap: var(--rf-space-1);
  overflow: hidden;
  border: var(--rf-border-width) solid var(--rf-color-border);
  border-radius: 999px;
  background: rgb(214 194 187 / 0.18);
  color: var(--rf-color-text);
  font-size: var(--rf-font-size-sm);
  box-shadow: var(--rf-shadow-xs);
}

.rf-user-departments__item.is-primary {
  border-color: var(--rf-color-success-border);
  background: var(--rf-color-success-bg);
}

.rf-user-departments__name {
  min-width: 0;
  overflow: hidden;
  padding: 0.25rem var(--rf-space-3);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.rf-user-departments__badge {
  display: none;
  flex: 0 0 auto;
  border-radius: 999px;
  padding: 0.125rem var(--rf-space-2);
  background: var(--rf-color-success);
  color: var(--rf-color-surface);
  font-size: var(--rf-font-size-xs);
  font-weight: var(--rf-font-weight-semibold);
  line-height: 1.2;
}

.rf-user-departments__item.is-primary .rf-user-departments__badge {
  display: inline-flex;
}

.rf-user-departments__primary {
  min-height: 1.75rem;
  flex: 0 0 auto;
  border-color: transparent;
  border-radius: 999px;
  padding: 0.25rem var(--rf-space-2);
  background: transparent;
  color: var(--rf-color-rose-dark);
  font-size: var(--rf-font-size-xs);
  font-weight: var(--rf-font-weight-semibold);
}

.rf-user-departments__primary:hover,
.rf-user-departments__primary:focus {
  background: rgb(181 154 145 / 0.18);
  color: var(--rf-color-graphite);
}

.rf-user-departments__primary:disabled,
.rf-user-departments__item.is-primary .rf-user-departments__primary {
  display: none;
}

.rf-user-departments__remove {
  width: 2rem;
  min-height: 2rem;
  flex: 0 0 2rem;
  border-width: 0 0 0 var(--rf-border-width);
  border-color: var(--rf-color-border);
  border-radius: 0;
  padding: 0;
  background: transparent;
  color: var(--rf-color-text-muted);
  font-size: var(--rf-font-size-lg);
  line-height: 1;
}

.rf-user-departments__remove:hover,
.rf-user-departments__remove:focus {
  background: var(--rf-color-error-bg);
  color: var(--rf-color-error);
}

.rf-user-departments__empty {
  margin: 0;
  border: 1px dashed var(--rf-color-border);
  border-radius: var(--rf-radius-md);
  padding: var(--rf-space-3) var(--rf-space-4);
  color: var(--rf-color-text-muted);
  font-size: var(--rf-font-size-sm);
}

.rf-user-departments__clear {
  justify-self: start;
}

@media (max-width: 1099px) {
  .rf-user-access-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 699px) {
  .rf-user-access-grid {
    grid-template-columns: 1fr;
  }

  .rf-user-departments__controls {
    align-items: stretch;
    flex-direction: column;
  }

  .rf-user-departments__add,
  .rf-user-departments__clear {
    width: 100%;
  }

  .rf-user-departments__list {
    display: grid;
    grid-template-columns: 1fr;
  }

  .rf-user-departments__item {
    width: 100%;
    justify-content: space-between;
    border-radius: var(--rf-radius-md);
  }

  .rf-user-departments__name {
    flex: 1 1 auto;
  }
}

.rf-management-status {
  margin-top: var(--rf-space-5);
}

.rf-management-list {
  display: grid;
  gap: var(--rf-space-3);
}

.rf-management-list__item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--rf-space-4);
  border-bottom: var(--rf-border-subtle);
  padding-bottom: var(--rf-space-3);
}

.rf-management-list__item:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}

.rf-management-list__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: var(--rf-space-2);
}

.rf-management-confirm {
  max-width: 48rem;
}

.rf-permission-tools {
  margin-bottom: var(--rf-space-5);
}

.rf-permission-modules {
  display: grid;
  gap: var(--rf-space-4);
}

.rf-permission-module {
  display: grid;
  gap: var(--rf-space-4);
  border: var(--rf-border-subtle);
  border-radius: var(--rf-radius-md);
  padding: var(--rf-space-4);
}

.rf-permission-module__header {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--rf-space-3);
}

.rf-permission-module__summary {
  min-width: min(16rem, 100%);
}

.rf-permission-module h3 {
  margin: 0;
  font-size: var(--rf-font-size-base);
}

.rf-permission-module__count {
  margin: var(--rf-space-1) 0 0;
  color: var(--rf-color-text-muted);
  font-size: var(--rf-font-size-sm);
}

.rf-permission-module__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: var(--rf-space-2);
}

.rf-permission-checkboxes {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 20rem), 1fr));
  gap: var(--rf-space-3);
}

.rf-permission-list {
  display: grid;
  gap: var(--rf-space-2);
}

.rf-permission-option {
  display: flex;
  align-items: flex-start;
  gap: var(--rf-space-3);
  min-width: 0;
  margin: 0;
  border: var(--rf-border-width) solid var(--rf-color-border);
  border-radius: var(--rf-radius-md);
  padding: var(--rf-space-3);
  background: var(--rf-color-surface);
  color: var(--rf-color-text);
  cursor: pointer;
  transition:
    background-color var(--rf-transition-duration) var(--rf-transition-timing),
    border-color var(--rf-transition-duration) var(--rf-transition-timing),
    box-shadow var(--rf-transition-duration) var(--rf-transition-timing);
}

.rf-permission-option:hover {
  border-color: var(--rf-color-rose-light);
  background: rgb(214 194 187 / 0.16);
}

.rf-permission-option.is-selected,
.rf-permission-option:has(input:checked) {
  border-color: var(--rf-color-rose-dark);
  background: rgb(214 194 187 / 0.24);
  box-shadow: inset 0 0 0 1px var(--rf-color-rose-light);
}

.rf-permission-option:has(input:focus-visible) {
  border-color: var(--rf-color-rose);
  box-shadow: var(--rf-shadow-focus);
}

.rf-permission-option input[type="checkbox"] {
  width: 1.125rem;
  min-width: 1.125rem;
  height: 1.125rem;
  margin: 0.15rem 0 0;
  padding: 0;
  accent-color: var(--rf-color-rose-dark);
}

.rf-permission-option__content {
  display: grid;
  gap: var(--rf-space-1);
  min-width: 0;
}

.rf-permission-option__name {
  color: var(--rf-color-text);
  font-size: var(--rf-font-size-sm);
  font-weight: var(--rf-font-weight-semibold);
  overflow-wrap: anywhere;
}

.rf-permission-option__code,
.rf-permission-list code {
  display: block;
  color: var(--rf-color-text-muted);
  font-family: var(--rf-font-family-mono);
  font-size: var(--rf-font-size-xs);
  font-weight: var(--rf-font-weight-regular);
  line-height: var(--rf-line-height-base);
  overflow-wrap: anywhere;
}

.rf-permission-list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.rf-permission-list li {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--rf-space-3);
  border-bottom: var(--rf-border-subtle);
  padding-bottom: var(--rf-space-2);
}

.rf-permission-list li:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}

.rf-report-catalog {
  display: grid;
  gap: var(--rf-space-8);
}

.rf-report-category {
  display: grid;
  gap: var(--rf-space-4);
}

.rf-report-category__header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--rf-space-4);
}

.rf-report-category__header h2 {
  margin-bottom: var(--rf-space-1);
  font-size: var(--rf-font-size-xl);
}

.rf-report-category__header p {
  margin: 0;
  color: var(--rf-color-text-muted);
}

.rf-report-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--rf-space-4);
}

.rf-report-card {
  display: grid;
  gap: var(--rf-space-4);
}

.rf-report-card__topline {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--rf-space-2);
}

.rf-report-card__body h3 {
  margin-bottom: var(--rf-space-2);
  font-size: var(--rf-font-size-lg);
}

.rf-report-card__body p {
  margin: 0;
  color: var(--rf-color-text-muted);
}

.rf-report-card__meta {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--rf-space-3);
  margin: 0;
}

.rf-report-card__meta div {
  min-width: 0;
}

.rf-report-card__meta dt {
  color: var(--rf-color-text-muted);
  font-size: var(--rf-font-size-xs);
  font-weight: var(--rf-font-weight-semibold);
  text-transform: uppercase;
}

.rf-report-card__meta dd {
  overflow: hidden;
  margin: var(--rf-space-1) 0 0;
  color: var(--rf-color-text);
  font-size: var(--rf-font-size-sm);
  font-weight: var(--rf-font-weight-medium);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.rf-report-detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(22rem, 0.72fr);
  gap: var(--rf-space-4);
  align-items: start;
}

.rf-report-detail-main,
.rf-report-execution-panel,
.rf-report-validated {
  display: grid;
  gap: var(--rf-space-5);
}

.rf-report-validated {
  margin-top: var(--rf-space-4);
}

.rf-report-detail__topline {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--rf-space-4);
}

.rf-detail-list {
  display: grid;
  gap: var(--rf-space-3);
  margin: 0;
}

.rf-detail-list div {
  display: grid;
  grid-template-columns: 9rem minmax(0, 1fr);
  gap: var(--rf-space-4);
  padding-bottom: var(--rf-space-3);
  border-bottom: var(--rf-border-subtle);
}

.rf-detail-list div:last-child {
  padding-bottom: 0;
  border-bottom: 0;
}

.rf-detail-list dt {
  color: var(--rf-color-text-muted);
  font-size: var(--rf-font-size-sm);
  font-weight: var(--rf-font-weight-semibold);
}

.rf-detail-list dd {
  margin: 0;
  color: var(--rf-color-text);
}

.rf-report-capabilities {
  display: grid;
  gap: var(--rf-space-3);
  padding-top: var(--rf-space-4);
  border-top: var(--rf-border-subtle);
}

.rf-report-capabilities h3 {
  margin: 0;
  font-size: var(--rf-font-size-base);
}

.rf-report-capabilities__list {
  display: flex;
  flex-wrap: wrap;
  gap: var(--rf-space-2);
}

.rf-report-capability {
  display: inline-flex;
  min-height: 2.25rem;
  align-items: center;
  gap: var(--rf-space-2);
  border: var(--rf-border-subtle);
  border-radius: 999px;
  padding: 0.35rem 0.75rem;
  background: rgb(214 194 187 / 0.14);
  color: var(--rf-color-text);
  font-size: var(--rf-font-size-sm);
  font-weight: var(--rf-font-weight-medium);
  text-decoration: none;
}

.rf-report-capability i {
  color: var(--rf-color-rose-dark);
}

.rf-report-capability:hover {
  border-color: var(--rf-color-rose);
  color: var(--rf-color-text);
}

.rf-parameter-form {
  display: grid;
  gap: var(--rf-space-5);
}

.rf-parameter-form__grid {
  display: grid;
  gap: var(--rf-space-4);
}

.rf-parameter-field {
  margin-bottom: 0;
}

.rf-parameter-field input,
.rf-parameter-field select,
.rf-parameter-field textarea {
  margin-top: var(--rf-space-1);
}

.rf-parameter-field select[multiple] {
  min-height: 8rem;
}

.rf-parameter-field input[type="checkbox"] {
  width: 1rem;
  height: 1rem;
  flex: 0 0 1rem;
  margin: 0;
  accent-color: var(--rf-color-rose-dark);
}

.rf-checkbox-field {
  display: flex;
  align-items: center;
  gap: var(--rf-space-2);
}

.rf-checkbox-field label {
  margin-bottom: 0;
}

.rf-sidebar {
  width: var(--rf-sidebar-width);
  height: 100vh;
  position: sticky;
  top: 0;
  overflow: hidden;
  border-right: 1px solid rgb(214 194 187 / 0.14);
  background: var(--rf-color-graphite);
  color: var(--rf-color-surface);
  transition: width var(--rf-transition-duration-slow) var(--rf-transition-timing);
}

.rf-sidebar-overlay {
  position: fixed;
  inset: 0;
  z-index: 1040;
  background: rgb(41 41 53 / 0.58);
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--rf-transition-duration-slow) var(--rf-transition-timing);
}

.rf-sidebar__inner {
  display: flex;
  height: 100%;
  min-height: 100%;
  flex-direction: column;
  padding: var(--rf-space-4);
}

.rf-sidebar__brand-row {
  display: flex;
  min-height: 3rem;
  align-items: center;
  justify-content: space-between;
  gap: var(--rf-space-3);
  margin-bottom: var(--rf-space-6);
}

.rf-brand {
  display: inline-flex;
  min-width: 0;
  align-items: center;
  gap: var(--rf-space-3);
  color: var(--rf-color-surface);
  font-size: var(--rf-font-size-lg);
  font-weight: var(--rf-font-weight-bold);
  text-decoration: none;
}

.rf-brand:hover {
  color: var(--rf-color-rose-light);
}

.rf-brand__mark {
  display: inline-flex;
  width: 2.25rem;
  height: 2.25rem;
  flex: 0 0 2.25rem;
  align-items: center;
  justify-content: center;
  border: 1px solid rgb(214 194 187 / 0.42);
  border-radius: var(--rf-radius-md);
  background: rgb(181 154 145 / 0.16);
  color: var(--rf-color-rose-light);
  font-size: var(--rf-font-size-sm);
  font-weight: var(--rf-font-weight-bold);
}

.rf-sidebar__toggle {
  width: 2.25rem;
  min-height: 2.25rem;
  flex: 0 0 2.25rem;
  border-color: rgb(214 194 187 / 0.24);
  border-radius: var(--rf-radius-md);
  padding: 0;
  background: rgb(255 255 255 / 0.04);
  color: var(--rf-color-rose-light);
}

.rf-sidebar__toggle:hover {
  border-color: rgb(214 194 187 / 0.48);
  background: rgb(255 255 255 / 0.08);
  color: var(--rf-color-surface);
}

.rf-sidebar__nav {
  display: grid;
  gap: var(--rf-space-4);
  overflow-y: auto;
  padding-right: 0.2rem;
  scrollbar-width: thin;
  scrollbar-color: rgb(214 194 187 / 0.35) transparent;
}

.rf-sidebar__group {
  display: grid;
  gap: var(--rf-space-1);
}

.rf-sidebar__group-label {
  padding: 0 var(--rf-space-3) var(--rf-space-1);
  color: rgb(252 251 250 / 0.5);
  font-size: var(--rf-font-size-xs);
  font-weight: var(--rf-font-weight-semibold);
  letter-spacing: 0;
  text-transform: uppercase;
}

.rf-sidebar__group + .rf-sidebar__group {
  padding-top: var(--rf-space-2);
}

.rf-sidebar__group--management {
  gap: var(--rf-space-2);
}

.rf-nav-link {
  position: relative;
  display: grid;
  min-height: 2.75rem;
  grid-template-columns: 1.25rem minmax(0, 1fr);
  align-items: center;
  gap: var(--rf-space-3);
  border: 1px solid transparent;
  border-radius: var(--rf-radius-md);
  padding: 0.65rem var(--rf-space-3);
  color: rgb(252 251 250 / 0.76);
  text-decoration: none;
  transition:
    background-color var(--rf-transition-duration) var(--rf-transition-timing),
    border-color var(--rf-transition-duration) var(--rf-transition-timing),
    color var(--rf-transition-duration) var(--rf-transition-timing);
}

.rf-nav-link i {
  color: var(--rf-color-rose);
  font-size: var(--rf-font-size-lg);
  line-height: 1;
  text-align: center;
}

.rf-nav-link:focus-visible,
.rf-nav-submenu__button:focus-visible,
.rf-sidebar__toggle:focus-visible {
  outline: 0;
  box-shadow: 0 0 0 3px rgb(214 194 187 / 0.25);
}

.rf-nav-link:hover,
.rf-nav-link:focus {
  border-color: rgb(214 194 187 / 0.2);
  background: rgb(255 255 255 / 0.06);
  color: var(--rf-color-surface);
}

.rf-nav-link.is-active {
  border-color: rgb(214 194 187 / 0.32);
  background: rgb(181 154 145 / 0.16);
  color: var(--rf-color-surface);
  font-weight: var(--rf-font-weight-semibold);
}

.rf-nav-link.is-active i {
  color: var(--rf-color-rose-light);
}

.rf-nav-link.is-active::before {
  position: absolute;
  top: 0.625rem;
  bottom: 0.625rem;
  left: -1px;
  width: 3px;
  border-radius: 999px;
  background: var(--rf-color-rose);
  content: "";
}

.rf-nav-link--with-badge {
  grid-template-columns: 1.25rem minmax(0, 1fr) auto;
}

.rf-nav-link--disabled,
.rf-nav-link--tech {
  grid-template-columns: 1.25rem minmax(0, 1fr) auto;
}

.rf-nav-link--child {
  min-height: 2.4rem;
  margin-left: var(--rf-space-4);
  padding-block: 0.55rem;
  font-size: var(--rf-font-size-sm);
}

.rf-nav-link--child::after {
  position: absolute;
  top: 0.75rem;
  bottom: 0.75rem;
  left: -0.55rem;
  width: 1px;
  border-radius: 999px;
  background: rgb(214 194 187 / 0.16);
  content: "";
}

.rf-nav-link--disabled {
  cursor: not-allowed;
  opacity: 0.62;
}

.rf-nav-link--disabled:hover,
.rf-nav-link--disabled:focus {
  border-color: transparent;
  background: transparent;
  color: rgb(252 251 250 / 0.76);
}

.rf-sidebar__meta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgb(214 194 187 / 0.22);
  border-radius: 999px;
  padding: 0.1rem 0.35rem;
  color: rgb(252 251 250 / 0.62);
  font-size: 0.625rem;
  font-weight: var(--rf-font-weight-semibold);
  line-height: 1.1;
  white-space: nowrap;
}

.rf-sidebar__label {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.rf-nav-submenu {
  display: grid;
  gap: var(--rf-space-1);
}

.rf-nav-submenu__button {
  position: relative;
  display: grid;
  width: 100%;
  min-height: 2.75rem;
  grid-template-columns: 1.25rem minmax(0, 1fr) auto;
  align-items: center;
  gap: var(--rf-space-3);
  border: 1px solid transparent;
  border-radius: var(--rf-radius-md);
  padding: 0.65rem var(--rf-space-3);
  background: transparent;
  color: rgb(252 251 250 / 0.76);
  font: inherit;
  text-align: left;
  transition:
    background-color var(--rf-transition-duration) var(--rf-transition-timing),
    border-color var(--rf-transition-duration) var(--rf-transition-timing),
    color var(--rf-transition-duration) var(--rf-transition-timing);
}

.rf-nav-submenu__button i:first-child {
  color: var(--rf-color-rose);
  font-size: var(--rf-font-size-lg);
  line-height: 1;
  text-align: center;
}

.rf-nav-submenu__button:hover,
.rf-nav-submenu__button:focus {
  border-color: rgb(214 194 187 / 0.18);
  background: rgb(255 255 255 / 0.05);
  color: var(--rf-color-surface);
}

.rf-nav-submenu__button.is-active {
  color: var(--rf-color-surface);
  font-weight: var(--rf-font-weight-semibold);
}

.rf-nav-submenu__button.is-active::before {
  position: absolute;
  top: 0.625rem;
  bottom: 0.625rem;
  left: -1px;
  width: 3px;
  border-radius: 999px;
  background: var(--rf-color-rose);
  content: "";
}

.rf-nav-submenu__chevron {
  color: rgb(252 251 250 / 0.62);
  font-size: var(--rf-font-size-sm);
  transition: transform var(--rf-transition-duration) var(--rf-transition-timing);
}

.rf-nav-submenu.is-open .rf-nav-submenu__chevron,
.rf-nav-submenu__button[aria-expanded="true"] .rf-nav-submenu__chevron {
  transform: rotate(180deg);
}

.rf-nav-submenu__items {
  display: grid;
  gap: var(--rf-space-1);
}

.rf-nav-submenu__items[hidden] {
  display: none;
}

.rf-sidebar__technical {
  margin-top: var(--rf-space-2);
  padding-top: var(--rf-space-2);
  border-top: 1px solid rgb(214 194 187 / 0.14);
}

.rf-sidebar__badge {
  display: inline-flex;
  min-width: 1.45rem;
  height: 1.45rem;
  align-items: center;
  justify-content: center;
  border: 1px solid rgb(214 194 187 / 0.5);
  border-radius: 999px;
  background: var(--rf-color-rose);
  color: var(--rf-color-graphite);
  font-size: var(--rf-font-size-xs);
  font-weight: var(--rf-font-weight-bold);
  line-height: 1;
}

.rf-content {
  min-width: 0;
}

.rf-header {
  position: sticky;
  top: 0;
  z-index: 1020;
  min-height: var(--rf-header-height);
  border-bottom: var(--rf-border-subtle);
  background: var(--rf-color-surface);
  box-shadow: var(--rf-shadow-xs);
}

.rf-header__inner {
  display: flex;
  min-height: var(--rf-header-height);
  align-items: center;
  justify-content: space-between;
  gap: var(--rf-space-4);
  padding: 0.75rem var(--rf-space-4);
}

.rf-header__title-group {
  display: flex;
  min-width: 0;
  align-items: center;
  gap: var(--rf-space-3);
}

.rf-header__sidebar-toggle,
.rf-header__icon-button,
.rf-user-menu {
  border: var(--rf-border-subtle);
  background: var(--rf-color-surface);
  color: var(--rf-color-text);
}

.rf-header__sidebar-toggle,
.rf-header__icon-button {
  width: 2.5rem;
  min-height: 2.5rem;
  flex: 0 0 2.5rem;
  border-radius: var(--rf-radius-md);
  padding: 0;
}

.rf-header__sidebar-toggle:hover,
.rf-header__icon-button:hover,
.rf-user-menu:hover {
  border-color: var(--rf-color-rose);
  background: rgb(214 194 187 / 0.18);
  color: var(--rf-color-text);
}

.rf-header__title-copy {
  min-width: 0;
}

.rf-header__title {
  color: var(--rf-color-text);
  font-weight: var(--rf-font-weight-semibold);
}

.rf-header__subtitle {
  overflow: hidden;
  color: var(--rf-color-text-muted);
  font-size: var(--rf-font-size-sm);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.rf-header__actions {
  display: flex;
  flex: 0 0 auto;
  align-items: center;
  gap: var(--rf-space-3);
}

.rf-header__icon-button {
  position: relative;
  text-decoration: none;
}

.rf-header__icon-button i {
  font-size: var(--rf-font-size-lg);
  line-height: 1;
}

.rf-header__notification-count {
  position: absolute;
  top: -0.35rem;
  right: -0.35rem;
  display: inline-flex;
  min-width: 1.25rem;
  height: 1.25rem;
  align-items: center;
  justify-content: center;
  border: 2px solid var(--rf-color-surface);
  border-radius: 999px;
  background: var(--rf-color-rose);
  color: var(--rf-color-graphite);
  font-size: 0.6875rem;
  font-weight: var(--rf-font-weight-bold);
  line-height: 1;
}

.rf-user-menu {
  display: inline-flex;
  min-height: 2.5rem;
  align-items: center;
  gap: var(--rf-space-2);
  border-radius: var(--rf-radius-md);
  padding: 0.25rem 0.625rem 0.25rem 0.25rem;
}

.rf-user-menu__avatar {
  display: inline-flex;
  width: 2rem;
  height: 2rem;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: var(--rf-color-graphite);
  color: var(--rf-color-rose-light);
  font-size: var(--rf-font-size-xs);
  font-weight: var(--rf-font-weight-bold);
  line-height: 1;
  text-transform: uppercase;
}

.rf-user-menu__name {
  display: inline-block;
  max-width: 12rem;
  overflow: hidden;
  color: var(--rf-color-text);
  font-size: var(--rf-font-size-sm);
  font-weight: var(--rf-font-weight-medium);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.rf-user-menu__dropdown {
  min-width: 15rem;
  border: var(--rf-border-subtle);
  border-radius: var(--rf-radius-md);
  box-shadow: var(--rf-shadow-md);
}

.rf-user-menu__summary {
  display: grid;
  gap: var(--rf-space-1);
  padding: var(--rf-space-2) var(--rf-space-4);
}

.rf-user-menu__summary-name {
  color: var(--rf-color-text);
  font-size: var(--rf-font-size-sm);
  font-weight: var(--rf-font-weight-semibold);
}

.rf-user-menu__summary-email {
  overflow: hidden;
  color: var(--rf-color-text-muted);
  font-size: var(--rf-font-size-xs);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.rf-user-menu__item {
  display: flex;
  width: 100%;
  align-items: center;
  justify-content: flex-start;
  gap: var(--rf-space-2);
  border: 0;
  border-radius: 0;
  background: transparent;
  color: var(--rf-color-text);
  font-size: var(--rf-font-size-sm);
  text-align: left;
}

.rf-user-menu__item i {
  color: var(--rf-color-rose-dark);
  font-size: var(--rf-font-size-base);
}

.rf-user-menu__item:hover,
.rf-user-menu__item:focus {
  background: rgb(214 194 187 / 0.22);
  color: var(--rf-color-text);
}

.rf-card-label {
  margin-bottom: 0.35rem;
  color: var(--rf-color-text-muted);
  font-size: var(--rf-font-size-sm);
}

.rf-card-value {
  margin-bottom: 0;
  font-size: var(--rf-font-size-xl);
  font-weight: var(--rf-font-weight-bold);
}

table {
  width: 100%;
  border-collapse: collapse;
  background: var(--rf-color-surface);
  color: var(--rf-color-text);
  font-size: var(--rf-font-size-sm);
}

caption {
  margin-bottom: var(--rf-space-3);
  color: var(--rf-color-text-muted);
  text-align: left;
}

th,
td {
  border-bottom: var(--rf-border-subtle);
  padding: 0.75rem var(--rf-space-4);
  text-align: left;
  vertical-align: middle;
}

th {
  color: var(--rf-color-text-muted);
  font-size: var(--rf-font-size-xs);
  font-weight: var(--rf-font-weight-semibold);
  letter-spacing: 0;
  text-transform: uppercase;
}

tbody tr:hover {
  background: rgb(214 194 187 / 0.18);
}

.rf-badge {
  display: inline-flex;
  min-height: 1.5rem;
  align-items: center;
  border: var(--rf-border-width) solid var(--rf-color-border);
  border-radius: 999px;
  padding: 0.125rem 0.625rem;
  background: var(--rf-color-surface);
  color: var(--rf-color-text-muted);
  font-size: var(--rf-font-size-xs);
  font-weight: var(--rf-font-weight-medium);
  line-height: 1.2;
}

.rf-badge--success {
  border-color: var(--rf-color-success-border);
  background: var(--rf-color-success-bg);
  color: var(--rf-color-success);
}

.rf-badge--warning {
  border-color: var(--rf-color-warning-border);
  background: var(--rf-color-warning-bg);
  color: var(--rf-color-warning);
}

.rf-badge--error {
  border-color: var(--rf-color-error-border);
  background: var(--rf-color-error-bg);
  color: var(--rf-color-error);
}

.rf-badge--info {
  border-color: var(--rf-color-info-border);
  background: var(--rf-color-info-bg);
  color: var(--rf-color-info);
}

.rf-status-badge {
  display: inline-flex;
  min-height: 1.75rem;
  align-items: center;
  gap: var(--rf-space-2);
  border: var(--rf-border-width) solid var(--rf-color-border);
  border-radius: 999px;
  padding: 0.1875rem 0.625rem;
  background: var(--rf-color-surface);
  color: var(--rf-color-text-muted);
  font-size: var(--rf-font-size-xs);
  font-weight: var(--rf-font-weight-semibold);
  line-height: 1.2;
  white-space: nowrap;
}

.rf-status-badge__dot {
  width: 0.5rem;
  height: 0.5rem;
  border-radius: 999px;
  background: currentcolor;
}

.rf-status-badge--pending {
  border-color: var(--rf-color-warning-border);
  background: var(--rf-color-warning-bg);
  color: var(--rf-color-warning);
}

.rf-status-badge--processing {
  border-color: var(--rf-color-info-border);
  background: var(--rf-color-info-bg);
  color: var(--rf-color-info);
}

.rf-status-badge--completed,
.rf-status-badge--active,
.rf-status-badge--ativo {
  border-color: var(--rf-color-success-border);
  background: var(--rf-color-success-bg);
  color: var(--rf-color-success);
}

.rf-status-badge--failed {
  border-color: var(--rf-color-error-border);
  background: var(--rf-color-error-bg);
  color: var(--rf-color-error);
}

.rf-status-badge--cancelled,
.rf-status-badge--inactive,
.rf-status-badge--inativo {
  border-color: var(--rf-color-border);
  background: #efebea;
  color: var(--rf-color-text-muted);
}

.rf-alert {
  border: var(--rf-border-width) solid var(--rf-color-border);
  border-radius: var(--rf-radius-md);
  padding: var(--rf-space-4);
  background: var(--rf-color-surface);
  color: var(--rf-color-text);
  box-shadow: var(--rf-shadow-xs);
}

.rf-alert--success {
  border-color: var(--rf-color-success-border);
  background: var(--rf-color-success-bg);
  color: var(--rf-color-success);
}

.rf-alert--warning {
  border-color: var(--rf-color-warning-border);
  background: var(--rf-color-warning-bg);
  color: var(--rf-color-warning);
}

.rf-alert--error {
  border-color: var(--rf-color-error-border);
  background: var(--rf-color-error-bg);
  color: var(--rf-color-error);
}

.rf-alert--info {
  border-color: var(--rf-color-info-border);
  background: var(--rf-color-info-bg);
  color: var(--rf-color-info);
}

.rf-alert__title {
  margin: 0 0 var(--rf-space-1);
  font-size: var(--rf-font-size-sm);
  font-weight: var(--rf-font-weight-semibold);
}

.rf-alert__content {
  margin: 0;
  font-size: var(--rf-font-size-sm);
}

.rf-confirmation-modal {
  position: fixed;
  inset: 0;
  z-index: 1080;
  display: grid;
  place-items: center;
  padding: var(--rf-space-4);
  background: rgb(41 41 53 / 0.52);
}

.rf-confirmation-modal[hidden] {
  display: none;
}

.rf-confirmation-modal__dialog {
  width: min(100%, 30rem);
  border: var(--rf-border-subtle);
  border-radius: var(--rf-radius-lg);
  padding: var(--rf-space-6);
  background: var(--rf-color-surface);
  box-shadow: var(--rf-shadow-md);
}

.rf-confirmation-modal__header {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: var(--rf-space-3);
  align-items: center;
  margin-bottom: var(--rf-space-4);
}

.rf-confirmation-modal__icon {
  display: inline-flex;
  width: 2.5rem;
  height: 2.5rem;
  align-items: center;
  justify-content: center;
  border-radius: var(--rf-radius-md);
  background: rgb(181 154 145 / 0.18);
  color: var(--rf-color-rose-dark);
  font-size: var(--rf-font-size-lg);
}

.rf-confirmation-modal__title {
  margin: 0;
  font-size: var(--rf-font-size-xl);
}

.rf-confirmation-modal__message {
  margin: 0;
  color: var(--rf-color-text-muted);
}

.rf-confirmation-modal__actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: var(--rf-space-3);
  margin-top: var(--rf-space-6);
}

.rf-confirmation-modal--danger .rf-confirmation-modal__dialog {
  border-color: var(--rf-color-error-border);
}

.rf-confirmation-modal--danger .rf-confirmation-modal__icon {
  background: var(--rf-color-error-bg);
  color: var(--rf-color-error);
}

.rf-button--danger {
  border-color: var(--rf-color-error);
  background: var(--rf-color-error);
  color: var(--rf-color-surface);
}

.rf-button--danger:hover {
  border-color: #8f3434;
  background: #8f3434;
  color: var(--rf-color-surface);
}

.rf-empty-state {
  display: grid;
  justify-items: center;
  gap: var(--rf-space-4);
  border: 1px dashed var(--rf-color-border);
  border-radius: var(--rf-radius-lg);
  padding: var(--rf-space-10) var(--rf-space-6);
  background: rgb(252 251 250 / 0.76);
  text-align: center;
}

.rf-empty-state__icon {
  display: inline-flex;
  width: 3rem;
  height: 3rem;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: rgb(181 154 145 / 0.16);
  color: var(--rf-color-rose-dark);
  font-size: var(--rf-font-size-xl);
}

.rf-empty-state__content {
  max-width: 32rem;
}

.rf-empty-state__title {
  margin-bottom: var(--rf-space-2);
  font-size: var(--rf-font-size-xl);
}

.rf-empty-state__description {
  margin: 0;
  color: var(--rf-color-text-muted);
}

.rf-page-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--rf-space-5);
  margin-bottom: var(--rf-space-6);
}

.rf-page-header__content {
  min-width: 0;
}

.rf-page-header__eyebrow {
  margin: 0 0 var(--rf-space-1);
  color: var(--rf-color-rose-dark);
  font-size: var(--rf-font-size-xs);
  font-weight: var(--rf-font-weight-bold);
  letter-spacing: 0;
  text-transform: uppercase;
}

.rf-page-header__title {
  margin-bottom: var(--rf-space-2);
}

.rf-page-header__subtitle {
  max-width: 48rem;
  margin: 0;
  color: var(--rf-color-text-muted);
}

.rf-page-header__actions {
  display: flex;
  flex: 0 0 auto;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: var(--rf-space-3);
}

.rf-pagination {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--rf-space-4);
  margin-top: var(--rf-space-5);
}

.rf-table-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--rf-space-4);
  margin-bottom: var(--rf-space-3);
}

.rf-per-page {
  display: inline-flex;
  align-items: center;
  gap: var(--rf-space-2);
  width: auto;
  max-width: 100%;
  margin: 0;
  color: var(--rf-color-text-muted);
  font-size: var(--rf-font-size-sm);
}

.rf-per-page__label,
.rf-per-page__suffix {
  margin-bottom: 0;
  color: var(--rf-color-text-muted);
  font-size: var(--rf-font-size-sm);
  font-weight: var(--rf-font-weight-medium);
  white-space: nowrap;
}

.rf-per-page__select {
  width: 4.75rem;
  min-width: 4.75rem;
  flex: 0 0 4.75rem;
  padding-block: 0.5rem;
  padding-inline: 0.625rem;
}

.rf-per-page__button {
  min-height: 2.25rem;
  padding-block: 0.5rem;
}

.rf-pagination__summary {
  color: var(--rf-color-text-muted);
  font-size: var(--rf-font-size-sm);
}

.rf-pagination__list {
  display: flex;
  align-items: center;
  gap: var(--rf-space-1);
  padding: 0;
  margin: 0;
  list-style: none;
}

.rf-pagination__link {
  display: inline-flex;
  min-width: 2.25rem;
  height: 2.25rem;
  align-items: center;
  justify-content: center;
  border: var(--rf-border-subtle);
  border-radius: var(--rf-radius-md);
  background: var(--rf-color-surface);
  color: var(--rf-color-text);
  font-size: var(--rf-font-size-sm);
  font-weight: var(--rf-font-weight-medium);
  text-decoration: none;
}

.rf-pagination__link:hover {
  border-color: var(--rf-color-rose);
  background: rgb(214 194 187 / 0.18);
  color: var(--rf-color-text);
}

.rf-pagination__link.is-active {
  border-color: var(--rf-color-graphite);
  background: var(--rf-color-graphite);
  color: var(--rf-color-surface);
}

.rf-pagination__link.is-disabled {
  color: var(--rf-color-text-muted);
  opacity: 0.56;
}

.rf-loading {
  display: inline-flex;
  align-items: center;
  gap: var(--rf-space-2);
  color: var(--rf-color-text-muted);
  font-size: var(--rf-font-size-sm);
}

.rf-loading::before {
  width: 1rem;
  height: 1rem;
  border: 2px solid var(--rf-color-border);
  border-top-color: var(--rf-color-rose);
  border-radius: 999px;
  content: "";
  animation: rf-spin 800ms linear infinite;
}

.rf-skeleton {
  min-height: 1rem;
  border-radius: var(--rf-radius-sm);
  background: linear-gradient(
    90deg,
    rgb(228 222 220 / 0.48),
    rgb(252 251 250 / 0.88),
    rgb(228 222 220 / 0.48)
  );
  background-size: 200% 100%;
  animation: rf-skeleton 1200ms ease-in-out infinite;
}

@keyframes rf-spin {
  to {
    transform: rotate(360deg);
  }
}

@keyframes rf-skeleton {
  to {
    background-position-x: -200%;
  }
}

:focus {
  outline: 2px solid var(--rf-color-rose);
  outline-offset: 2px;
}

:focus-visible {
  outline: 2px solid var(--rf-color-rose);
  outline-offset: 2px;
  box-shadow: var(--rf-shadow-focus);
}

:focus:not(:focus-visible) {
  outline: none;
  box-shadow: none;
}

::selection {
  background: var(--rf-color-rose-light);
  color: var(--rf-color-graphite);
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }
}

@media (max-width: 991.98px) {
  .rf-shell {
    display: block;
  }

  .rf-sidebar {
    position: fixed;
    top: auto;
    inset: 0 auto 0 0;
    z-index: 1050;
    width: min(var(--rf-sidebar-width), 86vw);
    max-width: 21rem;
    height: 100vh;
    overflow-y: auto;
    border-right: 1px solid rgb(214 194 187 / 0.14);
    border-bottom: 0;
    transform: translateX(-100%);
    transition: transform var(--rf-transition-duration-slow)
      var(--rf-transition-timing);
  }

  body.rf-mobile-sidebar-open .rf-sidebar {
    transform: translateX(0);
  }

  body.rf-mobile-sidebar-open .rf-sidebar-overlay {
    opacity: 1;
    pointer-events: auto;
  }

  .rf-content {
    width: 100%;
    margin-left: 0;
  }

  .rf-header__inner {
    gap: var(--rf-space-3);
    padding-inline: var(--rf-space-3);
  }

  .rf-header__title-group {
    flex: 1 1 auto;
    min-width: 0;
  }

  .rf-header__title-copy {
    min-width: 0;
  }

  .rf-header__subtitle {
    max-width: 44vw;
  }

  .rf-header__actions {
    gap: var(--rf-space-2);
  }

  .rf-user-menu {
    padding-right: 0.25rem;
  }

  .rf-user-menu__name,
  .rf-user-menu > .bi-chevron-down {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
  }

  .rf-card__header,
  .rf-card__footer,
  .rf-action-bar,
  .rf-page-header,
  .rf-pagination {
    align-items: stretch;
    flex-direction: column;
  }

  .rf-action-bar__group,
  .rf-filter-bar__group,
  .rf-page-header__actions {
    width: 100%;
    justify-content: flex-start;
  }

  .rf-page-header__actions form {
    width: 100%;
  }

  .rf-action-bar .rf-button,
  .rf-page-header__actions .rf-button {
    width: 100%;
  }

  .rf-filter-bar__field {
    flex-basis: 100%;
  }

  .rf-pagination__list {
    flex-wrap: wrap;
  }

  .rf-table-toolbar {
    flex-wrap: wrap;
    justify-content: flex-start;
  }

  .rf-per-page {
    flex-wrap: wrap;
    justify-content: flex-start;
  }

  .rf-public-card,
  .rf-error-card {
    padding: var(--rf-space-6);
  }

  .rf-empty-state {
    padding: var(--rf-space-8) var(--rf-space-4);
  }

  .rf-confirmation-modal {
    align-items: end;
    padding: var(--rf-space-3);
  }

  .rf-confirmation-modal__dialog {
    padding: var(--rf-space-5);
  }

  .rf-confirmation-modal__actions {
    flex-direction: column-reverse;
  }

  .rf-confirmation-modal__actions .rf-button {
    width: 100%;
  }

  .rf-dashboard-metrics,
  .rf-dashboard-shortcuts,
  .rf-dashboard-grid,
  .rf-management-grid {
    grid-template-columns: 1fr;
  }

  .rf-dashboard-shortcut {
    min-height: 4.25rem;
  }

  .rf-report-category__header {
    align-items: stretch;
    flex-direction: column;
  }

  .rf-report-grid,
  .rf-report-card__meta,
  .rf-report-detail-layout,
  .rf-detail-list div {
    grid-template-columns: 1fr;
  }

  .rf-report-detail__topline {
    align-items: stretch;
    flex-direction: column;
  }

  .rf-execution-detail-layout,
  .rf-execution-detail-grid {
    grid-template-columns: 1fr;
  }

  .rf-execution-summary__header {
    align-items: stretch;
    flex-direction: column;
  }

  .rf-department-primary,
  .rf-department-grid {
    grid-template-columns: 1fr;
  }

  .rf-department-primary__status {
    justify-self: start;
  }

  .rf-department-card__header {
    align-items: stretch;
    flex-direction: column;
  }

  .rf-profile-layout,
  .rf-profile-grid {
    grid-template-columns: 1fr;
  }

  .rf-profile-card {
    align-items: flex-start;
    flex-direction: column;
  }

  .rf-notification-item {
    grid-template-columns: 1fr;
  }

  .rf-notification-item__header {
    align-items: stretch;
    flex-direction: column;
  }

  .rf-notification-item__badges,
  .rf-notification-item__actions {
    justify-content: flex-start;
  }

  .rf-management-list__item,
  .rf-permission-list li {
    align-items: stretch;
    flex-direction: column;
  }

  .rf-permission-module__actions {
    justify-content: flex-start;
  }

  .rf-management-list__actions {
    justify-content: flex-start;
  }

  .rf-schedule-form__report,
  .rf-schedule-form__grid,
  .rf-management-form__grid {
    grid-template-columns: 1fr;
  }

  .rf-schedule-form__actions,
  .rf-management-form__actions {
    position: static;
  }
}

@media (min-width: 992px) {
  .rf-sidebar {
    position: fixed;
    inset: 0 auto 0 0;
    z-index: 1030;
    height: 100vh;
    overflow-y: auto;
  }

  .rf-content {
    margin-left: var(--rf-sidebar-width);
    transition: margin-left var(--rf-transition-duration-slow)
      var(--rf-transition-timing);
  }

  body.rf-sidebar-collapsed .rf-sidebar {
    width: var(--rf-sidebar-collapsed-width);
  }

  body.rf-sidebar-collapsed .rf-content {
    margin-left: var(--rf-sidebar-collapsed-width);
  }

  body.rf-sidebar-collapsed .rf-sidebar__inner {
    padding-inline: var(--rf-space-3);
  }

  body.rf-sidebar-collapsed .rf-sidebar__brand-row {
    justify-content: center;
  }

  body.rf-sidebar-collapsed .rf-brand {
    justify-content: center;
  }

  body.rf-sidebar-collapsed .rf-sidebar__label,
  body.rf-sidebar-collapsed .rf-sidebar__group-label {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
  }

  body.rf-sidebar-collapsed .rf-sidebar__toggle {
    position: absolute;
    top: var(--rf-space-4);
    right: -1rem;
    box-shadow: var(--rf-shadow-sm);
  }

  body.rf-sidebar-collapsed .rf-nav-link {
    grid-template-columns: 1fr;
    justify-items: center;
    padding-inline: 0;
  }

  body.rf-sidebar-collapsed .rf-nav-submenu__button {
    grid-template-columns: 1fr;
    justify-items: center;
    padding-inline: 0;
  }

  body.rf-sidebar-collapsed .rf-nav-link--with-badge {
    grid-template-columns: 1fr;
  }

  body.rf-sidebar-collapsed .rf-nav-link--disabled,
  body.rf-sidebar-collapsed .rf-nav-link--tech,
  body.rf-sidebar-collapsed .rf-nav-link--child {
    grid-template-columns: 1fr;
  }

  body.rf-sidebar-collapsed .rf-nav-link--child {
    margin-left: 0;
  }

  body.rf-sidebar-collapsed .rf-nav-link--child::after,
  body.rf-sidebar-collapsed .rf-nav-submenu__button::before {
    display: none;
  }

  body.rf-sidebar-collapsed .rf-sidebar__meta,
  body.rf-sidebar-collapsed .rf-nav-submenu__chevron {
    display: none;
  }

  body.rf-sidebar-collapsed .rf-sidebar__badge {
    position: absolute;
    top: 0.35rem;
    right: 0.35rem;
    min-width: 1rem;
    height: 1rem;
    padding: 0 0.25rem;
    font-size: 0.625rem;
  }
}

@media (min-width: 768px) and (max-width: 991.98px) {
  .rf-dashboard-metrics,
  .rf-dashboard-shortcuts,
  .rf-dashboard-grid,
  .rf-management-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
