/* QualityPack — search modal + standalone page styles. */

/* ---------- Modal overlay triggered from the header magnifier ---------- */

.qp-search-overlay {
  position: fixed;
  inset: 0;
  z-index: 1080;
  visibility: hidden;
  opacity: 0;
  transition: opacity .25s ease, visibility .25s ease;
}
.qp-search-overlay.is-open {
  visibility: visible;
  opacity: 1;
}
.qp-search-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 30, 0.55);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
}
.qp-search-panel {
  position: relative;
  background: #fff;
  width: min(880px, calc(100% - 32px));
  margin: 4rem auto 0;
  border-radius: 14px;
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.35);
  padding: 2.25rem 1.75rem 1.5rem;
  transform: translateY(-16px);
  transition: transform .25s ease;
  max-height: calc(100vh - 6rem);
  display: flex;
  flex-direction: column;
}
.qp-search-overlay.is-open .qp-search-panel {
  transform: translateY(0);
}
.qp-search-close {
  position: absolute;
  top: 10px;
  right: 14px;
  background: transparent;
  border: 0;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  font-size: 22px;
  color: #888;
  cursor: pointer;
  transition: background .15s ease, color .15s ease;
}
.qp-search-close:hover {
  background: #f3f5f7;
  color: #111;
}
.qp-search-eyebrow {
  font-size: 0.78rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: #6c7770;
  text-align: center;
  margin-bottom: 0.6rem;
}
.qp-search-title {
  font-size: 1.3rem;
  color: #1f2a24;
  text-align: center;
  margin: 0 0 1.25rem;
  font-weight: 700;
}
.qp-search-box {
  position: relative;
  margin-bottom: 0.5rem;
}
.qp-search-box .qp-icon {
  position: absolute;
  left: 22px;
  top: 50%;
  transform: translateY(-50%);
  color: #9aa3a0;
  font-size: 1.05rem;
  pointer-events: none;
}
.qp-search-input {
  width: 100%;
  padding: 16px 56px 16px 56px;
  font-size: 1.05rem;
  font-family: inherit;
  border: 1px solid #e6ebee;
  border-radius: 50px;
  outline: none;
  background: #fbfcfd;
  transition: border-color .2s ease, box-shadow .2s ease, background .2s ease;
}
.qp-search-input:focus {
  border-color: #94c93d;
  background: #fff;
  box-shadow: 0 0 0 4px rgba(148, 201, 61, 0.12);
}
.qp-search-clear {
  position: absolute;
  right: 14px;
  top: 50%;
  transform: translateY(-50%);
  background: transparent;
  border: 0;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  color: #9aa3a0;
  cursor: pointer;
  font-size: 14px;
  display: none;
}
.qp-search-clear.is-visible { display: inline-flex; align-items: center; justify-content: center; }
.qp-search-clear:hover { background: #f3f5f7; color: #111; }

.qp-search-hint {
  text-align: center;
  font-size: 0.82rem;
  color: #6c7770;
  padding: 8px 0 4px;
  min-height: 24px;
}

.qp-search-results {
  margin-top: 0.5rem;
  overflow-y: auto;
  padding-right: 4px;
}
.qp-search-result {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px;
  border-radius: 10px;
  text-decoration: none;
  color: inherit;
  transition: background .15s ease;
}
.qp-search-result + .qp-search-result {
  margin-top: 4px;
}
.qp-search-result:hover,
.qp-search-result.is-active {
  background: #f5f7f9;
}
.qp-search-result-img {
  width: 56px;
  height: 56px;
  object-fit: cover;
  border-radius: 8px;
  background: #f0f3f5;
  flex-shrink: 0;
}
.qp-search-result-body { min-width: 0; }
.qp-search-result-name {
  font-weight: 600;
  color: #1f2a24;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.qp-search-result-meta {
  font-size: 0.82rem;
  color: #6c7770;
  margin-top: 2px;
}
.qp-search-result-arrow {
  margin-left: auto;
  color: #c5ccd1;
  font-size: 0.85rem;
}
.qp-search-result:hover .qp-search-result-arrow { color: #94c93d; }

.qp-search-empty {
  text-align: center;
  padding: 2rem 1rem;
  color: #6c7770;
}
.qp-search-empty i {
  font-size: 2.2rem;
  color: #d4dade;
  margin-bottom: 10px;
  display: block;
}

.qp-search-cta {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 10px;
  padding: 12px;
  background: #94c93d;
  color: #fff !important;
  border-radius: 10px;
  text-decoration: none;
  font-weight: 600;
  transition: background .15s ease;
}
.qp-search-cta:hover { background: #7eb030; }

.qp-search-popular {
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid #eef1f3;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}
.qp-search-popular-label {
  color: #6c7770;
  font-size: 0.85rem;
  margin-right: 4px;
}
.qp-search-popular a {
  padding: 5px 12px;
  border-radius: 50px;
  background: #f3f5f7;
  color: #4d5860;
  font-size: 0.85rem;
  text-decoration: none;
  transition: background .15s ease, color .15s ease;
}
.qp-search-popular a:hover {
  background: #94c93d;
  color: #fff;
}

@media (max-width: 768px) {
  .qp-search-panel {
    margin: 0;
    width: 100%;
    border-radius: 0;
    height: 100vh;
    max-height: 100vh;
    padding-top: 1.5rem;
  }
  .qp-search-input {
    font-size: 1rem;
    padding: 14px 50px 14px 48px;
  }
}

/* ---------- Standalone /cautare page ---------- */

.search-page-hero {
  background: linear-gradient(135deg, #f3f8ec 0%, #e9f5d8 100%);
  padding: 4rem 0 3rem;
  text-align: center;
  border-bottom: 1px solid #e6ece9;
}
.search-page-hero h1 {
  font-size: 2rem;
  font-weight: 700;
  color: #1f2a24;
  margin-bottom: 0.5rem;
}
.search-page-hero p {
  color: #6b7780;
  margin-bottom: 1.5rem;
}
.search-page-box {
  position: relative;
  max-width: 640px;
  margin: 0 auto;
}
.search-page-box .qp-icon {
  position: absolute;
  left: 22px;
  top: 50%;
  transform: translateY(-50%);
  color: #6c7770;
  font-size: 1.1rem;
}
.search-page-input {
  width: 100%;
  padding: 18px 24px 18px 56px;
  font-size: 1.1rem;
  border: 1px solid #d8e0e4;
  border-radius: 50px;
  background: #fff;
  outline: none;
  transition: border-color .2s ease, box-shadow .2s ease;
}
.search-page-input:focus {
  border-color: #94c93d;
  box-shadow: 0 0 0 4px rgba(148, 201, 61, 0.15);
}
.search-page-submit {
  position: absolute;
  right: 6px;
  top: 50%;
  transform: translateY(-50%);
  background: #94c93d;
  border: 0;
  color: #fff;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  cursor: pointer;
  transition: background .15s ease;
}
.search-page-submit:hover { background: #7eb030; }

.search-page-body {
  padding: 3rem 0;
}
.search-page-summary {
  color: #6b7780;
  margin-bottom: 1.5rem;
}
.search-page-summary strong { color: #1f2a24; }

.search-page-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 1.25rem;
}
.search-page-card {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px;
  background: #fff;
  border: 1px solid #eef1f3;
  border-radius: 12px;
  text-decoration: none;
  color: inherit;
  transition: transform .15s ease, box-shadow .15s ease, border-color .15s ease;
}
.search-page-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.06);
  border-color: #cfd6d0;
}
.search-page-card img {
  width: 64px;
  height: 64px;
  object-fit: cover;
  border-radius: 8px;
  background: #f3f5f7;
  flex-shrink: 0;
}
.search-page-card-name { font-weight: 600; color: #1f2a24; }
.search-page-card-meta { font-size: 0.82rem; color: #6c7770; margin-top: 2px; }

.search-page-empty {
  text-align: center;
  padding: 4rem 1rem;
  color: #6b7780;
}
.search-page-empty i {
  font-size: 3rem;
  color: #d4dade;
  margin-bottom: 1rem;
}
