.cwvf-wrapper {
  margin: 1rem 0 1.5rem;
  border: 1px solid #e3e5e8;
  border-radius: 8px;
  background: #fff;
}

.cwvf-card-block {
  padding: 1rem;
}

.cwvf-form {
  width: 100%;
}

.cwvf-title {
  margin-bottom: 1rem;
}

.cwvf-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
  margin-bottom: 1rem;
}

.cwvf-grid .form-group {
  margin-bottom: 0;
}

.cwvf-form-group {
  width: 100%;
}

.cwvf-grid label {
  display: block;
  margin-bottom: 0.35rem;
  font-size: 0.9rem;
  font-weight: 600;
}

.cwvf-control {
  width: 100%;
  height: 44px;
  padding: 0 0.75rem;
  border: 1px solid #cfd4dc;
  border-radius: 6px;
  background: #fff;
  color: #1f2937;
}

.cwvf-control:focus {
  border-color: #1f6feb;
  outline: 0;
  box-shadow: 0 0 0 3px rgba(31, 111, 235, 0.15);
}

.cwvf-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0.6rem 1rem;
  border-radius: 6px;
  border: 1px solid transparent;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.cwvf-btn-primary {
  background: #1f6feb;
  border-color: #1f6feb;
  color: #fff;
}

.cwvf-btn-primary:hover,
.cwvf-btn-primary:focus {
  background: #185dc7;
  border-color: #185dc7;
  color: #fff;
}

.cwvf-btn-secondary {
  background: #fff;
  border-color: #cfd4dc;
  color: #2f3b4a;
}

.cwvf-btn-secondary:hover,
.cwvf-btn-secondary:focus {
  background: #f6f8fb;
  border-color: #b8c1cd;
  color: #1f2937;
}

.cwvf-submit {
  min-width: 240px;
}

.cwvf-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  align-items: center;
}

.cwvf-actions .btn {
  min-height: 44px;
}

.cwvf-reset {
  min-width: 180px;
}

.cwvf-results-meta {
  margin: 1rem 0;
}

.cwvf-alert {
  margin: 1rem 0 0;
  padding: 0.75rem 0.9rem;
  border-radius: 6px;
  border: 1px solid transparent;
}

.cwvf-alert-warning {
  background: #fff8e6;
  border-color: #ffe2a8;
  color: #7a5800;
}

.cwvf-product-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1rem;
}

.cwvf-product-card {
  border: 1px solid #e5e5e5;
  border-radius: 6px;
  overflow: hidden;
  background: #fff;
}

.cwvf-product-link {
  color: inherit;
  display: block;
  padding: 0.75rem;
  text-decoration: none;
}

.cwvf-product-link img {
  display: block;
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: contain;
  background: #f7f7f7;
  margin-bottom: 0.6rem;
}

.cwvf-product-link h4 {
  font-size: 0.95rem;
  line-height: 1.35;
  min-height: 2.6rem;
  margin: 0 0 0.5rem;
}

.cwvf-price {
  font-weight: 700;
}

@media (max-width: 1199px) {
  .cwvf-product-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 991px) {
  .cwvf-wrapper {
    margin: 0.75rem 0 1.25rem;
  }

  .cwvf-title {
    font-size: 1.15rem;
    line-height: 1.3;
  }

  .cwvf-grid {
    grid-template-columns: 1fr;
    gap: 0.75rem;
  }

  .cwvf-grid .form-control {
    min-height: 44px;
  }

  .cwvf-actions {
    gap: 0.5rem;
  }

  .cwvf-submit,
  .cwvf-reset {
    min-width: 0;
    width: 100%;
  }

  .cwvf-product-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.75rem;
  }

  .cwvf-product-link {
    padding: 0.65rem;
  }
}

@media (max-width: 575px) {
  .cwvf-wrapper .card-block,
  .cwvf-card-block {
    padding: 0.8rem;
  }

  .cwvf-title {
    font-size: 1.05rem;
    margin-bottom: 0.8rem;
  }

  .cwvf-product-link h4 {
    font-size: 0.9rem;
    min-height: 0;
  }

  .cwvf-product-grid {
    grid-template-columns: 1fr;
  }
}

