.resources-hero {
  background: linear-gradient(180deg, #fff, #f7fbff);
  border-bottom: 1px solid var(--border);
  padding: 24px 0 16px;
}

.resources-hero h1 {
  margin-bottom: 6px;
}

/* Filters */
.resources-hero .filters {
  margin-top: 14px;
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}

.resources-hero .filters>* {
  max-width: 860px;
  width: 100%;
  margin-inline: auto;
}

/* Search */
.search {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 12px;
  position: relative;
}

.search-ic {
  position: absolute;
  left: 16px;
  top: 50%;
  transform: translateY(-50%);
  pointer-events: none;
}

.search .input {
  width: 100%;
  padding: 16px 56px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: #fff;
  box-shadow: 0 10px 26px rgba(16, 24, 40, .08);
  font-size: 1.05rem;
}

.search .input:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 4px rgba(37, 99, 235, .1);
}

.clear-btn {
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  border: 1px solid var(--border);
  background: #fff;
  border-radius: 50%;
  width: 36px;
  height: 36px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.kbd {
  display: inline-grid;
  place-items: center;
  padding: 0 10px;
  height: 44px;
  border: 1px solid var(--border);
  background: #fff;
  border-radius: 10px;
  font-size: .95rem;
  color: var(--muted);
}

@media (max-width: 560px) {
  .kbd {
    display: none;
  }
}

/* Tags */
.tags {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: center;
}

.tag {
  border: 1px solid var(--border);
  background: #fff;
  border-radius: 999px;
  padding: 8px 12px;
  font-weight: 600;
  cursor: pointer;
  transition: all .2s ease;
}

.tag:hover {
  background: #f8fbff;
  border-color: #cfe0ff;
  transform: translateY(-1px);
}

.tag.active {
  background: var(--accent);
  color: #fff;
  border-color: transparent;
}

/* Cards */
#resourcesGrid {
  display: grid;
  gap: 20px;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
}

.card {
  display: block;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: #fff;
  overflow: hidden;
  transition: transform .2s ease, box-shadow .2s ease;
  text-decoration: none;
  color: inherit;
}

.card:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, .08);
}

.resource-cover {
  width: 100%;
  height: 180px;
  object-fit: cover;
  display: block;
}

.card h3 {
  margin: 12px 16px 6px;
  font-size: 1.1rem;
}

.card p {
  margin: 0 16px 10px;
  color: var(--muted);
}

.resource-meta {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  margin: 0 16px 16px;
}

.pill {
  padding: 4px 8px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: #f9fafb;
  font-size: .85rem;
}
