/* ===== Zero One — Bold Gradient Animated Header ===== */

:root {
  --zg-1: #7c3aed;   /* violet */
  --zg-2: #ec4899;   /* pink   */
  --zg-3: #f97316;   /* orange */
  --zg-4: #06b6d4;   /* cyan   */
  --zg-header-h: 74px;
  --zg-bar-h: 40px;
}

/* ── Animated announcement bar ── */
.zg-bar {
  position: relative;
  z-index: 1001;
  height: var(--zg-bar-h);
  display: flex;
  align-items: center;
  overflow: hidden;
  background: linear-gradient(90deg, var(--zg-1), var(--zg-2), var(--zg-3), var(--zg-4), var(--zg-1));
  background-size: 300% 100%;
  animation: zgFlow 12s linear infinite;
}

body[data-page="home"] .zg-bar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  transition: transform 0.35s ease, opacity 0.35s ease;
}

body[data-page="home"] #site-header {
  height: var(--zg-bar-h);
}

body[data-page="home"].header-pinned .zg-bar {
  transform: translateY(-100%);
  opacity: 0;
  pointer-events: none;
}

@keyframes zgFlow {
  0%   { background-position: 0% 50%; }
  100% { background-position: 300% 50%; }
}

.zg-bar-track {
  display: flex;
  white-space: nowrap;
  animation: zgMarquee 22s linear infinite;
}

.zg-bar-track span {
  padding: 0 2.5rem;
  font-size: 12.5px;
  font-weight: 600;
  letter-spacing: 0.03em;
  color: #fff;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
}

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

/* ── Header shell ── */
.zg-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  transition: top 0.35s ease, background 0.4s ease, box-shadow 0.4s ease;
}

body[data-page="home"] .zg-header {
  position: fixed;
  top: var(--zg-bar-h);
  left: 0;
  right: 0;
}

body[data-page="home"].header-pinned .zg-header {
  top: 0;
}

body[data-page="home"] .zg-header:not(.scrolled) {
  background: transparent;
  box-shadow: none;
}

/* Glass on scroll (and always on inner pages) */
.zg-header.scrolled,
body:not([data-page="home"]) .zg-header {
  background: rgba(11, 8, 20, 0.88);
  backdrop-filter: blur(18px) saturate(160%);
  -webkit-backdrop-filter: blur(18px) saturate(160%);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.06),
              0 12px 40px -18px rgba(124, 58, 237, 0.5);
}

body[data-page="home"] .zg-header.scrolled {
  background: rgba(11, 8, 20, 0.88);
  backdrop-filter: blur(18px) saturate(160%);
  -webkit-backdrop-filter: blur(18px) saturate(160%);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.06),
              0 12px 40px -18px rgba(124, 58, 237, 0.5);
}

/* Gradient hairline under header */
.zg-header::after {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--zg-1), var(--zg-2), var(--zg-3), var(--zg-4), transparent);
  background-size: 200% 100%;
  opacity: 0;
  transition: opacity 0.4s;
  animation: zgFlow 8s linear infinite;
}

.zg-header.scrolled::after,
body:not([data-page="home"]) .zg-header::after,
body[data-page="home"] .zg-header.scrolled::after { opacity: 0.9; }

.zg-inner {
  max-width: 1320px;
  margin: 0 auto;
  padding: 0 clamp(18px, 4vw, 40px);
  height: var(--zg-header-h);
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 20px;
}

/* ── Logo (SVG wordmark) ── */
.zg-logo {
  justify-self: start;
  display: flex;
  align-items: center;
  line-height: 0;
  transition: opacity 0.25s ease, transform 0.25s ease;
}

.zg-logo:hover {
  opacity: 0.92;
  transform: translateY(-1px);
}

.zg-logo-full-img {
  display: block;
  width: auto;
  height: 34px;
  max-width: min(168px, 42vw);
}

.zg-logo--icon .zg-logo-mark-img,
.zg-logo-mark-img {
  display: block;
  width: 38px;
  height: 38px;
  border-radius: 11px;
  box-shadow: 0 6px 20px -6px rgba(236, 72, 153, 0.55);
  transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.zg-logo--icon:hover .zg-logo-mark-img,
.zg-logo:hover .zg-logo-mark-img {
  transform: rotate(-6deg) scale(1.06);
}

/* Legacy text logo fallback (if JS disabled) */
.zg-logo-mark {
  width: 38px;
  height: 38px;
  border-radius: 11px;
  display: grid;
  place-items: center;
  font-weight: 900;
  font-size: 19px;
  color: #fff;
  background: linear-gradient(135deg, var(--zg-1), var(--zg-2), var(--zg-3));
  background-size: 200% 200%;
  animation: zgLogoShift 6s ease infinite;
  box-shadow: 0 6px 20px -6px rgba(236, 72, 153, 0.7);
  transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.zg-logo:hover .zg-logo-mark {
  transform: rotate(-8deg) scale(1.08);
}

@keyframes zgLogoShift {
  0%, 100% { background-position: 0% 50%; }
  50%      { background-position: 100% 50%; }
}

.zg-logo-text {
  font-size: 20px;
  font-weight: 800;
  letter-spacing: -0.01em;
  line-height: 1;
  color: #fff;
  white-space: nowrap;
}

.zg-logo-text b {
  background: linear-gradient(90deg, var(--zg-2), var(--zg-3), var(--zg-4));
  background-size: 200% 100%;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: zgFlow 6s linear infinite;
  font-weight: 800;
}

/* Footer logo on dark bg */
.footer-zero-brand .zg-logo-text { color: #fff; }

/* ── Center nav ── */
.zg-nav {
  justify-self: center;
  display: flex;
  align-items: center;
  gap: 2px;
  padding: 5px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(8px);
}

.zg-nav a {
  position: relative;
  font-size: 13px;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.7);
  padding: 8px 16px;
  border-radius: 999px;
  transition: color 0.25s;
  white-space: nowrap;
}

.zg-nav a::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--zg-1), var(--zg-2), var(--zg-3));
  opacity: 0;
  transform: scale(0.8);
  transition: opacity 0.25s, transform 0.25s;
  z-index: -1;
}

.zg-nav a:hover { color: #fff; }
.zg-nav a:hover::before { opacity: 0.9; transform: scale(1); }

.zg-nav a.active {
  color: #fff;
}
.zg-nav a.active::before { opacity: 1; transform: scale(1); }

/* ── Right actions ── */
.zg-actions {
  justify-self: end;
  display: flex;
  align-items: center;
  gap: 8px;
}

.zg-icon-btn {
  position: relative;
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  color: #fff;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  cursor: pointer;
  transition: all 0.3s;
}

.zg-icon-btn:hover {
  background: linear-gradient(135deg, var(--zg-1), var(--zg-2));
  border-color: transparent;
  transform: translateY(-2px);
  box-shadow: 0 8px 20px -8px rgba(236, 72, 153, 0.8);
}

.zg-icon-btn svg { width: 19px; height: 19px; }

.zg-cta {
  height: 42px;
  padding: 0 20px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 700;
  color: #fff;
  background: linear-gradient(135deg, var(--zg-1), var(--zg-2), var(--zg-3));
  background-size: 200% 200%;
  animation: zgLogoShift 6s ease infinite;
  box-shadow: 0 8px 22px -8px rgba(236, 72, 153, 0.7);
  transition: transform 0.3s;
}

.zg-cta:hover { transform: translateY(-2px) scale(1.03); }

.zg-cart-badge {
  position: absolute;
  top: -4px;
  right: -4px;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 999px;
  font-size: 10px;
  font-weight: 800;
  color: #fff;
  background: linear-gradient(135deg, var(--zg-3), var(--zg-2));
  display: grid;
  place-items: center;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

.zg-menu-btn { display: none; }

/* ── Mobile ── */
@media (max-width: 1100px) {
  .zg-nav a { padding: 8px 12px; font-size: 12px; }
}

@media (max-width: 940px) {
  .zg-nav { display: none; }
  .zg-inner { grid-template-columns: auto 1fr auto; }
  .zg-logo { justify-self: start; }
  .zg-actions { justify-self: end; }
  .zg-menu-btn {
    display: grid;
    place-items: center;
    width: 42px;
    height: 42px;
    border-radius: 12px;
    color: #fff;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.1);
    cursor: pointer;
  }
  .zg-cta span { display: none; }
  .zg-cta { padding: 0 14px; }
}

@media (max-width: 560px) {
  .zg-logo-text { font-size: 17px; }
  .zg-actions { gap: 6px; }
}

/* ── Footer layout (works with .footer-zero base) ── */
.footer-zero-inner {
  max-width: 1320px;
  margin: 0 auto;
  padding: 0 clamp(20px, 4vw, 40px);
  display: grid;
  grid-template-columns: 1.4fr 2fr;
  gap: 48px;
  margin-bottom: 40px;
}

.footer-zero-brand .zg-logo { margin-bottom: 16px; }
.footer-zero-brand .zg-logo-full-img { height: 36px; }
.footer-zero-brand p {
  font-size: 13px;
  line-height: 1.7;
  max-width: 320px;
  color: rgba(255, 255, 255, 0.55);
}

.footer-zero-cols {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.footer-zero-col h4 {
  color: #fff;
  font-size: 13px;
  font-weight: 700;
  margin-bottom: 14px;
}

.footer-zero-col a {
  display: block;
  font-size: 12.5px;
  color: rgba(255, 255, 255, 0.5);
  padding: 4px 0;
  transition: color 0.25s;
}
.footer-zero-col a:hover { color: #fff; }

.footer-zero-bottom {
  max-width: 1320px;
  margin: 0 auto;
  padding: 20px clamp(20px, 4vw, 40px) 0;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 12px;
}

@media (max-width: 780px) {
  .footer-zero-inner { grid-template-columns: 1fr; gap: 32px; }
  .footer-zero-cols { grid-template-columns: repeat(2, 1fr); }
  .footer-zero-bottom { flex-direction: column; gap: 8px; text-align: center; }
}

/* ── Fullscreen search modal ── */
.search-modal {
  position: fixed;
  inset: 0;
  z-index: 2000;
  background: rgba(8, 6, 15, 0.9);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding-top: 15vh;
  opacity: 0;
  visibility: hidden;
  transition: all 0.4s cubic-bezier(0.22, 1, 0.36, 1);
}

.search-modal.active { opacity: 1; visibility: visible; }

.search-modal-box {
  width: min(600px, 90vw);
  transform: translateY(20px);
  transition: transform 0.4s cubic-bezier(0.22, 1, 0.36, 1);
}
.search-modal.active .search-modal-box { transform: translateY(0); }

.search-modal-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
}

.search-modal-mark {
  flex-shrink: 0;
  border-radius: 10px;
  box-shadow: 0 6px 18px -6px rgba(236, 72, 153, 0.55);
}

.search-modal-label {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  background: linear-gradient(90deg, var(--zg-2), var(--zg-3));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  margin-bottom: 0;
}

.search-modal-input-wrap {
  display: flex;
  align-items: center;
  border-bottom: 2px solid rgba(255, 255, 255, 0.15);
  padding-bottom: 14px;
}

.search-modal-input {
  flex: 1;
  background: none;
  border: none;
  font-size: clamp(1.3rem, 3vw, 1.9rem);
  font-weight: 300;
  color: #fff;
}
.search-modal-input:focus { outline: none; }
.search-modal-input::placeholder { color: rgba(255, 255, 255, 0.25); }

.search-modal-close {
  margin-left: 16px;
  padding: 8px 16px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: rgba(255, 255, 255, 0.55);
  font-size: 13px;
  background: none;
  cursor: pointer;
  transition: all 0.3s;
}
.search-modal-close:hover { color: #fff; border-color: rgba(255, 255, 255, 0.4); }

.search-modal .search-dropdown {
  position: static;
  margin-top: 18px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 16px;
  max-height: 340px;
  overflow-y: auto;
}

.search-modal .search-result-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 16px;
  color: #fff;
  transition: background 0.2s;
}
.search-modal .search-result-item:hover { background: rgba(255, 255, 255, 0.06); }
.search-modal .search-result-item img { width: 46px; height: 46px; object-fit: contain; border-radius: 8px; background: rgba(255,255,255,.06); }
.search-modal .search-result-info { flex: 1; }
.search-modal .search-result-info h4 { color: #fff; font-size: 14px; font-weight: 600; }
.search-modal .search-result-item .price {
  font-weight: 700;
  background: linear-gradient(90deg, var(--zg-2), var(--zg-3));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* ── Mobile menu drawer ── */
.menu-drawer-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
  z-index: 1998;
  opacity: 0;
  visibility: hidden;
  transition: all 0.4s;
  backdrop-filter: blur(4px);
}
.menu-drawer-overlay.active { opacity: 1; visibility: visible; }

.menu-drawer {
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  width: min(340px, 86vw);
  background: #0b0814;
  z-index: 1999;
  transform: translateX(-100%);
  transition: transform 0.45s cubic-bezier(0.22, 1, 0.36, 1);
  display: flex;
  flex-direction: column;
  border-right: 1px solid rgba(255, 255, 255, 0.06);
}
.menu-drawer.active { transform: translateX(0); }

.menu-drawer-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 22px 24px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.07);
}

.menu-drawer-title {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.4);
}

.menu-drawer-close {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: rgba(255, 255, 255, 0.6);
  font-size: 18px;
  background: none;
  cursor: pointer;
}

.menu-drawer-nav { flex: 1; padding: 14px 16px; overflow-y: auto; }
.menu-drawer-nav a {
  display: block;
  padding: 13px 14px;
  font-size: 15px;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.78);
  border-radius: 12px;
  transition: all 0.25s;
}
.menu-drawer-nav a:hover {
  color: #fff;
  background: linear-gradient(135deg, rgba(124,58,237,.35), rgba(236,72,153,.35));
  padding-left: 20px;
}

.menu-drawer-nav a.active {
  color: #fff;
  background: linear-gradient(135deg, var(--zg-1), var(--zg-2));
  font-weight: 600;
}
.menu-drawer-nav .menu-divider {
  height: 1px;
  background: rgba(255, 255, 255, 0.07);
  margin: 12px 0;
}
