/*
Theme Name: Crazy Web Studio (Divi Child)
Template: Divi
Text Domain: Divi-child
Author: Crazy Web Studio
Author URI: https://www.crazywebstudio.co.th
*/
body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Open Sans", "Helvetica Neue", sans-serif;
  font-weight: 400;
}

/*cart icon with item counter bubble*/
.woofc-cart-link-inner-subtotal {
  display: none !important;
}

/* expand icon size */
.woofc-cart-link-inner i.woofc-icon-cart4 {
  font-size: 30px !important;
  /* change the size */
  display: inline-block;
  line-height: 1;
  vertical-align: middle;
  color: black;
}

/* adjust the space between the icon and the edge (if necessary) */
.woofc-cart-link-inner {
  display: flex;
  align-items: center;
  justify-content: center;
}

/* select the number (Pseudo-element) from WPC */
.woofc-cart-link-inner::after {
  /* get the info from data-count to display the number */
  content: attr(data-count) !important;

  /* force new position */
  position: absolute !important;
  top: 0 !important;
  right: 0 !important;
  transform: translate(50%, -50%) !important;
  /* move to top right */

  /* Bubble style */
  background-color: #ff4747 !important;
  color: #ffffff !important;
  width: 18px !important;
  height: 18px !important;
  border-radius: 50% !important;

  /* adjust the number to display at the middle of the bubble */
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  font-size: 10px !important;
  font-family: inherit;
  font-weight: bold;
  line-height: 1 !important;
  z-index: 99 !important;
}

/* hide the original number (if overlap) */
.woofc-cart-link-inner .woofc-cart-link-inner-count {
  display: none !important;
}

/* my account page */
/* 1. adjust main layout and background */
.woocommerce-account .woocommerce {
  display: flex;
  flex-wrap: wrap;
  gap: 40px;
  margin-top: 30px;
}

/* 2. navigation style */
.woocommerce-MyAccount-navigation {
  flex: 0 0 250px;
  background: #ffffff;
  padding: 0;
}

.woocommerce-MyAccount-navigation ul {
  list-style: none;
  padding: 0;
  margin: 0;
  border-top: 1px solid #000;
  /* Minimal style border */
}

.woocommerce-MyAccount-navigation ul li {
  border-bottom: 1px solid #eeeeee;
}

.woocommerce-MyAccount-navigation ul li a {
  padding: 15px 0;
  display: block;
  color: #000;
  font-family: Montserrat;
  font-weight: bold;
  text-decoration: none;
  text-transform: uppercase;
  /* uppercase from the style */
  font-size: 14px;
  letter-spacing: 1px;
  transition: all 0.3s ease;
}

.woocommerce-MyAccount-navigation ul li.is-active a {
  font-weight: bold;
  padding-left: 10px;
}

.woocommerce-MyAccount-navigation ul li a:hover {
  padding-left: 10px;
  color: #666;
}

/* 3. Content Area */
.woocommerce-MyAccount-content {
  flex: 1;
  min-width: 300px;
  font-family: Montserrat;
}

.woocommerce-MyAccount-content a {
  color: #000 !important;
  text-decoration: underline !important;
  text-underline-offset: 4px;
  transition: opacity 0.3s ease;
}

.woocommerce-MyAccount-content a:hover {
  opacity: 0.6;
  text-decoration: underline !important;
}

/* exclude underlines on the buttons */
.woocommerce-MyAccount-content a.button,
.woocommerce-MyAccount-content a.edit-link {
  text-decoration: none !important;
}

/* 4. Buttons style */
.woocommerce-account .button {
  background-color: #000 !important;
  color: #fff !important;
  border-radius: 0 !important;
  /* sharp corner */
  padding: 12px 25px !important;
  text-transform: uppercase !important;
  font-size: 13px !important;
  letter-spacing: 1.5px !important;
  border: 1px solid #000 !important;
  transition: 0.3s !important;
}

.woocommerce-account .button:hover {
  background-color: transparent !important;
  color: #000 !important;
}

/* 5. Orders Table */
.woocommerce-orders-table {
  border-collapse: collapse;
  width: 100%;
}

.woocommerce-orders-table th {
  text-transform: uppercase;
  font-size: 12px;
  background: #fdfdfd;
  padding: 15px;
  border-bottom: 2px solid #000;
}

.woocommerce-orders-table td {
  padding: 15px;
  border-bottom: 1px solid #eee;
}

/* 6. Notices */
.woocommerce-message,
.woocommerce-info {
  border-top-color: #000 !important;
  background-color: #f9f9f9 !important;
  color: #000 !important;
}

/* delete arrow icon from the buttons on My Account page */
.woocommerce-Button.wc-forward::after,
.woocommerce-account .button::after {
  display: none !important;
  content: none !important;
}

/* center the text on the buttons */
.woocommerce-account .button {
  text-align: center;
  padding-right: 25px !important;
  padding-left: 25px !important;
}

/* Stack WooCommerce variation labels and buttons vertically */
table.variations tr {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  margin-bottom: 0;
}

table.variations th.label {
  text-align: left;
  padding: 0 0 10px 0;
}

/* WooCommerce Variation Buttons */
.cws-variation-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 10px;
}

.cws-variation-btn {
  background-color: #ffffff;
  border: 2px solid #000000;
  color: #000000;
  padding: 10px 18px;
  cursor: pointer;
  font-family: "Montserrat", sans-serif;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 2px;
  transition: all 0.3s ease;
  line-height: 1.2;
}

/* Hide WooCommerce dropdown wrapper arrow */
.variations td.value>span::after,
.variations td.value>span::before {
  display: none !important;
  content: none !important;
}

/* Completely hide original select wrapper */
.variations td.value>span {
  display: none !important;
}

/* On hover, or when selected, invert the colors to match the primary button style */
.cws-variation-btn:hover,
.cws-variation-btn.selected {
  background-color: #000000 !important;
  color: #ffffff !important;
  border-color: #000000 !important;
}

.cws-variation-btn::after,
.cws-variation-btn::before {
  display: none !important;
  content: none !important;
}

a.reset_variations {
  font-family: "Montserrat", sans-serif;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: #000000 !important;
  text-decoration: underline !important;
  text-underline-offset: 4px;
  margin-top: 10px;
  display: inline-block;
  transition: opacity 0.3s ease;
}

a.reset_variations:hover {
  opacity: 0.6;
}

@media (max-width: 768px) {
  table.variations tr {
    align-items: center;
    width: 100%;
  }

  table.variations th.label,
  table.variations td.value {
    text-align: center;
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
  }

  .cws-variation-buttons {
    justify-content: center;
    width: 100%;
  }
}

th.label label[for="pa_grind"]::after {
  content: "Please select your brewing method so we can grind it to suit you";
  display: block;
  font-family: Montserrat;
  font-size: 12px;
  font-weight: 700;
  color: #000;
  margin-top: 4px;
  line-height: 1.3;
}

/* Disabled / Out-of-Stock / Unavailable Variation Buttons */
.cws-variation-btn:disabled,
.cws-variation-btn.disabled {
  background-color: #e0e0e0 !important;
  border-color: #cccccc !important;
  color: #a0a0a0 !important;
  cursor: not-allowed !important;
  opacity: 0.6 !important;
  pointer-events: none !important;
}

.cws-variation-btn:disabled:hover,
.cws-variation-btn.disabled:hover {
  background-color: #e0e0e0 !important;
  border-color: #cccccc !important;
  color: #a0a0a0 !important;
}

/* View Cart Link after add to cart - Minimal Underline Style */
a.added_to_cart.wc-forward {
  display: inline-block !important;
  margin-left: 15px;
  font-family: "Montserrat", sans-serif !important;
  font-size: 12px !important;
  font-weight: 700 !important;
  text-transform: uppercase !important;
  letter-spacing: 1.5px !important;
  color: #000000 !important;
  text-decoration: underline !important;
  text-underline-offset: 4px;
  transition: opacity 0.3s ease !important;
  vertical-align: middle;
}

/* Hover Effect */
a.added_to_cart.wc-forward:hover {
  opacity: 0.6 !important;
}

/* Hide default WooCommerce arrow icon */
a.added_to_cart.wc-forward::after,
a.added_to_cart.wc-forward::before {
  display: none !important;
  content: none !important;
}

/* ==========================================================================
   Single product: quantity stepper + Add To Cart row
   ========================================================================== */

/* Put the quantity box and the Add To Cart button on the same row.
   Simple products use form.cart, variable products use the variation wrapper. */
.single-product form.cart:not(.variations_form),
.single-product .woocommerce-variation-add-to-cart {
  display: flex;
  flex-wrap: wrap;
  align-items: stretch;
  gap: 10px;
  margin-top: 20px;
}

/* The "- 1 +" box - fixed height so every part can centre against it */
.single-product .cws-qty-wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex: 0 0 auto;
  width: 150px;
  height: 56px;
  margin: 0;
  padding: 0;
  background-color: #ffffff;
  border: 2px solid #000000;
  box-sizing: border-box;
}

.single-product .cws-qty-wrap.cws-qty-hidden {
  display: none;
}

.single-product .cws-qty-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 38px;
  width: 38px;
  height: 100%;
  margin: 0 !important;
  padding: 0 !important;
  background: none !important;
  border: 0 !important;
  border-radius: 0 !important;
  color: #000000 !important;
  font-family: "Montserrat", sans-serif;
  font-size: 20px;
  font-weight: 700;
  line-height: 1;
  cursor: pointer;
  transition: opacity 0.3s ease;
}

.single-product .cws-qty-btn:hover {
  background: none !important;
  opacity: 0.55;
}

.single-product .cws-qty-btn:disabled {
  opacity: 0.25;
  cursor: not-allowed;
}

/* Strip the Divi / WooCommerce button arrow */
.single-product .cws-qty-btn::after,
.single-product .cws-qty-btn::before {
  display: none !important;
  content: none !important;
}

/* WooCommerce quantity field inside the stepper.
   Divi styles div.quantity as a floated block, so the layout is forced here. */
.single-product .cws-qty-wrap .quantity {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  flex: 1 1 auto;
  width: auto !important;
  height: 100%;
  max-width: none !important;
  margin: 0 !important;
  padding: 0 !important;
  float: none !important;
}

/* Divi renders its own stepper arrows on div.quantity */
.single-product .cws-qty-wrap .quantity::before,
.single-product .cws-qty-wrap .quantity::after {
  display: none !important;
  content: none !important;
}

/* Keep the accessible label out of the flex flow */
.single-product .cws-qty-wrap .quantity label,
.single-product .cws-qty-wrap .quantity .screen-reader-text {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  margin: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.single-product .cws-qty-wrap .quantity input.qty {
  width: 100% !important;
  min-width: 30px;
  height: auto !important;
  min-height: 0 !important;
  margin: 0 !important;
  padding: 0 !important;
  background: transparent !important;
  border: 0 !important;
  border-radius: 0 !important;
  box-shadow: none !important;
  color: #000000;
  font-family: "Montserrat", sans-serif;
  font-size: 16px;
  font-weight: 700;
  line-height: 1.2 !important;
  text-align: center;
  -moz-appearance: textfield;
  appearance: textfield;
}

.single-product .cws-qty-wrap .quantity input.qty:focus {
  outline: none;
}

/* Remove the native number spinners - the +/- buttons replace them */
.single-product .cws-qty-wrap .quantity input.qty::-webkit-outer-spin-button,
.single-product .cws-qty-wrap .quantity input.qty::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

/* Add To Cart button, matched to the height of the stepper */
.single-product form.cart .single_add_to_cart_button {
  flex: 1 1 220px;
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  gap: 12px;
  min-height: 56px;
  padding: 12px 25px !important;
  background-color: #000000 !important;
  border: 2px solid #000000 !important;
  border-radius: 0 !important;
  color: #ffffff !important;
  font-family: "Montserrat", sans-serif !important;
  font-size: 13px !important;
  font-weight: 700 !important;
  text-transform: uppercase !important;
  letter-spacing: 1.5px !important;
  line-height: 1 !important;
  transition: all 0.3s ease !important;
}

.single-product form.cart .single_add_to_cart_button:hover {
  background-color: #ffffff !important;
  color: #000000 !important;
}

.single-product form.cart .single_add_to_cart_button.disabled,
.single-product form.cart .single_add_to_cart_button:disabled {
  background-color: #e0e0e0 !important;
  border-color: #cccccc !important;
  color: #a0a0a0 !important;
  cursor: not-allowed !important;
}

/* Cart icon - masked so it follows the button text colour on hover */
.single-product form.cart .single_add_to_cart_button::after {
  content: "" !important;
  display: inline-block !important;
  position: static !important;
  width: 22px;
  height: 22px;
  margin: 0 !important;
  opacity: 1 !important;
  background-color: currentColor;
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2024%2024'%20fill='none'%20stroke='%23000'%20stroke-width='2'%20stroke-linecap='round'%20stroke-linejoin='round'%3E%3Ccircle%20cx='9'%20cy='20'%20r='1.6'/%3E%3Ccircle%20cx='19'%20cy='20'%20r='1.6'/%3E%3Cpath%20d='M1.5%202h3.2l2.6%2012.4a1.8%201.8%200%200%200%201.8%201.4h9.1a1.8%201.8%200%200%200%201.8-1.4L22.5%206.5H6'/%3E%3C/svg%3E");
  mask-image: url("data:image/svg+xml,%3Csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2024%2024'%20fill='none'%20stroke='%23000'%20stroke-width='2'%20stroke-linecap='round'%20stroke-linejoin='round'%3E%3Ccircle%20cx='9'%20cy='20'%20r='1.6'/%3E%3Ccircle%20cx='19'%20cy='20'%20r='1.6'/%3E%3Cpath%20d='M1.5%202h3.2l2.6%2012.4a1.8%201.8%200%200%200%201.8%201.4h9.1a1.8%201.8%200%200%200%201.8-1.4L22.5%206.5H6'/%3E%3C/svg%3E");
  -webkit-mask-repeat: no-repeat;
  mask-repeat: no-repeat;
  -webkit-mask-position: center;
  mask-position: center;
  -webkit-mask-size: contain;
  mask-size: contain;
}

.single-product form.cart .single_add_to_cart_button::before {
  display: none !important;
  content: none !important;
}

@media (max-width: 768px) {

  .single-product form.cart:not(.variations_form),
  .single-product .woocommerce-variation-add-to-cart {
    justify-content: center;
  }

  .single-product .cws-qty-wrap {
    width: 130px;
  }

  .single-product .cws-qty-btn {
    flex: 0 0 32px;
    width: 32px;
  }

  .single-product form.cart .single_add_to_cart_button {
    flex: 1 1 160px;
    padding: 12px 15px !important;
    letter-spacing: 1px !important;
  }
}

.woocommerce div.product form.cart div.quantity,
.woocommerce-page div.product form.cart div.quantity,
.woocommerce #content div.product form.cart div.quantity,
.woocommerce-page #content div.product form.cart div.quantity {
  margin-right: 0 !important;
}


@media (max-width: 768px) {
  .woocommerce div.product form.cart .variations label {
    text-align: center;
  }
}

/* Product gallery image is no longer clickable - zoom and lightbox are disabled */
.single-product .woocommerce-product-gallery__image,
.single-product .woocommerce-product-gallery__image img {
  cursor: default;
}