/* Ana menü hover ile açılacak */
.nav-item.dropdown:hover > .dropdown-menu {
  display: block;
}

/* Alt menülerin hover ile açılması */
.dropdown-submenu {
  position: relative;
}

.dropdown-submenu > .submenu {
  display: none;
  position: absolute;
  left: 100%;
  top: 0;
  background: white;
  border: 1px solid #ddd;
  border-radius: 5px;
  box-shadow: 0px 4px 6px rgba(0, 0, 0, 0.1);
  min-width: 150px;
  padding: 0;
  z-index: 1000;
}

/* Sadece hover olunca alt menü açılacak */
.dropdown-submenu:hover > .submenu {
  display: block;
}

/* Alt menü içeriği */
.submenu li {
  list-style: none;
}

.submenu a {
  display: block;
  padding: 10px;
  color: #333;
  text-decoration: none;
}

.submenu a:hover {
  background: #f8f9fa;
  color: #007bff;
}

/* Languages dropdown da hover ile açılacak şekilde ayarlandı */
.nav-item.dropdown:hover .dropdown-menu[aria-labelledby="languagesDropdown"] {
  display: block;
}

/* Dropdown menü öğeleri */
.dropdown-item {
  padding: 10px 20px;
  color: #333;
  transition: background 0.3s ease-in-out;
  white-space: nowrap;
}

/* Dropdown menü öğelerinin hover durumu */
.dropdown-item:hover {
  background-color: #f8f9fa;
  color: #007bff;
}

/* Aktif dil seçeneği */
.dropdown-item.active {
  background-color: #007bff;
  color: #fff;
}

/* Video kapsayıcı divin yüksekliğini videonun boyutuna göre ayarlama */
.services-icon-wrap {
  width: 100%;
  /* Genişliği %100 yaparak videonun genişliğine uyum sağlar */
  height: auto;
  /* Yüksekliği otomatik yaparak videonun yüksekliğine uyum sağlar */
  display: flex;
  justify-content: center;
  align-items: center;
  position: relative;
  overflow: hidden;
  /* Taşmayı engeller */
}

/* Videonun dikey şekilde görünmesini sağlama */
.rounded-video {
  width: auto;
  /* Genişliği otomatik yaparak yüksekliğe uyum sağlar */
  height: 100%;
  /* Yüksekliği %100 yaparak kapsayıcı divin yüksekliğine uyum sağlar */
  object-fit: cover;
  /* Videonun kapsayıcı divi tamamen doldurmasını sağlar */
  border-radius: 15px;
  /* Kenarları yuvarlatır */
}

.section-title-wrap h2 {
  font-size: 3rem;
  /* Başlık boyutunu artırıyoruz */
}

.avatar-image {
  width: 60px;
  /* Logoyu büyütüyoruz */
  height: auto;
  margin-left: 15px;
  /* Başlıkla logo arasındaki boşluğu artırıyoruz */
  border-radius: 0;
  /* Kenarları yuvarlak yapmayı kaldırıyoruz */
}

/* Sağ ve sol tarafından 1px boşluk bırakmak için */
.custom-padding {
  padding-left: 10px;
  padding-right: 10px;
  padding-top: 10px;
}

/* GLOBAL TANIMLAR — her cihaz için geçerli */
.submenu {
  display: none;
}

.submenu.show {
  display: block;
}

/* Uçan WhatsApp Butonu Stilleri */
.floating-whatsapp-btn {
  position: fixed;
  bottom: 30px;
  right: 30px;
  z-index: 9999;
  animation: floating 3s ease-in-out infinite;
}

.floating-whatsapp-btn a {
  display: flex;
  align-items: center;
  gap: 10px;
  background: linear-gradient(135deg, #25d366 0%, #128c7e 100%);
  color: white;
  padding: 15px 20px;
  border-radius: 50px;
  text-decoration: none;
  box-shadow: 0 4px 20px rgba(37, 211, 102, 0.3);
  transition: all 0.3s ease;
  font-weight: 600;
  font-size: 16px;
  white-space: nowrap;
}

.floating-whatsapp-btn a:hover {
  background: linear-gradient(135deg, #128c7e 0%, #25d366 100%);
  transform: translateY(-3px);
  box-shadow: 0 8px 25px rgba(37, 211, 102, 0.5);
  color: white;
}

.whatsapp-icon {
  width: 24px;
  height: 24px;
  fill: currentColor;
}

.btn-text {
  font-family: "DM Sans", sans-serif;
}

/* Yüzen animasyon efekti */
@keyframes floating {
  0%,
  100% {
    transform: translateY(0px);
  }
  50% {
    transform: translateY(-10px);
  }
}

/* Pulse animasyon efekti */
.floating-whatsapp-btn::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 100%;
  height: 100%;
  background: rgba(37, 211, 102, 0.3);
  border-radius: 50px;
  transform: translate(-50%, -50%);
  animation: pulse 2s infinite;
  z-index: -1;
}

@keyframes pulse {
  0% {
    transform: translate(-50%, -50%) scale(1);
    opacity: 1;
  }
  100% {
    transform: translate(-50%, -50%) scale(1.5);
    opacity: 0;
  }
}

/* Mobil cihazlar için */
@media (max-width: 767px) {
  .hero {
    padding-top: 200px;
    padding-bottom: 200px;
  }

  .hero-image {
    width: 100%;
    height: auto;
    min-width: auto; /* ya da hiç tanımlama */
  }

  .services-thumb {
    margin-bottom: 30px;
  }

  .services-icon-wrap {
    height: 70%;
    bottom: 5px;
  }

  .contact-info {
    padding: 30px;
  }
}

@media (max-width: 768px) {
  .hero-image video {
    width: 100%;
    height: auto;
  }

  .navbar .nav-link {
    white-space: nowrap;
  }

  .navbar-collapse {
    max-height: 90vh;
    overflow-y: auto;
  }

  /* Mobil dropdown submenu düzeltmesi */
  .dropdown-submenu {
    position: relative;
  }

  .dropdown-submenu .submenu {
    position: static !important;
    float: none !important;
    width: 100% !important;
    margin-top: 0 !important;
    border: none !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    background-color: rgba(0, 0, 0, 0.05) !important;
    padding-left: 20px !important;
    left: 0 !important;
    top: 0 !important;
  }

  .dropdown-submenu .submenu .dropdown-item {
    padding: 8px 15px !important;
    border-bottom: 1px solid rgba(0, 0, 0, 0.1) !important;
  }

  .dropdown-submenu .submenu .dropdown-item:last-child {
    border-bottom: none !important;
  }

  /* Submenu'yu toggle etmek için */
  .dropdown-submenu .submenu {
    display: none;
  }

  .dropdown-submenu.show .submenu {
    display: block !important;
  }

  /* Ana dropdown item'a tıklanabilirlik eklemek için */
  .dropdown-submenu > .dropdown-toggle::after {
    display: inline-block;
    margin-left: 0.255em;
    vertical-align: 0.255em;
    content: "";
    border-top: 0.3em solid;
    border-right: 0.3em solid transparent;
    border-bottom: 0;
    border-left: 0.3em solid transparent;
    transform: rotate(90deg);
    transition: transform 0.3s ease;
  }

  .dropdown-submenu.show > .dropdown-toggle::after {
    transform: rotate(180deg);
  }

  /* WhatsApp butonu mobil düzenleme */
  .floating-whatsapp-btn {
    bottom: 20px;
    right: 20px;
  }

  .floating-whatsapp-btn a {
    padding: 12px 18px;
    font-size: 14px;
    border-radius: 50%;
    width: 60px;
    height: 60px;
    justify-content: center;
    padding: 0;
  }

  .whatsapp-icon {
    width: 20px;
    height: 20px;
  }

  .btn-text {
    display: none;
  }
}
/* Hero bölümünün stilleri */

/* Tabletler için */
@media (min-width: 768px) and (max-width: 991px) {
  .hero {
    padding-top: 250px;
    padding-bottom: 250px;
  }

  .services-thumb {
    margin-bottom: 40px;
  }

  .services-icon-wrap {
    height: 60%;
    bottom: 5px;
  }
}

/* Masaüstü ekranlar için */
@media (min-width: 992px) {
  .hero {
    padding-top: 300px;
    padding-bottom: 300px;
  }

  .services-thumb {
    margin-bottom: 50px;
  }

  .services-icon-wrap {
    height: 50%;
    bottom: 0;
  }
}

/* Çok küçük ekranlar için */
@media (max-width: 480px) {
  .floating-whatsapp-btn {
    bottom: 15px;
    right: 15px;
  }

  .floating-whatsapp-btn a {
    width: 50px;
    height: 50px;
  }

  .whatsapp-icon {
    width: 18px;
    height: 18px;
  }
}

.suggestions {
  position: absolute;
  top: 100%; /* Position right below the input field */
  left: 0; /* Align with the left edge of the input field */
  right: auto; /* Allow width to be controlled by 'width' property */
  background: white;
  border: 1px solid #ddd;
  border-radius: 5px;
  max-height: 200px;
  overflow-y: auto;
  width: var(--search-input-width, 180px); /* Use a CSS variable for dynamic width or a fixed value */
  z-index: 1000;
  box-shadow: 0px 4px 6px rgba(0, 0, 0, 0.1); /* Add a subtle shadow */
}

.suggestion-item {
  padding: 8px 12px;
  cursor: pointer;
  transition: background 0.2s;
}

.suggestion-item:hover {
  background: #f0f0f0;
}

.news-slider {
  position: absolute; /* Mutlak konumlandırma */
  bottom: 20px; /* Alttan 20 piksel yukarıda */
  left: 50%; /* Soldan %50 */
  transform: translateX(
    -50%
  ); /* Kendi genişliğinin yarısı kadar sola kaydırarak ortalama */
  width: 90%; /* Genişliği ayarla, ihtiyaca göre değiştirebilirsin */
  max-width: 800px; /* Maksimum genişlik, içeriğe göre ayarla */
  border-radius: 20px;
  overflow: hidden;
  max-height: 300px;
  z-index: 22;
}

.news-slide {
  opacity: 0;
  transition: opacity 1s ease-in-out;
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
}

.news-slide.active {
  opacity: 1;
  position: relative;
}

.news-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.news-slider button {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(0, 0, 0, 0.4);
  border: none;
  color: white;
  font-size: 24px;
  padding: 5px 12px;
  cursor: pointer;
  border-radius: 50%;
  transition: background 0.3s ease;
}

.news-slider button:hover {
  background: rgba(0, 0, 0, 0.7);
}

.news-prev {
  left: 10px;
}

.news-next {
  right: 10px;
}
/* Existing CSS for .nav-item.position-relative */
.nav-item.position-relative {
  position: relative; /* Essential for absolute positioning of suggestions */
  padding-left: 15px; /* Add some padding to properly contain the search input */
  padding-right: 15px; /* Add some padding to properly contain the search input */
  display: flex; /* Use flexbox to align input and suggestions */
  align-items: center; /* Vertically center the input */
}

/* Style for the search input field */
#siteSearchInput {
  flex-grow: 1; /* Allow the input to take available space */
  border: 1px solid #ced4da; /* Subtle border */
  border-radius: 20px; /* Rounded corners for a softer look */
  padding: 8px 15px; /* Adjust padding for better visual spacing */
  font-size: 1rem; /* Standard font size */
  transition: all 0.3s ease; /* Smooth transition for focus effects */
  box-shadow: none; /* Remove any default Bootstrap shadow if present */
  background-color: #f8f9fa; /* Light background */
  width: 180px; /* Set a default width */
}

#siteSearchInput:focus {
  border-color: #007bff; /* Highlight border on focus */
  box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25); /* Subtle shadow on focus */
  background-color: #fff; /* White background on focus */
  outline: none; /* Remove default outline */
}

/* Adjust suggestions box position to be relative to the input */
.suggestions {
  position: absolute;
  top: 100%; /* Position below the input */
  left: 0;
  right: 0;
  background: white;
  border: 1px solid #ddd;
  border-radius: 5px;
  max-height: 200px;
  overflow-y: auto;
  width: 100%;
  z-index: 1000;
  box-shadow: 0px 4px 6px rgba(0, 0, 0, 0.1); /* Add a subtle shadow */
}

/* Media query for smaller screens to adjust search input width */
@media (max-width: 991px) {
  #siteSearchInput {
    width: 100%; /* Full width on smaller screens */
    margin-top: 10px; /* Add some space from previous nav items */
  }

  .nav-item.position-relative {
    padding-left: 0;
    padding-right: 0;
  }
}
