/* =========================
   HEADER GRUNDSTRUKTUR
========================= */

.site-header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: var(--header-h);
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  z-index: 1000;
  border-bottom: 1px solid rgba(226, 232, 240, 0.9);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
  transition: box-shadow 0.25s ease, background 0.25s ease, border-color 0.25s ease;
}

.site-header.scrolled {
  box-shadow: 0 10px 30px rgba(15, 23, 42, 0.07);
  background: rgba(255, 255, 255, 0.98);
}

.header-inner {
  max-width: 1400px;
  height: 100%;
  margin: 0 auto;
  padding: 0 28px;
  display: flex;
  align-items: center;
  position: relative;
}

/* =========================
   LOGO / BRAND
========================= */

.header-left {
  position: relative;
  z-index: 20;
  display: flex;
  align-items: center;
  flex-shrink: 0;
  min-width: 0;
}

.logo-wrap {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.logo-wrap:hover {
  transform: translateY(-1px);
}

.logo-img {
  width: 46px;
  height: 46px;
  object-fit: contain;
  flex-shrink: 0;
}

.logo-text {
  display: flex;
  flex-direction: column;
  justify-content: center;
  line-height: 1.05;
}

.logo-title {
  font-size: 1.08rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: #0f172a;
}

.logo-sub {
  font-size: 0.8rem;
  font-weight: 500;
  color: #64748b;
  margin-top: 4px;
}

/* =========================
   DESKTOP NAVIGATION
========================= */

.main-nav {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 34px;
  z-index: 5;
}

.nav-link {
  position: relative;
  display: inline-flex;
  align-items: center;
  text-decoration: none;
  color: #334155;
  font-size: 0.95rem;
  font-weight: 600;
  padding: 6px 0;
  transition: color 0.22s ease, transform 0.22s ease;
}

.nav-link::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -7px;
  width: 100%;
  height: 2px;
  background: #2563eb;
  transform: scaleX(0);
  transform-origin: center;
  transition: transform 0.22s ease;
}

.nav-link:hover,
.nav-link.active {
  color: #0f172a;
  transform: translateY(-1px);
}

.nav-link:hover::after,
.nav-link.active::after {
  transform: scaleX(1);
}

/* =========================
   RIGHT AREA
========================= */

.header-right {
  position: relative;
  z-index: 20;
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 16px;
  padding-left: 28px;
}

.cta-header {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 44px;
  padding: 0 18px;
  border-radius: 999px;
  background: linear-gradient(135deg, #2563eb, #1d4ed8);
  color: #ffffff;
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 700;
  box-shadow: 0 8px 22px rgba(37, 99, 235, 0.18);
  transition: transform 0.22s ease, box-shadow 0.22s ease, opacity 0.22s ease;
  white-space: nowrap;
}

.cta-header:hover {
  transform: translateY(-1px);
  box-shadow: 0 12px 28px rgba(37, 99, 235, 0.24);
}

.lang-switch {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 40px;
  padding: 0 12px;
  border: 1px solid #e2e8f0;
  border-radius: 999px;
  background: #ffffff;
  color: #0f172a;
  font-size: 0.82rem;
  font-weight: 700;
  cursor: pointer;
  transition: border-color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

.lang-switch:hover {
  transform: translateY(-1px);
  border-color: #cbd5e1;
  box-shadow: 0 6px 18px rgba(15, 23, 42, 0.06);
}

.lang-arrow {
  font-size: 0.8rem;
  color: #64748b;
  line-height: 1;
}

.lang-dropdown {
  position: relative;
  z-index: 30;
}

.lang-menu {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  min-width: 190px;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.10);
  padding: 6px;
  display: none;
  flex-direction: column;
  gap: 4px;
  z-index: 40;
}

.lang-menu.open {
  display: flex;
}

.lang-option {
  border: none;
  background: transparent;
  padding: 10px 12px;
  border-radius: 10px;
  font-size: 0.82rem;
  font-weight: 700;
  color: #0f172a;
  cursor: pointer;
  text-align: left;
  transition: background 0.2s ease, color 0.2s ease;
}

.mobile-language-option {
  display: flex;
  align-items: center;
  gap: 10px;
}

.lang-option:hover {
  background: #eff6ff;
  color: #1d4ed8;
}

.lang-dropdown {
  position: relative;
  z-index: 1300;
}

.lang-code {
  letter-spacing: 0.02em;
}

.lang-flag {
  font-size: 0.95rem;
  line-height: 1;
}

.lang-flag-img,
.lang-option-flag-img,
.mobile-language-flag-img {
  width: 20px;
  height: 14px;
  object-fit: cover;
  border-radius: 3px;
  flex-shrink: 0;
  display: inline-block;
  box-shadow: 0 0 0 1px rgba(15, 23, 42, 0.08);
}

.lang-menu {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  min-width: 190px;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.10);
  padding: 6px;
  display: none;
  flex-direction: column;
  gap: 4px;
  z-index: 1400;
}

.lang-menu.open {
  display: flex;
}

.lang-option {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  padding: 10px 12px;
  border-radius: 10px;
  font-size: 0.84rem;
  font-weight: 600;
  color: #0f172a;
  transition: background 0.2s ease, color 0.2s ease;
}

.lang-option:hover,
.lang-option.active {
  background: #eff6ff;
  color: #1d4ed8;
}

.lang-option-flag {
  font-size: 1rem;
  line-height: 1;
}

.lang-option-name {
  white-space: nowrap;
}

/* =========================
   MOBILE LANGUAGE BLOCK
========================= */

.mobile-language-block {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.mobile-language-title {
  font-size: 0.82rem;
  font-weight: 700;
  color: #64748b;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.mobile-language-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.mobile-language-option {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: #0f172a;
  padding: 10px 12px;
  border-radius: 12px;
  font-size: 0.92rem;
  font-weight: 600;
  transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.mobile-language-option:hover,
.mobile-language-option.active {
  background: #eff6ff;
  color: #1d4ed8;
  transform: translateX(3px);
}

.mobile-language-flag {
  font-size: 1rem;
  line-height: 1;
}

.mobile-language-name {
  white-space: nowrap;
}

@media (max-width: 768px) {
  .lang-menu {
    min-width: 170px;
  }

  .lang-option {
    font-size: 0.78rem;
    padding: 9px 10px;
  }
}

/* =========================
   BURGER
========================= */

.burger {
  display: none;
  width: 28px;
  height: 22px;
  position: relative;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  flex-shrink: 0;
}

.burger span {
  position: absolute;
  left: 0;
  width: 100%;
  height: 2px;
  background: #0f172a;
  border-radius: 2px;
  transition: all 0.28s ease;
}

.burger span:nth-child(1) {
  top: 0;
}

.burger span:nth-child(2) {
  top: 10px;
}

.burger span:nth-child(3) {
  bottom: 0;
}

.burger.active span:nth-child(1) {
  transform: rotate(45deg);
  top: 10px;
}

.burger.active span:nth-child(2) {
  opacity: 0;
}

.burger.active span:nth-child(3) {
  transform: rotate(-45deg);
  bottom: 10px;
}

/* =========================
   OVERLAY
========================= */

.mobile-menu-overlay {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.45);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.25s ease, visibility 0.25s ease;
  z-index: 1900;
}

.mobile-menu-overlay.open {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

/* =========================
   MOBILE DRAWER
========================= */

.mobile-menu {
  position: fixed;
  top: 0;
  right: -100%;
  width: min(88vw, 320px);
  height: 100vh;
  background: rgba(255, 255, 255, 0.98);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  box-shadow: -16px 0 40px rgba(15, 23, 42, 0.15);
  z-index: 2000;
  padding: 18px 18px 22px;
  transition: right 0.28s ease;
  display: flex;
  flex-direction: column;
  overflow-y: auto;
}

.mobile-menu.open {
  right: 0;
}

.mobile-menu-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 20px;
}

.mobile-menu-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.mobile-menu-logo {
  width: 38px;
  height: 38px;
  object-fit: contain;
  flex-shrink: 0;
}

.mobile-menu-brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1.05;
}

.mobile-menu-brand-text strong {
  font-size: 0.95rem;
  color: #0f172a;
}

.mobile-menu-brand-text span {
  font-size: 0.76rem;
  color: #64748b;
  margin-top: 4px;
}

.mobile-close {
  width: 40px;
  height: 40px;
  border: 1px solid #e2e8f0;
  border-radius: 999px;
  background: #ffffff;
  color: #0f172a;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

.mobile-close:hover {
  transform: scale(1.04);
  border-color: #cbd5e1;
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.08);
}

.mobile-close-arrow {
  font-size: 1.4rem;
  line-height: 1;
}

.mobile-nav {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.mobile-nav a {
  display: block;
  text-decoration: none;
  font-size: 1rem;
  font-weight: 600;
  color: #0f172a;
  padding: 12px 14px;
  border-radius: 14px;
  transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.mobile-nav a:hover,
.mobile-nav a.active {
  background: #eff6ff;
  color: #1d4ed8;
  transform: translateX(3px);
}

.mobile-divider {
  height: 1px;
  background: #e2e8f0;
  margin: 18px 0;
}

.mobile-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 16px;
  border-radius: 999px;
  background: linear-gradient(135deg, #2563eb, #1d4ed8);
  color: #ffffff;
  text-decoration: none;
  font-size: 0.92rem;
  font-weight: 700;
  box-shadow: 0 10px 24px rgba(37, 99, 235, 0.18);
}

.mobile-usps {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 18px;
}

.mobile-usps span {
  font-size: 0.9rem;
  color: #475569;
}

/* =========================
   BODY LOCK
========================= */

body.menu-open {
  overflow: hidden;
}

/* =========================
   RESPONSIVE
========================= */

@media (max-width: 980px) {
  .main-nav {
    gap: 24px;
  }

  .header-right {
    gap: 12px;
    padding-left: 20px;
  }

  .cta-header {
    padding: 0 15px;
  }
}

@media (max-width: 768px) {
  :root {
    --header-h: 68px;
  }

  .header-inner {
    padding: 0 16px;
  }

  .logo-wrap {
    gap: 10px;
  }

  .logo-img {
    width: 40px;
    height: 40px;
  }

  .logo-title {
    font-size: 1rem;
  }

  .logo-sub {
    display: block;
    font-size: 0.62rem;
    margin-top: 2px;
    color: #64748b;
    line-height: 1.1;
  }

  .main-nav,
  .cta-header {
    display: none;
  }

  .lang-switch {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 34px;
    padding: 0 10px;
    font-size: 0.75rem;
    gap: 4px;
    border-radius: 999px;
    border: 1px solid #e2e8f0;
    background: #ffffff;
    white-space: nowrap;
    flex-shrink: 0;
  }

  .lang-switch:hover {
    transform: none;
    box-shadow: none;
  }

  .lang-arrow {
    font-size: 0.7rem;
  }
  
  .lang-menu {
    right: 0;
    min-width: 64px;
  }

  .lang-option {
    font-size: 0.75rem;
    padding: 9px 10px;
  }

  .burger {
    display: block;
  }

  .header-right {
    gap: 10px;
    padding-left: 0;
  }
}

@media (max-width: 420px) {
  .mobile-menu {
    width: min(92vw, 300px);
    padding: 16px 14px 20px;
  }

  .mobile-nav a {
    font-size: 0.95rem;
  }

  .mobile-usps span {
    font-size: 0.86rem;
  }

  .logo-wrap {
    gap: 8px;
  }

  .logo-img {
    width: 34px;
    height: 34px;
  }

  .logo-title {
    font-size: 0.9rem;
  }

  .logo-sub {
    font-size: 0.58rem;
  }

  .lang-switch {
    height: 32px;
    padding: 0 8px;
    font-size: 0.72rem;
  }

  .header-right {
    gap: 8px;
  }
}