
/* ==========================================================================
   Portal42 Design System
   Version: 0.1
   Purpose: Shared visual language for Portal42 UI
   Notes:
   - Preserve the existing footer implementation.
   - Apply incrementally; do not rewrite business logic.
   - Prefer these variables/classes over one-off inline styles.
   ========================================================================== */

:root {
  /* Brand */
  --p42-teal: #35c8eb;
  --p42-teal-strong: #18b9df;
  --p42-purple: #7e5bff;
  --p42-purple-strong: #6845eb;
  --p42-pink: #f06bb4;
  /* primary: the one colour to override per shop or for white labelling */
  --p42-primary: var(--p42-purple);
  --p42-primary-strong: var(--p42-purple-strong);
  --p42-primary-wash: rgba(126, 91, 255, .10);
  --p42-primary-wash-strong: rgba(126, 91, 255, .18);
  --p42-primary-ink: var(--p42-primary-strong);
  --p42-indigo: #1f2754;
  --p42-indigo-deep: #151c3d;

  /* Surfaces */
  --p42-bg: #f7f9fc;
  --p42-surface: #ffffff;
  --p42-surface-soft: #f4f7fb;
  --p42-surface-hover: #eef3f8;
  --p42-sidebar: #2d3642;
  --p42-sidebar-deep: #222b37;

  /* Text */
  --p42-text: #202936;
  --p42-text-strong: #101828;
  --p42-text-muted: #667085;
  --p42-text-subtle: #98a2b3;
  --p42-text-on-dark: #f7f9fc;
  --p42-text-on-dark-muted: #aeb8c5;

  /* Borders */
  --p42-border: #dbe2ea;
  --p42-border-soft: #e9eef4;
  --p42-border-dark: rgba(255,255,255,.10);

  /* Status */
  --p42-success: #16a36b;
  --p42-success-bg: #ecfdf3;
  --p42-warning: #b7791f;
  --p42-warning-bg: #fff8e6;
  --p42-danger: #a91543;
  --p42-danger-bg: #fff0f3;
  --p42-info: #2675c9;
  --p42-info-bg: #eef6ff;

  /* Radius */
  --p42-r-xs: 4px;
  --p42-r-sm: 8px;
  --p42-r-md: 12px;
  --p42-r-lg: 16px;
  --p42-r-xl: 22px;
  --p42-r-pill: 999px;

  /* Shadows */
  --p42-shadow-xs: 0 1px 2px rgba(16,24,40,.05);
  --p42-shadow-pressed: inset 0 2px 4px rgba(16,24,40,.14);
  --p42-shadow-sm: 0 4px 12px rgba(16,24,40,.08);
  --p42-shadow-md: 0 10px 28px rgba(16,24,40,.12);
  --p42-shadow-sidebar: 0 12px 32px rgba(0,0,0,.22);

  /* Focus */
  --p42-focus-ring: 0 0 0 3px rgba(53,200,235,.20);

  /* Spacing */
  --p42-1: 4px;
  --p42-2: 8px;
  --p42-3: 12px;
  --p42-4: 16px;
  --p42-5: 20px;
  --p42-6: 24px;
  --p42-8: 32px;
  --p42-10: 40px;

  /* Motion */
  --p42-ease: 160ms ease;

  /* Header */
  --p42-header-bg: rgba(255, 255, 255, .96);
  --p42-header-shadow: 0 2px 10px rgba(16, 24, 40, .04);
  --p42-header-btn-radius: 10px;
  --p42-header-edge: linear-gradient(90deg, var(--p42-teal) 0%, var(--p42-teal) 55%, var(--p42-pink) 100%);
  --p42-header-edge-size: 3px;
  --p42-header-btn-bg: var(--p42-surface-soft);
  --p42-header-btn-border: var(--p42-border-soft);
  --p42-header-btn-hover: var(--p42-primary-wash);
  --p42-header-btn-active: var(--p42-primary-wash-strong);
  --p42-dropdown-radius: 14px;
  --p42-dropdown-shadow: 0 12px 32px rgba(20, 26, 58, .18);

  /* Frame: the side menu wears the footer's ground (inc/views/base_footer.php) */
  --p42-frame-ground: #141a3a;
  --p42-frame-ground-deep: #0c1030;
  --p42-frame-backdrop:
    radial-gradient(160% 40% at 0% 100%, rgba(94, 63, 196, .42) 0%, rgba(94, 63, 196, 0) 60%),
    radial-gradient(160% 40% at 100% 85%, rgba(52, 146, 222, .30) 0%, rgba(52, 146, 222, 0) 62%),
    linear-gradient(180deg, var(--p42-frame-ground) 0%, var(--p42-frame-ground-deep) 100%);
  --p42-frame-edge: linear-gradient(180deg, var(--p42-teal) 0%, var(--p42-teal) 55%, var(--p42-pink) 100%);
  --p42-frame-text: #c9d4f5;
  --p42-frame-text-strong: #fff;
  --p42-frame-label: rgba(201, 212, 245, .65);
  --p42-frame-icon: rgba(201, 212, 245, .6);
  --p42-frame-hover: rgba(255, 255, 255, .06);
  --p42-frame-band: rgba(255, 255, 255, .03);
  --p42-frame-hairline: rgba(255, 255, 255, .08);
  --p42-frame-submenu: rgba(0, 0, 0, .12);
  --p42-frame-warning: #f3b760;
  --p42-nav-active: var(--p42-teal);
  --p42-nav-active-wash: rgba(53, 200, 235, .11);
}

/* Base */
.p42-ui,
.p42-ui * {
  box-sizing: border-box;
}

.p42-ui {
  color: var(--p42-text);
  background: var(--p42-bg);
}

/* --------------------------------------------------------------------------
   Panels / Cards
   -------------------------------------------------------------------------- */

.p42-panel {
  background: var(--p42-surface);
  border: 1px solid var(--p42-border-soft);
  border-radius: var(--p42-r-lg);
  box-shadow: var(--p42-shadow-xs);
}

.p42-panel--raised {
  box-shadow: var(--p42-shadow-sm);
}

.p42-panel__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--p42-4);
  padding: var(--p42-5) var(--p42-6);
  border-bottom: 1px solid var(--p42-border-soft);
}

.p42-panel__body {
  padding: var(--p42-6);
}

.p42-panel__footer {
  padding: var(--p42-4) var(--p42-6);
  border-top: 1px solid var(--p42-border-soft);
  background: var(--p42-surface-soft);
  border-radius: 0 0 var(--p42-r-lg) var(--p42-r-lg);
}

/* --------------------------------------------------------------------------
   Inputs
   -------------------------------------------------------------------------- */

.p42-field {
  display: flex;
  flex-direction: column;
  gap: var(--p42-2);
}

.p42-label {
  font-size: 13px;
  font-weight: 600;
  color: var(--p42-text);
}

.p42-help {
  font-size: 12px;
  color: var(--p42-text-muted);
}

.p42-input,
.p42-select,
.p42-textarea {
  width: 100%;
  min-height: 40px;
  padding: 9px 12px;
  border: 1px solid var(--p42-border);
  border-radius: var(--p42-r-md);
  background: var(--p42-surface);
  color: var(--p42-text-strong);
  box-shadow: var(--p42-shadow-xs);
  outline: none;
  transition: border-color var(--p42-ease),
              box-shadow var(--p42-ease),
              background var(--p42-ease);
}

.p42-textarea {
  min-height: 110px;
  resize: vertical;
}

.p42-input::placeholder,
.p42-textarea::placeholder {
  color: var(--p42-text-subtle);
}

.p42-input:hover,
.p42-select:hover,
.p42-textarea:hover {
  border-color: #c8d2de;
}

.p42-input:focus,
.p42-select:focus,
.p42-textarea:focus {
  border-color: var(--p42-teal);
  box-shadow: var(--p42-focus-ring);
}

.p42-input:disabled,
.p42-select:disabled,
.p42-textarea:disabled {
  color: var(--p42-text-subtle);
  background: var(--p42-surface-soft);
  cursor: not-allowed;
}

/* --------------------------------------------------------------------------
   Buttons
   -------------------------------------------------------------------------- */

.p42-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--p42-2);
  min-height: 38px;
  padding: 8px 13px;
  border: 1px solid transparent;
  border-radius: var(--p42-r-md);
  font-weight: 600;
  line-height: 1;
  cursor: pointer;
  transition: transform var(--p42-ease),
              background var(--p42-ease),
              border-color var(--p42-ease),
              box-shadow var(--p42-ease);
}

.p42-btn:hover {
  transform: translateY(-1px);
}

.p42-btn:focus-visible {
  outline: none;
  box-shadow: var(--p42-focus-ring);
}

.p42-btn--primary {
  color: #fff;
  background: linear-gradient(135deg, var(--p42-primary), var(--p42-primary-strong));
  box-shadow: 0 4px 12px rgba(126,91,255,.18);
}

.p42-btn--primary:hover {
  background: linear-gradient(135deg, #7450fa, #5f3ddd);
}

.p42-btn--teal {
  color: #073a49;
  background: #e9fbff;
  border-color: rgba(53,200,235,.45);
}

.p42-btn--teal:hover {
  background: #dcf8ff;
  border-color: var(--p42-teal);
}

.p42-btn--secondary {
  color: var(--p42-text);
  background: var(--p42-surface);
  border-color: var(--p42-border);
}

.p42-btn--secondary:hover {
  background: var(--p42-surface-soft);
}

.p42-btn--danger {
  color: var(--p42-danger);
  background: #fff;
  border-color: rgba(169,21,67,.35);
}

.p42-btn--danger:hover {
  background: var(--p42-danger-bg);
  border-color: rgba(169,21,67,.55);
}

.p42-btn--icon {
  width: 38px;
  min-width: 38px;
  padding: 0;
}

/* --------------------------------------------------------------------------
   Pills / Badges
   -------------------------------------------------------------------------- */

.p42-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 26px;
  padding: 5px 10px;
  border: 1px solid transparent;
  border-radius: var(--p42-r-pill);
  font-size: 12px;
  font-weight: 650;
  line-height: 1;
  white-space: nowrap;
}

.p42-pill--neutral {
  color: var(--p42-text-muted);
  background: var(--p42-surface-soft);
  border-color: var(--p42-border-soft);
}

.p42-pill--success {
  color: #08724c;
  background: var(--p42-success-bg);
  border-color: rgba(22,163,107,.18);
}

.p42-pill--warning {
  color: #8a5815;
  background: var(--p42-warning-bg);
  border-color: rgba(183,121,31,.18);
}

.p42-pill--danger {
  color: var(--p42-danger);
  background: var(--p42-danger-bg);
  border-color: rgba(169,21,67,.18);
}

.p42-pill--info {
  color: #1f65ad;
  background: var(--p42-info-bg);
  border-color: rgba(38,117,201,.16);
}

/* --------------------------------------------------------------------------
   Alerts
   -------------------------------------------------------------------------- */

.p42-alert {
  display: flex;
  gap: var(--p42-3);
  align-items: flex-start;
  padding: var(--p42-4) var(--p42-5);
  border: 1px solid var(--p42-border-soft);
  border-radius: var(--p42-r-md);
  background: var(--p42-surface);
}

.p42-alert--danger {
  color: var(--p42-danger);
  background: var(--p42-danger-bg);
  border-color: rgba(169,21,67,.14);
}

.p42-alert--success {
  color: #08724c;
  background: var(--p42-success-bg);
  border-color: rgba(22,163,107,.14);
}

.p42-alert--info {
  color: #1f65ad;
  background: var(--p42-info-bg);
  border-color: rgba(38,117,201,.14);
}

/* --------------------------------------------------------------------------
   Icons
   -------------------------------------------------------------------------- */

.p42-icon {
  width: 18px;
  height: 18px;
  flex: 0 0 auto;
  color: currentColor;
  stroke-width: 1.8;
}

.p42-icon--muted {
  color: var(--p42-text-subtle);
}

.p42-icon-button {
  position: relative;
  display: inline-grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border: 1px solid var(--p42-border);
  border-radius: var(--p42-r-md);
  background: var(--p42-surface);
  color: var(--p42-text-muted);
  cursor: pointer;
  transition: var(--p42-ease);
}

.p42-icon-button:hover {
  color: var(--p42-text-strong);
  background: var(--p42-surface-soft);
  border-color: #c8d2de;
}

/* --------------------------------------------------------------------------
   Header / Top Navigation
   -------------------------------------------------------------------------- */

.p42-header {
  min-height: 64px;
  display: flex;
  align-items: center;
  gap: var(--p42-4);
  padding: 10px 16px;
  background: rgba(255,255,255,.96);
  border-bottom: 1px solid var(--p42-border-soft);
  box-shadow: 0 2px 10px rgba(16,24,40,.04);
  backdrop-filter: blur(12px);
}

.p42-header__brand {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-right: var(--p42-4);
}

.p42-header__actions {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-left: auto;
}

.p42-header__action {
  min-height: 36px;
  padding: 7px 11px;
  border: 1px solid var(--p42-border);
  border-radius: 10px;
  background: #fff;
  color: var(--p42-text);
  font-size: 13px;
  font-weight: 600;
}

.p42-header__action:hover {
  background: var(--p42-surface-soft);
  border-color: #c8d2de;
}

/* --------------------------------------------------------------------------
   Sidebar
   -------------------------------------------------------------------------- */

.p42-sidebar {
  position: relative;
  background:
    linear-gradient(
      180deg,
      var(--p42-sidebar) 0%,
      #293441 64%,
      #252d45 84%,
      var(--p42-indigo-deep) 100%
    );
  color: var(--p42-text-on-dark);
  border-right: 1px solid var(--p42-border-dark);
  box-shadow: var(--p42-shadow-sidebar);
}

.p42-sidebar::before {
  content: "";
  position: absolute;
  top: 0;
  right: auto;
  bottom: 0;
  left: 0;
  width: 3px;
  background: linear-gradient(
    180deg,
    var(--p42-teal) 0%,
    var(--p42-teal) 55%,
    var(--p42-pink) 100%
  );
  box-shadow: 0 0 14px rgba(53,200,235,.20);
}

.p42-sidebar__section-title {
  padding: 18px 18px 8px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: rgba(174,184,197,.65);
}

.p42-sidebar__item {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 42px;
  margin: 2px 8px;
  padding: 9px 12px;
  border-radius: 10px;
  color: var(--p42-text-on-dark-muted);
  transition: background var(--p42-ease),
              color var(--p42-ease),
              transform var(--p42-ease);
}

.p42-sidebar__item:hover {
  color: #fff;
  background: rgba(255,255,255,.06);
}

.p42-sidebar__item.is-active {
  color: #fff;
  background: rgba(53,200,235,.11);
  box-shadow: inset 3px 0 0 var(--p42-teal);
}

.p42-sidebar__item.is-active .p42-icon {
  color: var(--p42-teal);
}

/* Expanded sidebar panel */
.p42-sidebar--expanded {
  width: 460px;
  border-radius: 0 0 0 var(--p42-r-xl);
  overflow: hidden;
}

.p42-sidebar--expanded .p42-sidebar__item {
  margin-inline: 14px;
}

/* --------------------------------------------------------------------------
   Tables
   -------------------------------------------------------------------------- */

.p42-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  background: var(--p42-surface);
  border: 1px solid var(--p42-border-soft);
  border-radius: var(--p42-r-lg);
  overflow: hidden;
}

.p42-table th {
  padding: 11px 14px;
  text-align: left;
  font-size: 12px;
  font-weight: 700;
  color: var(--p42-text-muted);
  background: var(--p42-surface-soft);
  border-bottom: 1px solid var(--p42-border-soft);
}

.p42-table td {
  padding: 13px 14px;
  border-bottom: 1px solid var(--p42-border-soft);
}

.p42-table tr:last-child td {
  border-bottom: 0;
}

.p42-table tbody tr:hover td {
  background: #fbfcfe;
}

/* --------------------------------------------------------------------------
   Segmented controls / Tabs
   -------------------------------------------------------------------------- */

.p42-tabs {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px;
  border: 1px solid var(--p42-border-soft);
  border-radius: var(--p42-r-md);
  background: var(--p42-surface-soft);
}

.p42-tab {
  padding: 7px 11px;
  border: 0;
  border-radius: 9px;
  background: transparent;
  color: var(--p42-text-muted);
  font-weight: 600;
}

.p42-tab:hover {
  color: var(--p42-text-strong);
}

.p42-tab.is-active {
  color: var(--p42-text-strong);
  background: var(--p42-surface);
  box-shadow: var(--p42-shadow-xs);
}

/* --------------------------------------------------------------------------
   Empty / Loading states
   -------------------------------------------------------------------------- */

.p42-empty {
  padding: 44px 24px;
  text-align: center;
  color: var(--p42-text-muted);
}

.p42-skeleton {
  border-radius: 6px;
  background:
    linear-gradient(
      90deg,
      #edf1f5 25%,
      #f6f8fa 37%,
      #edf1f5 63%
    );
  background-size: 400% 100%;
  animation: p42-shimmer 1.35s ease infinite;
}

@keyframes p42-shimmer {
  0% { background-position: 100% 0; }
  100% { background-position: 0 0; }
}

/* --------------------------------------------------------------------------
   Utility
   -------------------------------------------------------------------------- */

.p42-divider {
  height: 1px;
  background: var(--p42-border-soft);
}

.p42-muted {
  color: var(--p42-text-muted);
}

.p42-strong {
  color: var(--p42-text-strong);
  font-weight: 700;
}

.p42-stack {
  display: flex;
  flex-direction: column;
  gap: var(--p42-4);
}

.p42-row {
  display: flex;
  /* wrap, or a row of cards runs off the right edge on narrow screens */
  flex-wrap: wrap;
  align-items: center;
  gap: var(--p42-3);
}

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


/* ==========================================================================
   PRIORITY LEGACY COMPONENT COVERAGE
   These are the highest-impact migration targets and should be implemented
   before lower-volume polish work.
   ========================================================================== */

/* --------------------------------------------------------------------------
   Block / Card
   Includes standard header/body/footer and gray-lighter header variant.
   -------------------------------------------------------------------------- */

.p42-block {
  background: var(--p42-surface);
  border: 1px solid var(--p42-border-soft);
  border-radius: var(--p42-r-lg);
  box-shadow: var(--p42-shadow-xs);
  overflow: hidden;
}

.p42-block__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--p42-4);
  min-height: 48px;
  padding: 12px 16px;
  background: var(--p42-surface);
  border-bottom: 1px solid var(--p42-border-soft);
  color: var(--p42-text-strong);
  font-weight: 700;
}

.p42-block__header--gray-lighter {
  background: var(--p42-surface-soft);
}

.p42-block__body {
  padding: 16px;
}

.p42-block__body--comfortable {
  padding: 24px;
}

/* --------------------------------------------------------------------------
   Form controls
   Text, select, checkbox, radio, date, masked, validation states.
   -------------------------------------------------------------------------- */

.p42-control-row {
  display: flex;
  align-items: center;
  gap: 10px;
}

.p42-checkbox,
.p42-radio {
  width: 18px;
  height: 18px;
  accent-color: var(--p42-primary);
  cursor: pointer;
}

.p42-checkbox:focus-visible,
.p42-radio:focus-visible {
  outline: none;
  box-shadow: var(--p42-focus-ring);
}

.p42-input[type="date"],
.p42-input[type="datetime-local"],
.p42-input[type="time"],
.p42-input[data-masked="true"] {
  font-variant-numeric: tabular-nums;
}

.p42-field.is-valid .p42-input,
.p42-field.is-valid .p42-select,
.p42-field.is-valid .p42-textarea {
  border-color: rgba(22,163,107,.55);
  box-shadow: 0 0 0 3px rgba(22,163,107,.10);
}

.p42-field.is-invalid .p42-input,
.p42-field.is-invalid .p42-select,
.p42-field.is-invalid .p42-textarea {
  border-color: rgba(169,21,67,.58);
  box-shadow: 0 0 0 3px rgba(169,21,67,.10);
}

.p42-field__feedback {
  font-size: 12px;
  line-height: 1.35;
}

.p42-field.is-valid .p42-field__feedback {
  color: var(--p42-success);
}

.p42-field.is-invalid .p42-field__feedback {
  color: var(--p42-danger);
}

/* --------------------------------------------------------------------------
   Data tables
   Header row, hover, sortable headers, pagination.
   -------------------------------------------------------------------------- */

.p42-table th[aria-sort],
.p42-table th[data-sortable="true"] {
  cursor: pointer;
  user-select: none;
}

.p42-table__sort {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.p42-table__sort-arrow {
  width: 14px;
  height: 14px;
  color: var(--p42-text-subtle);
}

.p42-table th[aria-sort="ascending"] .p42-table__sort-arrow,
.p42-table th[aria-sort="descending"] .p42-table__sort-arrow {
  color: var(--p42-primary);
}

.p42-pagination {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px;
  border: 1px solid var(--p42-border-soft);
  border-top: 0;
  border-radius: 0 0 var(--p42-r-lg) var(--p42-r-lg);
  background: var(--p42-surface);
}

.p42-pagination__pages {
  display: flex;
  align-items: center;
  gap: 6px;
}

.p42-page {
  min-width: 34px;
  height: 34px;
  display: inline-grid;
  place-items: center;
  border: 1px solid var(--p42-border);
  border-radius: 9px;
  background: var(--p42-surface);
  color: var(--p42-text-muted);
  font-weight: 600;
  cursor: pointer;
}

.p42-page:hover {
  background: var(--p42-surface-soft);
  color: var(--p42-text-strong);
}

.p42-page.is-active {
  color: #fff;
  background: var(--p42-primary);
  border-color: var(--p42-primary);
}

/* --------------------------------------------------------------------------
   Modals
   Header, body, footer action row.
   -------------------------------------------------------------------------- */

.p42-modal-backdrop {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(13,18,28,.52);
  backdrop-filter: blur(3px);
  z-index: 1000;
}

.p42-modal {
  width: min(640px, 100%);
  max-height: calc(100vh - 48px);
  display: flex;
  flex-direction: column;
  background: var(--p42-surface);
  border: 1px solid var(--p42-border-soft);
  border-radius: var(--p42-r-lg);
  box-shadow: 0 24px 70px rgba(16,24,40,.24);
  overflow: hidden;
}

.p42-modal__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 20px;
  border-bottom: 1px solid var(--p42-border-soft);
}

.p42-modal__title {
  margin: 0;
  color: var(--p42-text-strong);
  font-size: 18px;
  font-weight: 700;
}

.p42-modal__body {
  padding: 20px;
  overflow: auto;
}

.p42-modal__footer {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  padding: 14px 20px;
  background: var(--p42-surface-soft);
  border-top: 1px solid var(--p42-border-soft);
}

/* --------------------------------------------------------------------------
   Alerts
   Five canonical types: primary, success, info, warning, danger.
   -------------------------------------------------------------------------- */

.p42-alert--primary {
  color: #4f34c8;
  background: #f3efff;
  border-color: rgba(126,91,255,.18);
}

.p42-alert--warning {
  color: #8a5815;
  background: var(--p42-warning-bg);
  border-color: rgba(183,121,31,.16);
}

/* --------------------------------------------------------------------------
   Empty and loading states
   -------------------------------------------------------------------------- */

.p42-empty-state {
  display: grid;
  justify-items: center;
  gap: 10px;
  padding: 48px 24px;
  text-align: center;
  color: var(--p42-text-muted);
}

.p42-empty-state__icon {
  width: 42px;
  height: 42px;
  color: var(--p42-text-subtle);
}

.p42-empty-state__title {
  margin: 0;
  color: var(--p42-text-strong);
  font-size: 16px;
  font-weight: 700;
}

.p42-empty-state__text {
  max-width: 520px;
  margin: 0;
  font-size: 14px;
  line-height: 1.5;
}

.p42-loading-state {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 120px;
  padding: 24px;
  color: var(--p42-text-muted);
}

.p42-spinner {
  width: 20px;
  height: 20px;
  border: 2px solid var(--p42-border);
  border-top-color: var(--p42-primary);
  border-radius: 50%;
  animation: p42-spin .75s linear infinite;
}

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