@import "./variables.css";

.card-product {
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card-product:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-lg);
}

.card-product img.card-img-top {
  border-top-left-radius: var(--radius-lg);
  border-top-right-radius: var(--radius-lg);
  object-fit: cover;
  height: 250px;
}

.card-body {
  padding: 1rem 1.25rem;
}

.card-title {
  font-size: 1rem;
  font-weight: 600;
  min-height: 3rem;
  margin-bottom: 0.5rem;
}

.price {
  font-size: 1.1rem;
  font-weight: bold;
  margin-bottom: 0.3rem;
  color: var(--danger-color);
}

.stars {
  color: var(--warning-color);
  font-size: 0.9rem;
  margin-bottom: 0.5rem;
}

.card-text small.text-muted {
  opacity: 0.7;
}

.btn-outline-primary {
  border-radius: var(--radius-sm);
  transition: background-color 0.3s ease, color 0.3s ease;
}

.btn-outline-primary:hover {
  background-color: var(--primary-color);
  color: white;
  box-shadow: 0 4px 8px rgba(13, 110, 253, 0.3);
}

.card-product .total-price {
  display: flex;
  flex-wrap: nowrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.4rem;
}

.card-product .total-price .price,
.card-product .total-price .old-price {
  white-space: nowrap;
  margin: 0;
}

.card-product .total-price .old-price {
  font-size: 0.85rem;
  color: #6c757d;
  text-align: right;
}

.card-product .total-price .discount {
  color: #dc3545;
  margin-left: 0.15rem;
}

.title-product {
  text-decoration: none;
  color: black;
  font-size: 16px;
}

.title-product:hover {
  color: var(--primary-color);
}

.title-warranty {
  color: rgba(33, 37, 41, 0.75);
  font-size: 14px;
  font-weight: 300;
}

.title-home-product, 
.title-home-news {
  text-transform: uppercase;
  font-size: 1.6rem;
  font-weight: 700;
  margin-bottom: 20px;
}

.card-news {
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card-news:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
}

.card-news img {
  object-fit: cover;
  height: 200px;
}

.card-news .card-title {
  font-size: 1.1rem;
  font-weight: 600;
  transition: color 0.3s ease;
  min-height: 3.2rem;
}

.card-news .card-title a {
  color: var(--dark-color);
  text-decoration: none;
}

.card-news .card-title a:hover {
  color: var(--primary-color);
}

.card-news .card-text {
  font-size: 0.95rem;
  color: var(--muted-color);
  min-height: 4.2rem;
}

.ecosystem-title {
  font-size: 2rem;
  font-weight: bold;
}

.ecosystem-subtitle {
  font-size: 1.1rem;
  color: var(--muted-color);
}

.product-box {
  display: flex;
  align-items: center;
  background: var(--card-bg);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  padding: 10px 15px;
  margin-bottom: 20px;
  transition: var(--transition-normal);
  text-decoration: none;
  color: black;
}

.product-box:hover {
  box-shadow: var(--shadow-md);
  color: #1c57c4;
  transform: translateY(-5px);
}

.product-box img {
  width: 100%;
  height: 300px;
  object-fit: cover;
  border-radius: var(--radius-md);
}

.section-title {
  font-size: 1.8rem;
  font-weight: bold;
  margin: 20px 0 10px;
}

.product-icon {
  width: 60px;
  height: 60px;
  background: var(--brand-color);
  display: flex;
  justify-content: center;
  align-items: center;
  border-radius: var(--radius-md);
  margin-right: 15px;
  flex-shrink: 0;
}

.product-icon i {
  font-size: 24px;
  color: #ffffff;
}

.product-title {
  font-weight: 500;
  font-size: 1rem;
  margin: 0;
}

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

  .ecosystem-title {
    font-size: 1.6rem;
  }

  .ecosystem-subtitle {
    font-size: 1rem;
  }
}

@media (max-width: 575.98px) {
  .card-news img {
    height: 160px;
  }

  .card-product .total-price {
    gap: 0.3rem;
  }

   .card-product .total-price .price {
    font-size: clamp(0.95rem, 4.6vw, 1.1rem);
  }

  .card-product .total-price .old-price {
    font-size: clamp(0.72rem, 3.3vw, 0.85rem);
  }
}

@media (max-width: 359.98px) {
  .card-product .total-price .price {
    font-size: 0.9rem;
  }

  .card-product .total-price .old-price {
    font-size: 0.7rem;
  }
}
