.footer-minicart {
  list-style: none;
}

.footer-minicart__root {
  position: relative;
  display: inline-block;
}

.footer-minicart__trigger {
  position: relative;
  display: inline-flex;
  cursor: pointer;
  align-items: center;
  justify-content: center;
  border: 0;
  background: transparent;
  padding: 0.125rem;
  color: color-mix(in srgb, var(--color-primary-50, #fff) 50%, transparent);
  transition: color 0.3s ease;
}

.footer-minicart__trigger:hover,
.footer-minicart__trigger:focus-visible {
  color: var(--color-primary-50, #fff);
  outline: none;
}

.footer-minicart__icon {
  display: block;
}

.footer-minicart__badge {
  position: absolute;
  top: -0.25rem;
  right: -0.375rem;
  min-width: 1rem;
  height: 1rem;
  padding: 0 0.25rem;
  border-radius: 9999px;
  background-color: var(--color-primary-500, #6366f1);
  color: #fff;
  font-size: 0.625rem;
  font-weight: 600;
  line-height: 1rem;
  text-align: center;
}

.footer-minicart__badge--hidden {
  display: none;
}

.footer-minicart__sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.footer-minicart__panel {
  position: absolute;
  right: 50%;
  bottom: calc(100% + 0.75rem);
  z-index: 10000;
  box-sizing: border-box;
  width: min(20rem, calc(100vw - 2rem));
  padding: 0.75rem;
  border-radius: 0.75rem;
  border: 1px solid color-mix(in srgb, var(--color-stroke-3, #ccc) 30%, transparent);
  background-color: var(--color-background-6, #1a1a1a);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.4);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateX(50%) scale(0.95);
  transform-origin: bottom center;
  transition:
    opacity 0.2s ease,
    transform 0.2s ease,
    visibility 0.2s ease;
}

.footer-minicart[data-open='true'] .footer-minicart__panel {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateX(50%) scale(1);
}

.footer-minicart__section--hidden {
  display: none;
}

.footer-minicart__empty {
  padding: 1.5rem 0.75rem;
  text-align: center;
}

.footer-minicart__empty p {
  margin: 0;
  font-size: 0.875rem;
  color: color-mix(in srgb, #fff 60%, transparent);
}

.footer-minicart__list {
  max-height: 14rem;
  margin: 0;
  padding: 0;
  list-style: none;
  overflow-y: auto;
}

.footer-minicart__item {
  margin: 0;
  padding: 0;
  list-style: none;
}

.footer-minicart__item + .footer-minicart__item {
  margin-top: 0.75rem;
  padding-top: 0.75rem;
  border-top: 1px solid color-mix(in srgb, #fff 8%, transparent);
}

.footer-minicart__row {
  display: flex;
  gap: 0.75rem;
  align-items: flex-start;
}

.footer-minicart__thumb {
  flex-shrink: 0;
  width: 3.5rem;
  height: 3.5rem;
  overflow: hidden;
  border-radius: 0.5rem;
  background-color: color-mix(in srgb, #fff 6%, transparent);
}

.footer-minicart__thumb img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.footer-minicart__body {
  position: relative;
  flex: 1;
  min-width: 0;
  padding-right: 1.25rem;
}

.footer-minicart__title {
  margin: 0;
  font-size: 0.875rem;
  font-weight: 500;
  line-height: 1.35;
  color: #fff;
  text-decoration: none;
}

.footer-minicart__title:hover {
  color: color-mix(in srgb, #fff 85%, transparent);
}

.footer-minicart__badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem;
  margin-top: 0.25rem;
}

.footer-minicart__tag {
  display: inline-block;
  padding: 0.125rem 0.375rem;
  border-radius: 0.25rem;
  font-size: 0.625rem;
  font-weight: 600;
  line-height: 1.2;
}

.footer-minicart__tag--primary {
  background-color: color-mix(in srgb, #6366f1 80%, #000);
  color: #fff;
}

.footer-minicart__tag--info {
  background-color: color-mix(in srgb, #0ea5e9 80%, #000);
  color: #fff;
}

.footer-minicart__tag--success {
  background-color: color-mix(in srgb, #22c55e 80%, #000);
  color: #fff;
}

.footer-minicart__price {
  margin: 0.375rem 0 0;
  font-size: 0.8125rem;
  font-weight: 500;
  color: color-mix(in srgb, #fff 75%, transparent);
}

.footer-minicart__price-original {
  margin-right: 0.375rem;
  color: color-mix(in srgb, #fff 45%, transparent);
  text-decoration: line-through;
  font-size: 0.75rem;
  font-weight: 400;
}

.footer-minicart__remove {
  position: absolute;
  top: 0;
  right: 0;
  display: inline-flex;
  width: 1.25rem;
  height: 1.25rem;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 0.25rem;
  background: transparent;
  color: color-mix(in srgb, #fff 50%, transparent);
  cursor: pointer;
  transition:
    color 0.2s ease,
    background-color 0.2s ease;
}

.footer-minicart__remove:hover,
.footer-minicart__remove:focus-visible {
  color: #fff;
  background-color: color-mix(in srgb, #fff 8%, transparent);
  outline: none;
}

.footer-minicart__total {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-top: 0.875rem;
  padding-top: 0.875rem;
  border-top: 1px solid color-mix(in srgb, #fff 10%, transparent);
}

.footer-minicart__total h5,
.footer-minicart__total h4 {
  margin: 0;
}

.footer-minicart__total h5 {
  font-size: 0.875rem;
  font-weight: 500;
  color: color-mix(in srgb, #fff 65%, transparent);
}

.footer-minicart__total h4 {
  font-size: 1rem;
  font-weight: 700;
  color: var(--color-primary-400, #818cf8);
}

.footer-minicart__actions {
  display: flex;
  gap: 0.5rem;
  margin-top: 0.75rem;
}

.footer-minicart__btn {
  flex: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.25rem;
  padding: 0.375rem 0.75rem;
  border-radius: 0.5rem;
  border: 1px solid color-mix(in srgb, #fff 15%, transparent);
  background: transparent;
  color: #fff;
  font-size: 0.8125rem;
  font-weight: 500;
  line-height: 1.2;
  text-align: center;
  text-decoration: none;
  transition:
    background-color 0.2s ease,
    border-color 0.2s ease;
}

.footer-minicart__btn:hover {
  background-color: color-mix(in srgb, #fff 6%, transparent);
  color: #fff;
}

.footer-minicart__btn--primary {
  border-color: transparent;
  background-color: var(--color-primary-500, #6366f1);
}

.footer-minicart__btn--primary:hover {
  background-color: var(--color-primary-400, #818cf8);
}
