{% macro program_card(program, has_access) %}
<div class="col-sm-4 mb-4 text-left">
	<a href="/lms/program?program={{ program.name }}" class="no-decoration no-underline">
	<div class="card h-100">
		{% if program.hero_image %}
		<div class="card-hero-img" style="background-image: url('{{ program.hero_image }}')"></div>
		{% else %}
		<div class="card-image-wrapper text-center">
			<div class="image-body"><i class="fa fa-picture-o" aria-hidden="true"></i></div>
		</div>
		{% endif %}
		<div class='card-body'>
			<h5 class='card-title'>{{ program.program_name }}</h5>
			<div class="text-muted">{{ program.description[:110] + '...' if program.description else '' }}</div>
		</div>
		{% if has_access or program.intro_video%}
		<div class='card-footer'>
			{% if has_access %} <span class="indicator green">{{_('Enrolled')}}</span>
			{% elif program.intro_video %} <span><a href="{{ program.intro_video }}" target="blank">{{_('Watch Intro')}}</a></span>
			{% endif %}
		</div>
		{% endif %}
	</div>
	</a>
</div>
{% endmacro %}


{% macro null_card() %}
<div class="col-sm-4 mb-4 text-left">
	<div class="h-100 d-none d-sm-block" style="border: 1px solid rgba(209,216,221,0.5);border-radius: 0.25rem;background-color: rgb(250, 251, 252);">
	</div>
</div>
{% endmacro %}