/* 
   ПОДКЛЮЧЕНИЕ ШРИФТОВ
    */

@font-face {
    font-family: 'seoul_l';
    src: url('../Resources/fonts/seoulhanggang/SeoulHangangL.eot');
    src: url('../Resources/fonts/seoulhanggang/SeoulHangangL.eot?#iefix') format('embedded-opentype'),
         url('../Resources/fonts/seoulhanggang/SeoulHangangL.woff2') format('woff2'),
         url('../Resources/fonts/seoulhanggang/SeoulHangangL.woff') format('woff'),
         url('../Resources/fonts/seoulhanggang/SeoulHangangL.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'seoul_b';
    src: url('../Resources/fonts/seoulhanggang/SeoulHangangB.eot');
    src: url('../Resources/fonts/seoulhanggang/SeoulHangangB.eot?#iefix') format('embedded-opentype'),
         url('../Resources/fonts/seoulhanggang/SeoulHangangB.woff2') format('woff2'),
         url('../Resources/fonts/seoulhanggang/SeoulHangangB.woff') format('woff'),
         url('../Resources/fonts/seoulhanggang/SeoulHangangB.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'seoul_m';
    src: url('../Resources/fonts/seoulhanggang/SeoulHangangM.eot');
    src: url('../Resources/fonts/seoulhanggang/SeoulHangangM.eot?#iefix') format('embedded-opentype'),
         url('../Resources/fonts/seoulhanggang/SeoulHangangM.woff2') format('woff2'),
         url('../Resources/fonts/seoulhanggang/SeoulHangangM.woff') format('woff'),
         url('../Resources/fonts/seoulhanggang/SeoulHangangM.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'seoul';
    src: url('../Resources/fonts/seoulhanggang/SeoulHangangEB.eot');
    src: url('../Resources/fonts/seoulhanggang/SeoulHangangEB.eot?#iefix') format('embedded-opentype'),
         url('../Resources/fonts/seoulhanggang/SeoulHangangEB.woff2') format('woff2'),
         url('../Resources/fonts/seoulhanggang/SeoulHangangEB.woff') format('woff'),
         url('../Resources/fonts/seoulhanggang/SeoulHangangEB.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}


/* 
   ОБЩИЕ НАСТРОЙКИ
    */

* {
    box-sizing: border-box;
    border: none;
    padding: 0;
    margin: 0;
}

*:focus {
    outline: none;
}

*:focus-visible {
    outline: 3px solid rgba(0, 95, 127, 0.45);
    outline-offset: 3px;
}

html {
    width: 100%;
    min-height: 100%;
}

body {
    width: 100%;
    min-height: 100vh;
    font-family: "seoul_l", Arial, sans-serif;
    color: #2D595C;

    background-image: url("../Resources/bg_img.webp");
    background-position: center;
    background-repeat: no-repeat;
    background-size: cover;
}

/* Цвета сайта удобно менять здесь:

   Главный тёмно-зелёный: #2D595C
   Средний зелёный:       #73908E
   Светлый фон:           #E5E1D3
   Синий акцент:          #005f7f
   Белая стеклянная панель: rgba(255, 255, 255, 0.35)
*/


/* 
   ГЛАВНАЯ СТРАНИЦА
    */

.home-page {
    overflow-x: hidden;
    overflow-y: auto;
}

/* Весь экран главной страницы */
.home-screen {
    min-height: 100vh;
    min-height: 100dvh;

    display: flex;
    flex-direction: column;
    justify-content: space-between;
    gap: 20px;

    padding: clamp(10px, 2.2vh, 24px);

    box-sizing: border-box;
}
/*.home-screen {
    width: 100%;
    height: 100svh;
    min-height: 100vh;

    display: grid;

    /*
       3 зоны:
       1. шапка с логотипом
       2. центральный блок
       3. нижняя кнопка
    */
/*    grid-template-rows: auto 1fr auto;

    padding: clamp(12px, 2vw, 30px);
    gap: clamp(10px, 2vh, 25px);
}*/

/* Шапка главной */
.home-header {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;

    gap: clamp(14px, 4vw, 40px);
    width: 100%;
}

/* Логотип на главной */
#logo {
    width: clamp(150px, 16vw, 260px);
    height: clamp(150px, 16vw, 260px);
    object-fit: contain;
    opacity: 0.9;
}

/* Вертикальная линия */
#line {
    width: 3px;
    height: clamp(90px, 8vw, 130px);
    background-color: #73908E;
    border-radius: 5px;
}

/* Текст рядом с логотипом */
#header_text {
    font-family: "seoul", Arial, sans-serif;
    font-size: clamp(26px, 3vw, 38px);
    color: #73908E;
    line-height: 1.15;
}

/* Центральный блок */
#login_window {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
}

/* Стеклянная карточка на главной */
#login_window_wrapper {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;

    gap: 30px;

    background: rgba(255, 255, 255, 0.35);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);

    border-radius: 10px;

    width: fit-content;
    max-width: 95vw;

    padding: clamp(18px, 4vw, 35px) clamp(22px, 6vw, 60px);

    transition:
        transform 0.18s ease,
        background-color 0.18s ease,
        padding 0.3s ease;
}

#login_window_wrapper:hover {
    transform: translateY(-2px);
    background: rgba(255, 255, 255, 0.45);
}

#login_window div {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

#login_txt {
    gap: clamp(8px, 2vh, 20px);
    text-align: center;
}

#login_txt h2 {
    font-size: clamp(34px, 7vw, 70px);
    color: #2D595C;
    font-family: "seoul_l", Arial, sans-serif;
}

#login_txt h1 {
    font-size: clamp(22px, 4vw, 38px);
    color: #2D595C;
    font-family: "seoul_l", Arial, sans-serif;
}

#phone_btn {
    font-size: clamp(24px, 5vw, 48px);
    color: #005f7f;
    text-decoration: none;
    display: block;
    text-align: center;
    margin-top: 5px;
    font-weight: bold;

    transition:
        transform 0.15s ease,
        color 0.15s ease;
}

#phone_btn:hover {
    color: #2D595C;
    transform: scale(1.03);
}

#phone_btn:active {
    transform: scale(0.96);
}

/* Нижний блок с кнопкой */
/*.home-services-block {
    display: flex;
    justify-content: center;
    align-items: center;

    width: 100%;

    padding-top: 10px;
    padding-bottom: calc(14px + env(safe-area-inset-bottom));

    box-sizing: border-box;
}*/

.home-services-block {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 16px;

    width: 100%;

    padding-top: 10px;
    padding-bottom: calc(14px + env(safe-area-inset-bottom));

    box-sizing: border-box;
}

/*.home-services-block {
    display: flex;
    justify-content: center;
    align-items: center;

    width: 100%;
    padding-bottom: clamp(8px, 2vh, 20px);
}
*/
/* Главная большая кнопка */
.main-action-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    min-width: min(420px, 92vw);
    min-height: clamp(56px, 8vh, 76px);

    padding: 16px 34px;

    border-radius: 14px;

    background-color: #73908E;
    color: #E5E1D3;

    font-family: "seoul_l", Arial, sans-serif;
    font-size: clamp(22px, 4vw, 34px);
    font-weight: bold;
    text-decoration: none;

    box-shadow: 0 6px 22px rgba(35, 78, 84, 0.45);

    cursor: pointer;

    transition:
        transform 0.15s ease,
        background-color 0.15s ease,
        color 0.15s ease,
        box-shadow 0.15s ease;
}

.main-action-button:hover {
    background-color: #82A09E;
    box-shadow: 0 8px 28px rgba(35, 78, 84, 0.55);
    transform: translateY(-2px);
}

.main-action-button:active {
    background-color: #E5E1D3;
    color: #73908E;
    transform: scale(0.96);
}


/* 
   СТРАНИЦА СЕРВИСОВ
    */

.website-field {
    position: absolute;
    left: -9999px;
    opacity: 0;
    pointer-events: none;
}

.services-page {
    overflow-x: hidden;
}

/* Шапка страницы сервисов */
.services-header {
    width: min(1200px, 94vw);
    margin: 24px auto 0 auto;

    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;

    padding: 18px 22px;

    background: rgba(255, 255, 255, 0.35);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);

    border-radius: 14px;
}

.small-logo-link {
    display: inline-flex;
}

.small-logo {
    width: 92px;
    height: 92px;
    object-fit: contain;
}

.services-header-text {
    flex: 1;
    text-align: center;
}

.services-header-text h1 {
    font-family: "seoul", Arial, sans-serif;
    color: #2D595C;
    font-size: clamp(30px, 5vw, 54px);
}

.services-header-text p {
    margin-top: 8px;
    color: #2D595C;
    font-size: clamp(16px, 2.5vw, 22px);
}

.back-home-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    min-height: 50px;
    padding: 12px 18px;

    border-radius: 10px;

    background-color: #73908E;
    color: #E5E1D3;

    text-decoration: none;
    font-size: 18px;
    font-weight: bold;

    box-shadow: 0 4px 16px rgba(35, 78, 84, 0.35);

    transition:
        transform 0.15s ease,
        background-color 0.15s ease,
        color 0.15s ease;
}

.back-home-button:hover {
    background-color: #82A09E;
    transform: translateY(-2px);
}

.back-home-button:active {
    background-color: #E5E1D3;
    color: #73908E;
    transform: scale(0.96);
}

/* Контейнер всех карточек */
.services-container {
    width: min(1200px, 94vw);
    margin: 28px auto 50px auto;

    display: flex;
    flex-direction: column;
    gap: 26px;
}

/* Карточка сервиса */
.service-card {
    display: flex;
    flex-direction: row;

    gap: 28px;

    padding: clamp(18px, 3vw, 30px);

    border-radius: 16px;

    background: rgba(255, 255, 255, 0.42);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);

    box-shadow: 0 8px 28px rgba(35, 78, 84, 0.24);
}

/* Блок картинки */
.service-image-wrap {
    flex: 0 0 38%;

    min-height: 260px;

    border-radius: 14px;
    overflow: hidden;

    background: rgba(255, 255, 255, 0.35);
}

/* Картинка в карточке */
.service-image {
    width: 100%;
    height: 100%;
    min-height: 260px;

    display: block;
    object-fit: cover;
}

/* Правая часть карточки */
.service-content {
    flex: 1;

    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 18px;
}

.service-content h2 {
    font-family: "seoul", Arial, sans-serif;
    font-size: clamp(28px, 4vw, 44px);
    color: #2D595C;
}

.service-content p {
    font-size: clamp(17px, 2vw, 22px);
    line-height: 1.45;
    color: #2D595C;
}

/* Кнопки карточки */
.service-actions,
.form-bottom-row {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
}

.card-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    min-height: 58px;
    min-width: 210px;

    padding: 14px 24px;

    border-radius: 12px;

    font-family: "seoul_l", Arial, sans-serif;
    font-size: 20px;
    font-weight: bold;
    text-decoration: none;

    cursor: pointer;

    box-shadow: 0 4px 18px rgba(35, 78, 84, 0.35);

    transition:
        transform 0.15s ease,
        background-color 0.15s ease,
        color 0.15s ease,
        box-shadow 0.15s ease;
}

.go-button {
    background-color: #005f7f;
    color: #ffffff;
}

.request-open-button,
.submit-button {
    background-color: #73908E;
    color: #E5E1D3;
}

.close-form-button {
    background-color: rgba(45, 89, 92, 0.18);
    color: #2D595C;
}

.card-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 24px rgba(35, 78, 84, 0.48);
}

.go-button:hover {
    background-color: #007399;
}

.request-open-button:hover,
.submit-button:hover {
    background-color: #82A09E;
}

.close-form-button:hover {
    background-color: rgba(45, 89, 92, 0.28);
}

.card-button:active {
    transform: scale(0.96);
    box-shadow: 0 2px 12px rgba(35, 78, 84, 0.30);
}

/* 
   ФОРМА ЗАЯВКИ
    */

/* По умолчанию форма скрыта */
.request-form {
    display: none;

    margin-top: 6px;

    padding: 20px;

    border-radius: 14px;

    background: rgba(255, 255, 255, 0.45);
}

/* Этот класс добавляется JS-кодом, чтобы показать форму */
.request-form-visible {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.request-form label {
    display: flex;
    flex-direction: column;
    gap: 7px;

    color: #2D595C;
    font-size: 18px;
    font-weight: bold;
}

.request-form input,
.request-form textarea {
    width: 100%;

    padding: 13px 14px;

    border-radius: 10px;

    background: rgba(255, 255, 255, 0.65);
    color: #2D595C;

    font-family: Arial, sans-serif;
    font-size: 18px;

    border: 2px solid transparent;

    transition:
        background-color 0.15s ease,
        border-color 0.15s ease,
        box-shadow 0.15s ease;
}

.request-form input:focus,
.request-form textarea:focus {
    background: rgba(255, 255, 255, 0.88);
    border-color: #73908E;
    box-shadow: 0 0 0 4px rgba(115, 144, 142, 0.20);
}

.request-form textarea {
    min-height: 140px;
    resize: vertical;
}


/* 
   СТАРЫЕ ЭЛЕМЕНТЫ, ЕСЛИ ВДРУГ ПОНАДОБЯТСЯ
    */

#error_window_wrapper {
    display: flex;
    flex-direction: column;
    align-content: center;
    justify-content: center;
    align-items: center;

    gap: 30px;

    background: rgba(255, 255, 255, 0.35);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);

    border-radius: 10px;

    width: fit-content;

    padding: 70px 240px;
}

#inputs {
    gap: 20px;
}

#inputs input {
    width: 300px;
    height: 40px;
    color: #73908E;
    font-size: 20px;
    font-family: "seoul_l";
    background: rgba(255, 255, 255, 0.5);
    backdrop-filter: blur(9px);
    -webkit-backdrop-filter: blur(9px);
    border-radius: 10px;
    border: none;
    padding: 10px;
}

#inputs input:focus {
    color: #73908E;
    font-size: 20px;
    font-family: "seoul_l";
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(9px);
    -webkit-backdrop-filter: blur(9px);
    border-radius: 10px;
    border: none;
    padding: 10px;
}

button {
    font-family: inherit;
}


/* 
   АДАПТИВНОСТЬ ДЛЯ ПЛАНШЕТОВ И ТЕЛЕФОНОВ
    */

@media (max-width: 800px) {

    .home-header {
        gap: 14px;
    }

    #line {
        height: 90px;
    }

    .services-header {
        flex-direction: column;
        text-align: center;
    }

    .back-home-button {
        width: 100%;
    }

    /* На мобильных карточка становится вертикальной:
       сначала фото, потом текст */
    .service-card {
        flex-direction: column;
        gap: 20px;
    }

    .service-image-wrap {
        flex: none;
        width: 100%;
        min-height: 220px;
    }

    .service-image {
        min-height: 220px;
    }

    .service-actions,
    .form-bottom-row {
        flex-direction: column;
    }

    .card-button {
        width: 100%;
        min-width: 0;
    }
}

@media (max-width: 520px) {

    .home-screen {
        padding: 10px;
        gap: 8px;
    }

    .home-header {
        flex-direction: row;
        gap: 12px;
    }

    #logo {
        width: clamp(135px, 34vw, 165px);
        height: clamp(135px, 34vw, 165px);
    }

    #line {
        width: 2px;
        height: clamp(85px, 24vw, 110px);
    }

    #header_text {
        font-size: clamp(22px, 6vw, 28px);
    }

    #login_window_wrapper {
        padding: 18px 16px;
        width: 100%;
    }

    #login_txt h2 {
        font-size: 32px;
    }

    #login_txt h1 {
        font-size: 20px;
    }

    #phone_btn {
        font-size: 24px;
    }

    .main-action-button {
        width: 100%;
        min-width: 0;
        font-size: 24px;
    }

    .services-header {
        margin-top: 12px;
        padding: 16px;
    }

    .small-logo {
        width: 72px;
        height: 72px;
    }

    .services-container {
        width: 94vw;
        margin-top: 18px;
    }

    .service-card {
        padding: 16px;
    }

    .request-form {
        padding: 14px;
    }
}

@media (max-height: 680px) {

    .home-screen {
        gap: 6px;
    }

    #logo {
        width: clamp(95px, 18vh, 180px);
        height: clamp(95px, 18vh, 180px);
    }

    #line {
        height: clamp(65px, 13vh, 100px);
    }

    #header_text {
        font-size: clamp(18px, 4vh, 32px);
    }

    #login_txt h2 {
        font-size: clamp(28px, 7vh, 52px);
    }

    #login_txt h1 {
        font-size: clamp(18px, 4vh, 30px);
    }

    #phone_btn {
        font-size: clamp(20px, 5vh, 34px);
    }

    .main-action-button {
        min-height: 50px;
        padding: 12px 24px;
    }
}