{% extends 'expat_life/base.html' %}
{% load static %}

{% block title %}{{ venue.venue_name }} | Host Venue in Sri Lanka{% endblock %}

{% block content %}

<style>
    /* =========================================================
       GUEST HOST VENUE DETAIL — HOSTING THEME
    ========================================================= */

    .guest-host-detail-page {
        min-height: 100vh;
        background:
            radial-gradient(circle at top left, rgba(255, 193, 7, 0.10), transparent 30%),
            radial-gradient(circle at top right, rgba(116, 49, 41, 0.10), transparent 32%),
            linear-gradient(180deg, #fffaf5 0%, #ffffff 48%, #fff7ed 100%);
        color: #2c1b17;
    }

    .guest-host-detail-hero {
        position: relative;
        overflow: hidden;
        min-height: 640px;
        display: flex;
        align-items: end;
        color: #ffffff;
        background:
            linear-gradient(
                100deg,
                rgba(27, 16, 15, 0.96) 0%,
                rgba(54, 27, 24, 0.88) 44%,
                rgba(89, 44, 30, 0.55) 100%
            );
    }

    .guest-host-detail-hero-bg {
        position: absolute;
        inset: 0;
        z-index: 0;
    }

    .guest-host-detail-hero-bg img {
        width: 100%;
        height: 100%;
        object-fit: cover;
    }

    .guest-host-detail-hero-bg::after {
        content: "";
        position: absolute;
        inset: 0;
        background:
            radial-gradient(circle at 82% 18%, rgba(255, 193, 7, 0.28), transparent 28%),
            radial-gradient(circle at 12% 78%, rgba(202, 95, 58, 0.22), transparent 32%),
            linear-gradient(
                100deg,
                rgba(27, 16, 15, 0.96) 0%,
                rgba(54, 27, 24, 0.88) 44%,
                rgba(89, 44, 30, 0.60) 100%
            );
    }

    .guest-host-detail-hero-placeholder {
        position: absolute;
        inset: 0;
        background:
            radial-gradient(circle at top right, rgba(255, 193, 7, 0.28), transparent 34%),
            linear-gradient(145deg, #2e1817 0%, #6d2e28 64%, #a3601b 100%);
    }

    .guest-host-detail-hero::after {
        content: "";
        position: absolute;
        left: 0;
        right: 0;
        bottom: -1px;
        height: 120px;
        background: linear-gradient(180deg, transparent 0%, #fffaf5 100%);
        pointer-events: none;
        z-index: 1;
    }

    .guest-host-detail-hero-inner {
        position: relative;
        z-index: 2;
        padding: 7rem 0 8rem;
    }

    .guest-host-kicker {
        display: inline-flex;
        align-items: center;
        gap: 0.55rem;
        padding: 0.55rem 1.05rem;
        border-radius: 999px;
        background: rgba(255, 255, 255, 0.13);
        border: 1px solid rgba(255, 255, 255, 0.20);
        color: #ffd36b;
        font-size: 0.84rem;
        font-weight: 900;
        text-transform: uppercase;
        letter-spacing: 0.055em;
        backdrop-filter: blur(10px);
        margin-bottom: 1.1rem;
    }

    .guest-host-detail-hero h1 {
        max-width: 980px;
        font-size: clamp(2.35rem, 5vw, 4.8rem);
        font-weight: 950;
        line-height: 1.02;
        letter-spacing: -0.06em;
        margin-bottom: 1rem;
    }

    .guest-host-detail-hero p {
        max-width: 820px;
        color: rgba(255, 255, 255, 0.87);
        font-size: 1.06rem;
        line-height: 1.82;
        margin-bottom: 1.4rem;
    }

    .guest-host-hero-meta {
        display: flex;
        flex-wrap: wrap;
        gap: 0.65rem;
        margin-bottom: 1.6rem;
    }

    .guest-host-hero-chip {
        display: inline-flex;
        align-items: center;
        gap: 0.4rem;
        padding: 0.52rem 0.85rem;
        border-radius: 999px;
        background: rgba(255, 255, 255, 0.13);
        border: 1px solid rgba(255, 255, 255, 0.20);
        color: #ffffff;
        font-size: 0.82rem;
        font-weight: 850;
        backdrop-filter: blur(10px);
    }

    .guest-host-hero-chip.gold {
        background: rgba(255, 200, 63, 0.92);
        border-color: rgba(255, 200, 63, 0.96);
        color: #26160d;
    }

    .guest-host-hero-actions {
        display: flex;
        flex-wrap: wrap;
        gap: 0.9rem;
    }

    .guest-host-hero-actions .btn {
        min-height: 52px;
        border-radius: 18px;
        padding: 0.85rem 1.45rem;
        font-weight: 900;
    }

    .guest-host-btn-gold {
        background: linear-gradient(135deg, #ffc83f, #df9219);
        color: #26160d;
        border: none;
        font-weight: 950 !important;
        box-shadow: 0 18px 34px rgba(223, 146, 25, 0.30);
        transition: all 0.22s ease;
    }

    .guest-host-btn-gold:hover,
    .guest-host-btn-gold:focus {
        background: linear-gradient(135deg, #2e1817, #6d2e28);
        color: #ffffff !important;
        transform: translateY(-2px);
        box-shadow: 0 22px 42px rgba(54, 28, 23, 0.28);
    }

    .guest-host-btn-glass {
        background: rgba(255, 255, 255, 0.10);
        color: #ffffff;
        border: 1px solid rgba(255, 255, 255, 0.34);
        backdrop-filter: blur(10px);
    }

    .guest-host-btn-glass:hover {
        background: rgba(255, 255, 255, 0.17);
        color: #ffffff;
    }

    .guest-host-section {
        padding: 5rem 0;
    }

    .guest-host-section-mini {
        display: inline-flex;
        align-items: center;
        gap: 0.45rem;
        padding: 8px 15px;
        border-radius: 999px;
        background: rgba(184, 111, 31, 0.12);
        border: 1px solid rgba(184, 111, 31, 0.18);
        color: #975816;
        font-size: 0.82rem;
        font-weight: 950;
        text-transform: uppercase;
        letter-spacing: 0.06em;
        margin-bottom: 0.8rem;
    }

    .guest-host-section-title {
        color: #2c1b17;
        font-size: clamp(2rem, 4vw, 3.25rem);
        font-weight: 950;
        line-height: 1.08;
        letter-spacing: -0.05em;
        margin-bottom: 0.9rem;
    }

    .guest-host-section-text {
        color: #78625a;
        font-size: 1rem;
        line-height: 1.85;
        max-width: 830px;
    }

    .guest-host-card {
        border-radius: 32px;
        background: linear-gradient(145deg, #fffaf4 0%, #ffffff 100%);
        border: 1px solid rgba(124, 74, 50, 0.10);
        box-shadow: 0 18px 42px rgba(55, 31, 22, 0.07);
        overflow: hidden;
    }

    .guest-host-card-header {
        padding: 1.5rem 1.6rem 1.05rem;
        border-bottom: 1px solid rgba(124, 74, 50, 0.10);
        background:
            radial-gradient(circle at top right, rgba(255, 193, 7, 0.08), transparent 30%),
            linear-gradient(145deg, #fffaf4 0%, #ffffff 100%);
    }

    .guest-host-card-header h2,
    .guest-host-card-header h3 {
        color: #38231d;
        font-weight: 950;
        margin-bottom: 0.35rem;
    }

    .guest-host-card-header p {
        color: #78625a;
        line-height: 1.7;
        margin-bottom: 0;
    }

    .guest-host-card-body {
        padding: 1.6rem;
    }

    .guest-host-description {
        color: #78625a;
        line-height: 1.9;
        margin-bottom: 0;
        white-space: pre-line;
    }

    .guest-host-info-grid {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 0.9rem;
    }

    .guest-host-info-item {
        border-radius: 22px;
        padding: 1rem;
        background: #fff7e8;
        border: 1px solid #efd8b7;
    }

    .guest-host-info-item span {
        display: block;
        color: #8b6550;
        font-size: 0.76rem;
        font-weight: 950;
        text-transform: uppercase;
        letter-spacing: 0.05em;
        margin-bottom: 0.35rem;
    }

    .guest-host-info-item strong,
    .guest-host-info-item a {
        color: #38231d;
        font-weight: 900;
        text-decoration: none;
        word-break: break-word;
    }

    .guest-host-info-item a:hover {
        color: #a75e17;
        text-decoration: underline;
    }

    .guest-host-feature-grid {
        display: flex;
        flex-wrap: wrap;
        gap: 0.55rem;
    }

    .guest-host-feature-chip {
        display: inline-flex;
        align-items: center;
        gap: 0.35rem;
        border-radius: 999px;
        padding: 0.5rem 0.78rem;
        background: #fff7e8;
        border: 1px solid #efd8b7;
        color: #6f4f3f;
        font-size: 0.8rem;
        font-weight: 850;
    }

    .guest-host-feature-chip i {
        color: #a75e17;
    }

    .guest-host-gallery-grid {
        display: grid;
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 0.85rem;
    }

    .guest-host-gallery-item {
        border-radius: 24px;
        overflow: hidden;
        height: 220px;
        border: 1px solid rgba(124, 74, 50, 0.10);
        background: #ffe8bf;
    }

    .guest-host-gallery-item img {
        width: 100%;
        height: 100%;
        object-fit: cover;
        transition: 0.35s ease;
    }

    .guest-host-gallery-item:hover img {
        transform: scale(1.05);
    }

    .guest-host-product-card {
        height: 100%;
        border-radius: 28px;
        background: #ffffff;
        border: 1px solid rgba(124, 74, 50, 0.10);
        box-shadow: 0 15px 34px rgba(55, 31, 22, 0.06);
        overflow: hidden;
        transition: 0.25s ease;
    }

    .guest-host-product-card:hover {
        transform: translateY(-4px);
        box-shadow: 0 24px 50px rgba(55, 31, 22, 0.12);
    }

    .guest-host-product-img {
        position: relative;
        height: 190px;
        background: #ffe8bf;
        overflow: hidden;
    }

    .guest-host-product-img img {
        width: 100%;
        height: 100%;
        object-fit: cover;
        transition: 0.35s ease;
    }

    .guest-host-product-card:hover .guest-host-product-img img {
        transform: scale(1.05);
    }

    .guest-host-product-placeholder {
        height: 100%;
        display: flex;
        align-items: center;
        justify-content: center;
        background:
            radial-gradient(circle at top right, rgba(255, 193, 7, 0.18), transparent 34%),
            linear-gradient(135deg, #fffaf4, #ffe8bf);
        color: #a75e17;
        font-size: 2.6rem;
    }

    .guest-host-product-badge {
        position: absolute;
        top: 1rem;
        left: 1rem;
        display: inline-flex;
        align-items: center;
        gap: 0.35rem;
        border-radius: 999px;
        padding: 0.42rem 0.75rem;
        background: rgba(255, 200, 63, 0.95);
        color: #26160d;
        font-size: 0.72rem;
        font-weight: 950;
        text-transform: uppercase;
        letter-spacing: 0.04em;
        backdrop-filter: blur(10px);
    }

    .guest-host-product-body {
        padding: 1.25rem;
    }

    .guest-host-product-type {
        color: #975816;
        font-size: 0.76rem;
        font-weight: 950;
        text-transform: uppercase;
        letter-spacing: 0.05em;
        margin-bottom: 0.45rem;
    }

    .guest-host-product-body h3 {
        color: #38231d;
        font-weight: 950;
        font-size: 1.08rem;
        line-height: 1.35;
        margin-bottom: 0.55rem;
    }

    .guest-host-product-body p {
        color: #78625a;
        line-height: 1.65;
        font-size: 0.92rem;
        margin-bottom: 0.9rem;
    }

    .guest-host-product-price {
        display: inline-flex;
        align-items: center;
        gap: 0.35rem;
        border-radius: 999px;
        padding: 0.48rem 0.78rem;
        background: #fff7e8;
        border: 1px solid #efd8b7;
        color: #5a351f;
        font-size: 0.84rem;
        font-weight: 950;
    }

    .guest-host-side-card {
        border-radius: 32px;
        background: linear-gradient(145deg, #fffaf4 0%, #ffffff 100%);
        border: 1px solid rgba(124, 74, 50, 0.10);
        box-shadow: 0 18px 42px rgba(55, 31, 22, 0.07);
        overflow: hidden;
        margin-bottom: 1.4rem;
        position: sticky;
        top: 1rem;
    }

    .guest-host-side-card.not-sticky {
        position: static;
    }

    .guest-host-side-header {
        padding: 1.45rem 1.5rem 1rem;
        border-bottom: 1px solid rgba(124, 74, 50, 0.10);
        background:
            radial-gradient(circle at top right, rgba(255, 193, 7, 0.08), transparent 30%),
            linear-gradient(145deg, #fffaf4 0%, #ffffff 100%);
    }

    .guest-host-side-header h3 {
        color: #38231d;
        font-weight: 950;
        margin-bottom: 0.25rem;
    }

    .guest-host-side-header p {
        color: #78625a;
        line-height: 1.65;
        margin-bottom: 0;
    }

    .guest-host-side-body {
        padding: 1.45rem;
    }

    .guest-host-booking-box {
        border-radius: 28px;
        padding: 1.4rem;
        background:
            radial-gradient(circle at top right, rgba(255, 193, 7, 0.18), transparent 34%),
            linear-gradient(145deg, #2e1817 0%, #6d2e28 64%, #a3601b 100%);
        color: #ffffff;
        margin-bottom: 1rem;
    }

    .guest-host-booking-box span {
        display: block;
        color: rgba(255, 255, 255, 0.72);
        font-size: 0.78rem;
        font-weight: 950;
        text-transform: uppercase;
        letter-spacing: 0.05em;
        margin-bottom: 0.4rem;
    }

    .guest-host-booking-box strong {
        display: block;
        color: #ffffff;
        font-size: 1.6rem;
        font-weight: 950;
        line-height: 1.2;
        margin-bottom: 0.7rem;
    }

    .guest-host-booking-box p {
        color: rgba(255, 255, 255, 0.82);
        line-height: 1.65;
        margin-bottom: 0;
        font-size: 0.92rem;
    }

    .guest-host-note-box {
        border-radius: 24px;
        padding: 1rem;
        background: #fff7e8;
        border: 1px solid #efd8b7;
        color: #6f4f3f;
        line-height: 1.7;
        white-space: pre-line;
    }

    .guest-host-related-card {
        border-radius: 26px;
        overflow: hidden;
        background: #ffffff;
        border: 1px solid rgba(124, 74, 50, 0.10);
        box-shadow: 0 12px 28px rgba(55, 31, 22, 0.05);
        height: 100%;
    }

    .guest-host-related-img {
        height: 170px;
        background: #ffe8bf;
        overflow: hidden;
    }

    .guest-host-related-img img {
        width: 100%;
        height: 100%;
        object-fit: cover;
    }

    .guest-host-related-body {
        padding: 1rem;
    }

    .guest-host-related-body h4 {
        color: #38231d;
        font-weight: 950;
        font-size: 1rem;
        line-height: 1.35;
        margin-bottom: 0.4rem;
    }

    .guest-host-related-body p {
        color: #78625a;
        font-size: 0.88rem;
        line-height: 1.55;
        margin-bottom: 0.85rem;
    }

    @media (max-width: 991.98px) {
        .guest-host-detail-hero {
            min-height: auto;
        }

        .guest-host-detail-hero-inner {
            padding: 5.5rem 0 6.5rem;
        }

        .guest-host-section {
            padding: 4rem 0;
        }

        .guest-host-side-card {
            position: static;
        }

        .guest-host-gallery-grid {
            grid-template-columns: repeat(2, minmax(0, 1fr));
        }
    }

    @media (max-width: 767.98px) {
        .guest-host-hero-actions {
            flex-direction: column;
            align-items: stretch;
        }

        .guest-host-hero-actions .btn {
            width: 100%;
        }

        .guest-host-info-grid,
        .guest-host-gallery-grid {
            grid-template-columns: 1fr;
        }

        .guest-host-card-body,
        .guest-host-card-header,
        .guest-host-side-header,
        .guest-host-side-body {
            padding-left: 1.15rem;
            padding-right: 1.15rem;
        }
    }

    @media (max-width: 575.98px) {
        .guest-host-detail-hero > .container,
        .guest-host-section > .container {
            padding-left: 1.25rem !important;
            padding-right: 1.25rem !important;
        }
    }
</style>


<div class="guest-host-detail-page">

    <!-- =====================================================
         HERO
    ====================================================== -->
    <section class="guest-host-detail-hero">

        {% if venue.cover_image %}
            <div class="guest-host-detail-hero-bg">
                <img src="{{ venue.cover_image.url }}" alt="{{ venue.venue_name }}">
            </div>
        {% else %}
            <div class="guest-host-detail-hero-placeholder"></div>
        {% endif %}

        <div class="container guest-host-detail-hero-inner">

            <span class="guest-host-kicker">
                <i class="bi bi-building-heart"></i>
                Host Venue Details
            </span>

            <h1>{{ venue.venue_name }}</h1>

            <p>
                {{ venue.short_description }}
            </p>

            <div class="guest-host-hero-meta">
                {% if venue.is_featured %}
                    <span class="guest-host-hero-chip gold">
                        <i class="bi bi-star-fill"></i>
                        Featured Venue
                    </span>
                {% endif %}

                {% if venue.venue_category %}
                    <span class="guest-host-hero-chip">
                        <i class="bi bi-tag-fill"></i>
                        {{ venue.get_venue_category_display }}
                    </span>
                {% endif %}

                {% if venue.city or venue.district %}
                    <span class="guest-host-hero-chip">
                        <i class="bi bi-geo-alt-fill"></i>
                        {% if venue.city %}{{ venue.city }}{% endif %}
                        {% if venue.city and venue.district %}, {% endif %}
                        {% if venue.district %}{{ venue.district }}{% endif %}
                    </span>
                {% endif %}

                {% if venue.max_guest_capacity %}
                    <span class="guest-host-hero-chip">
                        <i class="bi bi-people-fill"></i>
                        Up to {{ venue.max_guest_capacity }} guests
                    </span>
                {% endif %}
            </div>

            <div class="guest-host-hero-actions">
                <a href="#packages"
                   class="btn guest-host-btn-gold">
                    <i class="bi bi-gift-fill me-2"></i>
                    View Packages
                </a>

                <a href="{% url 'expat_life:guest_host_venue_list' %}"
                   class="btn guest-host-btn-glass">
                    <i class="bi bi-arrow-left-circle me-2"></i>
                    Back to Venues
                </a>
            </div>

        </div>
    </section>


    <!-- =====================================================
         MAIN DETAILS
    ====================================================== -->
    <section class="guest-host-section">
        <div class="container">

            <div class="row g-4 align-items-start">

                <!-- MAIN CONTENT -->
                <div class="col-lg-8">

                    <!-- DESCRIPTION -->
                    <div class="guest-host-card mb-4">
                        <div class="guest-host-card-header">
                            <h2>About This Venue</h2>
                            <p>
                                Learn more about the atmosphere, suitability, and event possibilities of this venue.
                            </p>
                        </div>

                        <div class="guest-host-card-body">
                            <p class="guest-host-description">
                                {{ venue.full_description }}
                            </p>
                        </div>
                    </div>


                    <!-- GALLERY -->
                    {% if gallery_images %}
                        <div class="guest-host-card mb-4">
                            <div class="guest-host-card-header">
                                <h3>Venue Gallery</h3>
                                <p>
                                    Browse images shared by the hosting partner.
                                </p>
                            </div>

                            <div class="guest-host-card-body">
                                <div class="guest-host-gallery-grid">
                                    {% for image in gallery_images %}
                                        <div class="guest-host-gallery-item">
                                            <img src="{{ image.image.url }}"
                                                 alt="{{ image.caption|default:venue.venue_name }}">
                                        </div>
                                    {% endfor %}
                                </div>
                            </div>
                        </div>
                    {% endif %}


                    <!-- EVENT SUITABILITY -->
                    <div class="guest-host-card mb-4">
                        <div class="guest-host-card-header">
                            <h3>Suitable For</h3>
                            <p>
                                These are the celebration types this venue can usually support.
                            </p>
                        </div>

                        <div class="guest-host-card-body">
                            <div class="guest-host-feature-grid">

                                {% if venue.supports_romantic_dates %}
                                    <span class="guest-host-feature-chip">
                                        <i class="bi bi-heart-fill"></i>
                                        Romantic Dates
                                    </span>
                                {% endif %}

                                {% if venue.supports_proposal_events %}
                                    <span class="guest-host-feature-chip">
                                        <i class="bi bi-gem"></i>
                                        Proposal Events
                                    </span>
                                {% endif %}

                                {% if venue.supports_anniversaries %}
                                    <span class="guest-host-feature-chip">
                                        <i class="bi bi-calendar-heart"></i>
                                        Anniversaries
                                    </span>
                                {% endif %}

                                {% if venue.supports_birthdays %}
                                    <span class="guest-host-feature-chip">
                                        <i class="bi bi-balloon-heart"></i>
                                        Birthdays
                                    </span>
                                {% endif %}

                                {% if venue.supports_honeymoon_experiences %}
                                    <span class="guest-host-feature-chip">
                                        <i class="bi bi-suit-heart-fill"></i>
                                        Honeymoon Experiences
                                    </span>
                                {% endif %}

                                {% if venue.supports_private_dinners %}
                                    <span class="guest-host-feature-chip">
                                        <i class="bi bi-cup-hot"></i>
                                        Private Dinners
                                    </span>
                                {% endif %}

                                {% if venue.supports_engagement_events %}
                                    <span class="guest-host-feature-chip">
                                        <i class="bi bi-gift-fill"></i>
                                        Engagement Events
                                    </span>
                                {% endif %}

                                {% if venue.supports_small_weddings %}
                                    <span class="guest-host-feature-chip">
                                        <i class="bi bi-flower1"></i>
                                        Small Weddings
                                    </span>
                                {% endif %}

                                {% if venue.supports_custom_celebrations %}
                                    <span class="guest-host-feature-chip">
                                        <i class="bi bi-magic"></i>
                                        Custom Celebrations
                                    </span>
                                {% endif %}

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


                    <!-- FACILITIES -->
                    <div class="guest-host-card mb-4">
                        <div class="guest-host-card-header">
                            <h3>Venue Facilities & Capabilities</h3>
                            <p>
                                Practical facilities and support options available at this venue.
                            </p>
                        </div>

                        <div class="guest-host-card-body">
                            <div class="guest-host-feature-grid">

                                {% if venue.meal_service_available %}
                                    <span class="guest-host-feature-chip">
                                        <i class="bi bi-cup-hot-fill"></i>
                                        Meal Service
                                    </span>
                                {% endif %}

                                {% if venue.alcohol_available %}
                                    <span class="guest-host-feature-chip">
                                        <i class="bi bi-cup-straw"></i>
                                        Alcohol Available
                                    </span>
                                {% endif %}

                                {% if venue.decoration_available %}
                                    <span class="guest-host-feature-chip">
                                        <i class="bi bi-stars"></i>
                                        Decoration Available
                                    </span>
                                {% endif %}

                                {% if venue.photography_allowed %}
                                    <span class="guest-host-feature-chip">
                                        <i class="bi bi-camera-fill"></i>
                                        Photography Allowed
                                    </span>
                                {% endif %}

                                {% if venue.music_allowed %}
                                    <span class="guest-host-feature-chip">
                                        <i class="bi bi-music-note-beamed"></i>
                                        Music Allowed
                                    </span>
                                {% endif %}

                                {% if venue.indoor_available %}
                                    <span class="guest-host-feature-chip">
                                        <i class="bi bi-house-door-fill"></i>
                                        Indoor Area
                                    </span>
                                {% endif %}

                                {% if venue.outdoor_available %}
                                    <span class="guest-host-feature-chip">
                                        <i class="bi bi-tree-fill"></i>
                                        Outdoor Area
                                    </span>
                                {% endif %}

                                {% if venue.private_area_available %}
                                    <span class="guest-host-feature-chip">
                                        <i class="bi bi-shield-lock-fill"></i>
                                        Private Area
                                    </span>
                                {% endif %}

                                {% if venue.parking_available %}
                                    <span class="guest-host-feature-chip">
                                        <i class="bi bi-p-circle-fill"></i>
                                        Parking
                                    </span>
                                {% endif %}

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


                    <!-- EVENT PACKAGES -->
                    <div class="guest-host-card mb-4" id="packages">
                        <div class="guest-host-card-header">
                            <h3>Event Packages</h3>
                            <p>
                                Packages prepared by the host for specific celebration experiences.
                            </p>
                        </div>

                        <div class="guest-host-card-body">
                            {% if event_packages %}
                                <div class="row g-4">
                                    {% for package in event_packages %}
                                        <div class="col-md-6">
                                            <div class="guest-host-product-card">

                                                <div class="guest-host-product-img">
                                                    {% if package.package_image  %}
                                                        <img src="{{ package.package_image.url }}" alt="{{ package.title }}">
                                                    {% else %}
                                                        <div class="guest-host-product-placeholder">
                                                            <i class="bi bi-gift-fill"></i>
                                                        </div>
                                                    {% endif %}

                                                    {% if package.is_featured %}
                                                        <span class="guest-host-product-badge">
                                                            <i class="bi bi-star-fill"></i>
                                                            Featured
                                                        </span>
                                                    {% endif %}
                                                </div>

                                                <div class="guest-host-product-body">
                                                    <div class="guest-host-product-type">
                                                        Event Package
                                                    </div>

                                                    <h3>{{ package.title }}</h3>

                                                    {% if package.description %}
                                                        <p>{{ package.description|truncatechars:145 }}</p>
                                                    {% endif %}

                                                    <span class="guest-host-product-price">
                                                        <i class="bi bi-cash-coin"></i>
                                                        USD {{ package.price_usd|floatformat:2 }}
                                                    </span>
                                                </div>

                                            </div>
                                        </div>
                                    {% endfor %}
                                </div>
                            {% else %}
                                <p class="text-muted mb-0">
                                    No event packages have been published for this venue yet.
                                </p>
                            {% endif %}
                        </div>
                    </div>


                    <!-- MEAL PLANS -->
                    <div class="guest-host-card mb-4">
                        <div class="guest-host-card-header">
                            <h3>Meal Plans</h3>
                            <p>
                                Optional dining arrangements available for this venue.
                            </p>
                        </div>

                        <div class="guest-host-card-body">
                            {% if meal_plans %}
                                <div class="row g-4">
                                    {% for meal_plan in meal_plans %}
                                        <div class="col-md-6">
                                            <div class="guest-host-product-card">

                                                <div class="guest-host-product-img">
                                                    {% if meal_plan.meal_image  %}
                                                        <img src="{{ meal_plan.meal_image.url }}" alt="{{ meal_plan.title }}">
                                                    {% else %}
                                                        <div class="guest-host-product-placeholder">
                                                            <i class="bi bi-cup-hot-fill"></i>
                                                        </div>
                                                    {% endif %}

                                                    {% if meal_plan.is_featured %}
                                                        <span class="guest-host-product-badge">
                                                            <i class="bi bi-star-fill"></i>
                                                            Featured
                                                        </span>
                                                    {% endif %}
                                                </div>

                                                <div class="guest-host-product-body">
                                                    <div class="guest-host-product-type">
                                                        Meal Plan
                                                    </div>

                                                    <h3>{{ meal_plan.title }}</h3>

                                                    {% if meal_plan.description %}
                                                        <p>{{ meal_plan.description|truncatechars:145 }}</p>
                                                    {% endif %}

                                                    <span class="guest-host-product-price">
                                                        <i class="bi bi-cash-coin"></i>
                                                        USD {{ meal_plan.price_per_person_usd|floatformat:2 }} per person
                                                    </span>

                                                    {% if meal_plan.minimum_people %}
                                                        <div class="mt-2 text-muted small">
                                                            Minimum {{ meal_plan.minimum_people }} people
                                                        </div>
                                                    {% endif %}
                                                </div>

                                            </div>
                                        </div>
                                    {% endfor %}
                                </div>
                            {% else %}
                                <p class="text-muted mb-0">
                                    No meal plans have been published for this venue yet.
                                </p>
                            {% endif %}
                        </div>
                    </div>


                    <!-- ADD-ON SERVICES -->
                    <div class="guest-host-card mb-4">
                        <div class="guest-host-card-header">
                            <h3>Add-on Services</h3>
                            <p>
                                Optional enhancements such as décor, cake, flowers, photography, music, and more.
                            </p>
                        </div>

                        <div class="guest-host-card-body">
                            {% if add_on_services %}
                                <div class="row g-4">
                                    {% for service in add_on_services %}
                                        <div class="col-md-6">
                                            <div class="guest-host-product-card">

                                                <div class="guest-host-product-img">
                                                    {% if service.add_on_image  %}
                                                        <img src="{{ service.add_on_image.url }}" alt="{{ service.title }}">
                                                    {% else %}
                                                        <div class="guest-host-product-placeholder">
                                                            <i class="bi bi-stars"></i>
                                                        </div>
                                                    {% endif %}

                                                    {% if service.is_featured %}
                                                        <span class="guest-host-product-badge">
                                                            <i class="bi bi-star-fill"></i>
                                                            Featured
                                                        </span>
                                                    {% endif %}
                                                </div>

                                                <div class="guest-host-product-body">
                                                    <div class="guest-host-product-type">
                                                        Add-on Service
                                                    </div>

                                                    <h3>{{ service.title }}</h3>

                                                    {% if service.description %}
                                                        <p>{{ service.description|truncatechars:145 }}</p>
                                                    {% endif %}

                                                    <span class="guest-host-product-price">
                                                        <i class="bi bi-cash-coin"></i>
                                                        USD {{ service.price_usd|floatformat:2 }}
                                                        {% if service.pricing_type %}
                                                            · {{ service.get_pricing_type_display }}
                                                        {% endif %}
                                                    </span>
                                                </div>

                                            </div>
                                        </div>
                                    {% endfor %}
                                </div>
                            {% else %}
                                <p class="text-muted mb-0">
                                    No add-on services have been published for this venue yet.
                                </p>
                            {% endif %}
                        </div>
                    </div>

                </div>


                <!-- SIDEBAR -->
                <div class="col-lg-4">

                    <div class="guest-host-side-card">
                        <div class="guest-host-side-header">
                            <h3>Plan This Experience</h3>
                            <p>
                                Booking and ordering will be connected next.
                            </p>
                        </div>

                        <div class="guest-host-side-body">
                            <div class="guest-host-booking-box">
                                <span>Booking Flow</span>
                                <strong>Ready to Plan</strong>
                                <p>
                                    Select your preferred package, meal plan, add-on services, event date,
                                    guest count, and special notes. Your booking order will be prepared and
                                    added to your Guest Payment Center for confirmation.
                                </p>
                            </div>

                            <div class="d-grid gap-2">
                                <a href="{% url 'expat_life:guest_host_booking_start' venue.slug %}"
                                class="btn guest-host-btn-gold">
                                    <i class="bi bi-calendar-heart-fill me-2"></i>
                                    Book This Experience
                                </a>

                                <a href="#packages"
                                class="btn btn-outline-dark rounded-pill fw-bold">
                                    <i class="bi bi-gift-fill me-2"></i>
                                    Review Packages
                                </a>

                                <a href="{% url 'expat_life:contact_page' %}"
                                class="btn btn-outline-dark rounded-pill fw-bold">
                                    <i class="bi bi-chat-heart-fill me-2"></i>
                                    Ask About This Venue
                                </a>

                                <a href="{% url 'expat_life:guest_host_venue_list' %}"
                                class="btn btn-outline-secondary rounded-pill fw-bold">
                                    <i class="bi bi-arrow-left-circle me-2"></i>
                                    Back to Venues
                                </a>
                            </div>
                        </div>


                    <div class="guest-host-side-card not-sticky">
                        <div class="guest-host-side-header">
                            <h3>Venue Information</h3>
                            <p>
                                Key details about this host venue.
                            </p>
                        </div>

                        <div class="guest-host-side-body">
                            <div class="guest-host-info-grid" style="grid-template-columns: 1fr;">

                                <div class="guest-host-info-item">
                                    <span>Category</span>
                                    <strong>
                                        {% if venue.venue_category %}
                                            {{ venue.get_venue_category_display }}
                                        {% else %}
                                            Host Venue
                                        {% endif %}
                                    </strong>
                                </div>

                                <div class="guest-host-info-item">
                                    <span>Location</span>
                                    <strong>
                                        {% if venue.city %}{{ venue.city }}{% endif %}
                                        {% if venue.city and venue.district %}, {% endif %}
                                        {% if venue.district %}{{ venue.district }}{% endif %}
                                    </strong>
                                </div>

                                {% if venue.max_guest_capacity %}
                                    <div class="guest-host-info-item">
                                        <span>Guest Capacity</span>
                                        <strong>Up to {{ venue.max_guest_capacity }} guests</strong>
                                    </div>
                                {% endif %}

                                {% if venue.google_map_link %}
                                    <div class="guest-host-info-item">
                                        <span>Map Link</span>
                                        <a href="{{ venue.google_map_link }}" target="_blank" rel="noopener">
                                            Open Google Map
                                            <i class="bi bi-box-arrow-up-right ms-1"></i>
                                        </a>
                                    </div>
                                {% endif %}

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


                    {% if venue.important_notes %}
                        <div class="guest-host-side-card not-sticky">
                            <div class="guest-host-side-header">
                                <h3>Important Notes</h3>
                                <p>
                                    Please review these details before planning an event.
                                </p>
                            </div>

                            <div class="guest-host-side-body">
                                <div class="guest-host-note-box">
                                    {{ venue.important_notes }}
                                </div>
                            </div>
                        </div>
                    {% endif %}

                </div>

            </div>

        </div>
    </section>


    <!-- =====================================================
         RELATED VENUES
    ====================================================== -->
    {% if related_venues %}
        <section class="guest-host-section pt-0">
            <div class="container">

                <span class="guest-host-section-mini">
                    <i class="bi bi-building-heart"></i>
                    Related Venues
                </span>

                <h2 class="guest-host-section-title">
                    More venues nearby.
                </h2>

                <p class="guest-host-section-text mb-4">
                    Explore other host venues in the same district that may also suit your celebration plans.
                </p>

                <div class="row g-4">
                    {% for related in related_venues %}
                        <div class="col-md-6 col-xl-3">
                            <div class="guest-host-related-card">

                                <div class="guest-host-related-img">
                                    {% if related.cover_image %}
                                        <img src="{{ related.cover_image.url }}" alt="{{ related.venue_name }}">
                                    {% else %}
                                        <div class="guest-host-product-placeholder">
                                            <i class="bi bi-building-heart"></i>
                                        </div>
                                    {% endif %}
                                </div>

                                <div class="guest-host-related-body">
                                    <h4>{{ related.venue_name }}</h4>

                                    <p>
                                        {% if related.city %}{{ related.city }}{% endif %}
                                        {% if related.city and related.district %}, {% endif %}
                                        {% if related.district %}{{ related.district }}{% endif %}
                                    </p>

                                    <a href="{% url 'expat_life:guest_host_venue_detail' related.slug %}"
                                       class="btn btn-outline-dark rounded-pill fw-bold w-100">
                                        View Details
                                    </a>
                                </div>

                            </div>
                        </div>
                    {% endfor %}
                </div>

            </div>
        </section>
    {% endif %}

</div>

{% endblock %}