/* ==========================================================================
   Premium Healthcare-Tech Color System
   Primary brand: #193158 (soft navy)
   Load before styles.css
   ========================================================================== */

:root {
  /* --- Brand scale (#193158 base) --- */
  --brand-50: #f4f7fb;
  --brand-100: #e8eef5;
  --brand-200: #d4dde8;
  --brand-300: #b0c0d4;
  --brand-400: #7a96b5;
  --brand-500: #4a6f94;
  --brand-600: #2e5a8a;
  --brand-700: #234670;
  --brand-800: #193158;
  --brand-900: #12233d;
  --brand-950: #0c1929;

  /* --- Semantic aliases --- */
  --color-primary: var(--brand-800);
  --color-primary-hover: var(--brand-700);
  --color-primary-active: var(--brand-900);
  --color-primary-light: var(--brand-100);
  --color-primary-lighter: var(--brand-50);
  --color-primary-dark: var(--brand-900);
  --color-primary-muted: var(--brand-500);

  --color-accent: #4a8ba8;
  --color-accent-hover: #3d7a95;
  --color-accent-light: #e6f1f6;
  --color-accent-muted: #9ec4d4;

  /* --- 1. Main backgrounds (soft, no harsh white) --- */
  --color-white: #fafbfd;
  --color-bg-main: #f7f9fc;
  --color-bg-soft: #f3f6fa;
  --color-bg-alt: #eef2f7;
  --color-bg-elevated: #fcfdfe;
  --color-bg-mist: #e6ecf3;

  /* --- 2. Alternate section backgrounds --- */
  --section-a: #f7f9fc;
  --section-b: #eef2f7;
  --section-c: #f3f6fa;
  --section-d: #e8eef5;
  --section-e: #f5f8fb;

  /* --- 3. Card backgrounds + glass --- */
  --color-card: rgba(252, 253, 254, 0.88);
  --color-card-solid: #fcfdfe;
  --color-card-hover: #ffffff;
  --glass-bg: rgba(252, 253, 254, 0.72);
  --glass-bg-strong: rgba(252, 253, 254, 0.9);
  --glass-border: rgba(255, 255, 255, 0.55);
  --glass-blur: 14px;

  /* --- 4. Borders --- */
  --color-border: #d4dde8;
  --color-border-light: #e8edf3;
  --color-border-muted: #c5d0df;
  --color-border-focus: var(--brand-600);
  --color-border-on-dark: rgba(255, 255, 255, 0.12);

  /* --- 5. Hover surfaces --- */
  --color-hover-surface: #e8eef5;
  --color-hover-surface-strong: #dce4ee;
  --color-hover-link: var(--brand-700);
  --color-hover-nav: var(--brand-800);

  /* --- 8. Text (WCAG-friendly on soft backgrounds) --- */
  --color-text: #1a2b42;
  --color-text-soft: #3d4f63;
  --color-text-light: #5c6b7d;
  --color-text-muted: #7a8a9c;
  --color-text-inverse: #f4f7fb;
  --color-text-on-primary: #f5f8fc;
  --color-text-on-accent: #f5f8fc;

  /* --- 9. CTA section --- */
  --cta-bg-start: #e8eef5;
  --cta-bg-end: #dce8f2;
  --cta-overlay: linear-gradient(
    135deg,
    rgba(25, 49, 88, 0.06) 0%,
    rgba(74, 139, 168, 0.08) 100%
  );
  --cta-panel-bg: linear-gradient(135deg, var(--brand-800) 0%, var(--brand-700) 100%);
  --cta-title: var(--color-text);
  --cta-text: var(--color-text-soft);

  /* --- 10. Footer --- */
  --footer-bg: var(--brand-950);
  --footer-bg-alt: var(--brand-900);
  --footer-text: rgba(244, 247, 251, 0.9);
  --footer-text-muted: rgba(244, 247, 251, 0.68);
  --footer-link-hover: #b8cfe0;
  --footer-border: rgba(255, 255, 255, 0.1);

  /* --- Gradients --- */
  --gradient-hero: linear-gradient(
    145deg,
    #f0f4f9 0%,
    #e8eef5 42%,
    #f7f9fc 100%
  );
  --gradient-hero-overlay: linear-gradient(
    135deg,
    rgba(247, 249, 252, 0.92) 0%,
    rgba(232, 238, 245, 0.88) 55%,
    rgba(212, 221, 232, 0.35) 100%
  );
  --gradient-section-soft: linear-gradient(180deg, #f7f9fc 0%, #eef2f7 100%);
  --gradient-section-warm: linear-gradient(
    160deg,
    #f5f8fb 0%,
    #eef2f7 50%,
    #e8eef5 100%
  );
  --gradient-brand: linear-gradient(135deg, #193158 0%, #234670 50%, #2e5a8a 100%);
  --gradient-brand-soft: linear-gradient(
    135deg,
    rgba(25, 49, 88, 0.08) 0%,
    rgba(74, 139, 168, 0.06) 100%
  );
  --gradient-card-shine: linear-gradient(
    145deg,
    rgba(255, 255, 255, 0.9) 0%,
    rgba(248, 250, 253, 0.6) 100%
  );
  --gradient-cta-band: linear-gradient(
    120deg,
    #dce8f2 0%,
    #e8eef5 45%,
    #f0f4f9 100%
  );
  --gradient-footer: linear-gradient(180deg, #12233d 0%, #0c1929 100%);

  /* --- Shadows (navy-tinted, soft) --- */
  --shadow-xs: 0 1px 2px rgba(25, 49, 88, 0.04);
  --shadow-sm: 0 2px 10px rgba(25, 49, 88, 0.06);
  --shadow-md: 0 6px 24px rgba(25, 49, 88, 0.08);
  --shadow-lg: 0 14px 40px rgba(25, 49, 88, 0.1);
  --shadow-xl: 0 24px 56px rgba(25, 49, 88, 0.12);
  --shadow-card: 0 4px 20px rgba(25, 49, 88, 0.06);
  --shadow-card-hover: 0 12px 32px rgba(25, 49, 88, 0.1);
  --shadow-inset-soft: inset 0 1px 0 rgba(255, 255, 255, 0.8);
  --shadow-btn: 0 4px 14px rgba(25, 49, 88, 0.22);
  --shadow-btn-hover: 0 8px 22px rgba(25, 49, 88, 0.28);

  /* --- Radius & motion --- */
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 18px;
  --radius-xl: 24px;
  --radius-pill: 999px;
  --transition: 0.22s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-slow: 0.35s cubic-bezier(0.4, 0, 0.2, 1);
  --ease-premium: cubic-bezier(0.25, 0.8, 0.25, 1);

  /* --- Layout --- */
  --font-primary: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
    "Helvetica Neue", Arial, sans-serif;
  --font-heading: var(--font-primary);
  --container-max: 1200px;
  --header-height: 80px;
  --header-top-height: 2.25rem;
}

/* ==========================================================================
   Section background utilities (long-scroll rhythm)
   ========================================================================== */
.section-bg-a {
  background-color: var(--section-a);
}
.section-bg-b {
  background-color: var(--section-b);
}
.section-bg-c {
  background-color: var(--section-c);
}
.section-bg-d {
  background-color: var(--section-d);
}
.section-bg-e {
  background-color: var(--section-e);
}

.section-gradient-soft {
  background: var(--gradient-section-soft);
}
.section-gradient-warm {
  background: var(--gradient-section-warm);
}
.section-gradient-brand-soft {
  background: var(--gradient-brand-soft);
}

/* Example combinations for alternating pages */
.section-flow-1 {
  background: var(--section-a);
}
.section-flow-2 {
  background: var(--gradient-section-soft);
}
.section-flow-3 {
  background: var(--section-b);
}
.section-flow-4 {
  background: var(--section-c);
}
.section-flow-cta {
  background: var(--gradient-cta-band);
}

/* ==========================================================================
   Glass cards
   ========================================================================== */
.card-glass {
  background: var(--glass-bg);
  backdrop-filter: blur(var(--glass-blur));
  -webkit-backdrop-filter: blur(var(--glass-blur));
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card), var(--shadow-inset-soft);
  transition: transform var(--transition), box-shadow var(--transition),
    background var(--transition);
}

.card-glass:hover {
  background: var(--glass-bg-strong);
  box-shadow: var(--shadow-card-hover);
  transform: translateY(-2px);
}

.card-solid {
  background: var(--color-card-solid);
  border: 1px solid var(--color-border-light);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
  transition: box-shadow var(--transition), border-color var(--transition);
}

.card-solid:hover {
  border-color: var(--color-border);
  box-shadow: var(--shadow-card-hover);
}

/* ==========================================================================
   6–7. Buttons + hover animations
   ========================================================================== */
.btn-theme-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.75rem 1.5rem;
  border-radius: var(--radius-pill);
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--color-text-on-primary);
  background: var(--gradient-brand);
  border: 1px solid transparent;
  box-shadow: var(--shadow-btn);
  text-decoration: none;
  cursor: pointer;
  transition: transform var(--transition), box-shadow var(--transition),
    filter var(--transition), background var(--transition);
}

.btn-theme-primary:hover,
.btn-theme-primary:focus-visible {
  transform: translateY(-2px);
  box-shadow: var(--shadow-btn-hover);
  filter: brightness(1.06);
  text-decoration: none;
  color: var(--color-text-on-primary);
}

.btn-theme-primary:active {
  transform: translateY(0);
  box-shadow: var(--shadow-sm);
}

.btn-theme-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.75rem 1.5rem;
  border-radius: var(--radius-pill);
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--brand-800);
  background: var(--color-card-solid);
  border: 1.5px solid var(--color-border-muted);
  box-shadow: var(--shadow-xs);
  text-decoration: none;
  transition: transform var(--transition), border-color var(--transition),
    background var(--transition), box-shadow var(--transition);
}

.btn-theme-secondary:hover,
.btn-theme-secondary:focus-visible {
  transform: translateY(-2px);
  background: var(--color-hover-surface);
  border-color: var(--brand-600);
  box-shadow: var(--shadow-sm);
  text-decoration: none;
  color: var(--brand-800);
}

.btn-theme-outline {
  background: transparent;
  color: var(--brand-800);
  border: 1.5px solid var(--brand-800);
  border-radius: var(--radius-pill);
  padding: 0.75rem 1.5rem;
  font-weight: 600;
  transition: transform var(--transition), background var(--transition),
    color var(--transition);
}

.btn-theme-outline:hover,
.btn-theme-outline:focus-visible {
  background: var(--brand-800);
  color: var(--color-text-on-primary);
  transform: translateY(-1px);
  text-decoration: none;
}

.btn-theme-ghost {
  background: rgba(25, 49, 88, 0.06);
  color: var(--brand-800);
  border-radius: var(--radius-pill);
  padding: 0.65rem 1.25rem;
  transition: background var(--transition);
}

.btn-theme-ghost:hover {
  background: rgba(25, 49, 88, 0.12);
}

/* ==========================================================================
   CTA + Footer blocks
   ========================================================================== */
.cta-panel-premium {
  background: var(--cta-panel-bg);
  color: var(--color-text-on-primary);
  border-radius: var(--radius-xl);
  padding: 2.5rem 2rem;
  box-shadow: var(--shadow-lg);
}

.footer-theme {
  background: var(--gradient-footer);
  color: var(--footer-text);
  border-top: 1px solid var(--footer-border);
}

.footer-theme a {
  color: var(--footer-text);
}

.footer-theme a:hover {
  color: var(--footer-link-hover);
}

/* ==========================================================================
   Modern gradient showcase (utility classes)
   ========================================================================== */
.gradient-hero-bg {
  background: var(--gradient-hero);
}
.gradient-brand-bar {
  background: var(--gradient-brand);
  color: var(--color-text-on-primary);
}
.gradient-mesh-soft {
  background: radial-gradient(
      ellipse 80% 50% at 20% 40%,
      rgba(74, 139, 168, 0.12),
      transparent 70%
    ),
    radial-gradient(
      ellipse 60% 40% at 80% 20%,
      rgba(25, 49, 88, 0.08),
      transparent 65%
    ),
    var(--color-bg-main);
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  .btn-theme-primary,
  .btn-theme-secondary,
  .card-glass {
    transition: none;
  }
  .btn-theme-primary:hover,
  .btn-theme-secondary:hover,
  .card-glass:hover {
    transform: none;
  }
}

/* ==========================================================================
   TAILWIND CONFIG SUGGESTION (paste into tailwind.config.js theme.extend)
   ==========================================================================
   colors: {
     brand: {
       50:  '#f4f7fb',
       100: '#e8eef5',
       200: '#d4dde8',
       300: '#b0c0d4',
       400: '#7a96b5',
       500: '#4a6f94',
       600: '#2e5a8a',
       700: '#234670',
       800: '#193158',
       900: '#12233d',
       950: '#0c1929',
     },
     surface: {
       DEFAULT: '#f7f9fc',
       soft: '#f3f6fa',
       alt: '#eef2f7',
       mist: '#e6ecf3',
       card: '#fcfdfe',
     },
     ink: {
       DEFAULT: '#1a2b42',
       soft: '#3d4f63',
       muted: '#7a8a9c',
     },
     accent: {
       DEFAULT: '#4a8ba8',
       light: '#e6f1f6',
     },
   },
   boxShadow: {
     'soft-sm': '0 2px 10px rgba(25, 49, 88, 0.06)',
     'soft-md': '0 6px 24px rgba(25, 49, 88, 0.08)',
     'soft-lg': '0 14px 40px rgba(25, 49, 88, 0.1)',
     'brand': '0 4px 14px rgba(25, 49, 88, 0.22)',
   },
   backgroundImage: {
     'hero-gradient': 'linear-gradient(145deg, #f0f4f9 0%, #e8eef5 42%, #f7f9fc 100%)',
     'brand-gradient': 'linear-gradient(135deg, #193158 0%, #234670 50%, #2e5a8a 100%)',
     'section-gradient': 'linear-gradient(180deg, #f7f9fc 0%, #eef2f7 100%)',
   },
   ========================================================================== */
