/* ===== Общий контейнер ===== */
.container {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0;
}
/* ===== Header ===== */
.header {
  width: 100%;
  background: #afe6ff;
}

/* ===== Верхняя панель ===== */

.top-bar-inner {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
}

.header-title {
 display: flex;
  justify-content: center;
  text-align: center;
}

.header-title span {
  max-width: 900px;
  margin: 0 auto;
  font-family: 'Baloo 2', cursive;
  font-weight: 800;
  font-size: 28px;
  line-height: 1.25;
  color: #0c5d7f;
  text-shadow:
    -1px -1px 0 #ffffff,
     1px -1px 0 #ffffff,
    -1px  1px 0 #ffffff,
     1px  1px 0 #ffffff,
     0 3px 6px rgba(0,0,0,0.15);
}

@media (max-width: 768px) {
  .top-bar-inner {
    grid-template-columns: 1fr;
    gap: 12px;
    text-align: center;
  }

  .logo {
    width: auto;
  }
}

/* .logo span {
  margin-left: auto;
  margin-right: auto;
  font-family: 'Baloo 2', cursive;
  font-weight: 800;
  font-size: 28px;
  letter-spacing: 0.4px;
  color: #0c5d7f;
  text-align: center;
  text-shadow:
    -1px -1px 0 #ffffff,
     1px -1px 0 #ffffff,
    -1px  1px 0 #ffffff,
     1px  1px 0 #ffffff,
     0 3px 6px rgba(0,0,0,0.15);
  letter-spacing: 0.3px;
  line-height: 1.25;
  white-space: normal;        
  word-break: break-word;
  overflow-wrap: break-word;
  max-width: 900px;
  display: block;
  animation: soft-float 2s ease-in-out infinite;
} */

@keyframes soft-float {
  0%   { transform: translateY(0); }
  50%  { transform: translateY(-2px); }
  100% { transform: translateY(0); }
}

.lang{
  max-width: 100%;
}
.lang a {
  text-decoration: none;
  color: #1c759b;
  font-size: 18px;
  margin: 0 4px;
}

/* ===== Навигация ===== */
.nav {
  background-color: #afe6ff;   /* ← ТОЧНО ТАКОЙ ЖЕ */
  background-position: center;
  background-size: 100% 100%;
  position: sticky;
  top: 0;
  z-index: 100;
  padding-top: -20px;
}

.nav ul {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 30px;
  list-style: none;
  padding: 0px 0px 5px;
  margin: 0;
}

/* .nav a {
  text-decoration: none;
  color: #ffffff;

  font-family: "Times New Roman", Times, serif; 
  font-weight: 700;                            
  font-size: 22px;                              

  position: relative;
  letter-spacing: 0.3px;                       
} */

.nav a {
  display: flex;
  align-items: center;
  justify-content: center;

  min-width: 90px;        /* ← ВАЖНО */
  min-height: 80px;

  padding: 12px 36px;     /* ← даёт воздух */

  font-family: "Times New Roman", Times, serif;
  font-weight: 700;
  font-size: 20px;
  line-height: 1.2;
  text-align: center;

  color: #116488;
  text-decoration: none;

  background-image: url('/img/cloud-btn.png');
  background-repeat: no-repeat;
  background-position: center;
  background-size: 100% 100%;  /* ← ключ */

  white-space: normal;         /* ← перенос разрешён */
  word-break: keep-all;

  transition: transform 0.25s ease, filter 0.25s ease;
  
}
.nav a {
  will-change: transform;
}

.nav a:hover {
  transform: translateY(-3px) scale(1.03);
  filter: brightness(1.05);
}

.nav a.active {
  filter: drop-shadow(0 6px 14px #0077ff59);
}
/* Логотип + текст */
.logo {
  width: 200px;
  min-width: 200px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.logo-img {
  width: 300px;
  height: auto;
  display: block;
}



/* underline hover */
/* .nav a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -5px;
  width: 0;
  height: 2px;
  background: #ffffff;
  transition: 0.3s;
}

.nav a:hover::after {
  width: 100%;
} */

/* ===== АДАПТИВ ДЛЯ ЛОГО + ТЕКСТА ===== */

/* <= 1200px */
/* @media (max-width: 1200px) {
  .logo span {
    font-size: 22px;
    line-height: 1.25;
    white-space: normal;
    word-break: break-word;
    overflow-wrap: break-word;
  }
} */

/* <= 992px */
/* @media (max-width: 992px) {
  .logo span {
    font-size: 20px;
    line-height: 1.3;
    max-width: 100%;
  }
} */
.top-bar {
  position: relative;
  background-color: #afe6ff;
  overflow: hidden;
  padding: 0px 0;
}

/* <= 768px (планшеты и телефоны) */
@media (max-width: 768px) {
  .top-bar-inner {
    flex-direction: column;
    gap: 10px;
  }
  .nav a {
    min-width: 220px;
    font-size: 18px;
  }

  .logo {
    width: auto;
    min-width: auto;
  }

  .logo-img {
    width: 120px;
  }

  /* .logo span {
    font-size: 18px;
    line-height: 1.35;
    white-space: normal;
  } */
  .nav {
    background-position: center top;
    background-size: cover;
  }
}

/* <= 480px */
@media (max-width: 480px) {
  /* .logo span {
    font-size: 20px;
    line-height: 1.4;
  } */

  .logo-img {
    width: 50%;
    height: 50%;
  }
  
  .nav a {
    min-width: 200px;
    font-size: 16px;
    padding: 10px 28px;
  }
.nav {
    background-position: center 20%;
    padding-top: 10px;
    padding-bottom: 10px;
  }
}

/* <= 320px (маленькие экраны) */
@media (max-width: 320px) {
  /* .logo span {
    font-size: 18px;
    line-height: 1.45;
  } */

  .logo-img {
    width: 60px;
  }
}

/* Планшеты и ниже */
@media (max-width: 768px) {
  .nav ul {
    flex-direction: column;   /* ← ВОТ ГЛАВНОЕ */
    align-items: center;
    gap: 12px;
  }

  .nav a {
    font-size: 19px;
    font-weight: 700;
  }
}

/* Телефоны */
@media (max-width: 480px) {
  .nav ul {
    gap: 10px;
  }

  .nav a {
    font-size: 16px;
    font-weight: 700;
  }
}

/* Очень маленькие экраны */
@media (max-width: 320px) {
  .nav a {
    font-size: 14px;
    font-weight: 700;
  }
}

/* ===== HEADER ADAPTIVE ===== */

@media (max-width: 992px) {
  .top-bar-inner {
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 10px;
  }

  .logo {
    flex-direction: column;
    align-items: center;
  }

  .nav ul {
    flex-wrap: wrap;
    justify-content: center;
    gap: 15px;
  }
}

@media (max-width: 768px) {
  .nav ul {
    flex-direction: column;
    align-items: center;
  }
}

@media (max-width: 480px) {
  /* .logo span {
    font-size: 18px;
    line-height: 1.3;
  } */

  .nav a {
    font-size: 16px;
  }
}

@media (max-width: 320px) {
  .nav a {
    font-size: 14px;
  }
}
/* разделитель между top-bar и nav */
@keyframes cloud-wave {
  0%   { transform: translateY(0); }
  25%  { transform: translateY(-6px); }
  50%  { transform: translateY(0); }
  75%  { transform: translateY(4px); }
  100% { transform: translateY(0); }
}
.nav a {
  animation: cloud-wave 4s ease-in-out infinite;
}
.nav a:nth-child(1) { animation-delay: 0s; }
.nav a:nth-child(2) { animation-delay: 0.4s; }
.nav a:nth-child(3) { animation-delay: 0.8s; }
.nav a:nth-child(4) { animation-delay: 1.2s; }
.nav a:hover {
  animation-play-state: paused;
  transform: translateY(-8px);
}
.lang-switch {
  display: flex;
  gap: 8px;
  align-items: center;
}

/* общая кнопка */
.lang-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;

  width: 48px;
  height: 36px;

  font-family: "Times New Roman", Times, serif;
  font-weight: 700;
  font-size: 17px;

  color: #1b6f9c;
  text-decoration: none;

  background: linear-gradient(#ffffff, #eaf7ff);
  border-radius: 20px;

  box-shadow:
    inset 0 2px 4px rgba(255,255,255,0.9),
    0 4px 8px rgba(0,120,180,0.25);

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

/* активный язык */
.lang-btn.active {
  background: linear-gradient(#dff4ff, #bfe9ff);
  box-shadow:
    inset 0 2px 6px rgba(255,255,255,1),
    0 6px 14px rgba(0, 119, 255, 0.574);
  font-size: 17px;
}

/* hover — подпрыгивание */
.lang-btn:hover {
  transform: translateY(-3px);
}

/* 🔵 плавное "дыхание" облачка */
@keyframes lang-float {
  0%   { transform: translateY(0); }
  50%  { transform: translateY(-4px); }
  100% { transform: translateY(0); }
}

/* волна */
.lang-btn:nth-child(1) {
  animation: lang-float 3.5s ease-in-out infinite;
}

.lang-btn:nth-child(2) {
  animation: lang-float 3.5s ease-in-out infinite;
  animation-delay: 0.8s;
}

/* при наведении — останавливаем */
.lang-btn:hover {
  animation-play-state: paused;
}
/* .header-separator {
  height: 40px;
  background: linear-gradient(
    to bottom,
    #5271ff 0%,
    #7fd3ff 60%,
    #a6e3ff 100%
  );
  box-shadow: inset 0 -8px 12px rgba(0,0,0,0.01);
} */

@media (max-width: 1200px) {

}
@media (max-width: 992px) {



}

@media (max-width: 768px) {

}

@media (max-width: 480px) {

}

@media (max-width: 320px) {

}




.header-title span {
  max-width: 900px;
  font-family: 'Baloo 2', cursive;
  font-weight: 800;
  font-size: 28px;
  line-height: 1.25;
  color: #0c5d7f;
  text-shadow:
    -1px -1px 0 #ffffff,
     1px -1px 0 #ffffff,
    -1px  1px 0 #ffffff,
     1px  1px 0 #ffffff,
     0 3px 6px rgba(0,0,0,0.15);
}


@media (max-width: 768px) {
  .top-bar-inner {
    flex-direction: column;
    align-items: center;
  }
}
/* ===== TOP BAR (SINGLE SOURCE OF TRUTH) ===== */

