/* ============================================
   Om Automobile — nav.css
   All navigation styles
   ============================================ */

/* ── Nav wrapper ── */
#main-nav {
  position: fixed;
  top: 0; left: 0;
  width: 100%;
  z-index: 1000;
  display: flex;
  align-items: center;
  height: var(--nav-h);
  padding: 0 2.5rem;
  gap: 2rem;
  background: var(--dark);
  border-bottom: 1px solid var(--border);
  transition: background var(--ease), box-shadow var(--ease);
}

#main-nav.scrolled {
  background: rgba(13, 13, 13, 0.96);
  box-shadow: 0 4px 32px rgba(0,0,0,0.55);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}

/* ── Logo ── */
.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
  cursor: pointer;
  text-decoration: none;
}

.logo-icon {
  width: 38px; height: 38px;
  background: var(--red);
  border-radius: 8px;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
  transition: background var(--ease), transform 0.2s;
}
.logo:hover .logo-icon {
  background: var(--red-h);
  transform: rotate(-5deg) scale(1.05);
}
.logo-icon svg {
  width: 20px; height: 20px;
  fill: none;
  stroke: #fff;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.logo-text {
  font-family: 'Rajdhani', sans-serif;
  font-size: 21px;
  font-weight: 700;
  color: #fff;
  letter-spacing: 1.5px;
  white-space: nowrap;
}
.logo-text span { color: var(--red); }

/* ── Nav Links ── */
.nav-links {
  display: flex;
  align-items: center;
  gap: 2px;
  flex: 1;
  list-style: none;
  margin: 0; padding: 0;
}

.nav-links li { position: relative; }

.nav-links li a {
  display: inline-flex;
  align-items: center;
  padding: 8px 13px;
  font-size: 13.5px;
  font-weight: 500;
  color: #c0c0c0;
  border-radius: 6px;
  text-decoration: none;
  white-space: nowrap;
  transition: color var(--ease), background var(--ease);
}
.nav-links li a:hover { color: #fff; background: rgba(255,255,255,0.07); }
.nav-links li a.active { color: var(--red); }

/* Red underline */
.nav-links li a::after {
  content: '';
  position: absolute;
  bottom: 0; left: 13px; right: 13px;
  height: 2px;
  background: var(--red);
  border-radius: 2px;
  transform: scaleX(0);
  transition: transform var(--ease);
  transform-origin: center;
}
.nav-links li a:hover::after,
.nav-links li a.active::after { transform: scaleX(1); }

/* ── Nav Right ── */
.nav-right {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-shrink: 0;
}

.nav-phone {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  font-weight: 600;
  color: var(--red);
  text-decoration: none;
  white-space: nowrap;
  transition: color var(--ease);
}
.nav-phone:hover { color: #ff6b4a; }
.nav-phone svg {
  width: 15px; height: 15px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.nav-cta {
  background: var(--red);
  color: #fff;
  font-family: 'Inter', sans-serif;
  font-size: 13px;
  font-weight: 700;
  padding: 9px 20px;
  border-radius: 6px;
  border: none;
  cursor: pointer;
  white-space: nowrap;
  transition: background var(--ease), transform 0.12s;
}
.nav-cta:hover  { background: var(--red-h); }
.nav-cta:active { transform: scale(0.96); }

/* ── Hamburger ── */
.hamburger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 42px; height: 42px;
  padding: 9px;
  background: transparent;
  border: 1.5px solid rgba(255,255,255,0.16);
  border-radius: 7px;
  cursor: pointer;
  flex-shrink: 0;
  transition: border-color var(--ease);
}
.hamburger:hover { border-color: rgba(255,255,255,0.38); }
.hamburger span {
  display: block;
  height: 2px;
  background: #fff;
  border-radius: 2px;
  transition: transform 0.3s ease, opacity 0.3s ease;
}
.hamburger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.hamburger.open span:nth-child(2) { opacity: 0; transform: scaleX(0); }
.hamburger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ── Overlay ── */
.nav-overlay {
  display: none;
  position: fixed; inset: 0;
  background: rgba(0,0,0,0.65);
  z-index: 990;
  opacity: 0;
  transition: opacity 0.28s ease;
}
.nav-overlay.show { display: block; opacity: 1; }

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 1060px) {
  .nav-phone { display: none; }
}

@media (max-width: 820px) {
  #main-nav { padding: 0 1.2rem; }

  /* hide desktop items */
  .nav-links  { display: none; }
  .nav-right  { display: none; }
  .hamburger  { display: flex; }

  /* Mobile drawer */
  .nav-links.mobile-open {
    display: flex !important;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    list-style: none;
    margin: 0; padding: 0.8rem 0 2rem;

    position: fixed;
    top: var(--nav-h); left: 0;
    width: min(290px, 85vw);
    height: calc(100dvh - var(--nav-h));
    overflow-y: auto;
    overscroll-behavior: contain;

    background: #111;
    border-right: 1px solid rgba(255,255,255,0.07);
    z-index: 995;
    animation: slideInLeft 0.3s cubic-bezier(0.4,0,0.2,1);
  }

  @keyframes slideInLeft {
    from { transform: translateX(-100%); opacity: 0.6; }
    to   { transform: translateX(0);     opacity: 1; }
  }

  .nav-links.mobile-open li a {
    display: block;
    padding: 14px 1.5rem;
    font-size: 15px;
    color: #ccc;
    border-radius: 0;
    border-bottom: 1px solid rgba(255,255,255,0.05);
  }
  .nav-links.mobile-open li a:hover   { background: rgba(255,255,255,0.04); color: #fff; }
  .nav-links.mobile-open li a.active  { color: var(--red); background: rgba(230,48,18,0.06); }
  .nav-links.mobile-open li a::after  { display: none; }

  /* CTA at bottom of drawer */
  .nav-links.mobile-open::after {
    content: '📞 Book Service';
    display: block;
    margin: 1.2rem 1.2rem 0;
    padding: 13px;
    background: var(--red);
    color: #fff;
    font-size: 14px;
    font-weight: 700;
    border-radius: 7px;
    text-align: center;
    cursor: pointer;
  }
}

@media (max-width: 480px) {
  #main-nav { padding: 0 1rem; gap: 1rem; }
  .logo-text { font-size: 18px; }
}
