@extends('layouts.app')
@php $active_page = 'about'; @endphp



@section('content')
<main x-data>
    <!-- Hero Section -->
    <section class="relative pt-32 pb-20 bg-slate-50 overflow-hidden">
        <div class="absolute inset-0">
            <div class="absolute -top-[20%] -right-[10%] w-[70%] h-[70%] rounded-full bg-brand-primary/5 blur-3xl"></div>
            <div class="absolute top-[40%] -left-[10%] w-[50%] h-[50%] rounded-full bg-brand-accent/5 blur-3xl"></div>
        </div>
        <div class="container mx-auto px-6 relative z-10">
            <div class="max-w-3xl mx-auto text-center">
                <div class="inline-flex items-center gap-2 px-3 py-1 rounded-full bg-brand-primary/10 text-brand-primary text-xs font-bold uppercase tracking-wider mb-6">
                    About Us
                </div>
                <h1 class="text-4xl md:text-6xl font-extrabold text-slate-900 mb-6 leading-tight">
                    Building the Future with <span class="text-brand-primary">Innovation</span>
                </h1>
                <p class="text-lg text-slate-600 mb-8 max-w-2xl mx-auto leading-relaxed">
                    Extensive Creativity Services Limited (ECS) is a multi-disciplinary powerhouse dedicated to delivering integrated solutions across technology, infrastructure, and commerce.
                </p>
            </div>
        </div>
    </section>

    <!-- Our Story -->
    <section class="py-24 bg-white">
        <div class="container mx-auto px-6 reveal">
            <div class="flex flex-col lg:flex-row gap-16 items-center">
                <div class="lg:w-1/2">
                    <img src="{{ $settings['about_story_image'] ?? 'https://images.unsplash.com/photo-1522071820081-009f0129c71c?auto=format&fit=crop&w=800&q=80' }}" alt="Our Story" class="rounded-2xl shadow-xl w-full object-cover h-[500px]" loading="lazy">
                </div>
                <div class="lg:w-1/2">
                    <h2 class="text-sm font-bold text-brand-primary uppercase tracking-widest mb-2">Who We Are</h2>
                    <h3 class="text-3xl font-bold text-slate-900 mb-6">{{ $settings['about_story_heading'] ?? 'A Legacy of Excellence' }}</h3>
                    <p class="text-slate-600 mb-6 leading-relaxed">
                        {!! nl2br(e($settings['about_story_text'] ?? '')) !!}
                    </p>
                    <p class="text-slate-600 mb-6 leading-relaxed">
                        {!! nl2br(e($settings['about_story_text_2'] ?? '')) !!}
                    </p>
                    <div class="grid grid-cols-2 gap-6 mt-8">
                        <div class="border-l-4 border-brand-accent pl-4">
                            <span class="block text-3xl font-bold text-slate-900">{{ $division_count }}+</span>
                            <span class="text-sm text-slate-500">Business Divisions</span>
                        </div>
                        <div class="border-l-4 border-brand-accent pl-4">
                            <span class="block text-3xl font-bold text-slate-900">100%</span>
                            <span class="text-sm text-slate-500">Client Satisfaction</span>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </section>

    <!-- Mission & Vision -->
    <section class="py-24 bg-brand-dark text-white relative overflow-hidden">
         <div class="absolute top-0 right-0 w-1/2 h-full bg-brand-primary/10 skew-x-12"></div>
         <div class="container mx-auto px-6 relative z-10 reveal">
            <div class="grid md:grid-cols-2 gap-12">
                <div class="bg-white/5 p-8 rounded-2xl border border-white/10 backdrop-blur-sm">
                    <div class="w-12 h-12 bg-brand-accent rounded-lg flex items-center justify-center mb-6 text-white">
                        <svg class="w-6 h-6" fill="none" stroke="currentColor" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M13 10V3L4 14h7v7l9-11h-7z"></path></svg>
                    </div>
                    <h3 class="text-2xl font-bold mb-4">Our Mission</h3>
                    <p class="text-slate-300 leading-relaxed">
                        {!! nl2br(e($settings['mission_text'] ?? '')) !!}
                    </p>
                </div>
                <div class="bg-white/5 p-8 rounded-2xl border border-white/10 backdrop-blur-sm">
                    <div class="w-12 h-12 bg-brand-accent rounded-lg flex items-center justify-center mb-6 text-white">
                        <svg class="w-6 h-6" fill="none" stroke="currentColor" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M15 12a3 3 0 11-6 0 3 3 0 016 0z"></path><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M2.458 12C3.732 7.943 7.523 5 12 5c4.478 0 8.268 2.943 9.542 7-1.274 4.057-5.064 7-9.542 7-4.477 0-8.268-2.943-9.542-7z"></path></svg>
                    </div>
                    <h3 class="text-2xl font-bold mb-4">Our Vision</h3>
                    <p class="text-slate-300 leading-relaxed">
                        {!! nl2br(e($settings['vision_text'] ?? '')) !!}
                    </p>
                </div>
            </div>
         </div>
    </section>

    <!-- Core Values -->
    <section class="py-24 bg-slate-50">
        <div class="container mx-auto px-6 reveal">
            <div class="text-center max-w-2xl mx-auto mb-16">
                <h2 class="text-sm font-bold text-brand-primary uppercase tracking-widest mb-2">Our Culture</h2>
                <h3 class="text-3xl font-bold text-slate-900">Core Values</h3>
            </div>
            <div class="grid md:grid-cols-4 gap-6">
                <div class="bg-white p-6 rounded-xl shadow-sm border border-slate-100 text-center hover:-translate-y-1 transition">
                    <div class="w-12 h-12 mx-auto bg-brand-light text-brand-primary rounded-full flex items-center justify-center mb-4">
                        <svg class="w-6 h-6" fill="none" stroke="currentColor" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M9.663 17h4.673M12 3v1m6.364 1.636l-.707.707M21 12h-1M4 12H3m3.343-5.657l-.707-.707m2.828 9.9a5 5 0 117.072 0l-.548.547A3.374 3.374 0 0014 18.469V19a2 2 0 11-4 0v-.531c0-.895-.356-1.754-.988-2.386l-.548-.547z"></path></svg>
                    </div>
                    <h4 class="font-bold text-slate-900 mb-2">Innovation</h4>
                    <p class="text-sm text-slate-500">Constantly seeking new and better ways to solve problems.</p>
                </div>
                <!-- ... other values ... -->
                <div class="bg-white p-6 rounded-xl shadow-sm border border-slate-100 text-center hover:-translate-y-1 transition">
                    <div class="w-12 h-12 mx-auto bg-brand-light text-brand-primary rounded-full flex items-center justify-center mb-4">
                        <svg class="w-6 h-6" fill="none" stroke="currentColor" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M9 12l2 2 4-4m5.618-4.016A11.955 11.955 0 0112 2.944a11.955 11.955 0 01-8.618 3.04A12.02 12.02 0 003 9c0 5.591 3.824 10.29 9 11.622 5.176-1.332 9-6.03 9-11.622 0-1.042-.133-2.052-.382-3.016z"></path></svg>
                    </div>
                    <h4 class="font-bold text-slate-900 mb-2">Integrity</h4>
                    <p class="text-sm text-slate-500">Upholding the highest standards of honesty and transparency.</p>
                </div>
                <div class="bg-white p-6 rounded-xl shadow-sm border border-slate-100 text-center hover:-translate-y-1 transition">
                    <div class="w-12 h-12 mx-auto bg-brand-light text-brand-primary rounded-full flex items-center justify-center mb-4">
                        <svg class="w-6 h-6" fill="none" stroke="currentColor" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M5 3v4M3 5h4M6 17v4m-2-2h4m5-16l2.286 6.857L21 12l-5.714 2.143L13 21l-2.286-6.857L5 12l5.714-2.143L13 3z"></path></svg>
                    </div>
                    <h4 class="font-bold text-slate-900 mb-2">Excellence</h4>
                    <p class="text-sm text-slate-500">Delivering superior quality in every service we provide.</p>
                </div>
                <div class="bg-white p-6 rounded-xl shadow-sm border border-slate-100 text-center hover:-translate-y-1 transition">
                    <div class="w-12 h-12 mx-auto bg-brand-light text-brand-primary rounded-full flex items-center justify-center mb-4">
                        <svg class="w-6 h-6" fill="none" stroke="currentColor" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M3.055 11H5a2 2 0 012 2v1a2 2 0 002 2 2 2 0 012 2v2.945M8 3.935V5.5A2.5 2.5 0 0010.5 8h.5a2 2 0 012 2 2 2 0 104 0 2 2 0 012-2h1.064M15 20.488V18a2 2 0 012-2h3.064"></path></svg>
                    </div>
                    <h4 class="font-bold text-slate-900 mb-2">Sustainability</h4>
                    <p class="text-sm text-slate-500">Committing to environmentally and socially responsible practices.</p>
                </div>
            </div>
        </div>
    </section>

    <!-- Team Section -->
    <section class="py-24 bg-white">
        <div class="container mx-auto px-6 reveal">
            <div class="text-center max-w-2xl mx-auto mb-16">
                <h2 class="text-sm font-bold text-brand-primary uppercase tracking-widest mb-2">Leadership</h2>
                <h3 class="text-3xl font-bold text-slate-900">Meet Our Team</h3>
            </div>
            <div class="grid md:grid-cols-3 gap-8">
                @if (count($team_members) === 0)
                    <p class="text-center col-span-3 text-slate-500">Team members will be added soon.</p>
                @else
                    @foreach ($team_members as $member)
                    <div class="group text-center">
                        <div class="relative w-48 h-48 mx-auto mb-6 rounded-full overflow-hidden border-4 border-slate-50 shadow-lg group-hover:border-brand-accent transition duration-300">
                            @if ($member->image_path)
                            <img src="{{ url($member->image_path) }}" alt="{{ $member->name }}" class="w-full h-full object-cover" loading="lazy">
                            @else
                            <div class="w-full h-full bg-slate-200 flex items-center justify-center text-slate-400">No Image</div>
                            @endif
                        </div>
                        <h4 class="text-xl font-bold text-slate-900">{{ $member->name }}</h4>
                        <p class="text-brand-primary font-medium mb-3">{{ $member->role }}</p>
                        <p class="text-slate-500 text-sm leading-relaxed max-w-xs mx-auto">{{ $member->bio }}</p>
                    </div>
                    @endforeach
                @endif
            </div>
        </div>
    </section>

    <!-- Testimonials Section -->
    <section class="py-24 bg-slate-50">
        <div class="container mx-auto px-6 reveal">
            <div class="text-center max-w-2xl mx-auto mb-16">
                <h2 class="text-sm font-bold text-brand-primary uppercase tracking-widest mb-2">Testimonials</h2>
                <h3 class="text-3xl font-bold text-slate-900">What Our Clients Say</h3>
            </div>
            <div class="grid md:grid-cols-3 gap-8">
                @if (count($testimonials) === 0)
                    <p class="text-center col-span-3 text-slate-500">No testimonials yet.</p>
                @else
                @foreach ($testimonials as $testimonial)
                <div class="bg-white p-8 rounded-2xl shadow-sm border border-slate-100 relative hover:-translate-y-1 transition-transform duration-300 h-full flex flex-col justify-between">
                    <svg class="w-10 h-10 text-brand-primary/20 absolute top-6 left-6" fill="currentColor" viewBox="0 0 24 24"><path d="M14.017 21L14.017 18C14.017 16.8954 14.9124 16 16.017 16H19.017C19.5693 16 20.017 15.5523 20.017 15V9C20.017 8.44772 19.5693 8 19.017 8H15.017C14.4647 8 14.017 8.44772 14.017 9V11C14.017 11.5523 13.5693 12 13.017 12H12.017V5H22.017V15C22.017 18.3137 19.3307 21 16.017 21H14.017ZM5.0166 21L5.0166 18C5.0166 16.8954 5.91203 16 7.0166 16H10.0166C10.5689 16 11.0166 15.5523 11.0166 15V9C11.0166 8.44772 10.5689 8 10.0166 8H6.0166C5.46432 8 5.0166 8.44772 5.0166 9V11C5.0166 11.5523 4.56889 12 4.0166 12H3.0166V5H13.0166V15C13.0166 18.3137 10.3303 21 7.0166 21H5.0166Z"></path></svg>
                    <p class="text-slate-600 mb-6 relative z-10 pt-8 italic">"{{ $testimonial->content }}"</p>
                    <div>
                        <h4 class="font-bold text-sm text-slate-900">{{ $testimonial->client_name }}</h4>
                        <p class="text-xs text-slate-500">{{ $testimonial->client_role }}</p>
                    </div>
                </div>
                @endforeach
                @endif
            </div>
        </div>
    </section>

    <!-- CTA -->
    <section class="py-20 bg-white border-t border-slate-100">
        <div class="container mx-auto px-6 text-center reveal">
            <h2 class="text-3xl font-bold text-slate-900 mb-6">Ready to Work With Us?</h2>
            <p class="text-slate-600 mb-8 max-w-2xl mx-auto">Whether you need IT solutions, construction services, or logistics support, ECS is your trusted partner.</p>
            <a href="{{ route('contact') }}" class="inline-block px-8 py-4 bg-brand-primary text-white font-bold rounded-full hover:bg-brand-dark transition shadow-lg shadow-brand-primary/30">Contact Us Today</a>
        </div>
    </section>
</main>
@endsection
