/* State-only styles. The owning component keeps all geometry and final styling. */
:root {
  --avano-loading-surface: #e5e7eb;
}
html[data-theme='dark'] {
  --avano-loading-surface: #30343b;
}

html[data-avano-loading='enabled'] :is(
  [data-avano-cover], .first-slider-card, .new-novels-cover,
  .latest-updated-cover, .hero-cover, .categories-card-cover, .avano-novel-cover
):has(img:not([data-avano-image-state='ready'])) {
  background-color: var(--avano-loading-surface);
}
html[data-avano-loading='enabled'] :is(
  [data-avano-cover], .first-slider-card, .new-novels-cover,
  .latest-updated-cover, .hero-cover, .categories-card-cover, .avano-novel-cover
) img:not([data-avano-image-state='ready']) {
  opacity: 0 !important;
}

[data-avano-skeleton] {
  background-color: var(--avano-loading-surface);
}

/* Ready server text stays visible before carousel initialization. */
.first-slider-roman-info:not([data-avano-ready]) {
  opacity: 1;
  transform: translateY(0);
}

/* Match the existing search result row, without adding links or controls. */
.avano-search-results .avano-search-loading-row {
  display: flex;
  align-items: center;
  box-sizing: border-box;
  min-height: 32px;
  padding: 3px 10px;
}
.avano-search-loading-line {
  display: block;
  width: 65%;
  height: .65em;
  border-radius: 4px;
}
.avano-search-loading-row:nth-child(2) .avano-search-loading-line {
  width: 45%;
}

.accordion-list-container .skeleton-fake {
  opacity: 1;
  animation: none;
}
.accordion-list-container .loading-fasl {
  width: 65%;
  height: 10px;
  border: 0;
  border-radius: 4px;
  background: var(--avano-loading-surface);
  animation: none;
}
