

/* ========================================
   CAREAGENT DESIGN SYSTEM
   Universal Typography & Icon System
   iOS-Inspired Design Language
   ======================================== */

/* ========================================
   TYPOGRAPHY - SF Pro & System Fonts
   ======================================== */

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

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

html {
  color-scheme: light only;
  width: 100%;
  height: 100%;
  margin: 0;
  padding: 0;
}

body {
  color-scheme: light only;
  background-color: #F5F5F7;
  width: 100%;
  min-height: 100vh;
  margin: 0;
  padding: 0;
  overflow-x: hidden;
}

:root {
  color-scheme: light only;
  /* Font Families */
  --font-primary: -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'SF Pro Text', 'Inter', 'Segoe UI', 'Helvetica Neue', Arial, sans-serif;
  --font-mono: 'SF Mono', 'Monaco', 'Menlo', 'Consolas', 'Courier New', monospace;

  /* Font Weights - iOS Standard */
  --font-ultralight: 100;
  --font-thin: 200;
  --font-light: 300;
  --font-regular: 400;
  --font-medium: 500;
  --font-semibold: 600;
  --font-bold: 700;
  --font-heavy: 800;
  --font-black: 900;

  /* Font Sizes - iOS Scale */
  --text-xs: 0.6875rem;     /* 11px */
  --text-sm: 0.8125rem;     /* 13px */
  --text-base: 0.9375rem;   /* 15px - iOS body */
  --text-md: 1rem;          /* 16px */
  --text-lg: 1.0625rem;     /* 17px - iOS headline */
  --text-xl: 1.25rem;       /* 20px */
  --text-2xl: 1.5rem;       /* 24px */
  --text-3xl: 1.75rem;      /* 28px - iOS Large Title */
  --text-4xl: 2rem;         /* 32px */
  --text-5xl: 2.5rem;       /* 40px */
  --text-6xl: 3rem;         /* 48px */

  /* Line Heights - iOS Standard */
  --leading-none: 1;
  --leading-tight: 1.25;
  --leading-snug: 1.375;
  --leading-normal: 1.5;
  --leading-relaxed: 1.625;
  --leading-loose: 2;

  /* Letter Spacing - iOS Style */
  --tracking-tighter: -0.05em;
  --tracking-tight: -0.025em;
  --tracking-normal: 0;
  --tracking-wide: 0.025em;
  --tracking-wider: 0.05em;
  --tracking-widest: 0.1em;

  /* iOS 18 Colors - Updated Palette */
  --ios-primary: #04724d;
  --ios-primary-light: #05a36b;
  --ios-accent: #0A84FF;
  --ios-accent-light: #64B5FF;
  --ios-blue: #0A84FF;
  --ios-blue-light: #64B5FF;
  --ios-green: #30D158;
  --ios-green-light: #63E179;
  --ios-orange: #FF9F0A;
  --ios-orange-light: #FFBF3D;
  --ios-red: #FF453A;
  --ios-red-light: #FF6E64;
  --ios-purple: #BF5AF2;
  --ios-purple-light: #D98FFF;
  --ios-pink: #FF375F;
  --ios-pink-light: #FF6B8A;
  --ios-teal: #64D2FF;
  --ios-teal-light: #90E0FF;
  --ios-indigo: #5E5CE6;
  --ios-indigo-light: #8E8CFF;
  --ios-yellow: #FFD60A;
  --ios-yellow-light: #FFE33D;
  --ios-mint: #00C7BE;
  --ios-mint-light: #3DD9D1;
  --ios-cyan: #55BEF0;
  --ios-cyan-light: #82D1F5;

  /* iOS 18 Backgrounds - Softer, More Natural */
  --bg-primary: #F5F5F7;
  --bg-secondary: #FFFFFF;
  --bg-tertiary: #FAFAFA;
  --bg-elevated: #FFFFFF;
  --bg-grouped: #F2F2F7;

  /* iOS 18 Text Colors - Better Contrast */
  --text-primary: #1C1C1E;
  --text-secondary: #48484A;
  --text-tertiary: #8E8E93;
  --text-quaternary: #C7C7CC;
  --text-placeholder: #AEAEB2;

  /* iOS 18 Borders - Refined Opacity */
  --border-light: rgba(0, 0, 0, 0.08);
  --border-medium: rgba(0, 0, 0, 0.15);
  --border-strong: rgba(0, 0, 0, 0.25);
  --ios-separator: rgba(60, 60, 67, 0.29);

  /* Border Radius - iOS Standard */
  --radius-xs: 6px;
  --radius-sm: 8px;
  --radius-md: 10px;
  --radius-lg: 12px;
  --radius-xl: 14px;
  --radius-2xl: 18px;
  --radius-3xl: 20px;
  --radius-full: 9999px;

  /* Shadows - iOS Style */
  --shadow-xs: 0 1px 2px rgba(0, 0, 0, 0.04);
  --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.06);
  --shadow-md: 0 4px 8px rgba(0, 0, 0, 0.08);
  --shadow-lg: 0 8px 16px rgba(0, 0, 0, 0.1);
  --shadow-xl: 0 12px 24px rgba(0, 0, 0, 0.12);
  --shadow-2xl: 0 20px 40px rgba(0, 0, 0, 0.15);

  /* Transitions */
  --transition-fast: 150ms cubic-bezier(0.4, 0, 0.2, 1);
  --transition-base: 200ms cubic-bezier(0.4, 0, 0.2, 1);
  --transition-slow: 300ms cubic-bezier(0.4, 0, 0.2, 1);
  --transition-bounce: 300ms cubic-bezier(0.68, -0.55, 0.265, 1.55);

  /* Z-Index Scale */
  --z-dropdown: 1000;
  --z-sticky: 1020;
  --z-fixed: 1030;
  --z-modal-backdrop: 1040;
  --z-modal: 1050;
  --z-popover: 1060;
  --z-tooltip: 1070;
}

/* ========================================
   BASE TYPOGRAPHY STYLES
   ======================================== */

body {
  font-family: var(--font-primary);
  font-size: var(--text-base);
  font-weight: var(--font-regular);
  line-height: var(--leading-normal);
  color: var(--text-primary);
  letter-spacing: -0.01em;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-primary);
  font-weight: var(--font-semibold);
  line-height: var(--leading-tight);
  letter-spacing: var(--tracking-tight);
  margin: 0;
}

h1 {
  font-size: var(--text-4xl);
  font-weight: var(--font-bold);
  letter-spacing: -0.03em;
}

h2 {
  font-size: var(--text-3xl);
  font-weight: var(--font-bold);
  letter-spacing: -0.025em;
}

h3 {
  font-size: var(--text-2xl);
  font-weight: var(--font-semibold);
  letter-spacing: -0.02em;
}

h4 {
  font-size: var(--text-xl);
  font-weight: var(--font-semibold);
}

h5 {
  font-size: var(--text-lg);
  font-weight: var(--font-medium);
}

h6 {
  font-size: var(--text-base);
  font-weight: var(--font-medium);
}

p {
  margin: 0;
  line-height: var(--leading-relaxed);
}

/* Typography Utility Classes */
.text-display {
  font-size: var(--text-5xl);
  font-weight: var(--font-bold);
  letter-spacing: -0.04em;
  line-height: var(--leading-none);
}

.text-headline {
  font-size: var(--text-lg);
  font-weight: var(--font-semibold);
  letter-spacing: -0.015em;
}

.text-body {
  font-size: var(--text-base);
  font-weight: var(--font-regular);
  line-height: var(--leading-normal);
}

.text-caption {
  font-size: var(--text-sm);
  font-weight: var(--font-regular);
  color: var(--text-secondary);
}

.text-footnote {
  font-size: var(--text-xs);
  font-weight: var(--font-regular);
  color: var(--text-tertiary);
}

.font-light { font-weight: var(--font-light); }
.font-regular { font-weight: var(--font-regular); }
.font-medium { font-weight: var(--font-medium); }
.font-semibold { font-weight: var(--font-semibold); }
.font-bold { font-weight: var(--font-bold); }
.font-heavy { font-weight: var(--font-heavy); }

/* ========================================
   MODERN ICON SYSTEM
   Bootstrap Icons + Custom Styling
   ======================================== */

/* Icon Base Styles */
.icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  vertical-align: middle;
  line-height: 1;
}

/* Icon Sizes - iOS Standard */
.icon-xs { font-size: 0.75rem; width: 16px; height: 16px; }
.icon-sm { font-size: 0.875rem; width: 20px; height: 20px; }
.icon-md { font-size: 1rem; width: 24px; height: 24px; }
.icon-lg { font-size: 1.25rem; width: 28px; height: 28px; }
.icon-xl { font-size: 1.5rem; width: 32px; height: 32px; }
.icon-2xl { font-size: 2rem; width: 40px; height: 40px; }

/* Icon Styles */
.icon-filled {
  font-variation-settings: 'FILL' 1;
}

.icon-outlined {
  font-variation-settings: 'FILL' 0;
}

/* Icon Colors */
.icon-primary { color: var(--ios-primary); }
.icon-blue { color: var(--ios-blue); }
.icon-green { color: var(--ios-green); }
.icon-orange { color: var(--ios-orange); }
.icon-red { color: var(--ios-red); }
.icon-purple { color: var(--ios-purple); }
.icon-pink { color: var(--ios-pink); }
.icon-teal { color: var(--ios-teal); }
.icon-indigo { color: var(--ios-indigo); }
.icon-gray { color: var(--text-tertiary); }

/* Icon Containers */
.icon-container {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-full);
  transition: all var(--transition-base);
}

.icon-container-sm {
  width: 32px;
  height: 32px;
  padding: 6px;
}

.icon-container-md {
  width: 40px;
  height: 40px;
  padding: 8px;
}

.icon-container-lg {
  width: 48px;
  height: 48px;
  padding: 10px;
}

.icon-container-xl {
  width: 56px;
  height: 56px;
  padding: 12px;
}

/* Icon Button Styles */
.icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: none;
  background: transparent;
  cursor: pointer;
  padding: 8px;
  border-radius: var(--radius-full);
  transition: all var(--transition-base);
  color: var(--text-secondary);
}

.icon-btn:hover {
  background: var(--bg-tertiary);
  color: var(--text-primary);
}

.icon-btn:active {
  transform: scale(0.92);
}

.icon-btn.icon-btn-primary {
  color: var(--ios-primary);
}

.icon-btn.icon-btn-primary:hover {
  background: rgba(4, 114, 77, 0.1);
}

/* Badge with Icons */
.icon-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border-radius: var(--radius-full);
  font-size: var(--text-sm);
  font-weight: var(--font-medium);
  background: var(--bg-tertiary);
  color: var(--text-secondary);
}

.icon-badge.badge-primary {
  background: rgba(4, 114, 77, 0.1);
  color: var(--ios-primary);
}

.icon-badge.badge-blue {
  background: rgba(0, 122, 255, 0.1);
  color: var(--ios-blue);
}

.icon-badge.badge-green {
  background: rgba(52, 199, 89, 0.1);
  color: var(--ios-green);
}

.icon-badge.badge-orange {
  background: rgba(255, 149, 0, 0.1);
  color: var(--ios-orange);
}

.icon-badge.badge-red {
  background: rgba(255, 59, 48, 0.1);
  color: var(--ios-red);
}

/* ========================================
   MODERN ICON MAPPINGS
   Using Bootstrap Icons v1.11
   ======================================== */

/* Navigation Icons */
.icon-home::before { content: "\f424"; font-family: 'bootstrap-icons'; }
.icon-dashboard::before { content: "\f3fd"; font-family: 'bootstrap-icons'; }
.icon-messages::before { content: "\f4ad"; font-family: 'bootstrap-icons'; }
.icon-calendar::before { content: "\f1f3"; font-family: 'bootstrap-icons'; }
.icon-contacts::before { content: "\f4cc"; font-family: 'bootstrap-icons'; }
.icon-settings::before { content: "\f4ab"; font-family: 'bootstrap-icons'; }

/* Action Icons */
.icon-add::before { content: "\f4fe"; font-family: 'bootstrap-icons'; }
.icon-edit::before { content: "\f4d3"; font-family: 'bootstrap-icons'; }
.icon-delete::before { content: "\f5de"; font-family: 'bootstrap-icons'; }
.icon-save::before { content: "\f493"; font-family: 'bootstrap-icons'; }
.icon-close::before { content: "\f62a"; font-family: 'bootstrap-icons'; }
.icon-search::before { content: "\f52a"; font-family: 'bootstrap-icons'; }
.icon-filter::before { content: "\f38f"; font-family: 'bootstrap-icons'; }
.icon-more::before { content: "\f4ca"; font-family: 'bootstrap-icons'; }

/* Communication Icons */
.icon-chat::before { content: "\f26d"; font-family: 'bootstrap-icons'; }
.icon-send::before { content: "\f52b"; font-family: 'bootstrap-icons'; }
.icon-voice::before { content: "\f459"; font-family: 'bootstrap-icons'; }
.icon-mic::before { content: "\f459"; font-family: 'bootstrap-icons'; }
.icon-speaker::before { content: "\f653"; font-family: 'bootstrap-icons'; }
.icon-notification::before { content: "\f19d"; font-family: 'bootstrap-icons'; }

/* User Icons */
.icon-user::before { content: "\f4da"; font-family: 'bootstrap-icons'; }
.icon-users::before { content: "\f4db"; font-family: 'bootstrap-icons'; }
.icon-profile::before { content: "\f4da"; font-family: 'bootstrap-icons'; }
.icon-logout::before { content: "\f19b"; font-family: 'bootstrap-icons'; }

/* Status Icons */
.icon-success::before { content: "\f26b"; font-family: 'bootstrap-icons'; }
.icon-error::before { content: "\f623"; font-family: 'bootstrap-icons'; }
.icon-warning::before { content: "\f33a"; font-family: 'bootstrap-icons'; }
.icon-info::before { content: "\f431"; font-family: 'bootstrap-icons'; }
.icon-check::before { content: "\f26b"; font-family: 'bootstrap-icons'; }

/* ========================================
   UTILITY CLASSES
   ======================================== */

/* Text Colors */
.text-primary { color: var(--text-primary); }
.text-secondary { color: var(--text-secondary); }
.text-tertiary { color: var(--text-tertiary); }
.text-quaternary { color: var(--text-quaternary); }

/* Background Colors */
.bg-primary { background-color: var(--bg-primary); }
.bg-secondary { background-color: var(--bg-secondary); }
.bg-tertiary { background-color: var(--bg-tertiary); }
.bg-elevated { background-color: var(--bg-elevated); }

/* Border Radius */
.rounded-xs { border-radius: var(--radius-xs); }
.rounded-sm { border-radius: var(--radius-sm); }
.rounded-md { border-radius: var(--radius-md); }
.rounded-lg { border-radius: var(--radius-lg); }
.rounded-xl { border-radius: var(--radius-xl); }
.rounded-2xl { border-radius: var(--radius-2xl); }
.rounded-3xl { border-radius: var(--radius-3xl); }
.rounded-full { border-radius: var(--radius-full); }

/* Shadows */
.shadow-xs { box-shadow: var(--shadow-xs); }
.shadow-sm { box-shadow: var(--shadow-sm); }
.shadow-md { box-shadow: var(--shadow-md); }
.shadow-lg { box-shadow: var(--shadow-lg); }
.shadow-xl { box-shadow: var(--shadow-xl); }
.shadow-2xl { box-shadow: var(--shadow-2xl); }
.shadow-none { box-shadow: none; }

/* Transitions */
.transition-fast { transition: all var(--transition-fast); }
.transition-base { transition: all var(--transition-base); }
.transition-slow { transition: all var(--transition-slow); }
.transition-bounce { transition: all var(--transition-bounce); }

/* ========================================
   RESPONSIVE BREAKPOINTS
   ======================================== */

@media (max-width: 640px) {
  :root {
    --text-4xl: 1.75rem;
    --text-3xl: 1.5rem;
    --text-2xl: 1.25rem;
  }

  h1 { font-size: var(--text-3xl); }
  h2 { font-size: var(--text-2xl); }
  h3 { font-size: var(--text-xl); }
}

@media (prefers-color-scheme: dark) {
  /* Dark mode support (optional) */
  /* Can be enabled later */
}
