@layer components {
  /* ─── Doladiť účet ──────────────────────── */

  .checklist__head {
    align-items: flex-start;
    display: flex;
    gap: 1rem;
    justify-content: space-between;
  }

  .checklist__count {
    display: flex;
    flex-direction: column;
    flex-shrink: 0;
    margin: 0;
    text-align: end;
  }

  .checklist__number {
    color: var(--color-brand);
    font-family: var(--font-mono);
    font-size: 2rem;
    font-weight: 700;
  }

  /* The progress as a bar of the brand over the surface's tint. */
  .checklist__bar {
    -webkit-appearance: none;
    appearance: none;
    background: var(--color-surface-tint);
    block-size: 0.375rem;
    border: none;
    border-radius: var(--radius-pill);
    inline-size: 100%;
    margin-block: 1.5rem;
    overflow: hidden;

    &::-webkit-progress-bar {
      background: var(--color-surface-tint);
    }

    &::-webkit-progress-value {
      background: var(--color-brand-fill);
    }

    &::-moz-progress-bar {
      background: var(--color-brand-fill);
    }
  }

  .checklist__items {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    list-style: none;
    margin: 0;
    padding: 0;
  }

  /* The whole row is the link; hovering it tints it and shows where it
     leads. */
  .checklist__link {
    align-items: center;
    border-radius: var(--radius-md);
    color: inherit;
    display: flex;
    gap: 1rem;
    padding: 0.625rem 0.75rem;
    text-decoration: none;
    transition: background 0.15s;

    &:hover {
      background: var(--color-surface-tint);
    }
  }

  .checklist__mark {
    align-items: center;
    block-size: 1.75rem;
    border: 1.5px solid var(--color-border-strong);
    border-radius: 50%;
    color: var(--color-ink-inverted);
    display: flex;
    flex-shrink: 0;
    inline-size: 1.75rem;
    justify-content: center;
  }

  .checklist__item--done .checklist__mark {
    background: var(--color-positive);
    border-color: var(--color-positive);
  }

  .checklist__text {
    color: var(--color-ink-muted);
    display: flex;
    flex: 1;
    flex-direction: column;
    font-size: 0.875rem;
    gap: 0.125rem;
    min-inline-size: 0;

    strong {
      color: var(--color-ink);
      font-size: 1rem;
      font-weight: 600;
    }
  }

  .checklist__chevron {
    color: var(--color-brand);
    flex-shrink: 0;
    opacity: 0;
    transition: opacity 0.15s;
  }

  .checklist__link:hover .checklist__chevron,
  .checklist__link:focus-visible .checklist__chevron {
    opacity: 1;
  }
}
