@extends('site.layouts.site-layout')
@section('title', $announcement->title)

@section('content')

<div class="bread-crumb pt-3">
    <div class="container-fluid">
        <div class="content-box">
            <div class="container-fluid">
                <nav aria-label="breadcrumb">
                    <ol class="breadcrumb mb-0">
                        <li class="breadcrumb-item"><a href="{{ route('home') }}" class="font-14 text-muted">خانه</a></li>
                        <li class="breadcrumb-item"><a href="{{ route('panel.index') }}" class="font-14 text-muted">پنل کاربری</a></li>
                        <li class="breadcrumb-item"><a href="{{ route('panel.announcements.index') }}" class="font-14 text-muted">اطلاعیه ها</a></li>
                        <li class="breadcrumb-item active main-color-one-color font-14" aria-current="page">{{ $announcement->title }}</li>
                    </ol>
                </nav>
            </div>
        </div>
    </div>
</div>

<div class="content">
    <div class="container-fluid">

        <div class="custom-filter d-lg-none d-block">
            <button class="btn btn-filter-float border-0 main-color-two-bg shadow-box px-4 rounded-3 position-fixed"
                style="z-index:999;bottom:80px;" type="button"
                data-bs-toggle="offcanvas" data-bs-target="#panelSideCanvas" aria-controls="panelSideCanvas">
                <i class="bi bi-list font-20 fw-bold text-white"></i>
                <span class="d-block font-14 text-white">منو</span>
            </button>
            <div class="offcanvas offcanvas-start" tabindex="-1" id="panelSideCanvas">
                <div class="offcanvas-header">
                    <h5 class="offcanvas-title">منو پنل</h5>
                    <button type="button" class="btn-close" data-bs-dismiss="offcanvas" aria-label="Close"></button>
                </div>
                <div class="offcanvas-body">
                    <div class="panel-side">
                        <div class="content-box pb-0">
                            <div class="container-fluid">
                                @include('panel._sidebar')
                            </div>
                        </div>
                    </div>
                </div>
            </div>
        </div>

        <div class="dashboard-panel">
            <div class="row gy-3">

                <div class="col-lg-3 d-lg-block d-none">
                    <div class="panel-side">
                        <div class="content-box pb-0">
                            <div class="container-fluid">
                                @include('panel._sidebar')
                            </div>
                        </div>
                    </div>
                </div>

                <div class="col-lg-9">
                    <div class="content-box">
                        <div class="container-fluid">
                            <div class="title-panel mb-3 d-flex align-items-center justify-content-between flex-wrap gap-2">
                                <h5 class="font-18 mb-0">{{ $announcement->title }}</h5>
                                <span class="text-muted font-12"><i class="bi bi-clock me-1"></i>{{ $announcement->shamsiDate() }}</span>
                            </div>

                            <div class="announcement-content font-14" style="line-height:2">
                                {!! $announcement->content !!}
                            </div>

                            <div class="mt-4">
                                <a href="{{ route('panel.announcements.index') }}" class="btn btn-sm btn-outline-secondary rounded-3">
                                    <i class="bi bi-arrow-right me-1"></i>بازگشت به اطلاعیه ها
                                </a>
                            </div>
                        </div>
                    </div>
                </div>

            </div>
        </div>

    </div>
</div>

@endsection
