/* ==========================================================================
   NOVA PLATFORM - EXECUTIVE ADMIN DESIGN SYSTEM
   Ultra-Modern, Formal, High-Authority Multi-Tenant SaaS Admin UI
   Cohesive Light & Dark Themes (RTL & Arabic Precision Optimized)
   ========================================================================== */

/* --- GOOGLE FONTS IMPORT --- */
/* Fonts are loaded once from the layout <link>; an @import here chained a second blocking request. */

/* ==========================================================================
   THEME TOKENS:LIGHT THEME (Executive Slate & Royal Sapphire)
   ========================================================================== */
:root {
  --font-arabic:'Tajawal', -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-latin:'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-mono:'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, monospace;

  /* Canvas & Surfaces */
  --bg-page:var(--d-surface-2);
  --bg-canvas:var(--d-surface-2);
  --surface:var(--d-surface);
  --surface-hover:var(--d-surface-2);
  --surface-active:var(--d-surface-2);
  --surface-alt:var(--d-surface-2);
  --surface-muted:var(--d-primary-ink);
  --surface-glass:rgba(255, 255, 255, 0.94);

  /* Sidebar (Formal Deep Obsidian Navy in Light mode to anchor authority) */
  --sidebar-bg:var(--d-sidebar-bg);
  --sidebar-surface:var(--d-sidebar-bg);
  --sidebar-border:rgba(255, 255, 255, 0.08);
  --sidebar-text:var(--d-muted-soft);
  --sidebar-text-strong:var(--d-primary-ink);
  --sidebar-active-bg:color-mix(in srgb, var(--d-primary) 18%, transparent);
  --sidebar-active-border:var(--d-primary);

  /* Borders & Dividers */
  --border:var(--d-line);
  --border-light:var(--d-line);
  --border-subtle:var(--d-line);
  --border-focus:var(--d-primary);
  --border-hover:var(--d-line);

  /* Typography */
  --text-main:var(--d-ink);
  --text-body:var(--d-ink);
  --text-muted:var(--d-muted);
  --text-subtle:var(--d-muted-soft);

  /* Primary Brand:Executive Royal Cobalt / Navy */
  --primary: var(--d-primary);
  --primary-hover:var(--d-primary);
  --primary-active:var(--d-ink);
  --primary-light:var(--d-primary-ink);
  --primary-border:var(--d-line);
  --primary-glow:color-mix(in srgb, var(--d-primary) 18%, transparent);
  --primary-text:var(--d-primary-ink);

  /* Semantic Accents */
  --emerald:var(--d-primary);
  --emerald-bg:var(--d-surface-2);
  --emerald-text:var(--d-primary-strong);
  --emerald-border:color-mix(in srgb, var(--d-primary) 35%, var(--d-line));

  --amber:var(--d-warn);
  --amber-bg:var(--d-primary-ink);
  --amber-text:var(--d-warn);
  --amber-border:var(--d-warn);

  --rose:var(--d-danger);
  --rose-bg:var(--d-surface-2);
  --rose-text:var(--d-danger);
  --rose-border:color-mix(in srgb, var(--d-danger) 35%, var(--d-line));

  --sky:var(--d-info);
  --sky-bg:var(--d-surface-2);
  --sky-text:var(--d-ink-soft);
  --sky-border:var(--d-line);

  --violet:#8b5cf6;
  --violet-bg:var(--d-surface-2);
  --violet-text:#8b5cf6;
  --violet-border:var(--d-line);

  /* Elevation Shadows */
  --shadow-xs: 0 1px 2px 0 rgba(15, 23, 42, 0.04);
  --shadow-sm: 0 1px 3px 0 rgba(15, 23, 42, 0.06), 0 1px 2px -1px rgba(15, 23, 42, 0.06);
  --shadow-md: 0 4px 6px -1px rgba(15, 23, 42, 0.07), 0 2px 4px -2px rgba(15, 23, 42, 0.07);
  --shadow-lg: 0 10px 15px -3px rgba(15, 23, 42, 0.08), 0 4px 6px -4px rgba(15, 23, 42, 0.04);
  --shadow-card: 0 1px 3px 0 rgba(15, 23, 42, 0.04), 0 1px 2px -1px rgba(15, 23, 42, 0.04);

  /* Geometry & Radii */
  --radius-xs:6px;
  --radius-sm:8px;
  --radius-md:12px;
  --radius-lg:16px;
  --radius-xl:20px;
  --radius-full:9999px;

  --transition:all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

/* ==========================================================================
   THEME TOKENS:DARK THEME (Obsidian Space & Electric Cobalt)
   ========================================================================== */

/* ==========================================================================
   BASE & RESET
   ========================================================================== */
*, *::before, *::after {
  box-sizing:border-box;
}

[hidden] {
  display:none !important;
}

html {
  font-size:14px;
  -webkit-text-size-adjust:100%;
  color-scheme:light dark;
}

body {
  margin:0;
  padding:0;
  background-color:var(--bg-page);
  color:var(--text-body);
  font-family:var(--font-arabic);
  font-weight:400;
  line-height:1.6;
  direction:rtl;
  text-align:right;
  -webkit-font-smoothing:antialiased;
  -moz-osx-font-smoothing:grayscale;
  overflow-x:hidden;
  transition:background-color 0.25s ease, color 0.25s ease;
}

a {
  color:inherit;
  text-decoration:none;
  transition:var(--transition);
}

button, input, select, textarea {
  font-family:inherit;
  font-size:inherit;
  color:inherit;
}

button:focus-visible, a:focus-visible, input:focus-visible, select:focus-visible {
  outline:3px solid var(--primary-glow);
  outline-offset:2px;
}

svg {
  display:inline-block;
  vertical-align:middle;
  flex-shrink:0;
}

/* ==========================================================================
   APP SHELL LAYOUT
   ========================================================================== */
.admin-shell {
  display:flex;
  min-height:100vh;
  position:relative;
  background-color:var(--bg-page);
}

/* Backdrop for mobile drawer */
.sidebar-backdrop {
  position:fixed;
  inset:0;
  background:rgba(15, 23, 42, 0.65);
  backdrop-filter:blur(4px);
  z-index:40;
  opacity:0;
  pointer-events:none;
  transition:opacity 0.25s ease;
}

.sidebar-backdrop.active {
  opacity:1;
  pointer-events:auto;
}

/* --- SIDEBAR CONFIGURATION --- */
:root {
  --sidebar-width:268px;
  --sidebar-collapsed-width:76px;
}

/* --- SIDEBAR SHELL --- */
.sidebar {
  position:fixed;
  top:0;
  bottom:0;
  right:0;
  width:var(--sidebar-width);
  background-color:var(--sidebar-bg);
  border-left:1px solid var(--sidebar-border);
  color:var(--sidebar-text);
  display:flex;
  flex-direction:column;
  z-index:50;
  transition:width 0.28s cubic-bezier(0.16, 1, 0.3, 1), transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.28s ease;
  box-shadow: -4px 0 24px rgba(0, 0, 0, 0.25);
}

/* ==========================================================================
   MAIN CONTENT AREA
   ========================================================================== */
.main-content {
  margin-right:var(--sidebar-width);
  flex:1;
  min-height:100vh;
  display:flex;
  flex-direction:column;
  transition:margin-right 0.28s cubic-bezier(0.16, 1, 0.3, 1), width 0.28s cubic-bezier(0.16, 1, 0.3, 1);
  width:calc(100% - var(--sidebar-width));
}

/* --- TOPBAR --- */
.topbar {
  position:sticky;
  top:0;
  height:68px;
  background-color:var(--surface-glass);
  backdrop-filter:blur(14px);
  -webkit-backdrop-filter:blur(14px);
  border-bottom:1px solid var(--border);
  display:flex;
  align-items:center;
  justify-content:space-between;
  padding:0 32px;
  z-index:30;
  transition:var(--transition);
}

.topbar-left {
  display:flex;
  align-items:center;
  gap:16px;
}

.mobile-toggle {
  display:none;
  background:var(--surface);
  border:1px solid var(--border);
  width:38px;
  height:38px;
  border-radius:var(--radius-sm);
  color:var(--text-body);
  cursor:pointer;
  place-items:center;
  transition:var(--transition);
}

.mobile-toggle:hover {
  background:var(--surface-hover);
  border-color:var(--border-focus);
}

.desktop-sidebar-toggle {
  display:grid;
  place-items:center;
  background:var(--surface);
  border:1px solid var(--border);
  width:36px;
  height:36px;
  border-radius:var(--radius-sm);
  color:var(--text-muted);
  cursor:pointer;
  transition:var(--transition);
  box-shadow: var(--shadow-xs);
}

.desktop-sidebar-toggle:hover {
  background:var(--surface-hover);
  border-color:var(--border-hover);
  color:var(--primary);
}

@media (max-width:900px) {
  .desktop-sidebar-toggle {
    display:none;
  }
}

/* Breadcrumbs */
.breadcrumb {
  display:flex;
  align-items:center;
  gap:8px;
  font-size:12.5px;
  font-weight:600;
  color:var(--text-muted);
}

.breadcrumb a:hover {
  color:var(--primary);
}

.breadcrumb-sep {
  color:var(--text-subtle);
  font-size:11px;
}

.breadcrumb-current {
  color:var(--text-main);
  font-weight:700;
}

/* Topbar Actions */
.topbar-right {
  display:flex;
  align-items:center;
  gap:12px;
}

/* Quick Search input */
.topbar-search {
  position:relative;
  display:flex;
  align-items:center;
}

.topbar-search input {
  height:38px;
  width:260px;
  background:var(--surface);
  border:1px solid var(--border);
  border-radius:var(--radius-sm);
  padding:0 34px 0 44px;
  font-size:11.5px;
  color:var(--text-main);
  outline:none;
  transition:var(--transition);
}

.topbar-search input:focus {
  width:310px;
  border-color:var(--primary);
  box-shadow: 0 0 0 3px var(--primary-glow);
}

.search-icon {
  position:absolute;
  right:12px;
  width:15px;
  height:15px;
  color:var(--text-muted);
  pointer-events:none;
}

.search-shortcut {
  position:absolute;
  left:10px;
  font-family:var(--font-latin);
  font-size:10px;
  font-weight:700;
  padding:2px 6px;
  border-radius:4px;
  background:var(--bg-canvas);
  border:1px solid var(--border);
  color:var(--text-muted);
  pointer-events:none;
}

/* Action Icon Buttons */
.action-icon-btn, .theme-toggle-btn {
  width:38px;
  height:38px;
  border-radius:var(--radius-sm);
  background:var(--surface);
  border:1px solid var(--border);
  color:var(--text-body);
  display:grid;
  place-items:center;
  cursor:pointer;
  position:relative;
  transition:var(--transition);
}

.action-icon-btn:hover, .theme-toggle-btn:hover {
  background:var(--surface-hover);
  color:var(--primary);
  border-color:var(--border-focus);
}

.theme-toggle-btn:hover {
  transform:rotate(15deg);
}

.badge-dot {
  position:absolute;
  top:8px;
  right:8px;
  width:8px;
  height:8px;
  border-radius:50%;
  background:var(--rose);
  border:2px solid var(--surface);
}

.topbar-date {
  font-size:11.5px;
  font-weight:600;
  color:var(--text-muted);
  padding-right:8px;
  border-right:1px solid var(--border);
}

/* --- PAGE WRAPPER --- */
.page-wrap {
  flex:1;
  max-width:1600px;
  width:100%;
  margin:0 auto;
  padding:26px 32px 50px;
}

/* ==========================================================================
   HEADINGS & EXECUTIVE HERO CARDS
   ========================================================================== */
.page-heading {
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:18px;
  margin-bottom:22px;
}

.page-heading h1 {
  font-size:23px;
  font-weight:800;
  color:var(--text-main);
  letter-spacing:-0.02em;
  margin:0;
  line-height:1.3;
}

.page-heading p {
  font-size:12.5px;
  color:var(--text-muted);
  margin:4px 0 0;
  font-weight:500;
}

/* EXECUTIVE DASHBOARD HERO (Harmonious in Light & Dark modes) */
.dashboard-intro, .dashboard-hero {
  position:relative;
  display:flex;
  justify-content:space-between;
  align-items:center;
  gap:28px;
  padding:26px 30px;
  margin-bottom:22px;
  border-radius:var(--radius-xl);
  border:1px solid var(--border);
  background:var(--surface);
  box-shadow: var(--shadow-sm);
  transition:var(--transition);
  overflow:hidden;
}

/* Light Mode Hero Styling */
:root .dashboard-intro, :root .dashboard-hero {
  background:linear-gradient(135deg, var(--d-surface) 0%, var(--d-surface) 50%, var(--d-surface-2) 100%);
  border-color:rgba(226, 232, 240, 0.9);
  box-shadow: 0 4px 20px -2px rgba(15, 23, 42, 0.04), inset 0 1px 0 rgba(255, 255, 255, 1);
}

/* Dark Mode Hero Styling */

.dashboard-intro-main, .hero-content {
  position:relative;
  z-index:2;
  flex:1;
}

.hero-badge-row {
  display:flex;
  align-items:center;
  flex-wrap:wrap;
  gap:10px;
  margin-bottom:10px;
}

.hero-live-pill {
  display:inline-flex;
  align-items:center;
  gap:7px;
  padding:4px 10px;
  border-radius:var(--radius-full);
  background:var(--emerald-bg);
  color:var(--emerald-text);
  border:1px solid var(--emerald-border);
  font-size:11px;
  font-weight:750;
}

.live-pulse {
  width:7px;
  height:7px;
  border-radius:50%;
  background-color:var(--emerald);
  box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.6);
  animation:pulse-ring 2s infinite;
}

.hero-date-pill {
  display:inline-flex;
  align-items:center;
  gap:6px;
  padding:4px 10px;
  border-radius:var(--radius-full);
  background:var(--surface-alt);
  color:var(--text-muted);
  border:1px solid var(--border);
  font-size:11px;
  font-weight:600;
}

.hero-main-title h1 {
  margin:6px 0;
  color:var(--text-main);
  font-size:27px;
  font-weight:850;
  letter-spacing:-0.03em;
  line-height:1.25;
}

.hero-main-title h1 span {
  color:var(--primary);
}


.hero-main-title p {
  max-width:660px;
  margin:4px 0 0;
  color:var(--text-muted);
  font-size:12.5px;
  line-height:1.65;
}

.eyebrow {
  display:inline-block;
  color:var(--primary);
  font-size:11px;
  font-weight:800;
  letter-spacing:0.06em;
  text-transform:uppercase;
}

.dashboard-actions, .hero-actions {
  display:flex;
  align-items:center;
  flex-wrap:wrap;
  gap:10px;
  margin-top:18px;
}

.hero-btn {
  border-radius:var(--radius-sm);
  font-size:12px;
  padding:8px 16px;
  min-height:38px;
}

/* Executive Telemetry Box */
.hero-telemetry {
  flex-shrink:0;
  position:relative;
  z-index:2;
}

.telemetry-card {
  display:flex;
  flex-direction:column;
  gap:8px;
  padding:14px 18px;
  border-radius:var(--radius-lg);
  background:var(--surface-alt);
  border:1px solid var(--border);
  box-shadow: var(--shadow-xs);
  min-width:220px;
}

.telemetry-item {
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  font-size:11px;
}

.telemetry-label {
  color:var(--text-muted);
  font-weight:600;
}

.telemetry-val {
  display:inline-flex;
  align-items:center;
  gap:5px;
  font-weight:750;
  color:var(--text-main);
}

.telemetry-val.ok {
  color:var(--emerald-text);
}

.mini-dot {
  width:6px;
  height:6px;
  border-radius:50%;
  background-color:var(--emerald);
}

/* ==========================================================================
   BUTTONS (Formal & Crisp)
   ========================================================================== */
.button {
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:8px;
  border:1px solid var(--border);
  background:var(--surface);
  border-radius:var(--radius-sm);
  padding:8px 16px;
  min-height:38px;
  color:var(--text-body);
  font-size:12px;
  font-weight:700;
  white-space:nowrap;
  cursor:pointer;
  transition:var(--transition);
  box-shadow: var(--shadow-xs);
}

.button:hover {
  background:var(--surface-hover);
  color:var(--text-main);
  border-color:var(--border-hover);
  transform:translateY(-1px);
}

.button:active {
  transform:translateY(0);
}

.button.primary {
  background:var(--primary);
  color:var(--d-primary-ink);
  border-color:var(--primary);
  box-shadow: 0 2px 8px var(--primary-glow);
}

.button.primary:hover {
  background:var(--primary-hover);
  border-color:var(--primary-hover);
  box-shadow: 0 4px 12px var(--primary-glow);
}

.button.quiet {
  background:transparent;
  border-color:var(--border);
  box-shadow: none;
}

.button.quiet:hover {
  background:var(--surface-hover);
}

.button.small {
  padding:5px 10px;
  min-height:30px;
  font-size:11px;
}

/* ==========================================================================
   KPI STATS GRID (EXECUTIVE METRIC CARDS - HIGH END FINTECH)
   ========================================================================== */
.kpi-grid, .dashboard-kpis {
  display:grid;
  grid-template-columns:repeat(4, minmax(0, 1fr));
  gap:16px;
  margin-bottom:22px;
}

.kpi-card, .dashboard-kpi {
  position:relative;
  display:flex;
  flex-direction:column;
  padding:22px 24px;
  background:var(--surface);
  border:1px solid var(--border);
  border-radius:var(--radius-lg);
  box-shadow: var(--shadow-card);
  transition:all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  min-height:168px;
  overflow:hidden;
}

:root .kpi-card {
  background:linear-gradient(180deg, var(--d-surface) 0%, var(--d-surface) 100%);
  border-color:rgba(226, 232, 240, 0.85);
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.04), 0 4px 16px -2px rgba(15, 23, 42, 0.03), inset 0 1px 0 rgba(255, 255, 255, 1);
}


a.kpi-card:hover, .kpi-card:hover {
  transform:translateY(-3px);
  border-color:var(--border-hover);
  box-shadow: 0 8px 26px -4px rgba(15, 23, 42, 0.08), 0 0 0 1px var(--primary-glow);
}


.kpi-top {
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  margin-bottom:12px;
}

.kpi-meta {
  display:flex;
  flex-direction:column;
  gap:4px;
}

.kpi-title, .kpi-label {
  font-size:12px;
  font-weight:750;
  color:var(--text-muted);
}

.kpi-tag {
  display:inline-block;
  font-size:10px;
  font-weight:800;
  padding:1px 6px;
  border-radius:4px;
  width:fit-content;
}

.kpi-tag.success {
  background:var(--emerald-bg);
  color:var(--emerald-text);
}

.kpi-tag.neutral {
  background:var(--primary-light);
  color:var(--primary);
}

.kpi-tag.alert {
  background:var(--rose-bg);
  color:var(--rose-text);
}

.kpi-icon-box {
  width:42px;
  height:42px;
  border-radius:12px;
  display:grid;
  place-items:center;
  flex-shrink:0;
  transition:var(--transition);
}

.kpi-icon-box.cobalt {
  background:var(--primary-light);
  color:var(--primary);
  border:1px solid var(--primary-border);
}

.kpi-icon-box.emerald {
  background:var(--emerald-bg);
  color:var(--emerald);
  border:1px solid var(--emerald-border);
}

.kpi-icon-box.sky {
  background:var(--sky-bg);
  color:var(--sky);
  border:1px solid var(--sky-border);
}

.kpi-icon-box.rose {
  background:var(--rose-bg);
  color:var(--rose);
  border:1px solid var(--rose-border);
}

.kpi-card:hover .kpi-icon-box {
  transform:scale(1.05);
}

.kpi-main {
  display:flex;
  align-items:baseline;
  gap:8px;
  margin-top:2px;
  margin-bottom:8px;
}

.kpi-number, .dashboard-kpi > strong {
  color:var(--text-main);
  font-family:var(--font-latin), var(--font-arabic);
  font-size:30px;
  font-weight:850;
  line-height:1.1;
  font-variant-numeric:tabular-nums;
  letter-spacing:-0.03em;
}

.kpi-unit {
  font-size:12px;
  color:var(--text-muted);
  font-weight:600;
}

/* Micro Progress Bar inside KPI Card */
.kpi-progress-track {
  height:4px;
  width:100%;
  border-radius:var(--radius-full);
  background:var(--border-light);
  display:flex;
  overflow:hidden;
  margin-top:8px;
  margin-bottom:12px;
}

.kpi-progress-bar {
  height:100%;
  transition:width 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.bg-emerald { background:linear-gradient(90deg, var(--d-primary), var(--d-primary)); }
.bg-sky { background:linear-gradient(90deg, var(--d-primary), var(--d-primary)); }
.bg-rose { background:linear-gradient(90deg, var(--d-danger), var(--d-danger)); }
.bg-amber { background:linear-gradient(90deg, var(--d-warn), var(--d-warn)); }
.bg-muted { background:var(--text-subtle); }

.kpi-money-list {
  display:flex;
  flex-direction:column;
  gap:6px;
  margin-top:2px;
  margin-bottom:6px;
}

.kpi-money-row {
  display:flex;
  align-items:center;
  gap:8px;
}

.currency-badge {
  font-family:var(--font-latin);
  font-size:10px;
  font-weight:800;
  padding:2px 7px;
  border-radius:4px;
  letter-spacing:0.05em;
  background:var(--bg-canvas);
  color:var(--text-muted);
  border:1px solid var(--border);
  line-height:1.3;
  display:inline-block;
  flex-shrink:0;
}

.currency-badge.iqd {
  background:var(--primary-light);
  color:var(--primary);
  border-color:var(--primary-border);
}

.currency-badge.usd {
  background:var(--emerald-bg);
  color:var(--emerald);
  border-color:var(--emerald-border);
}

.currency-amount {
  font-family:var(--font-latin), var(--font-arabic);
  font-size:16px;
  font-weight:850;
  font-variant-numeric:tabular-nums;
  color:var(--text-main);
  line-height:1.3;
}

.currency-amount.text-rose {
  color:var(--rose);
}

.kpi-footer, .kpi-foot {
  margin-top:auto;
  display:flex;
  align-items:center;
  flex-wrap:wrap;
  gap:8px;
  color:var(--text-muted);
  font-size:11px;
  font-weight:500;
}

.kpi-pill {
  display:inline-flex;
  align-items:center;
  gap:5px;
  padding:3px 9px;
  border-radius:var(--radius-full);
  font-size:10.5px;
  font-weight:700;
}

.kpi-pill.success {
  background:var(--emerald-bg);
  color:var(--emerald-text);
  border:1px solid var(--emerald-border);
}

.kpi-pill.sky {
  background:var(--sky-bg);
  color:var(--sky-text);
  border:1px solid var(--sky-border);
}

.kpi-pill.danger {
  background:var(--rose-bg);
  color:var(--rose-text);
  border:1px solid var(--rose-border);
}

.kpi-pill.subtle {
  background:var(--bg-canvas);
  color:var(--text-muted);
  border:1px solid var(--border);
}

.pill-dot {
  width:6px;
  height:6px;
  border-radius:50%;
  background-color:currentColor;
}

/* ==========================================================================
   PANELS & DATA GRIDS
   ========================================================================== */
.content-grid, .dashboard-grid {
  display:grid;
  grid-template-columns:minmax(0, 1.55fr) minmax(330px, 0.95fr);
  gap:18px;
  margin-bottom:22px;
}

.dashboard-lists {
  grid-template-columns:minmax(0, 1.35fr) minmax(330px, 0.85fr);
}

.panel {
  background:var(--surface);
  border:1px solid var(--border);
  border-radius:var(--radius-xl);
  box-shadow: var(--shadow-card);
  min-width:0;
  overflow:hidden;
  transition:var(--transition);
}

:root .panel {
  background:var(--d-surface);
  border-color:rgba(226, 232, 240, 0.9);
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.03), 0 4px 16px -2px rgba(15, 23, 42, 0.03);
}


.panel-head, .dashboard-panel-head {
  display:flex;
  justify-content:space-between;
  align-items:flex-start;
  gap:14px;
  padding:18px 22px;
  border-bottom:1px solid var(--border);
  background-color:var(--surface);
}

.panel-head-actions {
  display:flex;
  align-items:center;
  gap:10px;
}

.chart-filter-tag {
  font-size:11px;
  font-weight:700;
  padding:3px 9px;
  border-radius:var(--radius-full);
  background:var(--surface-alt);
  color:var(--text-muted);
  border:1px solid var(--border);
}

.panel-head h2, .dashboard-panel-head h2 {
  margin:3px 0 2px;
  color:var(--text-main);
  font-size:16px;
  font-weight:850;
  letter-spacing:-0.01em;
}

.panel-head p, .dashboard-panel-head p {
  margin:0;
  color:var(--text-muted);
  font-size:11.5px;
  line-height:1.6;
}

.text-link {
  flex:0 0 auto;
  color:var(--primary);
  font-size:11.5px;
  font-weight:750;
  display:inline-flex;
  align-items:center;
  gap:4px;
}

.text-link:hover {
  color:var(--primary-hover);
  transform:translateX(-2px);
}

/* ==========================================================================
   TREND CHART & ANALYTICS WIDGETS
   ========================================================================== */
.trend-legend {
  display:flex;
  align-items:center;
  gap:18px;
  padding:16px 22px 4px;
  color:var(--text-muted);
  font-size:11px;
  font-weight:600;
}

.legend-item {
  display:inline-flex;
  align-items:center;
  gap:7px;
}

.legend-color {
  width:9px;
  height:9px;
  border-radius:3px;
}

.legend-color.org { background:var(--primary); }
.legend-color.sub { background:var(--emerald); }

.trend-chart-wrapper {
  position:relative;
  padding:16px 22px 20px;
  height:250px;
  display:flex;
  flex-direction:column;
  justify-content:flex-end;
}

/* Background Guides */
.chart-guides {
  position:absolute;
  inset:16px 22px 40px;
  display:flex;
  flex-direction:column;
  justify-content:space-between;
  pointer-events:none;
}

.chart-guide-line {
  position:relative;
  width:100%;
  border-bottom:1px dashed var(--border-light);
}

.chart-guide-line span {
  position:absolute;
  right:-2px;
  top:-9px;
  font-family:var(--font-latin);
  font-size:9.5px;
  color:var(--text-subtle);
  background:var(--surface);
  padding:0 4px;
}

.trend-chart {
  position:relative;
  z-index:2;
  height:100%;
  display:grid;
  grid-template-columns:repeat(6, minmax(0, 1fr));
  gap:12px;
  align-items:stretch;
}

.trend-month {
  display:flex;
  flex-direction:column;
  align-items:center;
  justify-content:flex-end;
  min-width:0;
  gap:8px;
}

.trend-bars {
  width:min(100%, 64px);
  height:100%;
  display:flex;
  align-items:flex-end;
  justify-content:center;
  gap:6px;
  padding:0 4px;
}

.trend-bar {
  position:relative;
  width:18px;
  height:var(--bar-height);
  min-height:8px;
  border-radius:6px 6px 0 0;
  transition:all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  cursor:pointer;
}

.trend-bar:hover {
  transform:scaleY(1.05);
  filter:brightness(1.15);
}

.bar-label {
  position:absolute;
  top:-18px;
  inset-inline:-6px;
  color:var(--text-muted);
  text-align:center;
  font-family:var(--font-latin);
  font-size:10px;
  font-weight:750;
  font-variant-numeric:tabular-nums;
  opacity:0.85;
}

.bar-tooltip {
  position:absolute;
  bottom:calc(100% + 8px);
  right:50%;
  transform:translateX(50%);
  background:var(--sidebar-bg);
  color:var(--d-primary-ink);
  font-size:10px;
  font-weight:700;
  padding:3px 8px;
  border-radius:4px;
  white-space:nowrap;
  pointer-events:none;
  opacity:0;
  visibility:hidden;
  transition:all 0.15s ease;
  z-index:10;
  box-shadow: var(--shadow-md);
}

.trend-bar:hover .bar-tooltip {
  opacity:1;
  visibility:visible;
}

.org-bar {
  background:linear-gradient(180deg, var(--d-primary) 0%, var(--d-primary) 100%);
  box-shadow: 0 2px 6px color-mix(in srgb, var(--d-primary) 25%, transparent);
}

.sub-bar {
  background:linear-gradient(180deg, var(--d-primary) 0%, var(--d-primary) 100%);
  box-shadow: 0 2px 6px rgba(16, 185, 129, 0.25);
}

.month-name {
  color:var(--text-muted);
  font-size:11px;
  font-weight:600;
}

/* ==========================================================================
   DISTRIBUTION PANEL & COMPOSITE GAUGES
   ========================================================================== */
.distribution-panel {
  display:flex;
  flex-direction:column;
}

.distribution-body {
  padding:18px 22px;
  display:flex;
  flex-direction:column;
  gap:16px;
}

.composite-gauge-wrap {
  width:100%;
}

.composite-gauge-bar {
  height:8px;
  width:100%;
  border-radius:var(--radius-full);
  background:var(--border-light);
  display:flex;
  overflow:hidden;
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.1);
}

.gauge-seg {
  height:100%;
  transition:width 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.status-meter-list {
  display:flex;
  flex-direction:column;
  gap:6px;
}

.meter-row {
  display:grid;
  grid-template-columns:80px 1fr 70px;
  align-items:center;
  gap:12px;
  padding:8px 10px;
  border-radius:var(--radius-sm);
  transition:var(--transition);
}

.meter-row:hover {
  background-color:var(--surface-hover);
}

.meter-info {
  display:flex;
  align-items:center;
  gap:8px;
}

.meter-label {
  font-size:12px;
  font-weight:700;
  color:var(--text-main);
}

.meter-bar-container {
  height:6px;
  width:100%;
  border-radius:var(--radius-full);
  background:var(--border-light);
  overflow:hidden;
}

.meter-bar-fill {
  height:100%;
  border-radius:var(--radius-full);
  transition:width 0.5s ease;
}

.meter-meta {
  display:flex;
  align-items:center;
  justify-content:flex-end;
  gap:8px;
  font-family:var(--font-latin);
}

.meter-pct {
  font-size:10.5px;
  color:var(--text-muted);
  font-weight:600;
}

.meter-count {
  font-size:12.5px;
  font-weight:800;
  color:var(--text-main);
  min-width:16px;
  text-align:left;
}

.status-dot {
  width:8px;
  height:8px;
  flex:0 0 auto;
  border-radius:50%;
}

.status-dot.emerald { background-color:var(--emerald); }
.status-dot.sky { background-color:var(--sky); }
.status-dot.rose { background-color:var(--rose); }
.status-dot.amber { background-color:var(--amber); }
.status-dot.muted { background-color:var(--text-subtle); }

/* ==========================================================================
   PRIORITY ACTION CENTER
   ========================================================================== */
.priority-list {
  padding:14px 20px;
  display:flex;
  flex-direction:column;
  gap:10px;
}

.priority-card {
  display:flex;
  align-items:center;
  gap:12px;
  padding:12px 14px;
  border-radius:var(--radius-md);
  border:1px solid var(--border);
  background:var(--surface-alt);
  transition:var(--transition);
}

.priority-card:hover {
  background:var(--surface-hover);
  border-color:var(--border-hover);
  transform:translateX(-2px);
}

.priority-card.past_due {
  border-right:3px solid var(--rose);
}

.priority-card.trialing {
  border-right:3px solid var(--sky);
}

.priority-marker {
  width:9px;
  height:9px;
  border-radius:50%;
  flex-shrink:0;
}

.priority-marker.past_due {
  background-color:var(--rose);
  box-shadow: 0 0 0 3px var(--rose-bg);
}

.priority-marker.trialing {
  background-color:var(--sky);
  box-shadow: 0 0 0 3px var(--sky-bg);
}

.priority-copy {
  flex:1;
  min-width:0;
}

.priority-copy b {
  display:block;
  font-size:12.5px;
  font-weight:750;
  color:var(--text-main);
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}

.priority-tags {
  display:flex;
  align-items:center;
  gap:6px;
  margin-top:3px;
}

.priority-plan {
  font-size:10.5px;
  color:var(--text-muted);
}

.priority-status {
  font-size:10px;
  font-weight:750;
  padding:1px 6px;
  border-radius:4px;
}

.priority-status.past_due {
  background:var(--rose-bg);
  color:var(--rose-text);
}

.priority-status.trialing {
  background:var(--sky-bg);
  color:var(--sky-text);
}

.priority-action-box {
  display:flex;
  align-items:center;
  gap:10px;
}

.priority-date {
  display:inline-flex;
  align-items:center;
  gap:4px;
  color:var(--text-muted);
  font-family:var(--font-mono);
  font-size:11px;
}

.priority-btn {
  font-size:11px;
  font-weight:700;
  padding:4px 10px;
  border-radius:var(--radius-sm);
  background:var(--surface);
  border:1px solid var(--border);
  color:var(--primary);
  transition:var(--transition);
}

.priority-btn:hover {
  background:var(--primary);
  color:var(--d-primary-ink);
  border-color:var(--primary);
}

.empty-state-box {
  display:flex;
  flex-direction:column;
  align-items:center;
  justify-content:center;
  padding:30px 20px;
  text-align:center;
  color:var(--text-muted);
  gap:10px;
}

.empty-state-box p {
  margin:0;
  font-size:12px;
  font-weight:600;
}

/* ==========================================================================
   MODERN TABLES & SECURITY TELEMETRY
   ========================================================================== */
.table-scroll {
  overflow-x:auto;
  scrollbar-width:thin;
}

table, .modern-table {
  width:100%;
  border-collapse:collapse;
  min-width:600px;
  text-align:right;
}

th {
  padding:13px 20px;
  background-color:var(--surface-alt);
  color:var(--text-muted);
  font-size:11px;
  font-weight:750;
  white-space:nowrap;
  border-bottom:1px solid var(--border);
  letter-spacing:0.02em;
}

td {
  padding:14px 20px;
  border-bottom:1px solid var(--border-light);
  color:var(--text-body);
  font-size:12.5px;
  white-space:nowrap;
  vertical-align:middle;
  transition:var(--transition);
}

tr:hover td {
  background-color:var(--surface-hover);
}

tr:last-child td {
  border-bottom:none;
}

.row-title {
  font-weight:750;
  color:var(--text-main);
  display:block;
}

.row-title:hover {
  color:var(--primary);
}

.subline {
  display:block;
  color:var(--text-muted);
  font-size:11px;
  margin-top:2px;
  font-weight:500;
}

.plan-badge {
  display:inline-flex;
  align-items:center;
  gap:5px;
  font-weight:600;
}

.pulse-dot-small {
  width:6px;
  height:6px;
  border-radius:50%;
  background-color:currentColor;
  display:inline-block;
  margin-left:4px;
}

.date-stamp {
  font-family:var(--font-mono);
  font-size:11px;
  color:var(--text-muted);
}

.quick-action-btn {
  display:inline-flex;
  align-items:center;
  gap:4px;
  font-size:11px;
  font-weight:750;
  color:var(--primary);
  padding:4px 10px;
  border-radius:var(--radius-sm);
  background:var(--surface-alt);
  border:1px solid var(--border);
  transition:var(--transition);
}

.quick-action-btn:hover {
  background:var(--primary);
  color:var(--d-primary-ink);
  border-color:var(--primary);
}

/* Security Audit Stream Styling */
.live-stream-badge {
  display:inline-flex;
  align-items:center;
  gap:6px;
  padding:3px 8px;
  border-radius:var(--radius-full);
  background:var(--emerald-bg);
  color:var(--emerald-text);
  border:1px solid var(--emerald-border);
  font-size:10.5px;
  font-weight:750;
}

.audit-target {
  display:flex;
  flex-direction:column;
  gap:2px;
}

.audit-table-name {
  font-weight:750;
  color:var(--text-main);
}

.audit-record-id {
  font-family:var(--font-mono);
  font-size:10.5px;
  color:var(--text-muted);
}

.op-badge {
  display:inline-flex;
  align-items:center;
  gap:5px;
  padding:2px 8px;
  border-radius:4px;
  font-size:10.5px;
  font-weight:750;
}

.op-badge.success {
  background:var(--emerald-bg);
  color:var(--emerald-text);
  border:1px solid var(--emerald-border);
}

.op-badge.info {
  background:var(--sky-bg);
  color:var(--sky-text);
  border:1px solid var(--sky-border);
}

.op-badge.danger {
  background:var(--rose-bg);
  color:var(--rose-text);
  border:1px solid var(--rose-border);
}

.op-badge.subtle {
  background:var(--bg-canvas);
  color:var(--text-muted);
  border:1px solid var(--border);
}

.actor-cell {
  display:flex;
  align-items:center;
  gap:8px;
  font-size:12px;
  font-weight:600;
}

.actor-avatar {
  width:24px;
  height:24px;
  border-radius:50%;
  background:var(--primary-light);
  color:var(--primary);
  display:grid;
  place-items:center;
  font-size:10px;
  font-weight:800;
}

.audit-time {
  display:inline-flex;
  align-items:center;
  gap:5px;
  color:var(--text-muted);
  font-size:11px;
}

/* Company Entity Cell */
.company-cell, .cell-entity {
  display:flex;
  align-items:center;
  gap:12px;
}

.company-avatar, .entity-avatar {
  width:36px;
  height:36px;
  border-radius:var(--radius-sm);
  background:var(--primary-light);
  color:var(--primary);
  display:grid;
  place-items:center;
  font-weight:800;
  font-size:13.5px;
  flex-shrink:0;
  border:1px solid var(--primary-border);
}


.empty {
  text-align:center !important;
  color:var(--text-muted) !important;
  padding:36px 20px !important;
  font-size:12.5px !important;
  font-weight:600;
}

/* Status Badges */
.status, .badge {
  display:inline-flex;
  align-items:center;
  gap:6px;
  padding:3px 10px;
  border-radius:var(--radius-full);
  font-size:11px;
  font-weight:700;
  background:var(--bg-canvas);
  color:var(--text-muted);
  border:1px solid var(--border);
}

.status::before, .badge-dot {
  content: "";
  width:6px;
  height:6px;
  border-radius:50%;
  background-color:currentColor;
}

.status.active, .status.paid, .badge.badge-active {
  background-color:var(--emerald-bg);
  color:var(--emerald-text);
  border-color:var(--emerald-border);
}

.status.trial, .status.trialing, .status.open, .badge.badge-trial {
  background-color:var(--sky-bg);
  color:var(--sky-text);
  border-color:var(--sky-border);
}

.status.past_due, .status.overdue, .badge.badge-pastdue {
  background-color:var(--rose-bg);
  color:var(--rose-text);
  border-color:var(--rose-border);
}

.status.suspended, .status.paused, .status.void, .status.canceled {
  background-color:var(--bg-canvas);
  color:var(--text-muted);
  border-color:var(--border);
}

/* ==========================================================================
   FILTERS & CONTROLS TOOLBAR (COHESIVE & FORMAL)
   ========================================================================== */
.filters, .report-filters, .data-filters {
  display:flex;
  flex-wrap:wrap;
  align-items:center;
  gap:10px;
  padding:16px 20px;
  background:var(--surface-alt);
  border:1px solid var(--border);
  border-radius:var(--radius-md);
  margin-bottom:20px;
}

.filters input, .filters select, .report-filters input, .report-filters select {
  min-height:40px;
  height:40px;
  border:1px solid var(--border);
  border-radius:var(--radius-sm);
  background-color:var(--surface);
  color:var(--text-main);
  padding:0 12px;
  font-size:12px;
  outline:none;
  transition:var(--transition);
}

.filters input:focus, .filters select:focus, .report-filters input:focus, .report-filters select:focus {
  border-color:var(--primary);
  box-shadow: 0 0 0 3px var(--primary-glow);
}

.report-stat-grid {
  display:grid;
  grid-template-columns:repeat(3, minmax(0, 1fr));
  gap:16px;
  margin-bottom:22px;
}

.stat-card {
  background:var(--surface);
  border:1px solid var(--border);
  border-radius:var(--radius-md);
  padding:20px;
  box-shadow: var(--shadow-card);
  position:relative;
  overflow:hidden;
  display:flex;
  flex-direction:column;
  transition:var(--transition);
}

.stat-card:hover {
  transform:translateY(-2px);
  box-shadow: var(--shadow-md);
  border-color:var(--border-hover);
}

.stat-card-header {
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  margin-bottom:12px;
}

.stat-card-title {
  font-size:12px;
  font-weight:700;
  color:var(--text-muted);
}

.stat-icon {
  width:36px;
  height:36px;
  border-radius:var(--radius-sm);
  display:grid;
  place-items:center;
  flex-shrink:0;
  background:var(--primary-light);
  color:var(--primary);
}

.stat-value {
  font-size:26px;
  font-weight:850;
  color:var(--text-main);
  line-height:1.2;
  font-family:var(--font-latin), var(--font-arabic);
}

.stat-footer {
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:8px;
  margin-top:12px;
  padding-top:10px;
  border-top:1px solid var(--border-light);
  font-size:11px;
  color:var(--text-muted);
}

/* Pagination */
.pagination-wrap {
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  padding:16px 20px;
  border-top:1px solid var(--border-light);
  flex-wrap:wrap;
}

.pagination-summary {
  color:var(--text-muted);
  font-size:11px;
  font-weight:500;
}

/* ==========================================================================
   ORGANIZATION PROFILE & SETTINGS
   ========================================================================== */
.organization-profile-heading {
  align-items:center;
}

.organization-profile-identity {
  display:flex;
  align-items:center;
  gap:16px;
  min-width:0;
}

.organization-profile-identity .company-avatar {
  width:54px;
  height:54px;
  flex:0 0 54px;
  font-size:22px;
}

.organization-profile-identity h1 {
  margin:2px 0 4px;
}

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

.organization-profile-nav {
  display:flex;
  gap:8px;
  overflow-x:auto;
  padding:10px;
  margin:18px 0;
  border:1px solid var(--border);
  border-radius:var(--radius-md);
  background:var(--surface);
}

.organization-profile-nav a {
  flex:0 0 auto;
  padding:8px 14px;
  border-radius:var(--radius-sm);
  color:var(--text-muted);
  font-size:12.5px;
  font-weight:700;
}

.organization-profile-nav a:hover, .organization-profile-nav a.active {
  color:var(--primary);
  background:var(--primary-light);
}

.organization-facts-grid {
  display:grid;
  grid-template-columns:repeat(3, minmax(0, 1fr));
  gap:12px;
  margin-bottom:20px;
}

.profile-fact {
  padding:16px;
  border:1px solid var(--border);
  border-radius:var(--radius-md);
  background:var(--surface);
}

.profile-fact > span {
  display:block;
  margin-bottom:6px;
  color:var(--text-muted);
  font-size:11.5px;
}

.profile-fact > strong {
  font-size:14.5px;
  font-weight:750;
  color:var(--text-main);
}

/* ==========================================================================
   RESPONSIVE STYLES
   ========================================================================== */
@media (max-width:1100px) {
  .dashboard-grid, .dashboard-lists, .content-grid {
    grid-template-columns:1fr;
  }
  .kpi-grid, .dashboard-kpis {
    grid-template-columns:repeat(2, minmax(0, 1fr));
  }
  .report-stat-grid {
    grid-template-columns:repeat(2, minmax(0, 1fr));
  }
}

@media (max-width:900px) {
  .main-content {
    margin-right:0;
    width:100%;
  }
  .sidebar {
    transform:translateX(100%);
  }
  .sidebar.mobile-open {
    transform:translateX(0);
  }
  .mobile-toggle {
    display:grid;
  }
}

@media (max-width:640px) {
  .page-wrap {
    padding:16px 14px 36px;
  }
  .topbar {
    padding:0 14px;
  }
  .topbar-date {
    display:none;
  }
  .dashboard-intro, .dashboard-hero {
    flex-direction:column;
    align-items:flex-start;
    padding:20px;
  }
  .dashboard-session {
    align-self:stretch;
  }
  .kpi-grid, .dashboard-kpis, .report-stat-grid {
    grid-template-columns:1fr;
  }
  .trend-chart {
    height:180px;
  }
  table {
    min-width:640px;
  }
}

@media (prefers-reduced-motion:reduce) {
  *, *::before, *::after {
    animation-duration:0.01ms !important;
    transition-duration:0.01ms !important;
  }
}
/* Organization directory and profile refresh */
.organization-directory-hero {
  position:relative; display:grid; grid-template-columns:minmax(0, 1fr) 220px auto; align-items:center; gap:24px;
  min-height:230px; overflow:hidden; margin:0 0 20px; padding:30px 34px; border:1px solid color-mix(in srgb, var(--d-primary) 15%, transparent); border-radius:22px;
  background:radial-gradient(circle at 74% 22%, color-mix(in srgb, var(--d-primary) 22%, transparent), transparent 28%), linear-gradient(115deg, var(--d-sidebar-bg) 0%, var(--d-sidebar-bg) 57%, var(--d-primary) 100%);
  color:var(--d-primary-ink); box-shadow: 0 18px 40px rgba(15,38,83,.16);
}
.directory-hero-copy { position:relative; z-index:1; }
.directory-eyebrow { display:flex; align-items:center; gap:9px; color:var(--d-sidebar-ink); font-size:12px; font-weight:700; letter-spacing:.02em; }
.directory-live-dot { width:7px; height:7px; border-radius:50%; background:var(--d-primary); box-shadow: 0 0 0 4px rgba(103,232,180,.14); }
.directory-hero-copy h1 { margin:13px 0 7px; color:var(--d-primary-ink); font-size:clamp(27px, 3.4vw, 39px); font-weight:800; letter-spacing:-.035em; line-height:1.2; }
.directory-hero-copy h1 em { color:var(--d-primary); font-style:normal; }
.directory-hero-copy > p { max-width:550px; margin:0; color:var(--d-sidebar-ink); font-size:14px; line-height:1.8; }
.directory-hero-meta { display:flex; align-items:center; gap:13px; margin-top:22px; color:var(--d-sidebar-ink); font-size:12px; }
.directory-hero-meta strong { color:var(--d-primary-ink); font-size:16px; }
.directory-meta-divider { width:1px; height:15px; background:rgba(255,255,255,.24); }
.directory-hero-side { position:relative; display:grid; place-items:center; min-height:164px; }
.directory-hero-glyph { position:relative; z-index:1; display:grid; place-items:center; width:100px; height:100px; border:1px solid rgba(206,228,255,.27); border-radius:28px; background:rgba(255,255,255,.08); color:var(--d-sidebar-ink); backdrop-filter:blur(8px); transform:rotate(-5deg); }
.directory-hero-glyph svg { width:60px; height:60px; }
.directory-orbit { position:absolute; width:160px; height:160px; border:1px solid color-mix(in srgb, var(--d-primary) 12%, transparent); border-radius:50%; }
.orbit-two { width:210px; height:210px; }
.hero-side-label { position:absolute; z-index:2; bottom:0; padding:5px 10px; border:1px solid rgba(255,255,255,.12); border-radius:20px; background:rgba(9,20,43,.45); color:var(--d-sidebar-ink); font-size:10px; }
.directory-create-button { position:relative; z-index:2; display:flex; align-items:center; gap:12px; min-width:210px; padding:14px; border:1px solid rgba(255,255,255,.2); border-radius:15px; background:rgba(255,255,255,.1); color:var(--d-primary-ink); text-decoration:none; backdrop-filter:blur(8px); transition:.2s ease; }
.directory-create-button:hover { border-color:rgba(255,255,255,.42); background:rgba(255,255,255,.17); transform:translateY(-2px); }
.create-button-icon { display:grid; place-items:center; width:39px; height:39px; flex:0 0 39px; border-radius:12px; background:var(--d-surface-3); color:var(--d-ink); font-size:25px; font-weight:500; }
.directory-create-button strong, .directory-create-button small { display:block; }
.directory-create-button strong { font-size:13px; }
.directory-create-button small { margin-top:3px; color:var(--d-sidebar-ink); font-size:10px; }
.directory-create-button > svg { width:17px; height:17px; margin-inline-start:auto; color:var(--d-sidebar-ink); }
.directory-workspace { display:grid; grid-template-columns:290px minmax(0, 1fr); align-items:start; gap:16px; }
.directory-filter-panel, .directory-results-panel { min-width:0; overflow:hidden; border:1px solid var(--border); border-radius:17px; background:var(--surface); box-shadow: 0 3px 15px rgba(15,23,42,.035); }
.directory-filter-panel { padding:20px; }
.directory-filter-heading { display:flex; align-items:flex-start; justify-content:space-between; gap:8px; margin-bottom:19px; }
.directory-filter-title { display:flex; align-items:center; gap:11px; }
.filter-title-icon { display:grid; place-items:center; width:37px; height:37px; border-radius:12px; background:var(--primary-light); color:var(--primary); font-size:25px; }
.directory-filter-title h2 { margin:0; color:var(--text-main); font-size:14px; }
.directory-filter-title p { margin:4px 0 0; color:var(--text-muted); font-size:10px; line-height:1.6; }
.directory-clear-link { display:inline-flex; align-items:center; gap:4px; white-space:nowrap; color:var(--primary); font-size:10px; text-decoration:none; }
.directory-clear-link span { font-size:17px; }
.directory-filters-grid { display:flex; flex-direction:column; gap:13px; }
.directory-filters-grid label { display:flex; flex-direction:column; gap:6px; color:var(--text-body); font-size:11px; font-weight:650; }
.directory-filters-grid input, .directory-filters-grid select { width:100%; min-height:40px; padding:0 11px; border:1px solid var(--border); border-radius:9px; outline:0; background:var(--surface); color:var(--text-main); font:inherit; font-size:11px; transition:.18s ease; }
.directory-filters-grid input:focus, .directory-filters-grid select:focus { border-color:var(--d-primary); box-shadow: 0 0 0 3px color-mix(in srgb, var(--d-primary) 11%, transparent); }
.directory-input-wrap { position:relative; }
.directory-input-wrap input { padding-inline-start:36px; }
.directory-input-wrap svg { position:absolute; inset-inline-start:11px; top:12px; width:16px; height:16px; color:var(--text-muted); pointer-events:none; }
.directory-apply-button { display:inline-flex; align-items:center; justify-content:center; gap:8px; min-height:42px; margin-top:3px; border:0; border-radius:10px; background:var(--d-primary); color:var(--d-primary-ink); font:inherit; font-size:12px; font-weight:700; cursor:pointer; transition:.18s ease; }
.directory-apply-button:hover { background:var(--d-primary); box-shadow: 0 6px 14px rgba(23,78,166,.2); transform:translateY(-1px); }
.directory-apply-button svg { width:16px; height:16px; }
.directory-results-head { display:flex; align-items:center; justify-content:space-between; gap:15px; padding:19px 22px; border-bottom:1px solid var(--border-light); }
.results-title-line { display:flex; align-items:center; gap:9px; }
.results-title-line h2 { margin:0; color:var(--text-main); font-size:16px; }
.results-title-mark { width:4px; height:19px; border-radius:5px; background:var(--d-primary); }
.directory-results-head p { margin:6px 0 0; color:var(--text-muted); font-size:11px; }
.directory-results-count { min-width:62px; text-align:center; }
.directory-results-count strong, .directory-results-count span { display:block; }
.directory-results-count strong { color:var(--text-main); font-size:21px; }
.directory-results-count span { color:var(--text-muted); font-size:10px; }
.filter-count-badge { padding:4px 7px; border-radius:20px; background:var(--primary-light); color:var(--primary); font-size:9px; font-weight:700; }
.directory-table-scroll { overflow-x:auto; }
.directory-table { width:100%; min-width:740px; border-collapse:collapse; }
.directory-table th { padding:12px 13px; background:var(--surface-alt); color:var(--text-muted); font-size:10px; font-weight:700; text-align:right; white-space:nowrap; }
.directory-table td { padding:14px 13px; border-bottom:1px solid var(--border-light); color:var(--text-body); font-size:11px; vertical-align:middle; }
.directory-table tbody tr { transition:background .16s ease; }
.directory-table tbody tr:hover { background:var(--surface-hover); }
.directory-table tbody tr:last-child td { border-bottom:0; }
.directory-company-cell { display:flex; align-items:center; gap:11px; min-width:180px; }
.directory-company-avatar { display:grid; place-items:center; width:42px; height:42px; flex:0 0 42px; border:1px solid var(--d-line); border-radius:13px; background:linear-gradient(145deg, var(--d-surface-2), var(--d-surface-3)); color:var(--d-ink-soft); font-size:16px; font-weight:800; }
.directory-company-info { display:flex; flex-direction:column; min-width:0; gap:2px; }
.directory-company-info a { overflow:hidden; max-width:210px; color:var(--text-main); font-size:12px; font-weight:750; text-decoration:none; text-overflow:ellipsis; white-space:nowrap; }
.directory-company-info a:hover { color:var(--primary); }
.directory-company-info > span { color:var(--text-muted); font-size:9px; }
.directory-company-info > small { color:var(--text-subtle); font-family:var(--font-mono); font-size:8px; }
.directory-plan-pill, .directory-currency-pill { display:inline-flex; align-items:center; gap:6px; padding:5px 8px; border:1px solid var(--border-light); border-radius:20px; background:var(--surface-alt); color:var(--text-body); font-size:10px; white-space:nowrap; }
.directory-plan-pill > span { width:6px; height:6px; border-radius:50%; background:var(--d-primary); }
.directory-currency-pill { border-color:var(--primary-border); background:var(--primary-light); color:var(--primary); font-family:var(--font-latin); font-weight:750; }
.directory-muted-label { color:var(--text-subtle); font-size:10px; }
.directory-contact { display:flex; flex-direction:column; gap:4px; min-width:120px; }
.directory-contact a { overflow:hidden; max-width:180px; color:var(--text-body); font-size:10px; text-decoration:none; text-overflow:ellipsis; }
.directory-contact a:hover { color:var(--primary); }
.directory-contact small { color:var(--text-muted); font-size:9px; direction:ltr; text-align:right; }
.directory-status { display:inline-flex; align-items:center; gap:6px; padding:5px 8px; border:1px solid transparent; border-radius:20px; font-size:9px; font-weight:700; white-space:nowrap; }
.directory-status i { width:6px; height:6px; border-radius:50%; background:currentColor; }
.directory-status-active { border-color:color-mix(in srgb, var(--d-primary) 35%, var(--d-line)); background:var(--d-surface-2); color:var(--d-primary-strong); }
.directory-status-trial { border-color:color-mix(in srgb, var(--d-warn) 35%, var(--d-line)); background:var(--d-surface-2); color:var(--d-warn); }
.directory-status-suspended { border-color:color-mix(in srgb, var(--d-danger) 35%, var(--d-line)); background:var(--d-surface-2); color:var(--d-danger); }
.directory-date { display:block; color:var(--text-body); white-space:nowrap; }
.directory-date-time { display:block; margin-top:3px; color:var(--text-subtle); font-family:var(--font-mono); font-size:9px; }
.directory-open-link { display:grid; place-items:center; width:30px; height:30px; border:1px solid var(--border); border-radius:9px; color:var(--text-muted); transition:.17s ease; }
.directory-open-link:hover { border-color:var(--primary-border); background:var(--primary-light); color:var(--primary); }
.directory-open-link svg { width:15px; height:15px; }
.directory-empty-state { display:flex; align-items:center; flex-direction:column; padding:50px 15px; color:var(--text-muted); text-align:center; }
.directory-empty-state > span { display:grid; place-items:center; width:44px; height:44px; margin-bottom:12px; border-radius:14px; background:var(--surface-muted); color:var(--primary); font-size:26px; }
.directory-empty-state strong { color:var(--text-main); font-size:14px; }
.directory-empty-state p { margin:5px 0 12px; font-size:11px; }
.directory-empty-state a { color:var(--primary); font-size:11px; font-weight:700; text-decoration:none; }
.directory-pagination { display:flex; align-items:center; justify-content:space-between; gap:12px; padding:13px 20px; border-top:1px solid var(--border-light); color:var(--text-muted); font-size:10px; }
.directory-pagination strong { color:var(--text-main); }
.directory-profile-hero { position:relative; overflow:hidden; margin-bottom:18px; padding:25px 28px; border-radius:20px; background:linear-gradient(112deg, var(--d-sidebar-bg), var(--d-primary) 80%, var(--d-primary)); color:var(--d-primary-ink); }
.directory-profile-hero::after { position:absolute; inset-inline-end:18%; top:-85px; width:260px; height:260px; border:1px solid rgba(255,255,255,.1); border-radius:50%; box-shadow: 0 0 0 34px rgba(255,255,255,.025), 0 0 0 72px rgba(255,255,255,.02); content: ""; }
.organization-profile-heading { position:relative; z-index:1; align-items:center; margin:0; }
.organization-profile-identity .company-avatar { width:62px; height:62px; flex-basis:62px; border:1px solid rgba(255,255,255,.3); border-radius:18px; background:rgba(255,255,255,.13); color:var(--d-primary-ink); box-shadow: 0 8px 20px rgba(0,0,0,.12); }
.organization-profile-identity h1 { color:var(--d-primary-ink); font-size:clamp(23px, 3vw, 32px); letter-spacing:-.025em; }
.organization-profile-identity p { color:var(--d-sidebar-ink); font-size:11px; }
.organization-profile-identity .eyebrow { color:var(--d-sidebar-ink); font-size:10px; }
.organization-profile-actions { flex-wrap:wrap; }
.organization-profile-actions .status { border:1px solid rgba(255,255,255,.22); background:rgba(255,255,255,.12); color:var(--d-primary-ink); }
.organization-profile-actions .button { border-color:var(--d-line); background:var(--d-surface); color:var(--d-ink); font-size:11px; font-weight:750; }
.organization-profile-nav { position:sticky; z-index:5; top:8px; justify-content:flex-start; margin:0 0 20px; padding:7px; border-color:var(--border); box-shadow: 0 8px 20px rgba(15,23,42,.055); }
.organization-profile-nav a { padding:9px 13px; font-size:11px; white-space:nowrap; }
.organization-profile-section { margin:24px 0 30px; }
.section-heading { margin-bottom:12px; }
.section-heading h2 { font-size:17px; font-weight:800; }
.section-heading p { font-size:11px; }
.organization-facts-grid { grid-template-columns:repeat(4, minmax(0, 1fr)); gap:10px; }
.profile-fact { position:relative; overflow:hidden; min-height:92px; padding:15px; border-radius:13px; box-shadow: 0 2px 8px rgba(15,23,42,.025); }
.profile-fact::before { position:absolute; inset-inline-start:0; top:14px; bottom:14px; width:3px; border-radius:3px; background:var(--d-surface-3); content: ""; }
.profile-fact > span { margin-bottom:9px; font-size:10px; }
.profile-fact > strong { font-size:12px; line-height:1.65; }
.profile-fact small { display:block; margin-top:3px; font-size:9px; }
.organization-notes { border:1px solid var(--border); border-inline-start:3px solid var(--d-primary); background:var(--surface); font-size:11px; }
.business-count-grid { grid-template-columns:repeat(4, minmax(0,1fr)); gap:10px; }
.business-count { position:relative; overflow:hidden; padding:16px 17px; border-radius:14px; }
.business-count strong { color:var(--text-main); font-size:22px; font-variant-numeric:tabular-nums; }
.business-count > span { margin:0; font-size:10px; }
.organization-detail-grid { gap:12px; }
.organization-detail-card { border-radius:15px; box-shadow: 0 2px 10px rgba(15,23,42,.03); }
.organization-detail-card .panel-head { padding:17px 18px 13px; }
.organization-detail-card .panel-head h3 { font-size:13px; font-weight:800; }
.organization-detail-card .panel-head p { font-size:10px; }
.organization-detail-card .table-scroll { padding-inline:5px; }
.organization-detail-card table { font-size:11px; }
.organization-detail-card th { color:var(--text-muted); font-size:9px; }
.organization-detail-card td { padding:11px 12px; font-size:10px; }
.organization-detail-card .status, .organization-detail-card .role-pill { font-size:9px; }
.tag-list { padding:0 17px 16px; }
.tag-list .role-pill { padding:6px 9px; border:1px solid var(--border); border-radius:8px; background:var(--surface-alt); color:var(--text-body); }
.organization-profile-section .panel.section-gap { margin-top:12px; }
.organization-profile-section .panel-head { border-bottom:1px solid var(--border-light); }
@media (max-width:1100px) {
  .organization-directory-hero { grid-template-columns:minmax(0, 1fr) 150px auto; padding:25px; }
  .directory-workspace { grid-template-columns:250px minmax(0,1fr); gap:12px; }
  .directory-filter-panel { padding:16px; }
  .directory-table { min-width:690px; }
  .organization-facts-grid { grid-template-columns:repeat(3,minmax(0,1fr)); }
}
@media (max-width:820px) {
  .organization-directory-hero { grid-template-columns:minmax(0,1fr) auto; }
  .directory-hero-side { display:none; }
  .directory-workspace { grid-template-columns:1fr; }
  .directory-filters-grid { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); }
  .directory-search-field { grid-column:span 2; }
  .directory-apply-button { align-self:end; }
}
@media (max-width:650px) {
  .organization-directory-hero { grid-template-columns:1fr; gap:18px; min-height:0; padding:22px 19px; border-radius:17px; }
  .directory-hero-copy h1 { font-size:26px; }
  .directory-hero-copy > p { font-size:12px; }
  .directory-hero-meta { margin-top:15px; font-size:10px; }
  .directory-create-button { width:100%; }
  .directory-filters-grid { grid-template-columns:repeat(2,minmax(0,1fr)); }
  .directory-search-field { grid-column:span 2; }
  .directory-filter-panel { padding:15px; }
  .directory-results-head { padding:15px; }
  .directory-results-head p { max-width:290px; line-height:1.6; }
  .directory-table { min-width:0; }
  .directory-table thead { display:none; }
  .directory-table, .directory-table tbody { display:block; width:100%; }
  .directory-table tbody { padding:10px; }
  .directory-table tbody tr { display:grid; grid-template-columns:minmax(0,1fr) auto; gap:2px 10px; margin-bottom:9px; padding:11px; border:1px solid var(--border-light); border-radius:13px; background:var(--surface); }
  .directory-table tbody tr:last-child { margin-bottom:0; }
  .directory-table td { display:flex; align-items:center; justify-content:space-between; gap:10px; padding:7px 2px; border:0; font-size:10px; }
  .directory-table td::before { color:var(--text-muted); content:attr(data-label); font-size:9px; }
  .directory-table td:first-child { grid-column:1 / -1; justify-content:flex-start; margin-bottom:5px; padding-bottom:10px; border-bottom:1px solid var(--border-light); }
  .directory-table td:first-child::before, .directory-table td:last-child::before { display:none; }
  .directory-table td:nth-child(3) { grid-column:1 / -1; }
  .directory-table td:last-child { position:absolute; justify-self:end; margin-top:2px; }
  .directory-table tbody tr { position:relative; }
  .directory-company-cell { min-width:0; }
  .directory-company-info a { max-width:230px; }
  .directory-contact { flex-direction:row; align-items:center; justify-content:flex-start; flex-wrap:wrap; }
  .directory-contact a { max-width:220px; }
  .directory-pagination { align-items:center; flex-direction:column; }
  .directory-profile-hero { padding:20px 17px; border-radius:16px; }
  .organization-profile-heading { align-items:flex-start; flex-direction:column; gap:15px; }
  .organization-profile-identity { gap:12px; }
  .organization-profile-identity .company-avatar { width:48px; height:48px; flex-basis:48px; border-radius:14px; }
  .organization-profile-identity h1 { font-size:21px; }
  .organization-profile-identity p { overflow-wrap:anywhere; font-size:10px; }
  .organization-profile-actions { align-items:center; }
  .organization-profile-nav { top:0; margin-bottom:14px; }
  .organization-profile-nav a { padding:8px 10px; font-size:10px; }
  .organization-facts-grid { grid-template-columns:repeat(2,minmax(0,1fr)); }
  .business-count-grid { grid-template-columns:repeat(2,minmax(0,1fr)); }
  .section-heading { align-items:flex-start; }
  .section-heading h2 { font-size:15px; }
  .section-heading p { max-width:280px; font-size:10px; line-height:1.55; }
  .organization-profile-section { margin:20px 0 24px; }
}
@media (max-width:390px) {
  .directory-filters-grid { grid-template-columns:1fr; }
  .directory-search-field { grid-column:auto; }
  .directory-company-info a { max-width:175px; }
  .organization-facts-grid { grid-template-columns:1fr; }
}

/* ==========================================================================
   AUTHENTICATION & LOGIN PORTAL (EXECUTIVE SECURITY DESIGN)
   ========================================================================== */
.login-page {
  min-height:100vh;
  display:flex;
  align-items:center;
  justify-content:center;
  padding:32px 20px;
  position:relative;
  overflow-x:hidden;
  background-color:var(--bg-page);
  background-image:radial-gradient(at 0% 0%, color-mix(in srgb, var(--d-primary) 8%, transparent) 0px, transparent 50%),
    radial-gradient(at 100% 100%, rgba(16, 185, 129, 0.05) 0px, transparent 50%),
    radial-gradient(at 50% 50%, rgba(15, 23, 42, 0.02) 0px, transparent 50%);
}


.login-card {
  width:100%;
  max-width:440px;
  background:var(--surface);
  border:1px solid var(--border);
  border-radius:24px;
  padding:38px 34px 30px;
  box-shadow: 0 20px 45px -10px rgba(15, 23, 42, 0.08), 0 1px 3px rgba(15, 23, 42, 0.04);
  position:relative;
  z-index:1;
  backdrop-filter:blur(12px);
  -webkit-backdrop-filter:blur(12px);
  transition:var(--transition);
  animation:loginCardFadeIn 0.4s cubic-bezier(0.16, 1, 0.3, 1) both;
}

@keyframes loginCardFadeIn {
  from {
    opacity:0;
    transform:translateY(14px) scale(0.99);
  }
  to {
    opacity:1;
    transform:translateY(0) scale(1);
  }
}

:root .login-card {
  background:var(--d-surface);
  border-color:rgba(226, 232, 240, 0.95);
  box-shadow: 0 20px 40px -10px rgba(15, 23, 42, 0.07), 0 0 0 1px rgba(15, 23, 42, 0.02);
}


.login-brand {
  display:flex;
  align-items:center;
  justify-content:center;
  gap:14px;
  margin-bottom:24px;
  padding:0 0 20px 0;
  border-bottom:1px solid var(--border);
  text-decoration:none;
}

.login-brand .brand-mark {
  width:44px;
  height:44px;
  border-radius:13px;
  font-size:20px;
  box-shadow: 0 4px 16px color-mix(in srgb, var(--d-primary) 35%, transparent);
}

.login-brand .brand-text {
  display:flex;
  flex-direction:column;
  text-align:right;
}

.login-brand .brand-text b {
  font-family:var(--font-latin);
  font-size:14px;
  font-weight:800;
  letter-spacing:0.05em;
  color:var(--text-main);
}


.login-brand .brand-text small {
  font-size:10.5px;
  color:var(--text-muted);
  font-weight:500;
  margin-top:2px;
}

.login-card h1 {
  font-size:21px;
  font-weight:850;
  letter-spacing:-0.02em;
  color:var(--text-main);
  text-align:center;
  margin:0 0 6px;
}

.login-card > p {
  font-size:12px;
  color:var(--text-muted);
  text-align:center;
  margin:0 0 22px;
  line-height:1.6;
}

.login-card .form-grid {
  display:grid;
  grid-template-columns:1fr;
  gap:16px;
}

.login-foot {
  display:flex;
  align-items:center;
  justify-content:center;
  gap:6px;
  text-align:center;
  color:var(--text-muted);
  font-size:11px;
  font-weight:500;
  margin-top:22px;
  padding-top:18px;
  border-top:1px solid var(--border);
}

/* ==========================================================================
   FORM CONTROLS & SYSTEM INPUTS (PRECISION TUNED)
   ========================================================================== */
.form-panel {
  padding:26px 28px;
}

.form-grid {
  display:grid;
  grid-template-columns:repeat(2, minmax(0, 1fr));
  gap:18px 22px;
}

.form-grid label,
label {
  display:flex;
  flex-direction:column;
  gap:7px;
  font-size:11.5px;
  font-weight:700;
  color:var(--text-body);
}

.form-grid label span.subline,
label small.subline {
  font-size:10.5px;
  font-weight:400;
  color:var(--text-muted);
  line-height:1.5;
  margin-top:3px;
}

input:not([type="checkbox"]):not([type="radio"]),
select,
textarea {
  width:100%;
  height:42px;
  padding:0 14px;
  border-radius:var(--radius-md);
  border:1px solid var(--border);
  background-color:var(--surface);
  color:var(--text-main);
  font-family:var(--font-arabic);
  font-size:12.5px;
  font-weight:500;
  transition:border-color 0.18s ease, box-shadow 0.18s ease, background-color 0.18s ease;
  outline:none;
}

:root input:not([type="checkbox"]):not([type="radio"]),
:root select,
:root textarea {
  background-color:var(--d-surface);
  border-color:var(--d-line);
}


input:not([type="checkbox"]):not([type="radio"]):hover,
select:hover,
textarea:hover {
  border-color:var(--border-hover);
}

input:not([type="checkbox"]):not([type="radio"]):focus,
select:focus,
textarea:focus {
  border-color:var(--primary);
  box-shadow: 0 0 0 3px var(--primary-glow);
}


input::placeholder,
textarea::placeholder {
  color:var(--text-subtle);
  font-weight:400;
}

textarea {
  height:auto;
  min-height:84px;
  padding:10px 14px;
  line-height:1.6;
  resize:vertical;
}

select {
  cursor:pointer;
  appearance:none;
  background-image:url("data:image/svg+xml,%3Csvg width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%2364748b' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round' xmlns='http://www.w3.org/2000/svg'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
  background-repeat:no-repeat;
  background-position:left 14px center;
  padding-left:36px;
}


label.checkbox-label,
.checkbox-label {
  display:flex !important;
  flex-direction:row !important;
  align-items:center;
  gap:10px;
  cursor:pointer;
  font-weight:600 !important;
  font-size:12px;
  color:var(--text-main);
  user-select:none;
}

input[type="checkbox"],
input[type="radio"] {
  width:17px;
  height:17px;
  accent-color:var(--primary);
  cursor:pointer;
  margin:0;
}

label.span-2,
.span-2 {
  grid-column:1 / -1;
}

.form-actions {
  grid-column:1 / -1;
  display:flex;
  align-items:center;
  gap:12px;
  margin-top:8px;
  padding-top:16px;
  border-top:1px solid var(--border);
}

.button.full {
  width:100%;
}

/* ==========================================================================
   SYSTEM NOTICES & ALERT BANNERS
   ========================================================================== */
.notice {
  display:flex;
  align-items:flex-start;
  gap:12px;
  padding:14px 18px;
  border-radius:var(--radius-lg);
  font-size:12px;
  line-height:1.6;
  margin-bottom:20px;
  border:1px solid transparent;
  animation:noticeSlideDown 0.25s ease-out both;
}

@keyframes noticeSlideDown {
  from {
    opacity:0;
    transform:translateY(-8px);
  }
  to {
    opacity:1;
    transform:translateY(0);
  }
}

.notice svg {
  flex-shrink:0;
  margin-top:2px;
}

.notice ul {
  margin:6px 0 0;
  padding-right:20px;
  list-style-type:disc;
}

.notice ul li {
  margin-bottom:3px;
}

/* Success / Ok */
.notice.success,
.notice.ok {
  background-color:var(--emerald-bg);
  border-color:var(--emerald-border);
  color:var(--emerald-text);
}

/* Error */
.notice.error {
  background-color:var(--rose-bg);
  border-color:var(--rose-border);
  color:var(--rose-text);
}

/* Warning */
.notice.warn,
.notice.warning {
  background-color:var(--amber-bg);
  border-color:var(--amber-border);
  color:var(--amber-text);
}

/* Info */
.notice.info {
  background-color:var(--sky-bg);
  border-color:var(--sky-border);
  color:var(--sky-text);
}

/* ==========================================================================
   TABLE & DIRECTORY FILTERS BAR
   ========================================================================== */
.filters {
  display:flex;
  align-items:center;
  gap:10px;
  flex-wrap:wrap;
}

.filters input,
.filters select {
  height:38px;
  padding:0 12px;
  border-radius:var(--radius-sm);
  font-size:11.5px;
}

.filters input {
  min-width:220px;
}

.filters select {
  min-width:140px;
}

/* ==========================================================================
   AUTHENTICATION & EXECUTIVE LOGIN PORTAL (NOVA ENTERPRISE)
   ========================================================================== */
.login-page {
  min-height:100vh;
  min-height:100svh;
  display:flex;
  flex-direction:column;
  align-items:center;
  justify-content:center;
  padding:24px 20px;
  position:relative;
  overflow-x:hidden;
  font-family:var(--font-arabic), -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background-color:var(--d-surface-2);
  background-image:radial-gradient(circle at 12% 15%, color-mix(in srgb, var(--d-primary) 12%, transparent) 0%, transparent 40%),
    radial-gradient(circle at 88% 85%, rgba(16, 185, 129, 0.09) 0%, transparent 40%),
    radial-gradient(circle at 50% 50%, rgba(99, 102, 241, 0.05) 0%, transparent 60%);
  color:var(--d-ink);
  transition:background-color 0.3s ease, color 0.3s ease;
}


/* Background Ambient Orbits */
.login-page::before,
.login-page::after {
  content: "";
  position:fixed;
  border-radius:50%;
  pointer-events:none;
  z-index:0;
}

.login-page::before {
  top:-160px;
  inset-inline-start:10%;
  width:440px;
  height:440px;
  border:1px solid color-mix(in srgb, var(--d-primary) 12%, transparent);
  box-shadow: 0 0 0 45px color-mix(in srgb, var(--d-primary) 3%, transparent), 0 0 0 95px color-mix(in srgb, var(--d-primary) 2%, transparent);
}

.login-page::after {
  bottom:-200px;
  inset-inline-end:6%;
  width:520px;
  height:520px;
  border:1px solid rgba(16, 185, 129, 0.1);
  box-shadow: 0 0 0 50px rgba(16, 185, 129, 0.025), 0 0 0 110px rgba(16, 185, 129, 0.015);
}

/* --------------------------------------------------------------------------
   TOP EXECUTIVE BAR
   -------------------------------------------------------------------------- */
.auth-topbar {
  position:relative;
  z-index:2;
  width:100%;
  max-width:1360px;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:16px;
  padding:12px 20px;
  margin-bottom:22px;
  border-radius:18px;
  background:rgba(255, 255, 255, 0.72);
  border:1px solid rgba(226, 232, 240, 0.8);
  box-shadow: 0 4px 20px -2px rgba(15, 23, 42, 0.04);
  backdrop-filter:blur(14px);
  -webkit-backdrop-filter:blur(14px);
}


.auth-brand {
  display:flex;
  align-items:center;
  gap:12px;
  text-decoration:none;
  color:inherit;
}

.auth-brand-mark {
  width:42px;
  height:42px;
  border-radius:12px;
  display:grid;
  place-items:center;
  background:linear-gradient(135deg, var(--d-primary), var(--d-primary));
  box-shadow: 0 4px 14px color-mix(in srgb, var(--d-primary) 35%, transparent);
  flex-shrink:0;
}

.auth-brand-mark svg {
  width:24px;
  height:24px;
}

.auth-brand-copy {
  display:flex;
  flex-direction:column;
}

.auth-brand-copy strong {
  font-family:var(--font-latin), sans-serif;
  font-size:14px;
  font-weight:800;
  letter-spacing:0.04em;
  color:var(--d-ink);
}


.auth-brand-copy strong i {
  color:var(--d-primary);
  font-style:normal;
}

.auth-brand-copy small {
  font-size:10px;
  color:var(--d-muted);
  font-weight:500;
}


.auth-topbar-status {
  display:inline-flex;
  align-items:center;
  gap:8px;
  padding:6px 14px;
  border-radius:30px;
  background:rgba(16, 185, 129, 0.09);
  border:1px solid rgba(16, 185, 129, 0.22);
  color:var(--d-primary-strong);
  font-size:11px;
  font-weight:600;
}


.auth-live-pulse {
  width:7px;
  height:7px;
  border-radius:50%;
  background:var(--d-primary);
  box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.25);
  animation:authPulse 2s infinite ease-in-out;
}

@keyframes authPulse {
  0%, 100% { transform:scale(1); opacity:1; }
  50% { transform:scale(1.3); opacity:0.7; }
}

.auth-topbar-actions {
  display:flex;
  align-items:center;
  gap:10px;
}

.auth-theme-btn {
  width:38px;
  height:38px;
  border-radius:11px;
  border:1px solid rgba(203, 213, 225, 0.8);
  background:var(--d-surface);
  color:var(--d-ink-soft);
  display:grid;
  place-items:center;
  cursor:pointer;
  transition:all 0.2s ease;
}

.auth-theme-btn:hover {
  background:var(--d-surface-2);
  color:var(--d-primary);
  border-color:var(--d-primary);
  transform:translateY(-1px);
}



.auth-theme-btn svg {
  width:18px;
  height:18px;
}

.auth-version-pill {
  font-family:var(--font-latin), sans-serif;
  font-size:10px;
  font-weight:700;
  letter-spacing:0.05em;
  padding:5px 10px;
  border-radius:8px;
  background:color-mix(in srgb, var(--d-primary) 8%, transparent);
  color:var(--d-primary);
  border:1px solid color-mix(in srgb, var(--d-primary) 20%, transparent);
}


/* --------------------------------------------------------------------------
   MASTER PORTAL CARD
   -------------------------------------------------------------------------- */
.auth-portal-card {
  position:relative;
  z-index:1;
  width:100%;
  max-width:1360px;
  min-height:740px;
  display:grid;
  grid-template-columns:minmax(430px, 0.95fr) minmax(460px, 1.05fr);
  border-radius:28px;
  background:var(--d-surface);
  border:1px solid rgba(226, 232, 240, 0.9);
  box-shadow:
    0 30px 80px -15px rgba(15, 23, 42, 0.12),
    0 4px 16px -2px rgba(15, 23, 42, 0.04);
  overflow:hidden;
  animation:authCardEnter 0.5s cubic-bezier(0.16, 1, 0.3, 1) both;
}


@keyframes authCardEnter {
  from { opacity:0; transform:translateY(16px) scale(0.99); }
  to { opacity:1; transform:translateY(0) scale(1); }
}

/* --------------------------------------------------------------------------
   RIGHT CONSOLE:AUTHENTICATION FORM
   -------------------------------------------------------------------------- */
.auth-console {
  display:flex;
  flex-direction:column;
  justify-content:space-between;
  padding:clamp(34px, 4.5vw, 54px) clamp(32px, 4.5vw, 56px);
  background:var(--d-surface);
  position:relative;
  z-index:1;
}


.auth-console-header {
  margin-bottom:24px;
}

.auth-kicker {
  display:inline-flex;
  align-items:center;
  gap:8px;
  margin-bottom:12px;
  padding:5px 12px;
  border-radius:20px;
  background:color-mix(in srgb, var(--d-primary) 8%, transparent);
  border:1px solid color-mix(in srgb, var(--d-primary) 18%, transparent);
  color:var(--d-primary);
  font-size:11px;
  font-weight:700;
}


.auth-kicker-dot {
  width:6px;
  height:6px;
  border-radius:50%;
  background:var(--d-primary);
}


.auth-console-header h1 {
  font-size:clamp(26px, 2.8vw, 32px);
  font-weight:850;
  letter-spacing:-0.02em;
  color:var(--d-ink);
  margin:0 0 8px;
}


.auth-console-header p {
  font-size:13px;
  color:var(--d-muted);
  margin:0;
  line-height:1.6;
}


/* Alert Box */
.auth-alert-box {
  display:flex;
  align-items:flex-start;
  gap:12px;
  padding:14px 16px;
  margin-bottom:22px;
  border-radius:14px;
  background:var(--d-surface-2);
  border:1px solid color-mix(in srgb, var(--d-danger) 35%, var(--d-line));
  color:var(--d-danger);
  animation:authAlertIn 0.3s ease both;
}


@keyframes authAlertIn {
  from { opacity:0; transform:translateY(-6px); }
  to { opacity:1; transform:translateY(0); }
}

.auth-alert-icon {
  width:24px;
  height:24px;
  flex-shrink:0;
  color:var(--d-danger);
  margin-top:1px;
}


.auth-alert-icon svg {
  width:22px;
  height:22px;
}

.auth-alert-text {
  display:flex;
  flex-direction:column;
  gap:2px;
  font-size:12px;
  line-height:1.5;
}

.auth-alert-text strong {
  font-weight:700;
}

/* --------------------------------------------------------------------------
   INPUT FIELDS REDESIGN & SHAPE
   -------------------------------------------------------------------------- */
.auth-form {
  display:flex;
  flex-direction:column;
  gap:20px;
}

.auth-input-group {
  display:flex;
  flex-direction:column;
  gap:8px;
}

.auth-field-header {
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:8px;
}

.auth-label {
  display:inline-flex;
  align-items:center;
  gap:7px;
  font-size:12.5px;
  font-weight:750;
  color:var(--d-ink);
  cursor:pointer;
}


.auth-label svg {
  width:16px;
  height:16px;
  color:var(--d-primary);
  flex-shrink:0;
}


.auth-badge-hint {
  font-size:10.5px;
  font-weight:600;
  color:var(--d-muted);
  padding:3px 8px;
  border-radius:6px;
  background:var(--d-surface-2);
}


/* Input Shell (Modern, High-End Border & Glass Glow) */
.auth-field-shell {
  position:relative;
  display:flex;
  align-items:center;
  width:100%;
  border-radius:14px;
  background:var(--d-surface-2);
  border:1.5px solid var(--d-line);
  transition:all 0.22s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.03);
}


.auth-field-shell:hover {
  border-color:var(--d-muted-soft);
  background:var(--d-surface);
}


.auth-field-shell:focus-within {
  border-color:var(--d-primary);
  background:var(--d-surface);
  box-shadow:
    0 0 0 4px color-mix(in srgb, var(--d-primary) 14%, transparent),
    0 4px 16px color-mix(in srgb, var(--d-primary) 8%, transparent);
}


/* Dedicated Icon Box */
.auth-field-icon {
  display:grid;
  place-items:center;
  width:44px;
  height:52px;
  flex-shrink:0;
  color:var(--d-muted);
  transition:color 0.2s ease;
  pointer-events:none;
}

.auth-field-shell:focus-within .auth-field-icon {
  color:var(--d-primary);
}


.auth-field-icon svg {
  width:19px;
  height:19px;
}

/* Input Itself */
.auth-input {
  flex:1;
  height:54px;
  padding:0 14px 0 16px;
  border:none;
  background:transparent !important;
  outline:none;
  font-family:var(--font-latin), var(--font-arabic), sans-serif;
  font-size:14px;
  font-weight:550;
  color:var(--d-ink) !important;
}


.auth-input::placeholder {
  color:var(--d-muted-soft);
  font-family:var(--font-arabic), sans-serif;
  font-size:13px;
  font-weight:400;
}


.auth-input.has-toggle {
  padding-inline-end:8px;
}

/* Eye Show/Hide Toggle Button (Non-overlapping, Clean End Alignment) */
.auth-toggle-pass {
  display:grid;
  place-items:center;
  width:38px;
  height:38px;
  margin-inline-end:8px;
  border:none;
  border-radius:9px;
  background:transparent;
  color:var(--d-muted);
  cursor:pointer;
  transition:all 0.2s ease;
  flex-shrink:0;
}

.auth-toggle-pass:hover {
  background:color-mix(in srgb, var(--d-primary) 8%, transparent);
  color:var(--d-primary);
  transform:scale(1.06);
}


.auth-toggle-pass svg {
  width:18px;
  height:18px;
}

.auth-toggle-pass .password-eye-hide {
  display:none;
}

.auth-toggle-pass[aria-pressed="true"] .password-eye-show {
  display:none;
}

.auth-toggle-pass[aria-pressed="true"] .password-eye-hide {
  display:block;
}

/* CapsLock Warning */
.auth-caps-warning {
  display:inline-flex;
  align-items:center;
  gap:7px;
  padding:6px 12px;
  border-radius:8px;
  background:var(--d-surface-2);
  border:1px solid color-mix(in srgb, var(--d-warn) 35%, var(--d-line));
  color:var(--d-warn);
  font-size:11px;
  font-weight:600;
  margin-top:4px;
}


.auth-caps-warning svg {
  width:15px;
  height:15px;
  flex-shrink:0;
}

/* --------------------------------------------------------------------------
   OPTIONS ROW & REMEMBER ME
   -------------------------------------------------------------------------- */
.auth-options-row {
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  flex-wrap:wrap;
  padding:2px 0;
}

.auth-remember-check {
  display:inline-flex;
  align-items:center;
  gap:9px;
  cursor:pointer;
  user-select:none;
}

.auth-remember-check input {
  position:absolute;
  opacity:0;
  width:0;
  height:0;
}

.auth-custom-checkbox {
  width:20px;
  height:20px;
  border-radius:6px;
  border:1.5px solid var(--d-line);
  background:var(--d-surface);
  display:grid;
  place-items:center;
  color:var(--d-primary-ink);
  transition:all 0.2s ease;
  flex-shrink:0;
}


.auth-custom-checkbox svg {
  width:13px;
  height:13px;
  opacity:0;
  transform:scale(0.6);
  transition:all 0.2s ease;
}

.auth-remember-check input:checked + .auth-custom-checkbox {
  background:var(--d-primary);
  border-color:var(--d-primary);
}

.auth-remember-check input:checked + .auth-custom-checkbox svg {
  opacity:1;
  transform:scale(1);
}

.auth-remember-text {
  font-size:12px;
  font-weight:600;
  color:var(--d-ink-soft);
}


.auth-secure-chip {
  display:inline-flex;
  align-items:center;
  gap:5px;
  font-size:11px;
  color:var(--d-muted);
  font-weight:550;
}


.auth-secure-chip svg {
  width:14px;
  height:14px;
  color:var(--d-primary);
}

/* --------------------------------------------------------------------------
   SUBMIT BUTTON (HIGH IMPACT)
   -------------------------------------------------------------------------- */
.auth-submit-btn {
  position:relative;
  width:100%;
  height:56px;
  display:flex;
  align-items:center;
  justify-content:center;
  gap:12px;
  border:none;
  border-radius:14px;
  background:linear-gradient(135deg, var(--d-primary) 0%, var(--d-primary) 55%, var(--d-primary) 100%);
  color:var(--d-primary-ink);
  font-family:var(--font-arabic), sans-serif;
  font-size:14.5px;
  font-weight:800;
  cursor:pointer;
  box-shadow:
    0 10px 25px -4px color-mix(in srgb, var(--d-primary) 38%, transparent),
    0 4px 10px -2px color-mix(in srgb, var(--d-primary) 20%, transparent);
  transition:all 0.24s cubic-bezier(0.16, 1, 0.3, 1);
  overflow:hidden;
  margin-top:4px;
}

.auth-submit-btn::before {
  content: "";
  position:absolute;
  top:0;
  inset-inline-start:-100%;
  width:60%;
  height:100%;
  background:linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.25), transparent);
  transform:skewX(-25deg);
  transition:inset-inline-start 0.65s ease;
}

.auth-submit-btn:hover {
  transform:translateY(-2px);
  box-shadow:
    0 14px 30px -4px color-mix(in srgb, var(--d-primary) 45%, transparent),
    0 6px 14px -2px color-mix(in srgb, var(--d-primary) 25%, transparent);
  filter:brightness(1.05);
}

.auth-submit-btn:hover::before {
  inset-inline-start:140%;
}

.auth-submit-btn:active {
  transform:translateY(0) scale(0.99);
}

.auth-submit-icon {
  display:grid;
  place-items:center;
  transition:transform 0.2s ease;
}

.auth-submit-btn:hover .auth-submit-icon {
  transform:translateX(-4px);
}

.auth-submit-icon svg {
  width:18px;
  height:18px;
}

.auth-submit-spinner {
  display:none;
  width:18px;
  height:18px;
  border:2.5px solid rgba(255, 255, 255, 0.3);
  border-top-color:var(--d-line);
  border-radius:50%;
  animation:authSpin 0.7s linear infinite;
}

@keyframes authSpin {
  to { transform:rotate(360deg); }
}

.auth-submit-btn.is-submitting {
  cursor:wait;
  opacity:0.88;
}

.auth-submit-btn.is-submitting .auth-submit-icon {
  display:none;
}

.auth-submit-btn.is-submitting .auth-submit-spinner {
  display:block;
}

/* --------------------------------------------------------------------------
   ONE-CLICK QUICK DEMO AUTOFILL CARD
   -------------------------------------------------------------------------- */
.auth-demo-card {
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  padding:10px 14px;
  border-radius:12px;
  background:var(--d-surface-2);
  border:1px dashed var(--d-line);
  transition:border-color 0.2s ease;
}


.auth-demo-info {
  display:flex;
  align-items:center;
  gap:8px;
}

.auth-demo-badge {
  font-size:10px;
  font-weight:700;
  padding:2px 7px;
  border-radius:6px;
  background:var(--d-surface-3);
  color:var(--d-ink-soft);
}


.auth-demo-info code {
  font-family:monospace;
  font-size:11px;
  color:var(--d-primary);
  font-weight:600;
}


.auth-demo-btn {
  display:inline-flex;
  align-items:center;
  gap:6px;
  padding:6px 12px;
  border-radius:8px;
  border:1px solid color-mix(in srgb, var(--d-primary) 25%, transparent);
  background:color-mix(in srgb, var(--d-primary) 8%, transparent);
  color:var(--d-primary);
  font-family:var(--font-arabic), sans-serif;
  font-size:11.5px;
  font-weight:700;
  cursor:pointer;
  transition:all 0.2s ease;
}

.auth-demo-btn:hover {
  background:var(--d-primary);
  color:var(--d-primary-ink);
  border-color:var(--d-primary);
}



.auth-demo-btn.is-filled {
  background:var(--d-primary) !important;
  color:var(--d-primary-ink) !important;
  border-color:var(--d-primary) !important;
}

.auth-demo-btn svg {
  width:14px;
  height:14px;
}

/* Console Footer */
.auth-console-foot {
  margin-top:26px;
  padding-top:18px;
  border-top:1px solid var(--d-line);
  display:flex;
  flex-direction:column;
  gap:10px;
}


.auth-foot-badge {
  display:flex;
  align-items:center;
  gap:8px;
  font-size:11px;
  color:var(--d-muted);
  line-height:1.5;
}


.auth-foot-badge svg {
  width:16px;
  height:16px;
  color:var(--d-primary);
  flex-shrink:0;
}


.auth-foot-links {
  display:flex;
  align-items:center;
  justify-content:center;
  gap:8px;
  font-size:10px;
  color:var(--d-muted-soft);
}


/* --------------------------------------------------------------------------
   LEFT SHOWCASE:PLATFORM INTELLIGENCE
   -------------------------------------------------------------------------- */
.auth-showcase {
  position:relative;
  display:flex;
  flex-direction:column;
  justify-content:space-between;
  padding:clamp(34px, 4.5vw, 54px) clamp(32px, 4.5vw, 56px);
  background:radial-gradient(ellipse at 80% 20%, color-mix(in srgb, var(--d-primary) 35%, transparent) 0%, transparent 45%),
    radial-gradient(ellipse at 15% 85%, rgba(13, 148, 136, 0.22) 0%, transparent 45%),
    linear-gradient(145deg, var(--d-sidebar-bg) 0%, var(--d-sidebar-bg) 55%, var(--d-sidebar-bg) 100%);
  color:var(--d-primary-ink);
  overflow:hidden;
  border-inline-start:1px solid rgba(255, 255, 255, 0.08);
}

.auth-showcase-mesh {
  position:absolute;
  inset:0;
  opacity:0.12;
  background-image:linear-gradient(rgba(255, 255, 255, 0.15) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.15) 1px, transparent 1px);
  background-size:36px 36px;
  mask-image:radial-gradient(circle at 60% 40%, var(--d-sidebar-bg) 0%, transparent 75%);
  pointer-events:none;
}

.auth-showcase-glow {
  position:absolute;
  width:480px;
  height:480px;
  top:-100px;
  inset-inline-start:-100px;
  border-radius:50%;
  background:radial-gradient(circle, color-mix(in srgb, var(--d-primary) 25%, transparent) 0%, transparent 70%);
  filter:blur(60px);
  pointer-events:none;
}

.auth-showcase-top {
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  position:relative;
  z-index:1;
}

.auth-tag-pill {
  display:inline-flex;
  align-items:center;
  gap:8px;
  padding:5px 12px;
  border-radius:20px;
  background:rgba(255, 255, 255, 0.08);
  border:1px solid rgba(255, 255, 255, 0.14);
  font-size:11px;
  font-weight:600;
  color:var(--d-sidebar-ink);
}

.auth-tag-dot {
  width:7px;
  height:7px;
  border-radius:50%;
  background:var(--d-primary);
  box-shadow: 0 0 0 3px rgba(52, 211, 153, 0.25);
}

.auth-tag-mono {
  font-family:var(--font-latin), monospace;
  font-size:9px;
  letter-spacing:0.12em;
  padding:4px 8px;
  border-radius:6px;
  background:rgba(255, 255, 255, 0.05);
  border:1px solid rgba(255, 255, 255, 0.08);
  color:var(--d-muted-soft);
}

.auth-showcase-content {
  position:relative;
  z-index:1;
  margin:24px 0 16px;
}

.auth-lead-tag {
  color:var(--d-primary);
  font-size:12px;
  font-weight:750;
  display:block;
  margin-bottom:8px;
}

.auth-showcase-content h2 {
  font-size:clamp(26px, 3.2vw, 38px);
  font-weight:850;
  line-height:1.35;
  letter-spacing:-0.025em;
  color:var(--d-primary-ink);
  margin:0 0 12px;
}

.auth-showcase-content h2 em {
  font-style:normal;
  background:linear-gradient(135deg, var(--d-primary) 0%, var(--d-primary) 100%);
  -webkit-background-clip:text;
  -webkit-text-fill-color:transparent;
}

.auth-showcase-content p {
  font-size:13px;
  line-height:1.75;
  color:var(--d-sidebar-ink);
  max-width:480px;
  margin:0;
}

/* --------------------------------------------------------------------------
   INTERACTIVE MINI DASHBOARD PREVIEW
   -------------------------------------------------------------------------- */
.auth-mini-preview {
  position:relative;
  z-index:1;
  margin:12px 0 20px;
}

.mini-preview-glass {
  border-radius:18px;
  background:rgba(15, 23, 42, 0.68);
  border:1px solid rgba(255, 255, 255, 0.12);
  box-shadow:
    0 20px 45px rgba(0, 0, 0, 0.4),
    inset 0 1px rgba(255, 255, 255, 0.1);
  backdrop-filter:blur(16px);
  -webkit-backdrop-filter:blur(16px);
  padding:16px;
  display:flex;
  flex-direction:column;
  gap:12px;
}

.mini-preview-header {
  display:flex;
  align-items:center;
  justify-content:space-between;
  padding-bottom:10px;
  border-bottom:1px solid rgba(255, 255, 255, 0.08);
}

.mini-header-dots {
  display:flex;
  align-items:center;
  gap:6px;
}

.mini-header-dots span {
  width:8px;
  height:8px;
  border-radius:50%;
}

.dot-red { background:var(--d-danger); }
.dot-yellow { background:var(--d-warn); }
.dot-green { background:var(--d-primary); }

.mini-header-title {
  font-family:var(--font-latin), monospace;
  font-size:9px;
  letter-spacing:0.08em;
  color:var(--d-muted-soft);
}

.mini-header-status {
  font-family:var(--font-latin), monospace;
  font-size:9px;
  font-weight:700;
  color:var(--d-primary);
}

.mini-preview-stats {
  display:grid;
  grid-template-columns:repeat(3, 1fr);
  gap:10px;
}

.mini-stat-card {
  display:flex;
  flex-direction:column;
  gap:4px;
  padding:10px 12px;
  border-radius:10px;
  background:rgba(255, 255, 255, 0.04);
  border:1px solid rgba(255, 255, 255, 0.06);
}

.mini-stat-card small {
  font-size:10px;
  color:var(--d-muted-soft);
}

.mini-stat-card strong {
  font-size:15px;
  font-weight:800;
  color:var(--d-primary-ink);
  font-family:var(--font-latin), sans-serif;
}

.mini-stat-trend {
  font-size:9px;
  font-weight:600;
  color:var(--d-primary);
}

.mini-preview-chart {
  position:relative;
  height:85px;
  border-radius:10px;
  overflow:hidden;
  background:rgba(10, 18, 32, 0.4);
  border:1px solid rgba(255, 255, 255, 0.06);
}

.mini-preview-chart svg {
  position:absolute;
  inset:0;
  width:100%;
  height:100%;
}

.mini-chart-floating-badge {
  position:absolute;
  bottom:8px;
  inset-inline-start:12px;
  display:inline-flex;
  align-items:center;
  gap:6px;
  padding:4px 10px;
  border-radius:20px;
  background:rgba(15, 23, 42, 0.85);
  border:1px solid rgba(255, 255, 255, 0.12);
  font-size:9.5px;
  color:var(--d-sidebar-ink);
}

.mini-chart-floating-badge .badge-dot {
  width:6px;
  height:6px;
  border-radius:50%;
  background:var(--d-primary);
}

/* --------------------------------------------------------------------------
   ENTERPRISE FEATURE HIGHLIGHTS
   -------------------------------------------------------------------------- */
.auth-showcase-features {
  display:flex;
  flex-direction:column;
  gap:10px;
  position:relative;
  z-index:1;
}

.auth-feature-item {
  display:flex;
  align-items:flex-start;
  gap:12px;
  padding:10px 12px;
  border-radius:12px;
  background:rgba(255, 255, 255, 0.035);
  border:1px solid rgba(255, 255, 255, 0.07);
  transition:all 0.2s ease;
}

.auth-feature-item:hover {
  background:rgba(255, 255, 255, 0.065);
  border-color:color-mix(in srgb, var(--d-primary) 30%, transparent);
  transform:translateX(-3px);
}

.auth-feature-num {
  width:28px;
  height:28px;
  border-radius:8px;
  display:grid;
  place-items:center;
  background:color-mix(in srgb, var(--d-primary) 18%, transparent);
  border:1px solid color-mix(in srgb, var(--d-primary) 30%, transparent);
  color:var(--d-primary);
  font-family:var(--font-latin), sans-serif;
  font-size:11px;
  font-weight:800;
  flex-shrink:0;
}

.auth-feature-info {
  display:flex;
  flex-direction:column;
  gap:2px;
}

.auth-feature-info strong {
  font-size:12px;
  font-weight:700;
  color:var(--d-primary-ink);
}

.auth-feature-info p {
  font-size:10.5px;
  line-height:1.5;
  color:var(--d-muted-soft);
  margin:0;
}

.auth-showcase-foot {
  display:flex;
  align-items:center;
  justify-content:space-between;
  margin-top:18px;
  padding-top:14px;
  border-top:1px solid rgba(255, 255, 255, 0.08);
  font-family:var(--font-latin), sans-serif;
  font-size:9px;
  letter-spacing:0.1em;
  color:var(--d-muted);
  position:relative;
  z-index:1;
}

.foot-dot {
  width:4px;
  height:4px;
  border-radius:50%;
  background:var(--d-muted-soft);
}

/* --------------------------------------------------------------------------
   RESPONSIVE DESIGN ADAPTATIONS
   -------------------------------------------------------------------------- */
@media (max-width:1080px) {
  .auth-portal-card {
    grid-template-columns:minmax(380px, 1fr) minmax(380px, 1fr);
  }
}

@media (max-width:900px) {
  .auth-portal-card {
    grid-template-columns:1fr;
    max-width:580px;
  }
  .auth-showcase {
    display:none;
  }
  .auth-topbar {
    max-width:580px;
  }
  .auth-topbar-status {
    display:none;
  }
}

@media (max-width:520px) {
  .login-page {
    padding:12px 10px;
  }
  .auth-topbar {
    padding:10px 14px;
    margin-bottom:14px;
    border-radius:14px;
  }
  .auth-brand-mark {
    width:36px;
    height:36px;
  }
  .auth-brand-copy strong {
    font-size:13px;
  }
  .auth-portal-card {
    border-radius:20px;
  }
  .auth-console {
    padding:26px 20px;
  }
  .auth-field-shell {
    border-radius:12px;
  }
  .auth-input {
    height:50px;
    font-size:13.5px;
  }
  .auth-submit-btn {
    height:50px;
    font-size:13.5px;
  }
  .auth-options-row {
    flex-direction:column;
    align-items:flex-start;
    gap:8px;
  }
  .auth-demo-card {
    flex-direction:column;
    align-items:stretch;
    gap:8px;
  }
  .auth-demo-btn {
    justify-content:center;
  }
}

/* Motion language for the organization directory and company profile */
@keyframes directory-arrive {
  0% { opacity:0; transform:translateY(16px) scale(.99); }
  100% { opacity:1; transform:translateY(0) scale(1); }
}
@keyframes directory-glow-drift {
  0%, 100% { transform:translate3d(0,0,0) scale(1); opacity:.55; }
  50% { transform:translate3d(14px,9px,0) scale(1.12); opacity:.9; }
}
@keyframes directory-orbit-breathe {
  0%, 100% { transform:scale(.94); opacity:.45; }
  50% { transform:scale(1.06); opacity:.95; }
}
.motion-pending { opacity:0; transform:translateY(17px) scale(.992); }
.motion-visible { opacity:1; transform:translateY(0) scale(1); transition:opacity .58s cubic-bezier(.2,.75,.25,1), transform .68s cubic-bezier(.2,.75,.25,1); transition-delay:var(--motion-delay, 0ms); }
.organization-directory-hero, .directory-profile-hero { animation:directory-arrive .72s cubic-bezier(.2,.75,.25,1) both; }
.organization-directory-hero::before { position:absolute; z-index:0; inset:-45%; background:radial-gradient(ellipse at 72% 38%, rgba(111,181,255,.2), transparent 22%), radial-gradient(ellipse at 22% 80%, rgba(82,119,255,.15), transparent 26%); content: ""; animation:directory-glow-drift 8s ease-in-out infinite; pointer-events:none; }
.directory-orbit { animation:directory-orbit-breathe 6s ease-in-out infinite; }
.orbit-two { animation-delay:-3s; }
.directory-hero-glyph { animation:directory-glyph-float 5s ease-in-out infinite; }
@keyframes directory-glyph-float { 0%, 100% { transform:translateY(1px) rotate(-5deg); } 50% { transform:translateY(-7px) rotate(-2deg); } }
.directory-create-button, .directory-apply-button, .directory-open-link, .organization-detail-card, .profile-fact, .business-count { transition:transform .24s cubic-bezier(.2,.75,.25,1), box-shadow .24s ease, border-color .24s ease, background-color .24s ease; }
.directory-create-button:active, .directory-apply-button:active { transform:translateY(1px) scale(.985); }
.directory-results-panel { animation:directory-arrive .65s .12s both; }
.directory-table tbody tr { transform-origin:center; }
.directory-table tbody tr:hover { transform:translateX(-3px); box-shadow: 0 5px 18px rgba(17,45,88,.055); }
.directory-company-avatar { transition:transform .28s cubic-bezier(.2,.75,.25,1), box-shadow .28s ease; }
.directory-table tbody tr:hover .directory-company-avatar { transform:rotate(-5deg) scale(1.06); box-shadow: 0 5px 12px color-mix(in srgb, var(--d-primary) 14%, transparent); }
.profile-fact:hover, .business-count:hover, .organization-detail-card:hover { transform:translateY(-2px); border-color:var(--border-hover); box-shadow: 0 10px 25px rgba(15,23,42,.07); }
.organization-profile-nav a { transition:color .2s ease, background-color .2s ease, transform .2s ease; }
.organization-profile-nav a:hover { transform:translateY(-1px); }
.organization-profile-section:nth-of-type(odd) { --motion-delay:80ms; }
.organization-profile-section:nth-of-type(even) { --motion-delay:150ms; }
@media (prefers-reduced-motion:reduce) {
  .motion-pending, .motion-visible, .organization-directory-hero, .directory-profile-hero,
  .organization-directory-hero::before, .directory-orbit, .directory-hero-glyph,
  .directory-results-panel, .directory-table tbody tr, .directory-company-avatar,
  .profile-fact, .business-count, .organization-detail-card {
    animation:none !important; transition:none !important; opacity:1 !important; transform:none !important;
  }
}

/* Organization directory search:full-width, clear hierarchy, responsive controls. */
.directory-workspace {
  display:grid;
  grid-template-columns:minmax(0, 1fr);
  gap:18px;
}
.directory-filter-panel {
  min-width:0;
  padding:clamp(16px, 2vw, 23px);
  border:1px solid var(--border, var(--d-line));
  border-radius:18px;
  background:linear-gradient(145deg, var(--d-surface) 0%, var(--d-surface) 100%);
  box-shadow: 0 10px 30px rgba(24, 45, 78, .055);
}
.directory-filter-heading {
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:16px;
  margin-bottom:17px;
}
.directory-filter-title { align-items:center; gap:11px; }
.directory-filter-title h2 { margin:0; }
.directory-filter-title p { margin:4px 0 0; }
.directory-filters-grid {
  display:grid;
  grid-template-columns:repeat(6, minmax(0, 1fr));
  align-items:end;
  gap:13px 12px;
}
.directory-filters-grid > label {
  display:flex;
  min-width:0;
  flex-direction:column;
  gap:7px;
  color:var(--d-ink-soft);
  font-size:12px;
  font-weight:700;
}
.directory-filters-grid > label > span { line-height:1.4; }
.directory-search-field { grid-column:span 5; }
.directory-search-field .directory-input-wrap { width:100%; }
.directory-filters-grid input,
.directory-filters-grid select {
  box-sizing:border-box;
  width:100%;
  min-width:0;
  min-height:46px;
  padding:0 13px;
  border:1px solid var(--d-line);
  border-radius:11px;
  outline:0;
  background-color:var(--d-surface);
  color:var(--d-ink);
  font:inherit;
  font-size:13px;
  transition:border-color .18s ease, box-shadow .18s ease, background-color .18s ease;
}
.directory-filters-grid .directory-input-wrap input { padding-inline-start:42px; }
.directory-filters-grid input:focus,
.directory-filters-grid select:focus {
  border-color:var(--d-primary);
  background-color:var(--d-surface);
  box-shadow: 0 0 0 4px rgba(64, 112, 220, .11);
}
.directory-input-wrap svg { inset-inline-start:14px; top:14px; width:18px; height:18px; color:var(--d-muted); }
.directory-apply-button {
  justify-content:center;
  min-height:46px;
  align-self:end;
  gap:8px;
  padding:0 16px;
  border-radius:11px;
  white-space:nowrap;
  box-shadow: 0 7px 16px rgba(42, 91, 190, .17);
}
.directory-apply-button svg { width:17px; height:17px; flex:0 0 auto; }
.directory-clear-link { flex:0 0 auto; }
@media (max-width:1050px) {
  .directory-filters-grid { grid-template-columns:repeat(3, minmax(0, 1fr)); }
  .directory-search-field { grid-column:span 2; }
}
@media (max-width:640px) {
  .directory-filter-heading { align-items:flex-start; }
  .directory-filter-title p { max-width:34ch; line-height:1.6; }
  .directory-filters-grid { grid-template-columns:repeat(2, minmax(0, 1fr)); gap:12px 10px; }
  .directory-search-field,
  .directory-apply-button { grid-column:1 / -1; }
  .directory-apply-button { width:100%; }
}
@media (max-width:390px) {
  .directory-filter-heading { flex-direction:column; }
  .directory-filters-grid { grid-template-columns:minmax(0, 1fr); }
  .directory-search-field,
  .directory-apply-button { grid-column:auto; }
}

.directory-summary {
  margin:20px 0;
  padding:clamp(17px, 2.1vw, 25px);
  border:1px solid var(--d-line);
  border-radius:20px;
  background:linear-gradient(135deg, var(--d-surface) 0%, var(--d-surface) 100%);
  box-shadow: 0 12px 32px rgba(24, 45, 78, .06);
}
.directory-summary-heading { display:flex; align-items:center; justify-content:space-between; gap:20px; margin-bottom:18px; }
.directory-summary-kicker { display:block; margin-bottom:5px; color:var(--d-primary); font-size:10px; font-weight:800; letter-spacing:.08em; }
.directory-summary-heading h2 { margin:0; color:var(--d-ink); font-size:18px; font-weight:800; }
.directory-summary-heading p { margin:6px 0 0; color:var(--d-muted); font-size:12px; }
.directory-summary-period { display:inline-flex; align-items:center; gap:8px; flex:0 0 auto; padding:9px 12px; border:1px solid var(--d-line); border-radius:999px; background:var(--d-surface-2); color:var(--d-ink-soft); font-size:11px; font-weight:700; }
.summary-live-dot { width:7px; height:7px; border-radius:50%; background:var(--d-primary); box-shadow: 0 0 0 4px rgba(71,121,229,.12); }
.directory-summary-grid { display:grid; grid-template-columns:repeat(6, minmax(0, 1fr)); gap:11px; }
.directory-summary-card { display:flex; min-width:0; min-height:112px; align-items:flex-start; gap:11px; padding:15px 13px; border:1px solid var(--d-line); border-radius:15px; background:rgba(255,255,255,.87); }
.directory-summary-card > div { display:flex; min-width:0; flex-direction:column; gap:5px; }
.directory-summary-card > div > span { overflow:hidden; color:var(--d-muted); font-size:11px; font-weight:700; text-overflow:ellipsis; white-space:nowrap; }
.directory-summary-card strong { color:var(--d-ink); font-size:24px; line-height:1.1; font-variant-numeric:tabular-nums; }
.directory-summary-card small { color:var(--d-muted); font-size:10px; }
.summary-card-icon, .summary-currency-symbol { display:grid; width:34px; height:34px; flex:0 0 34px; place-items:center; border-radius:11px; background:var(--d-surface-2); color:var(--d-primary); font-size:16px; font-weight:800; }
.summary-status-dot { width:9px; height:9px; flex:0 0 9px; margin:4px 2px 0; border-radius:50%; background:var(--d-primary); box-shadow: 0 0 0 4px rgba(41,164,122,.1); }
.summary-trial .summary-status-dot { background:var(--d-warn); box-shadow: 0 0 0 4px rgba(215,150,45,.12); }
.summary-suspended .summary-status-dot { background:var(--d-danger); box-shadow: 0 0 0 4px rgba(214,84,98,.11); }
.summary-trial strong { color:var(--d-warn); }
.summary-suspended strong { color:var(--d-danger); }
.summary-currency-symbol { font-size:11px; }
.directory-summary-footer { display:flex; flex-wrap:wrap; gap:8px 22px; margin-top:15px; padding-top:13px; border-top:1px solid var(--d-line); color:var(--d-muted); font-size:10px; }
.directory-summary-footer strong { margin-inline-start:4px; color:var(--d-ink-soft); font-variant-numeric:tabular-nums; }
@media (max-width:1200px) {
  .directory-summary-grid { grid-template-columns:repeat(3, minmax(0, 1fr)); }
}
@media (max-width:640px) {
  .directory-summary { margin-block:14px; padding:16px; }
  .directory-summary-heading { align-items:flex-start; flex-direction:column; gap:12px; }
  .directory-summary-grid { grid-template-columns:repeat(2, minmax(0, 1fr)); gap:9px; }
  .directory-summary-card { min-height:100px; padding:12px 10px; gap:8px; }
  .directory-summary-card strong { font-size:21px; }
  .directory-summary-card > div > span { font-size:10px; }
}
@media (max-width:390px) {
  .directory-summary-grid { grid-template-columns:minmax(0, 1fr); }
  .directory-summary-card { min-height:82px; }
}

/* Complete organization directory page layout */
.organizations-page { --org-ink:var(--d-ink); --org-muted:var(--d-muted); --org-line:var(--d-line); --org-blue:var(--d-primary); display:flex; flex-direction:column; gap:18px; max-width:1600px; margin-inline:auto; color:var(--org-ink); }
.org-page-header { display:flex; align-items:center; justify-content:space-between; gap:20px; padding:3px 2px 5px; }
.org-breadcrumb { display:flex; align-items:center; gap:8px; margin-bottom:12px; color:var(--d-muted); font-size:11px; }
.org-breadcrumb b { color:var(--d-sidebar-ink); font-weight:500; }
.org-breadcrumb strong { color:var(--d-ink-soft); font-weight:700; }
.org-title-row { display:flex; align-items:center; gap:13px; }
.org-title-icon { display:grid; width:47px; height:47px; flex:0 0 47px; place-items:center; border:1px solid var(--d-line); border-radius:15px; background:linear-gradient(145deg,var(--d-surface-2),var(--d-surface-2)); color:var(--d-primary); }
.org-title-icon svg { width:24px; height:24px; }
.org-title-row h1 { margin:0; color:var(--d-ink); font-size:26px; font-weight:850; letter-spacing:-.025em; }
.org-title-row p { margin:5px 0 0; color:var(--d-muted); font-size:12px; }
.org-create-action { display:inline-flex; min-height:44px; align-items:center; justify-content:center; gap:8px; padding:0 17px; border:1px solid var(--d-primary); border-radius:12px; background:linear-gradient(135deg,var(--d-primary),var(--d-primary)); color:var(--d-primary-ink); box-shadow:0 7px 16px rgba(48,94,184,.18); font-size:12px; font-weight:750; text-decoration:none; transition:transform .18s ease,box-shadow .18s ease; }
.org-create-action:hover { transform:translateY(-2px); box-shadow:0 10px 22px rgba(48,94,184,.24); }
.org-create-action svg { width:17px; height:17px; }
.org-report,.org-filter-card,.org-directory-card { overflow:hidden; border:1px solid var(--org-line); border-radius:17px; background:var(--d-surface); box-shadow:0 5px 20px rgba(26,43,70,.035); }
.org-report { padding:20px 21px 0; }
.org-report-head { display:flex; align-items:center; justify-content:space-between; gap:16px; margin-bottom:17px; }
.org-section-kicker { display:block; margin-bottom:4px; color:var(--d-primary); font-size:9px; font-weight:850; letter-spacing:.08em; }
.org-report-head h2,.org-filter-heading h2 { margin:0; color:var(--d-ink); font-size:17px; font-weight:800; }
.org-report-head p,.org-filter-heading p { margin:5px 0 0; color:var(--d-muted); font-size:11px; }
.org-report-scope { display:inline-flex; align-items:center; gap:8px; flex:0 0 auto; padding:8px 11px; border:1px solid var(--d-line); border-radius:999px; background:var(--d-surface); color:var(--d-muted); font-size:10px; font-weight:700; }
.org-report-scope i { width:7px; height:7px; border-radius:50%; background:var(--d-primary); box-shadow:0 0 0 4px var(--d-surface-2); }
.org-report-grid { display:grid; grid-template-columns:repeat(6,minmax(0,1fr)); gap:10px; }
.org-metric { display:flex; min-width:0; min-height:101px; align-items:flex-start; gap:10px; padding:14px 12px; border:1px solid var(--d-line); border-radius:13px; background:var(--d-surface); transition:transform .2s ease,border-color .2s ease,box-shadow .2s ease; }
.org-metric:hover { transform:translateY(-2px); border-color:var(--d-line); box-shadow:0 7px 18px rgba(34,58,94,.06); }
.org-metric>div { display:flex; min-width:0; flex-direction:column; gap:4px; }
.org-metric>div>span { overflow:hidden; color:var(--d-muted); font-size:10px; font-weight:750; text-overflow:ellipsis; white-space:nowrap; }
.org-metric strong { color:var(--d-ink); font-size:23px; font-variant-numeric:tabular-nums; line-height:1.15; }
.org-metric small { color:var(--d-muted-soft); font-size:9px; }
.org-metric-icon,.org-currency-icon { display:grid; width:31px; height:31px; flex:0 0 31px; place-items:center; border-radius:10px; background:var(--d-surface-2); color:var(--d-primary); }
.org-metric-icon svg { width:17px; height:17px; }
.org-metric-status { width:8px; height:8px; flex:0 0 8px; margin:4px 2px 0; border-radius:50%; background:var(--d-primary); box-shadow:0 0 0 4px var(--d-surface-2); }
.org-metric-trial .org-metric-status { background:var(--d-warn); box-shadow:0 0 0 4px var(--d-surface-3); }
.org-metric-suspended .org-metric-status { background:var(--d-danger); box-shadow:0 0 0 4px var(--d-surface-2); }
.org-metric-trial strong { color:var(--d-warn); }
.org-metric-suspended strong { color:var(--d-danger); }
.org-currency-icon { font-size:10px; font-weight:850; }
.org-report-foot { display:flex; flex-wrap:wrap; gap:8px 23px; margin:15px -21px 0; padding:12px 21px; border-top:1px solid var(--d-line); background:var(--d-surface); color:var(--d-muted); font-size:10px; }
.org-report-foot strong { margin-inline-start:4px; color:var(--d-ink-soft); font-variant-numeric:tabular-nums; }
.org-filter-card { padding:18px 20px 20px; }
.org-filter-heading { display:flex; align-items:center; justify-content:space-between; gap:14px; margin-bottom:16px; }
.org-reset-link { display:inline-flex; align-items:center; gap:5px; padding:7px 10px; border:1px solid var(--d-line); border-radius:9px; color:var(--d-danger); font-size:10px; font-weight:700; text-decoration:none; }
.org-reset-link:hover { background:var(--d-surface-2); }
.org-reset-link span { font-size:16px; line-height:10px; }
.org-filter-grid { display:grid; grid-template-columns:minmax(240px,2fr) repeat(5,minmax(120px,1fr)) auto; align-items:end; gap:11px; }
.org-field { display:flex; min-width:0; flex-direction:column; gap:6px; color:var(--d-ink-soft); font-size:10px; font-weight:750; }
.org-field>span { white-space:nowrap; }
.org-field input,.org-field select { box-sizing:border-box; width:100%; min-width:0; height:42px; padding:0 11px; border:1px solid var(--d-line); border-radius:10px; outline:0; background:var(--d-surface); color:var(--d-ink); font-family:inherit; font-size:11px; transition:border-color .18s ease,box-shadow .18s ease; }
.org-field input:focus,.org-field select:focus { border-color:var(--d-primary); box-shadow:0 0 0 3px rgba(60,108,201,.11); }
.org-search-input { position:relative; }
.org-search-input svg { position:absolute; top:12px; inset-inline-start:12px; width:17px; height:17px; color:var(--d-muted); pointer-events:none; }
.org-search-input input { padding-inline-start:38px; }
.org-filter-actions { display:flex; }
.org-submit-filter { display:inline-flex; height:42px; align-items:center; justify-content:center; gap:7px; padding:0 13px; border:0; border-radius:10px; background:var(--d-sidebar-bg); color:var(--d-primary-ink); font-family:inherit; font-size:10px; font-weight:750; white-space:nowrap; cursor:pointer; transition:background .18s ease,transform .18s ease; }
.org-submit-filter:hover { transform:translateY(-1px); background:var(--d-sidebar-bg); }
.org-submit-filter svg { width:15px; height:15px; }
.org-directory-head { display:flex; align-items:center; justify-content:space-between; gap:14px; padding:17px 20px; border-bottom:1px solid var(--d-line); }
.org-directory-title { display:flex; align-items:center; gap:9px; }
.org-directory-title h2 { margin:0; color:var(--d-ink); font-size:15px; font-weight:800; }
.org-directory-mark { width:4px; height:19px; border-radius:5px; background:var(--d-primary); }
.org-result-badge { padding:5px 8px; border:1px solid var(--d-line); border-radius:999px; background:var(--d-surface-2); color:var(--d-muted); font-size:9px; font-weight:750; }
.org-directory-head p { margin:5px 0 0 13px; color:var(--d-muted); font-size:10px; }
.org-sort-note { color:var(--d-muted); font-size:10px; }
.org-table-wrap { width:100%; overflow-x:auto; }
.org-table { width:100%; min-width:850px; border-collapse:separate; border-spacing:0; text-align:right; }
.org-table th { padding:11px 15px; border-bottom:1px solid var(--d-line); background:var(--d-surface-2); color:var(--d-muted); font-size:9px; font-weight:800; white-space:nowrap; }
.org-table td { padding:13px 15px; border-bottom:1px solid var(--d-line); color:var(--d-ink-soft); font-size:10px; vertical-align:middle; }
.org-table tbody tr { transition:background .16s ease; }
.org-table tbody tr:hover { background:var(--d-surface); }
.org-table tbody tr:last-child td { border-bottom:0; }
.org-company { display:flex; min-width:170px; align-items:center; gap:10px; }
.org-company-avatar { display:grid; width:38px; height:38px; flex:0 0 38px; place-items:center; border:1px solid var(--d-line); border-radius:12px; background:linear-gradient(145deg,var(--d-surface-2),var(--d-surface-2)); color:var(--d-primary); font-size:14px; font-weight:850; }
.org-company>div { display:flex; min-width:0; flex-direction:column; gap:3px; }
.org-company a { overflow:hidden; max-width:230px; color:var(--d-ink); font-size:11px; font-weight:800; text-decoration:none; text-overflow:ellipsis; white-space:nowrap; }
.org-company a:hover { color:var(--d-primary); }
.org-company small,.org-contact small,.org-created-time { color:var(--d-muted); font-size:9px; }
.org-company .org-public-id { color:var(--d-muted-soft); font-size:8px; }
.org-plan { display:inline-flex; align-items:center; gap:7px; padding:6px 9px; border:1px solid var(--d-line); border-radius:8px; background:var(--d-surface); color:var(--d-ink-soft); font-size:9px; font-weight:750; white-space:nowrap; }
.org-plan i { width:6px; height:6px; border-radius:50%; background:var(--d-primary); }
.org-empty-value { color:var(--d-muted-soft); font-size:9px; }
.org-contact { display:flex; min-width:140px; flex-direction:column; gap:4px; }
.org-contact a { overflow:hidden; max-width:190px; color:var(--d-muted); font-size:9px; text-decoration:none; text-overflow:ellipsis; }
.org-contact a:hover { text-decoration:underline; }
.org-currency-pill { display:inline-flex; padding:5px 8px; border:1px solid var(--d-line); border-radius:7px; background:var(--d-surface); color:var(--d-ink-soft); font-size:9px; font-weight:800; }
.org-status { display:inline-flex; align-items:center; gap:6px; padding:6px 9px; border:1px solid var(--d-line); border-radius:999px; background:var(--d-surface-2); color:var(--d-primary); font-size:9px; font-weight:750; white-space:nowrap; }
.org-status i { width:6px; height:6px; border-radius:50%; background:var(--d-primary); }
.org-status-trial { border-color:var(--d-line); background:var(--d-surface-2); color:var(--d-warn); }
.org-status-trial i { background:var(--d-warn); }
.org-status-suspended { border-color:var(--d-line); background:var(--d-surface-2); color:var(--d-danger); }
.org-status-suspended i { background:var(--d-danger); }
.org-created-date,.org-created-time { display:block; white-space:nowrap; }
.org-open-link { display:grid; width:30px; height:30px; place-items:center; border:1px solid var(--d-line); border-radius:9px; background:var(--d-surface); color:var(--d-primary); transition:all .18s ease; }
.org-open-link:hover { transform:translateX(-2px); border-color:var(--d-line); background:var(--d-surface-2); color:var(--d-primary); }
.org-open-link svg { width:15px; height:15px; }
.org-table-footer { display:flex; align-items:center; justify-content:space-between; gap:14px; min-height:55px; padding:10px 18px; border-top:1px solid var(--d-line); color:var(--d-muted); font-size:10px; }
.org-table-footer>span strong { color:var(--d-ink-soft); font-variant-numeric:tabular-nums; }
.org-table-footer nav { margin-inline-start:auto; }
.org-empty-state { display:flex; min-height:230px; align-items:center; justify-content:center; flex-direction:column; padding:22px; text-align:center; }
.org-empty-icon { display:grid; width:44px; height:44px; place-items:center; margin-bottom:10px; border-radius:14px; background:var(--d-surface-2); color:var(--d-muted); font-size:27px; }
.org-empty-state strong { color:var(--d-ink); font-size:13px; }
.org-empty-state p { margin:6px 0 12px; color:var(--d-muted); font-size:10px; }
.org-empty-state>a { color:var(--d-primary); font-size:10px; font-weight:750; text-decoration:none; }
@media (max-width:1250px) {
  .org-filter-grid { grid-template-columns:repeat(3,minmax(0,1fr)); }
  .org-field-search { grid-column:span 2; }
}
@media (max-width:900px) {
  .org-report-grid { grid-template-columns:repeat(3,minmax(0,1fr)); }
  .org-table { min-width:780px; }
}
@media (max-width:640px) {
  .organizations-page { gap:13px; }
  .org-page-header { align-items:flex-start; flex-direction:column; gap:13px; }
  .org-title-row h1 { font-size:22px; }
  .org-title-row p { max-width:42ch; line-height:1.6; }
  .org-create-action { align-self:stretch; }
  .org-report { padding:15px 14px 0; border-radius:14px; }
  .org-report-head { align-items:flex-start; flex-direction:column; gap:10px; }
  .org-report-head p { line-height:1.6; }
  .org-report-grid { grid-template-columns:repeat(2,minmax(0,1fr)); gap:8px; }
  .org-metric { min-height:91px; gap:8px; padding:11px 9px; }
  .org-metric strong { font-size:20px; }
  .org-report-foot { margin-inline:-14px; padding-inline:14px; gap:8px 15px; }
  .org-filter-card { padding:15px 14px; }
  .org-filter-heading { align-items:flex-start; }
  .org-filter-grid { grid-template-columns:repeat(2,minmax(0,1fr)); gap:10px; }
  .org-field-search,.org-filter-actions { grid-column:1/-1; }
  .org-submit-filter { width:100%; }
  .org-directory-head { align-items:flex-start; flex-direction:column; padding:14px; }
  .org-directory-head p { margin-inline-start:13px; line-height:1.6; }
  .org-sort-note { display:none; }
  .org-table { min-width:0; }
  .org-table thead { display:none; }
  .org-table,.org-table tbody { display:block; width:100%; }
  .org-table tbody { padding:8px; }
  .org-table tbody tr { position:relative; display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:1px 10px; margin-bottom:9px; padding:10px; border:1px solid var(--d-line); border-radius:12px; background:var(--d-surface); }
  .org-table tbody tr:last-child { margin-bottom:0; }
  .org-table td { display:flex; min-width:0; align-items:center; justify-content:space-between; gap:7px; padding:7px 1px; border:0; font-size:9px; }
  .org-table td::before { color:var(--d-muted); content:attr(data-label); font-size:8px; white-space:nowrap; }
  .org-table td:first-child { grid-column:1/-1; justify-content:flex-start; margin-bottom:3px; padding:2px 0 9px; border-bottom:1px solid var(--d-line); }
  .org-table td:first-child::before,.org-table td:last-child::before { display:none; }
  .org-table td:nth-child(3) { grid-column:1/-1; }
  .org-table td:last-child { position:absolute; top:8px; inset-inline-end:8px; padding:0; }
  .org-company { min-width:0; padding-inline-end:31px; }
  .org-company a { max-width:220px; }
  .org-contact { min-width:0; align-items:flex-end; }
  .org-contact a { max-width:185px; }
  .org-table-footer { align-items:center; flex-direction:column; padding:12px; }
  .org-table-footer nav { margin:0; }
}
@media (max-width:390px) {
  .org-report-grid { grid-template-columns:minmax(0,1fr); }
  .org-metric { min-height:78px; }
  .org-filter-heading { flex-direction:column; }
  .org-filter-grid { grid-template-columns:minmax(0,1fr); }
  .org-field-search,.org-filter-actions { grid-column:auto; }
}

/* Arabic readability pass:keep directory copy comfortably legible and correctly shaped. */
.organizations-page,
.organizations-page button,
.organizations-page input,
.organizations-page select {
  font-family:'Tajawal', 'Segoe UI', sans-serif;
  letter-spacing:normal;
}
.organizations-page { font-size:16px; line-height:1.75; }
.org-breadcrumb { font-size:13px; margin-bottom:10px; }
.org-title-row h1 { font-size:30px; line-height:1.35; }
.org-title-row p { font-size:15px; line-height:1.7; }
.org-create-action { font-size:14px; }
.org-section-kicker { margin-bottom:5px; font-size:12px; letter-spacing:0; }
.org-report-head h2,.org-filter-heading h2 { font-size:20px; line-height:1.5; }
.org-report-head p,.org-filter-heading p { font-size:14px; line-height:1.7; }
.org-report-scope { font-size:13px; }
.org-metric { min-height:116px; gap:12px; padding:16px 14px; }
.org-metric>div>span { font-size:13px; line-height:1.55; white-space:normal; }
.org-metric strong { font-size:27px; }
.org-metric small { color:var(--d-muted); font-size:12px; line-height:1.5; }
.org-currency-icon { font-size:12px; }
.org-report-foot { font-size:13px; line-height:1.6; }
.org-filter-card { padding:21px 22px 22px; }
.org-filter-heading { margin-bottom:19px; }
.org-reset-link { font-size:13px; }
.org-field { gap:7px; font-size:13px; line-height:1.5; }
.org-field input,.org-field select { height:47px; padding-inline:13px; font-size:14px; }
.org-search-input svg { top:15px; inset-inline-start:13px; }
.org-search-input input { padding-inline-start:40px; }
.org-submit-filter { height:47px; padding-inline:16px; font-size:13px; }
.org-directory-head { padding:20px 22px; }
.org-directory-title h2 { font-size:19px; }
.org-result-badge { font-size:12px; }
.org-directory-head p { font-size:13px; line-height:1.65; }
.org-sort-note { font-size:12px; }
.org-table th { padding:14px 16px; font-size:12px; }
.org-table td { padding:16px; font-size:13px; line-height:1.6; }
.org-company { gap:12px; }
.org-company-avatar { width:43px; height:43px; flex-basis:43px; font-size:16px; }
.org-company>div { gap:4px; }
.org-company a { font-size:15px; }
.org-company small,.org-contact small,.org-created-time { color:var(--d-muted); font-size:12px; line-height:1.5; }
.org-company .org-public-id { color:var(--d-muted); font-size:11px; }
.org-company>div>small:not(.org-public-id) { direction:ltr; text-align:right; unicode-bidi:isolate; }
.org-plan,.org-currency-pill,.org-status { font-size:12px; }
.org-empty-value,.org-contact a { font-size:13px; }
.org-contact { gap:5px; }
.org-contact a { direction:ltr; text-align:right; unicode-bidi:isolate; }
.org-created-date,.org-created-time { font-variant-numeric:tabular-nums; }
.org-table-footer { min-height:62px; font-size:13px; }
.org-empty-state strong { font-size:17px; }
.org-empty-state p,.org-empty-state>a { font-size:13px; }
@media (max-width:640px) {
  .org-title-row h1 { font-size:25px; }
  .org-title-row p { font-size:14px; }
  .org-report-head h2,.org-filter-heading h2 { font-size:19px; }
  .org-report-head p,.org-filter-heading p { font-size:13px; }
  .org-metric { min-height:103px; padding:13px 11px; }
  .org-metric>div>span { font-size:12px; }
  .org-metric strong { font-size:24px; }
  .org-metric small { font-size:11px; }
  .org-field { font-size:12px; }
  .org-field input,.org-field select { height:45px; font-size:13px; }
  .org-directory-title h2 { font-size:17px; }
  .org-directory-head p { font-size:12px; }
  .org-table td { font-size:12px; }
  .org-table td::before { font-size:11px; }
  .org-company a { font-size:14px; }
  .org-company small,.org-contact small,.org-created-time { font-size:11px; }
  .org-company .org-public-id { font-size:10px; }
  .org-table-footer { font-size:12px; }
}

/* Organizations hub — fresh page composition and Arabic-first typography */
.company-hub { --hub-ink:var(--d-ink); --hub-muted:var(--d-muted); --hub-line:var(--d-line); display:flex; max-width:1600px; margin-inline:auto; flex-direction:column; gap:20px; color:var(--hub-ink); font-family:'Tajawal','Segoe UI',sans-serif; font-size:15px; line-height:1.7; }
.company-hub * { box-sizing:border-box; letter-spacing:normal; }
.hub-hero { position:relative; display:grid; min-height:252px; grid-template-columns:minmax(0,1fr) 310px auto; align-items:center; gap:24px; overflow:hidden; padding:28px 34px; border:1px solid var(--d-sidebar-line); border-radius:23px; background:radial-gradient(ellipse at 78% 18%,color-mix(in srgb, var(--d-primary) 30%, transparent),transparent 27%),linear-gradient(115deg,var(--d-sidebar-bg) 0%,var(--d-sidebar-bg) 57%,color-mix(in srgb, var(--d-sidebar-bg) 55%, var(--d-primary)) 100%); color:var(--d-sidebar-ink); box-shadow:0 20px 42px rgba(21,46,84,.15); }
.hub-hero::before,.hub-hero::after { position:absolute; content:""; pointer-events:none; }
.hub-hero::before { inset:-50% 36% -55% -10%; border:1px solid rgba(194,220,255,.1); border-radius:50%; transform:rotate(-18deg); }
.hub-hero::after { top:-95px; inset-inline-end:35%; width:280px; height:280px; border:1px solid rgba(194,220,255,.09); border-radius:50%; }
.hub-hero-content,.hub-hero-side,.hub-create,.hub-hero-actions { position:relative; z-index:1; }
.hub-hero-actions { display:grid; min-width:235px; gap:10px; }
.hub-breadcrumb { display:flex; align-items:center; gap:10px; margin-bottom:20px; color:var(--d-muted-soft); font-size:13px; }
.hub-breadcrumb i { width:4px; height:4px; border-radius:50%; background:var(--d-primary); }
.hub-breadcrumb strong { color:var(--d-sidebar-ink); font-weight:700; }
.hub-title-icon { display:grid; width:40px; height:40px; place-items:center; margin-bottom:10px; border:1px solid color-mix(in srgb, var(--d-primary) 22%, transparent); border-radius:13px; background:rgba(255,255,255,.08); color:var(--d-sidebar-ink); }
.hub-title-icon svg { width:22px; height:22px; }
.hub-hero h1 { margin:0; color:var(--d-sidebar-ink); font-size:34px; font-weight:850; line-height:1.25; }
.hub-hero-content>p { max-width:520px; margin:9px 0 0; color:var(--d-sidebar-ink); font-size:16px; line-height:1.8; }
.hub-hero-foot { display:flex; align-items:center; gap:14px; margin-top:20px; color:var(--d-sidebar-ink); font-size:13px; }
.hub-live { display:inline-flex; align-items:center; gap:8px; }
.hub-live i { width:8px; height:8px; border-radius:50%; background:var(--d-primary); box-shadow:0 0 0 4px rgba(110,231,183,.13); }
.hub-separator { width:1px; height:16px; background:rgba(218,231,250,.25); }
.hub-hero-side { display:flex; min-height:155px; align-items:center; justify-content:center; gap:18px; }
.hub-orbit { position:absolute; width:190px; height:190px; border:1px solid rgba(180,210,250,.13); border-radius:50%; }
.hub-orbit-b { width:235px; height:235px; }
.hub-building { display:grid; width:90px; height:90px; flex:0 0 90px; place-items:center; border:1px solid rgba(213,231,255,.28); border-radius:24px; background:rgba(255,255,255,.08); color:var(--d-sidebar-ink); transform:rotate(-5deg); backdrop-filter:blur(8px); }
.hub-building svg { width:68px; height:68px; }
.hub-hero-total { position:relative; min-width:150px; padding-inline-start:18px; border-inline-start:1px solid rgba(210,229,255,.2); }
.hub-hero-total span,.hub-hero-total small { display:block; color:var(--d-sidebar-ink); font-size:12px; }
.hub-hero-total strong { display:block; margin:4px 0; color:var(--d-sidebar-ink); font-size:39px; font-weight:850; font-variant-numeric:tabular-nums; line-height:1.2; }
.hub-create { display:flex; min-width:210px; align-items:center; gap:11px; padding:13px 14px; border:1px solid rgba(218,234,255,.25); border-radius:15px; background:rgba(255,255,255,.1); color:var(--d-sidebar-ink); text-decoration:none; backdrop-filter:blur(8px); transition:background .2s ease,transform .2s ease; }
.hub-create:hover { transform:translateY(-2px); background:rgba(255,255,255,.17); }
.hub-create-plus { display:grid; width:40px; height:40px; flex:0 0 40px; place-items:center; border-radius:12px; background:var(--d-surface-3); color:var(--d-ink-soft); font-size:27px; line-height:1; }
.hub-create b,.hub-create small { display:block; }
.hub-create b { color:var(--d-sidebar-ink); font-size:14px; }
.hub-create small { margin-top:3px; color:var(--d-sidebar-ink); font-size:12px; }
.hub-create>svg { width:17px; height:17px; margin-inline-start:auto; color:var(--d-sidebar-ink); }
.hub-workspace-link { border-color:rgba(111,224,205,.34); background:rgba(20,160,143,.16); }
.hub-workspace-link:hover { background:rgba(20,160,143,.28); }
.hub-workspace-link .hub-create-plus { background:rgba(204,255,242,.95); color:var(--d-primary-strong); font-size:22px; }
.hub-summary,.hub-filters,.hub-directory { overflow:hidden; border:1px solid var(--hub-line); border-radius:19px; background:var(--d-surface); box-shadow:0 7px 24px rgba(25,45,74,.045); }
.hub-summary { padding:21px 22px 19px; }
.hub-summary-heading { display:flex; align-items:flex-end; justify-content:space-between; gap:16px; margin-bottom:17px; }
.hub-summary-heading>div>span { color:var(--d-primary); font-size:12px; font-weight:800; }
.hub-summary-heading h2 { margin:3px 0 0; color:var(--d-ink); font-size:21px; font-weight:850; }
.hub-summary-heading p { margin:0; color:var(--d-muted); font-size:13px; }
.hub-stat-grid { display:grid; grid-template-columns:repeat(6,minmax(0,1fr)); gap:11px; }
.hub-stat { display:flex; min-width:0; min-height:110px; align-items:flex-start; gap:11px; padding:15px 13px; border:1px solid var(--d-line); border-radius:15px; background:linear-gradient(145deg,var(--d-surface),var(--d-surface)); transition:transform .2s ease,border-color .2s ease,box-shadow .2s ease; }
.hub-stat:hover { transform:translateY(-2px); border-color:var(--d-line); box-shadow:0 9px 20px rgba(25,50,86,.06); }
.hub-stat>div { display:flex; min-width:0; flex-direction:column; gap:3px; }
.hub-stat small { color:var(--d-ink-soft); font-size:13px; font-weight:750; }
.hub-stat strong { color:var(--d-ink); font-size:27px; font-weight:850; font-variant-numeric:tabular-nums; line-height:1.25; }
.hub-stat>div>span { color:var(--d-muted); font-size:12px; }
.hub-stat-icon,.hub-currency-symbol { display:grid; width:35px; height:35px; flex:0 0 35px; place-items:center; border-radius:11px; background:var(--d-surface-2); color:var(--d-primary); }
.hub-stat-icon svg { width:19px; height:19px; }
.hub-stat-dot { width:9px; height:9px; flex:0 0 9px; margin:6px 2px 0; border-radius:50%; background:var(--d-primary); box-shadow:0 0 0 4px var(--d-surface-2); }
.is-trial .hub-stat-dot { background:var(--d-warn); box-shadow:0 0 0 4px var(--d-surface-2); }
.is-suspended .hub-stat-dot { background:var(--d-danger); box-shadow:0 0 0 4px var(--d-surface-2); }
.is-trial strong { color:var(--d-warn); }
.is-suspended strong { color:var(--d-danger); }
.hub-currency-symbol { font-size:13px; font-weight:850; }
.hub-filters { padding:21px 22px 22px; }
.hub-section-head,.hub-directory-head { display:flex; align-items:center; justify-content:space-between; gap:16px; }
.hub-section-head { margin-bottom:18px; }
.hub-section-head>div,.hub-directory-head>div { display:flex; align-items:center; gap:12px; }
.hub-section-index { display:grid; width:34px; height:34px; flex:0 0 34px; place-items:center; border:1px solid var(--d-line); border-radius:11px; background:var(--d-surface-2); color:var(--d-primary); font-family:var(--font-latin); font-size:12px; font-weight:800; }
.hub-section-head h2,.hub-directory-head h2 { margin:0; color:var(--d-ink); font-size:20px; font-weight:850; }
.hub-section-head p,.hub-directory-head p { margin:3px 0 0; color:var(--d-muted); font-size:13px; }
.hub-clear { display:inline-flex; align-items:center; gap:7px; padding:8px 11px; border:1px solid var(--d-line); border-radius:10px; color:var(--d-danger); font-size:13px; font-weight:750; text-decoration:none; }
.hub-clear:hover { background:var(--d-surface-2); }
.hub-clear b { font-size:19px; line-height:1; }
.hub-filter-grid { display:grid; grid-template-columns:repeat(7,minmax(0,1fr)); align-items:end; gap:13px; }
.hub-search { grid-column:span 2; }
.hub-field { display:flex; min-width:0; flex-direction:column; gap:7px; color:var(--d-ink-soft); font-size:13px; font-weight:750; }
.hub-field>span { line-height:1.5; }
.hub-field>input,.hub-field>select,.hub-search>div { box-sizing:border-box; width:100%; height:47px; border:1px solid var(--d-line); border-radius:11px; background:var(--d-surface); color:var(--d-ink); font-family:'Tajawal','Segoe UI',sans-serif; font-size:14px; }
.hub-field>input,.hub-field>select { padding:0 12px; outline:0; }
.hub-field>input:focus,.hub-field>select:focus,.hub-search>div:focus-within { border-color:var(--d-primary); box-shadow:0 0 0 4px rgba(58,104,193,.1); }
.hub-search>div { position:relative; display:flex; align-items:center; }
.hub-search svg { position:absolute; inset-inline-start:13px; width:18px; height:18px; color:var(--d-muted); pointer-events:none; }
.hub-search input { box-sizing:border-box; width:100%; height:100%; padding:0 42px 0 12px; border:0; outline:0; border-radius:inherit; background:transparent; color:inherit; font:inherit; }
.hub-search input::placeholder { color:var(--d-muted-soft); }
.hub-filter-submit { display:inline-flex; min-height:47px; align-items:center; justify-content:center; gap:9px; grid-column:1/-1; padding:0 18px; border:0; border-radius:11px; background:linear-gradient(110deg,var(--d-primary),var(--d-primary)); color:var(--d-sidebar-ink); font-family:'Tajawal','Segoe UI',sans-serif; font-size:14px; font-weight:800; cursor:pointer; box-shadow:0 7px 15px rgba(52,102,190,.16); transition:transform .18s ease,box-shadow .18s ease; }
.hub-filter-submit:hover { transform:translateY(-1px); box-shadow:0 10px 20px rgba(52,102,190,.23); }
.hub-filter-submit svg { width:18px; height:18px; }
.hub-filter-state { display:flex; flex-wrap:wrap; align-items:center; gap:8px; margin-top:13px; color:var(--d-muted); font-size:12px; }
.hub-filter-state>b { padding:5px 9px; border:1px solid var(--d-line); border-radius:999px; background:var(--d-surface-2); color:var(--d-ink-soft); font-size:12px; font-weight:700; }
.hub-directory-head { padding:20px 22px; border-bottom:1px solid var(--d-line); }
.hub-count { display:inline-flex; align-items:center; gap:5px; padding:7px 11px; border:1px solid var(--d-line); border-radius:999px; background:var(--d-surface-2); color:var(--d-muted); font-size:13px; }
.hub-count b { color:var(--d-ink); font-size:15px; }
.hub-table-scroll { overflow-x:auto; }
.hub-table { width:100%; min-width:930px; border-collapse:separate; border-spacing:0; text-align:right; }
.hub-table th { padding:14px 17px; border-bottom:1px solid var(--d-line); background:var(--d-surface-2); color:var(--d-ink-soft); font-size:13px; font-weight:850; white-space:nowrap; }
.hub-table td { padding:15px 17px; border-bottom:1px solid var(--d-line); color:var(--d-ink-soft); font-size:13px; line-height:1.55; vertical-align:middle; }
.hub-table tbody tr { transition:background .16s ease; }
.hub-table tbody tr:hover { background:var(--d-surface); }
.hub-table tbody tr:last-child td { border-bottom:0; }
.hub-company { display:flex; min-width:195px; align-items:center; gap:12px; }
.hub-avatar { display:grid; width:43px; height:43px; flex:0 0 43px; place-items:center; border:1px solid var(--d-line); border-radius:13px; background:linear-gradient(145deg,var(--d-surface-2),var(--d-surface-3)); color:var(--d-primary); font-size:17px; font-weight:850; }
.hub-company>div { display:flex; min-width:0; flex-direction:column; gap:3px; }
.hub-company a { overflow:hidden; max-width:240px; color:var(--d-ink); font-size:15px; font-weight:850; text-decoration:none; text-overflow:ellipsis; white-space:nowrap; }
.hub-company a:hover { color:var(--d-primary); }
.hub-company small,.hub-contact small,.hub-time { color:var(--d-muted); font-size:12px; }
.hub-company>div>small:not(.hub-public-id) { direction:ltr; text-align:right; unicode-bidi:isolate; }
.hub-company .hub-public-id { color:var(--d-muted); font-family:var(--font-latin); font-size:11px; }
.hub-plan,.hub-currency,.hub-status { display:inline-flex; align-items:center; gap:7px; padding:7px 10px; border:1px solid var(--d-line); border-radius:9px; background:var(--d-surface); color:var(--d-ink-soft); font-size:12px; font-weight:800; white-space:nowrap; }
.hub-plan { border-color:var(--d-line); background:var(--d-surface-2); color:var(--d-ink-soft); }
.hub-plan i,.hub-status i { width:7px; height:7px; border-radius:50%; background:var(--d-primary); }
.hub-no-plan { color:var(--d-muted); font-size:13px; }
.hub-contact { display:flex; min-width:150px; flex-direction:column; gap:4px; }
.hub-contact a { overflow:hidden; max-width:210px; color:var(--d-primary); font-size:13px; direction:ltr; text-align:right; text-overflow:ellipsis; text-decoration:none; unicode-bidi:isolate; }
.hub-contact a:hover { text-decoration:underline; }
.hub-currency { background:var(--d-surface); font-family:var(--font-latin); }
.hub-status { border-color:var(--d-line); background:var(--d-surface-2); color:var(--d-primary); }
.hub-status i { background:var(--d-primary); }
.hub-status.status-trial { border-color:var(--d-line); background:var(--d-surface-2); color:var(--d-warn); }
.hub-status.status-trial i { background:var(--d-warn); }
.hub-status.status-suspended { border-color:var(--d-line); background:var(--d-surface-2); color:var(--d-danger); }
.hub-status.status-suspended i { background:var(--d-danger); }
.hub-date,.hub-time { display:block; white-space:nowrap; font-variant-numeric:tabular-nums; }
.hub-open { display:grid; width:34px; height:34px; place-items:center; border:1px solid var(--d-line); border-radius:10px; background:var(--d-surface); color:var(--d-primary); transition:transform .18s ease,background .18s ease; }
.hub-open:hover { transform:translateX(-2px); background:var(--d-surface-2); }
.hub-open svg { width:17px; height:17px; }
.hub-pagination { display:flex; min-height:62px; align-items:center; justify-content:space-between; gap:16px; padding:11px 20px; border-top:1px solid var(--d-line); color:var(--d-muted); font-size:13px; }
.hub-pagination b { color:var(--d-ink-soft); font-variant-numeric:tabular-nums; }
.hub-pagination nav { margin-inline-start:auto; }
.hub-empty { display:flex; min-height:250px; align-items:center; justify-content:center; flex-direction:column; padding:25px; text-align:center; }
.hub-empty>span { display:grid; width:54px; height:54px; place-items:center; border-radius:17px; background:var(--d-surface-2); color:var(--d-muted); font-size:34px; }
.hub-empty h3 { margin:13px 0 0; color:var(--d-ink); font-size:19px; }
.hub-empty p { margin:5px 0 13px; color:var(--d-muted); font-size:14px; }
.hub-empty a { color:var(--d-primary); font-size:14px; font-weight:800; text-decoration:none; }
@media (max-width:1320px) {
  .hub-hero { grid-template-columns:minmax(0,1fr) 260px; }
  .hub-hero-actions { grid-column:1/-1; justify-self:start; }
  .hub-stat-grid { grid-template-columns:repeat(3,minmax(0,1fr)); }
  .hub-filter-grid { grid-template-columns:repeat(3,minmax(0,1fr)); }
  .hub-search { grid-column:span 2; }
}
@media (max-width:760px) {
  .company-hub { gap:14px; }
  .hub-hero { min-height:0; grid-template-columns:minmax(0,1fr); gap:18px; padding:23px 21px; border-radius:18px; }
  .hub-hero-side { justify-content:flex-start; min-height:110px; }
  .hub-orbit { inset-inline-start:0; width:140px; height:140px; }
  .hub-orbit-b { width:180px; height:180px; }
  .hub-building { width:70px; height:70px; flex-basis:70px; border-radius:19px; }
  .hub-building svg { width:54px; height:54px; }
  .hub-hero-total { min-width:0; }
  .hub-hero h1 { font-size:30px; }
  .hub-hero-content>p { font-size:14px; }
  .hub-hero-actions { grid-column:auto; justify-self:stretch; }
  .hub-create { justify-self:stretch; }
  .hub-summary,.hub-filters { padding:17px; border-radius:15px; }
  .hub-summary-heading { align-items:flex-start; flex-direction:column; gap:5px; }
  .hub-summary-heading h2 { font-size:19px; }
  .hub-summary-heading p { font-size:12px; }
  .hub-stat-grid { grid-template-columns:repeat(2,minmax(0,1fr)); gap:9px; }
  .hub-stat { min-height:100px; gap:8px; padding:12px 10px; }
  .hub-stat strong { font-size:24px; }
  .hub-stat small { font-size:12px; }
  .hub-stat>div>span { font-size:11px; }
  .hub-section-head,.hub-directory-head { align-items:flex-start; }
  .hub-section-head h2,.hub-directory-head h2 { font-size:18px; }
  .hub-section-head p,.hub-directory-head p { font-size:12px; line-height:1.6; }
  .hub-filter-grid { grid-template-columns:repeat(2,minmax(0,1fr)); gap:11px; }
  .hub-search,.hub-filter-submit { grid-column:1/-1; }
  .hub-filter-submit { width:100%; }
  .hub-directory-head { padding:16px; }
  .hub-table { min-width:0; }
  .hub-table thead { display:none; }
  .hub-table,.hub-table tbody { display:block; width:100%; }
  .hub-table tbody { padding:9px; }
  .hub-table tbody tr { position:relative; display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:3px 12px; margin-bottom:10px; padding:12px; border:1px solid var(--d-line); border-radius:14px; background:var(--d-surface); }
  .hub-table tbody tr:last-child { margin-bottom:0; }
  .hub-table td { display:flex; min-width:0; align-items:center; justify-content:space-between; gap:8px; padding:7px 0; border:0; font-size:12px; }
  .hub-table td::before { color:var(--d-muted); content:attr(data-label); font-size:11px; white-space:nowrap; }
  .hub-table td:first-child { grid-column:1/-1; justify-content:flex-start; margin-bottom:4px; padding:0 0 10px; border-bottom:1px solid var(--d-line); }
  .hub-table td:first-child::before,.hub-table td:last-child::before { display:none; }
  .hub-table td:nth-child(3) { grid-column:1/-1; }
  .hub-table td:last-child { position:absolute; top:10px; inset-inline-end:10px; padding:0; }
  .hub-company { min-width:0; padding-inline-end:34px; }
  .hub-company a { max-width:220px; font-size:14px; }
  .hub-contact { min-width:0; }
  .hub-contact a { max-width:200px; }
  .hub-pagination { align-items:center; flex-direction:column; padding:14px; }
  .hub-pagination nav { margin:0; }
}
@media (max-width:420px) {
  .hub-stat-grid,.hub-filter-grid { grid-template-columns:minmax(0,1fr); }
  .hub-search,.hub-filter-submit { grid-column:auto; }
  .hub-filter-heading { align-items:flex-start; flex-direction:column; }
  .hub-section-head,.hub-directory-head { gap:9px; }
  .hub-count { font-size:11px; }
}

/* ==========================================================================
   HUB SUBSCRIPTION EXTENSIONS & STATUS VARIANTS
   ========================================================================== */
.hub-status.status-trialing { border-color:var(--d-line); background:var(--d-surface-2); color:var(--d-warn); }
.hub-status.status-trialing i { background:var(--d-warn); }
.hub-status.status-past_due { border-color:color-mix(in srgb, var(--d-danger) 35%, var(--d-line)); background:var(--d-surface-2); color:var(--d-danger); }
.hub-status.status-past_due i { background:var(--d-danger); }
.hub-status.status-paused { border-color:var(--d-line); background:var(--d-surface-2); color:var(--d-ink-soft); }
.hub-status.status-paused i { background:var(--d-muted-soft); }
.hub-status.status-canceled { border-color:color-mix(in srgb, var(--d-danger) 35%, var(--d-line)); background:var(--d-surface-2); color:var(--d-danger); }
.hub-status.status-canceled i { background:var(--d-danger); }
.hub-status.status-paid { border-color:var(--d-line); background:var(--d-surface-2); color:var(--d-primary); }
.hub-status.status-paid i { background:var(--d-primary); }
.hub-status.status-open { border-color:var(--d-line); background:var(--d-surface-2); color:var(--d-primary); }
.hub-status.status-open i { background:var(--d-primary); }
.hub-status.status-overdue { border-color:color-mix(in srgb, var(--d-danger) 35%, var(--d-line)); background:var(--d-surface-2); color:var(--d-danger); }
.hub-status.status-overdue i { background:var(--d-danger); }
.hub-status.status-void { border-color:var(--d-line); background:var(--d-surface-2); color:var(--d-ink-soft); }
.hub-status.status-void i { background:var(--d-muted-soft); }
.hub-status.status-refunded { border-color:#8b5cf6; background:var(--d-surface-2); color:#8b5cf6; }
.hub-status.status-refunded i { background:#8b5cf6; }

.hub-inline-select { height:34px; border:1px solid var(--d-line); border-radius:8px; padding:0 8px; font-size:12px; font-weight:700; background:var(--d-surface); color:var(--d-ink); outline:0; }
.hub-inline-btn { height:34px; padding:0 12px; border:0; border-radius:8px; background:var(--d-primary); color:var(--d-sidebar-ink); font-size:12px; font-weight:750; cursor:pointer; transition:background .15s ease; white-space:nowrap; }
.hub-inline-btn:hover { background:var(--d-primary); }

.hub-billing-pill { display:inline-flex; align-items:center; gap:5px; padding:5px 9px; border-radius:8px; font-size:12px; font-weight:700; white-space:nowrap; border:1px solid var(--d-line); background:var(--d-surface-2); color:var(--d-ink-soft); }
.hub-billing-pill.is-yearly { border-color:var(--d-line); background:var(--d-surface-2); color:#8b5cf6; }
.hub-billing-pill.is-monthly { border-color:var(--d-line); background:var(--d-surface-2); color:var(--d-primary); }

.hub-subscription-amount { display:flex; align-items:baseline; gap:6px; }
.hub-subscription-amount strong { font-size:15px; font-weight:850; color:var(--d-ink); font-variant-numeric:tabular-nums; }
.hub-subscription-amount small { font-size:11px; font-weight:700; padding:2px 6px; border-radius:5px; background:var(--d-surface-2); color:var(--d-ink-soft); }

/* ==========================================================================
   HUB DESIGN SYSTEM:DARK THEME INTEGRATION
   ========================================================================== */

/* Hub Audit Ledger Styles */
.hub-audit-card { margin:16px 20px; border:1px solid var(--d-line); border-radius:14px; background:var(--d-surface); overflow:hidden; }
.hub-audit-head { display:flex; align-items:center; justify-content:space-between; flex-wrap:wrap; gap:12px; padding:12px 16px; background:var(--d-surface); border-bottom:1px solid var(--d-line); }
.hub-audit-head>div { display:flex; align-items:center; gap:8px; }
.hub-audit-diff { padding:12px 16px; display:flex; flex-direction:column; gap:8px; }
.hub-diff-item { display:flex; flex-direction:column; gap:4px; font-size:12px; }
.hub-diff-key { font-weight:750; color:var(--d-ink-soft); }
.hub-diff-box { display:grid; grid-template-columns:1fr auto 1fr; align-items:center; gap:10px; font-family:var(--font-mono); }
.hub-diff-box pre { margin:0; padding:8px 10px; border-radius:8px; font-size:11.5px; white-space:pre-wrap; word-break:break-all; }
.hub-diff-before { background:var(--d-surface-2); color:var(--d-danger); border:1px solid color-mix(in srgb, var(--d-danger) 35%, var(--d-line)); }
.hub-diff-after { background:var(--d-surface-2); color:var(--d-primary-strong); border:1px solid color-mix(in srgb, var(--d-primary) 35%, var(--d-line)); }
.hub-diff-arrow { color:var(--d-muted-soft); font-weight:800; }
.hub-audit-foot { display:flex; align-items:center; flex-wrap:wrap; gap:14px; padding:10px 16px; background:var(--d-surface-2); border-top:1px solid var(--d-line); color:var(--d-muted); font-size:11px; }


/* ==========================================================================
   HUB DASHBOARD ENHANCEMENTS
   ========================================================================== */
.hub-dashboard-grid { display:grid; grid-template-columns:minmax(0,1.4fr) minmax(0,1fr); gap:20px; }
.hub-ops-grid { display:grid; grid-template-columns:minmax(0,1.3fr) minmax(0,1fr); gap:20px; }
@media (max-width:1100px) {
  .hub-dashboard-grid, .hub-ops-grid { grid-template-columns:minmax(0,1fr); }
}

.hub-card-body { padding:20px 22px; }

/* Dashboard Trend Chart Inside Hub */
.hub-chart-container { position:relative; height:240px; display:flex; flex-direction:column; justify-content:flex-end; padding:10px 10px 0; }
.hub-chart-guides { position:absolute; inset:10px 10px 30px; display:flex; flex-direction:column; justify-content:space-between; pointer-events:none; }
.hub-chart-line { position:relative; width:100%; border-bottom:1px dashed var(--d-line); }
.hub-chart-line span { position:absolute; right:0; top:-9px; font-size:10px; color:var(--d-muted-soft); font-family:var(--font-latin); }

.hub-chart-bars { position:relative; z-index:2; height:100%; display:grid; grid-template-columns:repeat(6,minmax(0,1fr)); gap:10px; align-items:stretch; }
.hub-chart-col { display:flex; flex-direction:column; align-items:center; justify-content:flex-end; gap:8px; }
.hub-bar-pair { display:flex; align-items:flex-end; justify-content:center; gap:5px; height:100%; width:100%; }
.hub-bar { width:16px; min-height:6px; border-radius:5px 5px 0 0; transition:transform .2s ease, filter .2s ease; cursor:pointer; }
.hub-bar:hover { transform:scaleY(1.06); filter:brightness(1.15); }
.hub-bar-org { background:linear-gradient(180deg, var(--d-primary), var(--d-primary)); }
.hub-bar-sub { background:linear-gradient(180deg, var(--d-primary), var(--d-primary)); }
.hub-bar-col-label { font-size:11px; color:var(--d-muted); font-weight:700; white-space:nowrap; }

.hub-chart-legend { display:flex; align-items:center; gap:16px; margin-bottom:12px; font-size:12px; font-weight:700; color:var(--d-muted); }
.hub-legend-item { display:flex; align-items:center; gap:6px; }
.hub-legend-dot { width:8px; height:8px; border-radius:50%; }
.hub-legend-dot.org { background:var(--d-primary); }
.hub-legend-dot.sub { background:var(--d-primary); }

/* Composite Gauge & Meters */
.hub-composite-gauge { height:12px; width:100%; border-radius:999px; overflow:hidden; display:flex; background:var(--d-surface-2); margin-bottom:18px; }
.hub-gauge-chunk { height:100%; transition:width .3s ease; }

.hub-meter-list { display:flex; flex-direction:column; gap:11px; }
.hub-meter-item { display:flex; align-items:center; justify-content:space-between; gap:12px; text-decoration:none; color:inherit; padding:8px 12px; border-radius:10px; transition:background .15s ease; border:1px solid transparent; }
.hub-meter-item:hover { background:var(--d-surface); border-color:var(--d-line); }

.hub-meter-info { display:flex; align-items:center; gap:8px; width:80px; font-size:13px; font-weight:750; color:var(--d-ink); }
.hub-meter-track { flex:1; height:8px; background:var(--d-surface-2); border-radius:999px; overflow:hidden; }
.hub-meter-fill { height:100%; border-radius:999px; }
.hub-meter-counts { display:flex; align-items:center; gap:8px; width:70px; justify-content:flex-end; font-variant-numeric:tabular-nums; font-size:12px; }
.hub-meter-pct { color:var(--d-muted-soft); }
.hub-meter-num { font-weight:800; color:var(--d-ink); }

/* Attention Priority Cards */
.hub-priority-list { display:flex; flex-direction:column; gap:10px; padding:16px 20px; }
.hub-priority-card { display:flex; align-items:center; justify-content:space-between; gap:14px; padding:12px 14px; border-radius:12px; border:1px solid color-mix(in srgb, var(--d-warn) 35%, var(--d-line)); background:var(--d-surface-2); text-decoration:none; transition:transform .18s ease, box-shadow .18s ease; }
.hub-priority-card:hover { transform:translateY(-1px); box-shadow:0 6px 16px rgba(245,158,11,0.12); }
.hub-priority-card.past_due { border-color:color-mix(in srgb, var(--d-danger) 35%, var(--d-line)); background:var(--d-surface-2); }
.hub-priority-card.past_due:hover { box-shadow:0 6px 16px rgba(239,68,68,0.12); }
.hub-priority-info { display:flex; flex-direction:column; gap:4px; }
.hub-priority-info b { color:var(--d-ink); font-size:14px; font-weight:800; }
.hub-priority-tags { display:flex; align-items:center; gap:6px; }
.hub-priority-btn { padding:6px 12px; border-radius:8px; background:var(--d-surface); border:1px solid rgba(0,0,0,0.1); font-size:12px; font-weight:750; color:var(--d-warn); white-space:nowrap; }
.hub-priority-card.past_due .hub-priority-btn { color:var(--d-danger); }


/* Platform project catalog and subscriber details */
.project-hub { animation:project-hub-enter .42s ease both; }
.project-stat-grid .hub-stat { min-height:116px; }
.project-mark { display:grid; width:43px; height:43px; flex:0 0 43px; place-items:center; border:1px solid var(--d-line); border-radius:13px; background:linear-gradient(145deg,var(--d-surface-2),var(--d-surface-3)); color:var(--d-primary); font-size:18px; font-weight:900; }
.project-key { color:var(--d-muted)!important; font-family:var(--font-latin); font-size:11px!important; }
.project-url-cell { max-width:255px; }
.project-url { display:block; overflow:hidden; max-width:250px; color:var(--d-primary); font-family:var(--font-latin); font-size:12px; text-overflow:ellipsis; text-decoration:none; white-space:nowrap; unicode-bidi:isolate; }
.project-url:hover { color:var(--d-primary); text-decoration:underline; }
.project-url-cell small { display:block; overflow:hidden; max-width:250px; margin-top:4px; color:var(--d-muted); font-family:var(--font-latin); font-size:10px; text-overflow:ellipsis; white-space:nowrap; }
.project-muted { color:var(--d-muted); font-size:12px; }
.project-category { display:inline-flex; padding:6px 9px; border:1px solid var(--d-line); border-radius:9px; background:var(--d-surface-2); color:var(--d-ink-soft); font-size:12px; font-weight:750; white-space:nowrap; }
.project-status { display:inline-flex; align-items:center; gap:7px; padding:7px 10px; border:1px solid var(--d-line); border-radius:999px; background:var(--d-surface-2); color:var(--d-primary); font-size:12px; font-weight:800; white-space:nowrap; }
.project-status i { width:7px; height:7px; border-radius:50%; background:currentColor; }
.project-status-development { border-color:var(--d-line); background:var(--d-surface-2); color:var(--d-primary); }
.project-status-planned { border-color:var(--d-line); background:var(--d-surface-2); color:var(--d-muted); }
.project-status-maintenance { border-color:color-mix(in srgb, var(--d-warn) 35%, var(--d-line)); background:var(--d-surface-2); color:var(--d-warn); }
.project-status-archived { border-color:var(--d-line); background:var(--d-surface-2); color:#8b5cf6; }
.project-count { display:block; color:var(--d-ink); font-size:17px; font-variant-numeric:tabular-nums; }
.project-subtext { display:block; margin-top:2px; color:var(--d-muted); font-size:11px; }
.project-table { min-width:1160px; }
/* Project Form Panel */
.project-form-panel { border:1px solid var(--d-line); border-radius:17px; background:var(--d-surface); box-shadow:0 10px 30px rgba(24,47,81,.05); }
.project-form-panel .form-grid { gap:21px 24px; }
.project-form-panel .form-grid label { gap:8px; font-size:13px; }
.project-form-panel .subline { color:var(--d-muted); font-size:11px; line-height:1.6; }
.project-form-panel textarea { min-height:102px; }
.project-error { color:var(--d-danger)!important; font-size:11px!important; font-weight:700!important; }

/* ========================================================
   EXECUTIVE REDESIGN:PROJECT DETAIL HUB (SHOW VIEW)
   ======================================================== */
.proj-detail-wrap { max-width:1600px; margin-inline:auto; display:flex; flex-direction:column; gap:22px; font-family:'Tajawal','Segoe UI',sans-serif; animation:project-hub-enter .38s cubic-bezier(0.16,1,0.3,1) both; }
.proj-detail-wrap * { box-sizing:border-box; }

@keyframes project-hub-enter { from { opacity:0; transform:translateY(8px); } to { opacity:1; transform:translateY(0); } }
@keyframes proj-pulse { 0%, 100% { opacity:1; transform:scale(1); } 50% { opacity:.55; transform:scale(1.15); } }

/* 1. TOP BREADCRUMB & ACTION BAR */
.proj-top-nav { display:flex; align-items:center; justify-content:space-between; flex-wrap:wrap; gap:14px; padding:2px 4px; }
.proj-breadcrumbs { display:flex; align-items:center; flex-wrap:wrap; gap:8px; font-size:13px; }
.proj-bc-link { display:inline-flex; align-items:center; gap:6px; color:var(--d-muted); text-decoration:none; padding:4px 9px; border-radius:8px; background:transparent; transition:all .18s ease; }
.proj-bc-link:hover { color:var(--d-ink); background:var(--d-surface-2); }
.proj-bc-link svg { width:15px; height:15px; color:var(--d-muted-soft); }
.proj-bc-sep { color:var(--d-sidebar-ink); font-size:12px; }
.proj-bc-current { color:var(--d-ink); font-weight:800; padding:4px 9px; border-radius:8px; background:var(--d-surface-2); border:1px solid var(--d-line); }

.proj-nav-actions { display:flex; align-items:center; gap:10px; }
.proj-action-btn { display:inline-flex; align-items:center; gap:8px; height:38px; padding:0 15px; border-radius:10px; font-size:13px; font-weight:750; text-decoration:none; transition:all .18s ease; cursor:pointer; }
.proj-action-btn svg { width:15px; height:15px; }
.proj-btn-quiet { border:1px solid var(--d-line); background:var(--d-surface); color:var(--d-ink-soft); box-shadow:0 1px 3px rgba(15,23,42,.04); }
.proj-btn-quiet:hover { border-color:var(--d-line); background:var(--d-surface-2); color:var(--d-ink); transform:translateY(-1px); }
.proj-btn-primary { border:1px solid var(--d-primary); background:linear-gradient(135deg,var(--d-primary),var(--d-primary)); color:var(--d-primary-ink); box-shadow:0 4px 12px color-mix(in srgb, var(--d-primary) 22%, transparent); }
.proj-btn-primary:hover { background:linear-gradient(135deg,var(--d-primary),var(--d-primary)); box-shadow:0 6px 16px color-mix(in srgb, var(--d-primary) 30%, transparent); transform:translateY(-1px); color:var(--d-primary-ink); }

/* 2. EXECUTIVE HERO SHOWCASE CARD */
.proj-hero-card { position:relative; overflow:hidden; border-radius:24px; border:1px solid var(--d-primary); background:radial-gradient(ellipse at 85% 15%,color-mix(in srgb, var(--d-primary) 28%, transparent),transparent 42%),radial-gradient(ellipse at 15% 85%,rgba(99,102,241,0.2),transparent 40%),linear-gradient(135deg,var(--d-sidebar-bg) 0%,var(--d-sidebar-bg) 52%,var(--d-sidebar-bg) 100%); color:var(--d-primary-ink); box-shadow:0 20px 48px -10px rgba(9,18,32,.35),0 0 0 1px rgba(255,255,255,.06) inset; padding:32px 36px; }
.proj-hero-bg-glow { position:absolute; inset:-40% 40% -40% -10%; border-radius:50%; background:radial-gradient(circle,color-mix(in srgb, var(--d-primary) 12%, transparent),transparent 70%); pointer-events:none; }
.proj-hero-grid-pattern { position:absolute; inset:0; background-image:linear-gradient(rgba(255,255,255,0.03) 1px,transparent 1px),linear-gradient(90deg,rgba(255,255,255,0.03) 1px,transparent 1px); background-size:28px 28px; pointer-events:none; }

.proj-hero-body { position:relative; z-index:2; display:flex; align-items:center; justify-content:space-between; gap:32px; flex-wrap:wrap; }
.proj-hero-identity { display:flex; align-items:flex-start; gap:22px; min-width:0; flex:1 1 560px; }

.proj-brand-mark { position:relative; width:64px; height:64px; flex:0 0 64px; border-radius:18px; background:linear-gradient(140deg,var(--d-primary),var(--d-primary)); border:1px solid rgba(255,255,255,.25); box-shadow:0 10px 24px -4px color-mix(in srgb, var(--d-primary) 45%, transparent),0 0 0 1px rgba(255,255,255,.15) inset; display:grid; place-items:center; color:var(--d-primary-ink); }
.proj-mark-inner { display:grid; place-items:center; width:100%; height:100%; }
.proj-mark-svg { width:32px; height:32px; }
.proj-mark-pulse { position:absolute; inset:-4px; border-radius:22px; border:2px solid color-mix(in srgb, var(--d-primary) 35%, transparent); pointer-events:none; animation:proj-pulse 3s infinite ease-in-out; }

.proj-identity-info { display:flex; flex-direction:column; gap:10px; min-width:0; }
.proj-title-row { display:flex; align-items:center; flex-wrap:wrap; gap:10px; }
.proj-title { margin:0; font-size:30px; font-weight:850; color:var(--d-primary-ink); letter-spacing:-0.4px; line-height:1.25; }

.proj-status-pill { display:inline-flex; align-items:center; gap:7px; padding:5px 12px; border-radius:999px; font-size:12px; font-weight:800; backdrop-filter:blur(8px); }
.proj-status-dot { width:7px; height:7px; border-radius:50%; background:currentColor; box-shadow:0 0 0 3px rgba(255,255,255,.15); }
.status-active { background:rgba(16,185,129,.18); border:1px solid rgba(16,185,129,.35); color:var(--d-primary); }
.status-active .proj-status-dot { background:var(--d-primary); animation:proj-pulse 2s infinite ease-in-out; }
.status-development { background:color-mix(in srgb, var(--d-primary) 18%, transparent); border:1px solid color-mix(in srgb, var(--d-primary) 35%, transparent); color:var(--d-primary); }
.status-planned { background:rgba(148,163,184,.18); border:1px solid rgba(148,163,184,.35); color:var(--d-sidebar-ink); }
.status-maintenance { background:rgba(245,158,11,.18); border:1px solid rgba(245,158,11,.35); color:var(--d-warn); }
.status-archived { background:rgba(168,85,247,.18); border:1px solid rgba(168,85,247,.35); color:#8b5cf6; }

.proj-tag-pill { display:inline-flex; align-items:center; gap:5px; font-size:11px; font-weight:750; padding:4px 10px; border-radius:999px; backdrop-filter:blur(8px); }
.proj-tag-pill svg { width:12px; height:12px; }
.proj-tag-version { background:rgba(255,255,255,.09); border:1px solid rgba(255,255,255,.14); color:var(--d-sidebar-ink); font-family:var(--font-latin); }
.proj-tag-listed { background:color-mix(in srgb, var(--d-primary) 14%, transparent); border:1px solid color-mix(in srgb, var(--d-primary) 25%, transparent); color:var(--d-primary); }
.proj-tag-hidden { background:rgba(148,163,184,.12); border:1px solid rgba(148,163,184,.25); color:var(--d-muted-soft); }

.proj-description { margin:0; color:var(--d-sidebar-ink); font-size:14.5px; line-height:1.7; max-width:620px; }

.proj-badges-row { display:flex; align-items:center; flex-wrap:wrap; gap:8px; margin-top:3px; }
.proj-chip { display:inline-flex; align-items:center; gap:6px; padding:5px 11px; border-radius:9px; font-size:12px; font-weight:700; background:rgba(255,255,255,.07); border:1px solid rgba(255,255,255,.12); color:var(--d-sidebar-ink); backdrop-filter:blur(8px); }
.proj-chip svg { width:13px; height:13px; }
.proj-chip-category { background:color-mix(in srgb, var(--d-primary) 20%, transparent); border-color:color-mix(in srgb, var(--d-primary) 32%, transparent); color:var(--d-sidebar-ink); font-weight:800; }
.proj-chip-code { font-family:var(--font-latin); color:var(--d-primary-ink); }
.proj-chip-code code { font-family:inherit; color:var(--d-primary); font-weight:800; }
.proj-chip-label { color:var(--d-muted-soft); font-size:11px; font-weight:600; }
.proj-uuid-short { font-family:var(--font-latin); color:var(--d-sidebar-ink); font-size:11px; }
.proj-chip-muted { color:var(--d-muted-soft); font-size:11px; }

.proj-copy-btn { border:0; background:rgba(255,255,255,.1); color:var(--d-primary); width:20px; height:20px; border-radius:5px; display:inline-grid; place-items:center; cursor:pointer; padding:0; margin-inline-start:3px; transition:all .15s ease; }
.proj-copy-btn:hover { background:rgba(255,255,255,.25); color:var(--d-primary-ink); transform:scale(1.1); }
.proj-copy-btn svg { width:11px; height:11px; }

/* Hero Action Box */
.proj-hero-action-box { display:flex; flex-direction:column; gap:10px; min-width:230px; }
.proj-launch-btn { display:flex; align-items:center; gap:12px; padding:13px 18px; border-radius:15px; background:rgba(255,255,255,.12); border:1px solid rgba(255,255,255,.22); color:var(--d-primary-ink); text-decoration:none; backdrop-filter:blur(10px); box-shadow:0 8px 24px rgba(0,0,0,.22); transition:all .2s ease; }
.proj-launch-btn:hover { background:rgba(255,255,255,.2); border-color:rgba(255,255,255,.35); transform:translateY(-2px); color:var(--d-primary-ink); }
.proj-launch-icon { width:38px; height:38px; border-radius:10px; background:var(--d-primary); display:grid; place-items:center; color:var(--d-primary-ink); flex:0 0 38px; }
.proj-launch-icon svg { width:18px; height:18px; }
.proj-launch-text { display:flex; flex-direction:column; gap:2px; min-width:0; }
.proj-launch-text strong { font-size:14px; font-weight:800; color:var(--d-primary-ink); }
.proj-launch-text small { color:var(--d-sidebar-ink); font-size:11px; font-family:var(--font-latin); overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }

.proj-hero-edit-card { display:flex; align-items:center; gap:12px; padding:13px 18px; border-radius:15px; background:rgba(255,255,255,.09); border:1px solid rgba(255,255,255,.18); color:var(--d-primary-ink); text-decoration:none; backdrop-filter:blur(8px); transition:all .2s ease; }
.proj-hero-edit-card:hover { background:rgba(255,255,255,.16); border-color:rgba(255,255,255,.28); transform:translateY(-2px); color:var(--d-primary-ink); }
.proj-hero-edit-icon { width:38px; height:38px; border-radius:10px; background:rgba(255,255,255,.14); display:grid; place-items:center; color:var(--d-sidebar-ink); flex:0 0 38px; }
.proj-hero-edit-icon svg { width:17px; height:17px; }
.proj-hero-edit-info { display:flex; flex-direction:column; gap:2px; flex:1; min-width:0; }
.proj-hero-edit-info strong { font-size:13.5px; font-weight:800; color:var(--d-primary-ink); }
.proj-hero-edit-info small { color:var(--d-sidebar-ink); font-size:11px; }
.proj-arrow-icon { width:15px; height:15px; color:var(--d-muted-soft); transition:transform .2s ease; }
.proj-hero-edit-card:hover .proj-arrow-icon { transform:translateX(-3px); color:var(--d-primary-ink); }

/* 3. EXECUTIVE KPI STATS CARDS */
.proj-kpi-grid { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:15px; }
.proj-kpi-card { display:flex; flex-direction:column; justify-content:space-between; min-height:148px; padding:20px; border-radius:18px; border:1px solid var(--d-line); background:linear-gradient(150deg,var(--d-surface),var(--d-surface)); box-shadow:0 4px 18px rgba(15,23,42,.04); transition:transform .22s cubic-bezier(0.16,1,0.3,1),box-shadow .22s ease,border-color .22s ease; position:relative; overflow:hidden; }
.proj-kpi-card:hover { transform:translateY(-3px); box-shadow:0 12px 28px rgba(15,23,42,.08); border-color:var(--d-line); }

.proj-kpi-top { display:flex; align-items:center; justify-content:space-between; gap:10px; margin-bottom:12px; }
.proj-kpi-icon { width:42px; height:42px; border-radius:12px; display:grid; place-items:center; flex:0 0 42px; }
.proj-kpi-icon svg { width:20px; height:20px; }

.card-blue .proj-kpi-icon { background:var(--d-surface-2); color:var(--d-primary); border:1px solid var(--d-line); }
.card-emerald .proj-kpi-icon { background:var(--d-surface-2); color:var(--d-primary); border:1px solid color-mix(in srgb, var(--d-success) 35%, var(--d-line)); }
.card-purple .proj-kpi-icon { background:var(--d-surface-2); color:#8b5cf6; border:1px solid var(--d-line); }
.card-amber .proj-kpi-icon { background:var(--d-surface-2); color:var(--d-warn); border:1px solid color-mix(in srgb, var(--d-warn) 35%, var(--d-line)); }

.proj-kpi-badge { font-size:11px; font-weight:800; padding:4px 9px; border-radius:999px; }
.badge-blue { background:var(--d-surface-2); color:var(--d-primary); border:1px solid var(--d-line); }
.badge-emerald { background:var(--d-surface-2); color:var(--d-primary-strong); border:1px solid color-mix(in srgb, var(--d-primary) 35%, var(--d-line)); }
.badge-purple { background:var(--d-surface-2); color:#8b5cf6; border:1px solid var(--d-line); }
.badge-amber { background:var(--d-surface-2); color:var(--d-warn); border:1px solid var(--d-warn); }
.badge-slate { background:var(--d-surface-2); color:var(--d-muted); border:1px solid var(--d-line); }

.proj-kpi-body { display:flex; flex-direction:column; gap:3px; }
.proj-kpi-label { font-size:13px; font-weight:750; color:var(--d-muted); }
.proj-kpi-value { font-size:30px; font-weight:900; color:var(--d-ink); line-height:1.2; font-variant-numeric:tabular-nums; letter-spacing:-0.5px; }
.proj-val-compact { font-size:22px; }
.proj-kpi-hint { font-size:11.5px; color:var(--d-muted-soft); margin:2px 0 0; line-height:1.45; }

/* 4. TECHNICAL SPECIFICATIONS & ARCHITECTURE BENTO */
.proj-specs-panel,.proj-subscribers-panel { border-radius:20px; border:1px solid var(--d-line); background:var(--d-surface); box-shadow:0 4px 22px rgba(15,23,42,.035); overflow:hidden; }

.proj-panel-header { padding:20px 24px; border-bottom:1px solid var(--d-line); display:flex; align-items:center; justify-content:space-between; gap:16px; flex-wrap:wrap; }
.proj-header-title { display:flex; align-items:center; gap:14px; }
.proj-section-badge { width:34px; height:34px; border-radius:10px; background:var(--d-surface-2); border:1px solid var(--d-line); color:var(--d-primary); font-weight:850; font-size:13px; display:grid; place-items:center; font-family:var(--font-latin); flex:0 0 34px; }
.proj-header-title h2 { margin:0; color:var(--d-ink); font-size:19px; font-weight:850; }
.proj-header-title p { margin:3px 0 0; color:var(--d-muted); font-size:13px; }

.proj-header-action { display:inline-flex; align-items:center; gap:7px; padding:7px 13px; border-radius:9px; border:1px solid var(--d-line); background:var(--d-surface); color:var(--d-primary); font-size:12.5px; font-weight:750; text-decoration:none; transition:all .18s ease; }
.proj-header-action:hover { border-color:var(--d-primary); background:var(--d-surface-2); color:var(--d-primary); }
.proj-header-action svg { width:14px; height:14px; }

.proj-specs-content { padding:22px 24px; display:flex; flex-direction:column; gap:20px; }

/* Launch URL Highlight Box */
.proj-url-highlight-box { padding:18px 20px; border-radius:16px; background:linear-gradient(145deg,var(--d-surface-2),var(--d-surface-2)); border:1px solid var(--d-line); display:flex; flex-direction:column; gap:12px; }
.proj-url-box-top { display:flex; align-items:center; justify-content:space-between; gap:14px; flex-wrap:wrap; }
.proj-url-meta { display:flex; align-items:center; flex-wrap:wrap; gap:8px; }
.proj-url-type-badge { display:inline-flex; align-items:center; gap:6px; font-size:12.5px; font-weight:800; color:var(--d-ink); }
.proj-url-type-badge svg { width:15px; height:15px; color:var(--d-primary); }
.proj-token-pill { display:inline-flex; align-items:center; gap:5px; padding:3px 9px; border-radius:999px; background:var(--d-surface-2); border:1px solid var(--d-line); color:var(--d-primary); font-size:11px; font-weight:750; }
.proj-token-pill svg { width:12px; height:12px; }

.proj-url-actions { display:flex; align-items:center; gap:8px; }
.proj-btn-copy-url,.proj-btn-launch-url { display:inline-flex; align-items:center; gap:6px; height:34px; padding:0 12px; border-radius:8px; font-size:12.5px; font-weight:750; cursor:pointer; text-decoration:none; transition:all .15s ease; }
.proj-btn-copy-url { border:1px solid var(--d-line); background:var(--d-surface); color:var(--d-ink); }
.proj-btn-copy-url:hover { border-color:var(--d-muted-soft); background:var(--d-surface-2); color:var(--d-ink); }
.proj-btn-copy-url svg,.proj-btn-launch-url svg { width:13px; height:13px; }
.proj-btn-launch-url { border:1px solid var(--d-primary); background:var(--d-primary); color:var(--d-primary-ink); }
.proj-btn-launch-url:hover { background:var(--d-primary); color:var(--d-primary-ink); }

.proj-url-display-bar { border-radius:12px; overflow:hidden; border:1px solid var(--d-ink-soft); }
.proj-code-url { display:block; padding:12px 16px; background:var(--d-sidebar-bg); color:var(--d-primary); font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace; font-size:13.5px; word-break:break-all; }
.proj-url-empty { display:block; padding:12px 16px; background:var(--d-surface-2); color:var(--d-muted-soft); font-size:13px; }

.proj-url-note { display:flex; align-items:flex-start; gap:8px; color:var(--d-muted); font-size:12px; line-height:1.6; }
.proj-url-note svg { width:15px; height:15px; color:var(--d-primary); flex:0 0 15px; margin-top:2px; }
.proj-url-note code { font-family:var(--font-latin); color:var(--d-primary); font-weight:800; background:var(--d-surface-2); padding:1px 5px; border-radius:4px; }

/* Specs Grid (6 Bento Parameters) */
.proj-params-grid { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:12px; }
.proj-param-card { padding:14px 16px; border-radius:13px; border:1px solid var(--d-line); background:var(--d-surface); display:flex; flex-direction:column; gap:6px; transition:border-color .15s ease; }
.proj-param-card:hover { border-color:var(--d-line); }
.proj-param-header { display:flex; align-items:center; gap:6px; color:var(--d-muted); font-size:12px; font-weight:700; }
.proj-param-header svg { width:14px; height:14px; color:var(--d-muted-soft); }
.proj-param-body { display:flex; align-items:center; justify-content:space-between; gap:8px; min-width:0; }
.proj-param-text { color:var(--d-ink); font-size:13.5px; font-weight:800; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.proj-param-code { font-family:var(--font-latin); color:var(--d-primary); font-size:13px; font-weight:800; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.proj-param-date { color:var(--d-ink); font-size:12.5px; font-weight:750; font-family:var(--font-latin); }

.proj-micro-copy { border:0; background:var(--d-surface-2); color:var(--d-muted); width:22px; height:22px; border-radius:6px; display:inline-grid; place-items:center; cursor:pointer; padding:0; flex:0 0 22px; transition:all .15s ease; }
.proj-micro-copy:hover { background:var(--d-surface-3); color:var(--d-ink); transform:scale(1.1); }
.proj-micro-copy svg { width:11px; height:11px; }

/* Features Section */
.proj-features-section { padding-top:16px; border-top:1px solid var(--d-line); display:flex; flex-direction:column; gap:10px; }
.proj-features-title { display:flex; align-items:center; gap:7px; color:var(--d-ink); font-size:13px; }
.proj-features-title svg { width:15px; height:15px; color:var(--d-warn); }
.proj-features-pills { display:flex; flex-wrap:wrap; gap:8px; }
.proj-feature-chip { display:inline-flex; align-items:center; gap:6px; padding:6px 12px; border-radius:999px; background:var(--d-surface-2); border:1px solid color-mix(in srgb, var(--d-primary) 35%, var(--d-line)); color:var(--d-primary-strong); font-size:12px; font-weight:800; transition:transform .15s ease; }
.proj-feature-chip:hover { transform:translateY(-1px); }
.proj-feature-chip svg { width:12px; height:12px; stroke-width:3; }

/* 5. SUBSCRIBERS DIRECTORY */
.proj-counter-pill { display:inline-flex; align-items:center; gap:6px; padding:6px 12px; border-radius:999px; background:var(--d-surface-2); color:var(--d-ink-soft); font-size:12.5px; }
.proj-counter-pill strong { color:var(--d-ink); font-size:14px; font-weight:850; }

.proj-filter-bar { padding:16px 24px; border-bottom:1px solid var(--d-line); display:grid; grid-template-columns:minmax(220px,1.8fr) minmax(150px,.8fr) minmax(140px,.75fr) auto; gap:12px; align-items:flex-end; background:var(--d-surface-2); }
.proj-filter-field { display:flex; flex-direction:column; gap:6px; min-width:0; }
.proj-filter-field label { color:var(--d-ink-soft); font-size:12px; font-weight:750; }
.proj-input-with-icon { position:relative; display:flex; align-items:center; }
.proj-input-with-icon svg { position:absolute; inset-inline-start:12px; width:16px; height:16px; color:var(--d-muted-soft); pointer-events:none; }
.proj-filter-field input, .proj-filter-field select { box-sizing:border-box; width:100%; height:42px; border:1px solid var(--d-line); border-radius:10px; background:var(--d-surface); color:var(--d-ink); font-family:'Tajawal','Segoe UI',sans-serif; font-size:13.5px; padding:0 12px; outline:0; transition:border-color .15s ease,box-shadow .15s ease; }
.proj-filter-field input::placeholder { color:var(--d-muted-soft); }
.proj-filter-search input { padding-inline-start:38px; }
.proj-filter-field input:focus, .proj-filter-field select:focus { border-color:var(--d-primary); box-shadow:0 0 0 3px color-mix(in srgb, var(--d-primary) 15%, transparent); }

.proj-filter-actions { display:flex; align-items:center; gap:8px; }
.proj-btn-filter-submit { display:inline-flex; align-items:center; gap:7px; height:42px; padding:0 18px; border:0; border-radius:10px; background:linear-gradient(135deg,var(--d-primary),var(--d-primary)); color:var(--d-primary-ink); font-family:inherit; font-size:13.5px; font-weight:800; cursor:pointer; box-shadow:0 3px 10px color-mix(in srgb, var(--d-primary) 20%, transparent); transition:all .18s ease; }
.proj-btn-filter-submit:hover { transform:translateY(-1px); box-shadow:0 6px 14px color-mix(in srgb, var(--d-primary) 30%, transparent); }
.proj-btn-filter-submit svg { width:15px; height:15px; }
.proj-btn-filter-clear { display:inline-flex; align-items:center; gap:5px; height:42px; padding:0 12px; border:1px solid color-mix(in srgb, var(--d-danger) 35%, var(--d-line)); border-radius:10px; background:var(--d-surface); color:var(--d-danger); font-size:12.5px; font-weight:750; text-decoration:none; transition:all .15s ease; }
.proj-btn-filter-clear:hover { background:var(--d-surface-2); }
.proj-btn-filter-clear svg { width:13px; height:13px; }

/* Table */
.proj-table-wrap { overflow-x:auto; }
.proj-subscribers-table { width:100%; min-width:980px; border-collapse:separate; border-spacing:0; text-align:right; }
.proj-subscribers-table th { padding:14px 18px; border-bottom:1px solid var(--d-line); background:var(--d-surface-2); color:var(--d-ink-soft); font-size:12.5px; font-weight:850; white-space:nowrap; }
.proj-subscribers-table td { padding:14px 18px; border-bottom:1px solid var(--d-line); color:var(--d-ink); font-size:13px; vertical-align:middle; transition:background .15s ease; }
.proj-subscribers-table tbody tr:hover td { background:var(--d-surface-2); }
.proj-subscribers-table tbody tr:last-child td { border-bottom:0; }

.proj-org-cell { display:flex; align-items:center; gap:12px; min-width:180px; }
.proj-org-avatar { width:40px; height:40px; border-radius:11px; background:linear-gradient(140deg,var(--d-surface-2),var(--d-surface-3)); border:1px solid var(--d-line); color:var(--d-primary); font-size:16px; font-weight:900; display:grid; place-items:center; flex:0 0 40px; }
.proj-org-info { display:flex; flex-direction:column; gap:2px; min-width:0; }
.proj-org-name { color:var(--d-ink); font-size:14px; font-weight:800; text-decoration:none; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.proj-org-name:hover { color:var(--d-primary); }
.proj-org-sub { color:var(--d-muted); font-size:11.5px; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }

.proj-domain-chip { display:inline-flex; align-items:center; gap:6px; padding:4px 10px; border-radius:8px; background:var(--d-surface-2); border:1px solid var(--d-line); color:var(--d-ink); font-size:12px; font-family:var(--font-latin); }
.proj-domain-chip svg { width:12px; height:12px; color:var(--d-muted); }
.proj-muted-badge { color:var(--d-muted-soft); font-size:12px; }

.proj-service-link { display:inline-flex; align-items:center; gap:6px; padding:5px 11px; border-radius:8px; background:var(--d-surface-2); border:1px solid var(--d-line); color:var(--d-primary); font-size:12px; font-weight:750; text-decoration:none; transition:all .15s ease; }
.proj-service-link:hover { background:var(--d-surface-3); color:var(--d-primary); transform:translateY(-1px); }
.proj-service-link svg { width:12px; height:12px; }

.proj-members-badge { display:inline-flex; align-items:center; gap:6px; color:var(--d-ink-soft); font-size:13px; font-variant-numeric:tabular-nums; }
.proj-members-badge svg { width:14px; height:14px; color:var(--d-muted-soft); }
.proj-members-badge strong { color:var(--d-ink); font-weight:850; font-size:14px; }

.proj-org-status { display:inline-flex; align-items:center; gap:6px; padding:4px 10px; border-radius:999px; font-size:11.5px; font-weight:800; }
.proj-org-status i { width:6px; height:6px; border-radius:50%; background:currentColor; }
.proj-org-status.status-active { background:var(--d-surface-2); border:1px solid color-mix(in srgb, var(--d-primary) 35%, var(--d-line)); color:var(--d-primary-strong); }
.proj-org-status.status-trial { background:var(--d-surface-2); border:1px solid var(--d-warn); color:var(--d-warn); }
.proj-org-status.status-suspended { background:var(--d-surface-2); border:1px solid color-mix(in srgb, var(--d-danger) 35%, var(--d-line)); color:var(--d-danger); }

.proj-date-text { color:var(--d-muted); font-size:12px; font-family:var(--font-latin); }

.proj-col-action { text-align:center; width:64px; }
.proj-btn-view-org { width:32px; height:32px; border-radius:8px; border:1px solid var(--d-line); background:var(--d-surface); color:var(--d-muted); display:inline-grid; place-items:center; text-decoration:none; transition:all .15s ease; }
.proj-btn-view-org:hover { border-color:var(--d-line); background:var(--d-surface-2); color:var(--d-primary); transform:scale(1.08); }
.proj-btn-view-org svg { width:15px; height:15px; }

/* Pagination */
.proj-pagination-bar { padding:14px 22px; border-top:1px solid var(--d-line); display:flex; align-items:center; justify-content:space-between; gap:16px; flex-wrap:wrap; }
.proj-pagination-summary { color:var(--d-muted); font-size:12.5px; }
.proj-pagination-summary b { color:var(--d-ink); font-weight:800; }

/* Empty State */
.proj-empty-state { padding:56px 24px; text-align:center; display:flex; flex-direction:column; align-items:center; gap:10px; max-width:560px; margin:0 auto; }
.proj-empty-illustration { position:relative; width:84px; height:84px; margin-bottom:4px; display:grid; place-items:center; }
.proj-empty-glow { position:absolute; inset:-12px; border-radius:50%; background:radial-gradient(circle,color-mix(in srgb, var(--d-primary) 15%, transparent),transparent 70%); }
.proj-empty-icon { width:64px; height:64px; color:var(--d-primary); position:relative; z-index:1; }
.proj-empty-state h3 { margin:0; font-size:19px; font-weight:850; color:var(--d-ink); }
.proj-empty-state p { margin:0; color:var(--d-muted); font-size:13.5px; line-height:1.7; }
.proj-empty-state code { font-family:var(--font-latin); color:var(--d-primary); background:var(--d-surface-2); padding:2px 7px; border-radius:6px; font-weight:800; }
.proj-empty-cta { display:inline-flex; align-items:center; gap:9px; margin-top:8px; padding:10px 18px; border-radius:11px; background:var(--d-surface-2); border:1px solid var(--d-line); color:var(--d-primary); font-size:13.5px; font-weight:800; text-decoration:none; transition:all .18s ease; }
.proj-empty-cta:hover { background:var(--d-surface-3); transform:translateY(-1px); }
.proj-empty-cta svg { width:15px; height:15px; }

/* Mini Toast Feedback */
.proj-copy-toast { position:fixed; bottom:26px; left:50%; transform:translateX(-50%) translateY(20px); padding:10px 20px; border-radius:11px; background:var(--d-sidebar-bg); border:1px solid var(--d-ink-soft); color:var(--d-primary-ink); font-size:13px; font-weight:800; box-shadow:0 12px 28px rgba(0,0,0,.35); z-index:99999; pointer-events:none; opacity:0; transition:all .22s cubic-bezier(0.16,1,0.3,1); }
.proj-copy-toast.is-active { transform:translateX(-50%) translateY(0); opacity:1; }

/* ========================================================
   DARK THEME SYSTEM OVERRIDES
   ======================================================== */

















/* Responsive Adjustments */
@media (max-width:1150px) {
  .proj-kpi-grid { grid-template-columns:repeat(2,minmax(0,1fr)); }
  .proj-params-grid { grid-template-columns:repeat(2,minmax(0,1fr)); }
  .proj-filter-bar { grid-template-columns:repeat(2,minmax(0,1fr)); }
}
@media (max-width:768px) {
  .proj-hero-card { padding:22px 20px; border-radius:18px; }
  .proj-hero-identity { flex-direction:column; gap:16px; }
  .proj-hero-action-box { width:100%; }
  .proj-kpi-grid { grid-template-columns:1fr; }
  .proj-params-grid { grid-template-columns:1fr; }
  .proj-filter-bar { grid-template-columns:1fr; padding:14px; }
  .proj-top-nav { flex-direction:column; align-items:flex-start; }
  .proj-nav-actions { width:100%; justify-content:flex-start; }
}
@media (prefers-reduced-motion:reduce) {
  .proj-detail-wrap, .proj-kpi-card, .proj-brand-mark, .proj-status-dot { animation:none!important; transition:none!important; }
}

/* ==========================================================================
   ORGANIZATION PROFILE HUB & EXECUTIVE SHOWCASE
   ========================================================================== */
.org-profile-hub {
  display:flex;
  flex-direction:column;
  gap:24px;
}

/* Organization Hero Showcase Avatar */
.org-hero-avatar-box {
  position:relative;
  width:68px;
  height:68px;
  border-radius:18px;
  background:linear-gradient(135deg, var(--d-primary), var(--d-primary));
  display:flex;
  align-items:center;
  justify-content:center;
  box-shadow: 0 10px 25px -5px color-mix(in srgb, var(--d-primary) 35%, transparent);
  flex-shrink:0;
}

.org-hero-initial {
  font-family:var(--font-arabic), var(--font-sans);
  font-size:30px;
  font-weight:850;
  color:var(--d-primary-ink);
  line-height:1;
}

.org-avatar-ring {
  position:absolute;
  inset:-3px;
  border-radius:21px;
  border:2px solid color-mix(in srgb, var(--d-primary) 30%, transparent);
  pointer-events:none;
}

.org-hero-slug {
  font-family:var(--font-mono);
  color:var(--primary);
  font-weight:700;
  background:var(--primary-light, color-mix(in srgb, var(--d-primary) 8%, transparent));
  padding:2px 8px;
  border-radius:6px;
  border:1px solid color-mix(in srgb, var(--d-primary) 15%, transparent);
}

/* Micro Sub-Pills */
.org-sub-pill {
  display:inline-flex;
  align-items:center;
  gap:4px;
  padding:2px 8px;
  border-radius:6px;
  font-size:11px;
  font-weight:700;
  white-space:nowrap;
}

.org-sub-pill.is-green {
  background:rgba(16, 185, 129, 0.12);
  color:var(--d-primary);
  border:1px solid rgba(16, 185, 129, 0.25);
}

.org-sub-pill.is-gray {
  background:var(--surface-alt, var(--d-surface-2));
  color:var(--text-muted, var(--d-muted));
  border:1px solid var(--border-light, var(--d-line));
}

.org-sub-pill.is-amber {
  background:rgba(245, 158, 11, 0.12);
  color:var(--d-warn);
  border:1px solid rgba(245, 158, 11, 0.25);
}

/* Internal Notes Callout */
.org-notes-callout {
  margin-top:18px;
  padding:16px 20px;
  border-radius:12px;
  background:linear-gradient(135deg, rgba(245, 158, 11, 0.08), rgba(245, 158, 11, 0.03));
  border:1px solid rgba(245, 158, 11, 0.25);
  display:flex;
  flex-direction:column;
  gap:8px;
}

.org-notes-head {
  display:flex;
  align-items:center;
  gap:8px;
  color:var(--d-warn);
  font-size:13px;
  font-weight:800;
}

.org-notes-head svg {
  width:16px;
  height:16px;
  flex-shrink:0;
}

.org-notes-callout p {
  margin:0;
  color:var(--text-body);
  font-size:13px;
  line-height:1.6;
}

/* ==========================================================================
   TAB NAVIGATION SYSTEM
   ========================================================================== */
.org-tabs-container {
  width:100%;
  border-bottom:1px solid var(--border);
  margin-bottom:4px;
}

.org-tabs-nav {
  display:flex;
  align-items:center;
  gap:6px;
  overflow-x:auto;
  scrollbar-width:none;
  padding-bottom:2px;
}

.org-tabs-nav::-webkit-scrollbar {
  display:none;
}

.org-tab-btn {
  display:inline-flex;
  align-items:center;
  gap:8px;
  padding:12px 18px;
  background:transparent;
  border:none;
  border-bottom:2px solid transparent;
  color:var(--text-muted);
  font-size:13.5px;
  font-weight:700;
  cursor:pointer;
  white-space:nowrap;
  transition:all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  border-radius:8px 8px 0 0;
  margin-bottom:-1px;
}

.org-tab-btn svg {
  width:18px;
  height:18px;
  opacity:0.7;
  transition:transform 0.2s ease, opacity 0.2s ease;
}

.org-tab-btn:hover {
  color:var(--text-main);
  background:var(--surface-hover);
}

.org-tab-btn:hover svg {
  opacity:1;
  transform:translateY(-1px);
}

.org-tab-btn.is-active {
  color:var(--primary);
  border-bottom-color:var(--primary);
  background:var(--primary-light, color-mix(in srgb, var(--d-primary) 5%, transparent));
  font-weight:850;
}

.org-tab-btn.is-active svg {
  opacity:1;
  color:var(--primary);
}

.org-tab-count {
  font-family:var(--font-latin);
  font-size:11px;
  font-weight:800;
  padding:2px 7px;
  border-radius:var(--radius-full);
  background:var(--surface-alt);
  color:var(--text-muted);
  border:1px solid var(--border-light);
  line-height:1.2;
}

.org-tab-btn.is-active .org-tab-count {
  background:var(--primary);
  color:var(--d-primary-ink);
  border-color:var(--primary);
}

/* Tab Panes */
.org-tab-pane {
  display:none;
}

.org-tab-pane.is-active {
  display:block;
  animation:orgTabFadeIn 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes orgTabFadeIn {
  from {
    opacity:0;
    transform:translateY(6px);
  }
  to {
    opacity:1;
    transform:translateY(0);
  }
}

/* ==========================================================================
   OPERATIONAL VOLUMES GRID (8 CARDS)
   ========================================================================== */
.org-volumes-grid {
  display:grid;
  grid-template-columns:repeat(4, minmax(0, 1fr));
  gap:14px;
}

.org-volume-card {
  display:flex;
  align-items:center;
  gap:14px;
  padding:16px 18px;
  border-radius:14px;
  background:var(--surface-alt);
  border:1px solid var(--border-light);
  transition:all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.org-volume-card:hover {
  background:var(--surface);
  border-color:var(--border-hover);
  transform:translateY(-2px);
  box-shadow: 0 6px 16px -2px rgba(15, 23, 42, 0.06);
}

.org-volume-icon {
  width:44px;
  height:44px;
  border-radius:12px;
  background:var(--surface);
  border:1px solid var(--border-light);
  display:flex;
  align-items:center;
  justify-content:center;
  color:var(--primary);
  flex-shrink:0;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}

.org-volume-icon svg {
  width:20px;
  height:20px;
}

.org-volume-info {
  display:flex;
  flex-direction:column;
  min-width:0;
}

.org-volume-num {
  font-family:var(--font-latin), var(--font-arabic);
  font-size:20px;
  font-weight:850;
  color:var(--text-main);
  line-height:1.2;
}

.org-volume-title {
  font-size:12px;
  font-weight:700;
  color:var(--text-muted);
  margin-top:2px;
  white-space:nowrap;
}

/* ==========================================================================
   MEMBERS & PERMISSIONS HELPERS
   ========================================================================== */
.org-roles-wrap {
  display:flex;
  flex-direction:column;
  gap:3px;
}

.org-role-tag {
  font-weight:800;
  color:var(--text-main);
  font-size:12.5px;
}

.org-perm-sub {
  font-family:var(--font-mono);
  font-size:11px;
  color:var(--text-muted);
  line-height:1.4;
}

.org-verify-badge {
  display:inline-flex;
  align-items:center;
  padding:3px 8px;
  border-radius:6px;
  font-size:11px;
  font-weight:750;
}

.org-verify-badge.is-verified {
  background:rgba(16, 185, 129, 0.12);
  color:var(--d-primary);
  border:1px solid rgba(16, 185, 129, 0.25);
}

.org-verify-badge.is-unverified {
  background:rgba(100, 116, 139, 0.1);
  color:var(--d-muted);
  border:1px solid rgba(100, 116, 139, 0.2);
}

/* ==========================================================================
   MODULES & INFRASTRUCTURE BENTO SPLIT
   ========================================================================== */
.org-bento-split {
  display:grid;
  grid-template-columns:repeat(2, minmax(0, 1fr));
  gap:20px;
}

.org-chips-cloud {
  display:flex;
  flex-wrap:wrap;
  gap:10px;
}

.org-module-chip {
  display:inline-flex;
  align-items:center;
  gap:10px;
  padding:10px 14px;
  border-radius:10px;
  background:var(--surface-alt);
  border:1px solid var(--border-light);
  transition:all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.org-module-chip:hover {
  background:var(--surface);
  border-color:var(--primary);
  transform:translateY(-1px);
}

.org-module-chip svg {
  width:16px;
  height:16px;
  color:var(--d-primary);
  flex-shrink:0;
}

.org-module-chip strong {
  display:block;
  font-size:12.5px;
  font-weight:800;
  color:var(--text-main);
}

.org-module-chip small {
  display:block;
  font-size:10.5px;
  color:var(--text-muted);
  font-family:var(--font-mono);
}

.org-domains-list {
  display:flex;
  flex-direction:column;
  gap:10px;
}

.org-domain-item {
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  padding:12px 16px;
  border-radius:10px;
  background:var(--surface-alt);
  border:1px solid var(--border-light);
  transition:var(--transition);
}

.org-domain-item:hover {
  background:var(--surface);
  border-color:var(--border-hover);
}

.org-domain-meta {
  display:flex;
  align-items:center;
  gap:10px;
}

.org-domain-meta svg {
  width:18px;
  height:18px;
  color:var(--primary);
  flex-shrink:0;
}

.org-domain-meta strong {
  font-family:var(--font-mono);
  font-size:13px;
  color:var(--text-main);
}

.org-domain-badges {
  display:flex;
  align-items:center;
  gap:6px;
}

.org-sub-empty {
  padding:24px;
  text-align:center;
  color:var(--text-muted);
  font-size:13px;
  background:var(--surface-alt);
  border-radius:10px;
  border:1px dashed var(--border);
}

/* ==========================================================================
   DARK MODE OVERRIDES FOR ORGANIZATION
   ========================================================================== */





























/* Responsive adjustments */
.org-workspace-access-grid { padding:20px 24px 12px; display:grid; grid-template-columns:repeat(auto-fit,minmax(220px,1fr)); gap:12px; }
.org-workspace-access-item { min-width:0; display:flex; flex-direction:column; align-items:flex-start; gap:8px; padding:16px; border:1px solid var(--d-line); border-radius:14px; background:linear-gradient(145deg,var(--d-surface-2),var(--d-surface)); }
.org-workspace-access-item > span { color:var(--d-muted); font-size:12px; font-weight:750; }
.org-workspace-access-item > strong,.org-workspace-access-item > a { max-width:100%; color:var(--d-ink); font-size:14px; font-weight:800; overflow-wrap:anywhere; }
.org-workspace-access-item > a { color:var(--d-primary-strong); }
.org-workspace-access-item > small { color:var(--d-muted); font-size:11px; line-height:1.7; }
.org-workspace-access-item .proj-copy-btn { width:auto; min-height:28px; padding:0 9px; background:var(--d-surface-2); color:var(--d-primary-strong); border:1px solid color-mix(in srgb, var(--d-success) 35%, var(--d-line)); font:inherit; font-size:11px; font-weight:750; }
.org-workspace-security-note { margin:0 24px 20px; padding:11px 14px; border-radius:10px; background:var(--d-surface-2); color:var(--d-primary); font-size:12px; line-height:1.8; }
.org-workspace-onboarding { margin-top:20px; padding:22px 24px; display:flex; align-items:center; justify-content:space-between; gap:20px; flex-wrap:wrap; border:1px solid var(--d-line); border-radius:18px; background:linear-gradient(120deg,var(--d-surface-2),var(--d-surface-2) 60%,var(--d-surface-2)); }
.org-workspace-onboarding h2 { margin:5px 0; color:var(--d-ink); font-size:18px; }
.org-workspace-onboarding p { max-width:660px; margin:0 0 10px; color:var(--d-ink-soft); font-size:13px; line-height:1.8; }
.org-workspace-onboarding strong { color:var(--d-primary-strong); font-family:ui-monospace,SFMono-Regular,Menlo,monospace; letter-spacing:.08em; }
.org-workspace-step { color:var(--d-primary); font-size:11px; font-weight:800; }

@media (max-width:1024px) {
  .org-volumes-grid {
    grid-template-columns:repeat(2, minmax(0, 1fr));
  }
  .org-bento-split {
    grid-template-columns:1fr;
  }
}

@media (max-width:640px) {
  .org-volumes-grid {
    grid-template-columns:1fr;
  }
  .org-tabs-nav {
    gap:4px;
  }
  .org-tab-btn {
    padding:10px 12px;
    font-size:12.5px;
  }
}

/* ==========================================================================
   LOGISTICS PROVIDER SETUP & PROVISIONING STYLES
   ========================================================================== */
.logistics-setup-hub {
  display:flex;
  flex-direction:column;
  gap:22px;
}

.logistics-hero-card {
  margin-bottom:0;
}

.logistics-avatar-glow {
  background:linear-gradient(135deg, var(--d-primary), var(--d-primary));
  box-shadow: 0 10px 25px -5px rgba(2, 132, 199, 0.4);
}

/* ==========================================
   ALREADY CONFIGURED (PROVISIONED) STYLES
   ========================================== */
.logistics-configured-wrap {
  display:flex;
  flex-direction:column;
  gap:20px;
}

.logistics-success-banner {
  display:flex;
  align-items:center;
  gap:16px;
  padding:18px 24px;
  border-radius:var(--radius-xl);
  background:linear-gradient(135deg, rgba(16, 185, 129, 0.12), rgba(16, 185, 129, 0.04));
  border:1px solid rgba(16, 185, 129, 0.28);
}

.logistics-banner-icon {
  width:44px;
  height:44px;
  border-radius:12px;
  background:var(--d-primary);
  color:var(--d-primary-ink);
  display:flex;
  align-items:center;
  justify-content:center;
  flex-shrink:0;
  box-shadow: 0 4px 12px rgba(16, 185, 129, 0.35);
}

.logistics-banner-icon svg {
  width:22px;
  height:22px;
}

.logistics-banner-text h3 {
  margin:0 0 3px;
  font-size:16px;
  font-weight:850;
  color:var(--d-primary-strong);
}

.logistics-banner-text p {
  margin:0;
  font-size:12.5px;
  color:var(--d-primary-strong);
  line-height:1.5;
}

.logistics-bento-grid {
  display:grid;
  grid-template-columns:repeat(4, minmax(0, 1fr));
  gap:16px;
}

.logistics-info-card {
  display:flex;
  flex-direction:column;
  gap:6px;
  padding:18px 20px;
  border-radius:var(--radius-xl);
  background:var(--surface);
  border:1px solid var(--border);
  box-shadow: var(--shadow-card);
}

.logistics-info-label {
  font-size:11.5px;
  font-weight:750;
  color:var(--text-muted);
}

.logistics-info-val {
  font-size:16px;
  font-weight:850;
  color:var(--text-main);
  line-height:1.3;
}

.logistics-info-sub {
  font-size:11px;
  color:var(--text-subtle);
  margin-top:auto;
}

/* Access & Workspace Credentials Panel */
.logistics-access-panel {
  margin-top:4px;
}

.logistics-credentials-grid {
  display:grid;
  grid-template-columns:repeat(2, minmax(0, 1fr));
  gap:20px;
  margin-bottom:20px;
}

.logistics-credential-box {
  display:flex;
  flex-direction:column;
  gap:14px;
  padding:20px 22px;
  border-radius:14px;
  background:var(--surface-alt);
  border:1px solid var(--border-light);
}

.logistics-cred-header {
  display:flex;
  align-items:center;
  gap:12px;
}

.logistics-cred-icon {
  width:38px;
  height:38px;
  border-radius:10px;
  background:var(--primary-light, color-mix(in srgb, var(--d-primary) 10%, transparent));
  color:var(--primary);
  display:flex;
  align-items:center;
  justify-content:center;
  flex-shrink:0;
}

.logistics-cred-icon.icon-purple {
  background:rgba(147, 51, 234, 0.1);
  color:#8b5cf6;
}

.logistics-cred-icon svg {
  width:18px;
  height:18px;
}

.logistics-cred-header strong {
  display:block;
  font-size:13px;
  font-weight:800;
  color:var(--text-main);
}

.logistics-cred-header small {
  display:block;
  font-size:11px;
  color:var(--text-muted);
  margin-top:1px;
}

.logistics-cred-input-wrap {
  display:flex;
  align-items:center;
  gap:8px;
}

.logistics-cred-input {
  flex:1;
  height:40px;
  padding:0 14px;
  border-radius:8px;
  border:1px solid var(--border);
  background:var(--surface);
  color:var(--text-main);
  font-size:13px;
  font-weight:600;
  outline:none;
}

.logistics-cred-input.code-font {
  font-family:var(--font-mono);
  font-weight:800;
  letter-spacing:0.05em;
  font-size:15px;
  color:var(--primary);
}

.logistics-how-it-works {
  padding:18px 22px;
  border-radius:12px;
  background:linear-gradient(135deg, color-mix(in srgb, var(--d-primary) 6%, transparent), color-mix(in srgb, var(--d-primary) 2%, transparent));
  border:1px solid color-mix(in srgb, var(--d-primary) 20%, transparent);
  display:flex;
  flex-direction:column;
  gap:10px;
}

.how-head {
  display:flex;
  align-items:center;
  gap:8px;
  color:var(--primary);
  font-size:13px;
  font-weight:800;
}

.how-head svg {
  width:18px;
  height:18px;
  flex-shrink:0;
}

.how-steps {
  margin:0;
  padding-right:22px;
  padding-left:0;
  color:var(--text-body);
  font-size:12.5px;
  line-height:1.8;
}

.how-steps li strong {
  color:var(--text-main);
}

/* ==========================================
   PROVISIONING FORM & SIDEBAR (BENTO LAYOUT)
   ========================================== */
.logistics-setup-grid {
  display:grid;
  grid-template-columns:minmax(0, 1.55fr) minmax(320px, 0.95fr);
  gap:22px;
  align-items:start;
}

.logistics-form {
  display:flex;
  flex-direction:column;
  gap:20px;
}

/* Notice Card */
.logistics-notice-card {
  display:flex;
  align-items:center;
  gap:14px;
  padding:16px 20px;
  border-radius:var(--radius-xl);
  background:linear-gradient(135deg, rgba(2, 132, 199, 0.1), rgba(2, 132, 199, 0.03));
  border:1px solid rgba(2, 132, 199, 0.25);
}

.logistics-notice-icon {
  width:40px;
  height:40px;
  border-radius:10px;
  background:var(--d-primary);
  color:var(--d-primary-ink);
  display:flex;
  align-items:center;
  justify-content:center;
  flex-shrink:0;
}

.logistics-notice-icon svg {
  width:20px;
  height:20px;
}

.logistics-notice-content strong {
  display:block;
  font-size:13.5px;
  font-weight:850;
  color:var(--d-ink-soft);
}

.logistics-notice-content p {
  margin:2px 0 0;
  font-size:12px;
  color:var(--text-body);
  line-height:1.5;
}

/* Card Sections */
.logistics-card-section {
  border-radius:var(--radius-xl);
  overflow:hidden;
}

.logistics-form-fields {
  display:grid;
  grid-template-columns:repeat(2, minmax(0, 1fr));
  gap:18px 22px;
}

.logistics-field {
  display:flex;
  flex-direction:column;
  gap:8px;
}

.logistics-field.col-full {
  grid-column:1 / -1;
}

.logistics-field label {
  display:flex;
  flex-direction:column;
  gap:4px;
  font-size:12.5px;
  font-weight:750;
  color:var(--text-main);
}

.req-star {
  color:var(--d-danger);
  margin-right:2px;
}

.logistics-field .subline {
  font-size:11px;
  font-weight:500;
  color:var(--text-muted);
}

.logistics-input-wrap {
  position:relative;
  display:flex;
  align-items:center;
  width:100%;
}

.logistics-input-icon {
  position:absolute;
  right:14px;
  display:flex;
  align-items:center;
  justify-content:center;
  color:var(--text-muted);
  pointer-events:none;
  z-index:2;
}

.logistics-input-icon svg {
  width:18px;
  height:18px;
}

.logistics-input-wrap input,
.logistics-input-wrap select {
  width:100%;
  height:44px;
  padding:0 44px 0 16px;
  border-radius:10px;
  border:1px solid var(--border);
  background:var(--surface);
  color:var(--text-main);
  font-family:var(--font-arabic);
  font-size:13px;
  font-weight:500;
  transition:all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  outline:none;
}

.logistics-input-wrap input:hover,
.logistics-input-wrap select:hover {
  border-color:var(--border-hover);
}

.logistics-input-wrap input:focus,
.logistics-input-wrap select:focus {
  border-color:var(--primary);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--d-primary) 15%, transparent);
  background:var(--surface);
}

.logistics-input-wrap input.is-invalid,
.logistics-input-wrap select.is-invalid {
  border-color:var(--d-danger);
  background:rgba(239, 68, 68, 0.03);
}

.logistics-toggle-pwd {
  position:absolute;
  left:12px;
  background:transparent;
  border:none;
  color:var(--text-muted);
  cursor:pointer;
  display:flex;
  align-items:center;
  justify-content:center;
  padding:4px;
  border-radius:6px;
  transition:color 0.15s ease;
  z-index:2;
}

.logistics-toggle-pwd:hover {
  color:var(--primary);
}

.logistics-toggle-pwd svg {
  width:18px;
  height:18px;
}

.logistics-field-error {
  font-size:11.5px;
  font-weight:600;
  color:var(--d-danger);
  margin-top:2px;
}

/* Form Actions */
.logistics-form-actions {
  display:flex;
  align-items:center;
  gap:12px;
  padding-top:6px;
}

.logistics-submit-btn {
  height:46px;
  padding:0 24px;
  font-size:13.5px;
  font-weight:800;
  border-radius:10px;
}

/* ==========================================
   SIDEBAR & ROADMAP BENTO
   ========================================== */
.logistics-sidebar {
  display:flex;
  flex-direction:column;
  gap:20px;
}

.logistics-sidebar-card {
  padding:22px;
}

.logistics-side-header {
  display:flex;
  align-items:center;
  gap:12px;
  margin-bottom:18px;
  padding-bottom:14px;
  border-bottom:1px solid var(--border-light);
}

.logistics-side-badge {
  width:38px;
  height:38px;
  border-radius:10px;
  background:var(--primary-light, color-mix(in srgb, var(--d-primary) 10%, transparent));
  color:var(--primary);
  display:flex;
  align-items:center;
  justify-content:center;
  flex-shrink:0;
}

.logistics-side-badge.icon-emerald {
  background:rgba(16, 185, 129, 0.1);
  color:var(--d-primary);
}

.logistics-side-badge svg {
  width:18px;
  height:18px;
}

.logistics-side-header h3 {
  margin:0;
  font-size:14px;
  font-weight:850;
  color:var(--text-main);
}

.logistics-side-header small {
  display:block;
  font-size:11px;
  color:var(--text-muted);
  margin-top:2px;
}

.logistics-roadmap-list {
  display:flex;
  flex-direction:column;
  gap:14px;
}

.roadmap-item {
  display:flex;
  align-items:flex-start;
  gap:12px;
}

.step-num {
  width:24px;
  height:24px;
  border-radius:50%;
  background:var(--primary-light, color-mix(in srgb, var(--d-primary) 10%, transparent));
  color:var(--primary);
  font-family:var(--font-latin);
  font-size:12px;
  font-weight:850;
  display:flex;
  align-items:center;
  justify-content:center;
  flex-shrink:0;
  margin-top:1px;
}

.step-text strong {
  display:block;
  font-size:12.5px;
  font-weight:800;
  color:var(--text-main);
}

.step-text p {
  margin:2px 0 0;
  font-size:11px;
  color:var(--text-muted);
  line-height:1.5;
}

.step-text code {
  font-family:var(--font-mono);
  font-size:10.5px;
  padding:1px 5px;
  border-radius:4px;
  background:var(--surface-alt);
  color:var(--primary);
  border:1px solid var(--border-light);
}

/* Portal Preview Card */
.logistics-portal-preview {
  display:flex;
  flex-direction:column;
  gap:12px;
}

.preview-note {
  margin:0;
  font-size:12px;
  color:var(--text-body);
  line-height:1.6;
}

.preview-url-box {
  padding:10px 14px;
  border-radius:8px;
  background:var(--surface-alt);
  border:1px solid var(--border-light);
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
}

.preview-url {
  font-family:var(--font-mono);
  font-size:12px;
  color:var(--primary);
  font-weight:700;
}

.preview-code-tag {
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:8px;
  padding:10px 14px;
  border-radius:8px;
  background:color-mix(in srgb, var(--d-primary) 6%, transparent);
  border:1px dashed color-mix(in srgb, var(--d-primary) 30%, transparent);
  font-size:12px;
  color:var(--text-muted);
}

.preview-code-tag strong {
  color:var(--primary);
  font-family:var(--font-mono);
  font-size:13px;
}

/* ==========================================================================
   DARK MODE OVERRIDES FOR LOGISTICS SETUP
   ========================================================================== */

































/* Responsive adjustments */
@media (max-width:1024px) {
  .logistics-bento-grid {
    grid-template-columns:repeat(2, minmax(0, 1fr));
  }
  .logistics-credentials-grid {
    grid-template-columns:1fr;
  }
  .logistics-setup-grid {
    grid-template-columns:1fr;
  }
}

@media (max-width:640px) {
  .logistics-bento-grid {
    grid-template-columns:1fr;
  }
  .logistics-form-fields {
    grid-template-columns:1fr;
  }
  .logistics-cred-input-wrap {
    flex-direction:column;
    align-items:stretch;
  }
  .logistics-form-actions {
    flex-direction:column;
    align-items:stretch;
  }
}




/* ==========================================================================
   ADMIN SHARED ADDITIONS — classes used by detail pages and forms that had
   no rule before (subscription detail, admin user form). Theme tokens only.
   ========================================================================== */
.stat-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(220px, 100%), 1fr)); gap: 16px; margin-bottom: 22px; }
.stat-grid.four { grid-template-columns: repeat(4, minmax(0, 1fr)); }
@media (max-width: 1100px) { .stat-grid.four { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 600px) { .stat-grid.four { grid-template-columns: minmax(0, 1fr); } }
.stat-subtext { color: var(--text-muted); font-size: 11.5px; line-height: 1.6; }
.stat-value small { margin-inline-start: 6px; color: var(--text-muted); font-size: 12px; font-weight: 700; }
.stat-icon.indigo { background: color-mix(in srgb, #8b5cf6 14%, transparent); color: #8b5cf6; }

.panel-body { padding: 18px 22px; }
.panel-title-wrap { display: flex; align-items: center; gap: 12px; min-width: 0; }
.panel-head-link { display: inline-flex; align-items: center; gap: 6px; color: var(--primary); font-size: 12px; font-weight: 800; text-decoration: none; }
.panel-head-link:hover { text-decoration: underline; }

.detail-list { display: grid; }
.detail-list > div { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 12px 0; border-bottom: 1px dashed var(--border); }
.detail-list > div:last-child { border-bottom: 0; }
.detail-list span { color: var(--text-muted); font-size: 12.5px; }
.detail-list b { color: var(--text-main); font-size: 13px; text-align: end; overflow-wrap: anywhere; }

.stat-badge { display: inline-flex; align-items: center; padding: 3px 10px; border-radius: var(--radius-full); background: var(--primary-light); color: var(--primary); font-size: 11.5px; font-weight: 800; }
.stat-badge.indigo { background: color-mix(in srgb, #8b5cf6 14%, transparent); color: #8b5cf6; }
.currency-tag { display: inline-flex; padding: 2px 8px; border: 1px solid var(--border); border-radius: 7px; background: var(--surface-alt); color: var(--text-body); font: 700 11px var(--font-latin); }

.form-grid .hint, .hint { display: block; color: var(--text-muted); font-size: 12px; line-height: 1.7; }

/* Inside the dark sidebar, generic text/surface tokens resolve to the sidebar palette. */
.sidebar {
  --d-ink: var(--d-sidebar-ink);
  --d-ink-soft: color-mix(in srgb, var(--d-sidebar-ink) 86%, var(--d-sidebar-bg));
  --d-muted: var(--d-sidebar-muted);
  --d-muted-soft: color-mix(in srgb, var(--d-sidebar-muted) 80%, var(--d-sidebar-bg));
  --d-line: var(--d-sidebar-line);
  --d-line-soft: var(--d-sidebar-line);
  --d-surface: color-mix(in srgb, var(--d-sidebar-bg) 90%, #ffffff);
  --d-surface-2: color-mix(in srgb, var(--d-sidebar-bg) 94%, #ffffff);
  --d-surface-3: color-mix(in srgb, var(--d-sidebar-bg) 86%, #ffffff);
  --text-main: var(--d-sidebar-ink);
  --text-body: var(--d-sidebar-ink);
  --text-muted: var(--d-sidebar-muted);
  --border: var(--d-sidebar-line);
}

/* Platform support desk conversation (read-only) */
.support-thread { display:flex; flex-direction:column; gap:12px; padding:18px 20px 22px; }
.support-thread-message { max-width:min(680px, 88%); padding:12px 14px; border:1px solid var(--d-line); border-radius:14px; background:var(--d-surface); }
.support-thread-message.is-customer { align-self:flex-start; border-color:color-mix(in srgb, var(--d-primary) 35%, var(--d-line)); background:color-mix(in srgb, var(--d-primary) 7%, var(--d-surface)); }
.support-thread-message.is-company { align-self:flex-end; background:var(--d-surface-2); }
.support-thread-message.is-internal { border-style:dashed; border-color:color-mix(in srgb, var(--d-warn) 55%, var(--d-line)); }
.support-thread-message header { display:flex; flex-wrap:wrap; align-items:baseline; gap:8px; margin-bottom:6px; font-size:12.5px; color:var(--d-muted); }
.support-thread-message header strong { color:var(--d-ink); font-size:13.5px; }
.support-thread-message header time { margin-inline-start:auto; font-variant-numeric:tabular-nums; }
.support-thread-message p { margin:0; color:var(--d-ink); line-height:1.7; white-space:pre-wrap; overflow-wrap:anywhere; }

/* Logistics setup steps */
.logistics-tabs { display: flex; gap: 6px; padding: 6px; border: 1px solid var(--d-line, rgba(128,128,128,.25)); border-radius: 14px; background: var(--d-surface, transparent); overflow-x: auto; }
.logistics-tab { flex: 1 0 auto; padding: 10px 16px; border: 0; border-radius: 10px; background: transparent; color: inherit; font-size: 13px; font-weight: 700; font-family: inherit; cursor: pointer; opacity: .75; }
.logistics-tab:hover { opacity: 1; }
.logistics-tab.is-active { background: var(--d-primary, #2563eb); color: #fff; opacity: 1; }
[data-logistics-panel][hidden] { display: none; }
