/* ==========================================================================
   MoneyPathway Design System
   A calm, trustworthy, human-crafted fintech design system.
   ========================================================================== */

:root {
  /* Color Palette */
  --color-primary: #0f172a;          /* Deep midnight slate */
  --color-primary-light: #1e293b;    /* Slightly lighter navy for headers/subtitles */
  --color-primary-dark: #020617;     /* Darkest navy */
  
  --color-accent: #0f766e;           /* Muted emerald / deep teal */
  --color-accent-hover: #0d635d;     /* Darker hover emerald */
  --color-accent-subtle: #f0fdf4;    /* Very soft green tint for badges & highlights */
  --color-accent-border: #bbf7d0;    /* Soft green border */
  
  --color-bg: #f8fafc;               /* Warm off-white / light slate tint */
  --color-surface: #ffffff;          /* Clean white card surface */
  --color-surface-hover: #f1f5f9;    /* Subtle hover background */
  --color-surface-sunken: #f8fafc;   /* Sunken inputs and backgrounds */
  
  --color-text-main: #0f172a;        /* High-contrast dark charcoal */
  --color-text-body: #334155;        /* Comfortable reading slate */
  --color-text-muted: #64748b;       /* Muted secondary text */
  --color-text-subtle: #94a3b8;      /* Very subtle placeholders & metadata */
  
  --color-border: #e2e8f0;           /* Subtle crisp borders */
  --color-border-hover: #cbd5e1;     /* Interactive border hover */
  --color-border-focus: #0f766e;     /* Focused input outline */
  
  --color-success: #15803d;          /* Subtle green */
  --color-success-bg: #f0fdf4;
  --color-warning: #b45309;          /* Muted amber */
  --color-warning-bg: #fffbeb;
  --color-error: #b91c1c;            /* Restrained red */
  --color-error-bg: #fef2f2;
  
  /* Typography */
  --font-sans: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  --font-mono: 'JetBrains Mono', 'SFMono-Regular', Consolas, 'Liberation Mono', Menlo, monospace;
  
  /* Font Sizes & Line Heights */
  --text-xs: 0.75rem;     /* 12px */
  --text-sm: 0.875rem;    /* 14px */
  --text-base: 1rem;      /* 16px */
  --text-lg: 1.125rem;    /* 18px */
  --text-xl: 1.25rem;     /* 20px */
  --text-2xl: 1.5rem;     /* 24px */
  --text-3xl: 1.875rem;   /* 30px */
  --text-4xl: 2.25rem;    /* 36px */
  --text-5xl: 3rem;       /* 48px */
  
  /* Spacing Scale */
  --space-1: 0.25rem;   /* 4px */
  --space-2: 0.5rem;    /* 8px */
  --space-3: 0.75rem;   /* 12px */
  --space-4: 1rem;      /* 16px */
  --space-5: 1.25rem;   /* 20px */
  --space-6: 1.5rem;    /* 24px */
  --space-8: 2rem;      /* 32px */
  --space-10: 2.5rem;   /* 40px */
  --space-12: 3rem;     /* 48px */
  --space-16: 4rem;     /* 64px */
  --space-20: 5rem;     /* 80px */
  
  /* Border Radii - Restrained, Professional & Human */
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 10px;
  --radius-xl: 12px;
  --radius-full: 9999px;
  
  /* Shadows - Subtle, calm, never cartoonish */
  --shadow-xs: 0 1px 2px rgba(15, 23, 42, 0.04);
  --shadow-sm: 0 1px 3px rgba(15, 23, 42, 0.05), 0 1px 2px rgba(15, 23, 42, 0.03);
  --shadow-md: 0 4px 6px -1px rgba(15, 23, 42, 0.06), 0 2px 4px -2px rgba(15, 23, 42, 0.04);
  --shadow-lg: 0 10px 15px -3px rgba(15, 23, 42, 0.06), 0 4px 6px -4px rgba(15, 23, 42, 0.03);
  --shadow-modal: 0 20px 25px -5px rgba(15, 23, 42, 0.12), 0 8px 10px -6px rgba(15, 23, 42, 0.08);
  
  /* Transitions */
  --transition-fast: 150ms cubic-bezier(0.4, 0, 0.2, 1);
  --transition-normal: 200ms cubic-bezier(0.4, 0, 0.2, 1);
  
  /* Container Widths */
  --container-max: 1200px;
  --container-article: 780px;
}

/* Base Reset & Box Sizing */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-family: var(--font-sans);
  font-size: 16px;
  color: var(--color-text-body);
  background-color: var(--color-bg);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  overflow-x: hidden;
  color: var(--color-text-body);
  background-color: var(--color-bg);
}

/* Headings */
h1, h2, h3, h4, h5, h6 {
  color: var(--color-primary);
  font-weight: 700;
  line-height: 1.25;
  letter-spacing: -0.02em;
}

h1 {
  font-size: var(--text-4xl);
}

h2 {
  font-size: var(--text-2xl);
  margin-bottom: var(--space-3);
}

h3 {
  font-size: var(--text-xl);
  font-weight: 600;
  margin-bottom: var(--space-2);
}

p {
  line-height: 1.65;
  color: var(--color-text-body);
}

a {
  color: var(--color-accent);
  text-decoration: none;
  transition: color var(--transition-fast);
}

a:hover {
  color: var(--color-accent-hover);
}

button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  background: none;
}

input, select, textarea {
  font-family: inherit;
  font-size: inherit;
  color: inherit;
}

ul, ol {
  list-style-position: inside;
}

img, svg {
  vertical-align: middle;
  display: inline-block;
}

/* Standard Container */
.container {
  width: 100%;
  max-width: var(--container-max);
  margin-left: auto;
  margin-right: auto;
  padding-left: var(--space-6);
  padding-right: var(--space-6);
}

@media (max-width: 640px) {
  .container {
    padding-left: var(--space-4);
    padding-right: var(--space-4);
  }
}

/* Utilities */
.text-muted { color: var(--color-text-muted); }
.text-accent { color: var(--color-accent); }
.text-sm { font-size: var(--text-sm); }
.text-xs { font-size: var(--text-xs); }
.font-semibold { font-weight: 600; }
.font-medium { font-weight: 500; }
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border-width: 0;
}
