.napoli-current-branch.napoli-checkout__legacy-branch {
  display: none;
}

.napoli-checkout {
  box-sizing: border-box;
  max-width: 1500px;
  margin-inline: auto;
  padding: 32px;
  border-radius: 18px;
  background: #fbf8f3;
  color: #2f2b28;
  font-family: inherit;
}

.napoli-checkout *,
.napoli-checkout *::before,
.napoli-checkout *::after {
  box-sizing: border-box;
}

/* Encabezados del Checkout Napoli */
.napoli-checkout::before,
.napoli-order-type__heading,
.napoli-checkout .wc-block-components-checkout-step__title,
.napoli-checkout .wc-block-components-checkout-order-summary__title {
  font-family: "Playfair Display", serif !important;
}

.napoli-checkout::before {
  display: block;
  margin: 0 0 28px;
  color: #2f2b28;
  content: "Finaliza tu pedido";
  font-family: inherit;
  font-size: clamp(2.625rem, 3.2vw, 3rem);
  font-weight: 700;
  line-height: 1.1;
}

.napoli-checkout .wc-block-components-sidebar-layout {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.78fr) minmax(330px, 1fr);
  gap: 30px;
  align-items: start;
}

.napoli-checkout .wc-block-checkout__main {
  grid-column: 1;
  grid-row: 1;
  width: 100% !important;
  min-width: 0;
  padding: 500px 0 0 !important;
}

.napoli-checkout .wc-block-checkout__sidebar {
  grid-column: 2;
  grid-row: 1;
  position: static !important;
  width: 100% !important;
  min-width: 0;
  padding: 0 !important;
}

.napoli-checkout .wp-block-woocommerce-checkout-order-summary-block {
  overflow: hidden;
  border: 1px solid #e6ded3;
  border-radius: 16px;
  background: #ffffff;
  box-shadow: 0 8px 30px rgba(45, 35, 25, 0.05);
}

.napoli-checkout .wc-block-components-checkout-order-summary__title {
  margin: 0;
  padding: 26px 28px 20px;
  border-bottom: 0;
  color: #2f2b28;
  font-family: inherit;
  font-size: 0;
  font-weight: 700;
  line-height: 1.2;
}

.napoli-checkout .wc-block-components-checkout-order-summary__title[data-napoli-label]::after {
  content: attr(data-napoli-label);
  font-size: 1.65rem;
}

.napoli-checkout .wc-block-components-checkout-order-summary__title-text,
.napoli-checkout .wc-block-components-checkout-order-summary__title-price {
  display: none;
}

.napoli-checkout .wc-block-components-checkout-order-summary__content {
  display: flex;
  flex-direction: column;
  min-height: 0;
}

.napoli-checkout .wc-block-components-checkout-order-summary__content > * {
  margin: 0;
}

.napoli-checkout .wc-block-components-order-summary {
  padding: 0 28px 24px;
}

.napoli-checkout .wc-block-components-order-summary-item {
  padding-block: 14px;
}

.napoli-checkout .wc-block-components-order-summary-item__image {
  width: 70px;
}

.napoli-checkout .wc-block-components-order-summary-item__image img {
  border-radius: 50%;
}

.napoli-checkout .wc-block-components-order-summary-item__description {
  font-family: inherit;
}

.napoli-checkout .wc-block-components-order-summary-item__individual-price,
.napoli-checkout .wc-block-components-order-summary-item__total-price {
  color: #0d7a3a;
  font-weight: 700;
}

.napoli-checkout .wc-block-components-totals-wrapper {
  border-top: 1px solid #e6ded3;
}

.napoli-checkout .wc-block-components-totals-coupon {
  padding: 20px 28px;
}

.napoli-checkout .wc-block-components-totals-coupon-link[data-napoli-label],
.napoli-checkout .wc-block-components-totals-coupon .wc-block-components-panel__button[data-napoli-label] {
  color: #2f2b28;
  font-family: inherit;
  font-size: 0;
  font-weight: 600;
}

.napoli-checkout .wc-block-components-totals-coupon-link[data-napoli-label]::before,
.napoli-checkout .wc-block-components-totals-coupon .wc-block-components-panel__button[data-napoli-label]::after {
  content: attr(data-napoli-label);
  font-size: 0.95rem;
}

.napoli-checkout .wc-block-components-totals-item {
  padding: 14px 28px;
  color: #2f2b28;
  font-family: inherit;
}

.napoli-checkout .wc-block-components-totals-footer-item {
  margin-top: 4px;
  padding-block: 22px;
  border-top: 1px solid #e6ded3;
  font-size: 1.5rem;
  font-weight: 700;
}

.napoli-checkout .wc-block-components-totals-footer-item .wc-block-components-formatted-money-amount {
  color: #d62828;
  font-size: 1.65rem;
}

.napoli-checkout .wc-block-components-totals-wrapper:has(.napoli-order-type) {
  position: absolute;
  top: 0;
  left: 0;
  width: calc((100% - 30px) * 0.64);
  border: 0;
}

.napoli-checkout .wc-block-components-order-meta:has(.napoli-order-type) {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
  padding: 24px;
  border: 1px solid #e6ded3;
  border-radius: 16px;
  background: #ffffff;
  box-shadow: 0 8px 24px rgba(47, 43, 40, 0.045);
}

.napoli-order-type {
  display: contents;
}

.napoli-order-type__heading {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 0;
  color: #2f2b28;
  font-family: inherit;
  font-size: 1.2rem;
  font-weight: 700;
  line-height: 1.3;
  text-transform: uppercase;
}

.napoli-order-type__heading::before,
.napoli-checkout .wc-block-components-checkout-step__title[data-napoli-step]::before {
  display: inline-grid;
  flex: 0 0 32px;
  width: 32px;
  height: 32px;
  place-items: center;
  border-radius: 50%;
  background: #0d7a3a;
  color: #ffffff;
  content: "1";
  font-family: inherit;
  font-size: 0.9rem;
  font-weight: 700;
  line-height: 1;
}

.napoli-order-type__grid {
  display: contents;
}

.napoli-order-type__branch-card,
.napoli-order-type__fieldset,
.napoli-checkout .napoli-order-schedule {
  min-width: 0;
  height: 100%;
  margin: 0 !important;
  padding: 20px 22px !important;
  border: 1px solid #e6ded3;
  border-radius: 13px;
  background: #ffffff;
  box-shadow: none;
}

.napoli-order-type__branch-card {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 10px;
  align-content: start;
}

.napoli-order-type__location-icon {
  display: flex;
  min-height: 25px;
  align-items: center;
  align-self: start;
  color: #d62828;
  font-size: 1.15rem;
  line-height: 1;
}

.napoli-order-type__branch-details {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.napoli-order-type__label,
.napoli-order-type__title,
.napoli-checkout .napoli-order-schedule__title {
  display: flex;
  width: 100%;
  min-height: 40px;
  margin: 0 0 18px !important;
  padding: 0 !important;
  align-items: center;
  color: #2f2b28;
  font-family: inherit;
  font-size: 0.96rem !important;
  font-weight: 600 !important;
  line-height: 1.3 !important;
}

.napoli-checkout .napoli-order-type__fieldset > .napoli-order-type__title {
  float: left;
}

.napoli-checkout .napoli-order-type__fieldset > .napoli-order-type__title + * {
  clear: both;
}

.napoli-checkout .napoli-order-schedule__fieldset {
  min-width: 0;
  margin: 0 !important;
  padding: 0 !important;
  border: 0;
}

.napoli-order-type__branch-details strong {
  margin-bottom: 5px;
  color: #0d7a3a;
  font-size: 1rem;
  font-weight: 700;
  line-height: 1.35;
}

.napoli-order-type__address {
  color: #6f6a65;
  font-size: 0.88rem;
  line-height: 1.55;
}

.napoli-order-type__change-branch {
  grid-column: 1 / -1;
  justify-self: start;
  margin-top: 12px;
  padding: 3px 0;
  border: 0;
  border-bottom: 1px solid currentColor;
  background: transparent;
  color: #0d7a3a;
  cursor: pointer;
  font-family: inherit;
  font-size: 0.88rem;
  font-weight: 700;
}

.napoli-order-type__change-branch:hover {
  color: #075c2b;
}

.napoli-order-type__change-branch:focus-visible {
  border-radius: 3px;
  outline: 2px solid #0d7a3a;
  outline-offset: 3px;
}

.napoli-order-type__fieldset,
.napoli-checkout .napoli-order-schedule__fieldset {
  min-width: 0;
}

.napoli-order-type__options,
.napoli-checkout .napoli-order-schedule__options {
  display: grid;
  grid-template-columns: 1fr;
  gap: 11px;
}

.napoli-order-type__option,
.napoli-checkout .napoli-order-schedule__option {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 50px;
  margin: 0;
  padding: 12px 14px;
  border: 1px solid #e6ded3;
  border-radius: 9px;
  background: #ffffff;
  color: #2f2b28;
  cursor: pointer;
  font-family: inherit;
  transition: border-color 180ms ease, background-color 180ms ease,
    box-shadow 180ms ease, color 180ms ease;
}

.napoli-order-type__option:hover,
.napoli-order-type__option:focus-within,
.napoli-order-type__option.is-selected,
.napoli-checkout .napoli-order-schedule__option:hover,
.napoli-checkout .napoli-order-schedule__option:focus-within,
.napoli-checkout .napoli-order-schedule__option.is-selected {
  border-color: #0d7a3a;
  background: #f4f8f1;
  color: #0d7a3a;
  box-shadow: 0 0 0 1px #0d7a3a;
}

.napoli-order-type__option input,
.napoli-checkout .napoli-order-schedule__option input {
  flex: 0 0 auto;
  margin: 0;
  accent-color: #0d7a3a;
}

.napoli-order-type__fieldset:disabled,
.napoli-checkout .napoli-order-schedule__fieldset:disabled {
  opacity: 0.65;
}

.napoli-checkout .napoli-order-schedule__branch {
  display: none;
}

.napoli-checkout .napoli-order-schedule__estimate,
.napoli-checkout .napoli-order-schedule__notice,
.napoli-order-type__error,
.napoli-checkout .napoli-order-schedule__error {
  margin: 12px 0 0;
  color: #6f6a65;
  font-size: 0.82rem;
  line-height: 1.45;
}

.napoli-order-type__error,
.napoli-checkout .napoli-order-schedule__error {
  color: #b42318;
}

.napoli-checkout .napoli-order-schedule__selectors {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-top: 14px;
}

.napoli-checkout .napoli-order-schedule__field {
  display: grid;
  gap: 6px;
  margin: 0;
  color: #2f2b28;
  font-family: inherit;
  font-size: 0.82rem;
  font-weight: 600;
}

.napoli-checkout .napoli-order-schedule__field select {
  width: 100%;
  min-width: 0;
  min-height: 46px;
  padding: 8px 30px 8px 10px;
  border: 1px solid #e6ded3;
  border-radius: 9px;
  background-color: #ffffff;
  font: inherit;
}

.napoli-checkout .wc-block-checkout__form > .wc-block-components-checkout-step,
.napoli-checkout .wc-block-checkout__order-notes {
  margin: 0 0 16px;
  padding: 26px;
  border: 1px solid #e6ded3;
  border-radius: 15px;
  background: #ffffff;
  box-shadow: 0 6px 20px rgba(47, 43, 40, 0.035);
}

.napoli-checkout .wc-block-components-checkout-step__heading-container {
  margin-bottom: 20px;
}

.napoli-checkout .wc-block-components-checkout-step__title {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 0;
  color: #2f2b28;
  font-family: inherit;
  font-size: 0 !important;
  font-weight: 700;
  line-height: 1.3;
  text-transform: uppercase;
}

.napoli-checkout .wc-block-components-checkout-step__title[data-napoli-step]::before {
  content: attr(data-napoli-step);
}

.napoli-checkout .wc-block-components-checkout-step__title[data-napoli-label]::after {
  content: attr(data-napoli-label);
  font-size: 1.15rem;
}

.napoli-checkout .wc-block-components-address-form {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.napoli-checkout .wc-block-components-address-form > * {
  width: 100%;
  margin: 0;
}

.napoli-checkout .wc-block-components-address-form__country,
.napoli-checkout .wc-block-components-address-form__email,
.napoli-checkout .wc-block-checkout__guest-checkout-notice {
  grid-column: 1 / -1;
}

.napoli-checkout .wc-block-components-text-input input,
.napoli-checkout .wc-blocks-components-select__select,
.napoli-checkout .wc-block-components-textarea {
  min-height: 50px;
  border-color: #e6ded3;
  border-radius: 9px;
  background: #ffffff;
  font-family: inherit;
}

.napoli-checkout .wc-block-components-text-input input:focus,
.napoli-checkout .wc-blocks-components-select__select:focus,
.napoli-checkout .wc-block-components-textarea:focus {
  border-color: #0d7a3a;
  box-shadow: 0 0 0 2px rgba(13, 122, 58, 0.1);
  outline: 0;
}

.napoli-checkout .wc-block-checkout__terms {
  margin: 0 0 16px;
  padding: 18px 22px;
  border: 1px solid #e6ded3;
  border-radius: 12px;
  background: #ffffff;
  color: #2f2b28;
  font-family: inherit;
}

.napoli-checkout .wc-block-checkout__terms a {
  color: #d62828;
}

.napoli-checkout form.wc-block-checkout__form .wc-block-checkout__actions button.wc-block-components-checkout-place-order-button {
  width: 100%;
  min-height: 56px !important;
  border: 1px solid #d62828 !important;
  border-radius: 9px;
  background: #d62828 !important;
  color: #ffffff !important;
  font-family: inherit;
  font-weight: 700;
  transition: background-color 180ms ease, border-color 180ms ease;
}

.napoli-checkout form.wc-block-checkout__form .wc-block-checkout__actions .wc-block-components-button__text[data-napoli-label] {
  font-size: 0;
}

.napoli-checkout form.wc-block-checkout__form .wc-block-checkout__actions .wc-block-components-button__text[data-napoli-label]::after {
  content: attr(data-napoli-label);
  font-size: 1rem;
}

.napoli-checkout form.wc-block-checkout__form .wc-block-checkout__actions button.wc-block-components-checkout-place-order-button:hover {
  border-color: #b91f24 !important;
  background: #b91f24 !important;
  color: #ffffff !important;
}

.napoli-checkout form.wc-block-checkout__form .wc-block-checkout__actions button.wc-block-components-checkout-place-order-button:focus-visible {
  outline: 3px solid rgba(13, 122, 58, 0.35);
  outline-offset: 3px;
}

@media (max-width: 1400px) {
  .napoli-checkout {
    padding: 24px;
  }

  .napoli-checkout .wc-block-components-sidebar-layout {
    display: flex;
    flex-direction: column;
    gap: 0;
    padding-top: 500px;
  }

  .napoli-checkout .wc-block-checkout__main,
  .napoli-checkout .wc-block-checkout__form {
    display: contents;
  }

  .napoli-checkout .wc-block-checkout__sidebar {
    display: block;
    order: 7;
    width: 100% !important;
    margin-bottom: 16px;
  }

  .napoli-checkout .wp-block-woocommerce-checkout-order-summary-block,
  .napoli-checkout .wc-block-components-checkout-order-summary__content {
    position: static !important;
    width: 100% !important;
    height: auto !important;
    max-height: none !important;
    visibility: visible !important;
    opacity: 1 !important;
    transform: none !important;
  }

  .napoli-checkout .wc-block-components-checkout-order-summary__content {
    display: flex !important;
  }

  .napoli-checkout .wc-block-components-totals-wrapper:has(.napoli-order-type) {
    position: absolute;
    top: 0;
    left: 0;
    z-index: 1;
    width: 100%;
  }

  .napoli-checkout .wc-block-components-order-meta:has(.napoli-order-type) {
    width: 100%;
    margin-bottom: 16px;
  }

  .napoli-checkout .wc-block-checkout__form > * {
    order: 20;
    width: 100% !important;
    max-width: none !important;
  }

  .napoli-checkout #contact-fields {
    order: 2;
  }

  .napoli-checkout #billing-fields {
    order: 3;
  }

  .napoli-checkout #payment-method {
    order: 4;
  }

  .napoli-checkout .wc-block-checkout__order-notes {
    order: 5;
  }

  .napoli-checkout .wc-block-checkout__terms {
    order: 6;
  }

  .napoli-checkout .wc-block-checkout__actions {
    order: 8;
  }

}

@media (max-width: 700px) {
  .napoli-checkout {
    padding: 16px;
    border-radius: 14px;
  }

  .napoli-checkout::before {
    margin-bottom: 22px;
    font-size: clamp(1.75rem, 8vw, 2rem);
  }

  .napoli-checkout .wc-block-components-sidebar-layout {
    padding-top: 1000px;
  }

  .napoli-checkout .wc-block-components-order-meta:has(.napoli-order-type),
  .napoli-checkout .wc-block-components-address-form,
  .napoli-checkout .napoli-order-schedule__selectors {
    grid-template-columns: 1fr;
  }

  .napoli-order-type__heading {
    grid-column: auto;
  }

  .napoli-order-type__label,
  .napoli-order-type__title,
  .napoli-checkout .napoli-order-schedule__title {
    min-height: 25px;
  }

  .napoli-order-type__branch-card,
  .napoli-order-type__fieldset,
  .napoli-checkout .napoli-order-schedule,
  .napoli-checkout .wc-block-checkout__form > .wc-block-components-checkout-step,
  .napoli-checkout .wc-block-checkout__order-notes {
    padding: 20px;
  }

  .napoli-checkout .wc-block-components-checkout-order-summary__title,
  .napoli-checkout .wc-block-components-order-summary,
  .napoli-checkout .wc-block-components-totals-coupon,
  .napoli-checkout .wc-block-components-totals-item {
    padding-inline: 20px;
  }
}

@media (max-width: 400px) {
  .napoli-checkout .wc-block-components-sidebar-layout {
    padding-top: 1030px;
  }
}

@media (min-width: 701px) and (max-width: 900px) {
  .napoli-checkout .wc-block-components-sidebar-layout {
    padding-top: 900px;
  }

  .napoli-checkout .wc-block-components-order-meta:has(.napoli-order-type) {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .napoli-checkout .napoli-order-schedule {
    grid-column: 1 / -1;
  }
}
