* {
    padding: 0;
    margin: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, Helvetica, Arial, sans-serif;
    overflow: hidden;
}

/* background */
.background {
    margin: 0 auto;
    display: flex;
    width: 100%;
    height: 100%;
}
.image {
    margin-right: 0;
}
.map {
    flex: 1;
    display: block;
}
.desktop-image {
    display: block;
    height: 100%;
}

@media (max-width: 960px) {
    .image {
        width: 100%;
    }
    .desktop-image {
        height: auto;
        width: 100%;
    }
    .background {
        flex-direction: column;
        display: flex;
        width: 100%;
        height: 100%;
    }
}

/* модалка  */

:root {
    --card-bg: #f9f9f9;
    --accent-blue: #246bfd;
    --text-main: #000000;
    --text-muted: #707070;
    --input-bg: white;
    --text-gray: #8e8e93;
    --bg-light: #f5f5f7;

    --primary-blue: #007aff;
    --bg-light-blue: #f2f5f9;
    --text-secondary: #707070;
}

.modal-overlay {
    background: rgba(0,0,0, 0.5);
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    display: flex;
    align-items: flex-start;
    justify-content: center;
    overflow: auto;
    scroll-behavior: smooth;

    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease-in-out;
}

/* Контейнер модального окна */
.modal {
    margin-top: 40px;
    background: white;
    width: 95%;
    max-width: 498px;
    border-radius: 6px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.2);

    /* Эффект вылета (чуть ниже и меньше) */
    transform: scale(0.3) translateY(200px);
    transition: all 0.3s ease-in-out;
}
/* Состояние при открытии */
.modal-overlay.is-open {
    opacity: 1;
    visibility: visible;
}

.modal-overlay.is-open .modal {
    transform: scale(1) translateY(0);
}

/* Шапка */
.header {
    display: flex;
    padding: 20px 24px;
}

.logo {
    width: 56px;
    height: 56px;
    background-image: url(img/hayat-logo.png);
    border-radius: 50%;
    overflow: hidden;
    box-shadow: 0 0 1px 1px rgba(0, 0, 0, .25);
    margin-right: 20px;

    background-blend-mode: multiply;
    background-position: center center;
    background-repeat: no-repeat;
    background-size: cover;
}

.place-info {
    background: white;
    border-radius: 16px;
    text-align: left;
}

.place-name {
    font-weight: 400;
    font-size: 19px;
    margin-bottom: 4px;
}

.place-address {
    font-size: 14px;
    margin-bottom: 12px;
}

.stars-section {
    padding: 0 24px 16px;
    position: relative;
}

.stars {
    display: flex;
    justify-content: center;
    background-color: #f2f2f2;
    border-radius: 8px;
    padding: 16px 0;
}

.star {
    display: block;
    color: #bfbfbf;
    cursor: pointer;
    padding: 0 4px;

    /* Убирает синюю рамку/заливку при нажатии на iOS и Android */
    -webkit-tap-highlight-color: transparent;
    /* Дополнительно: убирает контур фокуса (если он появляется) */
    outline: none;
    /* Запрещает выделение элемента (чтобы при долгом нажатии не вылезало меню) */
    -webkit-touch-callout: none;
    user-select: none;
}

.star-hovered {
    color: #fc0;
}

.tooltip {
    display: none;
    position: absolute;
    left: 50%;
    top: 70%;
    transform: translateX(-50%);
    width: 90%;
    background: rgb(2, 142, 255);
    padding: 16px;
    color: white;
    border-radius: 8px;
}
.tooltip:after {
    content: " ";
    position: absolute;
    bottom: 100%;
    left: 50%;
    margin-left: -5px;
    border-width: 5px;
    border-style: solid;
    border-color:  transparent transparent #196dff transparent;
}

.showTooltip {
    display: block;
}

/* Поля ввода */
.input-group {
    padding: 0 24px;
}

.input-group input {
    padding: 16px 0;
    border-bottom: 1px solid #e6e6e6;
    width: 100%;
}

.input-group input:focus {
    border-bottom: 1px solid rgb(2, 142, 255);
}

input {
    width: 100%;
    border: none;
    background: transparent;
    resize: none;
    font-size: 15px;
    outline: none;
    font-family: inherit;
}


.date-input-wrapper {
    position: relative;
    width: 100%;
}

/* Создаем слой с плейсхолдером поверх инпута */
.date-input-wrapper::before {
    content: attr(data-placeholder);
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    color: #999;
    pointer-events: none; /* Клик проходит сквозь текст в инпут */

    z-index: 1;
    transition: opacity 0.1s;
}

/* 1. Скрываем плейсхолдер при фокусе */
.date-input-wrapper:focus-within::before {
    opacity: 0;
}

/* 2. Скрываем плейсхолдер, если значение введено (атрибут value не пустой) */
.date-input-wrapper:has(input:not([value=""]))::before {
    opacity: 0;
}

.custom-date-input {
    width: 100%;
    appearance: none; /* Убирает стандартные иконки в некоторых браузерах */
    -webkit-appearance: none;  /* Убираем системные стили iOS */
    border: none;
    font-size: 16px;
    z-index: 2;
    color: transparent; /* Прячем "дд.мм.гггг" пока нет даты */
    display: block;
}

/* На айфонах текст даты может быть смещен, выравниваем */
.custom-date-input::-webkit-date-and-time-value {
    text-align: left;
    min-height: 1em;
}

/* Показываем саму дату, когда поле в фокусе или когда оно заполнено */
.custom-date-input:focus,
.custom-date-input:not([value=""]) {
    color: #000;
}

/* Убираем стандартную иконку календаря на ПК (по желанию),
   чтобы она не мешала плейсхолдеру */
.custom-date-input::-webkit-calendar-picker-indicator {
    cursor: pointer;
}

/* Загрузка фото */

.dropzone-section {
    margin-top: 16px;
}
.upload-zone {
    border: 1px dashed #ccc;
    border-radius: 12px;
    padding: 20px;
    text-align: center;
    cursor: pointer;
    margin-top: 10px;
}

.upload-zone .icon {
    color: var(--accent-blue);
    font-size: 24px;
    margin-bottom: 8px;
    display: block;
}

.upload-text-blue {
    color: var(--accent-blue);
    font-weight: 600;
    font-size: 14px;
}

.upload-subtext {
    color: var(--text-muted);
    font-size: 13px;
    display: block;
    margin-top: 4px;
}


.policy-section {
    position: relative;
    padding: 0 24px 16px;
}

.policy-text {
    font-size: 13px;
    line-height: 16px;
    font-weight: 400;
    letter-spacing: -0.6px;
    color: #929292;
}

.policy-text a {
    text-decoration: none;
    color: #0072ce;;
}

/* Футер */
.footer {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    padding: 24px;
    background: #f2f2f2;
}

.save-btn {
    background: rgb(2, 142, 255);
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 4px;
    font-weight: 400;
    font-size: 15px;
    cursor: pointer;
}

.info-icon {
    border: 1px solid #ccc;
    border-radius: 50%;
    width: 14px;
    height: 14px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 10px;
}


/*  dropzone */

.dropzone {
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    margin-bottom: 20px;
}

.dropzone-logo {
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: #f2f2f2;
    width: 96px;
    height: 96px;
    color: #0070cc;
    border: 1px solid #e6e6e6;
    border-radius: 4px;
    margin-right: 20px;
}

/* Эффект при наведении или перетаскивании файла */
.dropzone.dragover {
    background-color: #edf3ff;
    border-color: var(--accent-blue);
}

.upload-icon {
    width: 24px;
    height: 24px;
}

.upload-title {
    font-size: 14px;
    line-height: 18px;
    font-weight: 400;
    letter-spacing: -0.7px;
}

.upload-subtitle {
    font-size: 14px;
    line-height: 18px;
    font-weight: 400;
    letter-spacing: -0.7px;
    color: #929292;
}

/* Скрываем стандартный инпут */
#fileInput {
    display: none;
}

/* Список загруженных файлов (для примера) */
#fileList {
    margin-top: 10px;
    font-size: 12px;
    color: var(--text-gray);
}


/*thanks modal*/

.thanks-modal {
    opacity: 1;
    visibility: visible;
    transition: none;
    align-items: center;

    display: none;
}

.thanks-modal.is-open {
    display: flex;
}

.modal-card {
    background: #fff;
    width: 90%;
    max-width: 420px;
    border-radius: 10px;
    padding: 16px;
    position: relative;
    text-align: center;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

/* Стилизация иллюстрации */
.illustration-container {
    margin-bottom: 24px;
    display: flex;
    justify-content: center;
}

/* Типографика */
.modal-title {
    font-size: 20px;
    font-weight: 500;
    margin: 0 0 12px;
    color: var(--text-main);
}

.modal-subtitle {
    font-size: 16px;
    line-height: 1.4;
    color: var(--text-secondary);
    margin-bottom: 32px;
    padding: 0 20px;
}

/* Кнопки */
.modal-actions {
    display: flex;
    flex-direction: column;
    gap: 12px;
}



.btn-link {
    background: var(--primary-blue);
    border: none;
    border-radius: 6px;
    color: white;
    font-size: 17px;
    padding: 4px;
    cursor: pointer;
}
