/* =====================
   AUTOFILL STYLES FOR OLIVIATRADING
   ===================== */

/* Основные цвета сайта Oliviatrading */
:root {
    --autofill-bg: transparent;
    --autofill-text: white;
    --autofill-bg-focus: transparent;
    --autofill-text-focus: white;
    --autofill-border: #889f67;
    --autofill-border-hover: #caa430;
}

/* Базовые стили для всех инпутов */
input:-webkit-autofill,
input:-webkit-autofill:hover,
input:-webkit-autofill:focus,
input:-webkit-autofill:active {
    -webkit-box-shadow: 0 0 0 1000px var(--autofill-bg) inset !important;
    -webkit-text-fill-color: var(--autofill-text) !important;
    transition: background-color 5000s ease-in-out 0s;
    border-color: var(--autofill-border) !important;
}

/* Firefox стили */
input:-moz-autofill,
input:-moz-autofill:hover,
input:-moz-autofill:focus,
input:-moz-autofill:active {
    box-shadow: 0 0 0 1000px var(--autofill-bg) inset !important;
    -moz-text-fill-color: var(--autofill-text) !important;
    background-color: var(--autofill-bg) !important;
    background-image: none !important;
    border-color: var(--autofill-border) !important;
}

/* Для Bootstrap form-control */
.form-control:-webkit-autofill,
.form-control:-webkit-autofill:hover,
.form-control:-webkit-autofill:focus,
.form-control:-webkit-autofill:active {
    -webkit-box-shadow: 0 0 0 1000px var(--autofill-bg) inset !important;
    -webkit-text-fill-color: var(--autofill-text) !important;
    transition: background-color 5000s ease-in-out 0s;
    border-color: var(--autofill-border) !important;
}

.form-control:-moz-autofill {
    box-shadow: 0 0 0 1000px var(--autofill-bg) inset !important;
    -moz-text-fill-color: var(--autofill-text) !important;
    background-color: var(--autofill-bg) !important;
    background-image: none !important;
    border-color: var(--autofill-border) !important;
}

/* Для floating labels (Bootstrap) */
.form-floating > .form-control:-webkit-autofill,
.form-floating > .form-control-plaintext:-webkit-autofill {
    -webkit-box-shadow: 0 0 0 1000px var(--autofill-bg) inset !important;
    -webkit-text-fill-color: var(--autofill-text) !important;
    transition: background-color 5000s ease-in-out 0s;
    padding-top: 1.625rem;
    padding-bottom: 0.625rem;
    border-color: var(--autofill-border) !important;
}

.form-floating > .form-control:-webkit-autofill:focus,
.form-floating > .form-control-plaintext:-webkit-autofill:focus {
    -webkit-box-shadow: 0 0 0 1000px var(--autofill-bg-focus) inset !important;
    -webkit-text-fill-color: var(--autofill-text-focus) !important;
    border-color: var(--autofill-border) !important;
}

.form-floating > .form-control:-moz-autofill {
    box-shadow: 0 0 0 1000px var(--autofill-bg) inset !important;
    -moz-text-fill-color: var(--autofill-text) !important;
    background-color: var(--autofill-bg) !important;
    background-image: none !important;
    padding-top: 1.625rem;
    padding-bottom: 0.625rem;
    border-color: var(--autofill-border) !important;
}

/* Для кастомных полей формы Oliviatrading */
.form__field:-webkit-autofill,
.form__field:-webkit-autofill:hover,
.form__field:-webkit-autofill:focus,
.form__field:-webkit-autofill:active {
    -webkit-box-shadow: 0 0 0 1000px var(--autofill-bg) inset !important;
    -webkit-text-fill-color: var(--autofill-text) !important;
    transition: background-color 5000s ease-in-out 0s;
    border-bottom-color: var(--autofill-border) !important;
}

.form__field:-moz-autofill {
    box-shadow: 0 0 0 1000px var(--autofill-bg) inset !important;
    -moz-text-fill-color: var(--autofill-text) !important;
    background-color: var(--autofill-bg) !important;
    background-image: none !important;
    border-bottom-color: var(--autofill-border) !important;
}

/* Состояние фокуса для автозаполнения */
input:-webkit-autofill:focus,
.form-control:-webkit-autofill:focus,
.form__field:-webkit-autofill:focus {
    -webkit-box-shadow: 0 0 0 1000px var(--autofill-bg-focus) inset !important;
    -webkit-text-fill-color: var(--autofill-text-focus) !important;
    border-color: var(--autofill-border) !important;
    outline: 0;
}

input:-moz-autofill:focus,
.form-control:-moz-autofill:focus,
.form__field:-moz-autofill:focus {
    box-shadow: 0 0 0 1000px var(--autofill-bg-focus) inset !important;
    -moz-text-fill-color: var(--autofill-text-focus) !important;
    background-color: var(--autofill-bg-focus) !important;
    border-color: var(--autofill-border) !important;
    outline: 0;
}

/* Для textarea */
textarea:-webkit-autofill,
textarea:-webkit-autofill:hover,
textarea:-webkit-autofill:focus,
textarea:-webkit-autofill:active {
    -webkit-box-shadow: 0 0 0 1000px var(--autofill-bg) inset !important;
    -webkit-text-fill-color: var(--autofill-text) !important;
    transition: background-color 5000s ease-in-out 0s;
    border-color: var(--autofill-border) !important;
}

textarea:-moz-autofill {
    box-shadow: 0 0 0 1000px var(--autofill-bg) inset !important;
    -moz-text-fill-color: var(--autofill-text) !important;
    background-color: var(--autofill-bg) !important;
    background-image: none !important;
    border-color: var(--autofill-border) !important;
}

/* Для email полей */
input[type="email"]:-webkit-autofill,
input[type="email"]:-webkit-autofill:hover,
input[type="email"]:-webkit-autofill:focus,
input[type="email"]:-webkit-autofill:active {
    -webkit-box-shadow: 0 0 0 1000px var(--autofill-bg) inset !important;
    -webkit-text-fill-color: var(--autofill-text) !important;
    transition: background-color 5000s ease-in-out 0s;
    border-color: var(--autofill-border) !important;
}

input[type="email"]:-moz-autofill {
    box-shadow: 0 0 0 1000px var(--autofill-bg) inset !important;
    -moz-text-fill-color: var(--autofill-text) !important;
    background-color: var(--autofill-bg) !important;
    background-image: none !important;
    border-color: var(--autofill-border) !important;
}

/* Для tel полей */
input[type="tel"]:-webkit-autofill,
input[type="tel"]:-webkit-autofill:hover,
input[type="tel"]:-webkit-autofill:focus,
input[type="tel"]:-webkit-autofill:active {
    -webkit-box-shadow: 0 0 0 1000px var(--autofill-bg) inset !important;
    -webkit-text-fill-color: var(--autofill-text) !important;
    transition: background-color 5000s ease-in-out 0s;
    border-color: var(--autofill-border) !important;
}

input[type="tel"]:-moz-autofill {
    box-shadow: 0 0 0 1000px var(--autofill-bg) inset !important;
    -moz-text-fill-color: var(--autofill-text) !important;
    background-color: var(--autofill-bg) !important;
    background-image: none !important;
    border-color: var(--autofill-border) !important;
}
