{% extends "base.html" %}

{% block title %}Home - ScanLook{% endblock %}

{% block content %}
<div class="dashboard-container">
    


    <div class="dashboard-header">
        <h1 class="page-title">Welcome, {{ session.full_name }}</h1>
    </div>
    <div><p class="page-subtitle">Select a module to get started</p></div>

    {% if modules %}
        <div class="module-grid">
            {% for m in modules %}
            <a href="/{{ m.module_key }}" class="module-card">
                <div class="module-icon">
                    <i class="fa-solid {{ m.icon }}"></i>
                </div>
                <h3 class="module-name">{{ m.module_name }}</h3>
                <p class="module-desc">{{ m.description }}</p>
            </a>
            {% endfor %}
        </div>
    {% else %}
        <div class="empty-state">
            <div class="empty-icon">🔒</div>
            <h2 class="empty-title">No Modules Available</h2>
            <p class="empty-text">You don't have access to any modules. Please contact your administrator.</p>
        </div>
    {% endif %}
</div>
{% endblock %}