/* ================================================
   header.css — Armada Gemicilik Kurumsal Header
================================================ */

.header {
  position: fixed; top: 0; left: 0; width: 100%; z-index: 100;
  background-color: transparent; border-bottom: 1px solid transparent; 
  transition: all 0.3s ease;
}

.header.scrolled {
  background-color: rgba(255, 255, 255, 0.98);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(27, 48, 34, 0.15);
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.05);
}

/* --- Konteyner ve Grid ile Ortalama --- */
.header-container { 
  display: flex; justify-content: space-between; align-items: center; 
  padding: 20px 0; transition: padding 0.3s ease; gap: 12px; 
}

.header.scrolled .header-container { padding: 10px 0; }

@media (min-width: 1024px) {
  .header-container {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
  }
  .logo { justify-self: flex-start; }
  .nav-links { justify-self: center; }
  .header-actions { justify-self: flex-end; margin-inline-start: 0 !important; }
}

/* --- Logolar ve Linkler --- */
.logo { font-family: var(--font-h-family); font-size: 20px; font-weight: 900; letter-spacing: 0.2em; color: var(--tactical-green); text-decoration: none; display: flex; align-items: center; }
.header-logo { height: 60px; width: auto; display: block; transition: all 0.3s ease; }
.nav-links { display: flex; gap: 32px; align-items: center; }
.header-actions { display: inline-flex; align-items: center; gap: 16px; margin-inline-start: auto; }

.nav-link {
  font-family: var(--font-h-family); font-size: 14px; font-weight: 700;
  text-transform: uppercase; color: rgba(27, 48, 34, 0.6); text-decoration: none; transition: color 0.2s ease;
}
.nav-link:hover { color: var(--tactical-green); }

/* --- Dropdown Ayarları --- */
.nav-dropdown-toggle { background: transparent; border: none; color: inherit; display: inline-flex; align-items: center; justify-content: center; cursor: pointer; padding: 0; }
.dropdown-menu { background: #ffffff !important; }
.dropdown-menu a { display: block; white-space: nowrap; }
.dropdown-menu a:hover { background-color: var(--tactical-green) !important; color: white !important; }

.lang-switcher.open .dropdown-menu { display: flex !important; }
.nav-item-dropdown.open .nav-dropdown-menu { display: flex !important; }

/* Masaüstü hover ile açılma */
@media (min-width: 1024px) {
  .nav-dropdown-toggle { display: none; }
  .lang-switcher:hover .dropdown-menu, .lang-switcher:focus-within .dropdown-menu { display: flex !important; }
  .nav-item-dropdown:hover .nav-dropdown-menu, .nav-item-dropdown:focus-within .nav-dropdown-menu { display: flex !important; }
}

/* --- Masaüstü Görünüm (Renkler ve Hamburger İptali) --- */
@media (min-width: 1024px) {
  .mobile-menu-btn { display: none !important; } /* Hamburger masaüstünde gizli */
  
  .header:not(.scrolled) .logo { color: white !important; }
  .header:not(.scrolled) .header-logo { filter: brightness(0) invert(1); }
  .header:not(.scrolled) .nav-link { color: rgba(255, 255, 255, 0.8) !important; }
  .header:not(.scrolled) .nav-link:hover { color: white !important; }
  
  /* Dil Seçici (Scroll Olmadan Beyaz) */
  .header:not(.scrolled) .lang-switcher .nav-link { color: white !important; }
  .header:not(.scrolled) .lang-switcher .nav-link .material-symbols-outlined { color: white !important; }
  
  /* Dil Seçici (Scroll Olunca Koyu Yeşil) */
  .header.scrolled .lang-switcher .nav-link { color: var(--tactical-green) !important; }
  .header.scrolled .lang-switcher .nav-link .material-symbols-outlined { color: var(--tactical-green) !important; }
}

/* --- Mobil Görünüm --- */
.mobile-menu-btn {
  background: none; border: none; color: var(--tactical-green); cursor: pointer; display: block;
  position: relative; z-index: 60; width: 44px; height: 44px;
  display: flex; align-items: center; justify-content: center;
  -webkit-tap-highlight-color: transparent;
}

@media (max-width: 1023px) {
  .header:not(.scrolled) .logo { color: white !important; }
  .header:not(.scrolled) .header-logo { filter: brightness(0) invert(1); }
  .header:not(.scrolled) .mobile-menu-btn { color: white !important; }
  
  /* Mobilde Dil Seçici (Tıpkı Hamburger Gibi Beyazdan Yeşile) */
  .header:not(.scrolled) .lang-switcher .nav-link { color: white !important; }
  .header:not(.scrolled) .lang-switcher .nav-link .material-symbols-outlined { color: white !important; }
  .header.scrolled .lang-switcher .nav-link { color: var(--tactical-green) !important; }
  .header.scrolled .lang-switcher .nav-link .material-symbols-outlined { color: var(--tactical-green) !important; }

  .header.mobile-open { background-color: #ffffff; border-bottom-color: rgba(27, 48, 34, 0.15); }
  .header.mobile-open .header-logo { filter: none; }
  .header.mobile-open .logo { color: var(--tactical-green) !important; }
  .header.mobile-open .mobile-menu-btn { color: var(--tactical-green) !important; }
  
  .header-container { position: relative; z-index: 60; }
  .header-logo { height: 48px; }
  .header-actions { gap: 12px; }

  .nav-links {
    flex-direction: column; position: fixed; top: 0; left: 0; right: 0; bottom: 0;
    width: 100%; height: 100vh; height: 100dvh; background-color: #ffffff;
    padding: 100px 24px 40px; border-bottom: none; box-shadow: none;
    transform: translateX(100%); opacity: 0; visibility: hidden;
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.3s ease, visibility 0.3s ease;
    gap: 0; z-index: 40; overflow-y: auto; align-items: stretch;
  }
  .nav-links.active { transform: translateX(0); opacity: 1; visibility: visible; }
  .nav-links > a.nav-link {
    display: block; padding: 16px 0; border-bottom: 1px solid rgba(27, 48, 34, 0.08);
    text-align: left; font-size: 15px; color: var(--tactical-green) !important; width: 100%;
  }
  .nav-links > a.nav-link:first-child { border-top: 1px solid rgba(27, 48, 34, 0.08); }

  .nav-item-dropdown { width: 100%; flex-direction: column; align-items: stretch !important; height: auto !important; position: relative !important; border-bottom: 1px solid rgba(27, 48, 34, 0.08); }
  .nav-item-dropdown > .nav-link { width: 100%; justify-content: space-between; padding: 16px 0; font-size: 15px; color: var(--tactical-green) !important; text-align: left; }
  .nav-item-dropdown > .nav-link > .material-symbols-outlined { display: none; }
  
  .nav-dropdown-toggle { position: absolute; top: 0; right: 0; width: 48px; height: 52px; display: flex; align-items: center; justify-content: center; margin-top: 0; z-index: 2; transition: transform 0.3s ease; }
  .nav-item-dropdown.open .nav-dropdown-toggle { transform: rotate(180deg); }
  
  .nav-dropdown-menu { position: static !important; inset-inline-start: auto !important; min-width: 0 !important; width: 100%; padding-top: 0 !important; display: none; }
  .nav-dropdown-menu > div { background: rgba(27, 48, 34, 0.04) !important; border: none !important; box-shadow: none !important; padding: 4px 0 !important; }
  .nav-dropdown-menu a { padding: 12px 24px !important; font-size: 13px !important; color: rgba(27, 48, 34, 0.7) !important; border-top: none !important; }
  .nav-dropdown-menu a:hover { background-color: var(--tactical-green) !important; color: white !important; }
  
  .lang-switcher .dropdown-menu { position: absolute !important; min-width: 140px !important; width: max-content; max-width: 80vw; margin-top: 0; inset-inline-end: 0; box-shadow: 0 8px 24px rgba(0,0,0,0.15) !important; }
  .dropdown-menu a { white-space: normal; word-break: break-word; }

  .lang-switcher:hover .dropdown-menu, .nav-item-dropdown:hover .nav-dropdown-menu { display: none !important; }
  .lang-switcher.open .dropdown-menu, .nav-item-dropdown.open .nav-dropdown-menu { display: flex !important; }
}