/* ═══════════════════════════════════════════════════
   RealHub Admin — Design System
   Aligned with EDMA Estate public site (globals.css)
   ═══════════════════════════════════════════════════ */

/* ── EDMA brand tokens (mirrors frontend globals.css) ── */
:root {
  --rh-gold-50:   #fdfaf3;
  --rh-gold-100:  #f9f0d8;
  --rh-gold-400:  #dca83a;
  --rh-gold-500:  #c4911e;
  --rh-gold-600:  #a07316;

  --rh-charcoal-400: #8f8378;
  --rh-charcoal-500: #6e6358;
  --rh-charcoal-700: #3f3830;
  --rh-charcoal-800: #28231d;
  --rh-charcoal-900: #151210;
  --rh-charcoal-950: #0c0b09;

  --rh-cream-50:  #fefefc;
  --rh-cream-100: #fdfcf8;
  --rh-cream-200: #f9f6ed;
  --rh-cream-300: #f3eedf;
  --rh-cream-400: #e8e0cc;

  --rh-radius-sm: 2px;
  --rh-radius-md: 4px;
  --rh-radius-lg: 6px;

  --rh-duration: 200ms;
  --rh-ease: cubic-bezier(0.16, 1, 0.3, 1);
}

/* ── Base ─────────────────────────────────────────── */
html, body {
  margin: 0;
  font-family: 'Noto Sans', system-ui, -apple-system, sans-serif;
  background: var(--rh-cream-100);
  color: var(--rh-charcoal-800);
  -webkit-font-smoothing: antialiased;
}

/* ── Shared: clickable table link ──────────────────
   Use class="rh-link" on <span> inside MudTd.         */
.rh-link {
  color: var(--rh-charcoal-800);
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: color var(--rh-duration) ease,
              border-color var(--rh-duration) ease;
}
.rh-link:hover {
  color: var(--rh-gold-500);
  border-bottom-color: var(--rh-gold-400);
}

/* ── Shared: spec table (replaces inline <table> styling) ─ */
.rh-spec-table {
  width: 100%;
  border-collapse: collapse;
}
.rh-spec-table td {
  padding: 10px 4px;
  border-bottom: 1px solid var(--rh-cream-300);
  vertical-align: middle;
  font-size: 0.875rem;
  line-height: 1.5;
}
.rh-spec-table td:first-child {
  width: 42%;
  color: var(--rh-charcoal-500);
  font-size: 0.8125rem;
}
.rh-spec-table tr:last-child td {
  border-bottom: none;
}

/* ── Shared: filter toolbar above grids ───────────── */
.rh-toolbar {
  background: var(--rh-cream-50);
  border: 1px solid var(--rh-cream-300);
  border-radius: var(--rh-radius-sm);
  padding: 16px 20px;
}
/* Vertically centre all filter controls (inputs + button row) */
.rh-toolbar .mud-grid {
  align-items: center;
}

/* ── Shared: section label (overline uppercase) ────── */
.rh-overline {
  font-size: 0.65rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--rh-gold-500);
}

/* ── Shared: nav version label ─────────────────────── */
.rh-nav-version {
  font-size: 0.7rem;
  letter-spacing: 0.06em;
  color: rgba(255,255,255,0.25);
}

/* ── MudBlazor overrides to align with EDMA style ─── */

/* Drawer nav links active state: gold underline */
.mud-nav-link.active {
  color: var(--rh-gold-400) !important;
  background: rgba(220,168,58,0.08) !important;
}
.mud-nav-link.active .mud-nav-link-icon {
  color: var(--rh-gold-400) !important;
}

/* Drawer nav link hover */
.mud-nav-link:hover {
  color: var(--rh-gold-400) !important;
  background: rgba(220,168,58,0.06) !important;
}
.mud-nav-link:hover .mud-nav-link-icon {
  color: var(--rh-gold-400) !important;
}

/* Tables: tighter, cleaner */
.mud-table-head .mud-table-cell {
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--rh-charcoal-500);
  border-bottom: 1px solid var(--rh-cream-400);
  padding: 10px 16px;
}

/* Chip: square radius */
.mud-chip {
  border-radius: var(--rh-radius-sm) !important;
}

/* Tabs: square underline style */
.mud-tab-active {
  border-radius: 0 !important;
}

/* Dialog: tighter radius */
.mud-dialog {
  border-radius: var(--rh-radius-md) !important;
}

/* MudPaper: subtle border */
.mud-paper:not(.mud-dialog):not(.mud-snackbar) {
  border-radius: var(--rh-radius-sm) !important;
}

/* AppBar title: serif */
.mud-appbar .mud-typography-h6 {
  font-family: 'Noto Serif', Georgia, serif;
  font-weight: 300;
  letter-spacing: 0.02em;
  color: #fff;
}

/* ── Blazor error UI ─────────────────────────────── */
#blazor-error-ui {
  background: #fff4e5;
  bottom: 0;
  box-shadow: 0 -1px 8px rgba(0, 0, 0, 0.12);
  display: none;
  left: 0;
  padding: 0.75rem 1.25rem;
  position: fixed;
  width: 100%;
  z-index: 1000;
}
#blazor-error-ui .dismiss {
  cursor: pointer;
  position: absolute;
  right: 0.75rem;
  top: 0.5rem;
}
