/* ============================================================
   MERIDIAN — Layout & sections
   ============================================================ */

/* ============ ANNOUNCEMENT BAR ============ */
.announce {
  height: 36px; background: var(--ink); color: var(--white);
  display: flex; align-items: center; justify-content: center;
  overflow: hidden; position: relative;
}
.announce__track { position: relative; height: 100%; width: 100%; }
.announce__msg {
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
  font-size: 11px; letter-spacing: 0.08em; font-weight: 400;
  opacity: 0; transform: translateY(100%);
  transition: opacity 0.6s var(--ease), transform 0.6s var(--ease);
}
.announce__msg.on { opacity: 1; transform: none; }
.announce__msg.out { opacity: 0; transform: translateY(-100%); }
.announce__msg a { text-decoration: underline; text-underline-offset: 2px; text-decoration-color: transparent; transition: text-decoration-color 0.25s var(--ease); }
.announce__msg a:hover { text-decoration-color: currentColor; }

/* ============ NAV ============ */
.nav {
  position: sticky; top: 0; z-index: 100;
  height: 56px; background: var(--white);
  border-bottom: 1px solid var(--ghost);
  display: grid; grid-template-columns: 1fr auto 1fr; align-items: center;
  padding: 0 var(--pad);
  transition: box-shadow 0.3s var(--ease);
}
.nav.scrolled { box-shadow: 0 2px 20px rgba(0,0,0,0.06); }
.nav__brand { font-size: 14px; font-weight: 500; letter-spacing: 0.18em; color: var(--ink); display: inline-flex; align-items: center; gap: 9px; animation: grumbBrandIn 0.7s cubic-bezier(0.16,1,0.3,1) both; }
.nav__mark { height: 30px; width: auto; display: block; transform-origin: 50% 80%; animation: grumbBlink 7s ease-in-out infinite; transition: transform 0.38s cubic-bezier(0.2,0.9,0.3,1.35); }
.nav__word { font-weight: 800; font-size: 21px; letter-spacing: -0.005em; color: var(--ink); line-height: 1; transition: letter-spacing 0.38s var(--ease); }
.nav__brand:hover .nav__mark { animation: none; transform: rotate(-8deg) translateY(-1px) scale(1.06); }
.nav__brand:hover .nav__word { letter-spacing: 0.02em; }
@keyframes grumbBlink {
  0%, 86%, 100% { transform: scaleY(1); }
  89.5% { transform: scaleY(0.5); }
  93% { transform: scaleY(1.07); }
  96% { transform: scaleY(1); }
}
@keyframes grumbBrandIn { from { opacity: 0; transform: translateY(-7px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) {
  .nav__brand, .nav__mark { animation: none !important; }
}
@media (max-width: 700px) { .nav__mark { height: 25px; } .nav__word { font-size: 18px; } }
.nav__links { display: flex; align-items: center; gap: 30px; justify-self: center; }
.nav__shop { display: flex; align-items: center; }
.nav__link {
  position: relative; font-size: 12px; font-weight: 400; letter-spacing: 0.04em;
  color: rgba(17,17,16,0.75); padding: 18px 0;
  transition: color 0.25s var(--ease);
}
.nav__link::after {
  content: ''; position: absolute; left: 0; bottom: 14px; width: 100%; height: 1px;
  background: var(--ink); transform: scaleX(0); transform-origin: left;
  transition: transform 0.3s var(--ease);
}
.nav__link:hover, .nav__link.active { color: var(--ink); }
.nav__link:hover::after, .nav__link.active::after { transform: scaleX(1); }
.nav__right { justify-self: end; display: flex; align-items: center; gap: 6px; }
.nav__account { display: inline-flex; align-items: center; gap: 7px; font-size: 12px; color: rgba(17,17,16,0.75); padding: 0 10px; height: 40px; transition: color 0.2s var(--ease); }
.nav__account:hover { color: var(--ink); }
.cart-badge {
  position: absolute; top: 4px; right: 2px;
  min-width: 15px; height: 15px; padding: 0 4px;
  background: var(--rust); color: var(--white);
  font-size: 8px; font-weight: 600; border-radius: 100px;
  display: flex; align-items: center; justify-content: center;
}

/* MEGA MENU */
.mega {
  position: absolute; top: 100%; left: 0; right: 0;
  background: var(--white); border-bottom: 1px solid var(--ghost);
  padding: 40px 80px;
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 40px;
  opacity: 0; transform: translateY(-8px); pointer-events: none;
  transition: opacity 0.25s var(--ease), transform 0.25s var(--ease);
  box-shadow: 0 18px 40px -20px rgba(0,0,0,0.18);
}
.nav__shop:hover .mega, .mega:hover { opacity: 1; transform: none; pointer-events: auto; }
.mega__col h5 { font-size: 11px; text-transform: uppercase; letter-spacing: 0.16em; color: var(--mid); margin-bottom: 18px; font-weight: 500; }
.mega__col a { display: block; font-size: 13px; color: rgba(17,17,16,0.78); padding: 7px 0; transition: color 0.2s var(--ease), padding-left 0.2s var(--ease); }
.mega__col a:hover { color: var(--ink); padding-left: 5px; }
.mega__feature { grid-column: 4; }
.mega__feature .ph { height: 220px; margin-bottom: 14px; }
.mega__feature .label { font-size: 12px; font-weight: 500; letter-spacing: 0.02em; }
.mega__feature .sub { font-size: 11px; color: var(--mid); margin-top: 4px; }

/* ============ HERO ============ */
.hero { height: 92vh; position: relative; overflow: hidden; background: #d4c8b8; }
.hero__media { position: absolute; inset: -8% 0 0 0; height: 116%; display: grid; grid-template-columns: 60% 40%; will-change: transform; }
.hero__zone { position: relative; }
.hero__zone--l { background: linear-gradient(135deg, #c8bca8, #b8aa96); }
.hero__zone--r { background: linear-gradient(135deg, #d0c8b8, #beb0a0); }
.hero__zone .lbl {
  position: absolute; inset: 0; display: flex; align-items: center; justify-content: center;
  font-size: 11px; letter-spacing: 0.24em; text-transform: uppercase; color: rgba(255,255,255,0.55); font-weight: 400;
}
.hero__overlay-tint { position: absolute; inset: 0; background: radial-gradient(120% 90% at 50% 40%, transparent 30%, rgba(0,0,0,0.22) 100%); }
.hero__content {
  position: absolute; inset: 0; z-index: 5;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  text-align: center; padding: 0 24px; will-change: transform;
}
.hero__badge {
  background: rgba(255,255,255,0.9); border-radius: 100px; padding: 6px 16px;
  font-size: 10px; text-transform: uppercase; letter-spacing: 0.2em; color: var(--ink); font-weight: 400;
  margin-bottom: 28px;
}
.hero__title { font-family: var(--serif); color: var(--white); letter-spacing: -0.02em; text-shadow: 0 2px 40px rgba(0,0,0,0.3); }
.hero__title .l1 { display: block; font-style: italic; font-weight: 400; font-size: clamp(28px, 4vw, 52px); opacity: 0.92; }
.hero__title .l2 { display: block; font-style: italic; font-weight: 400; font-size: clamp(56px, 8vw, 110px); line-height: 1.02; }
.hero__cta { margin-top: 32px; }
.hero__scroll {
  position: absolute; bottom: 26px; left: 50%; transform: translateX(-50%); z-index: 5;
  font-size: 10px; letter-spacing: 0.24em; text-transform: uppercase; color: rgba(255,255,255,0.75);
  display: flex; flex-direction: column; align-items: center; gap: 8px;
}
.hero__scroll .line { width: 1px; height: 30px; background: rgba(255,255,255,0.6); animation: scrollLine 2.2s var(--ease) infinite; transform-origin: top; }
@keyframes scrollLine { 0% { transform: scaleY(0); } 40% { transform: scaleY(1); } 100% { transform: scaleY(0); transform-origin: bottom; } }

/* ============ TICKER ============ */
.ticker { background: var(--ink); color: var(--white); overflow: hidden; height: 44px; display: flex; align-items: center; }
.ticker__row { display: flex; gap: 48px; white-space: nowrap; animation: tickerScroll 28s linear infinite; padding-left: 48px; }
.ticker__row span { font-size: 11px; letter-spacing: 0.18em; text-transform: uppercase; color: rgba(255,255,255,0.8); display: inline-flex; align-items: center; gap: 48px; }
.ticker__row span::after { content: '✦'; color: var(--rust); font-size: 9px; }
@keyframes tickerScroll { to { transform: translateX(-50%); } }

/* ============ PRODUCT CAROUSEL SECTION ============ */
.capsule { background: var(--paper); padding: 64px var(--pad) 48px; border-top: 1px solid var(--ghost); }
.capsule__head { display: flex; flex-direction: column; align-items: center; margin-bottom: 40px; gap: 10px; }
.capsule__viewport { position: relative; overflow: hidden; }
.capsule__track { display: flex; gap: 16px; transition: transform 0.6s var(--ease); }
.card { flex: 0 0 calc(25% - 12px); }
.card__media { position: relative; height: 380px; background: var(--cream); overflow: hidden; }
.card__img { position: absolute; inset: 0; transition: transform 0.7s var(--ease), opacity 0.4s var(--ease); }
.card__img--alt { opacity: 0; }
.card:hover .card__img--main { transform: scale(1.04); opacity: 0; }
.card:hover .card__img--alt { opacity: 1; transform: scale(1.04); }
.card__tag {
  position: absolute; top: 12px; left: 12px; z-index: 3;
  background: var(--rust); color: var(--white); font-size: 9px; font-weight: 500;
  letter-spacing: 0.14em; text-transform: uppercase; padding: 4px 9px;
}
.card__tag--ghost { background: var(--white); color: var(--ink); border: 1px solid var(--ghost); }
.card__wish {
  position: absolute; top: 10px; right: 10px; z-index: 3;
  width: 32px; height: 32px; border-radius: 50%; background: rgba(255,255,255,0.85);
  display: flex; align-items: center; justify-content: center; color: var(--ink);
  opacity: 0; transform: translateY(-4px); transition: opacity 0.3s var(--ease), transform 0.3s var(--ease), background 0.2s;
}
.card__wish svg { width: 15px; height: 15px; }
.card:hover .card__wish { opacity: 1; transform: none; }
.card__wish:hover { background: var(--white); }
.card__wish.on { color: var(--rust); }
.card__quick {
  position: absolute; left: 0; right: 0; bottom: 0; z-index: 3;
  background: var(--white); border-top: 1px solid var(--ghost);
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 12px 14px;
  transform: translateY(101%); transition: transform 0.4s var(--ease);
}
.card:hover .card__quick { transform: none; }
.card__sizes { display: flex; gap: 6px; }
.card__add {
  font-size: 10px; font-weight: 500; letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--ink); white-space: nowrap; display: inline-flex; align-items: center; gap: 6px;
  transition: color 0.2s var(--ease);
}
.card__add:hover { color: var(--rust); }
.card__info { padding: 14px 2px 0; display: flex; flex-direction: column; gap: 5px; }
.card__row { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
.card__name { font-size: 13px; font-weight: 400; color: var(--ink); }
.card__price { font-size: 13px; font-weight: 400; color: var(--ink); }
.card__price .was { color: var(--mid); text-decoration: line-through; margin-right: 7px; }
.card__price .now { color: var(--rust); }
.card__meta { font-size: 11px; color: var(--mid); letter-spacing: 0.02em; }
.card__swatches { display: flex; gap: 5px; margin-top: 2px; }
.card__swatches i { width: 11px; height: 11px; border-radius: 50%; border: 1px solid var(--ghost-mid); display: inline-block; }

.capsule__nav { position: absolute; top: -64px; right: 0; display: flex; gap: 8px; }
.capsule__foot { display: flex; justify-content: center; margin-top: 40px; }
.capsule__progress { margin-top: 28px; height: 2px; background: var(--ghost); position: relative; overflow: hidden; }
.capsule__progress i { position: absolute; left: 0; top: 0; bottom: 0; background: var(--ink); transition: transform 0.6s var(--ease), width 0.6s var(--ease); }

/* ============ CATEGORY GRID ============ */
.cats { padding: 96px var(--pad); background: var(--cream); }
.cats__head { display: flex; align-items: flex-end; justify-content: space-between; margin-bottom: 40px; gap: 24px; }
.cats__grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 16px; }
.cat { position: relative; height: 520px; overflow: hidden; cursor: pointer; }
.cat .ph { position: absolute; inset: 0; transition: transform 0.9s var(--ease); }
.cat:hover .ph { transform: scale(1.05); }
.cat__veil { position: absolute; inset: 0; background: linear-gradient(to top, rgba(0,0,0,0.42), transparent 55%); z-index: 2; }
.cat__body { position: absolute; left: 28px; bottom: 28px; right: 28px; z-index: 3; color: var(--white); }
.cat__kicker { font-size: 10px; letter-spacing: 0.2em; text-transform: uppercase; opacity: 0.85; }
.cat__title { font-family: var(--serif); font-style: italic; font-size: 34px; margin: 8px 0 16px; }
.cat__link { font-size: 11px; letter-spacing: 0.16em; text-transform: uppercase; display: inline-flex; align-items: center; gap: 8px; opacity: 0.9; transition: gap 0.3s var(--ease); }
.cat:hover .cat__link { gap: 14px; }

/* ============ EDITORIAL DARK SPLIT ============ */
.editorial { background: var(--black); color: var(--white); display: grid; grid-template-columns: 1fr 1fr; min-height: 640px; }
.editorial__media { position: relative; }
.editorial__media .ph { position: absolute; inset: 0; }
.editorial__body { display: flex; flex-direction: column; justify-content: center; padding: 96px 80px; max-width: 620px; }
.editorial__eyebrow { font-size: 11px; letter-spacing: 0.24em; text-transform: uppercase; color: rgba(255,255,255,0.6); margin-bottom: 24px; }
.editorial__title { font-family: var(--serif); font-style: italic; font-size: clamp(40px, 5vw, 64px); line-height: 1.02; letter-spacing: -0.01em; margin-bottom: 24px; }
.editorial__copy { font-size: 13px; line-height: 1.8; color: rgba(255,255,255,0.72); max-width: 440px; margin-bottom: 36px; }
.editorial__cta { display: flex; gap: 14px; flex-wrap: wrap; }

/* ============ COLLECTION BANNER ============ */
.banner { position: relative; height: 560px; overflow: hidden; display: flex; align-items: center; }
.banner .ph { position: absolute; inset: 0; }
.banner__veil { position: absolute; inset: 0; background: linear-gradient(90deg, rgba(0,0,0,0.5), rgba(0,0,0,0.1) 60%, transparent); z-index: 2; }
.banner__body { position: relative; z-index: 3; color: var(--white); padding: 0 80px; max-width: 560px; }
.banner__eyebrow { font-size: 11px; letter-spacing: 0.24em; text-transform: uppercase; opacity: 0.8; margin-bottom: 18px; }
.banner__title { font-family: var(--serif); font-style: italic; font-size: clamp(36px, 4.5vw, 58px); line-height: 1.04; margin-bottom: 28px; }

/* ============ EDIT TRIO (lookbook) ============ */
.trio { padding: 96px var(--pad); background: var(--paper); }
.trio__head { text-align: center; margin-bottom: 40px; display: flex; flex-direction: column; gap: 10px; align-items: center; }
.trio__grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.look { position: relative; overflow: hidden; cursor: pointer; }
.look .ph { height: 460px; transition: transform 0.9s var(--ease); }
.look:hover .ph { transform: scale(1.04); }
.look__cap { display: flex; justify-content: space-between; align-items: baseline; padding: 16px 2px 0; }
.look__cap .name { font-size: 13px; }
.look__cap .meta { font-size: 11px; color: var(--mid); }

/* ============ NEWSLETTER ============ */
.news { background: var(--bone); padding: 96px var(--pad); }
.news__inner { max-width: 560px; margin: 0 auto; text-align: center; }
.news__title { font-family: var(--serif); font-style: italic; font-size: clamp(32px, 4vw, 48px); margin-bottom: 16px; }
.news__copy { font-size: 13px; line-height: 1.8; color: var(--mid); margin-bottom: 32px; }
.news__form { display: flex; gap: 0; border: 1px solid var(--ink); background: var(--white); }
.news__form input { flex: 1; border: none; outline: none; padding: 14px 18px; font-size: 13px; font-family: inherit; background: transparent; color: var(--ink); }
.news__form input::placeholder { color: var(--mid); }
.news__note { font-size: 11px; color: var(--mid); margin-top: 16px; letter-spacing: 0.02em; }
.news__ok { font-size: 13px; color: var(--rust); margin-top: 18px; opacity: 0; transition: opacity 0.4s var(--ease); }
.news__ok.show { opacity: 1; }

/* ============ FOOTER ============ */
.footer { background: var(--ink); color: var(--white); padding: 80px var(--pad) 40px; }
.footer__top { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1fr; gap: 48px; padding-bottom: 56px; border-bottom: 1px solid rgba(255,255,255,0.1); }
.footer__brand { font-size: 24px; font-weight: 500; letter-spacing: 0.18em; margin-bottom: 20px; }
.footer__tag { font-size: 13px; line-height: 1.8; color: rgba(255,255,255,0.6); max-width: 280px; }
.footer__col h6 { font-size: 11px; text-transform: uppercase; letter-spacing: 0.14em; color: rgba(255,255,255,0.5); margin-bottom: 20px; font-weight: 500; }
.footer__col a { display: block; font-size: 13px; color: rgba(255,255,255,0.78); padding: 7px 0; transition: color 0.2s var(--ease); }
.footer__col a:hover { color: var(--white); }
.footer__bottom { display: flex; justify-content: space-between; align-items: center; padding-top: 28px; gap: 24px; flex-wrap: wrap; }
.footer__legal { font-size: 11px; color: rgba(255,255,255,0.5); letter-spacing: 0.02em; }
.footer__social { display: flex; gap: 8px; }
.footer__social a { width: 36px; height: 36px; border: 1px solid rgba(255,255,255,0.18); border-radius: 50%; display: flex; align-items: center; justify-content: center; color: rgba(255,255,255,0.7); transition: background 0.25s var(--ease), color 0.25s var(--ease), border-color 0.25s var(--ease); }
.footer__social a:hover { background: var(--white); color: var(--ink); border-color: var(--white); }
.footer__social svg { width: 15px; height: 15px; }

/* ============ TOAST ============ */
.toast {
  position: fixed; bottom: 32px; left: 50%; transform: translate(-50%, 20px); z-index: 200;
  background: var(--ink); color: var(--white); padding: 14px 22px;
  font-size: 12px; letter-spacing: 0.04em; display: flex; align-items: center; gap: 12px;
  opacity: 0; pointer-events: none; transition: opacity 0.3s var(--ease), transform 0.3s var(--ease);
  box-shadow: 0 12px 40px rgba(0,0,0,0.25);
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.toast .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--rust); }

/* ============ RESPONSIVE ============ */
@media (max-width: 1100px) {
  .card { flex-basis: calc(33.333% - 11px); }
  .cats__grid { grid-template-columns: 1fr 1fr; }
  .cats__grid .cat:first-child { grid-column: 1 / -1; }
}
@media (max-width: 880px) {
  :root { --pad: 16px; }
  .nav {
    padding: 0 clamp(14px, 4vw, 24px);
    grid-template-columns: auto 1fr;
  }
  .nav__links { display: none; }
  .nav__brand {
    font-size: 13px;
    letter-spacing: 0.16em;
    flex-shrink: 0;
  }
  .nav__right {
    justify-self: end;
    display: flex;
    align-items: center;
    gap: clamp(4px, 1.5vw, 8px);
  }
  /* Reorder right side: Search | Account | Cart | Hamburger */
  .nav__right .icon-btn:not([data-open-bag]),
  .nav__right a.icon-btn { order: 1; }
  .nav__account { order: 2; padding: 0 4px; display: inline-flex; align-items: center; justify-content: center; }
  .nav__account span { display: none; }
  .nav__right [data-open-bag] { order: 3; }
  .burger { order: 4; display: flex; }
  
  /* Minimum 44x44px touch targets without pushing width */
  .nav__right .icon-btn, .nav__right .burger, .nav__right .nav__account {
    position: relative;
    min-width: 38px;
    height: 44px;
  }
  .nav__right .icon-btn::after, .nav__right .burger::after, .nav__right .nav__account::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 44px;
    height: 44px;
    transform: translate(-50%, -50%);
  }
  .editorial { grid-template-columns: 1fr; }
  .editorial__media { min-height: 360px; }
  .editorial__body { padding: 56px 28px; }
  .trio__grid { grid-template-columns: 1fr; }
  .card { flex-basis: calc(50% - 8px); }
  .footer__top { grid-template-columns: 1fr 1fr; gap: 32px; }
  .hero__media { grid-template-columns: 100%; }
  .hero__zone--r { display: none; }
}
@media (max-width: 560px) {
  .card { flex-basis: calc(100% - 0px); }
  .cats__grid { grid-template-columns: 1fr; }
  .footer__top { grid-template-columns: 1fr; }
  .news__form { flex-direction: column; }
}
