/* ステップナビ */
.cart-navi ul {
  display: flex;
  border: 1px solid #d1d5db;
  border-radius: 4px;
  overflow: hidden;
  text-align: center;
  font-size: 0.875rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.cart-navi li {
  flex: 1;
  padding: 0.75rem 0;
  border-left: 1px solid #d1d5db;
  color: #9ca3af;
}

.cart-navi li:first-child {
  border-left: none;
}

.cart-navi li.current {
  background-color: #166534;
  color: #fff;
  font-weight: bold;
}

@media screen and (max-width: 480px) {
  .cart-navi ul {
    flex-direction: column;
  }

  .cart-navi li {
    border-left: none;
    border-top: 1px solid #d1d5db;
  }

  .cart-navi li:first-child {
    border-top: none;
  }
}

/* （税込）の斜体解除 */
.cart-content em,
#cart_completion em,
#info-confirm em {
  font-style: normal !important;
}

/* カートテーブル：Welcart が出力する行 */
#cart_table tbody td {
  padding: 0.75rem 0.5rem;
  vertical-align: middle;
}

#cart_table tbody tr:last-child {
  border-bottom: none;
}

/* サムネイル画像 */
#cart_table .thumbnail img {
  width: 80px;
  height: auto;
  border-radius: 4px;
}

/* 数量 input */
#cart_table .quantity input {
  width: 60px;
  padding: 0.4rem 0.25rem;
  border: 1px solid #aaa;
  border-radius: 4px;
  text-align: center;
  font-size: 0.875rem;
  background-color: #fff;
  appearance: textfield;
  -moz-appearance: textfield;
}

#cart_table .quantity input:focus {
  outline: 2px solid #166534;
  outline-offset: 1px;
  border-color: #166534;
}

#cart_table .quantity input::-webkit-inner-spin-button,
#cart_table .quantity input::-webkit-outer-spin-button {
  opacity: 1;
}

/* 削除ボタン */
#cart .action input.delButton {
  padding: 0.25rem 0.75rem;
  font-size: 0.75rem;
  background-color: #e5e7eb;
  border: none;
  border-radius: 4px;
  cursor: pointer;
}

#cart .action input.delButton:hover {
  background-color: #d1d5db;
}

/* 送信ボタン（Welcart 出力） */
.send {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0.5rem;
  margin-top: 2rem;
}

.send input[type="submit"],
.send input[type="button"] {
  padding: 0.75rem 2rem;
  background-color: #166534;
  color: #fff;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  font-size: 0.875rem;
}

@media screen and (max-width: 480px) {
  .send input[type="submit"],
  .send input[type="button"] {
    padding: 0.75rem 0.75rem;
  }
}

.send input[type="submit"]:hover,
.send input[type="button"]:hover {
  background-color: #14532d;
}

.send a {
  display: inline-block;
  padding: 0.75rem 2rem;
  background-color: #e5e7eb;
  border-radius: 4px;
  font-size: 0.875rem;
  text-decoration: none;
  color: #374151;
}

.send a:hover {
  background-color: #d1d5db;
}

/* お客様情報・配送・確認ページ共通 */
.cart_page_title {
  display: none;
}

.cart_navi,
.usccart_navi {
  display: none;
}

.customer_form {
  width: 100%;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
  border-collapse: collapse;
}

.customer_form,
.customer_form tbody,
.customer_form tr,
.customer_form th,
.customer_form td {
  display: block;
  width: 100%;
}

.customer_form tr {
  border-top: 1px solid #e5e7eb;
}

.customer_form th {
  padding: 0.75rem 0.5rem 0;
  text-align: left;
  font-weight: bold;
  white-space: nowrap;
  font-size: 0.875rem;
}

.customer_form td {
  padding: 0.25rem 0.5rem 0.75rem;
  font-size: 0.875rem;
}

@media screen and (min-width: 38.75em) {
  .customer_form {
    display: table;
    width: 100%;
  }

  .customer_form tbody {
    display: table-row-group;
  }

  .customer_form tr {
    display: table-row;
    border-top: none;
    border-bottom: 1px solid #e5e7eb;
  }

  .customer_form th {
    display: table-cell;
    width: 1%;
    white-space: nowrap;
    padding: 0.75rem 0.5rem;
    vertical-align: top;
  }

  .customer_form td {
    display: table-cell;
    width: auto;
    padding: 0.75rem 0.5rem;
  }
}

.customer_form input[type="text"],
.customer_form input[type="password"],
.customer_form input[type="email"],
.customer_form select,
.customer_form textarea {
  width: 100%;
  padding: 0.5rem;
  border: 1px solid #aaa;
  border-radius: 4px;
  font-size: 0.875rem;
  background-color: #fff;
}

.customer_form input:focus,
.customer_form select:focus,
.customer_form textarea:focus {
  outline: 2px solid #166534;
  outline-offset: 1px;
  border-color: #166534;
}

.customer_form em {
  color: #dc2626;
  font-style: normal;
  margin-right: 0.25rem;
}

/* 確認ページ */
#info-confirm {
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
}

#info-confirm #cart_table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.875rem;
}

#info-confirm #cart_table thead tr {
  border-bottom: 2px solid #d1d5db;
  background-color: #f9fafb;
}

#info-confirm #cart_table thead th {
  padding: 0.75rem 0.5rem;
  font-size: 0.8rem;
  white-space: nowrap;
}

#info-confirm #cart_table thead .num {
  text-align: center;
}

#info-confirm #cart_table thead .productname {
  text-align: left;
}

#info-confirm #cart_table thead .price,
#info-confirm #cart_table thead .subtotal {
  text-align: right;
}

#info-confirm #cart_table thead .quantity {
  text-align: center;
}

#info-confirm #cart_table tbody td {
  padding: 0.75rem 0.5rem;
  vertical-align: middle;
  border-bottom: 1px solid #e5e7eb;
}

#info-confirm #cart_table tbody .num {
  text-align: center;
}

#info-confirm #cart_table tbody .aright {
  text-align: right;
}

#info-confirm #cart_table tbody .thumbnail img {
  width: 64px;
  height: auto;
  border-radius: 4px;
}

#info-confirm #cart_table tfoot th,
#info-confirm #cart_table tfoot td {
  padding: 0.75rem 0.5rem;
  border-bottom: 1px solid #e5e7eb;
}

#info-confirm #cart_table tfoot .aright {
  text-align: right;
}

#info-confirm #cart_table tfoot .amount {
  font-size: 1.1rem;
  font-weight: bold;
  color: #166534;
}

#info-confirm #cart_table tfoot tr:last-child th,
#info-confirm #cart_table tfoot tr:last-child td {
  border-bottom: 2px solid #d1d5db;
}

#confirm_table {
  width: 100%;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
  border-collapse: collapse;
}

#confirm_table,
#confirm_table tbody,
#confirm_table tr,
#confirm_table th,
#confirm_table td {
  display: block;
  width: 100%;
}

#confirm_table tr {
  border-top: 1px solid #e5e7eb;
}

#confirm_table th {
  padding: 0.75rem 0.5rem 0;
  text-align: left;
  font-weight: bold;
  white-space: nowrap;
  font-size: 0.875rem;
}

#confirm_table td {
  padding: 0.25rem 0.5rem 0.75rem;
  font-size: 0.875rem;
}

@media screen and (min-width: 38.75em) {
  #confirm_table {
    display: table;
    width: 100%;
  }

  #confirm_table tbody {
    display: table-row-group;
  }

  #confirm_table tr {
    display: table-row;
    border-top: none;
    border-bottom: 1px solid #e5e7eb;
  }

  #confirm_table th {
    display: table-cell;
    width: 1%;
    white-space: nowrap;
    padding: 0.75rem 0.5rem;
    vertical-align: top;
  }

  #confirm_table td {
    display: table-cell;
    width: auto;
    padding: 0.75rem 0.5rem;
  }
}

#confirm_table .ttl td {
  padding-top: 1.5rem;
  border-bottom: none;
  border-top: none;
}

#confirm_table .ttl h3 {
  font-size: 1rem;
  font-weight: bold;
  margin: 0;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid #166534;
}

.confiem_notice {
  padding: 0.75rem 1rem;
  background-color: #fef3c7;
  border: 1px solid #f59e0b;
  border-radius: 4px;
  font-size: 0.875rem;
  margin-bottom: 1.5rem;
}

/* 購入ボタン */
#info-confirm .send {
  text-align: center;
  margin-top: 2rem;
}

#info-confirm .send input[type="submit"] {
  padding: 1rem 3rem;
  background-color: #166534;
  color: #fff;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  font-size: 1rem;
  font-weight: bold;
}

#info-confirm .send input[type="submit"]:hover {
  background-color: #14532d;
}

/* ポイントテーブル */
#point_table {
  width: 100%;
  max-width: 400px;
  margin: 1rem auto;
  border-collapse: collapse;
  font-size: 0.875rem;
}

#point_table td {
  padding: 0.5rem;
}

#point_table .point {
  font-weight: bold;
  font-size: 1.1rem;
  color: #166534;
}

.header_explanation {
  margin-bottom: 0.75rem;
}

.footer_explanation {
  margin-top: 1.5rem;
}

.error_message {
  color: #dc2626;
  font-weight: bold;
  margin-bottom: 1rem;
}

.no_cart {
  text-align: center;
  font-size: 1.125rem;
  padding: 3rem 0;
  color: #6b7280;
}

.currency_code {
  font-size: 0.75rem;
  color: #6b7280;
  margin-top: 0.5rem;
}

/* 完了ページ */
#cart_completion h3 {
  font-size: 1.125rem;
  font-weight: bold;
  margin-bottom: 0.75rem;
}

#cart_completion .header_explanation p {
  line-height: 1.8;
}
