/* AutoParts Theme Design Styles - Figma Implementation */

/* Latest Products Swiper - Fixed 4 Column Layout */
.module-latest-swiper {
  width: 100%;
  margin: 0;
  max-width: 1200px;
  margin-left: auto !important;
  margin-right: auto !important;
}

.module-latest-swiper .swiper-slide {
  width: 25% !important; /* Fixed 4 columns */
  max-width: 25% !important;
  flex: 0 0 25% !important;
}

/* Force 4-column layout at all sizes */
@media (min-width: 992px) {
  .module-latest-swiper .swiper-slide {
    width: 25% !important;
    max-width: 25% !important;
    flex: 0 0 25% !important;
  }
}

@media (max-width: 991px) and (min-width: 768px) {
  .module-latest-swiper .swiper-slide {
    width: 33.333% !important; /* 3 columns */
    max-width: 33.333% !important;
    flex: 0 0 33.333% !important;
  }
}

@media (max-width: 767px) and (min-width: 576px) {
  .module-latest-swiper .swiper-slide {
    width: 50% !important; /* 2 columns */
    max-width: 50% !important;
    flex: 0 0 50% !important;
  }
}

@media (max-width: 575px) {
  .module-latest-swiper .swiper-slide {
    width: 100% !important; /* 1 column */
    max-width: 100% !important;
    flex: 0 0 100% !important;
  }
}

/* Swiper Navigation and Pagination Styles */
.module-latest-swiper .swiper-pagination {
  bottom: -30px;
  background: #fd8900;
  height: 4px;
  border-radius: 2px;
  margin-top: 15px;
}

.module-latest-swiper .swiper-pagination-progressbar .swiper-pagination-progressbar-fill {
  background: #dc2626;
}

/* Ensure product layout consistency */
.module-latest-swiper .product-layout {
  margin-bottom: 20px;
  width: 100%;
}

.module-latest-swiper .product-layout .product-thumb {
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  padding: 15px;
  background: white;
  transition: all 0.3s ease;
}

.module-latest-swiper .product-layout .product-thumb:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
  border-color: #fd8900;
}

/* Body and Global Styles */
body.autoparts-body {
  background-color: #f8fafc !important;
  font-family: 'Inter', 'Microsoft YaHei', 'Segoe UI', sans-serif !important;
  line-height: 1.6;
  color: #0f172a;
}

/* Hero Banner Section - Enhanced for Figma Design */
.autoparts-hero-banner {
  position: relative;
  width: 100%;
  height: 500px;
  overflow: hidden;
  background: linear-gradient(135deg, #1e40af 0%, #0f172a 100%) !important;
  border-radius: 0 0 20px 20px;
  margin-bottom: 3rem;
}

.autoparts-hero-slide {
  position: absolute;
  inset: 0;
  transition: opacity 0.7s ease-in-out;
  opacity: 0;
}

.autoparts-hero-slide.active {
  opacity: 1;
}

.autoparts-hero-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: brightness(0.8);
}

.autoparts-hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(30, 64, 175, 0.8) 0%, rgba(15, 23, 42, 0.6) 50%, transparent 100%) !important;
}

.autoparts-hero-content {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.autoparts-hero-text {
  max-width: 600px;
  text-align: center;
  color: white;
}

.autoparts-hero-title {
  font-size: 3.5rem;
  font-weight: 700;
  margin-bottom: 1rem;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.autoparts-hero-subtitle {
  font-size: 1.5rem;
  font-weight: 500;
  margin-bottom: 2rem;
  opacity: 0.9;
}

.autoparts-hero-button {
  background: linear-gradient(135deg, #dc2626 0%, #b91c1c 100%) !important;
  color: white;
  border: none;
  padding: 1rem 2.5rem;
  font-size: 1.125rem;
  font-weight: 600;
  border-radius: 50px;
  transition: all 0.3s ease;
  box-shadow: 0 4px 15px rgba(220, 38, 38, 0.3);
}

.autoparts-hero-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(220, 38, 38, 0.4);
}

/* Featured Products Section - Enhanced for Figma Design */
.autoparts-featured-section {
  padding: 4rem 0;
  background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%) !important;
}

.autoparts-section-title {
  color: #0f172a;
  font-size: 2.5rem;
  font-weight: 700;
  text-align: center;
  margin-bottom: 3rem;
  position: relative;
}

.autoparts-section-title::after {
  content: '';
  position: absolute;
  bottom: -10px;
  left: 50%;
  transform: translateX(-50%);
  width: 60px;
  height: 4px;
  background: linear-gradient(135deg, #1e40af 0%, #dc2626 100%) !important;
  border-radius: 2px;
}

.autoparts-part-card {
  background: white;
  border: 2px solid #e2e8f0;
  border-radius: 16px;
  transition: all 0.3s ease;
  overflow: hidden;
  position: relative;
}

.autoparts-part-card:hover {
  border-color: #1e40af;
  transform: translateY(-5px);
  box-shadow: 0 20px 40px rgba(30, 64, 175, 0.15);
}

.autoparts-part-badge {
  background: linear-gradient(135deg, #dc2626 0%, #b91c1c 100%) !important;
  color: white;
  padding: 0.5rem 1rem;
  font-size: 0.875rem;
  font-weight: 600;
  position: absolute;
  top: 1rem;
  left: 1rem;
  z-index: 10;
  border-radius: 20px;
}

.autoparts-part-image {
  width: 100%;
  height: 200px;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.autoparts-part-card:hover .autoparts-part-image {
  transform: scale(1.05);
}

.autoparts-part-name {
  color: #0f172a;
  font-weight: 600;
  font-size: 1.125rem;
  margin-bottom: 0.5rem;
  line-height: 1.4;
}

.autoparts-part-price {
  color: #1e40af;
  font-size: 1.5rem;
  font-weight: 700;
}

.autoparts-part-original-price {
  color: #94a3b8;
  text-decoration: line-through;
  font-size: 1rem;
}

.autoparts-add-cart-btn {
  background: linear-gradient(135deg, #1e40af 0%, #1e3a8a 100%) !important;
  color: white;
  border: none;
  width: 100%;
  padding: 0.75rem;
  font-weight: 600;
  border-radius: 8px;
  transition: all 0.3s ease;
}

.autoparts-add-cart-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(30, 64, 175, 0.3);
}

/* Trending Categories Section - Enhanced for Figma Design */
.autoparts-trending-section {
  padding: 4rem 0;
  background: linear-gradient(180deg, #f8fafc 0%, #ffffff 100%) !important;
}

.autoparts-category-card {
  background: white;
  border: 2px solid #e2e8f0;
  border-radius: 16px;
  overflow: hidden;
  transition: all 0.3s ease;
  position: relative;
}

.autoparts-category-card:hover {
  border-color: #1e40af;
  transform: translateY(-5px);
  box-shadow: 0 20px 40px rgba(30, 64, 175, 0.15);
}

.autoparts-category-image {
  height: 200px;
  overflow: hidden;
}

.autoparts-category-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.autoparts-category-card:hover .autoparts-category-image img {
  transform: scale(1.1);
}

.autoparts-category-content {
  padding: 1.5rem;
}

.autoparts-category-name {
  color: #0f172a;
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
}

.autoparts-category-count {
  color: #64748b;
  font-size: 0.875rem;
}

/* Brands Section - Enhanced for Figma Design */
.autoparts-brands-section {
  padding: 4rem 0;
  background: white;
}

.autoparts-brand-card {
  background: white;
  border: 2px solid #e2e8f0;
  border-radius: 12px;
  padding: 2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 120px;
  transition: all 0.3s ease;
}

.autoparts-brand-card:hover {
  border-color: #1e40af;
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(30, 64, 175, 0.1);
}

.autoparts-brand-card img {
  max-width: 100%;
  max-height: 60px;
  object-fit: contain;
  filter: grayscale(100%);
  transition: filter 0.3s ease;
}

.autoparts-brand-card:hover img {
  filter: grayscale(0%);
}

/* Add Vehicle Modal Styles */
.autoparts-vehicle-modal .modal-dialog {
  max-width: 900px;
  margin: 1.75rem auto;
}

.autoparts-vehicle-modal .modal-header {
  border-bottom: 2px solid #e2e8f0;
  padding: 1.5rem 2rem;
  background-color: #f8fafc;
}

.autoparts-vehicle-modal .modal-title {
  color: #0f172a;
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 0;
}

.autoparts-vehicle-modal .modal-body {
  padding: 2rem;
}

.autoparts-vehicle-modal .vehicle-tabs {
  margin-bottom: 2rem;
}

.autoparts-vehicle-modal .vehicle-tabs .nav-tabs {
  border-bottom: 2px solid #e2e8f0;
}

.autoparts-vehicle-modal .vehicle-tabs .nav-link {
  color: #64748b;
  font-weight: 600;
  padding: 1rem 1.5rem;
  border: none;
  border-bottom: 3px solid transparent;
}

.autoparts-vehicle-modal .vehicle-tabs .nav-link.active {
  color: #1e40af;
  border-bottom-color: #1e40af;
  background-color: transparent;
}

.autoparts-vehicle-modal .vehicle-form-row {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.autoparts-vehicle-modal .form-group {
  margin-bottom: 1rem;
}

.autoparts-vehicle-modal .form-label {
  color: #0f172a;
  font-weight: 600;
  margin-bottom: 0.5rem;
  display: block;
}

.autoparts-vehicle-modal .form-label .required {
  color: #dc2626;
}

.autoparts-vehicle-modal .form-select {
  border: 2px solid #e2e8f0;
  border-radius: 8px;
  padding: 0.75rem 1rem;
  font-size: 0.9rem;
  transition: border-color 0.3s ease;
  width: 100%;
}

.autoparts-vehicle-modal .form-select:focus {
  border-color: #1e40af;
  outline: none;
  box-shadow: 0 0 0 3px rgba(30, 64, 175, 0.1);
}

.autoparts-vehicle-modal .form-input {
  border: 2px solid #e2e8f0;
  border-radius: 8px;
  padding: 0.75rem 1rem;
  font-size: 0.9rem;
  transition: border-color 0.3s ease;
  width: 100%;
}

.autoparts-vehicle-modal .form-input:focus {
  border-color: #1e40af;
  outline: none;
  box-shadow: 0 0 0 3px rgba(30, 64, 175, 0.1);
}

.autoparts-vehicle-modal .form-input::placeholder {
  color: #94a3b8;
}

.autoparts-vehicle-modal .vin-description {
  color: #64748b;
  font-size: 0.8rem;
  margin-top: 0.5rem;
}

.autoparts-vehicle-modal .modal-footer {
  border-top: 2px solid #e2e8f0;
  padding: 1.5rem 2rem;
  background-color: #f8fafc;
}

.autoparts-vehicle-modal .save-btn {
  background: linear-gradient(135deg, #94a3b8 0%, #64748b 100%);
  color: white;
  border: none;
  padding: 0.75rem 2rem;
  font-weight: 600;
  border-radius: 8px;
  transition: all 0.3s ease;
  min-width: 120px;
}

.autoparts-vehicle-modal .save-btn:not(:disabled) {
  background: linear-gradient(135deg, #1e40af 0%, #1e3a8a 100%);
  cursor: pointer;
}

.autoparts-vehicle-modal .save-btn:not(:disabled):hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(30, 64, 175, 0.3);
}

.autoparts-vehicle-modal .save-btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.autoparts-vehicle-modal .btn-close {
  background: transparent;
  border: none;
  font-size: 1.5rem;
  color: #64748b;
  padding: 0;
  opacity: 0.7;
  transition: opacity 0.3s ease;
}

.autoparts-vehicle-modal .btn-close:hover {
  opacity: 1;
  color: #dc2626;
}

/* Responsive Design */
@media (max-width: 768px) {
  .autoparts-hero-banner {
    height: 400px;
  }
  
  .autoparts-hero-title {
    font-size: 2.5rem;
  }
  
  .autoparts-hero-subtitle {
    font-size: 1.25rem;
  }
  
  .autoparts-section-title {
    font-size: 2rem;
  }
  
  .autoparts-vehicle-modal .modal-dialog {
    margin: 1rem;
    max-width: calc(100% - 2rem);
  }
  
  .autoparts-vehicle-modal .modal-body {
    padding: 1rem;
  }
  
  .autoparts-vehicle-modal .vehicle-form-row {
    grid-template-columns: 1fr;
    gap: 0.5rem;
  }
  
  .autoparts-vehicle-modal .vehicle-tabs .nav-link {
    padding: 0.75rem 1rem;
    font-size: 0.9rem;
  }
}

body.multiseller-design-editor .el-drawer__body {
  overflow-y: auto;
}
body.multiseller-design-editor .menu-fixed {
  display: none;
}
body.multiseller-design-editor .pb-images-selector .pb-images-selector-add {
  width: 100%;
  margin-top: 16px;
  padding: 10px 20px;
}
body.multiseller-design-editor .pb-images-selector .pb-images-list {
  border: 1px solid #eee;
  margin-bottom: 8px;
  padding: 5px;
  border-radius: 6px;
  padding-bottom: 8px;
}
body.multiseller-design-editor .pb-images-selector .pb-images-list:hover {
  border-color: #409EFF;
}
body.multiseller-design-editor .pb-images-selector .pb-images-list .pb-images-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 7px;
}
body.multiseller-design-editor .pb-images-selector .pb-images-list .pb-image-selector-wrapper {
  display: flex;
  align-items: center;
}
body.multiseller-design-editor .pb-images-selector .pb-images-list .pb-image-selector-wrapper span {
  margin-left: 4px;
}
body.multiseller-design-editor .pb-images-selector .pb-images-list .pb-image-selector {
  cursor: pointer;
  min-width: 50px;
  min-height: 50px;
}
body.multiseller-design-editor .pb-images-selector .pb-images-list .pb-images-btns button {
  margin-left: 0 !important;
  padding: 9px 10px;
}
body.multiseller-design-editor .pb-images-selector .pb-images-list .el-input-group__prepend {
  padding: 0 10px;
}
body.multiseller-design-editor .seller-modules-image .modules-image-list {
  display: flex;
  align-items: center;
  margin: 0 -10px;
}
body.multiseller-design-editor .seller-modules-image .modules-image-list > div {
  padding: 0 10px;
}
body.multiseller-design-editor .seller-modules-image .img-style-301, body.multiseller-design-editor .seller-modules-image .img-style-401 {
  margin-top: -20px;
}
body.multiseller-design-editor .seller-modules-image .img-style-301 img, body.multiseller-design-editor .seller-modules-image .img-style-401 img {
  display: block;
  margin-top: 20px;
}
body.multiseller-design-editor .module-heading-edit .heading-item {
  margin-bottom: 16px;
  padding-bottom: 16px;
  border-bottom: 1px solid #eee;
}
body.multiseller-design-editor .module-heading-edit .heading-item .heading-item-x {
  display: flex;
  align-items: center;
}
body.multiseller-design-editor .module-heading-edit .heading-item .heading-item-x > div {
  width: 50%;
}
body.multiseller-design-editor .module-heading-edit .heading-item .heading-item-x > div.heading-color-edit {
  margin-right: 10px;
}
body.multiseller-design-editor .module-heading-edit .heading-item .title {
  font-size: 14px;
  margin-bottom: 5px;
}
body.multiseller-design-editor .products-box {
  overflow: hidden;
}
body.multiseller-design-editor .products-box .product-wrapper .product-item {
  margin-bottom: 20px;
  overflow: hidden;
}
body.multiseller-design-editor .products-box .product-wrapper .product-item .flash-price-wrapper > .left-price {
  padding-left: 6px;
}
body.multiseller-design-editor .products-box .product-wrapper .product-item .product-name {
  overflow: hidden;
  height: 38px;
  margin: 8px 0;
  color: #111;
  font-weight: bold;
  font-size: 13px;
}
body.multiseller-design-editor .products-box .product-wrapper .product-item .price {
  font-size: 16px;
  margin-bottom: 0;
  color: #d4282d;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
@media (max-width: 768px) {
  body.multiseller-design-editor .products-box .product-wrapper .product-item .price {
    font-size: 14px;
    text-overflow: ellipsis;
    overflow: hidden;
    white-space: nowrap;
  }
}
body.multiseller-design-editor .products-box .product-wrapper .product-item .price .price-old {
  font-weight: 500;
  color: #bbb;
  font-size: 12px;
  text-decoration: line-through;
}
body.multiseller-design-editor .products-box .product-wrapper .product-item .price .price-tax {
  color: #bbb;
  font-size: 12px;
}
body.multiseller-design-editor .products-box .product-wrapper .product-item .price .price-left {
  text-overflow: ellipsis;
  overflow: hidden;
  white-space: nowrap;
}
body.multiseller-design-editor .products-box .product-wrapper .product-item .price .price-left > div {
  text-overflow: ellipsis;
  overflow: hidden;
  white-space: nowrap;
}
body.multiseller-design-editor .products-box .product-wrapper .product-item .price .price-right {
  max-width: 50%;
  display: flex;
  align-items: center;
}
body.multiseller-design-editor .products-box .product-wrapper .product-item .price .price-right span {
  text-overflow: ellipsis;
  overflow: hidden;
  white-space: nowrap;
  display: block;
}
body.multiseller-design-editor .products-box .product-wrapper .product-item .price .flag-icon {
  font-size: 12px;
  background: #ee3333;
  padding: 1px 2px;
  min-width: 32px;
  border-radius: 2px;
  color: #fff;
  text-align: center;
}
body.multiseller-design-editor .products-box .product-wrapper .product-item .price .seller-icon {
  padding: 0 2px;
  border: 1px solid #fdad00;
  color: #fdad00;
  border-radius: 2px;
  font-size: 12px;
  margin-right: 2px;
}
body.multiseller-design-editor .products-box .product-wrapper .product-item .price .seller-icon a {
  color: #fdad00;
}
body.multiseller-design-editor .products-box .product-wrapper.product-list .product-image {
  float: left;
  width: 130px;
}
body.multiseller-design-editor .products-box .product-wrapper.product-list .product-info {
  width: calc(100% - 130px);
}

#multiseller-design-editor-app .no-info {
  height: 150px;
  display: flex;
  justify-content: center;
  align-items: center;
  font-size: 16px;
}
#multiseller-design-editor-app .editor-top-tool {
  position: fixed;
  top: 0;
  right: 0;
  width: 100%;
  background: rgba(0, 0, 0, 0.6);
  text-align: center;
  padding: 10px 0;
  z-index: 999;
  border-bottom: 1px solid #eee;
  box-shadow: 0 2px 16px 1px rgba(0, 0, 0, 0.1);
}
#multiseller-design-editor-app .editor-top-tool .editor-top-title {
  font-weight: bold;
  color: #fff;
  font-size: 16px;
}
#multiseller-design-editor-app .editor-top-tool .editor-top-info {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
#multiseller-design-editor-app .editor-top-tool button {
  padding: 9px 20px;
}
#multiseller-design-editor-app .pe-canvas .pe-module-wrapper {
  position: relative;
  overflow: hidden;
  border-top: 1px dashed #409EFF;
}
#multiseller-design-editor-app .pe-canvas .pe-module-wrapper:before {
  content: '';
  position: absolute;
  width: 100%;
  left: 0;
  height: 100%;
  top: 0;
  z-index: 9;
  background: rgba(255, 0, 0, 0.05);
  display: none;
}
#multiseller-design-editor-app .pe-canvas .pe-module-wrapper:hover {
  border-top: 1px solid #409EFF;
}
#multiseller-design-editor-app .pe-canvas .pe-module-wrapper:hover:before {
  display: block;
}
#multiseller-design-editor-app .pe-canvas .action-group {
  position: absolute;
  top: 0;
  left: 0;
  z-index: 99;
  background: #409EFF;
  border-radius: 0 0 4px 0;
  overflow: hidden;
}
#multiseller-design-editor-app .pe-canvas .action-group span {
  padding: 2px;
  text-align: center;
  line-height: 26px;
  color: #fff;
  width: 30px;
  height: 30px;
  display: inline-block;
  cursor: pointer;
}
#multiseller-design-editor-app .pe-canvas .action-group span:hover {
  background: #fff;
  color: #409EFF;
}
#multiseller-design-editor-app .add-module {
  margin-top: 20px;
  text-align: center;
  border: 2px dashed #ddd;
  cursor: pointer;
  padding: 20px 10px;
  border-radius: 6px;
  font-size: 20px;
  color: #222;
  transition: all 0.3s ease 0s;
}
#multiseller-design-editor-app .add-module:hover {
  color: #799af5;
  border-color: #799af5;
}
#multiseller-design-editor-app .no-module {
  min-height: 400px;
  display: flex;
  color: #555;
  align-items: center;
  justify-content: center;
  font-size: 40px;
}

.global-edit .global-item {
  margin-bottom: 10px;
}
.global-edit .global-item .global-title {
  margin-bottom: 6px;
}

.el-drawer__header {
  margin-bottom: 0;
  padding: 10px;
  border-bottom: 1px solid #eee;
}
.el-drawer__header span {
  font-weight: bold;
  color: #222;
}

.module-edit-drawer .el-drawer__header {
  margin-bottom: 10px;
  padding: 10px 20px;
}
.module-edit-drawer .el-slider__runway.show-input {
  margin-left: 10px;
}

.modal-button-wrapper {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  padding: 0 0 0 10px;
}
.modal-button-wrapper div {
  width: 50%;
  padding-right: 10px;
  margin-bottom: 10px;
}
.modal-button-wrapper div i {
  color: #409EFF;
}
.modal-button-wrapper .el-button {
  padding: 16px 12px;
  font-size: 16px;
  text-align: left;
  width: 100%;
}
.modal-button-wrapper .el-button + .el-button {
  margin-left: 0;
}
