/* ==========================================================================
   Header & Topbar Styles — Matching Visual Reference Exactly
   شركة الكوادر العاملة للتشغيل والصيانة
   ========================================================================== */

/* Topbar */
.topbar {
  background-color: var(--navy);
  color: #cfd9e5;
  font-size: 0.78rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  position: relative;
  z-index: 101;
}

.topbar .inner {
  min-height: var(--topbar-height);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-md);
}

.topbar-left {
  display: flex;
  align-items: center;
  gap: 20px;
}

.topbar-center {
  display: flex;
  align-items: center;
  gap: 6px;
  color: #b8c7d9;
}

.topbar-right {
  display: flex;
  align-items: center;
  gap: 16px;
}

.topbar-item {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #cfd9e5;
  text-decoration: none;
  transition: color var(--transition-fast);
}

.topbar-item:hover {
  color: var(--gold-light);
}

.topbar-icon {
  width: 13px;
  height: 13px;
  fill: var(--gold-light);
  flex-shrink: 0;
}

.topbar-socials {
  display: flex;
  align-items: center;
  gap: 12px;
}

.topbar-socials a {
  color: #b8c7d9;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: color var(--transition-fast), transform var(--transition-fast);
  text-decoration: none;
}

.topbar-socials a:hover {
  color: var(--gold-light);
  transform: translateY(-1px);
}

.topbar-socials svg {
  width: 14px;
  height: 14px;
  fill: currentColor;
}

.topbar-lang {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  color: #cfd9e5;
  font-family: var(--font-latin);
  font-weight: 600;
  text-decoration: none;
  font-size: 0.74rem;
  border-right: 1px solid rgba(255, 255, 255, 0.15);
  padding-right: 12px;
  margin-right: 4px;
}

.topbar-lang:hover {
  color: var(--gold-light);
}

/* Header & Main Navigation */
header {
  position: sticky;
  top: 0;
  z-index: 100;
  background-color: var(--white);
  border-bottom: 1px solid var(--line);
  transition: box-shadow var(--transition-normal);
}

header.scrolled {
  box-shadow: 0 4px 18px rgba(11, 32, 56, 0.06);
}

nav {
  height: var(--header-height);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-md);
}

/* Brand Logo */
.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  flex-shrink: 0;
}

.brand img {
  width: 56px;
  height: 50px;
  object-fit: contain;
  border-radius: var(--radius-xs);
}

.brand-text {
  display: flex;
  flex-direction: column;
}

.brand strong {
  font-size: 1.02rem;
  font-weight: 700;
  line-height: 1.25;
  color: var(--navy);
}

.brand small {
  display: block;
  color: var(--gold);
  font-weight: 600;
  font-size: 0.78rem;
  margin-top: 1px;
}

/* Navlinks */
.navlinks {
  display: flex;
  align-items: center;
  gap: 24px;
  font-weight: 600;
  font-size: 0.88rem;
}

.navlinks a {
  position: relative;
  padding: 8px 0;
  color: var(--ink-secondary);
  text-decoration: none;
  transition: color var(--transition-fast);
}

.navlinks a:hover,
.navlinks a.active {
  color: var(--navy);
  font-weight: 700;
}

.navlinks a.active::after {
  content: "";
  position: absolute;
  right: 0;
  bottom: -2px;
  width: 100%;
  height: 2px;
  background-color: var(--gold);
  border-radius: var(--radius-full);
}

/* Header CTA Button */
.navcta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  border-radius: var(--radius-sm);
  padding: 10px 18px;
  font-weight: 700;
  font-size: 0.85rem;
  background: linear-gradient(135deg, #c7953e 0%, #b88226 100%);
  color: var(--white) !important;
  text-decoration: none;
  transition: all var(--transition-normal);
  border: 1px solid rgba(255, 255, 255, 0.2);
  box-shadow: 0 4px 12px rgba(199, 149, 62, 0.25);
  flex-shrink: 0;
}

.navcta:hover {
  background: linear-gradient(135deg, #d3a148 0%, #c48c2e 100%);
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(199, 149, 62, 0.35);
}

/* Mobile Toggle */
.menu {
  display: none;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: var(--radius-xs);
  color: var(--navy);
  background: transparent;
  border: 1px solid var(--line);
  cursor: pointer;
}

.menu-icon {
  width: 20px;
  height: 14px;
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.menu-bar {
  display: block;
  width: 100%;
  height: 2px;
  background-color: var(--navy);
  border-radius: var(--radius-full);
  transition: all var(--transition-normal);
}

.menu[aria-expanded="true"] .menu-bar:nth-child(1) {
  transform: translateY(6px) rotate(45deg);
}

.menu[aria-expanded="true"] .menu-bar:nth-child(2) {
  opacity: 0;
  transform: scaleX(0);
}

.menu[aria-expanded="true"] .menu-bar:nth-child(3) {
  transform: translateY(-6px) rotate(-45deg);
}
