/**
 * @file typography.css
 * Mukta font, Devanagari-optimized line heights and spacing.
 * Mukta supports full Devanagari script — ideal for Marathi content.
 */

/* ── Global font reset — Mukta everywhere ─────────────────────────────────── */
*,
*::before,
*::after {
  font-family: var(--mp-font-primary);
}

/* Keep monospace for code only */
code, pre, kbd, samp, tt {
  font-family: var(--mp-font-mono) !important;
}

body {
  font-family: var(--mp-font-primary);
  font-size: var(--mp-text-base);
  line-height: var(--mp-leading-normal);
  color: var(--mp-text);
}

/* ── Headings ─────────────────────────────────────────────────────────────── */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--mp-font-primary);
  font-weight: 700;
  line-height: var(--mp-leading-tight);
  letter-spacing: var(--mp-tracking-tight);
  color: var(--mp-secondary);
  margin-top: 0;
  margin-bottom: var(--mp-space-4);
}

h1 { font-size: var(--mp-text-3xl); }
h2 { font-size: var(--mp-text-2xl); }
h3 { font-size: var(--mp-text-xl); }
h4 { font-size: var(--mp-text-lg); }
h5 { font-size: var(--mp-text-base); font-weight: 600; }
h6 { font-size: var(--mp-text-sm);  font-weight: 600; }

@media (max-width: 767.98px) {
  h1 { font-size: var(--mp-text-2xl); }
  h2 { font-size: var(--mp-text-xl); }
  h3 { font-size: var(--mp-text-lg); }
}

/* ── Body Text ────────────────────────────────────────────────────────────── */
p {
  margin-top: 0;
  margin-bottom: var(--mp-space-4);
  line-height: var(--mp-leading-relaxed);   /* Extra generous for Devanagari */
}

/* ── Links ────────────────────────────────────────────────────────────────── */
a {
  color: var(--mp-text-link);
  text-decoration: none;
  transition: color var(--mp-transition-fast);
}

a:hover {
  color: var(--mp-text-link-hover);
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* ── Devanagari-Specific Fixes ───────────────────────────────────────────── */
/* Mukta renders Devanagari well, but these tweaks improve legibility */
:lang(mr),
:lang(hi) {
  font-family: var(--mp-font-primary);
  line-height: var(--mp-leading-relaxed);   /* Matras need vertical breathing room */
  word-spacing: 0.05em;
}

/* Node titles in Devanagari */
.node__title a,
.views-field-title a {
  font-weight: 600;
  color: var(--mp-secondary);
}

.node__title a:hover,
.views-field-title a:hover {
  color: var(--mp-primary);
}

/* ── Blockquote ───────────────────────────────────────────────────────────── */
blockquote {
  border-left: 4px solid var(--mp-primary);
  margin: var(--mp-space-6) 0;
  padding: var(--mp-space-4) var(--mp-space-6);
  background: var(--mp-primary-50);
  border-radius: 0 var(--mp-radius) var(--mp-radius) 0;
  color: var(--mp-secondary);
  font-style: italic;
}

/* ── Code ─────────────────────────────────────────────────────────────────── */
code, pre {
  font-family: var(--mp-font-mono);
  font-size: 0.9em;
  background: var(--mp-bg-alt);
  border: 1px solid var(--mp-border);
  border-radius: var(--mp-radius-sm);
}

code { padding: 0.1em 0.4em; }
pre  { padding: var(--mp-space-4); overflow-x: auto; }

/* ── Horizontal Rule ──────────────────────────────────────────────────────── */
hr {
  border: none;
  border-top: 1px solid var(--mp-border);
  margin: var(--mp-space-8) 0;
}
