:root {
  --gigal-cart-orange: #ff6800;
  --gigal-cart-dark: #0b0c16;
  --gigal-cart-surface: #141622;
  --gigal-cart-border: rgba(255, 255, 255, .14);
  --gigal-cart-text: #f7f7fb;
  --gigal-cart-muted: #b8bbc5;
}

.catalog-cart-head,
.catalog-cart-cell {
  width: 126px;
  min-width: 126px;
  text-align: center !important;
  vertical-align: middle !important;
}

.gigal-cart-add {
  width: 100%;
  min-height: 38px;
  padding: 8px 10px;
  color: #fff;
  background: var(--gigal-cart-orange);
  border: 0;
  border-radius: 7px;
  cursor: pointer;
  font: 700 13px/1.15 Inter, Arial, sans-serif;
  transition: transform .15s ease, background-color .15s ease;
}

.gigal-cart-add:hover,
.gigal-cart-add:focus-visible {
  background: #e85f00;
  outline: 2px solid #11131d;
  outline-offset: 2px;
  transform: translateY(-1px);
}

.gigal-cart-add[data-in-cart="true"] {
  color: #12131b;
  background: #ffd4b8;
}

.gigal-cart-unavailable {
  color: #686a73;
  font-size: 12px;
  font-weight: 650;
}

.gigal-cart-fab {
  position: fixed;
  z-index: 9997;
  right: 22px;
  bottom: 24px;
  min-height: 52px;
  padding: 0 17px;
  display: inline-flex;
  align-items: center;
  gap: 9px;
  color: #fff;
  background: var(--gigal-cart-orange);
  border: 0;
  border-radius: 999px;
  box-shadow: 0 14px 38px rgba(0, 0, 0, .42);
  cursor: pointer;
  font: 750 15px/1 Inter, Arial, sans-serif;
}

.category-page ~ .gigal-cart-fab,
body:has(.category-cta-bar) .gigal-cart-fab {
  bottom: 98px;
}

.gigal-cart-fab:hover,
.gigal-cart-fab:focus-visible {
  background: #e85f00;
  outline: 3px solid rgba(255, 255, 255, .7);
  outline-offset: 2px;
}

.gigal-cart-fab svg {
  width: 21px;
  height: 21px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 2;
}

.gigal-cart-badge {
  min-width: 24px;
  height: 24px;
  padding: 0 6px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #0b0c16;
  background: #fff;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
}

.gigal-cart-backdrop {
  position: fixed;
  z-index: 9998;
  inset: 0;
  background: rgba(2, 3, 9, .66);
  opacity: 0;
  visibility: hidden;
  transition: opacity .2s ease, visibility .2s ease;
}

.gigal-cart-drawer {
  position: fixed;
  z-index: 9999;
  top: 0;
  right: 0;
  bottom: 0;
  width: min(440px, 100%);
  display: flex;
  flex-direction: column;
  color: var(--gigal-cart-text);
  background: var(--gigal-cart-dark);
  border-left: 1px solid var(--gigal-cart-border);
  box-shadow: -20px 0 48px rgba(0, 0, 0, .48);
  transform: translateX(102%);
  transition: transform .24s ease;
}

body.gigal-cart-open {
  overflow: hidden;
}

body.gigal-cart-open .gigal-cart-backdrop {
  opacity: 1;
  visibility: visible;
}

body.gigal-cart-open .gigal-cart-drawer {
  transform: translateX(0);
}

.gigal-cart-drawer-header {
  padding: 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  border-bottom: 1px solid var(--gigal-cart-border);
}

.gigal-cart-drawer-title {
  margin: 0;
  color: #fff;
  font: 800 24px/1.15 "Inter Tight", Inter, Arial, sans-serif;
}

.gigal-cart-close {
  width: 42px;
  height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  background: #232631;
  border: 1px solid var(--gigal-cart-border);
  border-radius: 50%;
  cursor: pointer;
  font-size: 25px;
  line-height: 1;
}

.gigal-cart-drawer-body {
  flex: 1 1 auto;
  padding: 16px 18px 24px;
  overflow-y: auto;
}

.gigal-cart-empty {
  margin: 28px 0;
  padding: 24px;
  color: var(--gigal-cart-muted);
  background: var(--gigal-cart-surface);
  border: 1px solid var(--gigal-cart-border);
  border-radius: 12px;
  text-align: center;
}

.gigal-cart-empty strong {
  display: block;
  margin-bottom: 7px;
  color: #fff;
  font-size: 18px;
}

.gigal-cart-item {
  padding: 15px 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  border-bottom: 1px solid var(--gigal-cart-border);
}

.gigal-cart-item-name {
  margin: 0 0 5px;
  color: #fff;
  font-size: 15px;
  font-weight: 750;
  line-height: 1.3;
}

.gigal-cart-item-details,
.gigal-cart-item-category {
  margin: 0 0 4px;
  color: var(--gigal-cart-muted);
  font-size: 12px;
  line-height: 1.35;
}

.gigal-cart-item-price {
  margin-top: 7px;
  color: #ffad75;
  font-size: 13px;
  font-weight: 750;
}

.gigal-cart-qty {
  display: flex;
  align-items: center;
  align-self: center;
  gap: 6px;
}

.gigal-cart-qty button {
  width: 34px;
  height: 34px;
  padding: 0;
  color: #fff;
  background: #242733;
  border: 1px solid var(--gigal-cart-border);
  border-radius: 7px;
  cursor: pointer;
  font-size: 18px;
  font-weight: 800;
}

.gigal-cart-qty output {
  min-width: 34px;
  color: #fff;
  font-weight: 800;
  text-align: center;
}

.gigal-cart-drawer-footer {
  padding: 17px 18px max(18px, env(safe-area-inset-bottom));
  background: #10121b;
  border-top: 1px solid var(--gigal-cart-border);
}

.gigal-cart-total-row {
  margin-bottom: 13px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  font-weight: 700;
}

.gigal-cart-total {
  color: #fff;
  font-size: 19px;
  font-weight: 850;
}

.gigal-cart-checkout-link,
.gigal-cart-continue-link {
  width: 100%;
  min-height: 48px;
  padding: 12px 16px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #fff !important;
  background: var(--gigal-cart-orange);
  border: 0;
  border-radius: 8px;
  font-weight: 800;
  line-height: 1.2;
  text-decoration: none !important;
}

.gigal-cart-checkout-link[aria-disabled="true"] {
  opacity: .48;
  pointer-events: none;
}

.gigal-cart-clear {
  margin-top: 10px;
  padding: 8px;
  color: var(--gigal-cart-muted);
  background: transparent;
  border: 0;
  cursor: pointer;
  font: 650 13px/1.2 Inter, Arial, sans-serif;
  text-decoration: underline;
}

.gigal-cart-toast {
  position: fixed;
  z-index: 10001;
  right: 22px;
  bottom: 88px;
  max-width: min(360px, calc(100% - 28px));
  padding: 11px 14px;
  color: #fff;
  background: #181b25;
  border: 1px solid var(--gigal-cart-border);
  border-radius: 9px;
  box-shadow: 0 12px 30px rgba(0, 0, 0, .38);
  opacity: 0;
  pointer-events: none;
  transform: translateY(8px);
  transition: opacity .18s ease, transform .18s ease;
  font-size: 13px;
  font-weight: 700;
}

.gigal-cart-toast.is-visible {
  opacity: 1;
  transform: translateY(0);
}

body:has(.category-cta-bar) .gigal-cart-toast {
  bottom: 158px;
}

@media screen and (max-width: 767px) {
  .catalog-cart-head,
  .catalog-cart-cell {
    width: 112px;
    min-width: 112px;
  }

  .gigal-cart-fab {
    right: 12px;
    bottom: 14px;
    min-height: 48px;
    padding: 0 14px;
  }

  body:has(.category-cta-bar) .gigal-cart-fab {
    bottom: 88px;
  }

  .gigal-cart-drawer {
    width: 100%;
  }

  .gigal-cart-toast {
    right: 14px;
    bottom: 74px;
  }

  body:has(.category-cta-bar) .gigal-cart-toast {
    bottom: 144px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .gigal-cart-drawer,
  .gigal-cart-backdrop,
  .gigal-cart-toast,
  .gigal-cart-add {
    transition: none;
  }
}
