/* ============================================================
   FEKRA — Header, Navigation, Mobile Menu, Lang Toggle
   ============================================================ */

/* ── Header ─────────────────────────────────────────────────── */
.header {
  position: fixed; top: 0; left: 0; right: 0;
  z-index: 500;
  padding: 22px 0;
  transition: background .4s, padding .4s, backdrop-filter .4s;
}
.header.scrolled {
  background: rgba(6,13,26,0.88);
  backdrop-filter: blur(24px);
  padding: 14px 0;
  border-bottom: 1px solid var(--border);
}

/* ── Nav ────────────────────────────────────────────────────── */
.nav {
  display: flex; align-items: center; justify-content: space-between;
  gap: 32px;
}
.nav-logo {
  display: flex; align-items: center; gap: 12px;
  text-decoration: none;
  color: var(--text);
  font-family: var(--font-display);
  font-weight: 400;
  font-size: 1.4rem;
  letter-spacing: .08em;
  flex-shrink: 0;
}
.nav-logo img { height: 48px; object-fit: contain; }
.site-logo { height: 48px; width: auto; object-fit: contain; display: block; }

.nav-links {
  display: flex; align-items: center; gap: 36px;
  list-style: none;
}
.nav-link {
  color: var(--text-2);
  text-decoration: none;
  font-size: .9rem;
  font-weight: 400;
  transition: color .25s;
  position: relative;
  letter-spacing: .04em;
}
.nav-link::after {
  content: '';
  position: absolute; bottom: -4px; right: 0; left: 0;
  height: 1px;
  background: var(--lime);
  transform: scaleX(0);
  transform-origin: right;
  transition: transform .25s;
}
.nav-link:hover,
.nav-link.active { color: var(--text); }
.nav-link:hover::after,
.nav-link.active::after { transform: scaleX(1); }
.nav-link.active { color: var(--lime); }

.nav-actions { display: flex; align-items: center; gap: 16px; }

/* ── Hamburger ──────────────────────────────────────────────── */
.hamburger {
  display: none;
  flex-direction: column; gap: 5px;
  background: none; border: none; cursor: pointer;
  padding: 6px; z-index: 401;
}
.hamburger span {
  display: block; width: 24px; height: 1.5px;
  background: var(--text);
  transition: all .3s;
}
.hamburger.open span:nth-child(1) { transform: translateY(6.5px) rotate(45deg); }
.hamburger.open span:nth-child(2) { opacity: 0; }
.hamburger.open span:nth-child(3) { transform: translateY(-6.5px) rotate(-45deg); }

/* ── Language toggle ────────────────────────────────────────── */
.lang-toggle {
  display: inline-flex;
  align-items: center;
  padding: 5px 13px;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(1,166,81,0.38);
  border-radius: 50px;
  font-family: 'Trox', sans-serif !important;
  font-size: 0.62rem;
  letter-spacing: 0.18em;
  color: var(--text-2);
  cursor: pointer;
  transition: border-color 0.3s, box-shadow 0.3s, background 0.3s;
  backdrop-filter: blur(8px);
  white-space: nowrap;
  line-height: 1;
  flex-shrink: 0;
}
.lang-toggle:hover {
  border-color: rgba(1,251,29,0.5);
  box-shadow: 0 0 18px rgba(1,251,29,0.12);
  background: rgba(1,166,81,0.07);
}
.lt-sep { color: rgba(1,166,81,0.4); margin: 0 5px; }
.lt-ar,
.lt-en { color: var(--text-3); transition: color 0.25s; }
.lt-active { color: #01fb1d !important; }

/* ── Mobile nav overlay ─────────────────────────────────────── */
.mobile-nav-overlay,
.mobile-nav-overlay *:not(i):not([class*="fa"]) {
  font-family: 'Trox', sans-serif !important;
  font-weight: 400 !important;
}
.mobile-nav-overlay {
  position: fixed;
  inset: 0;
  z-index: 550;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.38s ease, visibility 0.38s ease;
}
.mobile-nav-overlay.open {
  opacity: 1;
  visibility: visible;
  pointer-events: all;
}
.mobile-nav-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(6,13,26,0.55);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
}
.mobile-nav-panel {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  background:
    linear-gradient(160deg, rgba(255,255,255,0.038) 0%, rgba(255,255,255,0.008) 100%),
    rgba(6,13,26,0.97);
  background-image:
    linear-gradient(rgba(1,166,81,0.028) 1px, transparent 1px),
    linear-gradient(90deg, rgba(1,166,81,0.028) 1px, transparent 1px),
    linear-gradient(160deg, rgba(255,255,255,0.038) 0%, rgba(255,255,255,0.008) 100%);
  background-size: 60px 60px, 60px 60px, 100%;
  transform: translateY(-12px);
  transition: transform 0.45s cubic-bezier(0.22, 1, 0.36, 1);
  overflow: hidden;
}
.mobile-nav-overlay.open .mobile-nav-panel { transform: translateY(0); }

/* Top bar */
.mobile-nav-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 22px 24px;
  border-bottom: 1px solid rgba(255,255,255,0.06);
  flex-shrink: 0;
}
.mobile-nav-logo { display: flex; align-items: center; text-decoration: none; }
.mobile-nav-logo img { height: 36px; width: auto; }
.mobile-nav-close-btn {
  width: 42px; height: 42px;
  display: flex; align-items: center; justify-content: center;
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.09);
  border-radius: 50%;
  color: var(--text-2);
  cursor: pointer;
  transition: background 0.22s, color 0.22s, border-color 0.22s;
  flex-shrink: 0;
}
.mobile-nav-close-btn:hover {
  background: rgba(1,251,29,0.1);
  color: var(--lime);
  border-color: rgba(1,251,29,0.28);
}

/* Links list */
.mobile-nav-links-wrap {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 28px;
  overflow-y: auto;
}
.mobile-nav-links-wrap ul { list-style: none; }
.mobile-nav-links-wrap li { overflow: hidden; }
.mobile-nav-links-wrap .nav-link {
  display: flex;
  align-items: center;
  font-size: 1.65rem;
  font-weight: 400;
  color: var(--text-2);
  text-decoration: none;
  padding: 14px 0;
  border-bottom: 1px solid rgba(255,255,255,0.042);
  letter-spacing: 0.01em;
  opacity: 0;
  transform: translateY(16px);
}
.mobile-nav-links-wrap .nav-link::after { display: none; }
.mobile-nav-overlay.open .mobile-nav-links-wrap .nav-link {
  opacity: 1;
  transform: translateY(0);
}
/* Staggered entry */
.mobile-nav-links-wrap li:nth-child(1) .nav-link { transition: opacity 0.38s ease 0.12s, transform 0.38s cubic-bezier(0.22,1,0.36,1) 0.12s, color 0.22s; }
.mobile-nav-links-wrap li:nth-child(2) .nav-link { transition: opacity 0.38s ease 0.18s, transform 0.38s cubic-bezier(0.22,1,0.36,1) 0.18s, color 0.22s; }
.mobile-nav-links-wrap li:nth-child(3) .nav-link { transition: opacity 0.38s ease 0.24s, transform 0.38s cubic-bezier(0.22,1,0.36,1) 0.24s, color 0.22s; }
.mobile-nav-links-wrap li:nth-child(4) .nav-link { transition: opacity 0.38s ease 0.30s, transform 0.38s cubic-bezier(0.22,1,0.36,1) 0.30s, color 0.22s; }
.mobile-nav-links-wrap li:nth-child(5) .nav-link { transition: opacity 0.38s ease 0.36s, transform 0.38s cubic-bezier(0.22,1,0.36,1) 0.36s, color 0.22s; }
.mobile-nav-overlay:not(.open) .mobile-nav-links-wrap .nav-link {
  transition: opacity 0.18s ease, transform 0.18s ease, color 0.22s;
}
.mobile-nav-links-wrap .nav-link:hover,
.mobile-nav-links-wrap .nav-link.active { color: var(--lime); }

/* Bottom bar */
.mobile-nav-bottom {
  padding: 18px 28px;
  border-top: 1px solid rgba(255,255,255,0.06);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-shrink: 0;
}
.mobile-nav-socials { display: flex; gap: 10px; }
.mobile-nav-social-btn {
  width: 38px; height: 38px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 50%;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.07);
  color: var(--text-3);
  text-decoration: none;
  font-size: 0.82rem;
  transition: color 0.22s, background 0.22s, border-color 0.22s;
}
.mobile-nav-social-btn:hover {
  color: var(--lime);
  background: rgba(1,251,29,0.07);
  border-color: rgba(1,251,29,0.22);
}
.mobile-nav-lang-btn {
  display: flex; align-items: center; gap: 5px;
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.09);
  border-radius: 50px;
  padding: 8px 18px;
  color: var(--text-3);
  font-size: 0.8rem;
  font-family: var(--font-display);
  letter-spacing: .08em;
  cursor: pointer;
  transition: border-color 0.22s, color 0.22s;
}
.mobile-nav-lang-btn:hover { border-color: rgba(1,251,29,0.3); color: var(--lime); }
.mobile-nav-lang-btn .lt-active { color: var(--lime); font-weight: 700; }
.mobile-nav-lang-btn .lt-sep    { color: rgba(255,255,255,0.15); }
