/* ============================================
   ShopXnow Child Theme - Custom CSS
   All customizations safe from parent theme updates
   ============================================ */

/* 🔢 Code 01: Hide checkout/cart unwanted fields */
.woocommerce-shipping-fields,
.woocommerce-checkout .woocommerce-billing-fields .form-row.form-row-wide:nth-child(3),
.woocommerce-checkout #billing_email_field,
.woocommerce-cart .actions .button[name="update_cart"],
.woocommerce-cart td.actions.clear .continue-shopping,
#order_comments_field,
.sku_wrapper,
.woocommerce-message,
.message-container.container.success-color.medium-text-center,
.page-title-inner.flex-row.medium-flex-wrap.container {
  display: none !important;
}
/* 🔚 End Code 01 */

/* 🔢 Code 02: Thank You Page success styling */
.woocommerce-order-received .woocommerce-notice,
.woocommerce-order-received .woocommerce-order,
.woocommerce-order-received .woocommerce-customer-details {
  background: #e8f5e9;
  border: 1px solid #66bb6a;
  padding: 16px;
  margin-bottom: 20px;
  color: #2e7d32;
  border-radius: 8px;
  font-weight: 500;
  font-size: 16px;
  box-shadow: 0 0 10px rgba(0, 128, 0, 0.1);
}

.woocommerce-order-received .woocommerce-notice::after {
  content: "📸 Please take a screenshot of your Order ID for future reference.";
  display: block;
  margin-top: 12px;
  color: #1b5e20;
  font-size: 14px;
  font-weight: bold;
  text-align: center;
}
/* 🔚 End Code 02 */

/* 🔢 Code 03: Cart page compact layout */
body.woocommerce-cart .cart-container.container.page-wrapper.page-checkout {
  padding: 4px 6px !important;
  max-width: 100% !important;
  background: #fff !important;
  box-sizing: border-box;
}

body.woocommerce-cart .woocommerce-cart-form,
body.woocommerce-cart .cart_totals {
  padding: 4px 6px !important;
  margin: 6px 0 !important;
  background: #fff !important;
  border-radius: 4px;
  box-shadow: none !important;
}

body.woocommerce-cart .woocommerce-cart-form td,
body.woocommerce-cart .woocommerce-cart-form th,
body.woocommerce-cart .cart_totals td,
body.woocommerce-cart .cart_totals th {
  padding: 3px 4px !important;
  font-size: 12px !important;
  line-height: 1.2 !important;
}

body.woocommerce-cart .woocommerce-cart-form .product-thumbnail img {
  width: 45px !important;
  height: auto !important;
  border-radius: 3px;
}

body.woocommerce-cart .cart_totals h2,
body.woocommerce-cart .woocommerce-cart-form h2 {
  font-size: 13px !important;
  margin: 4px 0 !important;
}

body.woocommerce-cart .wc-proceed-to-checkout a.checkout-button {
  width: 100% !important;
  padding: 7px 10px !important;
  font-size: 12px !important;
  font-weight: 600;
  background: #007b8f !important;
  color: #fff !important;
  border-radius: 4px;
  margin-top: 8px !important;
  text-align: center;
  box-shadow: none !important;
  border: none !important;
}
/* 🔚 End Code 03 */

/* 🔢 Code 04: Mobile optimization for cart */
@media (max-width: 768px) {
  body.woocommerce-cart .woocommerce-cart-form td.product-name,
  body.woocommerce-cart .woocommerce-cart-form td.product-price,
  body.woocommerce-cart .woocommerce-cart-form td.product-quantity,
  body.woocommerce-cart .woocommerce-cart-form td.product-subtotal {
    font-size: 11px !important;
  }
}
/* 🔚 End Code 04 */

/* 🔢 Code 05: Facebook/Google login buttons */
.shopxnow-social-button-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  margin: 10px 0 20px;
}

.shopxnow-social-btn {
  font-size: 14px;
  padding: 10px 24px;
  border-radius: 30px;
  text-decoration: none;
  color: white;
  font-weight: 600;
  display: inline-block;
  transition: 0.3s;
  min-width: 220px;
  text-align: center;
}

.shopxnow-social-btn.google {
  background-color: #db4437;
}

.shopxnow-social-btn.facebook {
  background-color: #1877f2;
}

.shopxnow-social-btn:hover {
  opacity: 0.9;
}
/* 🔚 End Code 05 */

/* 🔢 Code 06: Add to Cart & Buy Now button design */
.woocommerce-variation-add-to-cart {
  display: flex;
  flex-direction: column;
  gap: 12px;
  align-items: center;
  margin-top: 10px;
  margin-bottom: 30px;
}

.woocommerce-variation-add-to-cart button {
  width: 180px;
  height: 44px;
  font-size: 14px;
  font-weight: bold;
  border: none;
  border-radius: 12px;
  text-transform: uppercase;
  transition: all 0.3s ease-in-out;
  box-shadow: 0 3px 10px rgba(0,0,0,0.12);
}

.woocommerce-variation-add-to-cart .single_add_to_cart_button {
  background: linear-gradient(135deg, #ff7b7b, #ff9999);
  color: #fff;
}

.woocommerce-variation-add-to-cart .buy-now-button {
  background: linear-gradient(135deg, #7c92b1, #a1b4cd);
  color: #fff;
}

.woocommerce-variation-add-to-cart button:hover {
  transform: scale(1.04);
  box-shadow: 0 4px 14px rgba(0,0,0,0.18);
}
/* 🔚 End Code 07 */

/* 🔢 Code 07: Mobile button responsiveness */
@media (max-width: 480px) {
  .woocommerce-variation-add-to-cart button {
    width: 90%;
    height: 42px;
    font-size: 13px;
  }
}
/* 🔚 End Code 07 */

/* Minimal error message styling - optimized for performance */
p#billing_state_description.checkout-inline-error-message {
  color: #e53e3e !important;
  font-weight: 500 !important;
  background-color: #fff5f5 !important;
  border-left: 2px solid #e53e3e !important;
  padding: 6px 10px !important;
  margin-top: 4px !important;
  display: block !important;
  font-size: 13px !important;
}

/* ============================================
   Homepage Design - Full Page Layout
   ============================================ */

/* Help Section - "Need Help? How to Order?" */
.help-section {
  padding: 12px 0;
  background: #f0f8ff;
  border-bottom: 1px solid #e0e0e0;
}

.help-banner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 15px;
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
  position: relative;
}

.help-content {
  display: flex;
  align-items: center;
  gap: 15px;
  flex: 1;
}

.help-text {
  font-size: 14px;
  font-weight: 600;
  color: #333;
}

.watch-video-btn {
  background: #28a745;
  color: #fff;
  border: none;
  padding: 8px 20px;
  border-radius: 20px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s;
}

.watch-video-btn:hover {
  background: #218838;
  transform: scale(1.05);
}

.close-help {
  background: transparent;
  border: none;
  font-size: 24px;
  color: #999;
  cursor: pointer;
  padding: 0;
  width: 30px;
  height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: color 0.3s;
}

.close-help:hover {
  color: #e53e3e;
}

/* App Banner Section */
.app-banner-section {
  margin-bottom: 20px;
}

.app-banner {
  position: relative;
  width: 100%;
  max-width: 100%;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.app-banner .banner-img {
  width: 100%;
  height: auto;
  display: block;
}

.app-banner .close-btn {
  position: absolute;
  top: 10px;
  right: 15px;
  font-size: 24px;
  font-weight: bold;
  color: #333;
  cursor: pointer;
  width: 30px;
  height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.9);
  border-radius: 50%;
  transition: all 0.3s;
  z-index: 10;
}

.app-banner .close-btn:hover {
  background: rgba(255, 255, 255, 1);
  color: #e53e3e;
}

.app-banner .store-btn {
  position: absolute;
  bottom: 15px;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(255, 255, 255, 0.9);
  padding: 8px 16px;
  border-radius: 8px;
  text-align: center;
  backdrop-filter: blur(10px);
  transition: all 0.3s;
}

.app-banner .store-btn:hover {
  background: rgba(255, 255, 255, 1);
  transform: translateX(-50%) scale(1.05);
}

.app-banner .store-btn img {
  height: 36px;
  width: auto;
}

/* Homepage Product Sections */
.new-products-section,
.top-selling-section {
  padding: 30px 0;
  margin: 20px 0;
}

.new-products-section {
  background: #fff;
}

.top-selling-section {
  background: #f8f9fa;
}

.section-title-center {
  text-align: center;
  font-size: 24px;
  font-weight: 700;
  color: #222;
  margin-bottom: 25px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}

.fire-icon {
  font-size: 28px;
}

.products-grid-home {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 20px;
  margin-top: 20px;
}

/* Product Card Styling */
.products-grid-home .product {
  position: relative;
  background: white;
  border-radius: 8px;
  overflow: hidden;
  transition: all 0.3s;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.products-grid-home .product:hover {
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
  transform: translateY(-4px);
}

.products-grid-home .product img {
  width: 100%;
  height: auto;
  display: block;
}

.products-grid-home .product .price {
  padding: 10px;
  font-size: 16px;
  font-weight: 600;
  color: #e91e63;
}

/* Mobile Responsive */
@media (max-width: 768px) {
  .help-banner {
    flex-direction: column;
    gap: 10px;
  }
  
  .help-content {
    flex-direction: column;
    width: 100%;
  }
  
  .watch-video-btn {
    width: 100%;
  }
  
  .products-grid-home {
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 15px;
  }
  
  .section-title-center {
    font-size: 20px;
  }
}

/* ============================================
   Single Product Page - Enhanced Design
   ============================================ */

/* Product Details Card - Beautiful Grid Layout */
.shopxnow-product-details-card {
  margin: 20px 0 !important;
  padding: 20px !important;
  background: linear-gradient(135deg, #f8f9fa 0%, #ffffff 100%) !important;
  border-radius: 12px !important;
  box-shadow: 0 2px 8px rgba(0,0,0,0.08) !important;
  border: 1px solid #e9ecef !important;
}

.shopxnow-product-details-card h3 {
  margin: 0 0 15px !important;
  font-size: 18px !important;
  font-weight: 600 !important;
  color: #1a1a2e !important;
  display: flex !important;
  align-items: center !important;
  gap: 8px !important;
}

.product-details-grid {
  display: grid !important;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)) !important;
  gap: 12px !important;
}

.product-details-grid .detail-item {
  padding: 10px !important;
  background: #fff !important;
  border-radius: 8px !important;
  border-left: 3px solid !important;
  transition: all 0.3s ease !important;
}

.product-details-grid .detail-item:hover {
  transform: translateY(-2px) !important;
  box-shadow: 0 4px 8px rgba(0,0,0,0.1) !important;
}

.product-details-grid .detail-item .detail-label {
  font-size: 11px !important;
  color: #6b7280 !important;
  text-transform: uppercase !important;
  letter-spacing: 0.5px !important;
  margin-bottom: 4px !important;
}

.product-details-grid .detail-item .detail-value {
  font-size: 14px !important;
  font-weight: 600 !important;
  color: #1a1a2e !important;
}

/* Vendor Info Styling */
.sxmv-vendor-info {
  margin: 15px 0 !important;
  padding: 12px !important;
  background: #f8f9fa !important;
  border-radius: 6px !important;
  border-left: 3px solid #667eea !important;
}

.sxmv-vendor-info a {
  color: #667eea !important;
  font-weight: 600 !important;
  text-decoration: none !important;
  transition: all 0.2s !important;
}

.sxmv-vendor-info a:hover {
  color: #4f46e5 !important;
  text-decoration: underline !important;
}

/* Variation Selector Enhancement */
.woocommerce-variations tr {
  border-bottom: 1px solid #e9ecef !important;
}

.woocommerce-variations td.label {
  font-weight: 600 !important;
  color: #374151 !important;
  padding: 12px !important;
}

.woocommerce-variations td.value {
  padding: 12px !important;
}

.woocommerce-variations select,
.woocommerce-variations .variation-select {
  padding: 10px 12px !important;
  border: 2px solid #e9ecef !important;
  border-radius: 8px !important;
  font-size: 14px !important;
  transition: all 0.3s !important;
}

.woocommerce-variations select:focus,
.woocommerce-variations .variation-select:focus {
  border-color: #667eea !important;
  outline: none !important;
  box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1) !important;
}

/* Variation Price Display */
.woocommerce-variation-price {
  font-size: 24px !important;
  font-weight: 700 !important;
  color: #e91e63 !important;
  margin: 15px 0 !important;
}

.woocommerce-variation-price .price {
  display: flex !important;
  align-items: center !important;
  gap: 10px !important;
}

.woocommerce-variation-price del {
  font-size: 18px !important;
  color: #6b7280 !important;
  opacity: 0.7 !important;
}

/* Add to Cart Button Enhancement */
.single_add_to_cart_button {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%) !important;
  color: #fff !important;
  padding: 14px 28px !important;
  font-size: 16px !important;
  font-weight: 600 !important;
  border: none !important;
  border-radius: 8px !important;
  transition: all 0.3s !important;
  box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3) !important;
}

.single_add_to_cart_button:hover {
  transform: translateY(-2px) !important;
  box-shadow: 0 6px 16px rgba(102, 126, 234, 0.4) !important;
}

.single_add_to_cart_button:disabled {
  opacity: 0.6 !important;
  cursor: not-allowed !important;
}

/* Product Image Gallery */
.woocommerce-product-gallery {
  border-radius: 12px !important;
  overflow: hidden !important;
  box-shadow: 0 4px 12px rgba(0,0,0,0.1) !important;
}

.woocommerce-product-gallery__image img {
  border-radius: 8px !important;
}

/* Product Tabs Enhancement */
.woocommerce-tabs {
  margin-top: 30px !important;
}

.woocommerce-tabs ul.tabs {
  border-bottom: 2px solid #e9ecef !important;
  margin-bottom: 20px !important;
}

.woocommerce-tabs ul.tabs li {
  margin-right: 20px !important;
}

.woocommerce-tabs ul.tabs li a {
  padding: 12px 20px !important;
  font-weight: 600 !important;
  color: #6b7280 !important;
  transition: all 0.3s !important;
}

.woocommerce-tabs ul.tabs li.active a,
.woocommerce-tabs ul.tabs li a:hover {
  color: #667eea !important;
  border-bottom: 3px solid #667eea !important;
}

.woocommerce-tabs .panel {
  padding: 20px !important;
  background: #fff !important;
  border-radius: 8px !important;
  box-shadow: 0 2px 8px rgba(0,0,0,0.05) !important;
}

/* Mobile Responsive for Product Page */
@media (max-width: 768px) {
  .product-details-grid {
    grid-template-columns: 1fr !important;
  }
  
  .shopxnow-product-details-card {
    padding: 15px !important;
  }
  
  .woocommerce-variation-price {
    font-size: 20px !important;
  }
  
  .single_add_to_cart_button {
    width: 100% !important;
    padding: 12px 20px !important;
  }
}

/* ============================================
   Product Listing Page - Shop/Archive
   ============================================ */

/* Product Card Enhancement */
.shopxnow-product-card {
  position: relative;
  background: #fff;
  border-radius: 12px;
  overflow: hidden;
  transition: all 0.3s ease;
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
  border: 1px solid #e9ecef;
  height: 100%;
  display: flex;
  flex-direction: column;
}

.shopxnow-product-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 20px rgba(0,0,0,0.12);
  border-color: #667eea;
}

/* Product Image */
.shopxnow-product-card .woocommerce-loop-product__link {
  position: relative;
  display: block;
  overflow: hidden;
  padding-top: 100%;
  background: #f8f9fa;
}

.shopxnow-product-card .woocommerce-loop-product__link img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}

.shopxnow-product-card:hover .woocommerce-loop-product__link img {
  transform: scale(1.1);
}

/* Sale Badge */
.shopxnow-product-card .onsale {
  position: absolute;
  top: 10px;
  left: 10px;
  background: linear-gradient(135deg, #ff5252 0%, #ff1744 100%);
  color: #fff;
  padding: 6px 12px;
  border-radius: 20px;
  font-size: 11px;
  font-weight: 700;
  z-index: 10;
  box-shadow: 0 2px 8px rgba(255,82,82,0.3);
}

/* Product Info Section */
.shopxnow-product-info {
  padding: 15px;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

/* Product Title */
.shopxnow-product-card .woocommerce-loop-product__title {
  font-size: 14px;
  font-weight: 600;
  color: #1a1a2e;
  line-height: 1.4;
  margin: 0 0 8px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  min-height: 40px;
}

.shopxnow-product-card .woocommerce-loop-product__title a {
  color: #1a1a2e;
  text-decoration: none;
  transition: color 0.3s;
}

.shopxnow-product-card .woocommerce-loop-product__title a:hover {
  color: #667eea;
}

/* Product Details Chips (Compact) */
.shopxnow-listing-details {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 8px;
}

.shopxnow-listing-details .detail-chip {
  display: inline-block;
  padding: 4px 10px;
  border-radius: 12px;
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.3px;
}

.shopxnow-listing-details .detail-chip.fabric {
  background: linear-gradient(135deg, #e8f5e9 0%, #c8e6c9 100%);
  color: #2e7d32;
  border: 1px solid #81c784;
}

.shopxnow-listing-details .detail-chip.style {
  background: linear-gradient(135deg, #e3f2fd 0%, #bbdefb 100%);
  color: #1565c0;
  border: 1px solid #64b5f6;
}

.shopxnow-listing-details .detail-chip.color {
  background: linear-gradient(135deg, #fff3e0 0%, #ffe0b2 100%);
  color: #e65100;
  border: 1px solid #ffb74d;
}

/* Variations Info */
.shopxnow-listing-variations {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-bottom: 8px;
  font-size: 11px;
}

.shopxnow-listing-variations .variation-info {
  display: flex;
  align-items: center;
  gap: 6px;
  color: #6b7280;
}

.shopxnow-listing-variations .variation-info strong {
  color: #374151;
  font-weight: 600;
  font-size: 10px;
  text-transform: uppercase;
}

.shopxnow-listing-variations .variation-info.size {
  color: #667eea;
}

.shopxnow-listing-variations .variation-info.color {
  color: #f59e0b;
}

/* Price Display */
.shopxnow-product-card .price {
  font-size: 18px;
  font-weight: 700;
  color: #e91e63;
  margin: 8px 0;
}

.shopxnow-product-card .price del {
  font-size: 14px;
  color: #9ca3af;
  margin-right: 8px;
  opacity: 0.7;
}

.shopxnow-product-card .price ins {
  text-decoration: none;
  color: #e91e63;
}

/* Rating */
.shopxnow-product-card .star-rating {
  margin: 4px 0;
  font-size: 12px;
}

/* Add to Cart Button */
.shopxnow-product-card .button,
.shopxnow-product-card .add_to_cart_button {
  margin-top: auto;
  padding: 10px 16px;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: #fff;
  border: none;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  transition: all 0.3s;
  box-shadow: 0 2px 8px rgba(102, 126, 234, 0.3);
  width: 100%;
  text-align: center;
}

.shopxnow-product-card .button:hover,
.shopxnow-product-card .add_to_cart_button:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
  background: linear-gradient(135deg, #764ba2 0%, #667eea 100%);
}

/* Products Grid */
.woocommerce ul.products {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 20px;
  list-style: none;
  padding: 0;
  margin: 0;
}

/* Mobile Responsive for Product Listing */
@media (max-width: 768px) {
  .woocommerce ul.products {
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 15px;
  }
  
  .shopxnow-product-info {
    padding: 12px;
  }
  
  .shopxnow-product-card .woocommerce-loop-product__title {
    font-size: 13px;
    min-height: 36px;
  }
  
  .shopxnow-product-card .price {
    font-size: 16px;
  }
}

