/* v2.6*/ /*Что ты смотришь на меня? Говнокодер у руля!*/
/* Оптимизированная версия */

/* --- Шрифты --- */
@font-face {
    font-family: 'font-head';
    src: url('./fonts/amaticsc-regular.woff2') format('woff2'),
    url('./fonts/amaticsc-regular.woff') format('woff'),
    url('./fonts/amaticsc-regular.ttf') format('truetype'),
    url('./fonts/amaticsc-regular.svg#AmaticSC-Regular') format('svg');
}

@font-face {
    font-family: 'font-body';
    src: url('./fonts/sfprodisplay-regular.woff2') format('woff2'),
    url('./fonts/sfprodisplay-regular.woff') format('woff'),
    url('./fonts/sfprodisplay-regular.ttf') format('truetype'),
    url('./fonts/sfprodisplay-regular.svg#SFProDisplay-Regular') format('svg');
}

/* --- Базовые стили --- */
a {
    color: blue; /* Цвет ссылок */
}

a:visited {
    color: blue; /* Цвет посещенных ссылок */
}

a:active {
    color: red; /* Цвет активных ссылок */
}

button {
    overflow: visible;
}

button,
select {
    text-transform: none;
}

button,
html input[type="button"],
input[type="reset"],
input[type="submit"] {
    -webkit-appearance: button;
    cursor: pointer;
}

button[disabled],
html input[disabled] {
    cursor: default;
}

button::-moz-focus-inner,
input::-moz-focus-inner {
    border: 0;
    padding: 0;
}

button:hover::after {
    content: attr(data-title);
}

/* --- Кнопки интерфейса на карте --- */
button#addContactButton {
    position: absolute;
    top: 45px;
    left: 10px;
    z-index: 1;
    padding: 14px 14px;
    background-image: url("/ico/interface/button_add.png");
    background-repeat: no-repeat;
    background-color: #fff;
    display: flex;
    background-size: contain;
    border: 0;
    box-shadow: 0 2px 10px 0 #a3a3a3;
}

button#aboutUsButton {
    position: absolute;
    top: 45px;
    left: 48px;
    z-index: 1;
    padding: 14px 14px;
    background-image: url("/ico/interface/button_info.png");
    background-repeat: no-repeat;
    background-color: #fff;
    display: flex;
    background-size: contain;
    border: 0;
    box-shadow: 0 2px 10px 0 #a3a3a3;
}

/* --- Формы --- */
form {
    display: flex;
    flex-direction: column;
}

input[type="text"],
input[type="email"],
input[type="submit"],
[type="number"],
[type="tel"],
[type="url"] {
    font-family: font-body, serif;
    border-radius: 2px;
    margin-bottom: 15px;
    height: 25px;
    border: 1px solid #ccc;
    padding: 0 5px;
}

input[type="submit"] {
    width: 100%;
}

textarea {
    font-family: font-body, serif;
    border-radius: 2px;
    margin-bottom: 15px;
    height: 100px;
    border: 1px solid #ccc;
    padding: 0 5px;
}

/* Поле для защиты от спама */
input[name="secondname"] {
    display: block;
    width: 2px;
    height: 2px;
    margin-bottom: -2px;
    border: none;
    padding: 0;
    opacity: 0.01;
}

/* --- Элементы карты и балунов --- */
.fest-data-bottom {
    position: absolute;
    text-align: center;
    color: #000;
    background-color: #fff;
    width: 80px;
    font-family: font-body, serif;
    border: 2px solid #0e0;
    border-radius: 4px;
}

/*Табличка для легенды*/
.table-legend-center {
    text-align: center;
    color: red;
}

.image-button-error {
    background-image: url("/ico/interface/button_error.svg");
    background-repeat: no-repeat;
    background-color: #fff;
    float: left;
    width: 30px;
    height: 30px;
    border: 0;
    margin: 7px;
    padding: 2px;
}

.image-button-error:hover {
    opacity: 0.8;
}

.image-button-error:active {
    transform: scale(0.95);
}

.footer_img:hover {
    opacity: 0.8;
}

.footer_img:active {
    transform: scale(0.95);
}

.ymaps-2-1-79-balloon__close-button {
    opacity: 1 !important;
}

.fullscreen {
    height: 100%;
    width: 100%;
    position: absolute;
    left: 0;
    top: 0;
}

/* --- Общие стили для контента балунов (работают на всех экранах) --- */
.body_img {
    color: red;
    /* max-width будет переопределен в медиа-запросах */
}

.broken-img {
    width: 200px;
}

.balloon_img {
    vertical-align: middle;
    width: 50px;
    height: 50px;
}

.footer_img {
    vertical-align: middle;
    float: right;
    width: 30px;
    height: 30px;
    /* border: 1px ridge #999999; */ /* Закомментировано */
    border-radius: 10%;
    margin: 2px;
    padding: 2px;
}

font.header {
    font-family: font-head, serif;
    font-size: 1.75rem; /* Единый размер для всех */
}

font.body {
    font-family: font-body, serif;
    font-size: 0.75rem;
    line-height: 1rem;
    font-weight: 600;
}

font.cluster {
    font-family: font-head;
    font-size: 1.5rem;
    line-height: 1rem;
    font-weight: 900;
}

.cluster_img {
    vertical-align: middle;
    width: 30px;
    height: 30px;
}

/* --- Легенда (общие стили) --- */
.table-legend {
    font-family: font-body, serif;
    font-size: 1rem;
    font-weight: 400;
    padding: 5px;
    margin: 0;
}

.table-legend img {
    width: 40px;
}

.legend-social-ico {
    text-align: center;
}

/* --- Модальные окна (Bootstrap стили) --- */
.close {
    float: right;
    font-size: 21px;
    font-weight: 700;
    color: #000;
    text-shadow: 0 1px 0 #fff;
    filter: alpha(opacity=20);
    opacity: 0.2;
}

.close:focus,
.close:hover {
    color: #000;
    text-decoration: none;
    cursor: pointer;
    filter: alpha(opacity=50);
    opacity: 0.5;
}

button.close {
    padding: 0;
    cursor: pointer;
    background: 0 0;
    border: 0;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
}

.modal-open {
    overflow: hidden;
}

.modal {
    display: none;
    position: fixed;
    z-index: 1050;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgb(0, 0, 0);
    background-color: rgba(0, 0, 0, 0.4);
}

.modal-dialog {
    position: relative;
    width: auto;
    margin: 10px;
}

.modal.fade .modal-dialog {
    transform: translate(0, -25%);
    -webkit-transform: translate(0, -25%);
    -ms-transform: translate(0, -25%);
    -o-transform: translate(0, -25%);
    transition: transform 0.3s ease-out, -webkit-transform 0.3s ease-out, -o-transform 0.3s ease-out;
    -webkit-transition: -webkit-transform 0.3s ease-out;
    -o-transition: -o-transform 0.3s ease-out;
}

.modal.in .modal-dialog {
    transform: translate(0, 0);
    -webkit-transform: translate(0, 0);
    -ms-transform: translate(0, 0);
    -o-transform: translate(0, 0);
}

.modal-open .modal {
    overflow-x: hidden;
    overflow-y: auto;
}

.modal-content {
    position: relative;
    background-color: #fff;
    background-clip: padding-box;
    border: 1px solid rgba(0, 0, 0, 0.2);
    border-radius: 6px;
    -webkit-box-shadow: 0 3px 9px rgba(0, 0, 0, 0.5);
    box-shadow: 0 3px 9px rgba(0, 0, 0, 0.5);
    outline: 0;
}

.modal-header:after,
.modal-header:before {
    display: table;
    content: " ";
}

.modal-header {
    padding: 15px;
    border-bottom: 1px solid #e5e5e5;
}

.modal-header .close {
    margin-top: -2px;
}

h4.modal-title {
    margin: 0;
    text-align: center;
    font-family: font-head, serif;
    font-size: 1.625rem;
}

h6.modal-title {
    margin: 0;
    text-align: center;
    font-family: font-head, serif;
    font-size: 1rem;
}

.modal-body {
    font-family: font-body, serif;
    position: relative;
    padding: 15px;
}

.about-title {
    font-family: font-body, serif;
    font-size: 1rem;
    font-weight: 400;
    padding: 5px;
    margin: 0;
}

.modal-footer {
    padding: 15px;
    font-family: font-body, serif;
    font-size: 0.8rem;
    text-align: right;
    border-top: 1px solid #e5e5e5;
}

.modal-footer .btn + .btn {
    margin-bottom: 0;
    margin-left: 5px;
}

.modal-footer .btn-group .btn + .btn {
    margin-left: -1px;
}

.modal-footer .btn-block + .btn-block {
    margin-left: 0;
}

.modal-scrollbar-measure {
    position: absolute;
    top: -9999px;
    width: 50px;
    height: 50px;
    overflow: scroll;
}

@media (min-width: 768px) {
    .modal-dialog {
        width: 600px;
        margin: 30px auto;
    }

    .modal-content {
        -webkit-box-shadow: 0 5px 15px rgba(0, 0, 0, 0.5);
        box-shadow: 0 5px 15px rgba(0, 0, 0, 0.5);
    }

    .modal-sm {
        width: 300px;
    }
}

/* --- Кнопки зума и навигации --- */
.btn-div {
    position: fixed;
    inset: auto 10px 40% auto !important;
}

#zoom-in.btn {
    background-image: url("/ico/interface/button_plus.svg");
}

#zoom-out.btn {
    background-image: url("/ico/interface/button_minus.svg");
}

#get-geolocation {
    background-image: url("/ico/interface/button_location.svg")
}

.btn {
    padding: 14px 14px;
    margin-bottom: 0;
    border-radius: 4px;
    cursor: pointer;
    background-size: contain;
    background-repeat: no-repeat;
    background-color: #fff;
    background-position: center;
    display: flex;
    border: 0;
    box-shadow: 0 2px 10px 0 #a3a3a3;
    -webkit-appearance: button;
    color: black;
}

.btn.btn-stretch {
    width: 100%;
    text-align: center;
    justify-content: center;
}

.btn:active {
    background-color: #ccc;
}

.phone:first-of-type {
    padding-top: 8px;
}

.phone {
    margin-bottom: 4px;
}

/* --- SweetAlert2 стили --- */
.custom-swal-popup {
    font-family: font-body, serif;
    font-size: 16px;
    color: #333;
}

.swal2-title {
    font-size: 24px;
    font-weight: bold;
    color: #4CAF50;
}

.swal2-content {
    font-size: 18px;
    color: #555;
}

.swal2-confirm {
    font-family: 'Roboto', sans-serif;
    font-size: 16px;
    background-color: #4CAF50 !important;
    border: none;
    padding: 10px 20px;
    border-radius: 5px;
}

.swal2-confirm:hover {
    background-color: #45a049 !important;
}

/* --- Медиа-запросы для мобильных --- */
@media screen and (max-width: 460px) {
    .ymaps-2-1-79-balloon__content {
        font: 13px/20px SFProDisplay-Regular, sans-serif !important;
    }

    [id^="id_"] {
        width: calc(100vw * 75 / 100) !important;
    }

    .ymaps-2-1-79-b-cluster-content {
        width: calc(100vw * 75 / 100) !important;
    }

    .body_img {
        width: 98%;
    }

    .cluster_img {
        width: 20px;
        height: 20px;
    }

    .table-legend {
        font-size: 0.875rem;
    }
}

/* --- Медиа-запросы для планшетов и ПК --- */
@media screen and (min-width: 461px) {
    .ymaps-2-1-79-balloon__content {
        font: 13px/20px SFProDisplay-Regular, sans-serif !important;
    }

    [id^="id_"] .ymaps-2-1-79-balloon__content {
        display: inline-block !important;
    }

    .ymaps-2-1-79-b-cluster-content {
        height: 400px !important;
    }

    .ymaps-2-1-79-b-cluster-tabs__section {
        height: 400px !important;
    }

    .ymaps-2-1-79-b-cluster-tabs__content-item {
        padding-right: 0;
    }

    .body_img {
        max-width: 394px;
        max-height: 394px;
    }
}