.cart-header {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;

  h1 { margin: 0; }
}

.cart-container {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.cart-item {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 10px;
  border: 1px solid var(--color-neutral-200);
  border-radius: var(--border-radius);
  background: var(--color-neutral-0);

  .cart-thumbnail {
    position: relative;

    .plant-thumbnail {
      height: 50px;
      width: 62.5px;
      object-fit: cover;
      overflow: hidden;
      border-radius: var(--border-radius);
    }

    .whishlist-toggle {
      position: absolute;
      top: 4px;
      left: 4px;

      i {
        cursor: pointer;
        padding: 4px;
        font-size: 12px;
        background: var(--color-green-light);
        border-radius: var(--border-radius);
        color: var(--color-green-dark);
        opacity: .7;

        &:hover,
        &.fa-solid { opacity: 1; }
      }
    }
  }

  .cart-details {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 5px;
  }

  .cart-plant-availability i {
    font-size: 24px;
    &.fa-ban { color: var(--color-red); }
    &.fa-triangle-exclamation { color: var(--color-yellow); }
  }

  .cart-quantity-confirmation {
    font-weight: bold;
  }

  .cart-quantity {
    display: flex;
    align-items: center;
    gap: 10px;

    .quantity-controls {
      display: flex;
      align-items: center;
      border: 1px solid var(--color-neutral-200);
      border-radius: var(--border-radius);
      padding: 0 4px;

      i {
        padding: 10px;

        &.fa-minus:hover { color: var(--color-red); }
        &.fa-plus:hover { color: var(--color-green); }

        &.unavailable {
          color: var(--color-neutral-200);
          pointer-events: none;
        }
      }

      .quantity-input {
        width: 40px;
        text-align: center;
        border: none;
        outline: none;
        font-size: 16px;
      }
    }

    .fa-trash-can {
      color: var(--color-red);
      &:hover { color: var(--color-red-dark); }
    }
  }
}

.form-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.cart-column {
  flex: 1;
  max-width: 33%;
}

.all-row-column {
  flex: 0 0 100%;
  max-width: 100%;
}

@media (max-width: 768px) {
  .cart-column {
    flex: 0 0 100%;
    max-width: 100%;
  }

  .cart-quantity {
    width: 100%;
  }
}

.control-label {
  width: 250px;
  display: block;
  margin-bottom: 5px;
  font-weight: bold;
}

.all-row-label {
  width: auto;
}

.form-control {
  flex: 1;
  width: 100%;
  padding: 10px;
  border: 1px solid var(--color-neutral-200);
  border-radius: var(--border-radius);
  min-width: 200px;
}

.choices::after {
  display: none;
}

.form-control-div {
  flex: 1;
}

.checkbox-label {
  display: flex;
  align-items: center;
}

.delivery-container {
  display: flex;
  margin-bottom: 20px;
}

.delivery-choices {
  flex: 1;
  border-right: 1px solid var(--color-neutral-200);
  padding-right: 20px;
}

.delivery-choice {
  cursor: pointer;
  border-radius: var(--border-radius);
  padding: 10px;

  h3 {
    font-weight: bold;
    margin: 0 0 5px;
  }
}

.delivery-choice p {
  margin: 5px 0;
}

.delivery-choice.selected {
  background-color: var(--color-green);
  border-color: var(--color-green);
  color: var(--color-neutral-0);
}

.delivery-choice.grayed-out {
  background-color: var(--color-neutral-100);
  color: var(--color-neutral-300);
}

.disabled, .disabled * {
  opacity: 0.9;
  pointer-events: none;
}

.delivery-details {
  flex: 2;
  padding-left: 20px;

  h3 {
    margin: 0;
    padding: 0 10px 15px;
  }

  .form-group,
  .form-row { display: block; }
}

.delivery-form {
  display: none;
}

.delivery-form.active {
  display: block;
}

@media (max-width: 768px) {
  .delivery-container {
    flex-direction: column;
  }

  .delivery-choices {
    border-right: none;
    border-bottom: 1px solid var(--color-neutral-200);
    padding-right: 0;
    margin-bottom: 20px;
  }

  .delivery-details {
    padding-left: 0;
  }
}

.hint {
  font-size: 0.875em;
  color: var(--color-neutral-300);
  margin-top: 5px;
}

.order-header {
  margin-bottom: 20px;
}

.order-info {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.order-info-item {
  display: flex;
  width: 100%;
}

.order-info-label {
  font-weight: bold;
  width: 150px;
}

.order-info-value {
  flex: 1;
}

.new_order {
  margin-top: 10px;

  .cart-container + & .form-row { justify-content: flex-end; }

  .btn {
    font-size: 14px;
    padding: 10px 20px;
  }
}

.autocomplete-results {
  border: 1px solid var(--color-neutral-200);
  max-height: 200px;
  overflow-y: auto;
  background-color: var(--color-neutral-0);
  position: absolute;
  z-index: 1000;
  width: 100%;
}

.autocomplete-result {
  padding: 10px;
  cursor: pointer;
}

.autocomplete-result:hover {
  background-color: var(--color-neutral-100);
}

.totals-container {
  display: flex;
  flex-direction: column;
  width: 100%;
  margin-top: 20px;
}

.totals-row {
  display: flex;
  justify-content: space-between;
  padding: 10px 0;
}

.totals-cell {
  flex: 1;
}

.totals-cell.text {
  text-align: right;
}

.totals-cell.number {
  text-align: right;
  max-width: 100px;
}
.totals-cell.number.totals {
  font-weight: bold;
}

.totals-horizontal-line {
  border-top: 1px solid var(--color-neutral-200);
  margin: 10px 0;
}

.right {
  text-align: right;
}

/* Gift Card — Orderer Info Section */
.orderer-info-section {
  padding-bottom: 20px;
  margin-bottom: 20px;
  border-bottom: 1px solid var(--color-neutral-200);

  h3 { margin: 0 0 5px; }
}

/* Gift Card Preview */
.gift-card-preview-form {
  display: none !important;
  visibility: hidden;
  position: absolute;
  left: -9999px;
  width: 0;
  height: 0;
}

.gift-card-preview-image {
  border-radius: 8px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.gift-card-preview-container {
  padding: 20px;
  text-align: center;
}
