:where(.ui-panel) {
  border: 1px solid var(--ui-color-line);
  border-radius: var(--ui-radius-lg);
  background: var(--ui-color-surface);
  box-shadow: var(--ui-shadow-soft);
}

:where(.ui-button) {
  min-height: var(--ui-control-height);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 var(--ui-space-3);
  border: 0;
  border-radius: var(--ui-radius-sm);
  background: var(--ui-gradient-brand);
  color: #fff;
  font: 800 12px var(--ui-font-family);
  text-decoration: none;
  cursor: pointer;
}

:where(.ui-button--secondary) {
  border: 1px solid var(--ui-color-line);
  background: var(--ui-color-surface-soft);
  color: var(--ui-color-text);
}

:where(.ui-field) {
  min-width: 0;
  display: grid;
  gap: var(--ui-space-1);
}

:where(.ui-field > label) {
  color: var(--ui-color-text);
  font: 800 11px/1.35 var(--ui-font-family);
}

:where(.ui-control) {
  width: 100%;
  min-width: 0;
  min-height: var(--ui-control-height);
  padding: 5px 9px;
  border: 1px solid var(--ui-color-line);
  border-radius: var(--ui-radius-sm);
  background: var(--ui-color-surface);
  color: var(--ui-color-text);
  font: 700 12px var(--ui-font-family);
}

:where(.ui-alert) {
  padding: 10px 12px;
  border: 1px solid var(--ui-color-line);
  border-radius: var(--ui-radius-md);
  background: var(--ui-color-surface-soft);
  color: var(--ui-color-text);
  font-weight: 800;
}

:where(.ui-alert--success) { color: var(--ui-color-success); }
:where(.ui-alert--warning) { color: var(--ui-color-warning); }
:where(.ui-alert--danger) { color: var(--ui-color-danger); }

/* Shared interactive components rendered by the application runtime. */
:where(.smart-select-list, .project-date-picker) {
  border: 1px solid var(--ui-color-line);
  border-radius: var(--ui-radius-md);
  background: var(--ui-color-surface);
  color: var(--ui-color-text);
  box-shadow: var(--ui-shadow-modal);
}

:where(.smart-select-option, .smart-select-empty) {
  border-radius: var(--ui-radius-sm);
  color: var(--ui-color-text);
  font-size: 13px;
  font-weight: 800;
  line-height: 1.6;
}

:where(.smart-select-option:hover, .smart-select-option.is-selected, .smart-select-option.is-active) {
  background: var(--ui-color-row-hover);
  color: var(--ui-color-primary-strong);
}

:where(.smart-select-empty) {
  color: var(--ui-color-muted);
}

:where(.project-date-picker-week) {
  color: var(--ui-color-muted);
  font-size: 11px;
  font-weight: 800;
}

:where(.project-date-picker-day) {
  border: 0;
  background: var(--ui-color-surface-soft);
  color: var(--ui-color-text);
  box-shadow: none;
}

:where(.project-date-picker-day:hover, .project-date-picker-day.is-selected) {
  background: var(--ui-gradient-brand);
  color: var(--ui-color-surface);
}

:where(.badge, .role-pill, .type-badge, .status-pill, .record-count) {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--ui-color-line);
  border-radius: 999px;
  background: var(--ui-color-surface-soft);
  color: var(--ui-color-primary-strong);
  font-weight: 800;
}
