/* ==========================
   LISTING PAGE LAYOUT STYLES
   Extends style.css with listing-specific layouts
========================== */

/* ==========================
   Header & Navigation
========================== */
.main-header {
    background: var(--card-bg);
    border-bottom: 1px solid var(--border-color);
    padding: 1rem 0;
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: var(--shadow-sm);
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.logo-text {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    color: var(--primary-color);
    letter-spacing: 0.5px;
}

.main-nav {
    display: flex;
    align-items: center;
}

.nav-list {
    display: flex;
    gap: 2rem;
    list-style: none;
    margin: 0;
    padding: 0;
}

.nav-list li a {
    color: var(--text-main);
    font-weight: 500;
    font-size: 0.95rem;
    transition: var(--transition);
    padding: 0.5rem 0;
}

.nav-list li a:hover,
.nav-list li a.active {
    color: var(--primary-color);
}

.mobile-nav-toggle {
    display: none;
    background: transparent;
    border: none;
    font-size: 1.5rem;
    color: var(--text-main);
    cursor: pointer;
}

/* ==========================
   Hero Section (Mini)
========================== */
.mini-hero {
    position: relative;
    height: 300px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 3rem;
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    filter: brightness(0.7);
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to bottom, rgba(0, 0, 0, 0.3), rgba(0, 0, 0, 0.5));
}

.hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    color: white;
}

.hero-header-center {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
}

.hero-page-title {
    font-family: var(--font-heading);
    font-size: 3rem;
    margin: 0;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
    letter-spacing: 1px;
}

/* Breadcrumb in Hero */
.mini-hero .breadcrumb-nav {
    margin-top: 0.5rem;
}

.mini-hero .breadcrumb-list {
    color: rgba(255, 255, 255, 0.9);
}

.mini-hero .breadcrumb-item a {
    color: rgba(255, 255, 255, 0.9);
}

.mini-hero .breadcrumb-item a:hover {
    color: white;
}

.mini-hero .breadcrumb-item.active {
    color: white;
}

.mini-hero .breadcrumb-item + .breadcrumb-item::before {
    color: rgba(255, 255, 255, 0.7);
}

/* ==========================
   Main Layout (Sidebar + Content)
========================== */
.main-layout {
    padding: 2rem 0;
}

.listing-layout {
    display: grid;
    grid-template-columns: var(--sidebar-width) 1fr;
    gap: 2rem;
    align-items: start;
}

/* ==========================
   Sidebar
========================== */
.listing-sidebar {
    position: sticky;
    top: 100px;
}

.sidebar-card {
    background: var(--card-bg);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    box-shadow: var(--shadow-md);
    border: 1px solid var(--border-color);
}

.sidebar-header {
    margin-bottom: 1.5rem;
}

.sidebar-header h3 {
    font-size: 1.2rem;
    color: var(--text-main);
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin: 0;
}

.sidebar-header h3 i {
    color: var(--primary-color);
}

.filter-group {
    margin-bottom: 1.5rem;
}

.filter-group:last-child {
    margin-bottom: 0;
}

.filter-title {
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--text-muted);
    margin-bottom: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.checkbox-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.checkbox-list li {
    margin-bottom: 0.5rem;
}

.related-link {
    display: block;
    padding: 0.5rem 0.8rem;
    color: var(--text-main);
    font-size: 0.9rem;
    border-radius: var(--radius-md);
    transition: var(--transition);
}

.related-link:hover {
    background: var(--bg-color);
    color: var(--primary-color);
    padding-left: 1rem;
}

/* ==========================
   Main Content Area
========================== */
.listing-content {
    min-width: 0;
}

.listing-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    flex-wrap: wrap;
    gap: 1rem;
}

.listing-header h2 {
    font-family: var(--font-heading);
    font-size: 1.8rem;
    color: var(--text-main);
    margin: 0;
}

.listing-sort {
    min-width: 200px;
}

/* ==========================
   Place Cards Grid
========================== */
.listing-grid-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1.5rem;
    margin-bottom: 3rem;
}

.place-card {
    background: var(--card-bg);
    border-radius: var(--radius-lg);
    overflow: hidden;
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    display: flex;
    flex-direction: column;
}

.place-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-hover);
}

.card-image {
    position: relative;
    width: 100%;
    height: 200px;
    overflow: hidden;
}

.card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

.place-card:hover .card-image img {
    transform: scale(1.05);
}

.card-badge {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: var(--primary-color);
    color: white;
    padding: 0.4rem 0.8rem;
    border-radius: var(--radius-pill);
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.card-content {
    padding: 1.25rem;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.card-header-row {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 1rem;
    margin-bottom: 0.8rem;
}

.card-header-row h3 {
    font-size: 1.15rem;
    margin: 0;
    flex: 1;
}

.card-header-row h3 a {
    color: var(--text-main);
    transition: var(--transition);
}

.card-header-row h3 a:hover {
    color: var(--primary-color);
}

.card-rating {
    display: flex;
    align-items: center;
    gap: 0.3rem;
    background: rgba(255, 165, 0, 0.1);
    padding: 0.3rem 0.6rem;
    border-radius: var(--radius-pill);
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--text-main);
    white-space: nowrap;
}

.card-rating i {
    color: #ffa500;
    font-size: 0.85rem;
}

.card-address {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.card-address i {
    color: var(--primary-color);
    font-size: 0.85rem;
}

.card-footer-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: auto;
    padding-top: 1rem;
    border-top: 1px solid var(--border-color);
}

.review-count-badge {
    font-size: 0.85rem;
    color: var(--text-muted);
}

/* ==========================
   Pagination
========================== */
.pagination-container {
    display: flex;
    justify-content: center;
    padding: 2rem 0;
}

/* ==========================
   Footer
========================== */
.main-footer {
    background: var(--card-bg);
    border-top: 1px solid var(--border-color);
    padding: 3rem 0 1.5rem;
    margin-top: 4rem;
}

.footer-content {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 3rem;
    margin-bottom: 2rem;
}

.footer-col h3 {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.footer-col h4 {
    font-size: 1.1rem;
    color: var(--text-main);
    margin-bottom: 1rem;
    font-weight: 600;
}

.footer-col p {
    color: var(--text-muted);
    font-size: 0.9rem;
    line-height: 1.7;
    margin-bottom: 1rem;
}

.footer-col ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-col ul li {
    margin-bottom: 0.6rem;
}

.footer-col ul li a {
    color: var(--text-muted);
    font-size: 0.9rem;
    transition: var(--transition);
}

.footer-col ul li a:hover {
    color: var(--primary-color);
    padding-left: 0.5rem;
}

.footer-col .social-links {
    margin-top: 1rem;
}

.footer-col .social-links a {
    width: 40px;
    height: 40px;
    background: var(--bg-color);
    border: 1px solid var(--border-color);
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--text-main);
    font-size: 1.1rem;
    transition: var(--transition);
}

.footer-col .social-links a:hover {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
    transform: translateY(-3px);
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid var(--border-color);
}

.footer-bottom small {
    color: var(--text-muted);
    font-size: 0.85rem;
}

/* ==========================
   Responsive Design
========================== */

/* Tablet */
@media (max-width: 968px) {
    .listing-layout {
        grid-template-columns: 1fr;
    }

    .listing-sidebar {
        position: static;
        order: 2;
        margin-top: 3rem;
    }

    .listing-content {
        order: 1;
    }

    .listing-grid-container {
        grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    }

    .footer-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
}

/* Mobile */
@media (max-width: 768px) {
    .hero-page-title {
        font-size: 2rem;
    }

    .mini-hero {
        height: 250px;
    }

    .nav-list {
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--card-bg);
        flex-direction: column;
        gap: 0;
        padding: 1rem;
        border-bottom: 1px solid var(--border-color);
        box-shadow: var(--shadow-md);
        display: none;
    }

    .nav-list.active {
        display: flex;
    }

    .nav-list li {
        width: 100%;
    }

    .nav-list li a {
        display: block;
        padding: 0.8rem;
        border-radius: var(--radius-md);
    }

    .nav-list li a:hover {
        background: var(--bg-color);
    }

    .mobile-nav-toggle {
        display: block;
    }

    .main-nav {
        position: relative;
    }

    .listing-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .listing-header h2 {
        font-size: 1.5rem;
    }

    .listing-sort {
        width: 100%;
    }

    .listing-grid-container {
        grid-template-columns: 1fr;
        gap: 1.25rem;
    }
}

/* Small Mobile */
@media (max-width: 480px) {
    .hero-page-title {
        font-size: 1.75rem;
    }

    .mini-hero {
        height: 200px;
        margin-bottom: 2rem;
    }

    .container {
        padding: 0 1rem;
    }

    .main-layout {
        padding: 1.5rem 0;
    }

    .card-header-row {
        flex-direction: column;
        align-items: flex-start;
    }

    .card-rating {
        align-self: flex-start;
    }

    .sidebar-card {
        padding: 1.25rem;
    }
}
