:root {
  --bg-start: #74EBD5;
  --bg-end: #9FACE6;
  --text-primary: #004B62;
  --text-muted: #333333;
  --input-bg: rgba(255, 255, 255, 0.95);
  --radius: 4px;
}

[hidden] {
  display: none !important;
}

.easy-search {
  background: linear-gradient(90deg, var(--bg-start) 20%, var(--bg-end) 100%);
  min-height: 10vh;
  display: grid;
  place-items: center;
  padding: 36px;
  border-radius: 30px;
}

.easy-search-container {
  width: 100%;
  text-align: center;
  z-index: 5;
}

/* Label and description */
.easy-search-label {
  font-weight: 700;
  font-size: 1.8rem;
  margin: 1rem 0 1rem 0;
  color: var(--text-primary);
}

.easy-search-text {
  color: var(--text-muted);
  margin: 8px 0 28px 0;
  text-align: center;
}

/* Search box row */
.easy-search-box {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 12px;
  align-items: center;
}

/* Input styles */
.easy-search-input-wrapper {
  display: flex;
  align-items: center;
  padding: 2px;
  background: var(--input-bg);
  border-radius: var(--radius);
}

.easy-search-icon {
  font-size: 1.125rem;
  margin-right: 8px;
  max-width: 45px;
}

.easy-search-input-wrapper .easy-search-input {
  flex: 1;
  border: none;
  min-height: auto;
}

.easy-search-separator {
  width: 1px;
  height: 20px;
  background-color: #ccc;
  margin: 0 0 0 8px;
}

.easy-search-filters-wrapper {
  position: relative;
  padding: 6px 2px;
  background: var(--input-bg);
  border-radius: var(--radius);
}

/* Buttons */
.easy-search-icon-btn {
  display: flex;
  align-items: center;
  border: none;
  color: var(--text-primary);
  border-radius: var(--radius);
  background: var(--input-bg);
}

.easy-search-filter-btn {
  display: flex;
  align-items: center;
  border: none;
  color: var(--text-primary);
  background: var(--input-bg);
  padding: 0 0 0 8px;
  width: 100%;
}

.filters-btn {
  flex: 1;
  display: flex;
  text-align: start;
  align-items: center;
}

.icon.material-icons-round {
  padding: 0 2px 0 6px;
}

.easy-search-filter-btn .icon {
  padding: 0 12px;
}

.material-icons-round.close {
  position: relative;
  left: calc(100% - 16px);
}

.clear-search {
  cursor: pointer;
  display: none;
}

.filter-chip .material-icons-round.close {
  left: calc(100% - 12px);
}

.buttons-container {
  padding-top: 24px;
  display: flex;
  align-items: center;
}

button {
  font-family: inherit;
  font-size: inherit;
  padding: 0.375rem 0.75rem;
  border: 1px solid transparent;
  border-radius: 0.25rem;
}

.btn {
  font-size: 16px;
  font-weight: normal;
  margin: 8px;
}

.btn-cmpa {
  color: #ffffff;
  background-color: #004B62;
  border-color: #004B62;
}

.btn-cmpa-alt {
  color: #000000;
  background-color: #EBECEA;
  border-color: #BEC5BC;
}

.btn-cmpa-alt:hover {
  background-color: #f8f6f5;
}

.btn-cmpa:hover, .btn-cmpa:focus, .btn-cmpa:active, .btn-cmpa.active, .open .dropdown-toggle.btn-cmpa {
  color: #ffffff;
  background-color: #2d6a7d;
  border-color: #2d6a7d;
}

.clickable {
  cursor: pointer;
}

.clickable:hover {
  cursor: pointer;
}

.filters-section {
  position: relative;
  top: -30px;
  padding: 36px;
  border-radius: 0 0 30px 30px;
  background: linear-gradient(90deg, rgba(116, 235, 213, 0.1) 0%, rgba(159, 172, 230, 0.1) 100%);
}

.filters-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 30px 24px;
}

.filter-field label {
  display: block;
  margin-bottom: 4px;
}

.easy-filter-wrapper {
  position: relative;
  width: 100%;
}

.easy-filter {
  border-radius: var(--radius);
  width: 100%;
  color: #8E8E8E;
}

.easy-filter:focus {
  color: #000000;
}

.easy-filter-clear {
  top: 50%;
  background: transparent;
  position: absolute;
  right: 20px;
  transform: translateY(-50%);
  border: none;
  cursor: pointer;
}

.active-filters {
  margin-bottom: 20px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.filter-chip {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  background: #f7f8f7;
  padding: 6px 12px;
  border-radius: 36px;
  font-size: 14px;
  color: #333;
}

.filter-chip button {
  border: none;
  background: transparent;
  cursor: pointer;
  display: inline-flex;
  padding: 0;
}

.clear-all-filters {
  padding: 6px;
  font-size: 14px;
}

#search-results {
  display: grid;
  width: 100%;
  gap: 20px;
  grid-template-columns: repeat(3, 1fr);
}

.results-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

select#sort-select {
  border-radius: var(--radius);
}

.search-card {
  display: flex;
  flex-direction: column;
  padding: 15px;
  border-radius: 15px;
  background-color: #fff;
  box-shadow: 0 0 5px #CCCCCC;
  min-height: 280px;
}

.card-img {
  max-width: 100%;
  border-radius: 15px;
}

.asset-type {
  margin-top: auto;
}

.date, .asset-type, .reading-time {
  font-size:14px;
}

.meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 0 15px 0;
}

.search-card:hover {
  box-shadow: 0 0 5px #8E8E8E;
}

@media (max-width: 960px) {
  .grid-100 {
    padding: 0 10px;
  }

  .easy-search {
    padding: 20px;
  }

  .easy-search-box {
    grid-template-columns: 1fr;
  }

  .easy-search-filters {
    justify-self: center;
  }

  .filters-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .filters-section {
    padding: 36px 20px;
  }

  .buttons-container {
    justify-content: center;
  }
}

@media (max-width: 520px) {
  .filters-grid {
    grid-template-columns: 1fr;
  }

  #search-results-wrapper {
    padding-bottom: 10px;
  }

  #search-results {
    grid-template-columns: repeat(1, 1fr);
  }

  .results-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .search-card {
    padding: 10px;
  }
}