{# レイアウトテンプレート名は文字列として渡される #}{% extends layout_template|default('default_frame.twig') %}{% block stylesheet %}<style>.message-container { max-width: 600px; margin: 80px auto; padding: 20px;}.message-card { background: white; border-radius: 8px; box-shadow: 0 2px 8px rgba(0,0,0,0.1); padding: 40px; text-align: center;}.message-icon { font-size: 60px; margin-bottom: 20px;}.message-icon.before { color: #ffc107;}.message-icon.after { color: #6c757d;}.message-icon.inactive { color: #dc3545;}.message-title { font-size: 24px; font-weight: bold; margin-bottom: 15px; color: #333;}.message-text { font-size: 16px; color: #666; line-height: 1.6; margin-bottom: 10px;}.date-info { font-size: 18px; color: #007bff; margin-top: 20px; font-weight: 600;}.btn-back { display: inline-block; margin-top: 30px; padding: 12px 30px; background: #6c757d; color: white; text-decoration: none; border-radius: 4px; transition: background 0.3s;}.btn-back:hover { background: #5a6268; color: white; text-decoration: none;}</style>{% endblock %}{% block main %}<div class="message-container"> <div class="message-card"> <div class="message-icon {{ type }}"> {% if type == 'before' %} <i class="fa fa-clock"></i> {% elseif type == 'after' %} <i class="fa fa-calendar-times"></i> {% else %} <i class="fa fa-ban"></i> {% endif %} </div> <h1 class="message-title">{{ message }}</h1> {% if type == 'before' and publish_start_date %} <p class="message-text">公開開始までお待ちください。</p> <div class="date-info"> 公開開始日時: {{ publish_start_date|date('Y年m月d日 H:i') }} </div> {% elseif type == 'after' and publish_end_date %} <p class="message-text">フォームの受付は終了しました。</p> <div class="date-info"> 公開終了日時: {{ publish_end_date|date('Y年m月d日 H:i') }} </div> {% else %} <p class="message-text">お探しのフォームは現在ご利用いただけません。</p> {% endif %} <a href="{{ url('homepage') }}" class="btn-back"> トップページへ戻る </a> </div></div>{% endblock %}