:root {
  /* Color Palette - Deep Clinical Blue & Precision Teal */
  --hf-primary: #0052FF;
  --hf-primary-dark: #0037A8;
  --hf-secondary: #00D1FF;
  --hf-accent: #7000FF;
  --hf-bg-main: #FFFFFF;
  --hf-bg-alt: #F8FAFF;
  --hf-text-main: #0A0F1D;
  --hf-text-muted: #4F5B76;
  --hf-border: #E2E8F0;
  --hf-success: #10B981;
  
  /* Typography */
  --hf-font-display: 'Instrument Serif', serif;
  --hf-font-body: 'Inter', system-ui, -apple-system, sans-serif;
  
  /* Spacing */
  --wf-space-xs: 4px;
  --wf-space-sm: 8px;
  --wf-space-md: 16px;
  --wf-space-lg: 24px;
  --wf-space-xl: 48px;
  --wf-space-2xl: 80px;
  --wf-space-3xl: 120px;

  /* Shadows */
  --hf-shadow-sm: 0 2px 4px rgba(0,0,0,0.05);
  --hf-shadow-md: 0 10px 30px rgba(0,0,0,0.08);
  --hf-shadow-lg: 0 20px 50px rgba(0,82,255,0.1);
}

* {
  box-sizing: border-box;
  -webkit-font-smoothing: antialiased;
}

body {
  margin: 0;
  padding: 0;
  font-family: var(--hf-font-body);
  color: var(--hf-text-main);
  background-color: var(--hf-bg-main);
  line-height: 1.6;
  overflow-x: hidden;
}

body.dashboard-page {
  background-color: var(--hf-bg-alt);
}

h1, h2, h3, h4 {
  font-family: var(--hf-font-body);
  font-weight: 600;
  letter-spacing: -0.02em;
  margin: 0;
}

.display-text {
  font-family: var(--hf-font-display);
  font-weight: 400;
  font-style: italic;
  font-size: clamp(2.5rem, 8vw, 5rem);
  line-height: 1.1;
}

p {
  margin: 0;
}

a {
  text-decoration: none;
  color: inherit;
  transition: all 0.2s ease;
}

.container {
  width: 100%;
  max-width: 1440px;
  margin: 0 auto;
  padding: 0 clamp(1.5rem, 5vw, 6rem);
}

/* Navigation */
.nav {
  height: 80px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: sticky;
  top: 0;
  background: rgba(255, 255, 255, 0.8);
  backdrop-filter: blur(10px);
  z-index: 1000;
  border-bottom: 1px solid var(--hf-border);
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
  font-size: 1.25rem;
  color: var(--hf-primary);
}

.nav-links {
  display: flex;
  gap: var(--wf-space-xl);
}

.nav-link {
  font-weight: 500;
  font-size: 0.95rem;
  color: var(--hf-text-muted);
}

.nav-link:hover {
  color: var(--hf-primary);
}

.nav-actions {
  display: flex;
  gap: var(--wf-space-md);
  align-items: center;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 24px;
  border-radius: 100px;
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  border: none;
}

.btn-primary {
  background: var(--hf-primary);
  color: white;
}

.btn-primary:hover {
  background: var(--hf-primary-dark);
  transform: translateY(-2px);
  box-shadow: var(--hf-shadow-lg);
}

.btn-outline {
  background: transparent;
  border: 1px solid var(--hf-border);
  color: var(--hf-text-main);
}

.btn-outline:hover {
  background: var(--hf-bg-alt);
  border-color: var(--hf-primary);
}

/* Hero Section */
.hero {
  padding: var(--wf-space-3xl) 0 var(--wf-space-2xl);
  background: radial-gradient(circle at 80% 20%, rgba(0, 82, 255, 0.05) 0%, transparent 50%);
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: var(--wf-space-2xl);
  align-items: center;
}

.hero-tag {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--hf-bg-alt);
  padding: 6px 16px;
  border-radius: 100px;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--hf-primary);
  margin-bottom: var(--wf-space-lg);
}

.hero-title {
  margin-bottom: var(--wf-space-lg);
}

.hero-subtitle {
  font-size: 1.25rem;
  color: var(--hf-text-muted);
  max-width: 540px;
  margin-bottom: var(--wf-space-xl);
}

/* Cards & Components */
.card {
  background: white;
  border: 1px solid var(--hf-border);
  border-radius: 24px;
  padding: var(--wf-space-xl);
  transition: all 0.3s ease;
}

.card:hover {
  border-color: var(--hf-primary);
  box-shadow: var(--hf-shadow-md);
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--wf-space-lg);
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--wf-space-xl);
  border-top: 1px solid var(--hf-border);
  padding-top: var(--wf-space-xl);
}

.stat-item h3 {
  font-size: 2.5rem;
  color: var(--hf-primary);
}

.stat-item p {
  color: var(--hf-text-muted);
  font-weight: 500;
}

/* Sections */
section {
  margin-top: var(--wf-space-3xl);
}

.section-header {
  text-align: center;
  max-width: 700px;
  margin: 0 auto var(--wf-space-2xl);
}

.section-title {
  font-size: 3rem;
  margin-bottom: var(--wf-space-md);
}

/* Platform Preview */
.platform-preview {
  position: relative;
  background: var(--hf-text-main);
  border-radius: 32px;
  padding: 12px;
  box-shadow: var(--hf-shadow-lg);
  overflow: hidden;
}

.preview-inner {
  background: var(--hf-bg-alt);
  border-radius: 20px;
  aspect-ratio: 16/10;
  display: grid;
  grid-template-columns: 240px 1fr;
  overflow: hidden;
}

.preview-sidebar {
  background: white;
  border-right: 1px solid var(--hf-border);
  padding: var(--wf-space-lg);
}

.preview-content {
  padding: var(--wf-space-xl);
}

/* Dashboard UI Elements */
.dashboard-container {
  display: grid;
  grid-template-columns: 280px 1fr;
  min-height: 100vh;
}

.sidebar {
  background: white;
  border-right: 1px solid var(--hf-border);
  padding: var(--wf-space-xl);
  display: flex;
  flex-direction: column;
}

.sidebar-nav {
  margin-top: var(--wf-space-2xl);
  flex-grow: 1;
}

.sidebar-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  border-radius: 12px;
  color: var(--hf-text-muted);
  margin-bottom: 4px;
  font-weight: 500;
  text-decoration: none;
}

.sidebar-item.active {
  background: var(--hf-bg-alt);
  color: var(--hf-primary);
}

.main-view {
  padding: var(--wf-space-2xl);
  max-width: 1200px;
  width: 100%;
  margin: 0 auto;
}

.dash-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: var(--wf-space-2xl);
}

.dash-grid {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: var(--wf-space-lg);
}

.status-badge {
  padding: 4px 12px;
  border-radius: 100px;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
}

.status-badge.critical { background: #FEE2E2; color: #EF4444; }
.status-badge.stable { background: #D1FAE5; color: #10B981; }

.patient-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: var(--wf-space-lg);
}

.patient-table th {
  text-align: left;
  padding: 16px;
  font-size: 0.85rem;
  color: var(--hf-text-muted);
  border-bottom: 1px solid var(--hf-border);
}

.patient-table td {
  padding: 16px;
  border-bottom: 1px solid var(--hf-border);
}

.placeholder-image {
  background: #EDF2F7;
  border-radius: 12px;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #A0AEC0;
  font-size: 0.9rem;
  position: relative;
  overflow: hidden;
}

.placeholder-image::after {
  content: attr(data-label);
}

.placeholder-avatar {
  width: 40px;
  height: 40px;
  background: var(--hf-primary);
  border-radius: 50%;
}

/* Footer */
footer {
  margin-top: var(--wf-space-3xl);
  padding: var(--wf-space-2xl) 0;
  background: var(--hf-bg-alt);
  border-top: 1px solid var(--hf-border);
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: var(--wf-space-2xl);
}

.footer-logo {
  font-weight: 700;
  font-size: 1.5rem;
  color: var(--hf-primary);
  margin-bottom: var(--wf-space-lg);
}

.footer-links h4 {
  margin-bottom: var(--wf-space-lg);
}

.footer-links ul {
  list-style: none;
  padding: 0;
}

.footer-links li {
  margin-bottom: var(--wf-space-md);
}

.footer-links a {
  color: var(--hf-text-muted);
}

.footer-links a:hover {
  color: var(--hf-primary);
}

/* Utility Classes */
.text-accent { color: var(--hf-accent); }
.text-bold { font-weight: 600; }
.text-sm { font-size: 0.85rem; }
.m-b-sm { margin-bottom: 8px; }
.m-b-md { margin-bottom: 16px; }
.m-b-lg { margin-bottom: 24px; }
.m-t-xl { margin-top: 48px; }
.flex { display: flex; }
.flex-col { display: flex; flex-direction: column; }
.items-center { align-items: center; }
.justify-between { justify-content: space-between; }
.gap-sm { gap: 8px; }
.gap-md { gap: 16px; }
.gap-lg { gap: 24px; }
.w-full { width: 100%; }
.p-0 { padding: 0 !important; }
.overflow-hidden { overflow: hidden; }
.text-primary { color: var(--hf-primary); }
.bg-alt { background-color: var(--hf-bg-alt); }

@media (max-width: 1024px) {
  .hero-grid, .feature-grid, .footer-grid {
    grid-template-columns: 1fr;
  }
  .hero-grid {
    text-align: center;
  }
  .hero-subtitle {
    margin-left: auto;
    margin-right: auto;
  }
  .stats-grid {
    grid-template-columns: 1fr 1fr;
  }
}
