/* ═══════════════════════════════════════════════
   Navbar — Cooling Breeze Air Conditioning
   ═══════════════════════════════════════════════ */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800;900&display=swap');

:root {
  --navy:       #071428;
  --navy-2:     #0b1e3d;
  --navy-3:     #0d2550;
  --blue:       #1D7CC7;
  --blue-light: #3D8DD6;
  --blue-glow:  rgba(29,124,199,0.35);
  --ice:        #e8f4fd;
  --white:      #ffffff;
  --muted:      #8ab4d4;
  --top-h:      40px;
  --nav-h:      76px;
  --font:       'Inter', 'Segoe UI', sans-serif;
  --radius:     8px;
  --transition: 0.25s cubic-bezier(0.4,0,0.2,1);
}

/* ── Sticky wrapper ── */
.site-header {
  position: -webkit-sticky;
  position: sticky;
  top: 0;
  width: 100%;
  z-index: 500;
  font-family: var(--font);
}

/* ════════════════════════════════
   TOP BAR
   ════════════════════════════════ */
.top-bar {
  background: var(--navy);
  border-bottom: 1px solid rgba(29,124,199,0.2);
  height: var(--top-h);
  overflow: hidden;
  animation: hideTopBar linear both;
  animation-timeline: scroll(root);
  animation-range: 0px 80px;
}

@keyframes hideTopBar {
  0%   { height: var(--top-h); opacity: 1; }
  100% { height: 0; opacity: 0; }
}

.top-bar-inner {
  max-width: 1320px;
  margin: 0 auto;
  padding: 0 32px;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* Left: info chips */
.top-bar-left {
  display: flex;
  align-items: center;
  gap: 20px;
}

.top-chip {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.72rem;
  font-weight: 500;
  color: var(--muted);
  letter-spacing: 0.2px;
}

.top-chip svg { color: var(--blue-light); flex-shrink: 0; }

.top-chip a {
  color: var(--muted);
  text-decoration: none;
  transition: color var(--transition);
}
.top-chip a:hover { color: var(--white); }

/* Emergency badge */
.top-chip--emergency {
  background: rgba(29,124,199,0.12);
  border: 1px solid rgba(29,124,199,0.25);
  border-radius: 20px;
  padding: 2px 10px 2px 6px;
  color: var(--blue-light);
}
.top-chip--emergency svg { color: #F7BC4B; }

/* Right: socials */
.top-bar-right {
  display: flex;
  align-items: center;
  gap: 4px;
}

.social-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  color: var(--muted);
  border-radius: 6px;
  transition: color var(--transition), background var(--transition);
  text-decoration: none;
}
.social-icon:hover {
  color: var(--white);
  background: rgba(29,124,199,0.2);
}

/* ════════════════════════════════
   MAIN NAV
   ════════════════════════════════ */
.main-nav {
  height: var(--nav-h);
  background: rgba(7,20,40,0.92);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border-bottom: 1px solid rgba(29,124,199,0.18);
  box-shadow: 0 8px 40px rgba(0,0,0,0.35), 0 1px 0 rgba(29,124,199,0.12);
  transition: height var(--transition), box-shadow var(--transition);
}

.site-header.scrolled .main-nav {
  height: 62px;
  box-shadow: 0 4px 32px rgba(0,0,0,0.5), 0 1px 0 rgba(29,124,199,0.2);
}

.main-nav-inner {
  max-width: 1320px;
  margin: 0 auto;
  padding: 0 32px;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

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

.nav-logo__icon {
  width: 44px;
  height: 44px;
  background: linear-gradient(135deg, var(--blue) 0%, var(--blue-light) 100%);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 16px var(--blue-glow);
  transition: transform var(--transition), box-shadow var(--transition);
  flex-shrink: 0;
}

.nav-logo:hover .nav-logo__icon {
  transform: rotate(-15deg) scale(1.08);
  box-shadow: 0 6px 24px rgba(29,124,199,0.55);
}

.nav-logo__img {
  height: 48px;
  width: auto;
  object-fit: contain;
  display: block;
  transition: opacity var(--transition);
}

.nav-logo:hover .nav-logo__img { opacity: 0.85; }

.nav-brand {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
}

.nav-brand__name {
  font-size: 1.05rem;
  font-weight: 800;
  letter-spacing: 0.5px;
  color: var(--white);
}

.nav-brand__name span { color: var(--blue-light); }

.nav-brand__tagline {
  font-size: 0.58rem;
  font-weight: 500;
  letter-spacing: 2px;
  color: var(--muted);
  text-transform: uppercase;
}

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

/* Gliding active indicator */
.nav-indicator {
  position: absolute;
  bottom: -1px;
  height: 2px;
  background: linear-gradient(90deg, var(--blue), var(--blue-light), #7dd3fc);
  border-radius: 2px;
  transition: left 0.35s cubic-bezier(0.4,0,0.2,1), width 0.35s cubic-bezier(0.4,0,0.2,1), opacity 0.3s;
  box-shadow: 0 0 10px rgba(29,124,199,0.8), 0 0 20px rgba(29,124,199,0.4);
  pointer-events: none;
}

.nav-links li a {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  color: var(--muted);
  text-decoration: none;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.6px;
  text-transform: uppercase;
  border-radius: var(--radius);
  transition: color var(--transition), background var(--transition);
  white-space: nowrap;
  position: relative;
  overflow: hidden;
}

/* Shimmer sweep on hover */
.nav-links li a::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(105deg, transparent 40%, rgba(255,255,255,0.07) 50%, transparent 60%);
  transform: translateX(-100%);
  transition: transform 0.5s ease;
  pointer-events: none;
}

.nav-links li a:hover::before { transform: translateX(100%); }

.nav-links li a svg {
  opacity: 0.6;
  transition: opacity var(--transition), transform var(--transition);
}

.nav-links li a:hover {
  color: var(--white);
  background: rgba(29,124,199,0.1);
}

.nav-links li a:hover svg {
  opacity: 1;
  transform: scale(1.15);
}

/* Active pill */
.nav-links li.active a {
  color: var(--white);
  background: rgba(29,124,199,0.12);
}

.nav-links li.active a svg { opacity: 1; }

/* ── Right side: CTA + Hamburger ── */
.nav-right {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
}

/* Free Quote CTA button */
.nav-cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  background: linear-gradient(135deg, var(--blue) 0%, var(--blue-light) 100%);
  color: var(--white);
  font-family: var(--font);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.8px;
  text-transform: uppercase;
  text-decoration: none;
  border: none;
  border-radius: 50px;
  cursor: pointer;
  box-shadow: 0 4px 20px var(--blue-glow);
  transition: transform var(--transition), box-shadow var(--transition), background var(--transition);
  white-space: nowrap;
  position: relative;
  overflow: hidden;
}

/* Ripple container */
.nav-cta .ripple {
  position: absolute;
  border-radius: 50%;
  background: rgba(255,255,255,0.35);
  transform: scale(0);
  animation: rippleAnim 0.55s linear;
  pointer-events: none;
}

@keyframes rippleAnim {
  to { transform: scale(4); opacity: 0; }
}

.nav-cta:hover {
  transform: translateY(-2px) scale(1.03);
  box-shadow: 0 8px 28px rgba(29,124,199,0.55);
  background: linear-gradient(135deg, #1a6fb5 0%, var(--blue) 100%);
}

.nav-cta svg { flex-shrink: 0; transition: transform var(--transition); }
.nav-cta:hover svg { transform: translateX(3px); }

/* ── Hamburger ── */
.hamburger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 38px;
  height: 38px;
  cursor: pointer;
  padding: 7px;
  border-radius: var(--radius);
  background: rgba(29,124,199,0.1);
  border: 1px solid rgba(29,124,199,0.2);
  transition: background var(--transition);
}

.hamburger:hover { background: rgba(29,124,199,0.2); }

.hamburger .bar {
  display: block;
  height: 2px;
  background: var(--blue-light);
  border-radius: 2px;
  transition: transform 0.3s, opacity 0.3s, width 0.3s;
}

.hamburger .bar:nth-child(1) { width: 100%; }
.hamburger .bar:nth-child(2) { width: 65%; }
.hamburger .bar:nth-child(3) { width: 40%; }

.hamburger.open .bar:nth-child(1) { transform: translateY(7px) rotate(45deg); width: 100%; }
.hamburger.open .bar:nth-child(2) { opacity: 0; }
.hamburger.open .bar:nth-child(3) { transform: translateY(-7px) rotate(-45deg); width: 100%; }

/* ════════════════════════════════
   MOBILE DRAWER
   ════════════════════════════════ */
.mobile-drawer {
  display: none;
  position: fixed;
  top: 0;
  right: -100%;
  width: min(320px, 85vw);
  height: 100vh;
  background: var(--navy-2);
  z-index: 499;
  border-left: 1px solid rgba(29,124,199,0.2);
  box-shadow: -8px 0 40px rgba(0,0,0,0.5);
  transition: right 0.35s cubic-bezier(0.4,0,0.2,1);
  overflow-y: auto;
  padding: 80px 0 32px;
}

.mobile-drawer.open {
  display: block;
  right: 0;
}

/* Drawer overlay */
.drawer-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.55);
  z-index: 498;
  backdrop-filter: blur(3px);
}

.drawer-overlay.open { display: block; }

/* Drawer close btn */
.drawer-close {
  position: absolute;
  top: 20px;
  right: 20px;
  width: 36px;
  height: 36px;
  background: rgba(29,124,199,0.12);
  border: 1px solid rgba(29,124,199,0.25);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
  cursor: pointer;
  transition: background var(--transition), color var(--transition);
}

.drawer-close:hover { background: rgba(29,124,199,0.25); color: var(--white); }

/* Drawer brand */
.drawer-brand {
  padding: 0 24px 24px;
  border-bottom: 1px solid rgba(29,124,199,0.15);
  margin-bottom: 12px;
}

.drawer-brand__name {
  font-size: 1rem;
  font-weight: 800;
  color: var(--white);
}

.drawer-brand__name span { color: var(--blue-light); }

.drawer-brand__tag {
  font-size: 0.6rem;
  font-weight: 500;
  letter-spacing: 2px;
  color: var(--muted);
  text-transform: uppercase;
}

/* Drawer links */
.mobile-drawer ul {
  list-style: none;
  margin: 0;
  padding: 0 12px;
}

.mobile-drawer ul li a {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 13px 16px;
  color: var(--muted);
  text-decoration: none;
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  border-radius: var(--radius);
  transition: color var(--transition), background var(--transition);
  margin-bottom: 2px;
}

.mobile-drawer ul li a svg { opacity: 0.6; }

.mobile-drawer ul li a:hover,
.mobile-drawer ul li.active a {
  color: var(--white);
  background: rgba(29,124,199,0.12);
}

.mobile-drawer ul li.active a {
  color: var(--blue-light);
  background: rgba(29,124,199,0.15);
  border-left: 3px solid var(--blue);
}

/* Drawer CTA */
.drawer-cta {
  margin: 20px 24px 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 13px 20px;
  background: linear-gradient(135deg, var(--blue) 0%, var(--blue-light) 100%);
  color: var(--white);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  text-decoration: none;
  border-radius: 50px;
  box-shadow: 0 4px 20px var(--blue-glow);
}

.main-nav {
  --border-angle: 0turn;
  height: var(--nav-h);
  background: rgba(7,20,40,0.92);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border-bottom: 1px solid rgba(29,124,199,0.18);
  box-shadow: 0 8px 40px rgba(0,0,0,0.35), 0 1px 0 rgba(29,124,199,0.12);
  animation: shrinkNav linear both;
  animation-timeline: scroll(root);
  animation-range: 0px 80px;
}

@keyframes shrinkNav {
  0%   { height: var(--nav-h); box-shadow: 0 8px 40px rgba(0,0,0,0.35), 0 1px 0 rgba(29,124,199,0.12); }
  100% { height: 62px;        box-shadow: 0 4px 32px rgba(0,0,0,0.5),  0 1px 0 rgba(29,124,199,0.2); }
}

/* ════════════════════════════════
   SCROLL ANIMATION
   ════════════════════════════════ */
@keyframes navSlideDown {
  from { transform: translateY(-100%); opacity: 0; }
  to   { transform: translateY(0);     opacity: 1; }
}

.site-header { animation: navSlideDown 0.5s cubic-bezier(0.22,1,0.36,1) both; }

/* ════════════════════════════════
   RESPONSIVE
   ════════════════════════════════ */
@media (max-width: 1024px) {
  .nav-links { gap: 0; }
  .nav-links li a { padding: 8px 10px; font-size: 0.73rem; }
  .nav-cta { padding: 9px 16px; font-size: 0.7rem; }
}

@media (max-width: 860px) {
  .nav-links { display: none; }
  .nav-cta   { display: none; }
  .hamburger { display: flex; }
  .top-bar-left .top-chip:not(:first-child) { display: none; }
}

@media (max-width: 560px) {
  .top-bar { display: none; }
  .main-nav-inner { padding: 0 16px; }
  .nav-brand__tagline { display: none; }
}
