

@extends('web.home.layout.master')

@section('content')

<section class="event-detail-section py-5">
    <div class="container-fluid">
        <div class="row justify-content-center">
            <div class="col-lg-8">
                <!-- News Header -->
                <div class="event-header mb-5">
                    <div class="d-flex align-items-center mb-3">
                        <span class="badge bg-primary me-3">News</span>
                    </div>
                    <h1 class="display-5 fw-bold mb-4">{{ $data->news_title }}</h1>
                    <div class="d-flex align-items-center">
                        <div class="avatar-sm me-3">
                            <span class="avatar-title bg-light text-dark rounded-circle">
                                <i class="fas fa-newspaper"></i>
                            </span>
                        </div>
                        <div>
                            <p class="mb-0 fw-medium">Posted by American Plastics</p>
                            <p class="mb-0 text-muted small">{{ $data->created_at->format('F j, Y') }}</p>
                        </div>
                    </div>
                </div>

                <!-- Featured Image -->
                <div class="event-featured-image mb-5">
                    <img src="{{ asset('admin/assets/img/news/' . $data->news_image) }}"
                         alt="{{ $data->news_title }}"
                         class="img-fluid rounded-4 shadow-lg w-100">
                </div>

                <!-- News Content -->
                <div class="event-content mb-5">
                    <div class="content-text">
                        <p class="lead">{{ Str::limit($data->description, 200) }}</p>
                        <div class="py-4">
                            {!! $data->description !!}
                        </div>
                    </div>
                </div>

                <!-- News Tags -->
                <div class="card border-0 shadow-sm rounded-4 mb-5">
                    <div class="card-body p-4">
                        <h5 class="card-title fw-bold mb-4">Tags</h5>
                        <div>
                            <a href="#" class="badge bg-secondary me-2">Plastic Industry</a>
                            <a href="#" class="badge bg-secondary me-2">Manufacturing</a>
                            <a href="#" class="badge bg-secondary me-2">Innovation</a>
                        </div>
                    </div>
                </div>

                <!-- Related News -->

            </div>
        </div>
    </div>
</section>

@endsection

@push('styles')
<style>
    .event-detail-section {
        background-color: #f8f9fa;
    }

    .event-header {
        border-bottom: 1px solid #eee;
        padding-bottom: 1.5rem;
    }

    .event-featured-image {
        overflow: hidden;
        border-radius: 12px;
    }

    .event-content {
        line-height: 1.8;
        font-size: 1.1rem;
    }

    .avatar-sm {
        width: 40px;
        height: 40px;
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .card-img-top {
        height: 200px;
        object-fit: cover;
    }
</style>
@endpush



