/* =============================================================
   neerajpharma — SHARED WHITE THEME DESIGN SYSTEM
   Applied to: Dashboard, Symptom Checker, AI Assistant,
               Appointments, Health Records, Consultations,
               My Profile
   ============================================================= */

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

/* ── TOKENS ── */
:root {
  --bg-base:        #f0f4ff;
  --bg-white:       #ffffff;
  --bg-surface:     #f8faff;
  --bg-hover:       #f1f5ff;
  --border:         #e2e8f5;
  --border-focus:   #3b82f6;
  --sidebar-bg:     #ffffff;
  --sidebar-w:      260px;

  --primary:        #3b82f6;
  --primary-dark:   #2563eb;
  --primary-light:  #eff6ff;
  --primary-glow:   rgba(59,130,246,.15);

  --cyan:           #06b6d4;
  --violet:         #8b5cf6;
  --rose:           #f43f5e;
  --emerald:        #10b981;
  --amber:          #f59e0b;

  --text-primary:   #0f172a;
  --text-secondary: #475569;
  --text-muted:     #94a3b8;
  --text-accent:    #2563eb;

  --radius-sm:  8px;
  --radius-md:  14px;
  --radius-lg:  20px;
  --radius-xl:  28px;
  --shadow-xs:  0 1px 3px rgba(0,0,0,.06);
  --shadow-sm:  0 4px 12px rgba(0,0,0,.06);
  --shadow-md:  0 8px 24px rgba(0,0,0,.08);
  --shadow-lg:  0 16px 40px rgba(0,0,0,.1);
  --shadow-blue:0 4px 20px rgba(59,130,246,.25);
  --transition: all .25s cubic-bezier(.4,0,.2,1);
}

/* ── RESET ── */
*, *::before, *::after { margin:0; padding:0; box-sizing:border-box; }
html { scroll-behavior: smooth; }

body {
  font-family: 'Inter', sans-serif;
  background: var(--bg-base);
  color: var(--text-primary);
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

/* ── LAYOUT ── */
.dashboard-wrapper {
  display: flex;
  height: 100vh;
  overflow: hidden;
}

/* ─────────────────────────────────────────────
   SIDEBAR — clean white with blue accent
───────────────────────────────────────────── */
.sidebar {
  width: var(--sidebar-w);
  min-width: var(--sidebar-w);
  background: var(--sidebar-bg);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  padding: 24px 16px;
  box-shadow: var(--shadow-xs);
  z-index: 100;
  overflow-y: auto;
  overflow-x: hidden;
}

/* Logo */
.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 4px 8px 28px;
  border-bottom: 1px solid var(--border);
  margin-bottom: 20px;
}
.logo i {
  font-size: 26px;
  color: var(--primary) !important;
}
.logo h2 {
  font-size: 20px;
  font-weight: 800;
  color: var(--text-primary);
  letter-spacing: -0.3px;
}
.logo h2 span { color: var(--primary); }

/* Nav */
.menu { list-style: none; display: flex; flex-direction: column; gap: 2px; }

.menu li {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 14px 18px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  font-size: 16px;
  font-weight: 500;
  color: var(--text-secondary);
  transition: var(--transition);
  position: relative;
  margin-bottom: 4px;
}
.menu li i {
  font-size: 18px;
  width: 18px;
  text-align: center;
  flex-shrink: 0;
}
.menu li:hover {
  background: var(--primary-light);
  color: var(--primary);
}
.menu li:hover i { color: var(--primary); }

.menu li.active {
  background: var(--primary-light);
  color: var(--primary-dark);
  font-weight: 600;
  border: 1px solid rgba(59,130,246,.18);
}
.menu li.active i { color: var(--primary); }
.menu li.active::before {
  content: '';
  position: absolute;
  left: 0; top: 20%; bottom: 20%;
  width: 3px;
  background: var(--primary);
  border-radius: 0 4px 4px 0;
}

/* Sidebar user mini card */
.sidebar-user-mini {
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 10px 12px;
  margin-bottom: 20px;
}
.sidebar-user-mini .mini-avatar {
  width: 34px; height: 34px;
  background: linear-gradient(135deg, var(--primary), var(--cyan));
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 13px; font-weight: 700;
  color: white; flex-shrink: 0;
}
.sidebar-user-mini .mini-info strong {
  display: block; font-size: 13px; font-weight: 600;
  color: var(--text-primary);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  max-width: 140px;
}
.sidebar-user-mini .mini-info small {
  font-size: 11px; color: var(--emerald);
  display: flex; align-items: center; gap: 4px;
}

/* Nav section label */
.nav-section-label {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 1.4px;
  text-transform: uppercase;
  color: var(--text-muted);
  padding: 2px 14px 6px;
}

/* Logout */
.menu li.logout-item { color: #ef4444; margin-top: 12px; border-top: 1px solid var(--border); padding-top: 15px; }
.menu li.logout-item:hover { background: #fff5f5; color: #dc2626; }

/* ─────────────────────────────────────────────
   MAIN AREA
───────────────────────────────────────────── */
.main-area {
  flex: 1;
  overflow-y: auto;
  background: var(--bg-base);
  scrollbar-width: thin;
  scrollbar-color: #dde4f0 transparent;
}
.main-area::-webkit-scrollbar { width: 5px; }
.main-area::-webkit-scrollbar-thumb { background: #dde4f0; border-radius: 10px; }

.main-content {
  padding: 36px 40px;
  max-width: 1440px;
}

/* ─────────────────────────────────────────────
   PAGE HEADER
───────────────────────────────────────────── */
.top-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 32px;
  gap: 20px;
}
.greeting h1 {
  font-size: 26px;
  font-weight: 800;
  color: var(--text-primary);
  letter-spacing: -0.4px;
  display: flex;
  align-items: center;
  gap: 10px;
}
.greeting h1 i { color: var(--primary); font-size: 22px; }
.greeting p { color: var(--text-secondary); font-size: 14px; margin-top: 5px; }
.header-actions { display: flex; align-items: center; gap: 12px; }

/* ─────────────────────────────────────────────
   BUTTONS
───────────────────────────────────────────── */
.primary-btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 10px 22px;
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: white;
  border: none;
  border-radius: var(--radius-md);
  font-size: 14px; font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
  box-shadow: var(--shadow-blue);
  letter-spacing: 0.1px;
  white-space: nowrap;
}
.primary-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 28px rgba(59,130,246,.35);
}
.primary-btn:active { transform: translateY(0); }

.secondary-btn {
  display: inline-flex; align-items: center; gap: 7px;
  padding: 9px 18px;
  background: var(--bg-white);
  color: var(--primary);
  border: 1.5px solid var(--border-focus);
  border-radius: var(--radius-md);
  font-size: 14px; font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
}
.secondary-btn:hover { background: var(--primary-light); }

.icon-btn {
  width: 38px; height: 38px;
  border-radius: var(--radius-sm);
  background: var(--bg-white);
  border: 1px solid var(--border);
  display: flex; align-items: center; justify-content: center;
  color: var(--text-secondary);
  cursor: pointer;
  transition: var(--transition);
  font-size: 14px;
  box-shadow: var(--shadow-xs);
}
.icon-btn:hover {
  background: var(--primary-light);
  color: var(--primary);
  border-color: rgba(59,130,246,.3);
}

/* ─────────────────────────────────────────────
   STAT CARDS
───────────────────────────────────────────── */
.stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 18px;
  margin-bottom: 32px;
}

.stat-card {
  background: var(--bg-white);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 22px 20px;
  transition: var(--transition);
  position: relative;
  overflow: hidden;
  box-shadow: var(--shadow-xs);
}
.stat-card::after {
  content: ''; position: absolute;
  bottom: 0; left: 0; right: 0; height: 3px;
  border-radius: 0 0 var(--radius-lg) var(--radius-lg);
  opacity: 0; transition: opacity .3s;
}
.stat-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); }
.stat-card:hover::after { opacity: 1; }

.stat-card.blue .stat-icon { background: #eff6ff; color: var(--primary); }
.stat-card.blue::after { background: var(--primary); }
.stat-card.red .stat-icon { background: #fff1f2; color: var(--rose); }
.stat-card.red::after { background: var(--rose); }
.stat-card.violet .stat-icon { background: #f5f3ff; color: var(--violet); }
.stat-card.violet::after { background: var(--violet); }
.stat-card.amber .stat-icon { background: #fffbeb; color: var(--amber); }
.stat-card.amber::after { background: var(--amber); }
.stat-card.green .stat-icon { background: #f0fdf4; color: var(--emerald); }
.stat-card.green::after { background: var(--emerald); }

.stat-icon {
  width: 44px; height: 44px;
  border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  font-size: 18px;
  margin-bottom: 16px;
}
.stat-card h4 {
  font-size: 12px; font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase; letter-spacing: 0.5px;
  margin-bottom: 6px;
}
.stat-card h2 {
  font-size: 26px; font-weight: 800;
  color: var(--text-primary);
  display: flex; align-items: baseline; gap: 6px;
  letter-spacing: -0.5px;
}
.badge-up, .badge-normal, .badge-warn {
  display: inline-flex; align-items: center; gap: 3px;
  font-size: 11px; font-weight: 600;
  padding: 3px 8px; border-radius: 20px;
  margin-top: 8px;
}
.badge-up { background: #f0fdf4; color: var(--emerald); }
.badge-normal { background: #eff6ff; color: var(--primary); }
.badge-warn { background: #fffbeb; color: var(--amber); }
.positive { background: #f0fdf4; color: var(--emerald); font-size:12px; padding: 2px 8px; border-radius:20px; font-weight:600; }
.neutral  { background: #f1f5f9; color: #64748b; font-size:12px; padding: 2px 8px; border-radius:20px; font-weight:600; }

/* ─────────────────────────────────────────────
   SECTION HEADINGS
───────────────────────────────────────────── */
.section-title {
  font-size: 16px; font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 16px;
  display: flex; align-items: center; gap: 10px;
}
.section-title .sep { flex:1; height:1px; background: var(--border); }

/* ─────────────────────────────────────────────
   CARDS / PANELS (white glass)
───────────────────────────────────────────── */
.white-card, .glass-panel, .glass-card {
  background: var(--bg-white);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
}

/* Appointment items */
.appointment-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  background: var(--bg-white);
  transition: var(--transition);
  cursor: pointer;
  margin-bottom: 10px;
}
.appointment-item:hover {
  background: var(--bg-hover);
  border-color: rgba(59,130,246,.25);
  transform: translateX(3px);
}
.appt-info { display: flex; align-items: center; gap: 13px; }
.doctor-avatar {
  width: 46px; height: 46px;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--primary), var(--cyan));
  color: white;
  display: flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: 15px;
}
.appt-info h4 { font-size: 15px; font-weight: 600; color: var(--text-primary); }
.appt-info p  { font-size: 12px; color: var(--text-muted); margin-top: 2px; }
.appt-time { text-align: right; }
.appt-time .date { display:block; font-weight:600; color:var(--primary); font-size:13px; }
.appt-time .time { font-size:12px; color:var(--text-muted); }

/* ─────────────────────────────────────────────
   QUICK ACTIONS
───────────────────────────────────────────── */
.quick-actions {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 16px;
  margin-bottom: 32px;
}
.action-card {
  background: var(--bg-white);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 22px 14px;
  text-align: center;
  cursor: pointer;
  transition: var(--transition);
  box-shadow: var(--shadow-xs);
}
.action-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-md);
  border-color: rgba(59,130,246,.25);
}
.action-card i {
  font-size: 26px;
  margin-bottom: 12px;
  display: block;
  color: var(--primary);
}
.action-card:nth-child(1) i { color: var(--violet); }
.action-card:nth-child(2) i { color: var(--primary); }
.action-card:nth-child(3) i { color: var(--cyan); }
.action-card:nth-child(4) i { color: var(--emerald); }
.action-card:nth-child(5) i { color: var(--amber); }

.action-card h3 { font-size: 13px; font-weight: 600; color: var(--text-secondary); }
.action-card:hover h3 { color: var(--primary); }

/* ─────────────────────────────────────────────
   BOTTOM SECTION
───────────────────────────────────────────── */
.bottom-section {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 24px;
}
.appointments {
  background: var(--bg-white);
  padding: 26px;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border);
}
.section-header {
  display: flex; justify-content: space-between; align-items: center;
  margin-bottom: 20px;
}
.view-all {
  font-size: 13px; font-weight: 600;
  color: var(--primary);
  cursor: pointer;
  display: flex; align-items: center; gap: 5px;
  transition: var(--transition);
  background: none; border: none;
}
.view-all:hover { color: var(--primary-dark); }

/* Health tip */
.health-tip {
  background: linear-gradient(135deg, var(--primary), #1d4ed8);
  color: white;
  padding: 26px;
  border-radius: var(--radius-lg);
  position: relative;
  overflow: hidden;
  box-shadow: var(--shadow-blue);
}
.health-tip h3 { font-size: 16px; margin-bottom: 12px; color: #bfdbfe; display:flex;gap:8px;align-items:center; }
.health-tip p  { font-size: 14px; line-height: 1.65; color: rgba(255,255,255,.85); }

/* ─────────────────────────────────────────────
   TABS
───────────────────────────────────────────── */
.custom-tabs { display: flex; gap: 8px; margin-bottom: 24px; flex-wrap: wrap; }
.tab-btn {
  padding: 8px 18px;
  border-radius: 10px;
  border: 1.5px solid var(--border);
  background: var(--bg-white);
  color: var(--text-secondary);
  font-size: 13px; font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
  box-shadow: var(--shadow-xs);
}
.tab-btn:hover { background: var(--primary-light); color: var(--primary); border-color: rgba(59,130,246,.3); }
.tab-btn.active {
  background: var(--primary);
  color: white;
  border-color: var(--primary);
  box-shadow: var(--shadow-blue);
}

/* ─────────────────────────────────────────────
   HEALTH RECORDS CARDS
───────────────────────────────────────────── */
.glass-record-card {
  background: var(--bg-white);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 18px 22px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  transition: var(--transition);
  box-shadow: var(--shadow-xs);
}
.glass-record-card:hover { transform: translateX(4px); box-shadow: var(--shadow-sm); border-color: rgba(59,130,246,.2); }
.record-left { display: flex; align-items: center; gap: 16px; }
.record-icon {
  width: 46px; height: 46px;
  border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  font-size: 18px;
  flex-shrink: 0;
}
.record-left h3 { font-size: 15px; font-weight: 600; color: var(--text-primary); }
.record-left p  { font-size: 12px; color: var(--text-muted); margin-top: 3px; }

/* ─────────────────────────────────────────────
   DOCTOR CARDS (Consultations)
───────────────────────────────────────────── */
.doctor-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 20px;
}
.doctor-card {
  background: var(--bg-white);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: var(--transition);
  box-shadow: var(--shadow-sm);
}
.doctor-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); }
.doctor-info { border-bottom-color: var(--border) !important; }
.doctor-info:hover { background: var(--bg-hover) !important; }
.doctor-actions { background: var(--bg-surface) !important; }

.call-btn {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 8px 16px; border-radius: var(--radius-sm);
  border: none; font-size: 13px; font-weight: 600;
  cursor: pointer; transition: var(--transition);
}
.btn-voice {
  background: var(--bg-white);
  color: var(--primary);
  border: 1.5px solid var(--border);
}
.btn-voice:hover { background: var(--primary-light); border-color: var(--primary); }
.btn-video {
  background: var(--primary);
  color: white;
  box-shadow: var(--shadow-blue);
}
.btn-video:hover { background: var(--primary-dark); transform: translateY(-1px); }

/* Secure box */
.secure-box { background: var(--primary-light) !important; border-color: rgba(59,130,246,.2) !important; color: var(--primary-dark) !important; }

/* ─────────────────────────────────────────────
   FORMS / PROFILE
───────────────────────────────────────────── */
.profile-summary.glass-panel {
  background: linear-gradient(135deg, var(--primary-light), #f0f9ff);
  border-color: rgba(59,130,246,.18);
}

/* Upload select */
.upload-select {
  background: var(--bg-white);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text-primary);
  font-size: 14px;
}
.upload-select:focus { border-color: var(--primary); outline: none; }

/* ─────────────────────────────────────────────
   PROGRESS BAR
───────────────────────────────────────────── */
.progress-wrap {
  width: 100%;
  background: #e2e8f5;
  border-radius: 99px;
  height: 8px;
  overflow: hidden;
}
.progress-fill {
  height: 100%;
  border-radius: 99px;
  background: linear-gradient(90deg, var(--primary), var(--cyan));
  transition: width 1.4s cubic-bezier(.4,0,.2,1);
}

/* Dashboard hero banner */
.health-banner {
  background: linear-gradient(135deg, #f0f7ff 0%, #ffffff 60%, #f0f4ff 100%);
  border: 1px solid rgba(59,130,246,.15);
  border-radius: var(--radius-xl);
  padding: 30px 32px;
  margin-bottom: 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  box-shadow: var(--shadow-sm);
  position: relative;
  overflow: hidden;
}
.health-banner::before {
  content: '';
  position: absolute; right:-40px; top:-40px;
  width: 200px; height: 200px;
  background: radial-gradient(circle, rgba(59,130,246,.06) 0%, transparent 70%);
  pointer-events: none;
}
.banner-left .banner-label {
  font-size: 11px; font-weight: 700;
  letter-spacing: 1.4px; text-transform: uppercase;
  color: var(--primary); margin-bottom: 8px;
}
.banner-left h2 { font-size: 20px; font-weight: 700; color: var(--text-primary); line-height: 1.35; }
.banner-left p  { font-size: 13px; color: var(--text-secondary); margin-top: 6px; }

/* Ring score */
.ring-wrap { width: 90px; height: 90px; position: relative; }
.ring-wrap svg { width:100%; height:100%; transform: rotate(-90deg); }
.ring-wrap .ring-bg { fill:none; stroke:#e2e8f5; stroke-width:8; }
.ring-wrap .ring-fg { fill:none; stroke:url(#ringGradLight); stroke-width:8; stroke-linecap:round; stroke-dasharray:283; stroke-dashoffset:70; transition: stroke-dashoffset 1.5s; }
.ring-center { position:absolute;inset:0;display:flex;flex-direction:column;align-items:center;justify-content:center; }
.ring-center .score-num { font-size:20px;font-weight:800;color:var(--text-primary); }
.ring-center .score-label { font-size:9px;font-weight:600;text-transform:uppercase;color:var(--primary);letter-spacing:.8px; }
.ring-info .ri-title { font-size:13px;font-weight:600;color:var(--text-primary); }
.ring-info .ri-sub   { font-size:12px;color:var(--text-muted); }
.ring-info .ri-badge {
  display:inline-flex;align-items:center;gap:4px;
  background:#f0fdf4;border:1px solid #bbf7d0;color:var(--emerald);
  font-size:11px;font-weight:600;padding:2px 8px;border-radius:20px;margin-top:5px;
}

/* Activity mini rows */
.metric-row {
  display: flex;align-items:center;gap:12px;
  padding: 10px 0; border-bottom: 1px solid var(--border);
}
.metric-row:last-child { border-bottom:none; padding-bottom:0; }
.mr-icon { width:32px;height:32px;border-radius:8px;display:flex;align-items:center;justify-content:center;font-size:13px;flex-shrink:0; }
.mr-label { flex:1;font-size:13px;color:var(--text-secondary); }
.mr-value { font-size:13px;font-weight:700;color:var(--text-primary); }
.mr-bar { width:56px;height:4px;background:#e2e8f5;border-radius:99px;overflow:hidden;flex-shrink:0; }
.mr-bar-fill { height:100%;border-radius:99px; }

/* ─────────────────────────────────────────────
   ANIMATIONS
───────────────────────────────────────────── */
@keyframes fadeSlideUp {
  from { opacity:0; transform:translateY(18px); }
  to   { opacity:1; transform:translateY(0); }
}
.anim-1 { animation: fadeSlideUp .45s ease both; }
.anim-2 { animation: fadeSlideUp .45s .07s ease both; }
.anim-3 { animation: fadeSlideUp .45s .14s ease both; }
.anim-4 { animation: fadeSlideUp .45s .21s ease both; }
.anim-5 { animation: fadeSlideUp .45s .28s ease both; }

/* Floating */
@keyframes float { 0%,100% { transform:translateY(0); } 50% { transform:translateY(-10px); } }
.float-animation { animation: float 4s ease-in-out infinite; }

/* ─────────────────────────────────────────────
   RESPONSIVE
───────────────────────────────────────────── */
/* ─────────────────────────────────────────────
   RESPONSIVE
───────────────────────────────────────────── */
@media (max-width: 1024px) {
  .bottom-grid { grid-template-columns: 1fr !important; }
  .bottom-section { grid-template-columns: 1fr; }
  .main-content { padding: 24px 20px; }
  .stats { grid-template-columns: repeat(2, 1fr) !important; }
}

@media (max-width: 768px) {
  .sidebar {
    position: fixed;
    left: 0;
    top: 0;
    bottom: 0;
    transform: translateX(-100%);
    transition: var(--transition);
    z-index: 2000;
    min-width: var(--sidebar-w); /* Maintain width when fixed */
  }
  .sidebar.active {
    transform: translateX(0);
  }
  
  /* Mobile Overlay */
  .sidebar-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(4px);
    z-index: 1999;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
  }
  .sidebar-overlay.active {
    opacity: 1;
    visibility: visible;
  }

  .dashboard-wrapper { 
    display: block; 
    height: auto; 
    min-height: 100vh;
    overflow: visible; 
  }
  .main-area { 
    width: 100%; 
    min-width: 100%; 
    height: auto;
    overflow: visible;
  }
  .main-content { 
    padding: 16px; 
    width: 100%;
    overflow-x: hidden;
  }

  .quick-actions { grid-template-columns: repeat(2, 1fr) !important; }
  .stats { grid-template-columns: 1fr !important; gap: 12px !important; }
  .health-banner { 
    flex-direction: column; 
    align-items: flex-start; 
    text-align: left; 
    padding: 20px; 
    gap: 15px;
  }
  .top-header { 
    flex-direction: row; /* Keep greeting and actions together if possible, or stack */
    flex-wrap: wrap;
    align-items: center; 
    gap: 12px; 
    margin-bottom: 20px;
  }
  .greeting h1 { font-size: 20px; }
  .header-actions, .header-right-btns { 
    width: 100%; 
    display: flex;
    flex-wrap: wrap; 
    gap: 8px;
  }
  .primary-btn { width: 100%; justify-content: center; }
  
  /* Stack the bottom grid panels */
  .bottom-section, .bottom-grid {
    grid-template-columns: 1fr !important;
    gap: 20px !important;
  }

  /* Prevent horizontal scroll */
  body { overflow-x: hidden; width: 100%; position: relative; }
}

