{{!
    This file is part of Moodle - http://moodle.org/

    Moodle is free software: you can redistribute it and/or modify
    it under the terms of the GNU General Public License as published by
    the Free Software Foundation, either version 3 of the License, or
    (at your option) any later version.

    Moodle is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    GNU General Public License for more details.

    You should have received a copy of the GNU General Public License
    along with Moodle.  If not, see <http://www.gnu.org/licenses/>.

    @template block_mwa_dashboard/chat_messages
    @copyright 2026 Bruno Porto
    @license   http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
}}
{{#messages}}
  <div style="display:flex;gap:.5rem;align-items:flex-start;align-self:{{align}};max-width:88%;{{direction}}">
    <div style="width:26px;height:26px;border-radius:50%;background:{{avatarbg}};display:flex;align-items:center;justify-content:center;font-size:.72rem;font-weight:700;color:var(--blue);flex-shrink:0;">{{avatarlabel}}</div>
    <div class="chat-md" style="{{bubblestyle}}padding:.6rem .85rem;font-size:.8rem;line-height:1.65;">
      {{{contenthtml}}}
    </div>
  </div>
{{/messages}}
