{% extends "layout.html" %}

{% block content %}
{% if bulletin %}
<section class="section-2025">
  <div class="container-2025">
    <div class="card-2025 scroll-reveal" style="max-width: 800px; margin: 0 auto;">
      <h1 class="section-title">{{ bulletin.title }}</h1>
      <p style="color: var(--medium-gray); font-size: 1.1rem;">{{ bulletin.date }}</p>
      
      {% if bulletin.scripture_reading %}
        <div style="background: var(--soft-gray); padding: 2rem; border-radius: 16px; margin: 2rem 0; border-left: 4px solid var(--soft-gold);">
          <strong>Scripture Reading:</strong><br>
          {{ bulletin.scripture_reading }}
        </div>
      {% endif %}
      
      {% if bulletin.sabbath_school %}
        <div style="margin: 2rem 0;">
          <h3>Sabbath School</h3>
          {{ bulletin.sabbath_school }}
        </div>
      {% endif %}
      
      {% if bulletin.divine_worship %}
        <div style="margin: 2rem 0;">
          <h3>Divine Worship</h3>
          {{ bulletin.divine_worship }}
        </div>
      {% endif %}
      
      {% if bulletin.sunset %}
        <div style="margin: 2rem 0;">
          <h3>Sunset</h3>
          {{ bulletin.sunset }}
        </div>
      {% endif %}
      
      <div style="text-align: center; margin-top: 3rem;">
        {% if bulletin.pdf_path %}
          <a href="{{ bulletin.pdf_path }}" target="_blank" class="btn-2025 btn-primary">
            <i class="fas fa-download"></i>
            Download PDF
          </a>
        {% endif %}
        <a href="/bulletins" class="btn-2025 btn-outline">
          <i class="fas fa-arrow-left"></i>
          Back to Bulletins
        </a>
      </div>
    </div>
  </div>
</section>
{% else %}
<section class="section-2025">
  <div class="container-2025">
    <div class="card-2025 scroll-reveal" style="text-align: center;">
      <h1>Bulletin Not Found</h1>
      <p>The bulletin you're looking for doesn't exist.</p>
      <a href="/bulletins" class="btn-2025 btn-primary">View All Bulletins</a>
    </div>
  </div>
</section>
{% endif %}
{% endblock %}