/*
font-family: 'Gilroy';
font-family: 'PT Serif';
*/

html {
	/*font-size: 24px;*/
    font-size: 18px;
}
/*@media (max-width: 2551.98px) {
	html {
        font-size: 18px;
    }
}
@media (max-width: 1911.98px) {
	html {
        font-size: 18px;
    }
}*/
@media (max-width: 1023.98px) {
    html {
        font-size: 16px;
    }
}

body {
    font-family: 'Gilroy';
    font-size: 1rem;
    color: #333;
    font-weight: 400;
    background-color: #ebebeb;
}

.debug { background: RGBa(0,0,0,0.2); outline: 1px dotted #FF0000; }
.vertfix { display: inline-block; vertical-align: middle; height: 100%; width: 0; }

a,
a:hover {
    text-decoration: none;
}

p {
    margin: 0 0 12px 0;
}

.container {
    padding: 0;
    margin-left: 0;
}
@media (max-width: 1359.98px) {
	.container {
        margin-left: auto;
    }
}
/*@media (max-width: 767.98px) {
    .row {
        margin: 0;
    }
	.container.page {
        padding-left: 8px;
        padding-right: 8px;
    }
}*/

.tmpl-site-container {
    position: relative;
    display: flex;
    position: relative;
    min-height: 100vh;
}
.tmpl-left-container {
    position: relative;
    /*width: 480px;*/
    width: 320px;
    background-color: #fff;
    z-index: 1003;
}
.tmpl-main-container {
    flex: 1;
    position: relative;
    padding-top: 48px;
    padding-left: 98px;
}
@media (max-width: 2551.98px) {
    .tmpl-left-container {
        width: 320px;
    }
}
@media (max-width: 1911.98px) {
    .tmpl-site-container {
        min-height: calc(100vh - 80px);
        padding-top: 80px;
    }
    .tmpl-left-container {
        width: 328px;
        border-top-right-radius: 1rem;
        overflow: hidden
    }
    .tmpl-main-container {
        padding-top: 0;
        padding-left: 16px;
    }
}
@media (max-width: 1359.98px) {
    .tmpl-left-container {
        position: fixed;
        left: 0;
        top: 0;
        width: 320px;
        height: 100vh;
        border-radius: 0;
        overflow: scroll;
        box-shadow: 0 0 0 1000px rgba(0,0,0,.7);
        display: none;
    }
    .tmpl-main-container {
        padding-left: 0;
    }
}
@media (min-width: 1360px) {
    .tmpl-left-container {
        display: block !important;
    }
}
@media (max-width: 1023.98px) {
    .tmpl-site-container {
        min-height: calc(100vh - 56px);
        margin-top: 56px;
    }
    .tmpl-left-container {
        top: 56px;
        width: 100%;
        box-shadow: none;
        height: calc(100vh - 56px);
    }
}


.tmpl-page {
    background-color: #fff;
    border-radius: 1rem;
    padding: 2rem;
    min-height: calc(100vh - 96px);
    margin-bottom: 48px;
}
@media (max-width: 1911.98px) {
    .tmpl-page {
        border-radius: 1rem 1rem 0 0;
        padding: 1.6rem;
        min-height: calc(100vh - 80px);
        margin-bottom: 0;
    }
}
@media (max-width: 1359.98px) {
    .tmpl-page {
        border-radius: 1rem;
        min-height: calc(100vh - 104px);
        margin-bottom: 24px;
    }
}
@media (max-width: 1023.98px) {
    .tmpl-page {
        border-radius: 0;
        min-height: calc(100vh - 112px);
        margin-bottom: 0;
        padding: .8rem;
    }
}

.tmpl-header-container {    
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1100;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    height: 56px;
    background-color: #fff;
    margin-bottom: 24px;
    box-shadow: 0 4px 3px #d3d3d3;
    padding: 0 1rem;
}
@media (max-width: 1023.98px) {
    .tmpl-header-container {
        position: fixed;
        top: 0;
        width: 100%;
        justify-content: space-between;
        flex-direction: row-reverse;
        background-color: #4a7cd7;
        box-shadow: none;
        z-index: 1002;
    }
}


/* SITENAME ------------------------------------ */

.tmpl-left-sitename {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem 2.4rem;
    color: #000;
}
.tmpl-left-sitename .tmpl-logo {
    font-size: 1.8rem;
    font-weight: 900;
    color: inherit;
}
.tmpl-left-sitename .tmpl-change {
    font-size: .72rem;
    font-weight: 600;
    text-decoration: underline;
    text-transform: uppercase;
    cursor: pointer;
}
@media (max-width: 1359.98px) {
    .tmpl-left-sitename {
        padding: .8rem;
    }
    .tmpl-left-sitename .tmpl-logo {
        font-size: 1.2rem;
    }
    .tmpl-left-sitename .tmpl-change {
        flex-grow: 1;
        font-size: .6rem;
        padding: 0 1rem;
    }
}

.tmpl-top-sitename {
    width: calc(328px - 1rem);
    display: flex;
    align-items: center;
    color: #000;    
    margin-right: 16px;
}
.tmpl-top-sitename .tmpl-logo {
    font-size: 1.14rem;
    font-weight: 900;
    margin-right: 2rem;
    color: inherit;
}
.tmpl-top-sitename .tmpl-change {
    font-size: .66rem;
    font-weight: 600;
    text-decoration: underline;
    text-transform: uppercase;
    cursor: pointer;
}
@media (max-width: 1359.98px) {
    .tmpl-top-sitename {
        width: 180px;
        padding: 0;
        margin-right: 0;
    }
    .tmpl-top-sitename .tmpl-logo {
        margin-left: 1rem;
        margin-right: 0;
    }
}
@media (max-width: 1023.98px) {
    .tmpl-top-sitename {
        color: #fff;
        width: auto;
    }
    .tmpl-top-sitename .tmpl-logo {
        margin-left: 0;
        font-size: 1.78rem;
    }
}


.tmpl-top-toolbar {
    display: flex;
    align-items: center;
}
.tmpl-top-search {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    height: 56px;
    cursor: pointer;
    margin-right: 1rem;
}
.tmpl-top-search::before {
    display: block;
    content: "";
    width: 23px;
    height: 23px;
    background-image: url("/images/svg/ico-search.svg");
    background-position: center;
    background-repeat: no-repeat;
}
.tmpl-top-hamburger {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    height: 56px;
    color: #4a7cd7;
    cursor: pointer;
}
.tmpl-top-hamburger::before {
    display: block;
    content: "";
    width: 20px;
    height: 20px;
    background-image: url("/images/svg/ico-hamburger-blue.svg");
    background-position: center;
    background-repeat: no-repeat;
}
@media (max-width: 1023.98px) {
    .tmpl-top-hamburger::before {
        background-image: url("/images/svg/ico-hamburger.svg");
    }
}
.tmpl-top-hamburger.close::before {
    background-image: url("/images/svg/ico-close.svg");
}


.tmpl-menu-close {
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}
.tmpl-menu-close::before {
    display: block;
    content: "";
    width: 20px;
    height: 20px;
    background-image: url("/images/svg/ico-close-blue.svg");
    background-position: center;
    background-repeat: no-repeat;
}


/* MAIN MENU ------------------------------------ */

.tmpl-mainmenu {
    border-top: 1px solid #d6e0f2;
    border-bottom: 1px solid #d6e0f2;
    margin-bottom: 1.7rem;
}
.tmpl-mainmenu ul {
    list-style-type: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-wrap: nowrap;
}
.tmpl-mainmenu ul > li {
    flex-grow: 1;
    flex-shrink: 1;
    /*flex-basis: 0;*/ /* same width */
}
.tmpl-mainmenu ul > li > a {
    display: flex;
    flex-direction: column;
    height: 96px;
    font-size: .62rem;
    font-weight: 500;
    text-align: center;
    padding: 0 5px;
    /*transition:
        background-color .2s ease-in-out,
        color .2s ease-in-out;*/
}
.tmpl-mainmenu ul > li > a .img-wrap {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 68px;
}
.tmpl-mainmenu ul > li > a .img-wrap svg path {
    fill: #3477f6;
}
.tmpl-mainmenu ul > li > a .img-wrap.el_1 svg {
    /*width: 44px;
    height: 44px*/
    /*transform: scale(.86)*/
    width: 38px;
    height: 38px;
}
.tmpl-mainmenu ul > li > a .img-wrap.el_2 svg {
    /*width: 51px;
    height: 44px;*/
    width: 44px;
    height: 38px;
}
.tmpl-mainmenu ul > li > a .img-wrap.el_3 svg {
    /*width: 45px;
    height: 51px;*/
    width: 39px;
    height: 44px;
}
.tmpl-mainmenu ul > li > a .img-wrap.el_4 svg {
    /*width: 50px;
    height: 45px;*/
    width: 43px;
    height: 39px;
}
.tmpl-mainmenu ul > li > a .img-wrap.el_5 svg {
    /*width: 45px;
    height: 50px;*/
    width: 39px;
    height: 43px;
}
.tmpl-mainmenu ul > li > a .img-wrap.el_6 svg {
    /*width: 45px;
    height: 50px;*/
    width: 44px;
    height: 44px;
}
.tmpl-mainmenu ul > li.directly-active > a, 
.tmpl-mainmenu ul > li > a:hover {
    background-color: #4a7cd7;
    color: #fff;
}
.tmpl-mainmenu ul > li.directly-active > a .img-wrap svg path, 
.tmpl-mainmenu ul > li > a:hover .img-wrap svg path {
    fill: #fff;
}
@media (min-width: 1024px) and (max-width: 1911.98px) {
    .tmpl-mainmenu {
        border: none;
        margin-bottom: 0;
        margin-left: 1.6rem;
    }
    .tmpl-mainmenu ul > li > a {
        flex-direction: row;
        height: 56px;
        align-items: center;
        font-size: .76rem;
        padding: 0 .8rem;
    }
    .tmpl-mainmenu ul > li > a .img-wrap {
        height: 30px;
        margin-right: .4rem;
    }
    .tmpl-mainmenu ul > li > a .img-wrap.el_1 svg {
        width: 30px;
        height: 30px;
        /*transform: scale(.68)*/
    }
    .tmpl-mainmenu ul > li > a .img-wrap.el_2 svg {
        width: 35px;
        height: 30px;
    }
    .tmpl-mainmenu ul > li > a .img-wrap.el_3 svg {
        width: 31px;
        height: 35px;
    }
    .tmpl-mainmenu ul > li > a .img-wrap.el_4 svg {
        width: 34px;
        height: 31px;
    }
    .tmpl-mainmenu ul > li > a .img-wrap.el_5 svg {
        width: 31px;
        height: 34px;
    }
}
@media (max-width: 1359.98px) {
    .tmpl-mainmenu {
        margin-left: 0;
    }
}
@media (max-width: 1023.98px) {
    .tmpl-mainmenu {
        margin-top: 1.5rem;
        margin-bottom: 1.5rem;
    }
    .tmpl-mainmenu ul > li > a {
        padding: 0 .5rem;
        height: 68px;
        /*word-break: break-all;*/
    }
    .tmpl-mainmenu ul > li > a .img-wrap {
        height: 36px;
        margin: .5rem 0;
    }
    /* Исправить размер */
    .tmpl-mainmenu ul > li > a .img-wrap.el_1 svg {
        width: 30px;
        height: 30px;
        /*transform: scale(.68)*/
    }
    .tmpl-mainmenu ul > li > a .img-wrap.el_2 svg {
        width: 35px;
        height: 30px;
    }
    .tmpl-mainmenu ul > li > a .img-wrap.el_3 svg {
        width: 31px;
        height: 35px;
    }
    .tmpl-mainmenu ul > li > a .img-wrap.el_4 svg {
        width: 34px;
        height: 31px;
    }
    .tmpl-mainmenu ul > li > a .img-wrap.el_5 svg {
        width: 31px;
        height: 34px;
    }
}


/* LEFT MENU ------------------------------------ */

.tmpl-leftmenu {
    position: relative;
}
.tmpl-leftmenu ul {
    list-style-type: none;
    padding: 0;
    margin: 0;
}
.tmpl-leftmenu > ul > li {
    border-bottom: solid 1px #d6d7db;
}
.tmpl-leftmenu > ul > li:first-of-type {
    border-top: solid 1px #d6d7db;
}
.tmpl-leftmenu  a {
    font-size: .88rem;
    line-height: 1.1;
}
.tmpl-leftmenu ul > li > a {
    display: flex;
    align-items: center;
    height: 60px;
    padding: 0 1rem;
    color: #517bb5;
    transition:
        padding-left .3s ease-in-out,
        padding-right .3s ease-in-out;
}
/* Применяем отступ только к пунктам первого уровня без подменю */
.tmpl-leftmenu > ul > li:not(.submenu-exist) > a {
    padding-left: 2.3rem; /* 0.8rem (width) + 0.5rem (margin) + 1rem (original padding) */
}
.tmpl-leftmenu ul > li > a::before {
    display: none;
}
.tmpl-leftmenu ul > li.submenu-exist > a::before {
    display: flex;
    align-items: center;
    justify-content: center;
    content: "\f0da";
    width: .8rem;
    height: .8rem;
    font-family: 'Font Awesome 5 Free';
    color: #517bb5;
    font-weight: 700;
    font-size: .8rem;
    margin-right: .5rem;
}
/* Убираем фон для родительского элемента развернутого меню */
.tmpl-leftmenu ul > li > a.arrow-down {
    /* background-color: #e1e2e6; */ /* Убрано */
}
.tmpl-leftmenu ul > li > a.arrow-down::before {
    transform: rotate(90deg);
}
.tmpl-leftmenu > ul > li.indirectly-active,
.tmpl-leftmenu > ul > li.directly-active {
    border-top-color: transparent;
    border-bottom-color: transparent;
}
.tmpl-leftmenu > ul > li.indirectly-active > a,
.tmpl-leftmenu > ul > li.directly-active > a {
    background-color: #4a7cd7;
    color: #fff;
    font-weight: 700;
}
/* Уточненный селектор для активных подменю */
.tmpl-leftmenu > ul > li.submenu-exist > ul > li.directly-active > a {
    background-color: #4a7cd7;
    color: #fff; /* Переопределяем базовый цвет подменю */
    font-weight: 700;
}

.tmpl-leftmenu > ul > li.indirectly-active > a::before,
.tmpl-leftmenu > ul > li.directly-active > a::before,
/* Уточненный селектор для ::before активных подменю */
.tmpl-leftmenu > ul > li.submenu-exist > ul > li.directly-active > a::before {
    color: #fff;
}

.tmpl-leftmenu > ul > li.indirectly-active > a.arrow-down,
.tmpl-leftmenu > ul > li.directly-active > a.arrow-down {
    background-color: #4a7cd7;
}
.tmpl-leftmenu > ul > li.indirectly-active ul,
.tmpl-leftmenu > ul > li.directly-active ul {
    display: block;
}
.tmpl-leftmenu > ul > li:not(.submenu-exist) > a:hover:not(.arrow-down),
.tmpl-leftmenu > ul > li:not(.submenu-exist) > a.hover:not(.arrow-down) {
    padding-left: 2.55rem; /* 2.3rem (base padding) + 0.25rem (hover effect) */
}

.tmpl-leftmenu ul ul {
    display: none;
    background-color: #e1e2e6;
    margin: 0;
}
.tmpl-leftmenu > ul > li.active-submenu ul {
    display: block;
}
.tmpl-leftmenu ul ul > li {
    border-bottom: solid 1px #d6d7db;
}
.tmpl-leftmenu ul ul > li:last-of-type {
    border-bottom: none;
}
/* Используем более специфичный селектор для подменю - ТОЛЬКО PADDING */
.tmpl-leftmenu > ul > li.submenu-exist > ul > li > a {
    padding-left: 3.6rem; /* 2.3rem (aligned base) + 1.3rem (additional indent) */
    padding-right: 1rem;
    /* color: #4a7cd7; <-- Убрали цвет отсюда */
}
/* Базовый цвет для ссылок подменю */
.tmpl-leftmenu > ul > li.submenu-exist > ul > li > a {
    color: #4a7cd7;
}

/* И для состояния hover - ТОЛЬКО PADDING */
.tmpl-leftmenu > ul > li.submenu-exist > ul > li > a:hover:not(.arrow-down),
.tmpl-leftmenu > ul > li.submenu-exist > ul > li > a.hover:not(.arrow-down) {
    padding-left: 3.85rem; /* 3.6rem base + 0.25rem (hover effect) */
    padding-right: .75rem;
    /* Цвет при наведении будет наследоваться или управляться другими правилами */
}

/* И добавляем правило для hover, когда подменю развернуто */
.tmpl-leftmenu > ul > li.submenu-exist > a.arrow-down:hover {
    padding-left: 1.25rem; /* Базовый 1rem + 0.25rem сдвиг */
    padding-right: .75rem;
}

@media (max-width: 1911.98px) {
    .tmpl-leftmenu ul > li > a {
        height: 48px;
    }    
}
@media (min-width: 1024px) and (max-width: 1911.98px) {
    .tmpl-leftmenu > ul > li:first-of-type {
        border-top: none;
    }
}
@media (max-width: 1023.98px) {
    .tmpl-leftmenu ul > li > a {
        height: 38px;
    }    
}


/* CONTENT STYLE ----------------------------- */

.content h1 {
    font-size: 1.5rem;
    font-weight: 700;
}
.content h2 {
    font-size: 1.25rem;
    font-weight: 700;
}
.btn-after {
    display: flex;
    align-items: center;
}
.btn-after .btn-after-item {
    display: flex;
    align-items: center;
    margin-left: .88rem;
    color: #4a7cd7;
    cursor: pointer;
    opacity: .65;
}
.btn-after .btn-after-item.link::after {
    display: block;
    content: "";
    width: 20px;
    height: 20px;
    background-image: url("/images/svg/ico-link.svg");
    background-position: center;
    background-repeat: no-repeat;
}


.content p {
    font-family: 'PT Serif';
    line-height: 1.3rem;
}
.content a {
    color: #4a7cd7;
    text-decoration: none;
}
.content a:hover {
    text-decoration: underline;
}

table.custom1 tr {
    border-bottom: 1px solid #d1d1d1;
}
table.custom2 tr > td:first-of-type {
    color: #4a7cd7;
}
table.custom2 tr > td:last-of-type {
    color: #4a7cd7;
    text-align: right;
}

.content .text-secondary {
    color: #b2b5bf !important;
}

.content .cite {
    display: block;
    border-left: 6px solid #d0b198;
    padding-left: 32px;
    margin-top: 1rem;
    margin-bottom: 1rem;
}

.content hr {
    background-color: #c1c1c1;
    opacity: 1;
}
.content hr.dark {
    background-color: #333;
}


/* FILTER-TOOLBAR ---------------------------- */

.filter-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: .5rem 0;
    font-size: .88rem;
}
.filter-toolbar .search {
    display: flex;
    align-items: center;   
}
.filter-toolbar .search::before {
    display: block;
    content: "";
    flex-shrink: 0;
    width: 42px;
    height: 31px;
    background-image: url('/images/svg/ico-filter-search.svg');
    background-repeat: no-repeat;
    background-position: center center;
    background-size: 24px 24px;
}
.filter-toolbar .search input {
    border: none;
    background: none;
}
.filter-toolbar .search input::placeholder {
    color: #4a7cd7;
}
.filter-toolbar .search input:focus,
.filter-toolbar .search input:active { outline: none; }

.filter-toolbar .button {
    display: flex;
    align-items: center;
    color: #4a7cd7;
    cursor: pointer;
    margin-left: 1rem;
}
.filter-toolbar .button::before {
    display: block;
    content: "";
    flex-shrink: 0;
    height: 32px;
    width: 32px;
    background-repeat: no-repeat;
    background-position: center center;
    margin-right: 6px;
}
.filter-toolbar .button.filter::before {
    width: 28px;
    background-image: url('/images/svg/ico-filter.svg');
}
.filter-toolbar .button.filter:hover::before,
.filter-toolbar .button.filter.active::before {
    background-image: url('/images/svg/ico-filter-a.svg');
}
.filter-toolbar .button.parameter::before {
    width: 35px;
    background-image: url('/images/svg/ico-filter-parameter.svg');
}
.filter-toolbar .button.parameter:hover::before,
.filter-toolbar .button.parameter.active::before {
    background-image: url('/images/svg/ico-filter-parameter-a.svg');
}
@media (max-width: 1911.98px)  {
    .filter-toolbar .button.filter::before {
        width: 22px;
    }
    .filter-toolbar .button.parameter::before {
        width: 28px;
    }
}
@media (max-width: 1023.98px) {
    .filter-toolbar .button span {
        display: none;
    }
}

.btn-like {
    display: flex;
    height: 30px;
    width: 30px;
    background-image: url('/images/svg/ico-like.svg');
    background-repeat: no-repeat;
    background-position: center center;
    cursor: pointer;
}
.btn-like.active {
    background-image: url('/images/svg/ico-like-a.svg');
}
@media (max-width: 1911.98px)  {
    .btn-like {
        width: 24px;
    }
}

.tmpl-card {
    display: flex;
    flex-direction: column;
    border: 1px solid #d1d1d1;
    padding: .5rem 0;
}
.tmpl-card.grayscale {
    background-color: #f1f1f1;
    color: #7e7e7e;
    border: none;
}
.tmpl-card .tmpl-card-header {
    display: flex;
    align-items: center;
    padding: .5rem 1rem;
    color: #4a7cd7;
}
.tmpl-card.grayscale .tmpl-card-header {
    font-size: 1.1rem;
    color: #7e7e7e;
    font-weight: 500;
}
.tmpl-card .tmpl-card-body {
    padding: .5rem 1rem;
}

.tmpl-label {
    display: block;
    padding: .2rem .5rem;
    background-color: #d0b198;
    color: #fff;
    text-decoration: underline;
}

.form-title {    
    display: flex;
    align-items: center;
    padding: 0 .5rem;
    font-weight: 700;
    text-transform: uppercase;
    border-bottom: 2px solid #333;
    margin-bottom: .75rem;
    min-height: 2.8rem;
}
.form-title.secondary {
    border-bottom: 1px solid #999;
    /*box-shadow: 0 1px 0 #999;*/
    padding-left: 0;
    padding-right: 0;
}
.form-title a {
    font-size: 1rem;
    text-transform: none;
    font-weight: 400;
}
.form-title .rounds {
    display: flex;
    align-items: center;
    font-size: 1rem;
    text-transform: none;
    margin-left: 1rem;
}
.form-title .rounds input[type="text"] {
    appearance: none;
    margin-left: .8rem;
    border: 1px solid #4a7cd7;
    color: #4a7cd7;
    text-align: center;
    width: 2rem;
    height: 2rem;
    padding: 0;
}
@media (max-width: 1023.98px) {
    .form-title .rounds {
        margin-left: 0;
    }
}


/* Buttons */
.tmpl-buttons {
	display: flex;
	align-items: center;
	justify-content: space-between;
}
.tmpl-buttons.right {
	justify-content: flex-end;
}
.tmpl-buttons.left {
	justify-content: flex-start;
}
.tmpl-buttons.center {
    justify-content: center;
}
.tmpl-button {
	display: flex;
	align-items: center;
	justify-content: center;
	height: 48px;
	border: 1px solid #4a7cd7;
	background-color: #4a7cd7;
	color: #fff;
	padding: 0 16px;
    z-index: auto;
    transition:
        box-shadow .15s ease-in-out;
}
.tmpl-button.small {
    height: 36px;
}
.tmpl-button.large {
    height: 72px;
}
.tmpl-button:not(:disabled):hover {
    cursor: pointer;
	text-decoration: none;
    box-shadow: 0 0 0 .2rem rgba(74,124,215,.25);
    z-index: 10;
}
.tmpl-buttons.full .tmpl-button {
    flex-grow: 1;
    flex-shrink: 1;
    flex-basis: 0;
}
.tmpl-buttons .tmpl-button:not(:first-child) {
    margin-left: -1px;
}
.tmpl-button.full {
	flex-grow: 1;
}
.tmpl-button.bordered {
    background-color: #fff;
	color: #4a7cd7;
}
/*.tmpl-buttons.full .tmpl-button.bordered {
    margin-right: -1px;
}*/
.tmpl-button.bordered:not(:disabled).active {
    background-color: #4a7cd7;
	color: #fff;
}
.tmpl-button.simple {
    border-color: transparent;
    background-color: transparent;
	color: #4a7cd7;
}
.tmpl-buttons.right .tmpl-button,
.tmpl-buttons.left .tmpl-button,
.tmpl-buttons.center .tmpl-button {
    min-width: 12rem;
}
@media (max-width: 1023.98px) {
    .tmpl-buttons.mobile-style2 .tmpl-button {
        color: #999;
        border: none;
        border-bottom: 1px solid #999;
    }
    .tmpl-buttons.mobile-style2 .tmpl-button:not(:disabled).active {
        background-color: #fff;
        color: #4a7cd7;
        border-bottom: 1px solid #4a7cd7;
        box-shadow: inset 0 -8px 0 0 #4a7cd7;
    }
}
.tmpl-button:disabled {
    background-color: #fff;
    border: 1px solid #bfc9d0;
    color: #b5c1c9;
}


.input-file {
	position: relative;
    display: flex;
    flex-grow: 1;
    flex-shrink: 1;
    flex-basis: 0;
    font-weight: 400;
}
.input-file input[type=file] {
	position: absolute;
	opacity: 0;
	display: block;
	width: 0;
	height: 0;
    z-index: -1;
}


.param-line {
    display: flex;
    align-items: center;
}
.param-line .label {
    margin-right: 1.7rem;
}
.color-selector {
    display: flex;
    width: 80px;
    height: 40px;
    box-shadow: inset 0 0 0 1px RGBa(0,0,0,.3);
    cursor: pointer;
}
.color-selector.disabled {
    align-items: center;
    justify-content: end;
    color: #4a7cd7;
    font-size: 1.2rem;
    box-shadow: none;
}
.color-selector:not(.disabled):hover {
    box-shadow: 0 0 0 .2rem rgba(74,124,215,.25);
}


/* Forms */
input[type="text"],
input[type="number"],
textarea {
    width: 100%;
    padding: 0.375rem 0.75rem;
    border-radius: 0;
    line-height: 1.5;
    color: #212529;
    background-color: #fff;
    border: 1px solid #ddd;
    transition:
        border-color 0.15s ease-in-out,
        box-shadow 0.15s ease-in-out;
}
textarea {
    padding: 1rem;
    resize: vertical;
}
input[type="text"]:focus,
input[type="text"]:focus-visible,
input[type="number"]:focus,
input[type="number"]:focus-visible,
textarea:focus,
textarea:focus-visible {
    outline: none;
    border-color: #86b7fe;
    box-shadow: 0 0 0 .2rem rgba(74,124,215,.25);
}
input[type="text"]::placeholder,
input[type="number"]::placeholder {
    color: #d1d1d1;
}


/* checkbox */
.form-check {
    display: flex;
    align-items: center;
}
.form-check-input {
    width: 1.5rem;
    height: 1.5rem;
    border: 1px solid #4a7cd7;
    margin: 0 .5rem 0 0;
}
.form-check-input[type=checkbox] {
    border-radius: 0;
}
.form-check-input:checked {
    border-color: #4a7cd7;
    background-color: #4a7cd7;
}


/* input range */
input[type="range"]:focus::-webkit-slider-thumb {
    box-shadow: 0 0 0 1px #fff, 0 0 0 .2rem rgba(74,124,215,.25);
}
input[type="range"]:focus::-moz-range-thumb {
    box-shadow: 0 0 0 1px #fff, 0 0 0 .2rem rgba(74,124,215,.25);
}
input[type="range"]::-webkit-slider-thumb {
    width: 1.3rem;
    height: 1.3rem;
    margin-top: calc(-0.65rem + 1px);
    background-color: #fff;
    border: 1px solid #4a7cd7;
}
.form-range::-webkit-slider-thumb:active {
    background-color: #fff;
}
.form-range::-webkit-slider-runnable-track {
    height: 2px;
    background-color: #4a7cd7;
    border-radius: 0;
}


/* Slidechecker */
input[type="checkbox"].tmpl-slidechecker {
    display: none;
}
input[type="checkbox"].tmpl-slidechecker + label {
    display: block;
    position: relative;
    height: 24px;
    width: 44px;
    border: 1px solid #4a7cd7;
    border-radius: 22px;
    padding: 1px;
    cursor: pointer;
    transition: margin .2s ease-in-out;
}
input[type="checkbox"].tmpl-slidechecker:disabled + label {
    opacity: .7;
    cursor: default;
}
input[type="checkbox"].tmpl-slidechecker:not(:disabled) + label:hover {
    box-shadow: 0 0 0 .2rem rgba(74,124,215,.25);
}
input[type="checkbox"].tmpl-slidechecker + label::before {
    content: "";
    display: block;
    position: absolute;
    width: 20px;
    height: 20px;
    background-color: #4a7cd7;
    border-radius: 50%;
    top: 1px;
    left: 0;
    margin-left: 1px;
    transition: margin .2s ease-in-out;
}
input[type="checkbox"].tmpl-slidechecker:checked + label {
    background-color: #4a7cd7;
}
input[type="checkbox"].tmpl-slidechecker:checked + label::before {
    margin-left: 21px;
    background-color: #fff;
}

/* Preview */
.tmpl-preview {
    position: relative;
    height: 364px;
    border: 1px solid #d1d1d1;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}
.tmpl-preview.type2 {
    border-style: dashed;
    height: auto;
    padding-top: 3rem;
    padding-bottom: 3rem;
}
.tmpl-preview .info {
    text-align: center;
    font-weight: 700;
    z-index: 2;
}
.tmpl-preview .info .muted {
    color: #d1d1d1;
    font-weight: 400;
}
.tmpl-preview .info .ext {
    font-size: 1.3rem;
    text-transform: uppercase;
    color: #d1d1d1;
    font-weight: 500;
}
.tmpl-preview .button-alpha {
    display: flex;
    align-items: center;
    color: #4a7cd7;
    cursor: pointer;
    position: absolute;
    left: 1rem;
    bottom: 1rem;
    z-index: 3;
}
.tmpl-preview .button-alpha::before {
    display: block;
    content: "";
    flex-shrink: 0;
    height: 32px;
    width: 35px;
    background-image: url(/images/svg/ico-filter-parameter.svg);
    background-repeat: no-repeat;
    background-position: center center;
    margin-right: 6px;
}
.tmpl-preview .circle {
    position: absolute;
    border: 10px solid #f8f8f8;
    width: 12rem;
    height: 12rem;
    left: calc(50% - 6rem);
    top: calc(50% - 6rem);
    border-radius: 50%;
    z-index: 1;
}

.tmpl-borders-grid {
    display: grid;    
    grid-template-columns: repeat(4, 1fr);;
    gap: 12px;
}
.tmpl-borders-grid > div {
    aspect-ratio: 1 / 1;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: #333;
    color: #fff;
    cursor: pointer;
}
.tmpl-borders-grid > div:hover {
    opacity: .9;
}

hr.tmpl-line {
    margin: 0;
    border-bottom: 1px solid #333;
    box-shadow: 0 1px 0 #a0a0a0;
}
hr.tmpl-line.grey {
    border-bottom: 2px solid #c9d2d7;
    box-shadow: none;
}

.tab-borders {
    padding: .8rem;
}

.tmpl-a4print-panel-wrapper {
    position: relative;
}
.tmpl-a4print-panel-wrapper.flex {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.tmpl-token-size {
    display: flex;
    align-items: center;
    font-size: 1.3rem;
    font-weight: 700;
}
.tmpl-token-size input[type="number"] {
    appearance: none;
    margin: 0 .8rem;
    border: 1px solid #4a7cd7;
    border-radius: 0;
    color: #4a7cd7;
    font-size: 1rem;
    text-align: center;
    padding-top: 0;
    padding-bottom: 0;
    /*padding-left: .75rem;*/
    padding-left: 0;
    padding-right: 0;
    height: 2rem;
    width: 3.5rem;
}
.tmpl-token-size input[type="number"]:focus,
.tmpl-token-size input[type="number"]:active,
.tmpl-token-size input[type="number"]:focus-visible {
    outline: none !important;
}

.tmpl-pawn-size {
    font-size: 1.3rem;
    font-weight: 700;
}
.tmpl-pawn-size-selector {

}

.tmpl-a4print-panel-wrapper .button {
    display: flex;
    align-items: center;
    color: #4a7cd7;
    cursor: pointer;
    margin-left: 1rem;
}
.tmpl-a4print-panel-wrapper .button::before {
    display: block;
    content: "";
    flex-shrink: 0;
    width: 22px;
    height: 16px;
    background-repeat: no-repeat;
    background-position: center center;
    margin-right: 6px;
}
.tmpl-a4print-panel-wrapper .button.preview::before {
    background-image: url('/images/svg/ico-filter-parameter.svg');
}


.tmpl-a4-info {
    background-color: #f1f1f1;
    padding: 1rem;
}
.tmpl-a4-info p {
    font-family: 'Gilroy';
}

.tmpl-a4-template {
    position: relative;
    border: 1px solid #d1d1d1;
    padding: 2rem;
    height: 100%;
}
.tmpl-a4-template .a4-grid-wrapper {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    background-repeat: no-repeat;
    background-size: contain;
    background-position: center;
}
.tmpl-a4-template .a4-grid {
    display: grid;
    width: 100%;
    /*grid-template-columns: repeat(7, 1fr);*/
    /*gap: 8px;*/
}
.tmpl-a4-template .a4-grid > div {
    display: none;
    aspect-ratio: 1 / 1;
    background-color: #d1d1d1;
    background-repeat: no-repeat;
    background-position: center;
    background-size: contain;
}
.tmpl-a4-template .a4-grid > div.active {
    background-color: transparent;
    border: 1px dotted #ddd;
}
.tmpl-a4-template .size-label {
    position: absolute;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #d1d1d1;
    font-size: .7rem;
    width: 2rem;
    height: 1rem;
}
.tmpl-a4-template .size-label.x {
    top: 0;
    left: calc(50% - 1rem);
}
.tmpl-a4-template .size-label.y {
    transform: rotate(-90deg);
    left: -.5rem;
    top: calc(50% - .5rem);
}
/* Pawn */
.tmpl-a4-template .a4-grid-wrapper-pawn {
    display: none;
    /*display: flex;*/
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
}
.tmpl-a4-template .a4-grid-1 {
    display: grid;
    width: 100%;
    grid-template-columns: repeat(7, 1fr);
    column-gap: 0;
    row-gap: 10px;
}
.tmpl-a4-template .a4-grid-1.line1 {
    margin-bottom: 51px;
}
.tmpl-a4-template .a4-grid-1.line2 {
    margin-top: 51px;
}
@media (max-width: 1359.98px) {
    .tmpl-a4-template .a4-grid-1 {
        row-gap: 8px;
    }
    .tmpl-a4-template .a4-grid-1.line1 {
        margin-bottom: 46px;
    }
    .tmpl-a4-template .a4-grid-1.line2 {
        margin-top: 46px;
    }
}
.tmpl-a4-template .a4-grid-2 {
    padding: 0 15px;
    display: grid;
    width: 100%;
    grid-template-columns: repeat(3, 1fr);
    column-gap: 0;
    row-gap: 12px;
}
.tmpl-a4-template .a4-grid-3 {
    padding: 0 47px;
    display: grid;
    width: 100%;
    grid-template-columns: repeat(2, 1fr);
    column-gap: 0;
    row-gap: 14px;
}
@media (max-width: 1911.98px)  {
    .tmpl-a4-template .a4-grid-3 {
        row-gap: 18px;
    }
}
.tmpl-a4-template .a4-grid-1 > div,
.tmpl-a4-template .a4-grid-2 > div,
.tmpl-a4-template .a4-grid-3 > div {
    /*display: none;*/
    /*background-color: #d1d1d1;*/
    aspect-ratio: 1 / 1;
    background-repeat: no-repeat;
    background-position: center;
    background-size: contain;
}
.tmpl-a4-template div.mirror {
    transform: rotate(180deg);
}

.tmpl-a4-template .pawn-mask {
	position: absolute;
	left: 2rem;
	top: 2rem;
    right: 2rem;
    bottom: 2rem;
	background-repeat: no-repeat;
	background-position: center;
	background-size: contain;
}

@media (max-width: 1911.98px)  { 
    .tmpl-buttons#pawn-sizes-selector {
        flex-wrap: nowrap;
        justify-content: space-between;
        
    }
    .tmpl-buttons#pawn-sizes-selector .tmpl-button {
        min-width: auto;
        flex-grow: 1;
        flex-shrink: 0;
    }
}


/* Tracker */
.tmpl-a4-template .a4-grid-wrapper-tracker {
    /*display: none;*/
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
}
.tmpl-a4-template .tracker-mask {
	position: absolute;
	left: 2rem;
	top: 2rem;
    right: 2rem;
    bottom: 2rem;
	background-repeat: no-repeat;
	background-position: center;
	background-size: contain;
}
.tmpl-a4-template .a4-grid-tracker {
    padding-left: 189px;
    padding-right: 45px;
    display: grid;
    width: 100%;
    grid-template-columns: 1fr;
    column-gap: 0;
    row-gap: 12px;
}
.tmpl-a4-template .a4-grid-tracker > div {
    aspect-ratio: 1 / 1;
    background-repeat: no-repeat;
    background-position: center;
    background-size: contain;
    transform: rotate(-90deg);
}
@media (max-width: 1911.98px)  {
    .tmpl-a4-template .a4-grid-tracker {
        padding-left: 183px;
    }
}
@media (max-width: 1359.98px) {
    .tmpl-a4-template .a4-grid-tracker {
        padding-left: 172px;
        padding-right: 43px;
    }
}
@media (max-width: 1023.98px) {
    .tmpl-a4-template .a4-grid-tracker {
        padding-left: 169px;
        padding-right: 43px;
    }
}


@media (max-width: 1023.98px) {
    /*.tmpl-a4-wrapper {
        display: flex;
        justify-content: center;
    }
    .tmpl-a4-template {
        width: 340px;
    }*/
    #mobile-a4 {
        width: 340px;
    }
}
@media (min-width: 1024px) {
    .tab-pane.desktop-show {
        display: block;
        opacity: 1;
    }
}

@keyframes shake {
    10%, 90% {
        transform: translate3d(-1px, 0, 0);
    }
    20%, 80% {
        transform: translate3d(1px, 0, 0);
    }
    30%, 50%, 70% {
        transform: translate3d(-2px, 0, 0);
    }
    40%, 60% {
        transform: translate3d(2px, 0, 0);
    }
}
#btn-print.animated {
    animation: shake 0.6s cubic-bezier(.36,.07,.19,.97) both;
    transform: translate3d(0, 0, 0);
    backface-visibility: hidden;
}


/* Modal */
.modal .modal-header {
    border-bottom: none;
    font-size: 1.8rem;
}
.modal .btn-close {
    background-image: url("/images/svg/ico-close-blue.svg");
    opacity: 1;
    background-size: 22px 22px;
}

/* Добавляем правило для hover у родительских пунктов с подменю */
.tmpl-leftmenu > ul > li.directly-active > a.arrow-down {
    background-color: #4a7cd7;
}

/* Добавляем правило для hover у родительских пунктов с подменю */
.tmpl-leftmenu > ul > li.submenu-exist > a:hover:not(.arrow-down) {
    padding-left: 1.25rem; /* Базовый 1rem + 0.25rem сдвиг */
    padding-right: .75rem; /* Выравниваем правый отступ при hover */
}

.tmpl-leftmenu > ul > li.indirectly-active ul,
.tmpl-leftmenu > ul > li.directly-active ul {
    display: block;
}
