/* ==========================================================================
   J H WEB SOLUTIONS - ADMIN PORTAL DESIGN SYSTEM
   Modern, Secure & Responsive Admin Console
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&family=Plus+Jakarta+Sans:wght@500;600;700;800&display=swap');

:root {
  --jh-admin-navy: #0D0A36;
  --jh-admin-indigo: #221C78;
  --jh-admin-indigo-light: #2E269E;
  --jh-admin-gold: #FFB800;
  --jh-admin-bg: #F8FAFC;
  --jh-admin-card-bg: #FFFFFF;
  --jh-admin-border: #E2E8F0;
  --jh-admin-text-main: #0F172A;
  --jh-admin-text-muted: #64748B;
  --jh-admin-font-heading: 'Plus Jakarta Sans', sans-serif;
  --jh-admin-font-body: 'Inter', sans-serif;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: var(--jh-admin-font-body);
  background-color: var(--jh-admin-bg);
  color: var(--jh-admin-text-main);
  min-height: 100vh;
  line-height: 1.5;
}

/* --- LOGIN PAGE STYLES --- */
.jh-admin-login-body {
  background: radial-gradient(circle at 10% 20%, rgba(46, 38, 158, 0.4) 0%, rgba(13, 10, 54, 0.98) 90%), #0D0A36;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px 16px;
}

.jh-admin-login-card {
  width: 100%;
  max-width: 440px;
  background: #FFFFFF;
  border-radius: 20px;
  box-shadow: 0 25px 60px -15px rgba(0, 0, 0, 0.5), 0 0 0 1px rgba(255, 255, 255, 0.1);
  padding: 40px 36px;
  animation: jhAdminFadeIn 0.4s ease-out;
}

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

.jh-admin-login-header {
  text-align: center;
  margin-bottom: 28px;
}

.jh-admin-logo-img {
  max-height: 48px;
  margin-bottom: 16px;
}

.jh-admin-login-title {
  font-family: var(--jh-admin-font-heading);
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--jh-admin-navy);
  margin-bottom: 4px;
}

.jh-admin-login-desc {
  font-size: 0.84rem;
  color: var(--jh-admin-text-muted);
}

.jh-admin-alert {
  padding: 12px 14px;
  border-radius: 10px;
  font-size: 0.8125rem;
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 20px;
}

.jh-admin-alert-error {
  background: #FEF2F2;
  color: #B91C1C;
  border: 1px solid #FCA5A5;
}

.jh-admin-alert-success {
  background: #ECFDF5;
  color: #047857;
  border: 1px solid #A7F3D0;
}

.jh-admin-form-group {
  margin-bottom: 20px;
}

.jh-admin-label {
  display: block;
  font-size: 0.8125rem;
  font-weight: 600;
  color: #334155;
  margin-bottom: 6px;
}

.jh-admin-input-wrap {
  position: relative;
  display: flex;
  align-items: center;
}

.jh-admin-input-icon {
  position: absolute;
  left: 14px;
  color: #94A3B8;
  font-size: 0.95rem;
}

.jh-admin-control {
  width: 100%;
  padding: 12px 14px 12px 42px;
  font-size: 0.9rem;
  font-family: inherit;
  border: 1.5px solid var(--jh-admin-border);
  border-radius: 10px;
  background: #F8FAFC;
  color: var(--jh-admin-text-main);
  transition: all 0.2s ease;
  outline: none;
}

.jh-admin-control:focus {
  border-color: var(--jh-admin-indigo);
  background: #FFFFFF;
  box-shadow: 0 0 0 3px rgba(34, 28, 120, 0.1);
}

.jh-admin-form-extras {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.8125rem;
  margin-bottom: 24px;
}

.jh-admin-checkbox {
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  color: #475569;
}

.jh-admin-btn-submit {
  width: 100%;
  padding: 13px;
  font-size: 0.9375rem;
  font-family: var(--jh-admin-font-heading);
  font-weight: 700;
  color: #FFFFFF;
  background: linear-gradient(135deg, var(--jh-admin-indigo), var(--jh-admin-indigo-light));
  border: none;
  border-radius: 10px;
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(34, 28, 120, 0.35);
  transition: all 0.25s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.jh-admin-btn-submit:hover {
  background: linear-gradient(135deg, var(--jh-admin-navy), var(--jh-admin-indigo));
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(34, 28, 120, 0.45);
}

.jh-admin-login-footer {
  margin-top: 24px;
  padding-top: 20px;
  border-top: 1px solid var(--jh-admin-border);
  text-align: center;
  font-size: 0.75rem;
  color: #94A3B8;
}

/* --- DASHBOARD STYLES --- */
.jh-dash-header {
  background: var(--jh-admin-navy);
  color: #FFFFFF;
  padding: 14px 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  position: sticky;
  top: 0;
  z-index: 100;
}

.jh-dash-brand {
  display: flex;
  align-items: center;
  gap: 14px;
}

.jh-dash-logo {
  height: 36px;
}

.jh-dash-brand-title {
  font-family: var(--jh-admin-font-heading);
  font-size: 1.05rem;
  font-weight: 800;
  color: #FFFFFF;
  letter-spacing: -0.01em;
}

.jh-dash-badge {
  background: var(--jh-admin-gold);
  color: var(--jh-admin-navy);
  font-size: 0.6875rem;
  font-weight: 800;
  padding: 2px 8px;
  border-radius: 4px;
  text-transform: uppercase;
}

.jh-dash-user-menu {
  display: flex;
  align-items: center;
  gap: 16px;
}

.jh-dash-user-info {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.84rem;
  color: #E2E8F0;
}

.jh-dash-user-avatar {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--jh-admin-indigo-light), #06B6D4);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  color: #FFFFFF;
  font-size: 0.84rem;
}

.jh-dash-logout-btn {
  background: rgba(255, 255, 255, 0.12);
  color: #FFFFFF;
  border: none;
  padding: 8px 14px;
  border-radius: 8px;
  font-size: 0.8125rem;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 6px;
  transition: all 0.2s;
}

.jh-dash-logout-btn:hover {
  background: #E5252A;
}

/* Dashboard Container */
.jh-dash-container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 32px 24px;
}

/* KPI Cards Grid */
.jh-dash-metrics {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 20px;
  margin-bottom: 32px;
}

.jh-metric-card {
  background: #FFFFFF;
  border: 1px solid var(--jh-admin-border);
  border-radius: 16px;
  padding: 22px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.03);
}

.jh-metric-info h3 {
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--jh-admin-text-muted);
  margin-bottom: 6px;
}

.jh-metric-count {
  font-family: var(--jh-admin-font-heading);
  font-size: 1.85rem;
  font-weight: 800;
  color: var(--jh-admin-navy);
  line-height: 1;
}

.jh-metric-icon {
  width: 50px;
  height: 50px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
}

.jh-metric-icon.leads { background: rgba(16, 185, 129, 0.12); color: #10B981; }
.jh-metric-icon.convs { background: rgba(34, 28, 120, 0.12); color: var(--jh-admin-indigo); }
.jh-metric-icon.msgs { background: rgba(6, 182, 212, 0.12); color: #06B6D4; }
.jh-metric-icon.bot { background: rgba(255, 184, 0, 0.15); color: #D97706; }

/* Dashboard Tabs */
.jh-dash-tabs {
  display: flex;
  gap: 8px;
  border-bottom: 1px solid var(--jh-admin-border);
  margin-bottom: 24px;
}

.jh-dash-tab-btn {
  padding: 12px 20px;
  background: none;
  border: none;
  font-family: var(--jh-admin-font-heading);
  font-size: 0.875rem;
  font-weight: 700;
  color: var(--jh-admin-text-muted);
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 8px;
  border-bottom: 2px solid transparent;
  transition: all 0.2s;
}

.jh-dash-tab-btn:hover {
  color: var(--jh-admin-navy);
}

.jh-dash-tab-btn.active {
  color: var(--jh-admin-indigo);
  border-bottom-color: var(--jh-admin-indigo);
}

/* Tab Content Cards */
.jh-dash-card {
  background: #FFFFFF;
  border: 1px solid var(--jh-admin-border);
  border-radius: 16px;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.03);
  overflow: hidden;
  margin-bottom: 24px;
}

.jh-dash-card-header {
  padding: 18px 24px;
  border-bottom: 1px solid var(--jh-admin-border);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.jh-dash-card-title {
  font-family: var(--jh-admin-font-heading);
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--jh-admin-navy);
}

/* ==========================================================================
   Universal Responsive Data Tables Architecture
   ========================================================================== */

.jh-table-responsive,
.jh-table-wrap {
  width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  background: #FFFFFF;
  position: relative;
  border-radius: 0 0 var(--jh-admin-radius) var(--jh-admin-radius);
}

/* Elegant slim scrollbars for responsive tables */
.jh-table-responsive::-webkit-scrollbar,
.jh-table-wrap::-webkit-scrollbar {
  height: 6px;
  width: 6px;
}
.jh-table-responsive::-webkit-scrollbar-track,
.jh-table-wrap::-webkit-scrollbar-track {
  background: #F1F5F9;
}
.jh-table-responsive::-webkit-scrollbar-thumb,
.jh-table-wrap::-webkit-scrollbar-thumb {
  background: #CBD5E1;
  border-radius: 6px;
}
.jh-table-responsive::-webkit-scrollbar-thumb:hover,
.jh-table-wrap::-webkit-scrollbar-thumb:hover {
  background: #94A3B8;
}

/* Table Base Styling */
.jh-admin-table,
.jh-responsive-table,
.jh-data-table {
  width: 100%;
  min-width: 660px; /* Guarantees columns never squeeze illegibly on mobile (320px+) */
  border-collapse: collapse;
  text-align: left;
  font-size: 0.84rem;
  background: #FFFFFF;
}

.jh-admin-table th,
.jh-responsive-table th,
.jh-data-table th {
  background: #F8FAFC;
  padding: 13px 18px;
  font-size: 0.775rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #475569;
  border-bottom: 1px solid var(--jh-admin-border);
  white-space: nowrap;
  vertical-align: middle;
}

.jh-admin-table td,
.jh-responsive-table td,
.jh-data-table td {
  padding: 13px 18px;
  border-bottom: 1px solid #F1F5F9;
  vertical-align: middle;
  font-size: 0.84rem;
  color: #1E293B;
  transition: background 0.15s ease;
}

.jh-admin-table tbody tr,
.jh-responsive-table tbody tr,
.jh-data-table tbody tr {
  transition: background 0.15s ease;
}

.jh-admin-table tbody tr:hover td,
.jh-responsive-table tbody tr:hover td,
.jh-data-table tbody tr:hover td {
  background: #F8FAFC;
}

/* Actions cell alignment */
.jh-actions-cell {
  display: flex;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
}

/* Order badge */
.jh-order-badge {
  display: inline-block;
  padding: 3px 8px;
  background: #F1F5F9;
  border: 1px solid #E2E8F0;
  border-radius: 6px;
  font-weight: 700;
  font-size: 0.75rem;
  color: #475569;
}

/* Mobile responsive optimizations (Down to 320px) */
@media (max-width: 768px) {
  .jh-admin-table,
  .jh-responsive-table,
  .jh-data-table {
    min-width: 600px;
  }
  .jh-admin-table th,
  .jh-responsive-table th,
  .jh-data-table th {
    padding: 10px 14px;
    font-size: 0.725rem;
  }
  .jh-admin-table td,
  .jh-responsive-table td,
  .jh-data-table td {
    padding: 10px 14px;
    font-size: 0.8125rem;
  }
}

.jh-wa-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border-radius: 6px;
  background: #25D366;
  color: #FFFFFF;
  text-decoration: none;
  font-weight: 700;
  font-size: 0.775rem;
}

.jh-wa-btn:hover {
  background: #1EBE5D;
}

/* ==========================================================================
   Admin Image Sizing & Thumbnail Controls (Small, Proportionate & Crisp)
   ========================================================================== */

/* Universal guard to prevent any admin image from overflowing */
.jh-admin-portal-body img {
  max-width: 100%;
  height: auto;
}

/* ==========================================================================
   Admin Image Sizing & Thumbnail Controls (Small, Proportionate & Attractive)
   ========================================================================== */

/* Universal guard to prevent any admin image from overflowing */
.jh-admin-portal-body img {
  max-width: 100%;
  height: auto;
}

/* Attractive Banner Thumbnail Container in Tables */
.jh-banner-thumb-wrap {
  position: relative;
  width: 96px;
  height: 54px;
  border-radius: 10px;
  overflow: hidden;
  border: 1.5px solid #E2E8F0;
  background: #0D0A36;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.08);
  cursor: pointer;
  transition: all 0.22s cubic-bezier(0.4, 0, 0.2, 1);
  display: block;
}

.jh-banner-thumb-wrap:hover {
  transform: translateY(-2px) scale(1.04);
  border-color: #0266C8;
  box-shadow: 0 8px 22px rgba(2, 102, 200, 0.25);
}

.jh-banner-thumb-compact {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.3s ease;
}

.jh-banner-thumb-wrap:hover .jh-banner-thumb-compact {
  transform: scale(1.08);
}

.jh-thumb-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(2, 102, 200, 0) 0%, rgba(13, 10, 54, 0.8) 100%);
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding-bottom: 4px;
  opacity: 0;
  transition: opacity 0.2s ease;
}

.jh-thumb-overlay i {
  color: #FFFFFF;
  font-size: 0.72rem;
  background: rgba(2, 102, 200, 0.95);
  padding: 3px 7px;
  border-radius: 4px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.3);
}

.jh-banner-thumb-wrap:hover .jh-thumb-overlay {
  opacity: 1;
}

/* Image Dimension & File Size Pill Badges */
.jh-img-dim-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  margin-top: 6px;
  font-size: 0.7rem;
  font-weight: 700;
  color: #1E293B;
  background: #EEF2F6;
  border: 1px solid #E2E8F0;
  padding: 3px 8px;
  border-radius: 6px;
  white-space: nowrap;
}

.jh-img-dim-badge i {
  color: #0266C8;
  font-size: 0.68rem;
}

/* Banner Form Live Preview Box */
.jh-banner-preview-box {
  background: #F8FAFC;
  border: 1.5px dashed #CBD5E1;
  border-radius: 12px;
  padding: 16px;
  margin-top: 12px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.jh-bprev-info {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
}

.jh-bprev-label {
  font-size: 0.8125rem;
  font-weight: 700;
  color: #0F172A;
  display: flex;
  align-items: center;
  gap: 6px;
}

.jh-bprev-specs {
  font-size: 0.75rem;
  font-weight: 600;
  color: #0266C8;
  background: rgba(2, 102, 200, 0.08);
  padding: 2px 8px;
  border-radius: 6px;
}

.jh-bprev-img-wrap {
  width: 100%;
  max-width: 360px;
  height: 150px;
  border-radius: 10px;
  overflow: hidden;
  border: 1.5px solid #CBD5E1;
  background: #0B0826;
  box-shadow: 0 4px 14px rgba(0,0,0,0.06);
}

.jh-bprev-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* ==========================================================================
   Image Lightbox Modal & Transcript Modal (Fix Popup Error & Add Luxury Design)
   ========================================================================== */

@keyframes jhModalBackdropFade {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes jhModalPopUp {
  from { opacity: 0; transform: scale(0.92) translateY(12px); }
  to { opacity: 1; transform: scale(1) translateY(0); }
}

/* Universal Modal Backdrop */
.jh-img-modal-backdrop,
.jh-img-modal,
.jh-modal-backdrop {
  position: fixed !important;
  inset: 0 !important;
  background: rgba(10, 8, 38, 0.82) !important;
  backdrop-filter: blur(8px) !important;
  -webkit-backdrop-filter: blur(8px) !important;
  z-index: 99999 !important;
  display: none !important;
  align-items: center !important;
  justify-content: center !important;
  padding: 24px !important;
  overflow-y: auto !important;
}

/* Open State */
.jh-img-modal-backdrop.is-open,
.jh-img-modal.is-open,
.jh-modal-backdrop.is-open {
  display: flex !important;
  animation: jhModalBackdropFade 0.2s ease-out !important;
}

/* Modal Content Card */
.jh-img-modal-content,
.jh-modal-content {
  background: #FFFFFF !important;
  border-radius: 16px !important;
  max-width: 860px !important;
  width: 100% !important;
  overflow: hidden !important;
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.45) !important;
  animation: jhModalPopUp 0.25s cubic-bezier(0.16, 1, 0.3, 1) !important;
  border: 1px solid rgba(255, 255, 255, 0.15) !important;
  position: relative !important;
}

/* Modal Header */
.jh-img-modal-header,
.jh-modal-header {
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  padding: 16px 22px !important;
  background: linear-gradient(135deg, #0D0A36 0%, #221C78 100%) !important;
  color: #FFFFFF !important;
}

.jh-img-modal-title,
.jh-modal-title {
  font-size: 1.05rem !important;
  font-weight: 700 !important;
  color: #FFFFFF !important;
  margin: 0 !important;
  display: flex !important;
  align-items: center !important;
  gap: 8px !important;
}

/* Modal Close Button */
.jh-img-modal-close,
.jh-modal-close {
  background: rgba(255, 255, 255, 0.15) !important;
  border: none !important;
  color: #FFFFFF !important;
  width: 32px !important;
  height: 32px !important;
  border-radius: 50% !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  font-size: 1.25rem !important;
  cursor: pointer !important;
  line-height: 1 !important;
  transition: all 0.18s ease !important;
}

.jh-img-modal-close:hover,
.jh-modal-close:hover {
  background: rgba(239, 68, 68, 0.95) !important;
  color: #FFFFFF !important;
  transform: rotate(90deg) !important;
}

/* Modal Image Body */
.jh-img-modal-body {
  padding: 24px !important;
  background: #08061E !important;
  text-align: center !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  min-height: 320px !important;
}

.jh-img-modal-body img {
  max-width: 100% !important;
  max-height: 65vh !important;
  border-radius: 10px !important;
  object-fit: contain !important;
  box-shadow: 0 12px 36px rgba(0, 0, 0, 0.6) !important;
  border: 1px solid rgba(255, 255, 255, 0.12) !important;
}

/* Modal Footer */
.jh-img-modal-footer,
.jh-modal-footer {
  padding: 14px 22px !important;
  background: #F8FAFC !important;
  border-top: 1px solid #E2E8F0 !important;
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  font-size: 0.84rem !important;
  color: #475569 !important;
  flex-wrap: wrap !important;
  gap: 10px !important;
}

.jh-img-meta-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #E2E8F0;
  color: #1E293B;
  font-weight: 600;
  font-size: 0.78125rem;
  padding: 4px 10px;
  border-radius: 6px;
}

/* Settings Form */
.jh-settings-grid {
  padding: 24px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}

.jh-settings-grid .full-col {
  grid-column: 1 / -1;
}

@media (max-width: 768px) {
  .jh-settings-grid {
    grid-template-columns: 1fr;
  }
}


/* ==========================================================================
   RIGHT-SIDE SIDEBAR & ENHANCED ADMIN PORTAL LAYOUT
   ========================================================================== */

.jh-admin-portal-body {
  background-color: #F1F5F9;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* Header Adjustments */
.jh-dash-submeta {
  font-size: 0.75rem;
  color: #94A3B8;
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 2px;
}

.jh-status-live-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #10B981;
  display: inline-block;
  box-shadow: 0 0 8px rgba(16, 185, 129, 0.8);
}

.jh-dash-btn-site {
  background: rgba(255, 255, 255, 0.12);
  color: #FFFFFF;
  padding: 6px 14px;
  border-radius: 8px;
  font-size: 0.8125rem;
  font-weight: 600;
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 6px;
  transition: all 0.2s;
}

.jh-dash-btn-site:hover {
  background: rgba(255, 255, 255, 0.22);
  color: #FFB800;
}

.jh-dash-user-text {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
}

.jh-dash-user-text span {
  font-size: 0.7rem;
  color: #94A3B8;
}

/* Main Dual-Column Layout: Sidebar on Left, Workspace on Right */
.jh-portal-wrapper {
  display: flex;
  flex-direction: row;
  flex: 1;
  width: 100%;
  min-height: calc(100vh - 64px);
}

.jh-portal-main {
  flex: 1;
  min-width: 0;
  padding: 24px 28px;
  overflow-y: auto;
}

/* Left-Side Sidebar (Compact & Clean - No Underlines) */
.jh-portal-sidebar {
  width: 245px;
  background: #0D0A36;
  color: #FFFFFF;
  border-right: 1px solid rgba(255, 255, 255, 0.08);
  padding: 12px 8px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  flex-shrink: 0;
  position: sticky;
  top: 64px;
  height: calc(100vh - 64px);
  overflow-y: auto;
  box-shadow: 4px 0 18px rgba(0, 0, 0, 0.06);
}

/* Explicitly remove all text underlines anywhere in sidebar */
.jh-portal-sidebar a,
.jh-portal-sidebar a:hover,
.jh-portal-sidebar a:focus,
.jh-portal-sidebar a:visited,
.jh-snav-btn,
.jh-snav-btn:hover,
.jh-snav-btn:focus,
.jh-snav-subitem,
.jh-snav-subitem:hover,
.jh-snav-subitem:focus {
  text-decoration: none !important;
}

.jh-sidebar-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 2px 6px 6px 6px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  margin-bottom: 2px;
}

.jh-sidebar-title {
  font-size: 0.6875rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  color: #94A3B8;
}

.jh-sidebar-badge {
  background: rgba(2, 102, 200, 0.25);
  color: #60A5FA;
  font-size: 0.65rem;
  font-weight: 700;
  padding: 2px 6px;
  border-radius: 5px;
}

/* Sidebar Navigation Items - Compact */
.jh-sidebar-nav {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.jh-snav-btn {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 7px 10px;
  background: transparent;
  color: #CBD5E1;
  border: 1px solid transparent;
  border-radius: 8px;
  cursor: pointer;
  font-size: 0.8125rem;
  font-weight: 600;
  transition: all 0.16s ease;
  text-align: left;
}

.jh-snav-btn:hover {
  background: rgba(255, 255, 255, 0.06);
  color: #FFFFFF;
  transform: translateX(2px);
}

.jh-snav-btn.active {
  background: linear-gradient(135deg, #221C78 0%, #0066cc 100%);
  color: #FFFFFF;
  border-color: rgba(255, 255, 255, 0.15);
  box-shadow: 0 3px 10px rgba(0, 102, 204, 0.3);
}

.jh-snav-left {
  display: flex;
  align-items: center;
  gap: 9px;
}

.jh-snav-left i {
  font-size: 0.875rem;
  width: 16px;
  text-align: center;
  opacity: 0.9;
}

.jh-snav-count {
  background: rgba(255, 255, 255, 0.15);
  color: #FFFFFF;
  font-size: 0.65rem;
  font-weight: 700;
  padding: 1px 6px;
  border-radius: 8px;
}

.jh-badge-pulse-green {
  background: #10B981 !important;
  color: #FFFFFF !important;
}

.jh-snav-dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #60A5FA;
}

/* Dropdown Accordion Groups in Left Sidebar */
.jh-snav-group {
  display: flex;
  flex-direction: column;
  border-radius: 8px;
  transition: background 0.16s ease;
}

.jh-snav-group.is-open {
  background: rgba(255, 255, 255, 0.03);
}

.jh-snav-right {
  display: flex;
  align-items: center;
  gap: 6px;
}

.jh-snav-arrow {
  font-size: 0.6875rem;
  color: #94A3B8;
  transition: transform 0.2s cubic-bezier(0.4, 0, 0.2, 1), color 0.16s ease;
}

.jh-snav-group.is-open .jh-snav-arrow {
  transform: rotate(180deg);
  color: #FFFFFF;
}

/* Dropdown Sub-List - Compact */
.jh-snav-sublist {
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  display: flex;
  flex-direction: column;
  gap: 1px;
  padding-left: 6px;
  margin-left: 12px;
  border-left: 1.5px solid rgba(255, 255, 255, 0.12);
  transition: max-height 0.25s ease, opacity 0.2s ease, margin 0.18s ease;
}

.jh-snav-group.is-open .jh-snav-sublist {
  max-height: 380px;
  opacity: 1;
  margin-top: 2px;
  margin-bottom: 4px;
  padding-top: 2px;
  padding-bottom: 2px;
}

.jh-snav-subitem {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 4.5px 8px;
  font-size: 0.775rem;
  font-weight: 500;
  color: #94A3B8;
  background: transparent;
  border: 1px solid transparent;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.15s ease;
  text-align: left;
}

.jh-snav-subitem i {
  font-size: 0.72rem;
  width: 14px;
  text-align: center;
  opacity: 0.85;
}

.jh-snav-subitem:hover {
  color: #FFFFFF;
  background: rgba(255, 255, 255, 0.08);
  transform: translateX(2px);
}

.jh-snav-subitem.active {
  color: #FFFFFF;
  background: rgba(2, 102, 200, 0.35);
  border-color: rgba(96, 165, 250, 0.45);
  font-weight: 600;
}

.jh-snav-subitem.active i {
  color: #60A5FA;
}

/* Quick Actions Box */
.jh-sidebar-quick-box {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  padding: 14px;
}

.jh-quick-title {
  display: block;
  font-size: 0.6875rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  color: #94A3B8;
  margin-bottom: 10px;
}

.jh-quick-actions-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.jh-btn-quick {
  width: 100%;
  padding: 8px 12px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  color: #E2E8F0;
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  text-align: left;
  display: flex;
  align-items: center;
  gap: 8px;
  transition: all 0.18s;
}

.jh-btn-quick:hover {
  background: #FFB800;
  color: #0D0A36;
  border-color: #FFB800;
}

/* Database Status Card */
.jh-sidebar-db-status {
  background: rgba(16, 185, 129, 0.08);
  border: 1px solid rgba(16, 185, 129, 0.2);
  border-radius: 10px;
  padding: 12px 14px;
}

.jh-sdb-head {
  font-size: 0.75rem;
  font-weight: 700;
  color: #34D399;
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 6px;
}

.jh-sdb-body {
  font-size: 0.75rem;
  color: #CBD5E1;
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.jh-sdb-body strong {
  color: #FFFFFF;
}

.jh-sidebar-footer {
  margin-top: auto;
  padding: 8px 6px 0 6px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.jh-sfoot-badge {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.72rem;
  color: #94A3B8;
}

.jh-sfoot-badge strong {
  color: #FFFFFF;
}

.jh-sfoot-meta {
  font-size: 0.65rem;
  color: #64748B;
  margin-top: 2px;
}

.jh-sfooter-link {
  font-size: 0.78rem;
  font-weight: 600;
  color: #94A3B8;
  text-decoration: none !important;
  display: flex;
  align-items: center;
  gap: 6px;
  transition: color 0.2s;
}

.jh-sfooter-link:hover {
  color: #FFFFFF;
}

.jh-sfooter-link.text-danger:hover {
  color: #F87171;
}

/* Section Header Hero */
.jh-section-hero {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 24px;
  flex-wrap: wrap;
  gap: 16px;
}

.jh-section-hero h2 {
  font-family: var(--jh-admin-font-heading);
  font-size: 1.45rem;
  font-weight: 800;
  color: #0F172A;
  margin-bottom: 4px;
}

.jh-section-hero p {
  font-size: 0.875rem;
  color: #64748B;
}

.jh-section-actions {
  display: flex;
  gap: 10px;
}

/* Tab View Panes */
.jh-tab-view {
  display: none;
  animation: jhAdminTabFade 0.25s ease-out;
}

.jh-tab-view.active {
  display: block;
}

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

/* Button Component Styles */
.jh-btn-action,
.jh-btn-primary,
.jh-btn-secondary,
.jh-btn-outline,
.jh-btn-submit {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 42px;
  padding: 0 18px;
  border-radius: 9px;
  font-family: var(--jh-admin-font-heading);
  font-size: 0.84rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  border: 1px solid transparent;
  text-decoration: none;
  box-sizing: border-box;
  white-space: nowrap;
}

.jh-btn-primary {
  background: linear-gradient(135deg, #042449 0%, #0066cc 100%);
  color: #FFFFFF !important;
  box-shadow: 0 4px 12px rgba(0, 102, 204, 0.28);
}

.jh-btn-primary:hover {
  background: linear-gradient(135deg, #021730 0%, #0052a3 100%);
  box-shadow: 0 6px 18px rgba(0, 102, 204, 0.38);
  transform: translateY(-1px);
}

.jh-btn-outline {
  background: #FFFFFF;
  color: #0F172A !important;
  border-color: #CBD5E1;
}

.jh-btn-outline:hover {
  background: #F8FAFC;
  border-color: #0266c8;
  color: #0266c8 !important;
  transform: translateY(-1px);
}

.jh-btn-secondary {
  background: #F1F5F9;
  color: #334155 !important;
  border-color: #E2E8F0;
}

.jh-btn-secondary:hover {
  background: #E2E8F0;
  color: #0F172A !important;
}

.jh-btn-icon {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid #E2E8F0;
  background: #FFFFFF;
  color: #64748B;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.18s ease;
  font-size: 0.85rem;
  box-sizing: border-box;
}

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

.jh-btn-icon.delete:hover {
  background: #FEF2F2;
  border-color: #FCA5A5;
  color: #DC2626;
  box-shadow: 0 3px 8px rgba(220, 38, 38, 0.15);
}

.jh-btn-icon.edit:hover {
  background: #EFF6FF;
  border-color: #93C5FD;
  color: #0266C8;
  box-shadow: 0 3px 8px rgba(2, 102, 200, 0.15);
}

/* Two Column Grid */
.jh-two-col-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}

/* Universal Form System Styles */
.jh-admin-form {
  padding: 22px 24px 24px;
}

.jh-form-row {
  display: flex;
  gap: 16px;
  align-items: flex-start;
  margin-bottom: 16px;
}

.jh-form-row:last-child {
  margin-bottom: 0;
}

.jh-form-col {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
}

.jh-form-label {
  display: block;
  font-size: 0.8125rem;
  font-weight: 700;
  color: #1E293B;
  margin-bottom: 2px;
}

.jh-form-label .text-danger {
  color: #EF4444;
  margin-left: 2px;
}

.jh-form-input {
  width: 100%;
  height: 44px;
  padding: 10px 14px;
  font-size: 0.875rem;
  font-family: inherit;
  color: #0F172A;
  background-color: #F8FAFC;
  border: 1.5px solid #E2E8F0;
  border-radius: 10px;
  transition: all 0.2s ease;
  outline: none;
  box-sizing: border-box;
}

select.jh-form-input {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%2364748b'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M19 9l-7 7-7-7'%3E%3C/path%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  background-size: 16px 16px;
  padding-right: 40px;
  cursor: pointer;
}

textarea.jh-form-input {
  height: auto;
  min-height: 100px;
  resize: vertical;
}

.jh-form-input:focus {
  background-color: #FFFFFF;
  border-color: #0066CC;
  box-shadow: 0 0 0 3.5px rgba(0, 102, 204, 0.12);
}

.jh-form-input::placeholder {
  color: #94A3B8;
}

.jh-form-hint {
  font-size: 0.75rem;
  color: #64748B;
  margin-top: 4px;
}

.jh-form-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 18px;
}

/* Badges & Chips */
.jh-badge-count {
  font-size: 0.75rem;
  font-weight: 700;
  padding: 4px 12px;
  border-radius: 9999px;
  background: #F1F5F9;
  color: #475569;
  border: 1px solid #E2E8F0;
}

.jh-badge-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 9999px;
  background: rgba(0, 102, 204, 0.08);
  color: #0066CC;
  border: 1px solid rgba(0, 102, 204, 0.18);
}

.jh-cat-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.78rem;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 6px;
  background: #F8FAFC;
  color: #334155;
  border: 1px solid #E2E8F0;
}

.jh-order-badge {
  font-family: monospace;
  font-weight: 700;
  font-size: 0.8rem;
  color: #64748B;
  background: #F1F5F9;
  padding: 2px 7px;
  border-radius: 4px;
}

/* Mini Lists */
.jh-mini-leads-list,
.jh-mini-convs-list {
  display: flex;
  flex-direction: column;
}

.jh-mini-lead-item,
.jh-mini-conv-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 18px;
  border-bottom: 1px solid #F1F5F9;
  transition: background 0.15s;
}

.jh-mini-lead-item:last-child,
.jh-mini-conv-item:last-child {
  border-bottom: none;
}

.jh-mini-lead-item:hover,
.jh-mini-conv-item:hover {
  background: #F8FAFC;
}

.jh-mini-lead-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: linear-gradient(135deg, #0066cc, #38bdf8);
  color: #FFFFFF;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-right: 12px;
}

.jh-mini-lead-details {
  flex: 1;
  display: flex;
  flex-direction: column;
  line-height: 1.3;
}

.jh-mini-lead-details strong {
  font-size: 0.875rem;
  color: #0F172A;
}

.jh-mini-lead-details span {
  font-size: 0.75rem;
  color: #64748B;
}

.jh-mini-lead-actions {
  display: flex;
  gap: 8px;
}

.jh-btn-icon-wa {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: #25D366;
  color: #FFFFFF;
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  font-size: 1rem;
  transition: transform 0.2s;
}

.jh-btn-icon-wa:hover {
  transform: scale(1.1);
}

.jh-btn-icon-call {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: #0266c8;
  color: #FFFFFF;
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  font-size: 0.875rem;
  transition: transform 0.2s;
}

.jh-btn-icon-call:hover {
  transform: scale(1.1);
}

.jh-mini-conv-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.jh-conv-code {
  display: flex;
  align-items: center;
  gap: 8px;
}

.jh-status-badge {
  font-size: 0.6875rem;
  font-weight: 700;
  padding: 2px 6px;
  border-radius: 4px;
  text-transform: uppercase;
}

.jh-status-active {
  background: #ECFDF5;
  color: #059669;
  border: 1px solid #A7F3D0;
}

.jh-status-closed {
  background: #F1F5F9;
  color: #64748B;
  border: 1px solid #E2E8F0;
}

.jh-conv-user {
  font-size: 0.8125rem;
  color: #475569;
}

.jh-btn-transcript-trigger {
  padding: 6px 12px;
  background: #F1F5F9;
  border: 1px solid #E2E8F0;
  border-radius: 6px;
  font-size: 0.75rem;
  font-weight: 600;
  color: #0266c8;
  cursor: pointer;
  transition: all 0.2s;
  display: flex;
  align-items: center;
  gap: 6px;
}

.jh-btn-transcript-trigger:hover {
  background: #0266c8;
  color: #FFFFFF;
  border-color: #0266c8;
}

.jh-link-more {
  font-size: 0.8125rem;
  color: #0266c8;
  font-weight: 600;
  text-decoration: none;
}

.jh-link-more:hover {
  text-decoration: underline;
}

.jh-empty-state-card {
  padding: 36px 20px;
  text-align: center;
  color: #64748B;
  font-size: 0.875rem;
}

/* ==========================================================================
   CAPTURE CARDS (LEAD CARDS GRID VIEW)
   ========================================================================== */
.jh-search-wrap-mini {
  width: 320px;
}

.jh-capture-cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 18px;
}

.jh-capture-card {
  background: #FFFFFF;
  border: 1px solid #E2E8F0;
  border-radius: 16px;
  padding: 18px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.03);
  transition: all 0.2s ease;
}

.jh-capture-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 24px -4px rgba(4, 36, 73, 0.12);
  border-color: #BFDBFE;
}

.jh-ccard-top {
  display: flex;
  align-items: center;
  gap: 12px;
  position: relative;
}

.jh-ccard-avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: linear-gradient(135deg, #042449 0%, #0066cc 100%);
  color: #FFFFFF;
  font-size: 1.1rem;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.jh-ccard-user {
  display: flex;
  flex-direction: column;
  flex: 1;
  line-height: 1.25;
}

.jh-ccard-name {
  font-size: 0.9375rem;
  font-weight: 700;
  color: #0F172A;
}

.jh-ccard-id {
  font-size: 0.72rem;
  color: #94A3B8;
}

.jh-ccard-date {
  font-size: 0.72rem;
  color: #64748B;
  background: #F8FAFC;
  padding: 3px 8px;
  border-radius: 6px;
  position: absolute;
  top: 0;
  right: 0;
}

.jh-ccard-body {
  background: #F8FAFC;
  border-radius: 10px;
  padding: 12px 14px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.jh-ccard-field {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.8125rem;
}

.jh-ccard-lbl {
  color: #64748B;
  display: flex;
  align-items: center;
  gap: 6px;
}

.jh-ccard-val {
  color: #0F172A;
  text-decoration: none;
  font-weight: 500;
}

.jh-ccard-service-badge {
  background: #EFF6FF;
  color: #1D4ED8;
  font-size: 0.75rem;
  font-weight: 600;
  padding: 3px 8px;
  border-radius: 6px;
  border: 1px solid #DBEAFE;
}

.jh-ccard-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.jh-btn-ccard-wa {
  background: #25D366;
  color: #FFFFFF;
  text-decoration: none;
  font-size: 0.8125rem;
  font-weight: 600;
  padding: 8px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: all 0.2s;
}

.jh-btn-ccard-wa:hover {
  background: #1EBE5D;
  transform: translateY(-1px);
}

.jh-btn-ccard-call {
  background: #0266c8;
  color: #FFFFFF;
  text-decoration: none;
  font-size: 0.8125rem;
  font-weight: 600;
  padding: 8px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: all 0.2s;
}

.jh-btn-ccard-call:hover {
  background: #042449;
  transform: translateY(-1px);
}

/* ==========================================================================
   CONVERSATION TRANSCRIPT MODAL VIEWER
   ========================================================================== */
.jh-modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(15, 23, 42, 0.65);
  backdrop-filter: blur(4px);
  z-index: 99999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.jh-transcript-modal {
  width: 100%;
  max-width: 580px;
  background: #FFFFFF;
  border-radius: 20px;
  box-shadow: 0 25px 60px -15px rgba(0, 0, 0, 0.4);
  display: flex;
  flex-direction: column;
  max-height: 85vh;
  overflow: hidden;
  animation: jhAdminFadeIn 0.3s ease-out;
}

.jh-tmodal-header {
  padding: 16px 22px;
  background: linear-gradient(135deg, #042449 0%, #0066cc 100%);
  color: #FFFFFF;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.jh-tmodal-title {
  display: flex;
  align-items: center;
  gap: 12px;
}

.jh-tmodal-avatar {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
}

.jh-tmodal-title h3 {
  font-size: 1rem;
  font-weight: 700;
  margin: 0;
}

.jh-tmodal-close {
  background: transparent;
  border: none;
  color: #FFFFFF;
  font-size: 1.5rem;
  cursor: pointer;
  opacity: 0.8;
  transition: opacity 0.2s;
}

.jh-tmodal-close:hover {
  opacity: 1;
}

.jh-tmodal-body {
  padding: 20px;
  overflow-y: auto;
  flex: 1;
  background: #F8FAFC;
}

.jh-transcript-chat-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.jh-tmsg-row {
  display: flex;
  flex-direction: column;
  max-width: 85%;
}

.jh-tmsg-user {
  align-self: flex-end;
  align-items: flex-end;
}

.jh-tmsg-ai {
  align-self: flex-start;
  align-items: flex-start;
}

.jh-tmsg-sender {
  font-size: 0.7rem;
  color: #64748B;
  margin-bottom: 4px;
}

.jh-tmsg-bubble {
  padding: 10px 14px;
  border-radius: 14px;
  font-size: 0.84rem;
  line-height: 1.45;
}

.jh-tmsg-user .jh-tmsg-bubble {
  background: #0266c8;
  color: #FFFFFF;
  border-bottom-right-radius: 2px;
}

.jh-tmsg-ai .jh-tmsg-bubble {
  background: #FFFFFF;
  color: #0F172A;
  border: 1px solid #E2E8F0;
  border-bottom-left-radius: 2px;
}

.jh-tmodal-footer {
  padding: 12px 20px;
  background: #FFFFFF;
  border-top: 1px solid #E2E8F0;
  display: flex;
  justify-content: flex-end;
}

/* Responsive adjustments */
@media (max-width: 860px) {
  .jh-portal-wrapper {
    flex-direction: column;
  }
  .jh-portal-sidebar {
    width: 100%;
    min-width: 100%;
    height: auto;
    position: static;
    border-right: none;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  }
  .jh-two-col-grid {
    grid-template-columns: 1fr;
  }
}

/* ==========================================================================
   UNIVERSAL ADMIN FORM & INTERACTIVE COMPONENT DESIGN SYSTEM
   Applies consistent high-end styling to all admin pages, forms, inputs,
   textareas, buttons, and CKEditor containers.
   ========================================================================== */

/* Form Layout Grids */
.jh-admin-form {
  display: flex;
  flex-direction: column;
}

.jh-form-grid {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.jh-form-row {
  display: flex;
  gap: 18px;
  margin-bottom: 16px;
  flex-wrap: wrap;
  align-items: flex-start;
}

.jh-form-col {
  flex: 1;
  min-width: 220px;
  display: flex;
  flex-direction: column;
}

.jh-form-group {
  display: flex;
  flex-direction: column;
  margin-bottom: 18px;
  width: 100%;
}

.jh-form-label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.8125rem;
  font-weight: 600;
  color: #1e293b;
  margin-bottom: 6px;
  letter-spacing: 0.15px;
}

/* Universal Inputs, Selects & Textareas */
.jh-form-input,
select.jh-form-input,
textarea.jh-form-input {
  width: 100%;
  height: 42px;
  padding: 8px 14px;
  font-size: 0.875rem;
  font-family: inherit;
  color: #0f172a;
  background-color: #ffffff;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  outline: none;
  box-sizing: border-box;
}

.jh-form-input:focus,
select.jh-form-input:focus,
textarea.jh-form-input:focus {
  border-color: #0256d3;
  box-shadow: 0 0 0 3.5px rgba(2, 86, 211, 0.15);
  background-color: #ffffff;
}

.jh-form-input::placeholder,
textarea.jh-form-input::placeholder {
  color: #94a3b8;
}

/* Textarea Customization */
textarea.jh-form-input,
textarea.ckeditor {
  height: auto;
  min-height: 100px;
  line-height: 1.55;
  resize: vertical;
  padding: 10px 14px;
}

/* Custom Select Dropdown Styling */
select.jh-form-input {
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='%2364748B'%3E%3Cpath fill-rule='evenodd' d='M5.293 7.293a1 1 0 011.414 0L10 10.586l3.293-3.293a1 1 0 111.414 1.414l-4 4a1 1 0 01-1.414 0l-4-4a1 1 0 010-1.414z' clip-rule='evenodd'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  background-size: 16px 16px;
  padding-right: 36px;
  cursor: pointer;
}

.jh-form-hint {
  font-size: 0.75rem;
  color: #64748b;
  margin-top: 5px;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  line-height: 1.4;
}

.jh-form-actions,
.jh-card-action-bar {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 20px;
  flex-wrap: wrap;
}

/* Universal Action Buttons */
.jh-btn-primary,
.jh-btn-action.jh-btn-primary,
button.jh-btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: linear-gradient(135deg, #0256d3 0%, #1d4ed8 100%);
  color: #ffffff !important;
  font-size: 0.85rem;
  font-weight: 600;
  padding: 9px 18px;
  border-radius: 8px;
  border: 1px solid #1d4ed8;
  cursor: pointer;
  text-decoration: none;
  box-shadow: 0 2px 6px rgba(2, 86, 211, 0.25);
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  line-height: 1.35;
}

.jh-btn-primary:hover,
.jh-btn-action.jh-btn-primary:hover,
button.jh-btn-primary:hover {
  background: linear-gradient(135deg, #0248b3 0%, #1e40af 100%);
  box-shadow: 0 4px 12px rgba(2, 86, 211, 0.35);
  transform: translateY(-1px);
}

.jh-btn-secondary,
.jh-btn-action.jh-btn-secondary,
button.jh-btn-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: #f1f5f9;
  color: #475569 !important;
  font-size: 0.85rem;
  font-weight: 600;
  padding: 9px 16px;
  border-radius: 8px;
  border: 1px solid #cbd5e1;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.2s ease;
  line-height: 1.35;
}

.jh-btn-secondary:hover,
.jh-btn-action.jh-btn-secondary:hover,
button.jh-btn-secondary:hover {
  background: #e2e8f0;
  color: #0f172a !important;
}

.jh-btn-action.jh-btn-outline,
.jh-btn-outline {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: #ffffff;
  color: #334155 !important;
  font-size: 0.85rem;
  font-weight: 600;
  padding: 8px 16px;
  border-radius: 8px;
  border: 1px solid #cbd5e1;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.2s ease;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03);
  line-height: 1.35;
}

.jh-btn-action.jh-btn-outline:hover,
.jh-btn-outline:hover {
  background: #f8fafc;
  border-color: #94a3b8;
  color: #0f172a !important;
}

.jh-btn-danger,
.jh-btn-action.jh-btn-danger {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: #ef4444;
  color: #ffffff !important;
  font-size: 0.85rem;
  font-weight: 600;
  padding: 8px 16px;
  border-radius: 8px;
  border: 1px solid #dc2626;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.2s ease;
  line-height: 1.35;
}

.jh-btn-danger:hover {
  background: #dc2626;
}

.jh-btn-close-card {
  background: none;
  border: none;
  font-size: 1.4rem;
  color: #94a3b8;
  cursor: pointer;
  line-height: 1;
  padding: 4px 8px;
  border-radius: 6px;
  transition: all 0.2s;
}

.jh-btn-close-card:hover {
  color: #ef4444;
  background: #fef2f2;
}

/* Edit Mode Banner */
.jh-edit-mode-indicator {
  display: none;
  align-items: center;
  justify-content: space-between;
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  color: #1e40af;
  padding: 8px 14px;
  border-radius: 8px;
  font-size: 0.82rem;
  margin-bottom: 16px;
}

/* Table Icon Buttons */
.jh-btn-icon {
  width: 32px;
  height: 32px;
  border-radius: 6px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid #e2e8f0;
  background: #ffffff;
  color: #64748b;
  cursor: pointer;
  transition: all 0.2s ease;
  font-size: 0.82rem;
  text-decoration: none;
}

.jh-btn-icon:hover {
  transform: translateY(-1px);
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.08);
}

.jh-btn-icon.edit:hover {
  color: #0256d3;
  border-color: #0256d3;
  background: #eff6ff;
}

.jh-btn-icon.delete:hover {
  color: #ef4444;
  border-color: #ef4444;
  background: #fef2f2;
}

/* CKEditor Polish */
.cke {
  border-radius: 8px !important;
  overflow: hidden !important;
  border: 1px solid #cbd5e1 !important;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04) !important;
  width: 100% !important;
  box-sizing: border-box !important;
}

.cke_top {
  background: #f8fafc !important;
  border-bottom: 1px solid #e2e8f0 !important;
  padding: 6px 8px !important;
}

.cke_bottom {
  background: #f8fafc !important;
  border-top: 1px solid #e2e8f0 !important;
}

.cke_inner {
  width: 100% !important;
  box-sizing: border-box !important;
}

.cke_wysiwyg_frame, 
.cke_wysiwyg_div {
  width: 100% !important;
  min-height: 220px !important;
}

/* Suppress CKEditor 4 security warning banner / version check notifications */
.cke_notifications_area,
.cke_notification,
.cke_notification_warning,
.cke_notification_info,
.cke_notification_message {
  display: none !important;
  visibility: hidden !important;
  opacity: 0 !important;
  height: 0 !important;
  max-height: 0 !important;
  overflow: hidden !important;
  pointer-events: none !important;
}

/* ==========================================================================
   GLOBAL LUXURY KPI METRICS GRID & CARDS
   ========================================================================== */
.jh-kpi-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 18px;
  margin-bottom: 28px;
}
@media (max-width: 600px) {
  .jh-kpi-grid {
    grid-template-columns: 1fr;
  }
}
.jh-kpi-card {
  background: #FFFFFF;
  border: 1px solid #E2E8F0;
  border-radius: 14px;
  padding: 18px 20px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04), 0 1px 2px rgba(0, 0, 0, 0.02);
  display: flex;
  align-items: center;
  gap: 16px;
  position: relative;
  overflow: hidden;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  text-decoration: none;
  color: inherit;
}
.jh-kpi-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 24px -4px rgba(15, 23, 42, 0.08), 0 4px 8px -2px rgba(15, 23, 42, 0.04);
  border-color: #CBD5E1;
}
.jh-kpi-card.card-blue:hover { border-color: #38BDF8; }
.jh-kpi-card.card-amber:hover { border-color: #FBBF24; }
.jh-kpi-card.card-green:hover { border-color: #34D399; }
.jh-kpi-card.card-red:hover { border-color: #F87171; }

.jh-kpi-icon {
  width: 50px;
  height: 50px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.35rem;
  flex-shrink: 0;
  transition: transform 0.25s ease;
}
.jh-kpi-card:hover .jh-kpi-icon {
  transform: scale(1.08);
}
.jh-kpi-icon.blue {
  background: linear-gradient(135deg, #0284C7, #0369A1) !important;
  color: #FFFFFF !important;
  box-shadow: 0 4px 12px rgba(2, 132, 199, 0.28);
}
.jh-kpi-icon.amber {
  background: linear-gradient(135deg, #F59E0B, #D97706) !important;
  color: #FFFFFF !important;
  box-shadow: 0 4px 12px rgba(245, 158, 11, 0.28);
}
.jh-kpi-icon.green {
  background: linear-gradient(135deg, #10B981, #059669) !important;
  color: #FFFFFF !important;
  box-shadow: 0 4px 12px rgba(16, 185, 129, 0.28);
}
.jh-kpi-icon.red {
  background: linear-gradient(135deg, #EF4444, #DC2626) !important;
  color: #FFFFFF !important;
  box-shadow: 0 4px 12px rgba(239, 68, 68, 0.28);
}

.jh-kpi-info {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-width: 0;
}
.jh-kpi-val {
  font-size: 1.75rem;
  font-weight: 800;
  color: #0F172A;
  line-height: 1.1;
  letter-spacing: -0.02em;
}
.jh-kpi-label {
  font-size: 0.75rem;
  font-weight: 700;
  color: #64748B;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-top: 4px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.jh-kpi-meta {
  font-size: 0.72rem;
  color: #94A3B8;
  font-weight: 600;
  margin-top: 2px;
  display: flex;
  align-items: center;
  gap: 5px;
}
.jh-kpi-pulse-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: #FEE2E2;
  color: #DC2626;
  font-size: 0.68rem;
  font-weight: 700;
  padding: 1px 7px;
  border-radius: 10px;
}
.jh-kpi-pulse-dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #DC2626;
  animation: kpiPulse 1.5s infinite;
}
@keyframes kpiPulse {
  0% { transform: scale(0.9); opacity: 0.7; }
  50% { transform: scale(1.3); opacity: 1; }
  100% { transform: scale(0.9); opacity: 0.7; }
}

/* ==========================================================================
   Live Support Hub Unified Suite Sub-Navigation Bar
   ========================================================================== */
.jh-support-suite-bar {
  background: #FFFFFF;
  border-bottom: 1px solid #E2E8F0;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.03);
  position: relative;
  z-index: 10;
  flex-shrink: 0;
}

.jh-portal-main > .jh-support-suite-bar {
  border: 1px solid #E2E8F0;
  border-radius: 14px;
  margin-bottom: 22px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

.jh-live-console-wrap > .jh-support-suite-bar {
  border-radius: 0;
  border-left: none;
  border-right: none;
  border-top: none;
  border-bottom: 1px solid #E2E8F0;
  margin-bottom: 0;
}

.jh-support-suite-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 20px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  gap: 12px;
}

.jh-support-suite-inner::-webkit-scrollbar {
  height: 3px;
}
.jh-support-suite-inner::-webkit-scrollbar-thumb {
  background: #CBD5E1;
  border-radius: 3px;
}

.jh-support-suite-tabs {
  display: flex;
  align-items: center;
  gap: 4px;
}

.jh-suite-tab {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 44px;
  padding: 0 14px;
  font-size: 13px;
  font-weight: 600;
  color: #64748B;
  text-decoration: none !important;
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
  white-space: nowrap;
  transition: all 0.16s ease;
  border-radius: 8px 8px 0 0;
}

.jh-suite-tab:hover {
  color: #0266C8;
  background: rgba(2, 102, 200, 0.04);
}

.jh-suite-tab.is-active {
  color: #0266C8;
  border-bottom-color: #0266C8;
  font-weight: 700;
  background: rgba(2, 102, 200, 0.05);
}

.jh-suite-tab i {
  font-size: 14px;
  transition: transform 0.16s ease;
}
.jh-suite-tab:hover i {
  transform: scale(1.1);
}

.jh-suite-pill-badge {
  font-size: 10.5px;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: 12px;
  line-height: 1;
}
.jh-suite-pill-badge.green {
  background: #DCFCE7;
  color: #166534;
}
.jh-suite-pill-badge.red {
  background: #FEE2E2;
  color: #DC2626;
}
.jh-suite-pill-badge.amber {
  background: #FEF3C7;
  color: #92400E;
}

.jh-suite-dot-live {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #10B981;
  box-shadow: 0 0 0 2px rgba(16, 185, 129, 0.25);
  animation: jhLivePulseDot 1.8s infinite;
}

@keyframes jhLivePulseDot {
  0% { transform: scale(0.9); box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7); }
  70% { transform: scale(1.2); box-shadow: 0 0 0 5px rgba(16, 185, 129, 0); }
  100% { transform: scale(0.9); box-shadow: 0 0 0 0 rgba(16, 185, 129, 0); }
}

.jh-support-suite-meta {
  display: flex;
  align-items: center;
  gap: 12px;
  white-space: nowrap;
}

.jh-suite-status-indicator {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 11.5px;
  font-weight: 600;
  color: #059669;
  background: #ECFDF5;
  border: 1px solid #A7F3D0;
  padding: 3px 9px;
  border-radius: 20px;
}

.jh-pulse-dot-emerald {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #10B981;
  box-shadow: 0 0 0 2px rgba(16, 185, 129, 0.3);
  animation: jhLivePulseDot 1.8s infinite;
}



