/* ----------------------------------------------
🎯 1. Glavni stil iskalnika (oboje: novice + projekti)
---------------------------------------------- */
.news-filter-form,
.projekti-filter-form {
  background: #EFF7FF;
  padding: 10px 15px;
  border-radius: 8px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  width: 100%;
  max-width: 100%;
  margin: 0 auto;
  box-sizing: border-box;
}

.news-filter-form .wp-block-columns,
.projekti-filter-form .wp-block-columns {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  width: 100%;
}

.news-filter-form .wp-block-column,
.projekti-filter-form .wp-block-column {
  flex: 1 1 auto;
  min-width: 150px;
}

.news-filter-form input,
.news-filter-form select,
.news-filter-form button,
.projekti-filter-form input,
.projekti-filter-form select,
.projekti-filter-form button {
  padding: 0.5rem 1.5rem;
  font-size: 1rem;
  font-family: 'DM Sans', sans-serif;
  font-weight: 700;
  text-transform: uppercase;
  border: 2px solid #067FF7;
  border-radius: 1.25rem;
  height: 42px;
  box-sizing: border-box;
  transition: all 0.2s ease;
  width: 100%;
}

/* ----------------------------------------------
🎯 2. Stil datumskih polj in placeholderjev
---------------------------------------------- */
.news-filter-form input[type="date"],
.projekti-filter-form input[type="date"] {
  color: #888888;
  appearance: none;
}

.news-filter-form input[type="date"]::-webkit-datetime-edit,
.projekti-filter-form input[type="date"]::-webkit-datetime-edit {
  color: #888888;
}

@supports (-webkit-touch-callout: none) {
  .news-filter-form input[type="date"],
  .projekti-filter-form input[type="date"] {
    background: url('data:image/svg+xml;utf8,<svg fill="%23666" height="20" viewBox="0 0 24 24" width="20" xmlns="http://www.w3.org/2000/svg"><path d="M19 4h-1V2h-2v2H8V2H6v2H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm0 16H5V9h14v11zm0-13H5V6h14v1z"/></svg>') no-repeat right 1rem center;
    background-color: white;
    background-size: 1rem;
    padding-right: 2.5rem;
  }
}

/* ----------------------------------------------
🎯 3. Gumba "IŠČI" in "Počisti"
---------------------------------------------- */
.news-filter-form button[type="submit"],
.projekti-filter-form button[type="submit"] {
  background: #067FF7;
  color: #051923;
  border: 2px solid #067FF7;
}

.news-filter-form button[type="submit"]:hover,
.projekti-filter-form button[type="submit"]:hover {
  background-color: #ffffff;
  color: #067FF7;
  box-shadow: 0 0 0.5rem #067FF7;
}

.news-filter-form .filter-reset,
.projekti-filter-form .filter-reset {
  background: #ffffff;
  border: 2px solid #067FF7;
  color: #067FF7;
}

.news-filter-form .filter-reset:hover,
.projekti-filter-form .filter-reset:hover {
  background: #067FF7;
  color: #051923;
  box-shadow: 0 0 0.5rem #067FF7;
}

/* ----------------------------------------------
🎯 4. Dropdown stil (oznake)
---------------------------------------------- */
.dropdown-wrapper {
  position: relative;
  width: 100%;
  flex-grow: 1;
  margin: 0;
}

.dropdown-btn {
  width: 100% !important;
  height: 42px;
  line-height: 1.4;
  padding: 0.5rem 1.5rem;
  font-size: 1rem;
  font-family: 'DM Sans', sans-serif;
  font-weight: 700;
  text-transform: uppercase;
  border: 2px solid #067FF7;
  border-radius: 1.25rem;
  background: white;
  color: #666;
  cursor: pointer;
  text-align: left;
  background-image: url("data:image/svg+xml,%3Csvg fill='%23067FF7' height='20' viewBox='0 0 24 24' width='20' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M7 10l5 5 5-5z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 1rem center;
  background-size: 1rem;
}

.dropdown-btn.selected {
  background: #067FF7;
  color: white;
}

.dropdown-btn::after {
  content: "";
}

.checkbox-dropdown {
  display: none;
  position: absolute;
  top: 42px;
  left: 0;
  width: 300px;
  background: #ffffff;
  border: 1px solid #ddd;
  border-radius: 4px;
  padding: 10px;
  z-index: 100;
  box-shadow: 0 2px 6px rgba(0,0,0,0.2);
}

.checkbox-dropdown label {
  display: flex;
  align-items: center;
  gap: 4px;
  margin: 2px 0;
  font-size: 14px;
  line-height: 1.2;
  color: #051923;
  white-space: nowrap;
}

.checkbox-dropdown input[type="checkbox"] {
  transform: scale(0.9);
  margin: 0;
}

.dropdown-actions {
  margin-bottom: 10px;
}

.dropdown-actions button {
  padding: 0.5rem 1.5rem;
  margin-right: 5px;
  cursor: pointer;
  border: 2px solid #067FF7;
  background-color: #ffffff;
  color: #067FF7;
  border-radius: 1.25rem;
  font-family: 'DM Sans', sans-serif;
  font-weight: 700;
  text-transform: uppercase;
  transition: all 0.2s ease;
}

.dropdown-actions button:hover {
  background-color: #067FF7;
  color: #051923;
  box-shadow: 0 0 0.5rem #067FF7;
}

/* ----------------------------------------------
🎯 5. Mobilna prilagoditev
---------------------------------------------- */
@media (max-width: 1125px) {
  .news-filter-form,
  .projekti-filter-form {
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
  }

  .news-filter-form .wp-block-columns,
  .projekti-filter-form .wp-block-columns {
    flex-direction: column;
    gap: 8px;
  }

  .news-filter-form .wp-block-column,
  .projekti-filter-form .wp-block-column {
    width: 100%;
  }

  .news-filter-form input,
  .news-filter-form select,
  .projekti-filter-form input,
  .projekti-filter-form select,
  .dropdown-btn,
  .news-filter-form button,
  .projekti-filter-form button {
    max-width: 100% !important;
    width: 100% !important;
  }

  .checkbox-dropdown {
    width: 100%;
    left: 0;
    top: 45px;
  }

  .checkbox-dropdown label {
    display: grid !important;
    grid-template-columns: auto 1fr !important;
    align-items: center !important;
    gap: 8px !important;
    width: 100% !important;
    font-size: 14px !important;
    line-height: 1.4 !important;
    margin: 4px 0 !important;
    color: #051923 !important;
    white-space: normal !important;
    word-break: break-word !important;
    text-align: left !important;
  }

  .checkbox-dropdown input[type="checkbox"] {
    width: 32px !important;
    height: 32px !important;
    transform: none !important;
    margin: 0 !important;
    cursor: pointer;
  }

  .search-button .button-wrap {
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
  }

  .search-button .button-wrap button {
    width: 100% !important;
    margin-left: 0 !important;
    text-align: center;
  }
}

/* ----------------------------------------------
🎯 6. Dodatki & popravki
---------------------------------------------- */
.search-button .button-wrap {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.wp-block-post-template {
  list-style: none;
  padding-left: 0;
}

/* 🧼 Odstranimo fiksne max-width za iskalnik */
.projekti-filter-form.hide-reset input#projekti-search-keyword[type="text"] {
  max-width: 100% !important;
  width: 100% !important;
  flex: 1 1 auto !important;
}


/* 🧼 Popolna odstranitev črne obrobe (tudi na :focus-visible) */
.filter-form-wrapper button:focus,
.filter-form-wrapper button:focus-visible {
  outline: none !important;
  box-shadow: none !important;
}

/* ✨ Hover efekt */
.filter-form-wrapper button:hover {
  transform: scale(1.03);
  background-color: #2f80ed;
  color: white;
}

/* 👇 Klik efekt (indentacija) */
.filter-form-wrapper button:active {
  transform: scale(0.97);
}

/* 🎯 Vzdrževanje gladkega prehoda */
.filter-form-wrapper button {
  transition: all 0.15s ease-in-out;
}
