html {
  font-size: 14px;
}

@media (min-width: 768px) {
  html {
    font-size: 16px;
  }
}

.btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-check-input:focus {
  box-shadow: 0 0 0 0.1rem white, 0 0 0 0.25rem #258cfb;
}

html {
  position: relative;
  min-height: 100%;
}

body {
  margin-bottom: 60px;
}

.form-floating > .form-control-plaintext::placeholder, .form-floating > .form-control::placeholder {
  color: var(--bs-secondary-color);
  text-align: end;
}

.form-floating > .form-control-plaintext:focus::placeholder, .form-floating > .form-control:focus::placeholder {
  text-align: start;
}

.catalog-card-img {
    width: 100%;
    height: clamp(160px, 24vw, 220px);
    object-fit: contain;
    background-color: #fff;
}

.catalog-card {
    transition: background-color 0.2s ease, border-color 0.2s ease;
}

.catalog-card:hover {
    background-color: #f1f3f5;
    border-color: #d5dbe1;
}

.catalog-card-body {
    display: flex;
    align-items: center;
    justify-content: center;
}

.catalog-card-info {
    min-height: 72px;
}

.catalog-card-title {
    min-height: 2.6em;
    line-height: 1.3;
    margin-bottom: 0.25rem;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 4;
    -webkit-box-orient: vertical;
}

.catalog-card-price {
    font-weight: 600;
}

@media (max-width: 576px) {
    .catalog-card-img {
        height: 125px;
    }

    .catalog-card-body {
        padding: 0.65rem !important;
    }

    .catalog-card-info {
        min-height: auto;
    }

    .catalog-card-title {
        min-height: 0;
        font-size: 0.85rem;
        line-height: 1.2;
        margin-bottom: 0.15rem;
        padding-inline: 0.1rem;
    }

    .catalog-card-price {
        font-size: 0.82rem;
    }
}

@media (max-width: 400px) {
    .catalog-card-img {
        height: 110px;
    }
}

.navbar-actions .nav-action-btn {
    padding: 0.35rem 0.6rem;
    line-height: 1.2;
}

.navbar-actions {
    margin-left: auto;
}

.search-input-wrap {
    position: relative;
    flex: 1 1 auto;
    min-width: 0;
}

.search-clear-btn {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    border: 0;
    background: transparent;
    color: #6c757d;
    padding: 0;
    line-height: 1;
    font-size: 18px;
    cursor: pointer;
    z-index: 3;
}

.search-clear-btn:hover {
    color: #212529;
}

.search-suggestions {
    position: absolute;
    top: calc(100% + 2px);
    left: 0;
    right: 0;
    z-index: 1050;
    max-height: 340px;
    overflow-y: auto;
}
