/* ============================================================
   The Store NZ — layout.css
   Navigation, footer, page scaffolding, home page sections.
   ============================================================ */

/* ---------- top navigation ---------- */

.site-nav {
  position: sticky; top: 0; z-index: 200;
  background: rgba(251, 251, 253, .78);
  backdrop-filter: saturate(1.8) blur(20px); -webkit-backdrop-filter: saturate(1.8) blur(20px);
  border-bottom: 1px solid rgba(0,0,0,.06);
}
.nav-inner {
  max-width: var(--content-wide); margin: 0 auto; height: var(--nav-h);
  display: flex; align-items: center; gap: clamp(8px, 2vw, 26px);
  padding: 0 clamp(14px, 3vw, 30px);
}
.brand { display: flex; align-items: center; gap: 10px; color: var(--ink); }
.brand:hover { text-decoration: none; opacity: .8; }
.brand-mark { width: 26px; height: 26px; border-radius: 8px; box-shadow: 0 2px 8px rgba(0,100,225,.35); }
.brand-word { font-weight: 700; font-size: 1.12rem; letter-spacing: -.02em; }
.nav-links { display: flex; gap: clamp(6px, 1.6vw, 22px); margin: 0 auto; }
.nav-links a {
  color: rgba(29,29,31,.82); font-size: .88rem; padding: 6px 10px; border-radius: 999px;
  transition: color .15s, background .15s; white-space: nowrap;
}
.nav-links a:hover { color: var(--ink); text-decoration: none; background: rgba(0,0,0,.05); }
.nav-links a[aria-current="page"] { color: var(--ink); background: rgba(0,0,0,.06); }
.nav-actions { display: flex; align-items: center; gap: 6px; margin-left: auto; }
.nav-location {
  display: inline-flex; align-items: center; gap: 6px; border: 0; background: transparent;
  cursor: pointer; padding: 6px 10px; border-radius: 999px; color: var(--muted);
  font-size: .82rem; transition: background .15s, color .15s; white-space: nowrap;
}
.nav-location:hover { background: rgba(0,0,0,.05); color: var(--ink); }
.nav-location svg { width: 15px; height: 15px; }
.nav-bag { position: relative; color: var(--ink); display: flex; align-items: center; padding: 6px 10px; border-radius: 50%; transition: background .15s; }
.nav-bag:hover { background: rgba(0,0,0,.05); text-decoration: none; }
.nav-bag > svg { width: 19px; height: 19px; }
.bag-count {
  position: absolute; top: 0; right: 0; min-width: 17px; height: 17px; padding: 0 4px;
  background: var(--accent); color: #fff; font-size: .68rem; font-weight: 700;
  border-radius: 999px; display: flex; align-items: center; justify-content: center;
  box-shadow: 0 0 0 2px rgba(251,251,253,.9); animation: bag-pop .35s var(--ease-spring);
}
@keyframes bag-pop { 40% { transform: scale(1.35); } }
.nav-bag-label, .nav-menu-btn { display: none; }

/* ---------- mobile menu ---------- */

.mobile-menu { position: fixed; inset: var(--nav-h) 0 auto 0; z-index: 199; background: rgba(251,251,253,.98); backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px); border-bottom: 1px solid rgba(0,0,0,.06); padding: 12px 20px 26px; animation: fade-in .2s ease; }
.mobile-menu nav { display: flex; flex-direction: column; }
.mobile-menu a {
  display: flex; justify-content: space-between; align-items: center;
  color: var(--ink); font-size: 1.35rem; font-weight: 600; letter-spacing: -.02em;
  padding: 12px 4px; border-bottom: 1px solid rgba(0,0,0,.05);
}
.mobile-menu a:hover { text-decoration: none; color: var(--accent); }
.mm-arrow { color: var(--faint); font-weight: 400; }

/* ---------- main scaffolding ---------- */

.app-main { min-height: 62vh; outline: none; }
.container { max-width: var(--content); margin: 0 auto; padding: 0 clamp(16px, 3.4vw, 40px); }
.container-wide { max-width: var(--content-wide); margin: 0 auto; padding: 0 clamp(16px, 3.4vw, 40px); }
.section { padding: clamp(2.6rem, 5vw, 4.2rem) 0; }
.section-tight { padding: clamp(1.6rem, 3vw, 2.4rem) 0; }
.section-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 1rem; margin-bottom: 1.4rem; }
.section-head h2 { font-size: clamp(1.4rem, 2.4vw, 1.9rem); letter-spacing: -.02em; }
.section-head .see-all { white-space: nowrap; font-size: .95rem; }
.page-title-block { padding: clamp(2rem, 4vw, 3rem) 0 1.2rem; }
.breadcrumb { font-size: .84rem; color: var(--faint); margin-bottom: .5rem; display: flex; flex-wrap: wrap; gap: .35em; }
.breadcrumb a { color: var(--muted); }
.breadcrumb a:hover { color: var(--accent); }

/* ---------- home hero ---------- */

.hero {
  position: relative; overflow: hidden;
  background: linear-gradient(180deg, #fbfbfd 0%, #f5f5f7 100%);
  padding: clamp(3rem, 7vw, 5.5rem) 0 clamp(2.5rem, 6vw, 5rem);
  text-align: center;
}
.hero h1 { margin: .4em 0 .3em; }
.hero .subhead { max-width: 620px; margin: 0 auto 1.6rem; }
.hero-cta { display: flex; gap: .9rem; justify-content: center; flex-wrap: wrap; }
.hero-stage { position: relative; max-width: 760px; margin: clamp(2rem, 4vw, 3.4rem) auto 0; }
.hero-stage .stage-glow { position: absolute; inset: -8% -14%; background: radial-gradient(52% 60% at 50% 55%, rgba(25,140,255,.16), transparent 70%); filter: blur(6px); }
.hero-device { position: relative; z-index: 1; filter: drop-shadow(0 34px 46px rgba(20,30,60,.22)); animation: hero-float 7s ease-in-out infinite; }
@keyframes hero-float { 50% { transform: translateY(-12px); } }
.hero-loc { margin-top: 1.4rem; }

/* ---------- category tiles ---------- */

.cat-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 16px; }
.cat-tile {
  display: flex; flex-direction: column; align-items: center; justify-content: space-between; gap: 10px;
  background: var(--surface); border-radius: var(--r-lg); padding: 26px 18px 20px;
  color: var(--ink); box-shadow: var(--shadow-1); position: relative; overflow: hidden;
  transition: transform .3s var(--ease-out), box-shadow .3s var(--ease-out);
}
.cat-tile:hover { transform: translateY(-5px); box-shadow: var(--shadow-2); text-decoration: none; }
.cat-tile .ct-art { height: 120px; display: flex; align-items: center; justify-content: center; width: 100%; }
.cat-tile .ct-name { font-weight: 600; font-size: 1.06rem; }
.cat-tile .ct-sub { font-size: .84rem; color: var(--muted); margin-top: -4px; }
.cat-tile .ct-cta { font-size: .88rem; color: var(--accent); display: inline-flex; align-items: center; gap: .3em; }

/* ---------- product cards & shelves ---------- */

.shelf-wrap { position: relative; }
.shelf {
  display: grid; grid-auto-flow: column; grid-auto-columns: min(78vw, 340px);
  gap: 16px; overflow-x: auto; scroll-snap-type: x mandatory;
  padding: 6px 6px 22px; margin: 0 -6px;
  scrollbar-width: thin; scrollbar-color: #c7c7cc transparent;
}
.shelf > * { scroll-snap-align: start; }
.shelf::-webkit-scrollbar { height: 8px; }
.shelf::-webkit-scrollbar-thumb { background: #c7c7cc; border-radius: 4px; }
.shelf::-webkit-scrollbar-track { background: transparent; }
.shelf-nav { display: flex; gap: 8px; }
.shelf-nav button {
  width: 34px; height: 34px; border-radius: 50%; border: 0; background: var(--surface);
  box-shadow: var(--shadow-1); cursor: pointer; color: var(--ink-2);
  display: flex; align-items: center; justify-content: center; transition: background .15s, transform .15s;
}
.shelf-nav button:hover { background: #fff; transform: scale(1.06); }
.shelf-nav button:disabled { opacity: .35; cursor: default; transform: none; }

.prod-card {
  display: flex; flex-direction: column; align-items: center; text-align: center;
  background: var(--surface); border-radius: var(--r-lg); padding: 28px 22px 22px;
  box-shadow: var(--shadow-1); height: 100%;
  transition: transform .3s var(--ease-out), box-shadow .3s var(--ease-out);
}
a.prod-card { color: var(--ink); }
a.prod-card:hover { text-decoration: none; transform: translateY(-5px); box-shadow: var(--shadow-2); }
.prod-card .pc-art { width: 100%; height: 190px; display: flex; align-items: center; justify-content: center; margin-bottom: 14px; position: relative; }
.prod-card .pc-badge { position: absolute; top: 0; left: 50%; transform: translateX(-50%); }
.prod-card .pc-name { font-weight: 600; font-size: 1.04rem; }
.prod-card .pc-tag { color: var(--muted); font-size: .88rem; margin: 3px 0 10px; min-height: 2.4em; line-height: 1.32; }
.prod-card .pc-price { font-size: .95rem; color: var(--ink-2); }
.prod-card .pc-monthly { font-size: .8rem; color: var(--faint); margin-top: 2px; }
.pc-swatches { display: flex; gap: 6px; margin-top: 10px; justify-content: center; }
.pc-swatches .sw { width: 12px; height: 12px; border-radius: 50%; box-shadow: inset 0 0 0 1px rgba(0,0,0,.12); }

.grid-3 { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 18px; }

/* ---------- banner strips ---------- */

.banner {
  border-radius: var(--r-xl); padding: clamp(1.8rem, 4vw, 3rem);
  display: grid; grid-template-columns: 1.2fr .8fr; gap: 2rem; align-items: center;
  overflow: hidden; position: relative;
}
.banner-dark { background: linear-gradient(135deg, #1d1d1f, #2c2c31 60%, #3a3a41); color: #f5f5f7; }
.banner-dark .subhead { color: #a1a1a6; }
.banner-art { display: flex; align-items: center; justify-content: center; }
.banner .eyebrow { color: #8f8f96; }

/* ---------- footer ---------- */

.site-footer { background: var(--surface-2); border-top: 1px solid var(--line-soft); margin-top: clamp(2rem, 5vw, 4rem); }
.footer-inner { max-width: var(--content-wide); margin: 0 auto; padding: clamp(2rem, 4vw, 3rem) clamp(16px, 3.4vw, 40px) 2.4rem; }
.footer-cols { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 1.6rem; padding-bottom: 1.8rem; }
.footer-cols h3 { font-size: .84rem; font-weight: 600; color: var(--ink); margin-bottom: .7rem; }
.footer-cols a { display: block; color: var(--muted); font-size: .84rem; padding: .28rem 0; }
.footer-cols a:hover { color: var(--ink); }
.footer-note { font-size: .84rem; color: var(--muted); padding-top: 1rem; border-top: 1px solid var(--line-soft); margin: 0 0 .5rem; }
.footer-legal { font-size: .78rem; color: var(--faint); margin: .25rem 0 0; }

/* ---------- responsive nav ---------- */

@media (max-width: 900px) {
  .nav-links { display: none; }
  .nav-menu-btn { display: inline-flex; }
  .nav-inner { gap: 10px; }
  .nav-location span { display: none; }
  .nav-location { padding: 6px; }
  .nav-location svg { width: 18px; height: 18px; }
  .nav-bag-label { display: block; font-size: .68rem; color: var(--muted); text-align: center; }
  .nav-actions { flex-direction: column; align-items: stretch; gap: 0; padding-top: 2px; }
}
@media (max-width: 720px) {
  .banner { grid-template-columns: 1fr; text-align: center; }
  .banner .hero-cta { justify-content: center; }
  .section-head { flex-direction: column; align-items: flex-start; }
}
