{{!-- Roll Result Chat Card --}}
<div class="ua2e-roll-card {{result.degree}}">
  <div class="roll-header">
    <span class="roll-label">{{label}}</span>
    <span class="check-type-badge">{{localize (concat "UA2E.Roll." (capitalize checkType))}}</span>
  </div>

  <div class="roll-body">
    <div class="roll-numbers">
      <span class="roll-total">{{rolledDisplay}}</span>
      <span class="roll-vs">{{localize "UA2E.Roll.Vs"}}</span>
      {{#if skill}}
        <span class="roll-target">{{skill}}% <span class="target-type">{{localize "UA2E.Roll.TargetSkill"}}</span></span>
      {{else}}
        <span class="roll-target">{{stat}}% <span class="target-type">{{#if (eq checkType "simple")}}{{localize "UA2E.Roll.TargetStat"}}{{else}}{{localize "UA2E.Roll.TargetStatUnskilled"}}{{/if}}</span></span>
      {{/if}}
      {{#if shift}}
        <span class="roll-shift">[{{localize "UA2E.Roll.ShiftInline" shift=shift}}]</span>
      {{/if}}
    </div>

    {{!-- Special indicators --}}
    <div class="roll-indicators">
      {{#if result.isCrit}}
        <span class="indicator crit">★ {{localize "UA2E.Roll.IndicatorCrit"}}</span>
      {{/if}}
      {{#if result.isFumble}}
        <span class="indicator fumble">✗ {{localize "UA2E.Roll.IndicatorFumble"}}</span>
      {{/if}}
      {{#if result.isMatch}}
        <span class="indicator match">◆ {{localize "UA2E.Roll.IndicatorMatch"}}</span>
      {{/if}}
    </div>

    {{!-- Outcome --}}
    <div class="roll-outcome outcome-{{result.degree}}">
      {{#if (eq result.degree "crit")}}     {{localize "UA2E.Roll.Outcome.Crit"}}{{/if}}
      {{#if (eq result.degree "fumble")}}   {{localize "UA2E.Roll.Outcome.Fumble"}}{{/if}}
      {{#if (eq result.degree "strong")}}   {{localize "UA2E.Roll.Outcome.Strong"}}{{/if}}
      {{#if (eq result.degree "success")}}  {{localize "UA2E.Roll.Outcome.Success"}}{{/if}}
      {{#if (eq result.degree "weak")}}     {{localize "UA2E.Roll.Outcome.Weak"}}{{/if}}
      {{#if (eq result.degree "hailmary")}} {{localize "UA2E.Roll.Outcome.HailMary"}}{{/if}}
      {{#if (eq result.degree "fail")}}     {{localize "UA2E.Roll.Outcome.Fail"}}{{/if}}
    </div>

    {{!-- Minimum roll warning --}}
    {{#if minRoll}}
      {{#unless meetsMinimum}}
        <div class="roll-warning">⚠ {{localize "UA2E.Roll.MinimumFail" minRoll=minRoll}}</div>
      {{/unless}}
    {{/if}}

    {{!-- Flip-flop option --}}
    {{#if result.flipOption}}
      <div class="flip-option">
        <span class="flip-label">★ {{localize "UA2E.Roll.FlipOptionAvailable"}}</span>
        <span class="flip-total">{{result.flipOption.rolled}}</span>
        →
        <span class="flip-outcome outcome-{{result.flipOption.degree}}">
          {{#if (eq result.flipOption.degree "crit")}}     {{localize "UA2E.Roll.Outcome.Crit"}}{{/if}}
          {{#if (eq result.flipOption.degree "fumble")}}   {{localize "UA2E.Roll.Outcome.Fumble"}}{{/if}}
          {{#if (eq result.flipOption.degree "strong")}}   {{localize "UA2E.Roll.Outcome.Strong"}}{{/if}}
          {{#if (eq result.flipOption.degree "success")}}  {{localize "UA2E.Roll.Outcome.Success"}}{{/if}}
          {{#if (eq result.flipOption.degree "weak")}}     {{localize "UA2E.Roll.Outcome.Weak"}}{{/if}}
          {{#if (eq result.flipOption.degree "hailmary")}} {{localize "UA2E.Roll.Outcome.HailMary"}}{{/if}}
          {{#if (eq result.flipOption.degree "fail")}}     {{localize "UA2E.Roll.Outcome.Fail"}}{{/if}}
          {{#if result.flipOption.isMatch}} ◆ {{localize "UA2E.Roll.IndicatorMatch"}}{{/if}}
        </span>
      </div>
    {{/if}}
  </div>
</div>
