/*
    Предрейсовые осмотры - мобильное приложение
    Стили компонента ввода пароля
*/

//---------------------
//Подключение библиотек
//---------------------

const { StyleSheet } = require('react-native');
const { APP_COLORS } = require('../../config/theme');
const { UI } = require('../../config/appConfig');
const { responsiveSpacing } = require('../../utils/responsive');

//-----------
//Тело модуля
//-----------

const styles = StyleSheet.create({
    container: {
        marginBottom: responsiveSpacing(4)
    },
    label: {
        marginBottom: responsiveSpacing(2),
        color: APP_COLORS.textPrimary
    },
    inputContainer: {
        flexDirection: 'row',
        alignItems: 'center',
        borderWidth: 1,
        borderColor: APP_COLORS.borderMedium,
        borderRadius: UI.BORDER_RADIUS,
        backgroundColor: APP_COLORS.white,
        minHeight: UI.INPUT_HEIGHT
    },
    inputContainerFocused: {
        borderColor: APP_COLORS.primary,
        borderWidth: 2,
        shadowColor: APP_COLORS.primary,
        shadowOffset: { width: 0, height: 0 },
        shadowOpacity: 0.2,
        shadowRadius: 4,
        elevation: 2
    },
    inputContainerError: {
        borderColor: APP_COLORS.error
    },
    inputContainerDisabled: {
        backgroundColor: APP_COLORS.surfaceAlt
    },
    input: {
        flex: 1,
        paddingHorizontal: responsiveSpacing(3),
        paddingVertical: responsiveSpacing(2.5),
        fontSize: UI.FONT_SIZE_MD,
        color: APP_COLORS.textPrimary,
        includeFontPadding: false,
        textAlignVertical: 'center'
    },
    inputDisabled: {
        color: APP_COLORS.textTertiary
    },
    placeholder: {
        color: APP_COLORS.textTertiary
    },
    toggleButton: {
        paddingHorizontal: responsiveSpacing(3),
        paddingVertical: responsiveSpacing(2),
        justifyContent: 'center',
        alignItems: 'center'
    },
    toggleButtonText: {
        color: APP_COLORS.primary,
        fontSize: UI.FONT_SIZE_SM
    },
    toggleButtonTextDisabled: {
        color: APP_COLORS.textTertiary
    },
    helperText: {
        marginTop: responsiveSpacing(1),
        color: APP_COLORS.textSecondary
    },
    helperTextError: {
        color: APP_COLORS.error
    }
});

//----------------
//Интерфейс модуля
//----------------

module.exports = styles;
