/* ===== TYPOGRAPHY ===== */
@font-face {
  font-family: 'OpenDyslexic';
  src: url('https://cdn.jsdelivr.net/npm/opendyslexic@2.0.0/fonts/OpenDyslexic-Regular.otf') format('opentype');
}

/* Deklarasi font kustom Minangkabau / Kerisdipa */
@font-face {
  font-family: 'Kerisdipa';
  src: url('../../fonts/Kerisdipa TTF Demo.ttf') format('truetype');
  font-weight: normal;
  font-style: normal;
}

@font-face {
  font-family: 'Minangkabau';
  src: url('../../fonts/Kerisdipa TTF Demo.ttf') format('truetype');
  font-weight: normal;
  font-style: normal;
}

html.font-opendyslexic *:not(.material-symbols-outlined) {
  font-family: 'OpenDyslexic', sans-serif !important;
}
html.font-dyslexie *:not(.material-symbols-outlined) {
  font-family: 'Lexend', sans-serif !important;
}

/* CUSTOM TYPOGRAPHY OVERRIDES */
/* 3. Card Title -> Plus Jakarta Sans (Semi-bold) */
.font-black:not(.text-emerald-800):not(.text-on-surface):not(.text-emerald-900),
.font-extrabold:not(.text-on-surface) {
  /* Convert anything excessively bold in cards to Semi-bold as requested, except titles we explicitly overrode */
  font-weight: 600 !important;
}

/* 5. Summary Numbers / Data -> Bold */
.text-4xl,
.text-3xl {
  font-weight: 700 !important;
}

/* 7. Navbar / Menu -> Medium, active = Kerisdipa */
nav a,
#mobile-nav a,
.nav-item {
  font-weight: 500 !important;
  font-family: 'Plus Jakarta Sans', sans-serif;
}

nav a.text-emerald-700,
#mobile-nav a.text-emerald-700 {
  font-family: 'Minangkabau', sans-serif !important;
}

/* 8. Sidebar & 9. Search Bar -> Plus Jakarta Sans */
.mobile-layer-panel,
input[type="text"],
#search-desktop,
#search-input {
  font-family: 'Plus Jakarta Sans', sans-serif !important;
}

/* 10. Buttons -> Plus Jakarta Sans (Semi-bold) */
button,
.btn,
#nira-fab-btn,
#form-fab,
.mlp-btn {
  font-family: 'Plus Jakarta Sans', sans-serif !important;
  font-weight: 600 !important;
}

/* Ensure Status badges use Plus Jakarta Sans Bold */
.badge,
.status-tinggi,
.status-sedang,
.status-rendah,
.bg-rose-100.text-rose-700,
.bg-amber-100.text-amber-700,
.bg-emerald-100.text-emerald-700 {
  font-family: 'Plus Jakarta Sans', sans-serif !important;
  font-weight: 700 !important;
  letter-spacing: 0.5px;
}
