/* ============================================
   HEADER + FOOTER CSS (LIGHT)
   ============================================ */

/* ── Announcement Bar ── */
.announcement-bar {
  position: relative; background: var(--color-accent-warm); color: #fff;
  overflow: hidden; height: 36px; display: flex; align-items: center;
}
.announcement-bar__inner { flex: 1; overflow: hidden; mask-image: linear-gradient(to right, transparent, black 5%, black 95%, transparent); }
.announcement-bar__track { display: flex; width: max-content; animation: bar-scroll 30s linear infinite; }
.announcement-bar__item {
  display: flex; align-items: center; gap: 1.5rem; padding: 0 3rem;
  font-size: 0.7rem; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase; white-space: nowrap;
}
.announcement-bar__dot { width: 4px; height: 4px; border-radius: 50%; background: rgba(255,255,255,0.5); flex-shrink: 0; }
.announcement-bar__close { position: absolute; right: 1rem; top: 50%; transform: translateY(-50%); opacity: 0.7; transition: opacity 0.2s; z-index: 2; color: #fff; }
.announcement-bar__close:hover { opacity: 1; }
@keyframes bar-scroll { from { transform: translateX(0); } to { transform: translateX(-50%); } }

/* ── Header Shell ── */
.header {
  position: sticky; top: 0; z-index: 800;
  background: rgba(250,250,248,0.92);
  backdrop-filter: blur(20px) saturate(120%);
  border-bottom: 1px solid var(--color-border);
  transition: background var(--dur-normal), box-shadow var(--dur-normal);
}
.header.is-scrolled { background: rgba(250,250,248,0.98); box-shadow: 0 2px 24px rgba(20,18,14,0.07); }

.header__inner {
  display: grid; grid-template-columns: 1fr auto 1fr;
  align-items: center;
  max-width: var(--max-width); margin: 0 auto; padding: 0 var(--gutter);
  height: 72px; gap: 2rem;
}

/* ── Logo ── */
.header__logo { justify-self: center; }
.header__logo-text { font-family: var(--font-display); font-size: 1.45rem; font-weight: 700; letter-spacing: 0.28em; color: var(--color-text); text-transform: uppercase; }

/* ── Nav ── */
.header__nav { justify-self: start; align-self: stretch; display: flex; align-items: center; }
.header__nav-list { display: flex; align-items: center; height: 100%; gap: 0.25rem; }
.header__nav-item { display: flex; align-items: center; height: 100%; }
.header__nav-link {
  display: flex; align-items: center; gap: 0.3rem;
  padding: 0.5rem 0.85rem;
  font-size: 0.78rem; font-weight: 500; letter-spacing: 0.07em; text-transform: uppercase;
  color: var(--color-text-muted);
  border-radius: var(--radius-full);
  transition: color var(--dur-fast), background var(--dur-fast);
}
.header__nav-link:hover,
.header__nav-item.is-active > .header__nav-link { color: var(--color-text); background: rgba(20,18,14,0.05); }

.nav-chevron { transition: transform var(--dur-fast); opacity: 0.4; }
.header__nav-item.has-mega:hover .nav-chevron { transform: rotate(180deg); }

/* ── Actions ── */
.header__actions { display: flex; align-items: center; gap: 0.25rem; justify-self: end; }
.header__action-btn {
  display: flex; align-items: center; justify-content: center;
  width: 2.6rem; height: 2.6rem; border-radius: 50%;
  color: var(--color-text-muted);
  transition: color var(--dur-fast), background var(--dur-fast);
}
.header__action-btn:hover { color: var(--color-text); background: rgba(20,18,14,0.06); }

.header__cart-btn {
  position: relative; display: flex; align-items: center; justify-content: center;
  width: 2.6rem; height: 2.6rem; border-radius: 50%;
  color: var(--color-text-muted);
  transition: color var(--dur-fast), background var(--dur-fast);
}
.header__cart-btn:hover { color: var(--color-text); background: rgba(20,18,14,0.06); }
.header__cart-count {
  position: absolute; top: 3px; right: 3px;
  width: 16px; height: 16px; border-radius: 50%;
  background: var(--color-accent-warm); color: #fff;
  font-size: 0.6rem; font-weight: 700;
  display: flex; align-items: center; justify-content: center; line-height: 1;
}
.header__cart-count:empty { display: none; }
.header__cart-btn.bump .header__cart-count { animation: bump 0.3s var(--ease-out); }
@keyframes bump { 0% { transform: scale(1); } 50% { transform: scale(1.5); } 100% { transform: scale(1); } }

/* ── Mega Menu ── */
.mega-menu {
  position: absolute; top: 100%; left: 0; right: 0;
  background: rgba(250,250,248,0.98);
  backdrop-filter: blur(20px);
  border-top: 1px solid var(--color-border);
  border-bottom: 1px solid var(--color-border);
  box-shadow: 0 8px 40px rgba(20,18,14,0.08);
  opacity: 0; pointer-events: none;
  transform: translateY(-6px);
  transition: opacity var(--dur-normal) var(--ease-out), transform var(--dur-normal) var(--ease-out);
  z-index: 100;
}
.header__nav-item.has-mega:hover .mega-menu { opacity: 1; pointer-events: all; transform: translateY(0); }
.mega-menu__inner { display: grid; grid-template-columns: repeat(2, 200px) 1fr; gap: 3rem; padding: 2.5rem 0; }
.mega-menu__label { font-size: 0.65rem; font-weight: 700; letter-spacing: 0.2em; text-transform: uppercase; color: var(--color-text-muted); margin-bottom: 1rem; }
.mega-menu__links { display: flex; flex-direction: column; gap: 0.5rem; }
.mega-menu__links a { font-size: 0.9rem; color: var(--color-text-muted); transition: color var(--dur-fast); padding: 0.2rem 0; }
.mega-menu__links a:hover { color: var(--color-text); }
.mega-menu__col--feature { border-left: 1px solid var(--color-border); padding-left: 3rem; }
.mega-menu__feature { display: grid; grid-template-columns: 80px 1fr; gap: 1rem; align-items: center; }
.mega-menu__feature-img { width: 80px; height: 100px; border-radius: var(--radius-md); flex-shrink: 0; }
.mega-menu__feature-title { font-size: 0.9rem; color: var(--color-text); margin-top: 0.3rem; }

/* ── Search Overlay ── */
.search-overlay {
  position: fixed; top: 0; left: 0; right: 0;
  background: rgba(250,250,248,0.98); backdrop-filter: blur(20px);
  z-index: 850; padding: 2rem 0;
  border-bottom: 1px solid var(--color-border);
  box-shadow: 0 8px 40px rgba(20,18,14,0.08);
  opacity: 0; pointer-events: none;
  transform: translateY(-100%);
  transition: all var(--dur-normal) var(--ease-out);
}
.search-overlay.is-open { opacity: 1; pointer-events: all; transform: translateY(0); }
.search-overlay__field {
  display: flex; align-items: center; gap: 1rem;
  padding-bottom: 1.5rem; border-bottom: 1px solid var(--color-border); margin-bottom: 1.5rem;
  color: var(--color-text-muted);
}
.search-overlay__input {
  flex: 1; background: none; border: none; outline: none;
  font-family: var(--font-display); font-size: clamp(1.5rem, 3vw, 2.5rem);
  color: var(--color-text); letter-spacing: -0.02em;
}
.search-overlay__input::placeholder { color: var(--color-text-subtle); }
.search-overlay__close { color: var(--color-text-muted); transition: color var(--dur-fast); }
.search-overlay__close:hover { color: var(--color-text); }
.search-overlay__tags { display: flex; flex-wrap: wrap; gap: 0.5rem; }

/* ── Mobile Menu ── */
.header__hamburger { display: none; flex-direction: column; justify-content: center; gap: 5px; width: 2.6rem; height: 2.6rem; padding: 0.5rem; }
.header__hamburger span { display: block; height: 1.5px; background: var(--color-text); border-radius: 2px; transition: all var(--dur-normal) var(--ease-out); transform-origin: center; }
.header__hamburger.is-open span:nth-child(1) { transform: translateY(6.5px) rotate(45deg); }
.header__hamburger.is-open span:nth-child(2) { opacity: 0; transform: scaleX(0); }
.header__hamburger.is-open span:nth-child(3) { transform: translateY(-6.5px) rotate(-45deg); }

.mobile-menu {
  position: fixed; top: 0; left: 0; bottom: 0;
  width: min(340px, 85vw);
  background: var(--color-bg);
  border-right: 1px solid var(--color-border);
  z-index: 900; display: flex; flex-direction: column;
  transform: translateX(-100%);
  transition: transform var(--dur-slow) var(--ease-out);
  box-shadow: 4px 0 40px rgba(20,18,14,0.08);
}
.mobile-menu.is-open { transform: translateX(0); }
.mobile-menu__header { display: flex; align-items: center; justify-content: space-between; padding: 1.5rem 2rem; border-bottom: 1px solid var(--color-border); }
.mobile-menu__nav { flex: 1; padding: 1.5rem 2rem; }
.mobile-menu__link { display: block; padding: 1rem 0; font-family: var(--font-display); font-size: 1.4rem; font-weight: 600; color: var(--color-text-muted); border-bottom: 1px solid var(--color-border); transition: color var(--dur-fast); }
.mobile-menu__link:hover { color: var(--color-text); }
.mobile-menu__footer { padding: 2rem; border-top: 1px solid var(--color-border); }
.mobile-menu__socials { display: flex; gap: 1.5rem; margin-top: 0.75rem; }
.mobile-menu__socials a { font-size: 0.8rem; color: var(--color-text-muted); transition: color var(--dur-fast); }
.mobile-menu__socials a:hover { color: var(--color-text); }

.mobile-overlay { position: fixed; inset: 0; background: rgba(20,18,14,0.25); backdrop-filter: blur(4px); z-index: 850; opacity: 0; pointer-events: none; transition: opacity var(--dur-normal); }
.mobile-overlay.is-open { opacity: 1; pointer-events: all; }

/* ── FOOTER ── */
.footer__newsletter { border-top: 1px solid var(--color-border); padding: var(--space-lg) 0; }
.footer__newsletter-inner { display: grid; grid-template-columns: 1fr 1fr; gap: 4rem; align-items: center; }
.footer__newsletter-field { display: flex; gap: 0.75rem; margin-bottom: 0.75rem; }
.footer__newsletter-field .input { flex: 1; }
.footer__newsletter-legal { font-size: 0.72rem; color: var(--color-text-subtle); }
.footer__newsletter-legal a { text-decoration: underline; text-underline-offset: 2px; }

.footer__main { padding: var(--space-lg) 0; border-top: 1px solid var(--color-border); }
.footer__grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 3rem; }

.footer__logo { display: block; font-family: var(--font-display); font-size: 1.3rem; font-weight: 700; letter-spacing: 0.28em; text-transform: uppercase; margin-bottom: 1rem; color: var(--color-text); }
.footer__brand-desc { font-size: 0.875rem; color: var(--color-text-muted); line-height: 1.7; margin-bottom: 1.5rem; }

.footer__socials { display: flex; gap: 0.75rem; }
.footer__social { display: flex; align-items: center; justify-content: center; width: 2.2rem; height: 2.2rem; border-radius: 50%; border: 1.5px solid var(--color-border); color: var(--color-text-muted); transition: all var(--dur-fast); }
.footer__social:hover { border-color: rgba(20,18,14,0.3); color: var(--color-text); background: rgba(20,18,14,0.05); }

.footer__nav-title { font-size: 0.65rem; font-weight: 700; letter-spacing: 0.2em; text-transform: uppercase; color: var(--color-text-muted); margin-bottom: 1.25rem; }
.footer__nav-list { display: flex; flex-direction: column; gap: 0.6rem; }
.footer__nav-list a { font-size: 0.875rem; color: var(--color-text-muted); transition: color var(--dur-fast); }
.footer__nav-list a:hover { color: var(--color-text); }

.footer__bottom { border-top: 1px solid var(--color-border); padding: 1.5rem 0; }
.footer__bottom-inner { display: flex; align-items: center; justify-content: space-between; gap: 2rem; flex-wrap: wrap; }
.footer__copy { font-size: 0.8rem; color: var(--color-text-muted); }
.footer__legal { display: flex; gap: 1.5rem; }
.footer__legal a { font-size: 0.8rem; color: var(--color-text-muted); transition: color var(--dur-fast); }
.footer__legal a:hover { color: var(--color-text); }
.footer__payments { display: flex; gap: 0.5rem; }
.payment-icon { display: inline-flex; align-items: center; justify-content: center; padding: 0.3rem 0.6rem; border: 1.5px solid var(--color-border); border-radius: var(--radius-sm); font-size: 0.6rem; font-weight: 700; letter-spacing: 0.05em; color: var(--color-text-muted); }

/* ── Responsive ── */
@media (max-width: 900px) {
  .header__nav { display: none; }
  .header__hamburger { display: flex; }
  .header__inner { grid-template-columns: auto 1fr auto; }
  .header__logo { justify-self: start; }
  .footer__newsletter-inner { grid-template-columns: 1fr; gap: 2rem; }
  .footer__grid { grid-template-columns: 1fr 1fr; gap: 2rem; }
}
@media (max-width: 600px) {
  .footer__grid { grid-template-columns: 1fr; }
  .footer__newsletter-field { flex-direction: column; }
  .footer__bottom-inner { flex-direction: column; align-items: flex-start; }
}
