/*==========================================================
  #HEADER — Varniraj Organic Agro
  Marquee bar · Top info bar · Sticky glassmorphism nav
  Scroll-shrink · Animated underline links · Mobile drawer
==========================================================*/

/* -------------------------------------------------------
   1.  MARQUEE BAR
------------------------------------------------------- */
.marquee-bar {
  background: linear-gradient(90deg,
    hsl(36,100%,42%) 0%,
    hsl(40,100%,48%) 35%,
    hsl(36,100%,44%) 65%,
    hsl(33,100%,40%) 100%);
  padding-block: 9px;
  overflow: hidden;
  position: relative;
  z-index: 100;
}

/* shimmer sweep */
.marquee-bar::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    105deg,
    transparent 30%,
    hsla(0,0%,100%,0.18) 50%,
    transparent 70%
  );
  animation: mSweep 4s linear infinite;
  pointer-events: none;
}

@keyframes mSweep {
  0%   { transform: translateX(-100%); }
  100% { transform: translateX(200%);  }
}

.marquee-track  { width: 100%; overflow: hidden; }

.marquee-content {
  display: flex;
  align-items: center;
  white-space: nowrap;
  animation: marqueeScroll 38s linear infinite;
  will-change: transform;
}

.marquee-content:hover { animation-play-state: paused; }

@keyframes marqueeScroll {
  0%   { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

.marquee-item {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: hsl(30,40%,10%);
  font-size: 1.2rem;
  font-weight: 700;
  padding-inline: 22px;
  letter-spacing: 0.3px;
  text-transform: uppercase;
}

.marquee-item ion-icon {
  font-size: 1.5rem;
  color: hsl(152,88%,22%);
  flex-shrink: 0;
}

.marquee-sep {
  color: hsl(152,88%,28%);
  font-size: 0.9rem;
  flex-shrink: 0;
  opacity: 0.65;
}

/* -------------------------------------------------------
   2.  TOP INFO BAR
------------------------------------------------------- */
.top-bar {
  background: hsl(152,90%,10%);
  border-bottom: 1px solid hsla(152,95%,50%,0.12);
  padding-block: 8px;
}

.top-bar-inner {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px 20px;
  font-size: 1.2rem;
}

.top-bar-left,
.top-bar-right {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px 14px;
}

.top-bar-item {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: hsla(0,0%,100%,0.68);
  font-size: 1.45rem;
  font-weight: 500;
  white-space: nowrap;
  text-decoration: none;
}

.top-bar-item ion-icon {
  color: hsl(46,100%,65%);
  font-size: 1.6rem;
  flex-shrink: 0;
}

.top-bar-link {
  transition: color 0.2s;
}

.top-bar-link:hover { color: hsl(46,100%,70%); }

.top-bar-sep {
  color: hsla(0,0%,100%,0.18);
  font-size: 1.45rem;
  user-select: none;
}

/* 2-col layout on wider screens */
@media (min-width: 768px) {
  .top-bar-inner {
    justify-content: space-between;
    font-size: 1.55rem;
  }
  .top-bar-item { font-size: 1.55rem; }
}

/* hide right side on mobile to save space */
@media (max-width: 575px) {
  .top-bar-right { display: none; }
  .top-bar-inner { justify-content: center; }
}

/* -------------------------------------------------------
   3.  MAIN NAV WRAPPER
------------------------------------------------------- */
.header {
  position: sticky;
  top: 0;
  z-index: 200;
  background: #fff;
  box-shadow: 0 2px 24px hsla(0,0%,0%,0.07);
  transition: box-shadow 0.3s;
}

/* scrolled state — added by JS */
.header.scrolled {
  box-shadow: 0 4px 32px hsla(0,0%,0%,0.13);
}

.nav-wrapper {
  background: #fff;
  border-bottom: 2px solid hsl(152,95%,91%);
}

.nav-wrapper .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding-block: 14px;
  padding-inline: 20px;
}

/* -------------------------------------------------------
   4.  LOGO
------------------------------------------------------- */
.nav-logo {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  flex-shrink: 0;
}

/* Icon box */
.nav-logo-icon {
  position: relative;
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: linear-gradient(135deg, hsl(152,95%,30%), hsl(152,88%,16%));
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2.2rem;
  color: #fff;
  flex-shrink: 0;
  box-shadow:
    0 6px 18px hsla(152,95%,20%,0.45),
    inset 0 1px 0 hsla(0,0%,100%,0.15);
  transition: transform 0.35s cubic-bezier(0.33, 0.85, 0.4, 0.96),
              box-shadow 0.35s;
}

.nav-logo:hover .nav-logo-icon {
  transform: rotate(-10deg) scale(1.1);
  box-shadow: 0 10px 28px hsla(152,95%,20%,0.6);
}

/* FSSAI badge — tiny green pip */
.nav-logo-icon::after {
  content: "";
  position: absolute;
  bottom: -3px;
  right: -3px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: hsl(46,100%,62%);
  border: 2px solid #fff;
}

/* Text stack */
.nav-logo-text {
  display: flex;
  flex-direction: column;
  gap: 1px;
  line-height: 1.2;
}

.nav-logo-name {
  color: hsl(152,88%,18%);
  font-family: 'Playfair Display', serif;
  font-size: 2.6rem;
  font-weight: 700;
  letter-spacing: -0.3px;
}

.nav-logo-sub {
  display: block;
  color: var(--emerald, hsl(152,95%,39%));
  font-family: 'Roboto', sans-serif;
  font-size: 1.3rem;
  font-weight: 600;
  letter-spacing: 0.2px;
}

/* -------------------------------------------------------
   5.  DESKTOP NAV LINKS
------------------------------------------------------- */
.navbar-list {
  display: flex;
  align-items: center;
  gap: 4px;
  list-style: none;
  margin: 0; padding: 0;
}

.navbar-link {
  position: relative;
  display: block;
  color: hsl(206,21%,20%);
  font-size: 1.7rem;
  font-weight: 600;
  padding: 9px 16px;
  border-radius: 10px;
  text-decoration: none;
  transition: color 0.22s, background 0.22s;
  white-space: nowrap;
}

/* animated underline */
.navbar-link::after {
  content: "";
  position: absolute;
  bottom: 5px;
  left: 16px;
  right: 16px;
  height: 2px;
  background: hsl(152,95%,36%);
  border-radius: 2px;
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform 0.28s cubic-bezier(0.33, 0.85, 0.4, 0.96);
}

.navbar-link:hover,
.navbar-link.active {
  color: hsl(152,88%,22%);
  background: hsl(152,95%,95%);
}

.navbar-link:hover::after,
.navbar-link.active::after {
  transform: scaleX(1);
}

/* -------------------------------------------------------
   6.  HEADER RIGHT ACTIONS
------------------------------------------------------- */
.header-action {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

/* search icon button */
.header-action-btn {
  position: relative;
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: hsl(152,95%,95%);
  border: 1.5px solid hsl(152,95%,85%);
  color: hsl(152,88%,22%);
  font-size: 1.9rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background 0.22s, border-color 0.22s, color 0.22s, transform 0.22s;
}

.header-action-btn:hover {
  background: hsl(152,95%,36%);
  border-color: hsl(152,95%,36%);
  color: #fff;
  transform: scale(1.07);
}

/* search icon toggle */
.search-wrapper .close-icon { display: none; }
.search-wrapper.active .search-icon { display: none; }
.search-wrapper.active .close-icon  { display: block; }

/* search dropdown */
.input-wrapper {
  position: absolute;
  top: calc(100% + 14px);
  right: 0;
  width: 300px;
  background: #fff;
  border-radius: 16px;
  border: 1.5px solid hsl(152,95%,85%);
  box-shadow: 0 12px 40px hsla(0,0%,0%,0.12);
  padding: 14px;
  visibility: hidden;
  opacity: 0;
  transform: translateY(-8px) scale(0.96);
  transform-origin: top right;
  transition: 0.2s cubic-bezier(0.51,0.03,0.64,0.28);
  z-index: 20;
}

.search-wrapper { position: relative; }

.search-wrapper.active .input-wrapper {
  visibility: visible;
  opacity: 1;
  transform: translateY(0) scale(1);
  transition: 0.3s cubic-bezier(0.33,0.85,0.4,0.96);
}

.search-input {
  width: 100%;
  padding: 12px 42px 12px 14px;
  border: 1.5px solid hsl(152,95%,85%);
  border-radius: 10px;
  font-size: 1.5rem;
  color: hsl(206,21%,18%);
  background: hsl(152,20%,97%);
  outline: none;
  transition: border-color 0.22s, box-shadow 0.22s;
}

.search-input:focus {
  border-color: hsl(152,95%,36%);
  box-shadow: 0 0 0 3px hsla(152,95%,39%,0.12);
  background: #fff;
}

.search-input::-webkit-search-cancel-button { display: none; }

.search-submit {
  position: absolute;
  top: 50%;
  right: 26px;
  transform: translateY(-50%);
  color: hsl(152,88%,28%);
  font-size: 1.8rem;
  background: none;
  border: none;
  cursor: pointer;
}

/* enquire CTA button */
.header-enquire-btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  background: linear-gradient(135deg, hsl(152,95%,34%), hsl(152,88%,20%));
  color: #fff;
  font-size: 1.55rem;
  font-weight: 700;
  padding: 12px 26px;
  border-radius: 50px;
  text-decoration: none;
  border: 1px solid hsla(152,95%,55%,0.25);
  box-shadow: 0 4px 16px hsla(152,88%,20%,0.38);
  transition: transform 0.25s, box-shadow 0.25s, background 0.25s;
  white-space: nowrap;
}

.header-enquire-btn ion-icon { font-size: 1.8rem; }

.header-enquire-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px hsla(152,88%,20%,0.5);
  background: linear-gradient(135deg, hsl(152,95%,38%), hsl(152,88%,24%));
}

/* call button */
.header-call-btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  background: hsl(152,95%,95%);
  color: hsl(152,88%,20%);
  font-size: 1.5rem;
  font-weight: 700;
  padding: 12px 20px;
  border-radius: 50px;
  text-decoration: none;
  border: 1.5px solid hsl(152,95%,80%);
  transition: background 0.22s, color 0.22s, border-color 0.22s, transform 0.22s;
  white-space: nowrap;
}

.header-call-btn ion-icon { font-size: 1.8rem; color: hsl(152,88%,26%); }

.header-call-btn:hover {
  background: hsl(152,88%,26%);
  color: #fff;
  border-color: hsl(152,88%,26%);
  transform: translateY(-2px);
}

.header-call-btn:hover ion-icon { color: #fff; }

/* -------------------------------------------------------
   7.  HAMBURGER (mobile only)
------------------------------------------------------- */
.nav-open-btn {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  padding: 10px;
  border-radius: 10px;
  background: hsl(152,95%,95%);
  border: 1.5px solid hsl(152,95%,82%);
  cursor: pointer;
  transition: background 0.22s, border-color 0.22s;
  flex-shrink: 0;
}

.nav-open-btn span {
  display: block;
  height: 2px;
  border-radius: 2px;
  background: hsl(152,88%,22%);
  transition: transform 0.3s, opacity 0.3s, width 0.3s;
}

.nav-open-btn span:nth-child(2) { width: 70%; }

.nav-open-btn:hover {
  background: hsl(152,95%,36%);
  border-color: hsl(152,95%,36%);
}

.nav-open-btn:hover span { background: #fff; width: 100% !important; }

/* -------------------------------------------------------
   8.  MOBILE DRAWER (< 992px)
------------------------------------------------------- */
.navbar {
  /* mobile: off-canvas drawer */
  position: fixed;
  inset: 0 auto 0 0;
  width: min(320px, 85vw);
  background: hsl(152,88%,10%);
  z-index: 300;
  padding: 0;
  display: flex;
  flex-direction: column;
  overflow-y: auto;
  transform: translateX(-100%);
  visibility: hidden;
  transition: transform 0.35s cubic-bezier(0.51,0.03,0.64,0.28),
              visibility 0.35s;
  box-shadow: 4px 0 40px hsla(0,0%,0%,0.3);
}

.navbar.active {
  transform: translateX(0);
  visibility: visible;
  transition: transform 0.4s cubic-bezier(0.33,0.85,0.4,0.96),
              visibility 0.4s;
}

/* drawer header */
.nav-drawer-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 22px 18px;
  border-bottom: 1px solid hsla(0,0%,100%,0.08);
}

.nav-drawer-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
}

.nav-drawer-logo-icon {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: linear-gradient(135deg, hsl(152,95%,38%), hsl(152,88%,22%));
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.8rem;
  color: #fff;
}

.nav-drawer-logo-text {
  font-family: 'Playfair Display', serif;
  font-size: 1.9rem;
  font-weight: 700;
  color: #fff;
  line-height: 1.2;
}

.nav-drawer-logo-sub {
  display: block;
  font-family: 'Roboto', sans-serif;
  font-size: 0.95rem;
  font-weight: 500;
  color: hsl(46,100%,68%);
}

/* close button */
.nav-close-btn {
  width: 36px;
  height: 36px;
  border-radius: 8px;
  background: hsla(0,0%,100%,0.08);
  border: 1px solid hsla(0,0%,100%,0.14);
  color: rgba(255,255,255,0.8);
  font-size: 2.2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background 0.22s, color 0.22s;
}

.nav-close-btn:hover {
  background: hsla(0,0%,100%,0.16);
  color: #fff;
}

/* nav links in drawer */
.navbar-list {
  flex-direction: column;
  gap: 2px;
  padding: 16px 14px;
  flex: 1;
}

/* drawer-specific link style (overrides desktop) */
@media (max-width: 991px) {
  .navbar-link {
    color: hsla(0,0%,100%,0.78);
    font-size: 1.85rem;
    padding: 14px 16px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    gap: 10px;
    border-bottom: none;
  }

  .navbar-link::before {
    content: "";
    display: block;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: hsla(0,0%,100%,0.25);
    flex-shrink: 0;
    transition: background 0.22s, transform 0.22s;
  }

  .navbar-link::after { display: none; }

  .navbar-link:hover,
  .navbar-link.active {
    color: #fff;
    background: hsla(0,0%,100%,0.08);
  }

  .navbar-link.active::before {
    background: hsl(46,100%,65%);
    transform: scale(1.5);
  }
}

/* drawer footer */
.nav-drawer-footer {
  padding: 18px 20px 28px;
  border-top: 1px solid hsla(0,0%,100%,0.08);
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.nav-drawer-cta {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: linear-gradient(135deg, hsl(152,95%,34%), hsl(152,88%,20%));
  color: #fff;
  font-size: 1.4rem;
  font-weight: 700;
  padding: 14px 20px;
  border-radius: 50px;
  text-decoration: none;
  box-shadow: 0 6px 20px hsla(152,88%,20%,0.45);
  transition: transform 0.22s, box-shadow 0.22s;
}

.nav-drawer-cta:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 28px hsla(152,88%,20%,0.6);
}

.nav-drawer-cta ion-icon { font-size: 1.8rem; }

.nav-drawer-contact {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.nav-drawer-contact a {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: hsla(0,0%,100%,0.6);
  font-size: 1.3rem;
  text-decoration: none;
  transition: color 0.22s;
  padding: 4px 0;
}

.nav-drawer-contact a ion-icon {
  color: hsl(46,100%,65%);
  font-size: 1.6rem;
  flex-shrink: 0;
}

.nav-drawer-contact a:hover { color: hsl(46,100%,70%); }

/* -------------------------------------------------------
   9.  OVERLAY BACKDROP (mobile)
------------------------------------------------------- */


/* -------------------------------------------------------
   10.  DESKTOP NAV  (992px+)
------------------------------------------------------- */
@media (min-width: 992px) {

  .nav-open-btn { display: none; }

  .navbar {
    /* reset all mobile overrides */
    all: unset;
    display: flex;
    align-items: center;
  }

  .navbar-list {
    flex-direction: row;
    gap: 2px;
    padding: 0;
  }

  .nav-drawer-head,
  .nav-drawer-footer { display: none; }

  .navbar-link {
    color: hsl(206,21%,20%);
    font-size: 1.7rem;
    font-weight: 600;
    padding: 9px 14px;
    border-radius: 9px;
  }

  .navbar-link:hover,
  .navbar-link.active {
    color: hsl(152,88%,20%);
    background: hsl(152,95%,94%);
  }

  .nav-wrapper .container {
    padding-inline: 40px;
    padding-block: 16px;
  }
}

/* -------------------------------------------------------
   11.  RESPONSIVE ADJUSTMENTS
------------------------------------------------------- */

/* Show hamburger on mobile */
@media (max-width: 991px) {
  .nav-open-btn { display: flex; }

  .header-call-btn { display: none; }

  .nav-wrapper .container {
    padding-block: 12px;
    padding-inline: 16px;
  }

  .nav-logo-name { font-size: 2.1rem; }
  .nav-logo-sub  { font-size: 1.15rem; }
}

/* Small mobile 480–575: hide enquire text */
@media (max-width: 575px) {
  .header-enquire-btn span { display: none; }
  .header-enquire-btn { padding: 11px 14px; border-radius: 10px; }
  .nav-logo-icon { width: 38px; height: 38px; font-size: 1.9rem; border-radius: 10px; }
  .nav-logo-name { font-size: 1.9rem; }
  .input-wrapper { width: calc(100vw - 32px); right: -40px; }
}

/* Extra small < 360 */
@media (max-width: 359px) {
  .nav-logo-sub  { display: none; }
  .nav-logo-name { font-size: 1.8rem; }
  .header-enquire-btn { padding: 10px 12px; }
  .header-action-btn  { width: 36px; height: 36px; font-size: 1.7rem; }
}

/* Large desktop 1200px+ */
@media (min-width: 1200px) {
  .nav-wrapper .container { max-width: 1200px; padding-inline: 48px; }
  .navbar-link { font-size: 1.8rem; padding: 10px 18px; }
  .header-call-btn { display: inline-flex; }
}

/* ---- Top-bar email: allow break on narrow widths ---- */
.top-bar-item { overflow-wrap: break-word; word-break: break-all; }
@media (min-width: 640px) {
  .top-bar-item { word-break: normal; overflow-wrap: normal; }
}

/* ---- Search dropdown: never wider than viewport ---- */
.input-wrapper {
  max-width: calc(100vw - 24px);
}

/* ---- Enquire button: minimum tap target ---- */
.header-enquire-btn,
.header-call-btn,
.header-action-btn,
.nav-open-btn {
  min-height: 44px;
}

/* ---- 320px specifics ---- */
@media (max-width: 320px) {
  .nav-logo-name { font-size: 1.6rem; }
  .header-enquire-btn { display: none; }
  .nav-wrapper .container { gap: 10px; }
}
