@charset "UTF-8";

/* 
 * WMODAL.MIN.CSS - Стили для модального окна
 * 
 * Содержание:
 * 1. Общие стили и сброс
 * 2. Кнопки и интерактивные элементы
 * 3. Заголовки и текст
 * 4. Формы и поля ввода
 * 5. Темная тема (dark-theme)
 * 6. Адаптивные стили для мобильных устройств
 */

/* 1. ОБЩИЕ СТИЛИ*/
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box
}

html #wmodal, body #wmodal {
    font-family: 'Manrope', sans-serif;
    font-style: normal;
    color: #2B2B2B;
    background-color: transparent
}

#wmodal {
    position: relative;
}

#wmodal .center {
    display: flex;
    justify-content: center
}

#wmodal .flex-column {
    display: flex;
    flex-direction: column
}

/* Контейнер-обертка модального окна (фон) */
#wmodal .modal-wraper {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 9999;
    text-align: center;
    display: none;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease;
}

/* Активное состояние обертки - центрирует окно по центру экрана */
#wmodal .modal-wraper.active {
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 1;
    visibility: visible;
}

#wmodal .modal-wraper:before {
    display: none;
}

/* Окно модального окна */
#wmodal .modal-window {
    display: none;
    opacity: 0;
    visibility: hidden;
    position: relative;
    z-index: 10000;
    max-width: 446px;
    width: 90%;
    margin: 0 auto;
    text-align: left;
    transition: opacity 0.3s ease;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
    border-radius: 10px;
    overflow: hidden;
}

/* Активное состояние окна */
#wmodal .modal-window.active {
    display: block;
    opacity: 1;
    visibility: visible;
}

/* Контейнер для вставки формы */
#objectModalWrap {
    position: static;
    width: auto;
    height: auto;
}

/* Активное состояние контейнера формы */
#objectModalWrap.active {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 9998;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* 2. КНОПКИ И ИНТЕРАКТИВНЫЕ ЭЛЕМЕНТЫ */
#wmodal .btn {
    width: 295px;
    height: 70px;
    cursor: pointer
}

#wmodal .btn-link {
    border: 3px solid #469FFF;
}

#wmodal .btn-click {
    width: 100%;
    position: relative
}

#wmodal .btn-click .btn-red {
    position: absolute;
    background-color: #469FFF;
    left: -7px;
    top: 8px;
    border-radius: 19px;
}

#wmodal .btn-click .btn-red:active {
    left: 0;
    top: 0
}

/* 3. ЗАГОЛОВКИ И ТЕКСТ */
/* Шапка модального окна */
#wmodal .modal-head {
    background-color: #469FFF;
    color: #fff;
    text-align: center;
    padding: 20px 32px;
    position: relative
}

#wmodal .modal-head h3 {
    font-size: 24px;
    margin: 4px 0;
    font-weight: 700;
    font-family: 'Alef', sans-serif;
}

#wmodal .modal-head .btn-close {
    position: absolute;
    width: 16px;
    height: 16px;
    right: 8px;
    top: 8px;
    cursor: pointer
}

/* 5. ФОРМЫ И ПОЛЯ ВВОДА */
/* Тело модального окна */
#wmodal .modal-body {
    padding: 30px 10px;
    background-color: #EFF7FF;
}

#wmodal .modal-body h5 {
    text-align: center;
    font-size: 16px;
    margin-top: 0;
    margin-bottom: 18px;
    color: #2B2B2B;
    font-weight: 600;
}

#wmodal .modal-body #comment {
    height: 100px
}

#wmodal .modal-body .callbackForm {
    margin: 0 30px
}

#wmodal .modal-body .callbackForm .fio,
#wmodal .modal-body .callbackForm .email,
#wmodal .modal-body .callbackForm .phone,
#wmodal .modal-body .callbackForm .task {
    margin-bottom: 15px
}

#wmodal #phone:focus {
    padding-left: 5px
}

#wmodal .modal-body .callbackForm label {
    font-size: 14px;
    font-weight: 500;
    color: #535050;
    margin-bottom: 5px;
}

#wmodal .modal-body .callbackForm input {
    height: 32px;
    border-color: #d0d0d0;
    border-top: 0;
    border-left: 0;
    border-right: 0;
    border-bottom: 2px solid #469FFF;
    background-color: rgba(255, 255, 255, 0.8);
    padding: 5px 10px;
    border-radius: 4px 4px 0 0;
}

#wmodal .modal-body .callbackForm .btn-modal-box {
    position: relative;
    height: 58px;
    margin-top: 25px;
    margin-bottom: 35px
}

#wmodal .modal-body .callbackForm .btn-modal-box .btn-red {
    text-align: center;
    font-weight: 700;
    font-size: 18px;
    text-shadow: 0 1px 10px rgba(0,0,0,.15);
    text-transform: uppercase;
    font-family: 'Alef', sans-serif;
    color: #fff;
    cursor: pointer;
    border-bottom: 0;
    height: 70px;
    position: absolute;
    background-color: #469FFF;
    left: -7px;
    top: 8px;
    width: 100%;
    white-space: normal;
    transition: background 0.2s;
}

#wmodal .modal-body .callbackForm .btn-modal-box .btn-red:hover {
    background-color: #298FFF;
}

#wmodal .modal-body .callbackForm .btn-modal-box .btn-link {
    border: 3px solid #2B2B2B;
    width: 100%
}

#wmodal .modal-body .callbackForm .btn-modal-box .btn-red:active {
    left: 0;
    top: 0
}

#wmodal .modal-body .callbackForm .sign {
    font-size: 14px
}

#wmodal .modal-body .callbackForm .sign a {
    color: #469FFF;
    text-decoration: none;
}

#wmodal .modal-body .callbackForm .sign a:hover {
    text-decoration: underline;
}

/* 6. ТЕМНАЯ ТЕМА */
/* Темная тема - изменение цветов для темного фона */
#wmodal .dark-theme .modal-head {
    background-color: #298FFF
}

#wmodal .dark-theme .modal-head h3 {
    font-size: 22px
}

#wmodal .dark-theme .modal-body {
    padding: 0 10px 20px;
    background-color: #EFF7FF;
}

#wmodal .dark-theme .modal-body .callbackForm .btn-modal-box .btn-red {
    background-color: #469FFF
}

#wmodal .dark-theme .modal-body h5 {
    color: #2B2B2B;
    padding-top: 15px;
}

#wmodal .dark-theme .flex-column label {
    margin-bottom: 6px;
    color: #535050;
}

#wmodal .dark-theme .flex-column input,
#wmodal .dark-theme .flex-column textarea {
    border-bottom: 0;
    border-radius: 6px;
    box-shadow: 0 0 4px 1px rgba(70,159,255,.3);
    background-color: #FAFAFA;
}

#wmodal .dark-theme .flex-column input:focus,
#wmodal .dark-theme .flex-column textarea:focus {
    outline: none;
    box-shadow: 0 0 5px 5px rgba(70,159,255,.3)
}

#wmodal .dark-theme .flex-column input {
    padding: 16px 4px 14px 8px
}

#wmodal .dark-theme .flex-column textarea {
    padding: 8px 4px 6px 8px;
    resize: none
}

#wmodal .dark-theme #phone:focus {
    padding: 16px 4px 14px 8px
}

#wmodal .dark-theme .file-upload-container input[type=file] {
    width: .1px;
    height: .1px;
    opacity: 0;
    overflow: hidden;
    position: absolute;
    z-index: -1
}

#wmodal .dark-theme .file-upload-container label {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    padding: 10px 4px 8px;
    border-radius: 6px;
    box-shadow: 0 0 4px 1px rgba(70,159,255,.3);
    transition: box-shadow .1s ease-out;
    cursor: pointer;
    background-color: #FAFAFA;
}

#wmodal .dark-theme .file-upload-container label svg,
#wmodal .dark-theme .file-upload-container label span {
    margin: 0 3px;
    color: #2B2B2B;
}

#wmodal .dark-theme .file-upload-container label:hover {
    box-shadow: 0 0 4px 1px rgba(70,159,255,.6)
}

#wmodal .dark-theme .file-upload-container label:active {
    box-shadow: 0 0 3px 2px rgba(70,159,255,.6)
}

#wmodal .dark-theme .btn-click .btn-red {
    background-color: #469FFF
}

#wmodal .dark-theme .modal-body .callbackForm .btn-modal-box .btn-red {
    position: relative;
    top: 0;
    left: 0;
    border-radius: 19px;
    box-shadow: 0 0 5px 5px rgba(0,0,0,.1);
    background-color: #469FFF;
    transition: background-color 0.2s, box-shadow 0.2s;
}

#wmodal .dark-theme .modal-body .callbackForm .btn-modal-box .btn-red:hover {
    background-color: #298FFF;
    box-shadow: 0 0 5px 5px rgba(0,0,0,.2)
}

#wmodal .dark-theme .modal-body .callbackForm .btn-modal-box .btn-red:active {
    box-shadow: 0 0 3px 3px rgba(0,0,0,.2)
}

#wmodal .dark-theme .modal-body .callbackForm .btn-modal-box .btn-link {
    display: none
}

#wmodal .modal-window.circular-escape #circular-container {
    opacity: 0;
    visibility: hidden;
    z-index: -1
}

#wmodal .modal-window.circular-escape .modal-head,
#wmodal .modal-window.circular-escape .modal-body {
    opacity: 1;
    visibility: visible
}

/* 7. АДАПТИВНЫЕ СТИЛИ ДЛЯ МОБИЛЬНЫХ УСТРОЙСТВ */
@media screen and (max-width: 400px) {
    #wmodal .dark-theme .modal-head {
        display:flex;
        justify-content: center;
        padding: 15px 6px 0
    }

    #wmodal .dark-theme .modal-head h3 {
        font-size: 16px;
        max-width: 80%
    }

    #wmodal .dark-theme .flex-column label {
        font-size: 13px
    }

    #wmodal .dark-theme .modal-body {
        padding-bottom: 0
    }

    #wmodal .dark-theme .modal-body h5 {
        font-size: 12px;
        margin-bottom: 5px
    }

    #wmodal .dark-theme .modal-body #comment {
        height: 60px
    }

    #wmodal .dark-theme .modal-body .callbackForm .fio,
    #wmodal .dark-theme .modal-body .callbackForm .email,
    #wmodal .dark-theme .modal-body .callbackForm .phone,
    #wmodal .dark-theme .modal-body .callbackForm .task {
        font-size: 13px;
        margin-bottom: 10px
    }

    #wmodal .dark-theme .modal-body .callbackForm .btn-modal-box {
        margin-top: 15px;
        margin-bottom: 10px
    }

    #wmodal .dark-theme .modal-body .callbackForm .btn-modal-box .btn-red {
        height: 40px;
        font-size: 14px
    }

    #wmodal .modal-wrap .wmodal .order-box .closeModal {
        right: 60px!important
    }
}

/* Стили для сообщения об успешной отправке */
.alertmodal {
    position: fixed;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    z-index: 10001;
    pointer-events: none;
}

.alert-modal-ok {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10001;
    background-color: rgba(0, 0, 0, 0.5);
    pointer-events: auto;
}

.amodal {
    background-color: #FFFFFF;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
    padding: 30px;
    max-width: 400px;
    width: 90%;
    text-align: center;
    animation: fadeInUp 0.3s ease;
    position: relative;
    z-index: 10002;
}

.alert-text {
    color: #2B2B2B;
    font-size: 18px;
    font-weight: 500;
    margin-bottom: 20px;
    font-family: 'Manrope', sans-serif;
}

.alert-btn-close {
    display: inline-block;
    background-color: #469FFF;
    color: #FFFFFF;
    padding: 8px 30px;
    border-radius: 19px;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    transition: background-color 0.2s;
}

.alert-btn-close:hover {
    background-color: #298FFF;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}
