/* ==========================================================================
   Engifted — cart.css (slide-out bag drawer, wrldinvsn.com-style right panel)
   ========================================================================== */

.drawer { position: fixed; inset: 0; z-index: 100; pointer-events: none; }
.drawer__scrim {
  position: absolute; inset: 0; background: rgba(0,0,0,.45); opacity: 0; transition: opacity .4s var(--ease);
}
.drawer__panel {
  position: absolute; top: 0; right: 0; bottom: 0; width: min(440px, 100%);
  background: #fff; display: flex; flex-direction: column;
  transform: translateX(100%); transition: transform .5s var(--ease-out);
  box-shadow: -20px 0 60px rgba(0,0,0,.08); outline: none;
}
.drawer.is-open { pointer-events: auto; }
.drawer.is-open .drawer__scrim { opacity: 1; }
.drawer.is-open .drawer__panel { transform: none; }

.drawer__head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 18px 22px; border-bottom: 1px solid var(--c-line);
}
.drawer__head h2 {
  margin: 0; font-size: 1.05rem; font-weight: 500; letter-spacing: .24em; text-transform: uppercase;
  display: flex; align-items: center; gap: 10px;
}
.drawer__count {
  display: inline-grid; place-items: center; min-width: 22px; height: 22px; padding: 0 6px; border-radius: 11px;
  background: var(--c-ink); color: #fff; font-size: .7rem; letter-spacing: 0;
}

.drawer__ship { padding: 14px 22px 16px; font-size: .85rem; text-align: center; border-bottom: 1px solid var(--c-line); }
.drawer__meter { display: block; height: 3px; background: var(--c-surface-2); margin-top: 10px; overflow: hidden; }
.drawer__meter span { display: block; height: 100%; background: var(--c-accent); transition: width .5s var(--ease-out); }

.drawer__notices:empty { display: none; }
.drawer__notices { padding: 10px 22px; background: #fff6f3; font-size: .82rem; color: #9a2a00; }
.drawer__notices p { margin: 0; }

.drawer__lines { list-style: none; margin: 0; padding: 0 22px; overflow-y: auto; flex: 1; overscroll-behavior: contain; }
.drawer.is-busy .line__total { opacity: .5; }
.line {
  display: grid; grid-template-columns: 96px 1fr; gap: 16px; padding: 20px 0; border-bottom: 1px solid var(--c-line);
  transition: opacity .22s var(--ease), transform .22s var(--ease);
}
.line.is-removing { opacity: 0; transform: translateX(30px); }
.line__img { display: block; aspect-ratio: 4 / 5; background: var(--c-surface); overflow: hidden; }
.line__img img { width: 100%; height: 100%; object-fit: cover; }
.line__noimg { display: block; width: 100%; height: 100%; }
.line__info { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.line__title {
  font-family: var(--f-display); font-weight: 500; text-transform: uppercase; letter-spacing: .03em; font-size: .95rem; line-height: 1.25;
}
.line__meta { margin: 0; font-size: .82rem; color: var(--c-muted); }
.line__meta s { color: #aaa; }
.line__meta .is-sale { color: var(--c-sale); }
.line__row { display: flex; align-items: center; justify-content: space-between; margin-top: 4px; }
.line__total { font-family: var(--f-display); font-weight: 500; transition: opacity .2s; }
.line__remove {
  align-self: flex-start; border: 0; background: none; padding: 0; font-size: .72rem; letter-spacing: .16em;
  text-transform: uppercase; color: var(--c-muted); text-decoration: underline; text-underline-offset: 3px;
}
.line__remove:hover { color: var(--c-accent); }

.stepper { display: inline-flex; align-items: center; border: 1px solid #d6d6d6; height: 36px; }
.stepper button { width: 34px; height: 100%; border: 0; background: none; font-size: 1rem; }
.stepper button:hover:not([disabled]) { background: var(--c-surface); }
.stepper button[disabled] { color: #ccc; cursor: not-allowed; }
.stepper span { min-width: 28px; text-align: center; font-family: var(--f-display); }

.drawer__empty { flex: 1; display: grid; place-content: center; text-align: center; gap: 8px; padding: 40px; }
.drawer__empty p { font-family: var(--f-display); text-transform: uppercase; letter-spacing: .14em; }

.drawer__foot { padding: 18px 22px calc(18px + env(safe-area-inset-bottom)); border-top: 1px solid var(--c-line); display: grid; gap: 8px; }
.drawer__row {
  display: flex; justify-content: space-between; align-items: baseline;
  font-family: var(--f-display); text-transform: uppercase; letter-spacing: .14em; font-size: .9rem;
}
.drawer__row strong { font-size: 1.15rem; letter-spacing: .04em; }
.drawer__note { margin: 0 0 6px; font-size: .78rem; color: var(--c-muted); }
.drawer__foot .btn--link { justify-self: center; }
