/* Extra WooCommerce overrides can go here. */
.front-page-custom .hero {
  background: #f5f5f5;
  padding: 60px 20px;
  text-align: center;
}
.front-page-custom .hero h1 {
  font-size: 42px;
  margin-bottom: 10px;
}
.front-page-custom section {
  margin: 50px 0;
}
.front-page-custom h2 {
  margin-bottom: 20px;
  text-align: center;
}

/* Force Tailwind-like button styles */
/* Force consistent product image size */
.woocommerce img,
.woocommerce-page img {
  max-width: 100%;
}

/* Set background for WooCommerce content area */
.woocommerce-page #primary,
.woocommerce-page .site-main,
.woocommerce-page .content-area {
  background-color: #f0f0f1; /* white background */
  padding: 2rem;
}

/* Product view */
/* Force override WooCommerce default image sizing */
li.product img {
    width: auto !important;
    height: auto !important;
    max-height: 80% !important;
    max-width: 80% !important;
    object-fit: contain !important;
    margin: auto;
}
.group img {
    transition: transform 0.3s ease;
}
.group:hover img {
    transform: scale(1.05);
}
.woocommerce-loop-product__title {
    display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2; /* standard property */
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.woocommerce ul.products {
    display: grid !important;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 1.5rem;
        padding: 0;
    margin: 0;
}
.woocommerce ul.products li.product {
    width: 100% !important;
}
.woocommerce ul.products::before,
.woocommerce ul.products::after,
.woocommerce-page ul.products::before,
.woocommerce-page ul.products::after {
    content: none !important;
    display: none !important;
}

/* Events */
.etn-advanced-search-form, 
.etn-container, 
.etn-es-events-page-container, 
.etn-event-archive-wrap, 
.etn_search_item_container,
.etn-order-purchase-create-form,
.eventin-page-container{
  background: white !important;
}

#eventin-checkout{
  background: white !important;
}

.etn-event-search-wrapper{
  margin-bottom: 0;
}

/* WooCommerce notices: align icon, text and button on one line */
.woocommerce .woocommerce-message,
.woocommerce .woocommerce-error,
.woocommerce .woocommerce-info,
.woocommerce-page .woocommerce-message,
.woocommerce-page .woocommerce-error,
.woocommerce-page .woocommerce-info,
/* Fallback when wrapper class is missing (e.g., Home) */
.woocommerce-message,
.woocommerce-error,
.woocommerce-info {
  display: flex;
  align-items: center; /* vertical center */
  gap: .75rem;
  flex-wrap: wrap; /* allow wrap on small screens */
  position: relative;
  padding: .9rem 1rem; /* balanced padding */
  line-height: 1.4;
}

.woocommerce .woocommerce-message::before,
.woocommerce .woocommerce-error::before,
.woocommerce .woocommerce-info::before,
.woocommerce-page .woocommerce-message::before,
.woocommerce-page .woocommerce-error::before,
.woocommerce-page .woocommerce-info::before,
/* Fallback */
.woocommerce-message::before,
.woocommerce-error::before,
.woocommerce-info::before {
  position: static !important; /* become a flex item */
  left: auto !important;
  top: auto !important;
  transform: none !important;
  display: inline-block;
  margin-right: .25rem; /* small space before text */
  pointer-events: none;
}

/* Keep button nicely spaced within notice */
.woocommerce .woocommerce-message .button,
.woocommerce .woocommerce-error .button,
.woocommerce .woocommerce-info .button,
.woocommerce-page .woocommerce-message .button,
.woocommerce-page .woocommerce-error .button,
.woocommerce-page .woocommerce-info .button,
/* Fallback */
.woocommerce-message .button,
.woocommerce-error .button,
.woocommerce-info .button {
  margin-left: auto; /* push button to the right */
  flex-shrink: 0; /* don't shrink the button */
  white-space: nowrap; /* keep on one line when possible */
  padding: .5rem .9rem;
  font-weight: 600;
  border-radius: 10px;
}

/* Match "View cart" button to site teal/green style inside notices */
.woocommerce .woocommerce-message .button,
.woocommerce-page .woocommerce-message .button,
.woocommerce .woocommerce-info .button,
.woocommerce-page .woocommerce-info .button,
/* Fallback */
.woocommerce-message .button,
.woocommerce-info .button {
  background-color: #14b8a6 !important; /* teal-500 */
  border-color: #14b8a6 !important;
  color: #fff !important;
  border-width: 1px;
  transition: background-color .2s ease, border-color .2s ease, color .2s ease;
}

.woocommerce .woocommerce-message .button:hover,
.woocommerce-page .woocommerce-message .button:hover,
.woocommerce .woocommerce-info .button:hover,
.woocommerce-page .woocommerce-info .button:hover,
/* Fallback */
.woocommerce-message .button:hover,
.woocommerce-info .button:hover {
  background-color: #0d9488 !important; /* teal-600 */
  border-color: #0d9488 !important;
  color: #fff !important;
}

.woocommerce .woocommerce-message .button:focus,
.woocommerce-page .woocommerce-message .button:focus,
.woocommerce .woocommerce-info .button:focus,
.woocommerce-page .woocommerce-info .button:focus,
/* Fallback */
.woocommerce-message .button:focus,
.woocommerce-info .button:focus {
  outline: 2px solid #99f6e4; /* teal-100 focus ring */
  outline-offset: 2px;
}

/* Inline "View cart" link that appears after AJAX add_to_cart */
.woocommerce a.added_to_cart,
.woocommerce-page a.added_to_cart,
.woocommerce a.wc-forward.added_to_cart,
.woocommerce-page a.wc-forward.added_to_cart,
/* Fallback */
a.added_to_cart,
a.wc-forward.added_to_cart {
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  margin-left: .5rem; /* sit next to Add to cart */
  background-color: #14b8a6 !important; /* teal-500 */
  color: #fff !important;
  padding: .45rem .8rem;
  border-radius: 10px;
  border: 1px solid #14b8a6 !important;
  font-weight: 600;
  line-height: 1.2;
  text-decoration: none !important;
  transition: background-color .2s ease, border-color .2s ease, color .2s ease, box-shadow .2s ease;
}

.woocommerce a.added_to_cart:hover,
.woocommerce-page a.added_to_cart:hover,
.woocommerce a.wc-forward.added_to_cart:hover,
.woocommerce-page a.wc-forward.added_to_cart:hover,
/* Fallback */
a.added_to_cart:hover,
a.wc-forward.added_to_cart:hover {
  background-color: #0d9488 !important; /* teal-600 */
  border-color: #0d9488 !important;
  color: #fff !important;
}

.woocommerce a.added_to_cart:focus,
.woocommerce-page a.added_to_cart:focus,
.woocommerce a.wc-forward.added_to_cart:focus,
.woocommerce-page a.wc-forward.added_to_cart:focus,
/* Fallback */
a.added_to_cart:focus,
a.wc-forward.added_to_cart:focus {
  outline: 2px solid #99f6e4; /* teal-100 */
  outline-offset: 2px;
}

/* When the add button changes to "Added" state, keep spacing tidy */
.woocommerce a.add_to_cart_button.added {
  margin-right: .25rem;
}

/* (Reverted) Unified Add to cart fallback styling block removed */

/* Ensure button row stays visible and wraps nicely on small cards */
.woocommerce ul.products li.product .button,
.woocommerce ul.products li.product a.added_to_cart {
  vertical-align: middle;
}

/* In our card layout, keep the inline "View cart" within the button area */
.woocommerce ul.products li.product .mt-auto .button + a.added_to_cart,
.woocommerce ul.products li.product .mt-auto a.add_to_cart_button.added + a.added_to_cart {
  display: inline-flex;
}

/* Prevent the added_to_cart link from dropping below the fold in our fixed-height cards */
.woocommerce ul.products li.product .mt-auto {
  display: flex;
  align-items: center;
  justify-content: center; /* center buttons horizontally */
  gap: .5rem;
  flex-wrap: nowrap; /* keep on one line when possible */
}

/* Optional: on very narrow screens, center buttons so they don't overflow */
@media (max-width: 420px) {
  .woocommerce ul.products li.product .mt-auto {
    justify-content: center;
  }
}

/* Prevent Woo defaults from forcing full width or float */
.woocommerce ul.products li.product .button {
  display: inline-flex;
  width: auto !important;
  float: none !important;
  margin: 0; /* keep spacing controlled by container gap */
}
.woocommerce ul.products li.product a.wc-forward {
  float: none !important;
}

/* Stronger rules for product cards on Shop to keep inline beside the Add to cart button */
.woocommerce ul.products li.product a.added_to_cart,
.woocommerce ul.products li.product a.wc-forward.added_to_cart {
  display: inline-flex !important;
  margin: 0 0 0 .5rem !important;
}

/* Fallback for Home (no .woocommerce wrapper) */
ul.products li.product a.added_to_cart,
ul.products li.product a.wc-forward.added_to_cart {
  display: inline-flex !important;
  margin-left: .5rem !important;
}

/* Home-only: make View cart grey to match Shop Add to cart */
body.home ul.products li.product a.added_to_cart,
body.home ul.products li.product a.wc-forward.added_to_cart,
body.home a.added_to_cart,
body.home a.wc-forward.added_to_cart {
  background-color: #e9e6ed !important; /* light gray */
  border-color: #e9e6ed !important;
  color: #333 !important; /* better contrast on light background */
}

body.home ul.products li.product a.added_to_cart:hover,
body.home ul.products li.product a.wc-forward.added_to_cart:hover,
body.home a.added_to_cart:hover,
body.home a.wc-forward.added_to_cart:hover {
  background-color: #d9d6dd !important; /* slightly darker hover */
  border-color: #d9d6dd !important;
  color: #222 !important;
}

ul.products li.product .mt-auto {
  display: flex;
  align-items: center;
  justify-content: center; /* center buttons horizontally on Home */
  gap: .5rem;
  flex-wrap: nowrap;
}

ul.products li.product .button,
ul.products li.product a.wc-forward {
  display: inline-flex;
  width: auto !important;
  float: none !important;
  margin: 0;
}

@media (max-width: 420px) {
  ul.products li.product .mt-auto {
    justify-content: center;
  }
}

/* Cart count badge animation */
@keyframes swt-bump {
  0% { transform: scale(1); }
  30% { transform: scale(1.2); }
  60% { transform: scale(0.95); }
  100% { transform: scale(1); }
}
.cart-count.swt-bump {
  animation: swt-bump .32s ease-out;
}