/* Resources Block Styles */

[data-name='acf_resources'] .resources-item {
  transition: all 0.3s ease;
}

[data-name='acf_resources'] .resources-item:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(29, 61, 59, 0.1);
}

[data-name='acf_resources'] .resources-category-link {
  transition: all 0.3s ease;
}

[data-name='acf_resources'] .resources-category-link:hover {
  transform: translateY(-2px);
}

[data-name='acf_resources'] .resources-doc-type-checkbox {
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  cursor: pointer;
  border: 1px solid white;
  background-color: transparent;
  width: 20px;
  height: 20px;
  min-width: 20px;
  min-height: 20px;
  flex-shrink: 0;
  border-radius: 4px;
  position: relative;
}

[data-name='acf_resources'] .resources-doc-type-checkbox:checked {
  background-color: var(--coloryellow);
  border-color: var(--coloryellow);
}

[data-name='acf_resources'] .resources-doc-type-checkbox:checked::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 10px;
  height: 7px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='7' viewBox='0 0 10 7' fill='none'%3E%3Cpath d='M1 3.48062L3.68041 6L9 1' stroke='%23BF5828' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
}

[data-name='acf_resources'] .resources-doc-type-filter label {
  transition: opacity 0.2s ease;
}

[data-name='acf_resources'] .resources-doc-type-filter label:hover {
  opacity: 0.8;
}

[data-name='acf_resources'] .resources-item svg path {
  transition: fill 0.3s ease;
}

[data-name='acf_resources'] #resources-content-wrapper {
  position: relative;
}

[data-name='acf_resources'] .resources-loading {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.7);
  z-index: 2;
}

[data-name='acf_resources'] .resources-loading.hidden {
  display: none;
}

[data-name='acf_resources'] .resources-loading__spinner {
  width: 40px;
  height: 40px;
  border: 4px solid rgba(29, 61, 59, 0.2);
  border-top-color: var(--colororange);
  border-radius: 50%;
  animation: resources-spin 0.8s linear infinite;
}

@keyframes resources-spin {
  to {
    transform: rotate(360deg);
  }
}

[data-name='acf_resources'] .resources-category-link svg {
  display: block;
  width: 100%;
  height: 100%;
}

[data-name='acf_resources'] .resources-category-link span:first-child {
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Category icon and text colors - default green for all category links */
[data-name='acf_resources'] .resources-category-link {
  color: var(--colorgreen) !important;
  transition: color 0.3s ease;
}

[data-name='acf_resources'] .resources-category-link span,
[data-name='acf_resources'] .resources-category-link svg,
[data-name='acf_resources'] .resources-category-link svg path {
  color: var(--colorgreen) !important;
  fill: var(--colorgreen) !important;
  transition: color 0.3s ease, fill 0.3s ease;
}

/* Category icon and text colors - active state (yellow when button is active) */
[data-name='acf_resources'] .resources-category-link[data-active='true'] {
  color: var(--coloryellow) !important;
}

[data-name='acf_resources'] .resources-category-link[data-active='true'] span,
[data-name='acf_resources'] .resources-category-link[data-active='true'] svg,
[data-name='acf_resources']
  .resources-category-link[data-active='true']
  svg
  path {
  color: var(--coloryellow) !important;
  fill: var(--coloryellow) !important;
}

/* Category icon and text colors - hover state (white when hovering) */
[data-name='acf_resources'] .resources-category-link:hover {
  color: white !important;
}

[data-name='acf_resources'] .resources-category-link:hover span,
[data-name='acf_resources'] .resources-category-link:hover svg path {
  color: white !important;
  fill: white !important;
}

/* Keep yellow on active even when hovering (must come after hover rule) */
[data-name='acf_resources'] .resources-category-link[data-active='true']:hover {
  color: var(--coloryellow) !important;
}

[data-name='acf_resources']
  .resources-category-link[data-active='true']:hover
  span,
[data-name='acf_resources']
  .resources-category-link[data-active='true']:hover
  svg
  path {
  color: var(--coloryellow) !important;
  fill: var(--coloryellow) !important;
}
