.twh-reorder-instructions { line-height: 1.8; color: #756550; }
#twh-reorder-confirmation[hidden] { display: none !important; }
.twh-order-number { display: block; overflow-wrap: anywhere; font-size: .85rem; }
.twh-order-number-label { display: inline-block; font-weight: 700; }
.twh-order-products { list-style: none !important; padding: 0 !important; margin: 12px 0 0 !important; }
.twh-order-product { display: flex; gap: 10px; align-items: flex-start; padding: 14px 0; margin: 0 !important; border-top: 1px solid #e4d5bc; font-weight: 400; text-align: left; }
.twh-order-product-image { flex: 0 0 48px; }
.twh-order-product-image img { width: 48px; height: 48px; object-fit: contain; border-radius: 6px; }
.twh-order-product-info { flex: 1; min-width: 0; }
.twh-order-product-purchase { flex: 0 0 auto; max-width: 45%; align-self: center; }
.twh-order-product-purchase .twh-reorder-price { white-space: nowrap; }
.woocommerce-orders .twh-order-product-purchase .twh-reorder-submit {
  width: auto; min-width: 0; white-space: nowrap; padding: 9px 14px;
}
.twh-order-product-name { display: block; font-weight: 600; overflow-wrap: anywhere; line-height: 1.6; }
.twh-order-product small, .twh-order-item-action small { display: block; margin: 4px 0; color: #756550; font-size: .8rem; line-height: 1.6; }
.twh-order-product .twh-reorder-unavailable, .twh-order-item-action .twh-reorder-unavailable { color: #815423; }
.twh-reorder-form { margin: 8px 0 0; }
.twh-reorder-form .twh-reorder-submit { white-space: normal; line-height: 1.5; margin: 0; padding: 9px 14px; font-size: .85rem; }
.twh-reorder-submit:disabled { opacity: .65; cursor: wait; }
.twh-order-item-action { margin-top: 10px; }
.woocommerce-orders-table__header-order-number, .woocommerce-orders-table__cell-order-number { width: 44%; min-width: 200px; }
/* Keep each order together, with a visible gap and alternating honey tones. */
.woocommerce-orders table.woocommerce-orders-table {
  width: 100%; border: 0; border-collapse: separate; border-spacing: 0 16px;
}
.woocommerce-orders .woocommerce-orders-table tr.order { --twh-order-surface: #fffbf3; }
.woocommerce-orders .woocommerce-orders-table tr.order:nth-child(even) { --twh-order-surface: #f7e6c5; }
.woocommerce-orders .woocommerce-orders-table tr.order > th,
.woocommerce-orders .woocommerce-orders-table tr.order > td {
  padding: 18px 12px; vertical-align: top; color: #49301a;
  background: var(--twh-order-surface);
  border: 0; border-top: 2px solid #caa76d; border-bottom: 2px solid #caa76d;
}
.woocommerce-orders .woocommerce-orders-table tr.order > :first-child {
  border-left: 2px solid #caa76d; border-radius: 12px 0 0 12px;
}
.woocommerce-orders .woocommerce-orders-table tr.order > :last-child {
  border-right: 2px solid #caa76d; border-radius: 0 12px 12px 0;
}
@media (max-width: 1000px) {
  .woocommerce-orders table.woocommerce-orders-table { border-spacing: 0; }
  .woocommerce-orders .woocommerce-orders-table thead { display: none; }
  .woocommerce-orders .woocommerce-orders-table tbody { display: block; }
  .woocommerce-orders .woocommerce-orders-table tr.order {
    display: block; margin-bottom: 24px; border: 2px solid #caa76d;
    border-radius: 12px; overflow: hidden; background: var(--twh-order-surface);
  }
  .woocommerce-orders .woocommerce-orders-table tr.order > th,
  .woocommerce-orders .woocommerce-orders-table tr.order > td {
    display: block; width: 100%; min-width: 0; box-sizing: border-box;
    padding: 10px 18px; border: 0; border-radius: 0; text-align: left !important;
  }
  .woocommerce-orders .woocommerce-orders-table tr.order > :first-child { padding-top: 18px; }
  .woocommerce-orders .woocommerce-orders-table tr.order > :last-child { padding-bottom: 18px; }
  .woocommerce-orders .woocommerce-orders-table tr.order > td::before { content: attr(data-title) '：'; font-weight: 600; float: none; margin-right: 8px; }
  .woocommerce-orders .woocommerce-orders-table tr.order > .woocommerce-orders-table__cell-order-number::before { display: none; }
  .woocommerce-orders .woocommerce-orders-table tr.order > .woocommerce-orders-table__cell-order-actions {
    display: flex; flex-wrap: wrap; align-items: center; gap: 8px;
  }
  .woocommerce-orders .woocommerce-orders-table tr.order > .woocommerce-orders-table__cell-order-actions::before { margin-right: 4px; }
  .twh-order-product { padding: 12px 0; }
}
.woocommerce-orders .woocommerce-orders-table .woocommerce-orders-table__cell-order-actions .button {
  display: inline-flex; width: auto; min-width: 0; flex: 0 0 auto;
  margin: 4px 6px 4px 0; padding: 9px 16px; white-space: nowrap;
}
@media (max-width: 480px) {
  .woocommerce-orders .twh-order-product { flex-wrap: wrap; }
  .woocommerce-orders .twh-order-product-info { flex: 1 1 calc(100% - 58px); }
  .woocommerce-orders .twh-order-product-purchase { flex: 1 1 calc(100% - 58px); max-width: none; margin-left: 58px; }
}
