/* ============================================================
   CorfuDiscovery - WooCommerce public pages
   Cart, checkout, login/register and password reset.
   Loads after styles.css + pages.css.
   ============================================================ */

.cdf-woocommerce-page {
  background: var(--sand);
}

.cdf-woo-section {
  padding-block: clamp(38px, 5vw, 74px);
}

.cdf-woo-shell {
  max-width: 1180px;
  margin: 0 auto;
  color: var(--ink);
}

.cdf-woo-shell .woocommerce {
  width: 100%;
}

.cdf-woo-shell .woocommerce::before,
.cdf-woo-shell .woocommerce::after {
  content: "";
  display: table;
  clear: both;
}

.cdf-woo-shell a {
  color: var(--coral);
  font-weight: 700;
}

.cdf-woo-shell h2,
.cdf-woo-shell h3,
.cdf-woo-shell .cart_totals h2,
.cdf-woo-shell #order_review_heading {
  font-family: var(--serif);
  color: var(--navy);
  font-weight: 500;
  letter-spacing: 0;
}

.cdf-woo-shell h2 {
  margin: 0 0 20px;
  font-size: clamp(26px, 3vw, 36px);
}

.cdf-woo-shell h3,
.cdf-woo-shell .cart_totals h2,
.cdf-woo-shell #order_review_heading {
  margin: 0 0 18px;
  font-size: clamp(22px, 2.2vw, 30px);
}

.cdf-woo-shell p {
  color: var(--body);
}

.cdf-woo-shell .woocommerce-notices-wrapper:not(:empty),
.cdf-woo-shell .woocommerce-form-coupon-toggle,
.cdf-woo-shell .woocommerce-form-login-toggle {
  margin: 0 0 18px;
}

.cdf-woo-shell .woocommerce-info,
.cdf-woo-shell .woocommerce-message,
.cdf-woo-shell .woocommerce-error,
.cdf-woo-shell .wc-block-components-notice-banner {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin: 0 0 18px;
  padding: 16px 18px;
  border: 1px solid var(--line);
  border-left: 4px solid var(--coral);
  border-radius: var(--r);
  background: #fff;
  box-shadow: var(--shadow-sm);
  color: var(--body);
  font-size: 15px;
  line-height: 1.55;
}

.cdf-woo-shell .woocommerce-error {
  border-left-color: #B42318;
  list-style: none;
}

.cdf-woo-shell .woocommerce-message {
  border-left-color: #1F9D67;
}

.cdf-woo-shell .woocommerce-message::before,
.cdf-woo-shell .woocommerce-info::before,
.cdf-woo-shell .woocommerce-error::before {
  display: none;
}

.cdf-woo-shell .woocommerce-error li {
  margin: 0;
}

.cdf-woo-shell .button,
.cdf-woo-shell button.button,
.cdf-woo-shell input.button,
.cdf-woo-shell .woocommerce-button,
.cdf-woo-shell .checkout-button,
.cdf-woo-shell .wc-block-cart__submit-button,
.cdf-woo-shell .wc-block-components-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 13px 23px;
  border: 0;
  border-radius: var(--pill);
  background: var(--coral);
  color: #fff;
  box-shadow: var(--shadow-coral);
  font-family: var(--sans);
  font-size: 15.5px;
  font-weight: 800;
  line-height: 1.15;
  text-align: center;
  text-decoration: none;
  transition: transform .18s ease, background .18s ease, box-shadow .18s ease;
}

.cdf-woo-shell .button:hover,
.cdf-woo-shell button.button:hover,
.cdf-woo-shell input.button:hover,
.cdf-woo-shell .woocommerce-button:hover,
.cdf-woo-shell .checkout-button:hover,
.cdf-woo-shell .wc-block-cart__submit-button:hover,
.cdf-woo-shell .wc-block-components-button:hover {
  background: var(--coral-deep);
  color: #fff;
  transform: translateY(-1px);
}

.cdf-woo-shell .button:disabled,
.cdf-woo-shell .button.disabled,
.cdf-woo-shell button.button:disabled,
.cdf-woo-shell input.button:disabled {
  opacity: .55;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.cdf-woo-shell input[type="text"],
.cdf-woo-shell input[type="email"],
.cdf-woo-shell input[type="tel"],
.cdf-woo-shell input[type="password"],
.cdf-woo-shell input[type="number"],
.cdf-woo-shell textarea,
.cdf-woo-shell select,
.cdf-woo-shell .select2-container--default .select2-selection--single,
.cdf-woo-shell .wc-block-components-text-input input,
.cdf-woo-shell .wc-block-components-combobox .wc-block-components-combobox-control input.components-combobox-control__input,
.cdf-woo-shell .wc-block-components-form .wc-block-components-text-input input[type="text"],
.cdf-woo-shell .wc-block-components-form .wc-block-components-text-input input[type="email"],
.cdf-woo-shell .wc-block-components-form .wc-block-components-text-input input[type="tel"] {
  width: 100%;
  min-height: 50px;
  border: 1.5px solid var(--line-strong);
  border-radius: var(--r);
  background: var(--sand);
  color: var(--ink);
  padding: 13px 15px;
  font-family: var(--sans);
  font-size: 15.5px;
  font-weight: 600;
  outline: none;
  transition: border-color .16s ease, background .16s ease, box-shadow .16s ease;
}

.cdf-woo-shell textarea {
  min-height: 120px;
  resize: vertical;
}

.cdf-woo-shell .select2-container--default .select2-selection--single {
  display: flex;
  align-items: center;
}

.cdf-woo-shell .select2-container--default .select2-selection--single .select2-selection__rendered {
  color: var(--ink);
  padding: 0;
  line-height: 1.3;
}

.cdf-woo-shell input:focus,
.cdf-woo-shell textarea:focus,
.cdf-woo-shell select:focus,
.cdf-woo-shell .select2-container--open .select2-selection--single,
.cdf-woo-shell .wc-block-components-text-input input:focus {
  border-color: var(--coral);
  background: #fff;
  box-shadow: 0 0 0 4px var(--coral-soft);
}

.cdf-woo-shell label,
.cdf-woo-shell .form-row label,
.cdf-woo-shell .wc-block-components-text-input label {
  display: block;
  margin: 0 0 7px;
  color: var(--ink);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: .03em;
}

.cdf-woo-shell .required {
  color: var(--coral);
}

.cdf-woo-shell .form-row {
  margin: 0 0 16px;
  padding: 0;
}

.cdf-woo-shell .form-row-first,
.cdf-woo-shell .form-row-last {
  width: calc(50% - 8px);
}

.cdf-woo-shell .form-row-first {
  float: left;
}

.cdf-woo-shell .form-row-last {
  float: right;
}

.cdf-woo-shell .clear {
  clear: both;
}

.cdf-woo-shell input[type="checkbox"],
.cdf-woo-shell input[type="radio"],
.cdf-woo-shell .input-checkbox {
  width: 18px;
  height: 18px;
  margin: 0 8px 0 0;
  accent-color: var(--coral);
}

/* Login, register and reset password */
.cdf-woo-shell #customer_login {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(20px, 3vw, 32px);
  align-items: stretch;
}

.cdf-woo-shell #customer_login::before,
.cdf-woo-shell #customer_login::after {
  display: none;
}

.cdf-woo-shell #customer_login .u-column1,
.cdf-woo-shell #customer_login .u-column2,
.cdf-woo-shell .woocommerce-ResetPassword,
.cdf-woo-shell .lost_reset_password,
.cdf-woo-shell .woocommerce-form-login,
.cdf-woo-shell .woocommerce-form-register,
.cdf-woo-shell .woocommerce-form-coupon,
.cdf-woo-shell .woocommerce-form-coupon-toggle + .woocommerce-form-coupon {
  float: none;
  width: 100%;
  min-width: 0;
  padding: clamp(24px, 3.2vw, 38px);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  background: #fff;
  box-shadow: var(--shadow);
}

.cdf-woo-shell #customer_login .woocommerce-form-login,
.cdf-woo-shell #customer_login .woocommerce-form-register {
  padding: 0;
  border: 0;
  border-radius: 0;
  box-shadow: none;
}

.cdf-woo-shell .lost_reset_password,
.cdf-woo-shell .woocommerce-ResetPassword {
  max-width: 640px;
  margin: 0 auto;
}

.cdf-woo-shell .woocommerce-form-login__rememberme,
.cdf-woo-shell .woocommerce-form__label-for-checkbox,
.cdf-woo-shell .woocommerce-privacy-policy-text,
.cdf-woo-shell .lost_password {
  font-size: 14.5px;
  color: var(--body);
}

.cdf-woo-shell .woocommerce-form-login__rememberme,
.cdf-woo-shell .woocommerce-form__label-for-checkbox {
  display: inline-flex;
  align-items: center;
  margin: 0 0 14px;
  letter-spacing: 0;
  font-weight: 700;
}

.cdf-woo-shell .woocommerce-LostPassword {
  margin: 14px 0 0;
}

/* Cart */
.cdf-woo-shell .woocommerce-cart-form,
.cdf-woo-shell .cart-collaterals .cart_totals,
.cdf-woo-shell .wc-block-cart,
.cdf-woo-shell .wp-block-woocommerce-cart {
  min-width: 0;
}

.cdf-woo-shell .woocommerce-cart-form {
  margin-bottom: 26px;
}

.cdf-woo-shell table.shop_table,
.cdf-woo-shell .woocommerce-checkout-review-order-table,
.cdf-woo-shell .wc-block-cart-items,
.cdf-woo-shell .wc-block-components-totals-wrapper {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  background: #fff;
  box-shadow: var(--shadow-sm);
}

.cdf-woo-shell table.shop_table th,
.cdf-woo-shell table.shop_table td,
.cdf-woo-shell .wc-block-cart-items th,
.cdf-woo-shell .wc-block-cart-items td {
  padding: 18px;
  border: 0;
  border-bottom: 1px solid var(--line);
  vertical-align: middle;
  color: var(--body);
}

.cdf-woo-shell table.shop_table thead th,
.cdf-woo-shell .wc-block-cart-items thead th {
  background: var(--sand-2);
  color: var(--navy);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: .1em;
  text-transform: uppercase;
}

.cdf-woo-shell table.shop_table tr:last-child td,
.cdf-woo-shell table.shop_table tr:last-child th,
.cdf-woo-shell .wc-block-cart-items tr:last-child td {
  border-bottom: 0;
}

.cdf-woo-shell .product-thumbnail img,
.cdf-woo-shell .wc-block-cart-item__image img {
  width: 84px;
  height: 68px;
  object-fit: cover;
  border-radius: var(--r-sm);
  background: var(--sand-2);
}

.cdf-woo-shell .product-name,
.cdf-woo-shell .wc-block-cart-item__product {
  color: var(--ink);
  font-weight: 800;
}

.cdf-woo-shell .product-name a,
.cdf-woo-shell .wc-block-cart-item__product a {
  color: var(--ink);
}

.cdf-woo-shell .product-price,
.cdf-woo-shell .product-subtotal,
.cdf-woo-shell .amount {
  color: var(--navy);
  font-weight: 800;
}

.cdf-woo-shell .quantity .qty {
  width: 82px;
  min-height: 44px;
  text-align: center;
  padding-inline: 10px;
}

.cdf-woo-shell .product-remove .remove,
.cdf-woo-shell a.remove {
  display: inline-grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: #fff;
  color: var(--coral);
  font-size: 22px;
  line-height: 1;
  text-decoration: none;
}

.cdf-woo-shell .product-remove .remove:hover,
.cdf-woo-shell a.remove:hover {
  background: var(--coral);
  color: #fff;
}

.cdf-woo-shell table.cart td.actions {
  background: var(--sand-2);
}

.cdf-woo-shell .coupon {
  display: flex;
  gap: 10px;
  align-items: center;
  max-width: 520px;
  float: left;
}

.cdf-woo-shell .coupon label {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
}

.cdf-woo-shell .coupon .input-text {
  min-width: 220px;
}

.cdf-woo-shell table.cart td.actions > .button {
  float: right;
}

.cdf-woo-shell .cart-collaterals {
  display: flex;
  justify-content: flex-end;
}

.cdf-woo-shell .cart-collaterals .cart_totals {
  float: none;
  width: min(100%, 430px);
  padding: clamp(22px, 3vw, 30px);
}

.cdf-woo-shell .cart_totals table.shop_table {
  box-shadow: none;
}

.cdf-woo-shell .wc-proceed-to-checkout {
  padding: 18px 0 0;
}

.cdf-woo-shell .wc-proceed-to-checkout .checkout-button {
  width: 100%;
  min-height: 54px;
  font-size: 16px;
}

.cdf-woo-shell .return-to-shop {
  text-align: center;
}

/* Checkout */
.cdf-woo-shell form.checkout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(340px, 430px);
  gap: clamp(22px, 3.4vw, 38px);
  align-items: start;
}

.cdf-woo-shell .woocommerce-billing-fields,
.cdf-woo-shell .woocommerce-shipping-fields,
.cdf-woo-shell .woocommerce-additional-fields,
.cdf-woo-shell #order_review,
.cdf-woo-shell .wc-block-components-sidebar,
.cdf-woo-shell .wc-block-checkout__main {
  min-width: 0;
  padding: clamp(22px, 3vw, 32px);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  background: #fff;
  box-shadow: var(--shadow);
}

.cdf-woo-shell .woocommerce-additional-fields {
  margin-top: 18px;
}

.cdf-woo-shell #order_review {
  position: sticky;
  top: calc(var(--header-h) + 22px);
}

.cdf-woo-shell #order_review_heading {
  grid-column: 2;
  margin: 0;
}

.cdf-woo-shell .woocommerce-checkout-review-order-table {
  margin-bottom: 18px;
  box-shadow: none;
}

.cdf-woo-shell #payment {
  border: 1px solid var(--line);
  border-radius: var(--r);
  background: var(--sand);
  overflow: hidden;
}

.cdf-woo-shell #payment ul.payment_methods {
  margin: 0;
  padding: 0;
  border-bottom: 1px solid var(--line);
  list-style: none;
}

.cdf-woo-shell #payment ul.payment_methods li {
  margin: 0;
  padding: 16px 18px;
  border-bottom: 1px solid var(--line);
}

.cdf-woo-shell #payment ul.payment_methods li:last-child {
  border-bottom: 0;
}

.cdf-woo-shell #payment .payment_box {
  margin: 12px 0 0;
  padding: 14px;
  border-radius: var(--r-sm);
  background: #fff;
  color: var(--body);
  font-size: 14.5px;
}

.cdf-woo-shell #payment .place-order {
  padding: 18px;
}

.cdf-woo-shell #place_order {
  width: 100%;
  min-height: 54px;
  font-size: 16px;
}

.cdf-woo-shell .woocommerce-terms-and-conditions-wrapper {
  margin-bottom: 16px;
  color: var(--body);
  font-size: 14px;
}

/* WooCommerce Blocks */
.cdf-woo-shell .wc-block-cart,
.cdf-woo-shell .wc-block-checkout {
  margin: 0;
}

.cdf-woo-shell .wc-block-components-main,
.cdf-woo-shell .wc-block-cart__main,
.cdf-woo-shell .wc-block-checkout__main {
  padding-right: clamp(16px, 2vw, 28px);
}

.cdf-woo-shell .wc-block-cart__sidebar,
.cdf-woo-shell .wc-block-checkout__sidebar {
  padding: clamp(22px, 3vw, 30px);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  background: #fff;
  box-shadow: var(--shadow);
}

.cdf-woo-shell .wc-block-components-sidebar-layout .wc-block-components-main {
  width: 64%;
}

.cdf-woo-shell .wc-block-components-sidebar-layout .wc-block-components-sidebar {
  width: 36%;
}

@media (max-width: 920px) {
  .cdf-woo-shell #customer_login,
  .cdf-woo-shell form.checkout {
    grid-template-columns: 1fr;
  }

  .cdf-woo-shell #order_review,
  .cdf-woo-shell #order_review_heading {
    grid-column: auto;
    position: static;
  }

  .cdf-woo-shell .form-row-first,
  .cdf-woo-shell .form-row-last {
    float: none;
    width: 100%;
  }

  .cdf-woo-shell .cart-collaterals {
    display: block;
  }

  .cdf-woo-shell .cart-collaterals .cart_totals {
    width: 100%;
  }

  .cdf-woo-shell .wc-block-components-sidebar-layout .wc-block-components-main,
  .cdf-woo-shell .wc-block-components-sidebar-layout .wc-block-components-sidebar {
    width: 100%;
    padding-right: 0;
  }
}

@media (max-width: 700px) {
  .cdf-woo-shell table.shop_table_responsive,
  .cdf-woo-shell table.shop_table_responsive tbody,
  .cdf-woo-shell table.shop_table_responsive tr,
  .cdf-woo-shell table.shop_table_responsive td {
    display: block;
    width: 100%;
  }

  .cdf-woo-shell table.shop_table_responsive thead {
    display: none;
  }

  .cdf-woo-shell table.shop_table_responsive tr {
    border-bottom: 1px solid var(--line);
    padding: 14px;
  }

  .cdf-woo-shell table.shop_table_responsive tr:last-child {
    border-bottom: 0;
  }

  .cdf-woo-shell table.shop_table_responsive td {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    padding: 10px 0;
    border-bottom: 0;
    text-align: right;
  }

  .cdf-woo-shell table.shop_table_responsive td::before {
    content: attr(data-title);
    color: var(--muted);
    font-size: 12px;
    font-weight: 900;
    letter-spacing: .08em;
    text-transform: uppercase;
  }

  .cdf-woo-shell table.shop_table_responsive td.product-thumbnail,
  .cdf-woo-shell table.shop_table_responsive td.product-remove,
  .cdf-woo-shell table.shop_table_responsive td.actions {
    display: block;
    text-align: left;
  }

  .cdf-woo-shell table.shop_table_responsive td.product-thumbnail::before,
  .cdf-woo-shell table.shop_table_responsive td.product-remove::before,
  .cdf-woo-shell table.shop_table_responsive td.actions::before {
    display: none;
  }

  .cdf-woo-shell .coupon,
  .cdf-woo-shell table.cart td.actions > .button {
    float: none;
    width: 100%;
  }

  .cdf-woo-shell .coupon {
    display: grid;
    grid-template-columns: 1fr;
    margin-bottom: 12px;
  }

  .cdf-woo-shell .coupon .input-text,
  .cdf-woo-shell .coupon .button {
    width: 100%;
    min-width: 0;
  }

  .cdf-woo-shell .product-thumbnail img {
    width: 100%;
    height: auto;
    max-height: 190px;
  }
}

