/* ============================================================
   topbar.css — Shared Navbar for ALL pages — بوصلة
   ============================================================ */

html, body {
  margin: 0;
  padding: 0;
}

.navbar {
  background: linear-gradient(180deg, #0d3b37 0%, #061816 100%);
  font-family: "IBM Plex Sans Arabic", "Segoe UI", Tahoma, Arial, sans-serif;
  height: 64px;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  box-shadow: 0 4px 32px rgba(0,0,0,0.5), 0 0 1px rgba(14,122,112,0.2);
  border-bottom: 1px solid rgba(102,202,194,0.12);
  backdrop-filter: blur(4px);
}

[dir="rtl"] .navbar {
  font-family: "IBM Plex Sans Arabic", "Segoe UI", Tahoma, Arial, sans-serif;
}

.navdiv {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 24px;
  position: relative;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 2px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.navdiv > ul {
  display: flex;
  align-items: center;
  gap: 2px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav-links li,
.navdiv > ul > li {
  list-style: none;
  display: inline-flex;
}

.nav-links a,
.navdiv > ul > li > a {
  display: flex;
  align-items: center;
  gap: 7px;
  text-decoration: none;
  color: #7ecbc5;
  font-size: 15px;
  font-weight: 600;
  padding: 8px 13px;
  border-radius: 8px;
  transition: background 0.22s, color 0.22s;
  white-space: nowrap;
}

.nav-links a:hover,
.navdiv > ul > li > a:hover {
  background: rgba(102,202,194,0.13);
  color: #c2f0ec;
}

.brand-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  user-select: none;
}

[dir="rtl"] .brand-logo {
  left: auto;
  right: 50%;
  transform: translateX(50%);
}

.brand-icon {
  font-size: 25px;
  color: #66cac2;
  filter: drop-shadow(0 0 7px rgba(102,202,194,0.45));
  transition: transform 0.4s ease;
}

.brand-logo:hover .brand-icon {
  transform: rotate(45deg);
}

.brand-name {
  font-size: 18px;
  font-weight: 400;
  color: #eaf6f5;
  letter-spacing: 0.3px;
  white-space: nowrap;
}

.brand-name strong {
  font-weight: 800;
  color: #66cac2;
}

.nav-actions,
.first-conent {
  display: flex;
  align-items: center;
  gap: 10px;
}

.lang-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(102,202,194,0.1);
  border: 1px solid rgba(102,202,194,0.35);
  color: #66cac2;
  font-family: "IBM Plex Sans Arabic", "Segoe UI", Tahoma, Arial, sans-serif;
  font-size: 13px;
  font-weight: 700;
  padding: 7px 14px;
  border-radius: 20px;
  cursor: pointer;
  transition: background 0.22s, color 0.22s, border-color 0.22s;
  white-space: nowrap;
}

.lang-btn:hover {
  background: rgba(102,202,194,0.22);
  color: #c2f0ec;
  border-color: rgba(102,202,194,0.6);
}

.create-btn {
  font-family: "IBM Plex Sans Arabic", "Segoe UI", Tahoma, Arial, sans-serif;
  background: #66cac2;
  color: #0a2f2c;
  font-weight: 800;
  font-size: 14px;
  border: none;
  border-radius: 8px;
  padding: 9px 18px;
  cursor: pointer;
  transition: background 0.22s, transform 0.2s, box-shadow 0.22s;
  white-space: nowrap;
}

.create-btn:hover {
  background: #4ab5ad;
  transform: translateY(-1px);
  box-shadow: 0 4px 14px rgba(102,202,194,0.3);
}

button.tablinks {
  font-family: "IBM Plex Sans Arabic", "Segoe UI", Tahoma, Arial, sans-serif;
  background: #66cac2;
  color: #0a2f2c;
  font-weight: 800;
  font-size: 14px;
  margin-left: 6px;
  border: none;
  border-radius: 8px;
  padding: 9px 16px;
  width: auto;
  min-width: 100px;
  cursor: pointer;
  transition: background 0.22s;
}

button.tablinks:hover {
  background: #4ab5ad;
}

@media (max-width: 700px) {
  .brand-name { display: none; }
  .nav-links a,
  .navdiv > ul > li > a { padding: 8px 9px; font-size: 13px; gap: 5px; }
  .lang-btn .lang-text { display: none; }
  .navdiv { padding: 0 14px; }
}

/* On very narrow phones, "Home" + "Account" + the centered logo + the lang
   button + "Saved Trips" all fighting for one row overflowed/crowded into
   each other. Icons-only for the nav links (their text is still read by
   screen readers via the visually-hidden span) frees up enough room. */
@media (max-width: 480px) {
  .navdiv { padding: 0 10px; gap: 4px; }
  .nav-links { gap: 0; }
  .nav-links a span,
  .navdiv > ul > li > a span {
    position: absolute;
    width: 1px; height: 1px;
    padding: 0; margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
  }
  .nav-links a,
  .navdiv > ul > li > a {
    padding: 8px;
    font-size: 16px;
  }
  .lang-btn { padding: 7px 10px; }
  .create-btn { padding: 8px 12px; font-size: 12.5px; }
  .brand-icon { font-size: 21px; }
}
