package dev.kaizen.app.ui.theme

import androidx.compose.material3.Typography
import androidx.compose.ui.text.TextStyle
import androidx.compose.ui.text.font.Font
import androidx.compose.ui.text.font.FontFamily
import androidx.compose.ui.text.font.FontVariation
import androidx.compose.ui.text.font.FontWeight
import androidx.compose.ui.unit.sp
import dev.kaizen.app.R

@OptIn(androidx.compose.ui.text.ExperimentalTextApi::class)
val InterVariable = FontFamily(
    Font(
        R.font.inter_variable,
        weight = FontWeight.W100,
        variationSettings = FontVariation.Settings(FontVariation.weight(100)),
    ),
    Font(
        R.font.inter_variable,
        weight = FontWeight.W200,
        variationSettings = FontVariation.Settings(FontVariation.weight(200)),
    ),
    Font(
        R.font.inter_variable,
        weight = FontWeight.W300,
        variationSettings = FontVariation.Settings(FontVariation.weight(300)),
    ),
    Font(
        R.font.inter_variable,
        weight = FontWeight.W400,
        variationSettings = FontVariation.Settings(FontVariation.weight(400)),
    ),
    Font(
        R.font.inter_variable,
        weight = FontWeight.W500,
        variationSettings = FontVariation.Settings(FontVariation.weight(500)),
    ),
    Font(
        R.font.inter_variable,
        weight = FontWeight.W600,
        variationSettings = FontVariation.Settings(FontVariation.weight(600)),
    ),
    Font(
        R.font.inter_variable,
        weight = FontWeight.W700,
        variationSettings = FontVariation.Settings(FontVariation.weight(700)),
    ),
    Font(
        R.font.inter_variable,
        weight = FontWeight.W800,
        variationSettings = FontVariation.Settings(FontVariation.weight(800)),
    ),
    Font(
        R.font.inter_variable,
        weight = FontWeight.W900,
        variationSettings = FontVariation.Settings(FontVariation.weight(900)),
    ),
)

val Typography = Typography(
    displayLarge = TextStyle(
        fontFamily = InterVariable,
        fontWeight = FontWeight.W600,
        fontSize = 32.sp,
        lineHeight = 38.sp,
        letterSpacing = (-0.32).sp,
    ),
    displayMedium = TextStyle(
        fontFamily = InterVariable,
        fontWeight = FontWeight.W600,
        fontSize = 24.sp,
        lineHeight = 30.sp,
        letterSpacing = (-0.12).sp,
    ),
    titleLarge = TextStyle(
        fontFamily = InterVariable,
        fontWeight = FontWeight.W600,
        fontSize = 20.sp,
        lineHeight = 26.sp,
    ),
    titleMedium = TextStyle(
        fontFamily = InterVariable,
        fontWeight = FontWeight.W500,
        fontSize = 16.sp,
        lineHeight = 22.sp,
        letterSpacing = 0.05.sp,
    ),
    bodyLarge = TextStyle(
        fontFamily = InterVariable,
        fontWeight = FontWeight.W300,
        fontSize = 16.sp,
        lineHeight = 24.sp,
        letterSpacing = 0.08.sp,
    ),
    bodyMedium = TextStyle(
        fontFamily = InterVariable,
        fontWeight = FontWeight.W300,
        fontSize = 14.sp,
        lineHeight = 20.sp,
        letterSpacing = 0.11.sp,
    ),
    labelLarge = TextStyle(
        fontFamily = InterVariable,
        fontWeight = FontWeight.W500,
        fontSize = 14.sp,
        lineHeight = 20.sp,
        letterSpacing = 0.14.sp,
    ),
    labelMedium = TextStyle(
        fontFamily = InterVariable,
        fontWeight = FontWeight.W500,
        fontSize = 12.sp,
        lineHeight = 16.sp,
        letterSpacing = 0.24.sp,
    ),
    labelSmall = TextStyle(
        fontFamily = InterVariable,
        fontWeight = FontWeight.W500,
        fontSize = 11.sp,
        lineHeight = 16.sp,
        letterSpacing = 0.33.sp,
    ),
)
