/* Typography System v2 - Elegant Editorial Style */

body {
  font-family: var(--font-body);
  font-size: var(--text-base);
  font-weight: var(--weight-normal);
  line-height: var(--leading-relaxed);
  color: var(--color-text);
  background-color: var(--color-bg);
  font-feature-settings: 'kern' 1, 'liga' 1;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Headings - Elegant Serif Display */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  font-weight: var(--weight-medium);
  line-height: var(--leading-tight);
  letter-spacing: var(--tracking-tight);
  color: var(--color-text);
  text-wrap: balance;
}

h1 {
  font-size: var(--text-6xl);
  font-weight: var(--weight-normal);
  line-height: 1.05;
  letter-spacing: -0.03em;
}

h2 {
  font-size: var(--text-5xl);
  font-weight: var(--weight-normal);
  line-height: 1.1;
}

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

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

h5 {
  font-size: var(--text-2xl);
}

h6 {
  font-size: var(--text-xl);
  font-family: var(--font-body);
  font-weight: var(--weight-semibold);
}

/* Display Headlines */
.display-hero {
  font-size: var(--text-7xl);
  font-weight: var(--weight-normal);
  line-height: 1;
  letter-spacing: -0.04em;
}

.display-lg {
  font-size: var(--text-6xl);
  font-weight: var(--weight-normal);
  line-height: 1.05;
}

/* Lead / Intro Text */
.lead {
  font-size: var(--text-xl);
  line-height: var(--leading-relaxed);
  color: var(--color-text-secondary);
}

.lead-lg {
  font-size: clamp(1.25rem, 1rem + 1.25vw, 1.5rem);
  line-height: var(--leading-relaxed);
  color: var(--color-text-secondary);
}

/* Body Text Variants */
.text-lg { font-size: var(--text-lg); }
.text-sm { font-size: var(--text-sm); }
.text-xs { font-size: var(--text-xs); }

/* Eyebrow / Overline */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  font-family: var(--font-body);
  font-size: var(--text-sm);
  font-weight: var(--weight-medium);
  letter-spacing: var(--tracking-wide);
  text-transform: uppercase;
  color: var(--color-primary);
}

.eyebrow::before {
  content: '';
  display: inline-block;
  width: 24px;
  height: 2px;
  background: var(--color-accent);
  border-radius: var(--radius-full);
}

/* Label */
.label {
  font-family: var(--font-body);
  font-size: var(--text-xs);
  font-weight: var(--weight-medium);
  letter-spacing: var(--tracking-wider);
  text-transform: uppercase;
  color: var(--color-text-muted);
}

/* Italic Accent (for serif emphasis) */
.accent-text {
  font-family: var(--font-display);
  font-style: italic;
  font-weight: var(--weight-normal);
}

/* Highlighted text */
.highlight {
  background: linear-gradient(120deg, var(--color-peach-light) 0%, var(--color-peach-light) 100%);
  background-repeat: no-repeat;
  background-size: 100% 40%;
  background-position: 0 90%;
}

.highlight-blue {
  background: linear-gradient(120deg, var(--color-sky) 0%, var(--color-sky) 100%);
  background-repeat: no-repeat;
  background-size: 100% 40%;
  background-position: 0 90%;
}

/* Gradient Text */
.gradient-text {
  background: linear-gradient(135deg, var(--color-trust-blue) 0%, var(--color-coral) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* Code / Mono */
code, .mono {
  font-family: var(--font-mono);
  font-size: 0.9em;
}

code {
  background: var(--color-surface-hover);
  padding: 0.15em 0.4em;
  border-radius: var(--radius-sm);
}

/* Links */
a {
  color: var(--color-primary);
  text-decoration: none;
  transition: color var(--duration-fast) var(--ease-out);
}

a:hover {
  color: var(--color-primary-soft);
}

.link-underline {
  color: var(--color-text);
  text-decoration: underline;
  text-decoration-color: var(--color-border-warm);
  text-underline-offset: 4px;
  text-decoration-thickness: 1px;
  transition: text-decoration-color var(--duration-fast) var(--ease-out);
}

.link-underline:hover {
  text-decoration-color: var(--color-accent);
}

/* Arrow link */
.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  font-weight: var(--weight-medium);
  color: var(--color-text);
  transition: gap var(--duration-base) var(--ease-out);
}

.link-arrow svg {
  transition: transform var(--duration-base) var(--ease-out);
}

.link-arrow:hover {
  gap: var(--space-3);
  color: var(--color-primary);
}

.link-arrow:hover svg {
  transform: translateX(4px);
}

/* Text Colors */
.text-primary { color: var(--color-primary); }
.text-secondary { color: var(--color-text-secondary); }
.text-muted { color: var(--color-text-muted); }
.text-accent { color: var(--color-accent); }
.text-success { color: var(--color-success); }
.text-white { color: var(--color-white); }

/* Text Alignment */
.text-left { text-align: left; }
.text-center { text-align: center; }
.text-right { text-align: right; }

/* Font Weights */
.font-normal { font-weight: var(--weight-normal); }
.font-medium { font-weight: var(--weight-medium); }
.font-semibold { font-weight: var(--weight-semibold); }
.font-bold { font-weight: var(--weight-bold); }

/* Prose Container */
.prose {
  max-width: 65ch;
}

.prose > * + * {
  margin-top: var(--space-4);
}

.prose h2 {
  margin-top: var(--space-12);
  margin-bottom: var(--space-4);
}

.prose h3 {
  margin-top: var(--space-8);
  margin-bottom: var(--space-3);
}

.prose ul, .prose ol {
  padding-left: var(--space-6);
}

.prose li {
  margin-bottom: var(--space-2);
}

.prose ul li { list-style-type: disc; }
.prose ol li { list-style-type: decimal; }

/* Blockquote */
.prose blockquote {
  padding-left: var(--space-6);
  border-left: 3px solid var(--color-accent);
  font-family: var(--font-display);
  font-size: var(--text-xl);
  font-style: italic;
  color: var(--color-text-secondary);
}

/* Selection */
::selection {
  background: var(--color-peach);
  color: var(--color-charcoal);
}

/* Number styling */
.number-display {
  font-family: var(--font-display);
  font-size: var(--text-5xl);
  font-weight: var(--weight-medium);
  line-height: 1;
  color: var(--color-primary);
}

.number-stat {
  font-family: var(--font-body);
  font-size: var(--text-4xl);
  font-weight: var(--weight-bold);
  color: var(--color-text);
}
