/* The lesson's "Документы и ресурсы" block — a panel that gives the reading
   list weight, paralleling the "Проверь себя" card. */
.resource-block {
  background: var(--color-subtle-light);
  border: 1px solid var(--color-subtle);
  border-radius: 0.75rem;
  padding: 1.25rem 1.5rem;
}

.resource-block__head {
  align-items: center;
  display: flex;
  gap: 0.6rem;
  margin-block-end: 1.25rem;
}

.resource-block__icon {
  color: var(--color-subtle-dark);
  line-height: 0;
}

.resource-block__icon .icon {
  height: 1.4rem;
  width: 1.4rem;
}

.resource-block__title {
  font-size: 1.2rem;
  margin: 0;
}

/* Editor-only "edit links" button sits at the far end of the head row. */
.resource-block__edit {
  margin-inline-start: auto;
}

/* The shared grid for both "Обязательные"/"Рекомендуемые" groups — see
   lesson.css .lesson-resources for why this lives one level up. row-gap
   handles resource-to-resource spacing; .resource-block__group's own
   margin is calc-adjusted so the group-to-group gap still nets out to the
   original 1.25rem/0.5rem despite that row-gap also landing on its rows. */
.resource-block__list {
  align-items: start;
  column-gap: 0.6rem;
  display: grid;
  grid-template-columns: auto auto 1fr;
  row-gap: 0.6rem;
}

/* Quiet group caption — whisper, not shout: small, muted, normal case, no icon.
   The meaning stays explicit without the visual noise of stars + ALL CAPS. */
.resource-block__group {
  color: var(--color-subtle-dark);
  font-size: 0.8rem;
  font-weight: 500;
  grid-column: 1 / -1;
  margin-block: calc(1.25rem - 0.6rem) calc(var(--block-space-half) - 0.6rem);
}

.resource-block__group:first-of-type {
  margin-block-start: 0;
}

/* Shown when a lesson has no sources yet — the block becomes an invitation. */
.resource-block__empty {
  color: var(--color-subtle-dark);
  font-size: 0.9rem;
  margin-block: 0 0.9rem;
}

/* The "propose a source" invitation — minimal by design: one short muted line
   with a small accent "+" as the intuitive add cue. Never competes with the
   sources above; the whole thing tints on hover to read as an action. */
.resource-block__suggest {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  margin-block-start: 1.25rem;
  color: var(--color-subtle-dark);
  font-size: 0.85rem;
  text-decoration: none;
  transition: color 120ms ease-out;
}

.resource-block__suggest .icon {
  inline-size: 1.15rem;
  block-size: 1.15rem;
  flex-shrink: 0;
  color: var(--color-link); /* the one accent — the intuitive "add" cue */
}

@media (any-hover: hover) {
  .resource-block__suggest:hover {
    color: var(--color-link);
  }
}
