<resources xmlns:tools="http://schemas.android.com/tools">
    <style name="AppTheme" parent="Theme.Material3.DayNight.NoActionBar">
        <item name="colorPrimary">@color/md_theme_primary</item>
        <item name="colorOnPrimary">@color/md_theme_onPrimary</item>
        <item name="colorPrimaryContainer">@color/md_theme_primaryContainer</item>
        <item name="colorOnPrimaryContainer">@color/md_theme_onPrimaryContainer</item>
        <item name="colorSecondary">@color/md_theme_secondary</item>
        <item name="colorOnSecondary">@color/md_theme_onSecondary</item>
        <item name="colorSecondaryContainer">@color/md_theme_secondaryContainer</item>
        <item name="colorOnSecondaryContainer">@color/md_theme_onSecondaryContainer</item>
        <item name="colorTertiary">@color/md_theme_tertiary</item>
        <item name="colorOnTertiary">@color/md_theme_onTertiary</item>
        <item name="colorTertiaryContainer">@color/md_theme_tertiaryContainer</item>
        <item name="colorOnTertiaryContainer">@color/md_theme_onTertiaryContainer</item>
        <item name="colorError">@color/md_theme_error</item>
        <item name="colorOnError">@color/md_theme_onError</item>
        <item name="colorErrorContainer">@color/md_theme_errorContainer</item>
        <item name="colorOnErrorContainer">@color/md_theme_onErrorContainer</item>
        <item name="android:colorBackground">@color/md_theme_background</item>
        <item name="colorOnBackground">@color/md_theme_onBackground</item>
        <item name="colorSurface">@color/md_theme_surface</item>
        <item name="colorOnSurface">@color/md_theme_onSurface</item>
        <item name="colorSurfaceVariant">@color/md_theme_surfaceVariant</item>
        <item name="colorOnSurfaceVariant">@color/md_theme_onSurfaceVariant</item>
        <item name="colorOutline">@color/md_theme_outline</item>
        <item name="colorOutlineVariant">@color/md_theme_outlineVariant</item>
        <item name="colorSurfaceInverse">@color/md_theme_inverseSurface</item>
        <item name="colorOnSurfaceInverse">@color/md_theme_inverseOnSurface</item>
        <item name="colorPrimaryInverse">@color/md_theme_inversePrimary</item>
        <item name="colorPrimaryFixed">@color/md_theme_primaryFixed</item>
        <item name="colorOnPrimaryFixed">@color/md_theme_onPrimaryFixed</item>
        <item name="colorPrimaryFixedDim">@color/md_theme_primaryFixedDim</item>
        <item name="colorOnPrimaryFixedVariant">@color/md_theme_onPrimaryFixedVariant</item>
        <item name="colorSecondaryFixed">@color/md_theme_secondaryFixed</item>
        <item name="colorOnSecondaryFixed">@color/md_theme_onSecondaryFixed</item>
        <item name="colorSecondaryFixedDim">@color/md_theme_secondaryFixedDim</item>
        <item name="colorOnSecondaryFixedVariant">@color/md_theme_onSecondaryFixedVariant</item>
        <item name="colorTertiaryFixed">@color/md_theme_tertiaryFixed</item>
        <item name="colorOnTertiaryFixed">@color/md_theme_onTertiaryFixed</item>
        <item name="colorTertiaryFixedDim">@color/md_theme_tertiaryFixedDim</item>
        <item name="colorOnTertiaryFixedVariant">@color/md_theme_onTertiaryFixedVariant</item>
        <item name="colorSurfaceDim">@color/md_theme_surfaceDim</item>
        <item name="colorSurfaceBright">@color/md_theme_surfaceBright</item>
        <item name="colorSurfaceContainerLowest">@color/md_theme_surfaceContainerLowest</item>
        <item name="colorSurfaceContainerLow">@color/md_theme_surfaceContainerLow</item>
        <item name="colorSurfaceContainer">@color/md_theme_surfaceContainer</item>
        <item name="colorSurfaceContainerHigh">@color/md_theme_surfaceContainerHigh</item>
        <item name="colorSurfaceContainerHighest">@color/md_theme_surfaceContainerHighest</item>

        <item name="switchPreferenceCompatStyle">@style/MaterialSwitch</item>
        <item name="windowActionModeOverlay">true</item>
        <item name="searchViewStyle">@style/AppSearchViewStyle</item>

        <item name="actionModeStyle">@style/ActionMode</item>
        <item name="actionModeCloseButtonStyle">@style/ActionModeCloseButtonStyle</item>
        <item name="actionOverflowButtonStyle">@style/OverflowButtonStyle</item>
    </style>

    <style name="OverflowButtonStyle" parent="Widget.AppCompat.ActionButton.Overflow" />

    <!-- SearchView style without the hint icon -->
    <style name="AppSearchViewStyle" parent="Widget.AppCompat.SearchView.ActionBar">
        <item name="searchHintIcon">@null</item>
    </style>

    <style name="DangerText" parent="@android:style/TextAppearance">
        <item name="android:textColor">?attr/colorError</item>
    </style>

    <style name="FloatingActionButton" parent="@style/Widget.Material3.FloatingActionButton.Primary">
        <item name="backgroundTint">?attr/colorPrimary</item>
        <item name="tint">?attr/colorOnPrimary</item>
    </style>

    <style name="CardView" parent="@style/Widget.Material3.CardView.Elevated" />

    <style name="CardViewBackground" />

    <!-- Rounded corners in images, see https://stackoverflow.com/a/61960983/1440785 -->
    <style name="roundedCornersImageView" parent="">
        <item name="cornerFamily">rounded</item>
        <item name="cornerSize">5dp</item>
    </style>

    <!-- Material Design 3 switches in the preferences -->
    <style name="MaterialSwitch" parent="@style/Preference.SwitchPreferenceCompat.Material">
        <item name="widgetLayout">@layout/view_preference_switch</item>
    </style>

    <!-- Action mode colors -->
    <style name="ActionMode" parent="@style/Widget.AppCompat.ActionMode">
        <item name="background">?attr/colorPrimary</item>
        <item name="titleTextStyle">@style/ActionModeTitle</item>
    </style>

    <style name="ActionModeTitle" parent="@style/TextAppearance.AppCompat.Widget.ActionMode.Title">
        <item name="android:textColor">?attr/colorOnPrimary</item>
    </style>

    <style name="ActionModeCloseButtonStyle" parent="Widget.AppCompat.ActionButton.CloseMode">
        <item name="android:tint">@android:color/white</item>
    </style>

    <!-- Banner style with reduced corner radius -->
    <style name="BannerCardStyle" parent="Widget.Material3.CardView.Elevated">
        <item name="shapeAppearanceOverlay">@style/BannerShapeAppearance</item>
    </style>

    <style name="BannerShapeAppearance">
        <item name="cornerFamily">rounded</item>
        <item name="cornerSize">0dp</item>
    </style>

    <!-- Full-screen dialog style for Material 3 compliance -->
    <style name="Theme.App.FullScreenDialog" parent="AppTheme">
        <item name="android:windowNoTitle">true</item>
        <item name="android:windowIsFloating">false</item>
        <item name="android:statusBarColor">?attr/colorSurface</item>
        <item name="android:windowBackground">?attr/colorSurface</item>
        <item name="android:windowLightStatusBar">true</item>
        <item name="android:windowAnimationStyle">@style/Animation.App.FullScreenDialog</item>
    </style>

    <!-- Slide animation for full-screen dialog -->
    <style name="Animation.App.FullScreenDialog" parent="Animation.AppCompat.Dialog">
        <item name="android:windowEnterAnimation">@anim/slide_in_bottom</item>
        <item name="android:windowExitAnimation">@anim/slide_out_bottom</item>
    </style>
</resources>
