/**
 * fonts.css — Self-Hosted High Performance Typography (Task 0.1)
 * All fonts are served locally as WOFF2 from /public/assets/fonts/
 * with font-display: swap and metric-matched fallback overrides.
 */

/* ==========================================================================
   1. Inter (UI, Navigation, Buttons, Inputs, Labels, Body Text)
   ========================================================================== */
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('../fonts/inter-normal-400.woff2') format('woff2');
}

@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('../fonts/inter-normal-500.woff2') format('woff2');
}

@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url('../fonts/inter-normal-600.woff2') format('woff2');
}

@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('../fonts/inter-normal-700.woff2') format('woff2');
}

/* ==========================================================================
   2. Cormorant Garamond (Editorial Display Serif for H1, H2, H3, Titles)
   ========================================================================== */
@font-face {
  font-family: 'Cormorant Garamond';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('../fonts/cormorant-garamond-normal-400.woff2') format('woff2');
}

@font-face {
  font-family: 'Cormorant Garamond';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('../fonts/cormorant-garamond-normal-500.woff2') format('woff2');
}

@font-face {
  font-family: 'Cormorant Garamond';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url('../fonts/cormorant-garamond-normal-600.woff2') format('woff2');
}

@font-face {
  font-family: 'Cormorant Garamond';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('../fonts/cormorant-garamond-normal-700.woff2') format('woff2');
}

@font-face {
  font-family: 'Cormorant Garamond';
  font-style: italic;
  font-weight: 500;
  font-display: swap;
  src: url('../fonts/cormorant-garamond-italic-500.woff2') format('woff2');
}

@font-face {
  font-family: 'Cormorant Garamond';
  font-style: italic;
  font-weight: 600;
  font-display: swap;
  src: url('../fonts/cormorant-garamond-italic-600.woff2') format('woff2');
}

/* ==========================================================================
   3. Noto Serif Tamil (Authentic Tamil Script Typography)
   ========================================================================== */
@font-face {
  font-family: 'Noto Serif Tamil';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('../fonts/noto-serif-tamil-normal-400.woff2') format('woff2');
}

@font-face {
  font-family: 'Noto Serif Tamil';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('../fonts/noto-serif-tamil-normal-500.woff2') format('woff2');
}

@font-face {
  font-family: 'Noto Serif Tamil';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url('../fonts/noto-serif-tamil-normal-600.woff2') format('woff2');
}

@font-face {
  font-family: 'Noto Serif Tamil';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('../fonts/noto-serif-tamil-normal-700.woff2') format('woff2');
}

/* ==========================================================================
   4. Metric-Matched Fallback Stacks to Eliminate Layout Shifts (CLS)
   ========================================================================== */
@font-face {
  font-family: 'Inter-Fallback';
  src: local('Arial'), local('Helvetica');
  ascent-override: 90%;
  descent-override: 22%;
  line-gap-override: 0%;
  size-adjust: 100%;
}

@font-face {
  font-family: 'Serif-Fallback';
  src: local('Georgia'), local('Times New Roman');
  ascent-override: 92%;
  descent-override: 24%;
  line-gap-override: 0%;
  size-adjust: 102%;
}
