.cxt-sidecart {
  --cxt-accent: #202020;
  --cxt-orange: #f39700;
  --cxt-text: #242424;
  --cxt-muted: #777;
  --cxt-border: #eeeeee;
  --cxt-soft: #f5f5f5;

  font: inherit;
  color: var(--cxt-text);
}

.cxt-sidecart[hidden] {
  display: none !important;
}

.cxt-sc-trigger {
  position: fixed;
  right: 0;
  bottom: 0;
  width: 48px;
  height: 48px;
  padding: 10px;
  margin: 10px;
  border-radius: 14px;
  z-index: 999999;

  display: flex;
  align-items: center;
  justify-content: center;

  cursor: pointer;
  transition: all .3s ease;

  -webkit-appearance: none !important;
  appearance: none !important;
  -webkit-tap-highlight-color: transparent !important;
  -webkit-touch-callout: none;

  border: 0 !important;
  outline: 0 !important;

  background: #fff !important;
  background-image: none !important;

  color: #000 !important;

  box-shadow: 0 1px 4px rgba(0,0,0,.35) !important;
  -webkit-box-shadow: 0 1px 4px rgba(0,0,0,.35) !important;
}

.cxt-sc-trigger:hover,
.cxt-sc-trigger:active {
  transform: scale(1.05);
}

.cxt-sc-trigger:focus,
.cxt-sc-trigger:focus-visible,
.cxt-sc-trigger:active {
  border: 0 !important;
  outline: 0 !important;

  box-shadow: 0 1px 4px rgba(0,0,0,.35) !important;
  -webkit-box-shadow: 0 1px 4px rgba(0,0,0,.35) !important;
}

.cxt-sc-trigger::-moz-focus-inner {
  border: 0;
}

.cxt-sc-trigger:hover,
.cxt-sc-trigger:active {
  transform: scale(1.05);
}

.cxt-sc-trigger svg {
  width: 27px;
  height: 27px;
  color: #000;
  fill: #000;
  border: 0;
  outline: 0;
}

.cxt-sc-count {
  position: absolute;
  top: -15px;
  left: -15px;
  min-width: 28px;
  height: 28px;
  padding: 0 5px;
  border-radius: 20px;
  background: var(--cxt-orange);
  color: #000;
  text-align: center;
  font-size: 13px;
  line-height: 28px;
  font-weight: 700;
  transition: all .3s ease;
}

.cxt-sc-count[hidden] {
  display: none !important;
}

/* overlay */

.cxt-sc-overlay {
  position: fixed;
  inset: 0;
  background: #0007;
  z-index: 9999;
}

.cxt-sc-overlay[hidden] {
  display: none;
}

/* painel */

.cxt-sc-panel {
  position: fixed;
  right: 0;
  top: 0;
  bottom: 0;
  width: min(440px, 100%);
  z-index: 10000;
  background: #fff;
  display: flex;
  flex-direction: column;
  box-shadow: -8px 0 40px #0002;
  transform: translateX(105%);
  visibility: hidden;
  transition: transform .25s, visibility .25s;
}

.cxt-sidecart.is-open .cxt-sc-trigger {
  right: 450px;
}

.cxt-sidecart.is-open .cxt-sc-panel {
  transform: none;
  visibility: visible;
}

/* header */

.cxt-sc-header {
  padding: 15px 20px;
  min-height: 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--cxt-border);
}

.cxt-sc-header,
.cxt-sc-subtotal {
  font-size: 25px;
}

.cxt-sc-close {
  background: none;
  border: 0;
  padding: 0;
  font-size: 44px;
  line-height: .8;
  cursor: pointer;
  color: inherit;
  transition: opacity .2s ease;
}

.cxt-sc-close:hover {
  opacity: .6;
}

/* conteúdo */

.cxt-sc-items {
  flex: 1;
  overflow-y: auto;
  min-height: 0;
  padding: 8px 24px;
  overscroll-behavior: contain;
  font-family: Roboto, sans-serif;
}

.cxt-sc-items::-webkit-scrollbar {
  width: 7px;
}

.cxt-sc-items::-webkit-scrollbar-thumb {
  background: #d8d8d8;
  border-radius: 10px;
}

.cxt-sc-item {
  display: grid;
  grid-template-columns: 76px minmax(0, 1fr);
  gap: 16px;
  padding: 20px 0;
  border-bottom: 1px solid var(--cxt-border);
}

.cxt-sc-item:last-child {
  border-bottom: 0;
}

.cxt-sc-item.is-busy {
  opacity: .55;
  pointer-events: none;
}

/* imagem */

.cxt-sc-image {
  width: 76px;
  height: 76px;
  object-fit: contain;
  border: 1px solid var(--cxt-border);
  border-radius: 8px;
  background: #fff;
}

/* título */

.cxt-sc-name {
  display: block;
  margin-bottom: 6px;
  font-size: 14px;
  font-weight: 600;
  color: #111;
  text-decoration: none;
  line-height: 1.35;
}
.cxt-sc-name:hover {
  color: black;
}

/* variações */

.cxt-sc-variation {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin: 6px 0 8px;
  font-size: 12px;
  color: #121212;
}

.cxt-sc-variation-line {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  padding: 3px 7px;
  border-radius: 40px;
  background: #f39700;
  line-height: 1.3;
}

.cxt-sc-variation-line span {
  font-weight: 700;
}

/* módulos */

.cxt-sc-meta {
  margin: 7px 0 6px;
  font-size: 12px;
  color: #121212;
  overflow-wrap: anywhere;
  display: flex;
  flex-direction: column;
  gap: 0;
}

.cxt-sc-meta-line {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  line-height: 1.35;
  padding: 6px 8px;
  border-radius: 5px;
  background: #fff;
}

.cxt-sc-meta-line:nth-child(even) {
  background: var(--cxt-soft);
}

.cxt-sc-meta-line:hover {
  background: #ddd;
}

.cxt-sc-meta-line > span:first-child {
  min-width: 0;
}

.cxt-sc-meta p {
  margin: 4px 0;
}

.cxt-sc-meta dl {
  margin: 0;
}

.cxt-sc-meta dt {
  font-weight: 600;
}

.cxt-sc-meta dd {
  margin: 0 0 5px;
}

/* preço */

.cxt-sc-price {
  margin: 10px 0 8px;
  font-weight: 700;
  font-size: 15px;
  line-height: 1.2;
  text-align: right;
}

/* ações */

.cxt-sc-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: 6px;
}

/* quantidade */

.cxt-sc-quantity {
  display: inline-flex;
  align-items: center;
  height: 36px;
  border: 1px solid #dedede;
  border-radius: 7px;
  overflow: hidden;
  background: #fff;
}

.cxt-sc-quantity button {
  width: 34px;
  height: 34px;
  border: 0;
  background: transparent;
  cursor: pointer;
  font-size: 17px;
  color: inherit;
  outline: none;
  transition: background .15s ease;
}

.cxt-sc-quantity button:hover,
.cxt-sc-quantity button:focus {
  background: #f3f3f3;
  outline: none;
}

.cxt-sc-quantity span {
  min-width: 28px;
  text-align: center;
  font-size: 13px;
}

.cxt-sc-qty-input {
  width: 44px;
  min-width: 0;
  height: 34px;
  padding: 0 4px;
  border: 1px solid #dedede;
  border-top: 0;
  border-bottom: 0;
  background: transparent;
  text-align: center;
  font: inherit;
  font-size: 13px;
  font-weight: 700;
  color: inherit;
  outline: none;
  appearance: textfield;
  -moz-appearance: textfield;
}

.cxt-sc-qty-input::-webkit-inner-spin-button,
.cxt-sc-qty-input::-webkit-outer-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.cxt-sc-qty-input:focus {
  background: var(--cxt-soft);
}

/* remover */

.cxt-sc-remove {
  width: 34px;
  height: 34px;
  padding: 0;
  border: 1px solid #dedede;
  border-radius: 7px;
  background: transparent;
  color: #777;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 14px;
  transition:
    background .2s ease,
    color .2s ease;
}

.cxt-sc-remove svg {
  width: 17px;
  height: 17px;
  pointer-events: none;
}

.cxt-sc-remove:hover {
  background: #fff1f1;
  color: #b10000;
}

/* footer */

.cxt-sc-footer {
  padding: 22px 24px;
  border-top: 1px solid var(--cxt-border);
  display: grid;
  gap: 10px;
  background: #fff;
  box-shadow: 0 -5px 18px rgba(0, 0, 0, .03);
}

.cxt-sc-footer .buttons {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}

.cxt-sc-total {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
}

.cxt-sc-total span {
  font-size: 14px;
  color: #555;
}

.cxt-sc-cart,
.cxt-sc-checkout {
  display: block;
  padding: 13px;
  width: 100%;
  text-align: center;
  border-radius: 7px;
  text-decoration: none !important;
  font-weight: 600;
  font-size: 14px;
  transition: all .2s ease;
}

.cxt-sc-cart:hover,
.cxt-sc-checkout:hover {
  transform: translateY(-2px);
}

.cxt-sc-cart {
  background: var(--cxt-accent);
  color: #fff !important;
}

.cxt-sc-checkout {
  background-color: var(--cxt-orange);
  color: #000 !important;
}

/* mensagens */

.cxt-sc-message {
  font-size: 13px;
  padding: 0 24px;
  color: #a33;
  text-align: center;
}

.cxt-sc-message:not(:empty) {
  padding-top: 12px;
}

/* vazio */

.cxt-sc-empty {
  padding: 50px 0;
  text-align: center;
  color: var(--cxt-muted);
}

/* bloqueio */

body.cxt-sc-locked {
  overflow: hidden;
}

/* loader */

.cxt-sc-loader {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 35px 20px;
  color: #666;
  font-size: 14px;
}

.cxt-sc-spinner {
  width: 20px;
  height: 20px;
  border: 2px solid #e5e5e5;
  border-top-color: #f58220;
  border-radius: 50%;
  animation: cxt-sc-spin .7s linear infinite;
}

@keyframes cxt-sc-spin {
  to {
    transform: rotate(360deg);
  }
}

.cxt-sidecart.is-loading .cxt-sc-items {
  opacity: .65;
  pointer-events: none;
}

.cxt-sidecart.is-loading .cxt-sc-loader {
  opacity: 1;
}

/* menu icon */

.cxt-cart-menu-icon {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.cxt-cart-menu-icon > i {
  font-size: 23px !important;
}

.cxt-cart-menu-count {
  position: absolute;
  top: -10px;
  right: -12px;
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 20px;
  background: #da8101;
  color: #000;
  font-size: 10px;
  font-weight: 700;
  line-height: 1;
}

.cxt-cart-menu-count[hidden] {
  display: none;
}

/* mobile */

@media (max-width: 600px) {
  .cxt-sc-trigger {
    right: 6px;
    bottom: 6px;
  }

  .cxt-sidecart.is-open .cxt-sc-panel {
    left: 15%;
    width: 85%;
  }

  .cxt-sidecart.is-open .cxt-sc-trigger {
    right: 85%;
  }

  .cxt-sidecart.is-open .cxt-sc-count {
    left: 50%;
    top: -20px;
    transform: translateX(-50%);
  }

  .cxt-sc-header,
  .cxt-sc-subtotal {
    font-size: 18px;
  }

  .cxt-sc-header,
  .cxt-sc-footer {
    padding: 16px;
  }

  .cxt-sc-items {
    padding: 8px 16px;
  }

  .cxt-sc-item {
    grid-template-columns: 60px minmax(0, 1fr);
    gap: 11px;
    padding: 17px 0;
  }

  .cxt-sc-image {
    width: 60px;
    height: 60px;
  }

  .cxt-sc-name {
    font-size: 13px;
  }

  .cxt-sc-variation {
    font-size: 11px;
  }

  .cxt-sc-meta {
    font-size: 11px;
  }

  .cxt-sc-meta-line {
    gap: 8px;
    padding: 5px 7px;
  }

  .cxt-sc-price {
    font-size: 14px;
  }

  .cxt-sc-footer .buttons {
    flex-flow: column;
  }
}

@media (max-width: 380px) {
  .cxt-sidecart.is-open .cxt-sc-panel {
    left: 6%;
    width: 94%;
  }

  .cxt-sidecart.is-open .cxt-sc-trigger {
    right: 94%;
  }

  .cxt-sc-item {
    grid-template-columns: 54px minmax(0, 1fr);
    gap: 9px;
  }

  .cxt-sc-image {
    width: 54px;
    height: 54px;
  }

  .cxt-sc-meta-line {
    grid-template-columns: minmax(0, 1fr) auto;
  }
}

@media (min-width: 992px) {
  .cxt-sc-meta-line > span:last-child {
    /*text-align: right;
    font-weight: 600;*/
    white-space: nowrap;
  }
}

@media (prefers-reduced-motion: reduce) {
  .cxt-sc-panel {
    transition: none;
  }
}