package de.arxsilex.maptools.converter.desktop

import androidx.compose.material3.MaterialTheme
import androidx.compose.material3.darkColorScheme
import androidx.compose.runtime.Composable
import androidx.compose.ui.graphics.Color

internal val Petrol980 = Color(0xFF020B0E)
internal val Petrol950 = Color(0xFF031014)
internal val Petrol920 = Color(0xFF06191E)
internal val Petrol900 = Color(0xFF08232B)
internal val Petrol860 = Color(0xFF0B3540)
internal val Petrol300 = Color(0xFF8FB9C2)
internal val Petrol220 = Color(0xFFB7D2D9)
internal val Petrol160 = Color(0xFFD6E8EC)
internal val Petrol040 = Color(0xFFF5F8FB)

internal val Moss300 = Color(0xFFAFC8B7)
private val Moss160 = Color(0xFFDCE9E0)
internal val Amber300 = Color(0xFFD8BF7A)
private val Amber160 = Color(0xFFEDE0B8)
internal val Clay200 = Color(0xFFE8B7B1)
private val Ink900 = Color(0xFF152033)

private val MapToolsDarkColorScheme = darkColorScheme(
    primary = Petrol220,
    onPrimary = Petrol950,
    primaryContainer = Petrol860,
    onPrimaryContainer = Petrol160,
    secondary = Moss300,
    onSecondary = Petrol950,
    secondaryContainer = Color(0xFF213B2D),
    onSecondaryContainer = Moss160,
    tertiary = Amber300,
    onTertiary = Petrol950,
    tertiaryContainer = Color(0xFF46391F),
    onTertiaryContainer = Amber160,
    error = Clay200,
    onError = Petrol980,
    errorContainer = Color(0xFF5A211C),
    onErrorContainer = Color(0xFFF6D8D4),
    background = Petrol950,
    onBackground = Color(0xFFF2F7F8),
    surface = Petrol920,
    onSurface = Color(0xFFF2F7F8),
    surfaceVariant = Petrol900,
    onSurfaceVariant = Petrol220,
    surfaceTint = Petrol300,
    outline = Petrol300.copy(alpha = 0.85f),
    outlineVariant = Petrol300.copy(alpha = 0.32f),
    scrim = Color.Black.copy(alpha = 0.6f),
    inverseSurface = Petrol040,
    inverseOnSurface = Ink900,
)

@Composable
internal fun MapToolsConverterTheme(content: @Composable () -> Unit) {
    MaterialTheme(
        colorScheme = MapToolsDarkColorScheme,
        content = content,
    )
}
