/* =========================================================================
   PoshWave Header & Footer — v1.1.0
   Every color is extracted from BlackLogo.svg (or is a tint/shade of a
   logo color). The single permitted exception is #25D366 — the official
   WhatsApp brand color for the floating button.

   The header controls carry hard !important resets: WordPress themes ship
   aggressive button/input styling (grey backgrounds, borders, shadows)
   and none of it may ever bleed into the header.
   ---------------------------------------------------------------------- */

:root {
  /* --- Raw logo colors (gradient stops + wordmark ink) --- */
  --pw-color-1:  #feeb75; /* pale gold highlight   */
  --pw-color-2:  #fbe472; /* light gold            */
  --pw-color-3:  #f5d661; /* soft gold             */
  --pw-color-4:  #f0d360; /* muted gold            */
  --pw-color-5:  #efc354; /* honey gold            */
  --pw-color-6:  #ebc04c; /* amber gold            */
  --pw-color-7:  #e9b548; /* warm gold             */
  --pw-color-8:  #e7b844; /* golden yellow         */
  --pw-color-9:  #dfae3a; /* deep amber            */
  --pw-color-10: #f3ba35; /* bright gold           */
  --pw-color-11: #d09628; /* rich gold             */
  --pw-color-12: #cd9824; /* antique gold          */
  --pw-color-13: #865915; /* bronze shadow         */
  --pw-color-14: #020202; /* wordmark ink (black)  */

  /* --- Semantic aliases (derived only from the colors above) --- */
  --pw-bg:          #fffdf4;                  /* ivory — near-white tint of --pw-color-1 */
  --pw-surface:     #fdf7e0;                  /* pale gold tint of --pw-color-2          */
  --pw-primary:     var(--pw-color-14);
  --pw-accent:      var(--pw-color-12);
  --pw-accent-deep: var(--pw-color-13);
  --pw-ink-soft:    rgba(2, 2, 2, 0.72);
  --pw-ink-faint:   rgba(2, 2, 2, 0.55);
  --pw-line:        rgba(205, 152, 36, 0.35);
  --pw-glow:        rgba(243, 186, 53, 0.20);
  --pw-gold-grad:   linear-gradient(135deg, var(--pw-color-2) 0%, var(--pw-color-10) 48%, var(--pw-color-12) 100%);

  --pw-hdr-height: 76px;

  --pw-font-head: 'Cinzel', serif;
  --pw-font-body: 'Manrope', sans-serif;
}

/* Push page content down by exactly the header height. */
body.pw-header-active {
  padding-top: var(--pw-hdr-height) !important;
}

/* =========================================================================
   HEADER — bar
   ---------------------------------------------------------------------- */

.pw-hdr *,
.pw-hdr *::before,
.pw-hdr *::after {
  box-sizing: border-box;
}

.pw-hdr-bar {
  position: fixed; /* NOT sticky — renders correctly even when injected via
                      the wp_footer fallback on older themes */
  top: 0;
  left: 0;
  right: 0;
  z-index: 9999;
  height: var(--pw-hdr-height);
  background: rgba(255, 253, 244, 0.88); /* translucent --pw-bg */
  -webkit-backdrop-filter: saturate(1.4) blur(14px);
  backdrop-filter: saturate(1.4) blur(14px);
  transition: background 0.3s ease, box-shadow 0.3s ease;
}

/* Gold hairline — gradient, not a flat border. */
.pw-hdr-bar::after {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 1px;
  background: linear-gradient(
    90deg,
    transparent 0%,
    var(--pw-color-12) 18%,
    var(--pw-color-2) 50%,
    var(--pw-color-12) 82%,
    transparent 100%
  );
}

/* Soft elevation once the page scrolls. */
.pw-hdr-bar.pw-scrolled {
  background: rgba(255, 253, 244, 0.97);
  box-shadow: 0 12px 40px rgba(2, 2, 2, 0.1);
}

/* Keep clear of the WP admin bar when logged in. */
body.admin-bar .pw-hdr-bar {
  top: 32px;
}

.pw-hdr-in {
  position: relative;
  max-width: 1560px;
  height: 100%;
  margin: 0 auto;
  padding: 0 clamp(20px, 3.4vw, 56px);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

/* =========================================================================
   HEADER — logo
   ---------------------------------------------------------------------- */

.pw-hdr .pw-hdr-logo {
  display: inline-flex;
  align-items: center;
  flex: 0 0 auto;
  text-decoration: none !important;
  border: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  line-height: 1;
}

.pw-hdr .pw-hdr-logo img {
  height: 44px;
  width: auto;
  max-width: none;
  display: block;
  border: 0;
  box-shadow: none;
}

/* =========================================================================
   HEADER — centered primary navigation (desktop)
   ---------------------------------------------------------------------- */

.pw-hdr .pw-hdr-links {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  display: flex;
  align-items: center;
  gap: clamp(22px, 2.6vw, 42px);
  white-space: nowrap;
}

.pw-hdr .pw-hdr-links a {
  position: relative;
  display: inline-block;
  padding: 6px 2px !important;
  margin: 0 !important;
  background: transparent !important;
  border: 0 !important;
  box-shadow: none !important;
  font-family: var(--pw-font-body) !important;
  font-size: 0.8rem !important;
  font-weight: 600 !important;
  letter-spacing: 0.22em !important;
  text-transform: uppercase !important;
  text-decoration: none !important;
  color: var(--pw-primary) !important;
  transition: color 0.25s ease;
}

/* Gold underline that grows from the center — the luxury signature. */
.pw-hdr .pw-hdr-links a::after {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  bottom: -1px;
  height: 1.5px;
  background: var(--pw-gold-grad);
  transform: scaleX(0);
  transform-origin: center;
  transition: transform 0.32s cubic-bezier(0.22, 1, 0.36, 1);
}

.pw-hdr .pw-hdr-links a:hover {
  color: var(--pw-accent-deep) !important;
}

.pw-hdr .pw-hdr-links a:hover::after {
  transform: scaleX(1);
}

/* =========================================================================
   HEADER — icon group (hard reset: theme styles must never bleed in)
   ---------------------------------------------------------------------- */

.pw-hdr-icons {
  display: flex;
  align-items: center;
  gap: 6px;
  flex: 0 0 auto;
}

.pw-hdr .pw-hdr-icobtn,
.pw-hdr button.pw-hdr-icobtn,
.pw-hdr a.pw-hdr-icobtn {
  position: relative;
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  width: 42px !important;
  height: 42px !important;
  padding: 0 !important;
  margin: 0 !important;
  background: transparent !important;
  border: 0 !important;
  border-radius: 50% !important;
  box-shadow: none !important;
  outline: none;
  -webkit-appearance: none !important;
  appearance: none !important;
  color: var(--pw-primary) !important;
  font-size: 1.02rem !important;
  line-height: 1 !important;
  cursor: pointer;
  text-decoration: none !important;
  transition: background 0.25s ease, color 0.25s ease, transform 0.25s ease;
}

.pw-hdr .pw-hdr-icobtn:hover,
.pw-hdr button.pw-hdr-icobtn:hover,
.pw-hdr a.pw-hdr-icobtn:hover {
  background: rgba(205, 152, 36, 0.13) !important; /* gold wash */
  color: var(--pw-accent-deep) !important;
  transform: translateY(-1px);
}

.pw-hdr .pw-hdr-icobtn:focus,
.pw-hdr .pw-hdr-icobtn:active {
  background: transparent !important;
  border: 0 !important;
  box-shadow: none !important;
  color: var(--pw-primary) !important;
}

.pw-hdr .pw-hdr-icobtn:focus-visible {
  outline: 2px solid var(--pw-color-10) !important;
  outline-offset: 2px;
}

/* Cart badge */

.pw-hdr .pw-hdr-badge {
  position: absolute;
  top: 1px;
  right: -1px;
  min-width: 17px;
  height: 17px;
  padding: 0 4px;
  border-radius: 999px;
  background: var(--pw-gold-grad);
  border: 2px solid var(--pw-bg);
  color: var(--pw-color-14);
  font-family: var(--pw-font-body);
  font-size: 0.6rem;
  font-weight: 800;
  line-height: 13px;
  text-align: center;
}

.pw-hdr .pw-hdr-badge-empty {
  display: none;
}

/* Hamburger only appears when the desktop nav is hidden. */
@media (min-width: 1100px) {
  .pw-hdr .pw-hdr-nav-toggle {
    display: none !important;
  }
}

/* =========================================================================
   HEADER — slide-down panels (menu + search)
   ---------------------------------------------------------------------- */

.pw-hdr-nav,
.pw-hdr-msearch {
  position: fixed;
  top: var(--pw-hdr-height);
  left: 0;
  right: 0;
  z-index: 9998;
  background: rgba(255, 253, 244, 0.98);
  -webkit-backdrop-filter: blur(16px);
  backdrop-filter: blur(16px);
  box-shadow: 0 24px 48px rgba(2, 2, 2, 0.14);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-12px);
  transition: opacity 0.3s ease, transform 0.3s ease, visibility 0.3s;
}

.pw-hdr-nav::after,
.pw-hdr-msearch::after {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 1px;
  background: linear-gradient(
    90deg,
    transparent 0%,
    var(--pw-color-12) 18%,
    var(--pw-color-2) 50%,
    var(--pw-color-12) 82%,
    transparent 100%
  );
}

body.admin-bar .pw-hdr-nav,
body.admin-bar .pw-hdr-msearch {
  top: calc(var(--pw-hdr-height) + 32px);
}

.pw-hdr-nav.pw-open,
.pw-hdr-msearch.pw-open {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

/* Slide-down menu */

.pw-hdr-nav {
  display: flex;
  flex-direction: column;
  padding: 14px 0 18px;
}

.pw-hdr .pw-hdr-nav a {
  display: block;
  padding: 15px clamp(24px, 6vw, 56px) !important;
  margin: 0 !important;
  background: transparent !important;
  border: 0 !important;
  box-shadow: none !important;
  font-family: var(--pw-font-head) !important;
  font-size: 1rem !important;
  font-weight: 600 !important;
  letter-spacing: 0.14em !important;
  text-transform: uppercase !important;
  text-decoration: none !important;
  color: var(--pw-primary) !important;
  border-left: 3px solid transparent !important;
  transition: background 0.25s ease, border-color 0.25s ease, color 0.25s ease, padding-left 0.25s ease;
}

.pw-hdr .pw-hdr-nav a:hover {
  background: var(--pw-surface) !important;
  border-left-color: var(--pw-accent) !important;
  color: var(--pw-accent-deep) !important;
}

/* Slide-down search */

.pw-hdr-msearch {
  padding: 34px clamp(20px, 5vw, 56px) 40px;
}

.pw-hdr-msearch-in {
  max-width: 680px;
  margin: 0 auto;
}

.pw-hdr-msearch-label {
  display: block;
  font-family: var(--pw-font-body);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--pw-accent-deep);
  margin-bottom: 10px;
}

.pw-hdr .pw-hdr-search-form {
  display: flex;
  align-items: center;
  gap: 14px;
  width: 100%;
  background: transparent !important;
  border: 0 !important;
  border-bottom: 2px solid var(--pw-line) !important;
  border-radius: 0 !important;
  padding: 0 0 10px !important;
  transition: border-color 0.3s ease;
}

.pw-hdr .pw-hdr-search-form:focus-within {
  border-bottom-color: var(--pw-color-10) !important;
}

.pw-hdr .pw-hdr-search-form input[type='search'] {
  flex: 1 1 auto;
  min-width: 0;
  background: transparent !important;
  border: 0 !important;
  border-radius: 0 !important;
  box-shadow: none !important;
  outline: none !important;
  padding: 8px 0 !important;
  margin: 0 !important;
  font-family: var(--pw-font-head) !important;
  font-size: clamp(1.15rem, 2.6vw, 1.5rem) !important;
  font-weight: 500 !important;
  letter-spacing: 0.02em;
  color: var(--pw-primary) !important;
}

.pw-hdr .pw-hdr-search-form input[type='search']::placeholder {
  color: var(--pw-ink-faint);
  opacity: 1;
}

.pw-hdr .pw-hdr-search-form input[type='search']::-webkit-search-decoration,
.pw-hdr .pw-hdr-search-form input[type='search']::-webkit-search-cancel-button {
  -webkit-appearance: none;
}

.pw-hdr .pw-hdr-search-form button {
  flex: 0 0 auto;
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  width: 46px !important;
  height: 46px !important;
  padding: 0 !important;
  margin: 0 !important;
  border: 0 !important;
  border-radius: 50% !important;
  box-shadow: 0 8px 20px var(--pw-glow) !important;
  -webkit-appearance: none !important;
  appearance: none !important;
  background: var(--pw-gold-grad) !important;
  color: var(--pw-color-14) !important;
  font-size: 1rem !important;
  line-height: 1 !important;
  cursor: pointer;
  transition: transform 0.25s ease, filter 0.25s ease;
}

.pw-hdr .pw-hdr-search-form button:hover {
  transform: scale(1.06);
  filter: brightness(1.05);
}

/* =========================================================================
   FOOTER
   ---------------------------------------------------------------------- */

.pw-ftr {
  background: var(--pw-bg);
  border-top: 1px solid var(--pw-accent);
  font-family: var(--pw-font-body);
  color: var(--pw-primary);
}

.pw-ftr * {
  box-sizing: border-box;
}

.pw-ftr-in {
  max-width: 1280px;
  margin: 0 auto;
  padding: 70px 24px 50px;
}

.pw-ftr-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1.3fr;
  gap: 44px;
}

.pw-ftr-col h4 {
  position: relative;
  display: inline-block;
  font-family: var(--pw-font-head);
  font-size: 1.02rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--pw-primary);
  margin: 0 0 24px;
  padding-bottom: 10px;
}

/* Animated gold underline under each column heading. */
.pw-ftr-col h4::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: 0;
  width: 100%;
  height: 2px;
  background: var(--pw-accent);
  transform-origin: left center;
  animation: pwFtrUnderline 1.1s cubic-bezier(0.22, 1, 0.36, 1) both;
}

@keyframes pwFtrUnderline {
  from {
    transform: scaleX(0);
  }
  to {
    transform: scaleX(1);
  }
}

/* Col 1 — brand */

.pw-ftr-logo {
  width: 155px;
  height: auto;
  display: block;
  margin-bottom: 18px;
}

.pw-ftr-tag {
  font-family: var(--pw-font-head);
  font-size: 0.98rem;
  color: var(--pw-accent-deep);
  margin: 0 0 12px;
}

.pw-ftr-desc {
  font-size: 0.92rem;
  line-height: 1.75;
  color: var(--pw-ink-soft);
  margin: 0 0 22px;
  max-width: 320px;
}

.pw-ftr-social {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.pw-ftr-social a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 1px solid var(--pw-accent);
  color: var(--pw-accent-deep);
  font-size: 0.95rem;
  text-decoration: none;
  transition: background 0.25s ease, color 0.25s ease, transform 0.25s ease, box-shadow 0.25s ease;
}

.pw-ftr-social a:hover {
  background: var(--pw-gold-grad);
  color: var(--pw-color-14);
  transform: translateY(-3px);
  box-shadow: 0 10px 22px var(--pw-glow);
}

/* Cols 2 & 3 — link lists */

.pw-ftr-links {
  list-style: none;
  margin: 0;
  padding: 0;
}

.pw-ftr-links li {
  padding: 6px 0;
}

.pw-ftr-links a {
  position: relative;
  font-size: 0.94rem;
  color: var(--pw-ink-soft);
  text-decoration: none;
  padding-left: 16px;
  transition: color 0.25s ease, text-shadow 0.25s ease, padding-left 0.25s ease;
}

.pw-ftr-links a::before {
  content: '\2726';
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  font-size: 0.6rem;
  color: var(--pw-accent);
  opacity: 0.7;
  transition: opacity 0.25s ease;
}

/* Accent glow on hover. */
.pw-ftr-links a:hover {
  color: var(--pw-accent-deep);
  text-shadow: 0 0 14px rgba(205, 152, 36, 0.55);
  padding-left: 20px;
}

.pw-ftr-links a:hover::before {
  opacity: 1;
}

/* Col 4 — contact list */

.pw-ftr-contact {
  list-style: none;
  margin: 0;
  padding: 0;
}

.pw-ftr-contact li {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 8px 0;
  font-size: 0.93rem;
  line-height: 1.65;
  color: var(--pw-ink-soft);
}

.pw-ftr-contact i {
  flex: 0 0 auto;
  width: 34px;
  height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  background: var(--pw-surface);
  border: 1px solid var(--pw-line);
  color: var(--pw-accent);
  font-size: 0.9rem;
  margin-top: 1px;
}

.pw-ftr-contact a {
  color: var(--pw-ink-soft);
  text-decoration: none;
  transition: color 0.25s ease, text-shadow 0.25s ease;
}

.pw-ftr-contact a:hover {
  color: var(--pw-accent-deep);
  text-shadow: 0 0 14px rgba(205, 152, 36, 0.55);
}

/* Bottom bar — logo-ink black with pale gold text */

.pw-ftr-bottom {
  background: var(--pw-color-14);
  padding: 20px 24px;
  text-align: center;
}

.pw-ftr-bottom p {
  margin: 0;
  font-size: 0.88rem;
  letter-spacing: 0.03em;
  color: var(--pw-color-1);
}

.pw-ftr-bottom a {
  color: var(--pw-color-10);
  font-weight: 700;
  text-decoration: none;
  transition: color 0.25s ease, text-shadow 0.25s ease;
}

.pw-ftr-bottom a:hover {
  color: var(--pw-color-1);
  text-shadow: 0 0 12px rgba(243, 186, 53, 0.7);
}

/* =========================================================================
   WhatsApp floating button
   #25D366 is the official WhatsApp brand color — the only permitted
   non-logo color in this stylesheet.
   ---------------------------------------------------------------------- */

.pw-wa-btn {
  position: fixed;
  right: 22px;
  bottom: 22px;
  z-index: 9997;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 58px;
  height: 58px;
  border-radius: 50%;
  background: #25d366;
  color: #fffdf4; /* --pw-bg ivory */
  font-size: 1.7rem;
  text-decoration: none;
  box-shadow: 0 10px 26px rgba(2, 2, 2, 0.25);
  animation: pwWaPulse 2.2s ease-in-out infinite;
  transition: transform 0.25s ease;
}

.pw-wa-btn:hover {
  transform: scale(1.08);
  color: #fffdf4;
  animation-play-state: paused;
}

@keyframes pwWaPulse {
  0% {
    transform: scale(1);
    box-shadow: 0 10px 26px rgba(2, 2, 2, 0.25), 0 0 0 0 rgba(37, 211, 102, 0.45);
  }
  55% {
    transform: scale(1.05);
    box-shadow: 0 10px 26px rgba(2, 2, 2, 0.25), 0 0 0 16px rgba(37, 211, 102, 0);
  }
  100% {
    transform: scale(1);
    box-shadow: 0 10px 26px rgba(2, 2, 2, 0.25), 0 0 0 0 rgba(37, 211, 102, 0);
  }
}

/* =========================================================================
   Responsive
   ---------------------------------------------------------------------- */

@media (max-width: 1099px) {
  /* Desktop nav hides — the hamburger + slide-down menu take over. */
  .pw-hdr .pw-hdr-links {
    display: none;
  }
}

@media (max-width: 1024px) {
  .pw-ftr-grid {
    grid-template-columns: 1fr 1fr;
    gap: 38px;
  }
}

@media (max-width: 782px) {
  /* WP admin bar becomes 46px tall at this width. */
  body.admin-bar .pw-hdr-bar {
    top: 46px;
  }

  body.admin-bar .pw-hdr-nav,
  body.admin-bar .pw-hdr-msearch {
    top: calc(var(--pw-hdr-height) + 46px);
  }
}

@media (max-width: 768px) {
  :root {
    --pw-hdr-height: 64px;
  }

  .pw-hdr .pw-hdr-logo img {
    height: 36px;
  }

  .pw-hdr-msearch {
    padding: 24px 20px 30px;
  }

  .pw-ftr-in {
    padding: 54px 20px 40px;
  }
}

@media (max-width: 540px) {
  .pw-hdr-icons {
    gap: 0;
  }

  .pw-hdr .pw-hdr-icobtn,
  .pw-hdr button.pw-hdr-icobtn,
  .pw-hdr a.pw-hdr-icobtn {
    width: 38px !important;
    height: 38px !important;
    font-size: 0.95rem !important;
  }

  /* Footer stacks to a single column. */
  .pw-ftr-grid {
    grid-template-columns: 1fr;
    gap: 34px;
  }

  .pw-ftr-desc {
    max-width: 100%;
  }

  .pw-wa-btn {
    width: 52px;
    height: 52px;
    right: 16px;
    bottom: 16px;
    font-size: 1.5rem;
  }
}
