/* ================= SMART AUTO HEADER ================= */

.dncl-header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 9999;

  background: transparent;
  transition: opacity 0.25s ease;
}

/* ================= HEADER STATES ================= */

/* Hidden (leave a small hover area) */
.dncl-header.hide {
   opacity: 0;
  pointer-events: none;
}

/* Visible */
.dncl-header.show {
  opacity: 1;
}

/* Invisible hover trigger at top */
.dncl-header::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 1.2em;
  pointer-events: auto;
}

/* ================= HEADER CONTAINER ================= */

.dncl-header-container {
  max-width: 1400px;
  margin: auto;
  padding: 12px 32px;
  display: flex;
  grid-template-columns: auto 1fr auto; /* LEFT | CENTER | RIGHT */
  align-items: center;
}

/* ================= FORCE TEXT COLOR ================= */

.dncl-header,
.dncl-header .nav-link {
  color: #0b1220 !important;
}

/* ================= NAV ================= */

.dncl-nav {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 32px;
  margin-left: 8px;
  flex: 1;
}

.nav-link {
  position: relative;
  display: inline-block;
  padding: 6px 0;
  font-family: "Poppins", "Segoe UI", sans-serif;
  font-size: 18px;
  font-weight: 700;
  text-decoration: none;
  color: #0b1220;
  cursor: pointer;
}

/* underline */
.nav-link::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -6px;
  width: 0%;
  height: 3px;
  background: #1e40ff;
  border-radius: 3px;
  transition: width 0.25s ease;
}

.nav-link:hover::after {
  width: 100%;
}

.nav-link:hover {
  color: #1e40ff;
}

/* ================= DROPDOWN ================= */

.nav-item {
  position: relative;
  display: inline-block;
}

/* hover bridge */
.nav-item.dropdown::after {
  content: "";
  position: absolute;
  left: 0;
  top: 100%;
  width: 100%;
  height: 16px;
}

.dropdown-menu {
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  background: #ffffff;
  min-width: 240px;
  border-radius: 10px;
  box-shadow: 0 14px 40px rgba(0,0,0,0.15);
  padding: 10px 0;

  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.25s ease, transform 0.25s ease;
}

.dropdown-menu a {
  display: block;
  padding: 12px 20px;
  font-weight: 600;
  color: #111;
  text-decoration: none;
}

.dropdown-menu a:hover {
  background: #f1f5ff;
  color: #1e40ff;
}

/* show dropdown */
.nav-item.dropdown:hover .dropdown-menu {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

/* ================= RIGHT SIDE ================= */

.dncl-header-right {
  display: flex;
  align-items: center;
  flex-shrink: 0;     /* 🔥 prevents layout bleed */
}

.madein-badge {
  height: 82px;
  width: auto;
  object-fit: contain;
  margin-left: 0;    
}

/* ================= LOGO ================= */

.logo-inner{
  height:83px;   /* adjust size */
  width:auto;
}

@media (max-width: 900px) {
  .logo-inner {
    height: 48px;
  }
}

/* ================= MOBILE ================= */

.mobile-menu-btn {
  display: none;
}



/* ================= MISC ================= */

.nav-parent {
  cursor: default;
}

.dncl-logo:focus-visible {
  outline: none;
}


.dncl-logo{
  display:flex;
  align-items:center;
  margin-right:20px;   /* space between logo and nav */
}

.dncl-header-container{
  padding-left:10px;   /* move whole header content left */
}

.dncl-header-container{
  padding-left:0;
}


/* =====================================
   RESPONSIVE FIX — HEADER
===================================== */

/* LARGE TABLETS */
@media (max-width: 1024px) {
  .dncl-header-container {
    padding: 10px 20px;
  }

  .nav-link {
    font-size: 16px;
  }

  .madein-badge {
  height: clamp(28px, 4vw, 82px);
  }
}

/* TABLET / MOBILE SWITCH */
@media (max-width: 900px) {
  .dncl-header {
    background: transparent;
  }

  .dncl-header.hide {
    transform: translateY(0); /* disable auto-hide on mobile */
  }

  .dncl-header::before {
    display: none;
  }

  .dncl-header-container {
    justify-content: space-between;
  }

  .mobile-menu-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 26px;
    cursor: pointer;
  }
}

/* MOBILE */
@media (max-width: 600px) {
  .logo-inner {
    height: 42px;
  }

  .madein-badge {
    height: 52px;
  }

  .dncl-header-container {
    padding: 8px 16px;
  }
}

/* VERY SMALL DEVICES */
@media (max-width: 380px) {
  .logo-inner {
    height: 36px;
  }

  .madein-badge {
    height: 46px;
  }
}


/* =========================
   FORCE NAV TABS VISIBLE
   (Mobile / Tablet / PC)
========================= */

@media (max-width: 900px) {
   .dncl-nav {
    flex: 1;
    min-width: 0;              /* VERY IMPORTANT */
    flex-wrap: nowrap;
    overflow-x: auto;          /* allow scroll */
    white-space: nowrap;
    justify-content: flex-start;
  }


  .dncl-nav::-webkit-scrollbar {
    display: none;
  }

  .nav-link {
    font-size: 14px;
    white-space: nowrap;
  }
}



@media (max-width: 600px) {
  .dncl-nav {
    gap: 12px;
  }

  .nav-link {
    font-size: 13px;
  }
}


/* =========================
   MOBILE — SINGLE ROW HEADER
========================= */

@media (max-width: 900px) {
  .dncl-header-container {
    flex-direction: row;        /*  back to single row */
    align-items: center;
    gap: 10px;
  }

   .dncl-nav {
    min-width: 0;              /* critical */
    justify-content: flex-start; /* NOT center */
    flex-wrap: nowrap;
    overflow-x: auto;
    white-space: nowrap;
    display: none !important;
  }

  .dncl-nav::-webkit-scrollbar {
    display: none;
  }
}


@media (max-width: 900px) {
  .dncl-logo,
  .dncl-header-right {
    flex-shrink: 0;
  }

  .logo-inner {
    height: 26px;   /*  smaller */
  }

  .madein-badge {
    height: 24px;   /*  smaller */
  }
}



@media (max-width: 900px) {
  .nav-link {
    font-size: 12px;
    font-weight: 600;
    padding: 4px 4px;
    flex-shrink: 0;          /*  IMPORTANT */
    white-space: nowrap;
  }
}



@media (max-width: 600px) {
  .logo-inner {
    height: 26px;
  }

  .madein-badge {
    height: 24px;
  }

  .nav-link {
    font-size: 11px;
  }
}


@media (max-width: 360px) {
  .dncl-nav {
    gap: 6px;
  }

  .nav-link {
    font-size: 11px;
    padding: 3px 3px;
  }
}


.desktop-only {
  display: flex;
  justify-content: center;
}


.mobile-menu-btn {
  display: none;
  background: none;
  border: none;
  font-size: 26px;
  cursor: pointer;
  margin-left: 12px;
}

.mobile-menu {
  display: none;
}



@media (max-width: 900px) {

  /* hide desktop nav */
  .desktop-only {
    display: none;
  }

  .mobile-menu-btn {
    display: block;
  }

  .mobile-menu {
    position: fixed;
    top: 72px;
    left: 0;
    right: 0;
    background: #ffffff;
    padding: 20px;
    box-shadow: 0 12px 40px rgba(0,0,0,0.15);
    display: flex;
    flex-direction: column;
    gap: 14px;
    transform: translateY(-10px);
    opacity: 0;
    pointer-events: none;
    transition: all 0.3s ease;
    z-index: 9998;
  }

  .mobile-menu.open {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
  }

  .mobile-menu a,
  .mobile-menu summary {
    font-size: 16px;
    font-weight: 600;
    color: #0b1220;
    text-decoration: none;
    cursor: pointer;
  }

  .mobile-menu details {
    display: flex;
    flex-direction: column;
    gap: 10px;
  }

  .mobile-menu details a {
    padding-left: 12px;
    font-size: 14px;
    font-weight: 500;
  }
}


