:root {
  --bg-color: #D6EFD8;
  --primary-color: #80AF81;
  --secondary-color: #508D4E;
  --text-color: #1A5319;
  --font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: var(--font-family);
  background-color: var(--bg-color);
  color: var(--text-color);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

a {
  color: var(--secondary-color);
  text-decoration: none;
  transition: color 0.2s ease;
}

a:hover {
  color: var(--text-color);
}

.navbar {
  background: linear-gradient(135deg, var(--secondary-color), var(--text-color));
  padding: 0.75rem 0;
}

.navbar .navbar-brand {
  color: #fff;
  font-size: 1.3rem;
  letter-spacing: 0.5px;
}

.navbar .navbar-brand:hover {
  color: rgba(255, 255, 255, 0.9);
}

.navbar .nav-link {
  color: rgba(255, 255, 255, 0.85);
  font-weight: 500;
  padding: 0.5rem 1rem;
  border-radius: 6px;
  transition: all 0.2s ease;
}

.navbar .nav-link:hover,
.navbar .nav-link:focus {
  color: #fff;
  background-color: rgba(255, 255, 255, 0.1);
}

.navbar-toggler {
  border-color: rgba(255, 255, 255, 0.5);
}

.navbar-toggler-icon {
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba%28255, 255, 255, 0.85%29' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
}

.lang-switch {
  border: 1px solid rgba(255, 255, 255, 0.4);
  font-size: 0.9rem;
}

.section-title {
  color: var(--text-color);
  font-weight: 700;
  position: relative;
  padding-bottom: 0.75rem;
}

.section-title::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 60px;
  height: 3px;
  background: linear-gradient(to right, var(--primary-color), var(--secondary-color));
  border-radius: 2px;
}

.section-alt {
  background-color: rgba(255, 255, 255, 0.5);
}

.carousel-img {
  width: 100%;
  height: 500px;
  object-fit: cover;
}

@media (max-width: 768px) {
  .carousel-img {
    height: 300px;
  }
}

.carousel-control-prev-icon,
.carousel-control-next-icon {
  background-color: rgba(0, 0, 0, 0.3);
  border-radius: 50%;
  padding: 1.5rem;
  background-size: 50%;
}

.carousel-indicators button {
  background-color: var(--primary-color);
}

.card {
  border: none;
  border-radius: 12px;
  overflow: hidden;
  transition: all 0.3s ease;
  background: #fff;
}

.product-card {
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
}

.product-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.15);
}

.card-img-wrapper {
  position: relative;
  overflow: hidden;
}

.product-img {
  height: 240px;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.product-card:hover .product-img {
  transform: scale(1.05);
}

.product-img-placeholder {
  height: 240px;
  background: linear-gradient(135deg, #f0f0f0, #e8e8e8);
}

.product-name {
  color: var(--text-color);
  font-weight: 600;
  font-size: 1rem;
  margin-bottom: 0.5rem;
}

.featured-badge {
  position: absolute;
  top: 12px;
  right: 12px;
  background: linear-gradient(135deg, #f59e0b, #d97706);
  color: #fff;
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 600;
  box-shadow: 0 2px 8px rgba(245, 158, 11, 0.3);
}

html[dir="rtl"] .featured-badge {
  right: auto;
  left: 12px;
}

.brand-badge {
  background-color: var(--primary-color);
  color: #fff;
  font-weight: 500;
  font-size: 0.75rem;
}

.category-badge {
  background-color: rgba(80, 141, 78, 0.15);
  color: var(--secondary-color);
  font-weight: 500;
  font-size: 0.75rem;
}

.brand-selector {
  background: #fff;
  border-radius: 16px;
  padding: 1.5rem;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
}

.brand-option {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  color: var(--text-color);
  border: 2px solid transparent;
  border-radius: 12px;
  padding: 0.75rem 1.25rem;
  transition: all 0.3s ease;
  background: #f8f9fa;
  min-width: 100px;
  text-align: center;
}

.brand-option:hover {
  border-color: var(--primary-color);
  background: rgba(128, 175, 129, 0.1);
  color: var(--text-color);
}

.brand-option.active {
  border-color: var(--secondary-color);
  background: rgba(80, 141, 78, 0.1);
  box-shadow: 0 0 0 2px rgba(80, 141, 78, 0.2);
}

.brand-logo-wrapper {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.25rem;
}

.brand-logo-img {
  height: 50px;
  width: auto;
  max-width: 120px;
  object-fit: contain;
}

.product-gallery .main-image-wrapper {
  background: #fff;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 2px 20px rgba(0, 0, 0, 0.08);
}

.main-product-img {
  width: 100%;
  max-height: 500px;
  object-fit: contain;
  border-radius: 16px;
}

.thumbnail-strip {
  padding-top: 0.5rem;
}

.thumbnail-item {
  width: 72px;
  height: 72px;
  border-radius: 8px;
  overflow: hidden;
  cursor: pointer;
  border: 2px solid transparent;
  transition: all 0.2s ease;
  background: #fff;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.08);
}

.thumbnail-item:hover {
  border-color: var(--primary-color);
}

.thumbnail-item.active {
  border-color: var(--secondary-color);
  box-shadow: 0 0 0 2px rgba(80, 141, 78, 0.3);
}

.thumbnail-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.product-details {
  padding: 1rem 0;
}

.product-title {
  font-size: 2rem;
  font-weight: 700;
  color: var(--text-color);
}

.brand-detail-logo {
  height: 36px;
  width: auto;
  object-fit: contain;
}

.variant-list .list-group-item {
  border-radius: 8px;
  margin-bottom: 0.25rem;
  border-color: rgba(0, 0, 0, 0.06);
}

.certification-card {
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
  transition: transform 0.3s ease;
}

.certification-card:hover {
  transform: translateY(-4px);
}

.cert-img-wrapper {
  width: 80px;
  height: 80px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
}

.cert-img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}

.cert-title {
  color: var(--text-color);
  font-weight: 600;
}

.cert-desc {
  font-size: 0.9rem;
}

.contact-info {
  background: #fff;
  border-radius: 16px;
  padding: 2rem;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
  height: 100%;
}

.contact-item {
  display: flex;
  align-items: center;
  font-size: 1rem;
}

.contact-item i {
  color: var(--secondary-color);
  font-size: 1.2rem;
  min-width: 30px;
}

.contact-item a {
  color: var(--text-color);
}

.contact-item a:hover {
  color: var(--secondary-color);
}

.social-links {
  display: flex;
  gap: 0.75rem;
}

.social-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
  color: #fff;
  font-size: 1.2rem;
  transition: all 0.3s ease;
}

.social-link:hover {
  transform: scale(1.1);
  color: #fff;
  box-shadow: 0 4px 12px rgba(80, 141, 78, 0.4);
}

.contact-form {
  background: #fff;
  border-radius: 16px;
  padding: 2rem;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
}

.contact-form .form-control,
.contact-form .form-select {
  border-radius: 8px;
  border-color: #dee2e6;
  padding: 0.65rem 1rem;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.contact-form .form-control:focus,
.contact-form .form-select:focus {
  border-color: var(--primary-color);
  box-shadow: 0 0 0 0.2rem rgba(128, 175, 129, 0.25);
}

.contact-form .form-label {
  font-weight: 500;
  color: var(--text-color);
  font-size: 0.9rem;
}

.btn-primary-custom {
  background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
  color: #fff;
  border: none;
  border-radius: 8px;
  font-weight: 600;
  padding: 0.65rem 1.5rem;
  transition: all 0.3s ease;
}

.btn-primary-custom:hover {
  background: linear-gradient(135deg, var(--secondary-color), var(--text-color));
  color: #fff;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(80, 141, 78, 0.3);
}

.btn-primary-custom:disabled {
  opacity: 0.6;
  transform: none;
  box-shadow: none;
}

.btn-outline-primary-custom {
  color: var(--secondary-color);
  border: 2px solid var(--secondary-color);
  border-radius: 8px;
  font-weight: 600;
  padding: 0.65rem 1.5rem;
  background: transparent;
  transition: all 0.3s ease;
}

.btn-outline-primary-custom:hover {
  background: var(--secondary-color);
  color: #fff;
  transform: translateY(-1px);
}

.about-content {
  font-size: 1.15rem;
  line-height: 1.8;
  color: var(--text-color);
}

.coming-soon {
  color: var(--text-color);
}

.coming-soon i {
  color: var(--primary-color);
}

.breadcrumb {
  background: rgba(255, 255, 255, 0.7);
  padding: 0.75rem 1.25rem;
  border-radius: 10px;
}

.breadcrumb-item a {
  color: var(--secondary-color);
  font-weight: 500;
}

.breadcrumb-item.active {
  color: var(--text-color);
}

.site-footer {
  background: linear-gradient(135deg, var(--secondary-color), var(--text-color));
  color: #fff;
  margin-top: auto;
}

.site-footer a {
  color: rgba(255, 255, 255, 0.8);
}

.site-footer a:hover {
  color: #fff;
}

#catalogSearch,
#categoryFilter {
  border-radius: 8px;
  border-color: #dee2e6;
  padding: 0.65rem 1rem;
}

#catalogSearch:focus,
#categoryFilter:focus {
  border-color: var(--primary-color);
  box-shadow: 0 0 0 0.2rem rgba(128, 175, 129, 0.25);
}

.input-group-text {
  background: var(--primary-color);
  color: #fff;
  border-color: var(--primary-color);
  border-radius: 8px 0 0 8px;
}

html[dir="rtl"] .input-group-text {
  border-radius: 0 8px 8px 0;
}

html[dir="rtl"] .input-group .form-control {
  border-radius: 8px 0 0 8px;
}

html[dir="rtl"] .me-2 {
  margin-right: 0 !important;
  margin-left: 0.5rem !important;
}

html[dir="rtl"] .ms-1 {
  margin-left: 0 !important;
  margin-right: 0.25rem !important;
}

html[dir="rtl"] .me-3 {
  margin-right: 0 !important;
  margin-left: 1rem !important;
}

html[dir="rtl"] .carousel-control-prev {
  right: 0;
  left: auto;
}

html[dir="rtl"] .carousel-control-next {
  left: 0;
  right: auto;
}

@media (max-width: 576px) {
  .section-title {
    font-size: 1.5rem;
  }

  .product-title {
    font-size: 1.5rem;
  }

  .brand-option {
    min-width: 80px;
    padding: 0.5rem 0.75rem;
  }

  .brand-logo-img {
    height: 36px;
  }

  .contact-form,
  .contact-info {
    padding: 1.25rem;
  }

  .social-link {
    width: 38px;
    height: 38px;
    font-size: 1rem;
  }
}

@media (max-width: 768px) {
  .thumbnail-item {
    width: 60px;
    height: 60px;
  }
}

::selection {
  background: var(--primary-color);
  color: #fff;
}

::-webkit-scrollbar {
  width: 8px;
}

::-webkit-scrollbar-track {
  background: var(--bg-color);
}

::-webkit-scrollbar-thumb {
  background: var(--primary-color);
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--secondary-color);
}
