/*=====Основные настройки страницы=====*/
*{
    box-sizing: border-box;
}

body{
    padding: 12px;
    margin: 24px;
    font-family: Georgia, Cambria, "Times New Roman", Times, serif;
    padding-top: 4rem;
}

/*=====Реализация блоков flexbox=====*/

/*Основной блок container*/
.container{
    display: flex;
    flex-wrap: wrap;
    margin: 0 auto;
    max-width: 1600px;
}

.navigation{
    display: flex;
    flex: 1 1 50%;
    gap: 20px;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;   
    padding: 25px 20px;
    background-color: none;
    
}

/*=== Реализация навигации ===*/

/* Шапка сайта */

.site-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;

    display: flex;
    justify-content: space-between;
    align-items: center;

    padding: 10px 5%;
    box-sizing: border-box;

    background: #ffffff;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
}

/* Логотип */

.logo img {
    display: block;
    width: 120px;
    height: auto;
    object-fit: contain;
}

/* Кнопка бургера */

.burger {
    width: 50px;
    height: 45px;

    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 7px;

    background: none;
    border: none;
    cursor: pointer;
    z-index: 1002;
}

.burger span {
    width: 32px;
    height: 3px;
    background: #263b59;
    border-radius: 5px;

    transition: 0.3s ease;
}

/* Анимация бургера */

.burger.active span:nth-child(1) {
    transform: translateY(10px) rotate(45deg);
}

.burger.active span:nth-child(2) {
    opacity: 0;
}

.burger.active span:nth-child(3) {
    transform: translateY(-10px) rotate(-45deg);
}

/* Выпадающее меню */

.nav-menu {
    position: absolute;
    top: calc(100% + 10px);
    right: 5%;

    width: 300px;
    padding: 25px;

    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 22px;

    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.15);

    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);

    transition: 0.3s ease;
}

/* Открытое меню */

.nav-menu.open {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

/* Ссылки */

.nav-menu ul {
    display: flex;
    flex-direction: column;
    gap: 18px;

    list-style: none;
    padding: 0;
    margin: 0;
}

.nav-menu ul a {
    color: #263b59;
    text-decoration: none;
    font-size: 16px;
    font-weight: 600;

    transition: 0.2s ease;
}

.nav-menu ul a:hover {
    color: #8299ba;
}

/* Кнопка проекта */

.link-button {
    display: block;
    padding: 12px 15px;

    text-align: center;
    text-decoration: none;

    color: white;
    background: #263b59;
    border-radius: 7px;

    transition: 0.3s ease;
}

.link-button:hover {
    background: #405b80;
}

/* Переключатель языков */

.language-switch {
    display: flex;
    align-items: center;
    gap: 5px;

    padding: 4px;
    background: #f1f3f6;
    border: 1px solid #dfe4eb;
    border-radius: 8px;
}

.language-switch a {
    padding: 7px 12px;
    border-radius: 5px;

    color: #596579;
    text-decoration: none;
    font-size: 13px;
    font-weight: 600;
}

.language-switch a.active {
    color: white;
    background: #263b59;
}
/*============================*/

.text-block-1{
    display: flex;
    flex: 1 1 100%;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center; 
    padding: 25px 20px;
    background-color: #fff7e6;
}

.text-block-1 h1{
    color: #2d4d68;
    margin: 0 auto;
    font-size: 30px;
    font-weight: 500;
    letter-spacing: -0.3px;
}

.text-block-1 p{
    text-align: center;
    line-height: 1.9;
    
    color: #737F88;
    font-size: 15px;
}

.navigation img{
    width: 60px;
    height: 60px;
}

/*Реалізація кнопкі*/

.link-button {
    display: inline-flex;
    align-items: start;
    justify-content: center;
    gap: 12px;

    padding: 14px 24px;
    background-color: #05386B;
    color: #EDF5E1;

    
    font-size: 13px;
    font-weight: 700;
    text-decoration: none;

    
    border-radius: 12px;

    transition:
        background-color 0.3s ease,
        color 0.3s ease,
        transform 0.3s ease,
        box-shadow 0.3s ease;
}

.link-button:hover {
    background-color: #A9B7C6;
    color: #05386B;
    
    transform: translateY(-3px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.15);
}
/*Реализация блока карточки*/
.content-block-2{
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    width: 100%;
    justify-content: center;
    padding: 25px 40px;   
    background-color: #fff7e6;
}

.card-3{   
    display: flex;
    flex-direction: column;
    flex: 1 1 300px;
    padding: 25px;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    overflow: hidden;
    background: #fff;

    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card-3:hover{
    transform: scale(1.03);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
}

.card-3 h3{
    color: #2d4d68;
    text-align: center;
    font-size: 20px;
    font-weight: 500;
    letter-spacing: -0.3px;
}

.card-3 p{
    text-align: center;
    line-height: 1.9;
    
    color: #737F88;
    font-size: 15px;
}

.gallery{
    flex: 1 1 100%;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 10px;
    background-color: #fff7e6;

    padding: 15px 15px;
}

.gallery-item{
    overflow: hidden;
    aspect-ratio: 1 / 1;
    border-radius: 10px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
}

.gallery-item img{
    display: block;
    width: 200%;
    height: auto;
    object-fit: cover;
    
}

.gallery-viewer{
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.8);
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.gallery-viewer.active{
    display: flex;
}

.gallery-viewer img{
    max-width: 90%;
    max-height: 90%;

    object-fit: contain;
}

/*   Реализация закрытия беблиотеки */

.gallery-close{
    position: absolute;
    top: 20px;
    right: 30px;
    font-size: 40px;
    color: white;
    background: none;
    border: none;
    cursor: pointer;
}

/*   Реализация вправо влево по галереи */

.gallery-prev,
.gallery-next{
    position: absolute;
    top: 50%;
    transform: translateY(-50%);

    font-size: 30px;
    color: white;
    background: none;
    border: none;
    cursor: pointer;
}

.gallery-prev{
    left: 30px;
}

.gallery-next{
    right: 30px;
}
/*Реализация эфекта приближения*/
.photo-hover {
    transition: transform 0.4s ease, box-shadow 0.4s ease;
}

.photo-hover:hover {
    transform: translateY(-8px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.25);
}

/*Плавное проявление элемента*/
/* Начальное состояние элемента */
.reveal {
    opacity: 0;
    transform: translateY(25px);
    transition:
        opacity 0.7s ease,
        transform 0.7s ease;
}

/* Элемент появился в области просмотра */
.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

.content-text-4{
    display: flex;
    flex: 1 1 100%;
    flex-wrap: wrap;
    justify-content: space-around;
    align-items: center;
    padding: 25px 20px;
    background-color: #2D3A47;
}

.content-text-4{
    color: #fff7e6;
}

/* Контейнер-обертка (нужен только для ширины) */
.btn-1 {
  width: 100%;
  box-sizing: border-box;
}

/* Сама кнопка-ссылка (делаем кликабельной всю площадь) */
.btn-1 a {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px; /* На случай, если добавишь иконку или стрелочку */
  
  width: 100%;
  padding: 14px 24px; /* Делаем кнопку чуть выше и солиднее */
  box-sizing: border-box;
  
  /* Благородный градиент на основе твоего цвета #2d4d68 */
  background: linear-gradient(135deg, #365c7c 0%, #243f56 100%);
  color: #fff8d9;
  
  font-weight: 600; /* Исправили font-size на font-weight */
  font-size: 15px;
  letter-spacing: 0.4px; /* Легкая разрядка букв для премиального вида */
  text-decoration: none;
  
  border-radius: 12px;
  border: 1px solid rgba(255, 248, 217, 0.15); /* Тончайшая рамка в цвет текста */
  
  /* Мягкая внешняя тень + легкий блик по верхнему краю */
  box-shadow: 
    0 4px 12px rgba(45, 77, 104, 0.25),
    inset 0 1px 0 rgba(255, 255, 255, 0.15);

  transition: all 0.25s cubic-bezier(0.25, 0.8, 0.25, 1);
}

/* Эффект при наведении мыши */
.btn-1 a:hover {
  /* Вариант А: кнопка становится ярче и насыщеннее, текст остается светлым */
  background: linear-gradient(135deg, #3f6b90 0%, #2d4d68 100%);
  color: #ffffff;
  
  transform: translateY(-2px);
  box-shadow: 
    0 8px 20px rgba(45, 77, 104, 0.35),
    inset 0 1px 0 rgba(255, 255, 255, 0.25);
}

/* Эффект реального нажатия (кнопка слегка утапливается) */
.btn-1 a:active {
  transform: translateY(0);
  box-shadow: 0 2px 6px rgba(45, 77, 104, 0.3);
}

.text-block-4{
    display: flex;
    flex: 1 1 100%;
    padding: 20px 20px;
    font-size: 12px;
}

.text-block-4 span{
    color: #2d4d68;
}

.text-block-4 a{
    text-decoration: none;
    color: #2d4d68;
}

.text-block-4 a:hover{
    color: #737F88;
}

/* Учитываем настройку уменьшения анимации */
@media (prefers-reduced-motion: reduce) {
    .reveal {
        opacity: 1;
        transform: none;
        transition: none;
    }
}

@media (max-width: 800px){
    .gallery{
        grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    }
    
    .gallery-item img{
        
        width: 180%;
        height: auto; 
    }

    body{
        padding: 8px;
        margin: 14px;
        padding-top: 5.5rem;
    }
}
