/* ── Kategori sayfası section wrapper ── */
.pest-finder-section {
  margin-bottom: 2rem;
}

/* =============================================
   İlaç Bul Aracı (Pest Finder) — Stiller
   ============================================= */

/* ── Widget kapsayıcı ── */
.pf-widget {
  background: #fff;
  border: 2px solid #e2f0d8;
  border-radius: 16px;
  padding: 1.5rem;
  max-width: 860px;
  margin: 0 auto 2rem;
  font-family: inherit;
}

/* ── Başlık ── */
.pf-header { text-align: center; margin-bottom: 1.25rem; }
.pf-title  { font-size: 1.35rem; font-weight: 700; color: #2d6a4f; margin: 0 0 .35rem; }
.pf-subtitle { font-size: .9rem; color: #555; margin: 0; }

/* ── Adım göstergesi ── */
.pf-steps {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: .5rem;
  margin-bottom: 1.5rem;
  flex-wrap: wrap;
}
.pf-step {
  display: flex;
  align-items: center;
  gap: .4rem;
  font-size: .82rem;
  color: #aaa;
  font-weight: 500;
  padding: .3rem .7rem;
  border-radius: 20px;
  border: 1.5px solid #ddd;
  background: #f9f9f9;
  transition: all .2s;
}
.pf-step--active {
  color: #2d6a4f;
  border-color: #52b788;
  background: #f0fff5;
}
.pf-step--done {
  color: #52b788;
  border-color: #b7e4c7;
  background: #f0fff5;
}
.pf-step-num {
  width: 20px; height: 20px;
  border-radius: 50%;
  background: currentColor;
  color: #fff;
  font-size: .7rem;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.pf-step--active .pf-step-num { background: #2d6a4f; color: #fff; }
.pf-step--done  .pf-step-num  { background: #52b788; color: #fff; }
.pf-step-arrow  { color: #ccc; font-size: 1rem; line-height: 1; }

/* ── Bitki grid ── */
.pf-plant-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(110px, 1fr));
  gap: .75rem;
}
.pf-search-wrap {
  margin-bottom: .9rem;
}
.pf-search-row {
  display: flex;
  gap: .5rem;
}
.pf-search-input {
  flex: 1;
  min-width: 0;
  border: 2px solid #d6e9da;
  border-radius: 10px;
  padding: .62rem .78rem;
  font: inherit;
  font-size: .9rem;
  background: #fff;
}
.pf-search-input:focus {
  outline: none;
  border-color: #52b788;
  box-shadow: 0 0 0 2px rgba(82, 183, 136, .2);
}
.pf-search-btn {
  border: none;
  border-radius: 10px;
  background: #2d6a4f;
  color: #fff;
  font: inherit;
  font-weight: 700;
  padding: .6rem 1rem;
  cursor: pointer;
  transition: background .15s;
}
.pf-search-btn:hover {
  background: #1f5a42;
}
.pf-search-suggestions {
  margin-top: .45rem;
  border: 1.5px solid #deece2;
  border-radius: 10px;
  background: #fff;
  overflow: hidden;
}
.pf-suggestion-item {
  width: 100%;
  border: none;
  border-bottom: 1px solid #eef5ef;
  background: transparent;
  display: grid;
  grid-template-columns: 24px 1fr auto;
  gap: .55rem;
  align-items: center;
  text-align: left;
  padding: .52rem .7rem;
  cursor: pointer;
  font: inherit;
}
.pf-suggestion-item:last-child {
  border-bottom: none;
}
.pf-suggestion-item:hover {
  background: #f4fbf6;
}
.pf-suggestion-icon {
  font-size: 1rem;
}
.pf-suggestion-text {
  color: #1f3f31;
  font-size: .86rem;
  font-weight: 600;
}
.pf-suggestion-cat {
  color: #5f8f75;
  font-size: .72rem;
}
.pf-suggestion-empty {
  margin: 0;
  padding: .6rem .7rem;
  color: #7a8f7f;
  font-size: .82rem;
}
.pf-plant-group {
  border: 1.5px solid #e6efe8;
  border-radius: 12px;
  padding: .75rem;
  background: #fcfffd;
}
.pf-plant-group + .pf-plant-group {
  margin-top: .75rem;
}
.pf-plant-group-title {
  margin: 0 0 .65rem;
  font-size: .88rem;
  font-weight: 700;
  color: #2d6a4f;
}
.pf-plant-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: .4rem;
  padding: .85rem .5rem;
  border: 2px solid #e0ede0;
  border-radius: 12px;
  background: #f9fdf7;
  cursor: pointer;
  font-family: inherit;
  font-size: .82rem;
  color: #333;
  font-weight: 600;
  transition: border-color .15s, transform .12s, background .15s;
  line-height: 1.2;
  text-align: center;
}
.pf-plant-btn:hover, .pf-plant-btn:focus {
  border-color: #52b788;
  background: #edfaf2;
  transform: translateY(-2px);
  outline: none;
}
.pf-plant-icon { font-size: 1.8rem; line-height: 1; }

/* ── Sorun chip'leri ── */
.pf-selected-plant {
  font-size: .9rem;
  color: #444;
  margin: 0 0 .9rem;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: .4rem;
}
.pf-badge {
  display: inline-flex;
  align-items: center;
  gap: .25rem;
  background: #e9f7ef;
  color: #1b5e3b;
  border: 1.5px solid #a8d8bb;
  border-radius: 20px;
  padding: .2rem .65rem;
  font-size: .82rem;
  font-weight: 600;
}
.pf-badge--problem {
  background: #fff8e1;
  color: #7c4a00;
  border-color: #f0c060;
}

.pf-problem-chips {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: .55rem;
}
.pf-chip {
  display: grid;
  grid-template-columns: 24px 1fr auto;
  align-items: center;
  column-gap: .55rem;
  width: 100%;
  padding: .6rem .75rem;
  border: 1.5px solid #d0e8d8;
  border-radius: 12px;
  background: #f7fdf9;
  font-family: inherit;
  font-size: .84rem;
  font-weight: 600;
  color: #2d6a4f;
  cursor: pointer;
  text-align: left;
  transition: background .15s, border-color .15s, transform .12s, box-shadow .15s;
}
.pf-chip:hover, .pf-chip:focus {
  background: #ecf9f1;
  border-color: #52b788;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(37, 99, 72, .12);
  outline: none;
}
.pf-chip-icon {
  font-size: 1rem;
  line-height: 1;
}
.pf-chip-text {
  min-width: 0;
  line-height: 1.25;
}
.pf-chip-qualifier {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: .16rem .5rem;
  border-radius: 999px;
  font-size: .7rem;
  font-weight: 700;
  background: #e8f5e9;
  border: 1px solid #b8dfc6;
  color: #236b48;
  white-space: nowrap;
}
.pf-chip-qualifier--empty {
  visibility: hidden;
}

/* ── Sonuç ── */
.pf-result-subtitle {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: .4rem;
  font-size: .88rem;
  color: #555;
  margin: 0 0 1rem;
}
.pf-results-grid {
  display: flex;
  flex-direction: column;
  gap: .75rem;
  margin-bottom: 1rem;
}
.pf-result-card {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1rem;
  border: 1.5px solid #e0ede0;
  border-radius: 12px;
  background: #fafffe;
}
.pf-result-icon  { font-size: 2.2rem; flex-shrink: 0; }
.pf-result-info  { flex: 1; min-width: 0; }
.pf-result-name  { display: block; font-size: .95rem; color: #1a3c2a; margin: 0 0 .2rem; }
.pf-result-desc  { font-size: .8rem; color: #666; margin: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pf-result-actions { display: flex; gap: .5rem; flex-shrink: 0; flex-wrap: wrap; }

/* ── Butonlar ── */
.pf-btn {
  display: inline-block;
  padding: .45rem .9rem;
  border-radius: 8px;
  font-size: .8rem;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  border: none;
  transition: opacity .15s, transform .12s;
  white-space: nowrap;
}
.pf-btn:hover { opacity: .88; transform: translateY(-1px); }
.pf-btn--primary { background: #2d6a4f; color: #fff; }
.pf-btn--wa      { background: #25d366; color: #fff; }
.pf-btn--reset   {
  display: block;
  margin: .5rem auto 0;
  background: transparent;
  color: #2d6a4f;
  border: 2px solid #52b788;
  padding: .45rem 1.4rem;
  font-family: inherit;
}
.pf-back-btn {
  background: none;
  border: none;
  color: #52b788;
  font-size: .85rem;
  font-weight: 600;
  cursor: pointer;
  padding: 0;
  margin-bottom: .9rem;
  display: inline-block;
}
.pf-back-btn:hover { text-decoration: underline; }
.pf-empty { color: #888; font-size: .85rem; text-align: center; padding: 1rem; }

/* ── Header "İlaç Bul" butonu ── */
.pf-header-btn {
  display: inline-flex;
  align-items: center;
  gap: .35rem;
  padding: .42rem .9rem;
  background: #2d6a4f;
  color: #fff !important;
  border-radius: 8px;
  font-size: .82rem;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  border: none;
  font-family: inherit;
  transition: background .15s, transform .12s;
  white-space: nowrap;
}
.pf-header-btn:hover { background: #1b4332; transform: translateY(-1px); }

/* ── Modal ── */
#pf-modal {
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: rgba(0,0,0,.55);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  overflow-y: auto;
}
#pf-modal[hidden] { display: none !important; }
.pf-modal--open   { animation: pfFadeIn .18s ease; }
@keyframes pfFadeIn { from { opacity: 0 } to { opacity: 1 } }

.pf-modal-box {
  background: #fff;
  border-radius: 18px;
  width: 100%;
  max-width: 880px;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 20px 60px rgba(0,0,0,.25);
  position: relative;
}
.pf-modal-close-row {
  display: flex;
  justify-content: flex-end;
  padding: .75rem .75rem 0;
}
#pf-modal-close {
  background: none;
  border: none;
  font-size: 1.4rem;
  cursor: pointer;
  color: #888;
  line-height: 1;
  padding: .2rem .4rem;
  border-radius: 4px;
  transition: color .15s;
}
#pf-modal-close:hover { color: #333; }
.pf-modal-inner { padding: 0 1.25rem 1.5rem; }
.pf-modal-inner .pf-widget { border: none; padding: 0; }

/* Modal lock */
body.pf-modal-lock { overflow: hidden; }

/* ── Responsif ── */
@media (max-width: 600px) {
  .pf-search-row { flex-direction: column; }
  .pf-search-btn { width: 100%; }
  .pf-plant-grid { grid-template-columns: repeat(auto-fill, minmax(90px, 1fr)); }
  .pf-result-card { flex-direction: column; align-items: flex-start; }
  .pf-result-actions { width: 100%; justify-content: flex-start; }
  .pf-header-btn span.pf-hb-text { display: none; }
}
