/**
 * Geo-Fin Font Schema
 *
 * Schriften werden lokal aus dem /fonts/ Ordner geladen (GDPR-konform, keine CDNs)
 *
 * Verwendung:
 * - Display/Headlines: Space Grotesk (font-display)
 * - Body/UI: Inter (font-body)
 * - Alternative: DM Sans (font-alt)
 */

/* ========================================
   SPACE GROTESK - Display/Headlines
   ======================================== */

@font-face {
    font-family: 'Space Grotesk';
    src: url('/fonts/SpaceGrotesk/SpaceGrotesk-Light.woff2') format('woff2'),
         url('/fonts/SpaceGrotesk/SpaceGrotesk-Light.woff') format('woff');
    font-weight: 300;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'Space Grotesk';
    src: url('/fonts/SpaceGrotesk/SpaceGrotesk-Regular.woff2') format('woff2'),
         url('/fonts/SpaceGrotesk/SpaceGrotesk-Regular.woff') format('woff');
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'Space Grotesk';
    src: url('/fonts/SpaceGrotesk/SpaceGrotesk-Medium.woff2') format('woff2'),
         url('/fonts/SpaceGrotesk/SpaceGrotesk-Medium.woff') format('woff');
    font-weight: 500;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'Space Grotesk';
    src: url('/fonts/SpaceGrotesk/SpaceGrotesk-SemiBold.woff2') format('woff2'),
         url('/fonts/SpaceGrotesk/SpaceGrotesk-SemiBold.woff') format('woff');
    font-weight: 600;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'Space Grotesk';
    src: url('/fonts/SpaceGrotesk/SpaceGrotesk-Bold.woff2') format('woff2'),
         url('/fonts/SpaceGrotesk/SpaceGrotesk-Bold.woff') format('woff');
    font-weight: 700;
    font-style: normal;
    font-display: swap;
}

/* ========================================
   INTER - Body/UI Text
   ======================================== */

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

@font-face {
    font-family: 'Inter';
    src: url('/fonts/Inter/Inter-Italic.woff2') format('woff2'),
         url('/fonts/Inter/Inter-Italic.woff') format('woff');
    font-weight: 400;
    font-style: italic;
    font-display: swap;
}

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

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

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

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

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

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

/* ========================================
   DM SANS - Alternative UI Font
   ======================================== */

@font-face {
    font-family: 'DM Sans';
    src: url('/fonts/DM_Sans/DMSans-Regular.woff2') format('woff2'),
         url('/fonts/DM_Sans/DMSans-Regular.woff') format('woff');
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'DM Sans';
    src: url('/fonts/DM_Sans/DMSans-Italic.woff2') format('woff2'),
         url('/fonts/DM_Sans/DMSans-Italic.woff') format('woff');
    font-weight: 400;
    font-style: italic;
    font-display: swap;
}

@font-face {
    font-family: 'DM Sans';
    src: url('/fonts/DM_Sans/DMSans-Medium.woff2') format('woff2'),
         url('/fonts/DM_Sans/DMSans-Medium.woff') format('woff');
    font-weight: 500;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'DM Sans';
    src: url('/fonts/DM_Sans/DMSans-MediumItalic.woff2') format('woff2'),
         url('/fonts/DM_Sans/DMSans-MediumItalic.woff') format('woff');
    font-weight: 500;
    font-style: italic;
    font-display: swap;
}

@font-face {
    font-family: 'DM Sans';
    src: url('/fonts/DM_Sans/DMSans-Bold.woff2') format('woff2'),
         url('/fonts/DM_Sans/DMSans-Bold.woff') format('woff');
    font-weight: 700;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'DM Sans';
    src: url('/fonts/DM_Sans/DMSans-BoldItalic.woff2') format('woff2'),
         url('/fonts/DM_Sans/DMSans-BoldItalic.woff') format('woff');
    font-weight: 700;
    font-style: italic;
    font-display: swap;
}

/* ========================================
   CSS CUSTOM PROPERTIES - Font Stack
   ======================================== */

:root {
    /* Font Families */
    --font-display: 'Space Grotesk', system-ui, -apple-system, sans-serif;
    --font-body: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --font-alt: 'DM Sans', system-ui, -apple-system, sans-serif;
    --font-mono: ui-monospace, 'Cascadia Code', 'Source Code Pro', Menlo, Consolas, monospace;

    /* Font Sizes (fluid typography) */
    --text-xs: clamp(0.75rem, 0.7rem + 0.25vw, 0.8125rem);
    --text-sm: clamp(0.8125rem, 0.775rem + 0.1875vw, 0.875rem);
    --text-base: clamp(0.9375rem, 0.9rem + 0.1875vw, 1rem);
    --text-lg: clamp(1.0625rem, 1rem + 0.3125vw, 1.125rem);
    --text-xl: clamp(1.1875rem, 1.1rem + 0.4375vw, 1.25rem);
    --text-2xl: clamp(1.4375rem, 1.3rem + 0.6875vw, 1.5rem);
    --text-3xl: clamp(1.75rem, 1.55rem + 1vw, 1.875rem);
    --text-4xl: clamp(2.0625rem, 1.8rem + 1.3125vw, 2.25rem);
    --text-5xl: clamp(2.75rem, 2.3rem + 2.25vw, 3rem);

    /* Line Heights */
    --leading-none: 1;
    --leading-tight: 1.25;
    --leading-snug: 1.375;
    --leading-normal: 1.5;
    --leading-relaxed: 1.625;
    --leading-loose: 2;

    /* Letter Spacing */
    --tracking-tighter: -0.05em;
    --tracking-tight: -0.025em;
    --tracking-normal: 0em;
    --tracking-wide: 0.025em;
    --tracking-wider: 0.05em;
    --tracking-widest: 0.1em;
}

/* ========================================
   BASE TYPOGRAPHY STYLES
   ======================================== */

body {
    font-family: var(--font-body);
    font-size: var(--text-base);
    line-height: var(--leading-normal);
    font-weight: 400;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
}

/* Headlines use Space Grotesk */
h1, h2, h3, h4, h5, h6,
.font-display {
    font-family: var(--font-display);
    font-weight: 600;
    line-height: var(--leading-tight);
    letter-spacing: var(--tracking-tight);
}

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

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

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

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

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

h6 {
    font-size: var(--text-base);
    font-weight: 600;
}

/* Body text */
.font-body {
    font-family: var(--font-body);
}

/* Alternative font */
.font-alt {
    font-family: var(--font-alt);
}

/* Monospace */
code, pre, kbd, samp,
.font-mono {
    font-family: var(--font-mono);
}

/* ========================================
   UTILITY CLASSES
   ======================================== */

/* Font Weights */
.font-light { font-weight: 300; }
.font-normal { font-weight: 400; }
.font-medium { font-weight: 500; }
.font-semibold { font-weight: 600; }
.font-bold { font-weight: 700; }

/* Font Sizes */
.text-xs { font-size: var(--text-xs); }
.text-sm { font-size: var(--text-sm); }
.text-base { font-size: var(--text-base); }
.text-lg { font-size: var(--text-lg); }
.text-xl { font-size: var(--text-xl); }
.text-2xl { font-size: var(--text-2xl); }
.text-3xl { font-size: var(--text-3xl); }
.text-4xl { font-size: var(--text-4xl); }
.text-5xl { font-size: var(--text-5xl); }

/* Line Heights */
.leading-none { line-height: var(--leading-none); }
.leading-tight { line-height: var(--leading-tight); }
.leading-snug { line-height: var(--leading-snug); }
.leading-normal { line-height: var(--leading-normal); }
.leading-relaxed { line-height: var(--leading-relaxed); }
.leading-loose { line-height: var(--leading-loose); }

/* Letter Spacing */
.tracking-tighter { letter-spacing: var(--tracking-tighter); }
.tracking-tight { letter-spacing: var(--tracking-tight); }
.tracking-normal { letter-spacing: var(--tracking-normal); }
.tracking-wide { letter-spacing: var(--tracking-wide); }
.tracking-wider { letter-spacing: var(--tracking-wider); }
.tracking-widest { letter-spacing: var(--tracking-widest); }
