/**
 * Borough Category Pages CSS
 * Premium design for category pages (borough landing pages)
 *
 * @package Astra Child
 */

/* =================================================================
   CSS VARIABLES
   ================================================================= */
:root {
    --borough-primary: #0066CC;
    --borough-dark: #1a1a1a;
    --borough-gray: #6b7280;
    --borough-light-gray: #f9fafb;
    --borough-border: #e5e7eb;

    --space-1: 4px;
    --space-2: 8px;
    --space-3: 12px;
    --space-4: 16px;
    --space-5: 20px;
    --space-6: 24px;
    --space-8: 32px;
    --space-10: 40px;
    --space-12: 48px;
    --space-16: 64px;
    --space-20: 80px;

    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-full: 9999px;

    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1);

    --transition-fast: 150ms ease-in-out;
    --transition-base: 300ms ease-in-out;
    --transition-slow: 500ms ease-in-out;
}

/* =================================================================
   GLOBAL CONTAINERS
   ================================================================= */
.container-1240 {
    max-width: 1240px;
    margin: 0 auto;
    padding: 0 var(--space-6);
}

/* =================================================================
   1. HERO SECTION
   ================================================================= */
.borough-hero {
    position: relative;
    width: 100%;
    min-height: 600px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    background: var(--borough-dark);
}

/* Hero Gallery Wrapper */
.hero-gallery-wrapper {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.hero-gallery {
    position: relative;
    width: 100%;
    height: 100%;
}

.hero-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    opacity: 0;
    transition: opacity 1s ease-in-out;
    z-index: 1;
}

.hero-slide.active {
    opacity: 1;
    z-index: 2;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(180deg, rgba(0,0,0,0.4) 0%, rgba(0,0,0,0.7) 100%);
    z-index: 3;
}

/* Hero Content */
.hero-content-container {
    position: relative;
    z-index: 10;
    text-align: center;
    color: white;
    max-width: 800px;
    padding: var(--space-20) var(--space-6);
}

.hero-breadcrumbs {
    margin-bottom: var(--space-4);
    opacity: 0.9;
}

.hero-breadcrumbs a {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    transition: color var(--transition-fast);
}

.hero-breadcrumbs a:hover {
    color: white;
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 800;
    margin: 0 0 var(--space-4) 0;
    line-height: 1.1;
    text-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.hero-subtitle {
    font-size: 1.25rem;
    margin: 0 0 var(--space-8) 0;
    opacity: 0.95;
    font-weight: 400;
    line-height: 1.6;
}

/* Hero Search Box */
.hero-search-box {
    max-width: 600px;
    margin: 0 auto var(--space-8);
}

.hero-search-box .search-form {
    position: relative;
    display: flex;
    background: white;
    border-radius: var(--radius-full);
    overflow: hidden;
    box-shadow: var(--shadow-xl);
}

.hero-search-box .search-field {
    flex: 1;
    padding: var(--space-4) var(--space-6);
    border: none;
    font-size: 1rem;
    color: var(--borough-dark);
    outline: none;
}

.hero-search-box .search-field::placeholder {
    color: var(--borough-gray);
}

.hero-search-box .search-submit {
    padding: 0 var(--space-8);
    background: var(--borough-primary);
    border: none;
    color: white;
    cursor: pointer;
    transition: background var(--transition-fast);
    display: flex;
    align-items: center;
    justify-content: center;
}

.hero-search-box .search-submit:hover {
    background: #0052a3;
}

/* Hero Indicators */
.hero-indicators {
    display: flex;
    gap: var(--space-4);
    justify-content: center;
    margin-bottom: var(--space-8);
    flex-wrap: wrap;
}

.indicator-card {
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(10px);
    border-radius: var(--radius-md);
    padding: var(--space-4) var(--space-6);
    display: flex;
    align-items: center;
    gap: var(--space-3);
    border: 1px solid rgba(255, 255, 255, 0.2);
    transition: all var(--transition-base);
}

.indicator-card:hover {
    background: rgba(255, 255, 255, 0.25);
    transform: translateY(-2px);
}

.indicator-card i {
    font-size: 1.5rem;
    opacity: 0.9;
}

.indicator-content {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.indicator-number {
    font-size: 1.5rem;
    font-weight: 700;
    line-height: 1;
}

.indicator-label {
    font-size: 0.875rem;
    opacity: 0.9;
}

/* Hero CTA Button */
.hero-cta-btn {
    display: inline-flex;
    align-items: center;
    gap: var(--space-2);
    padding: var(--space-4) var(--space-8);
    background: white;
    color: var(--borough-dark);
    text-decoration: none;
    border-radius: var(--radius-full);
    font-weight: 600;
    font-size: 1.125rem;
    transition: all var(--transition-base);
    box-shadow: var(--shadow-lg);
}

.hero-cta-btn:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-xl);
}

/* =================================================================
   2. CONTENT + SIDEBAR SECTION
   ================================================================= */
.borough-content-section {
    padding: var(--space-20) 0;
    background: white;
}

.content-sidebar-grid {
    display: grid;
    grid-template-columns: 1fr 340px;
    gap: var(--space-10);
    align-items: start;
}

/* Main Content */
.borough-main-content {
    max-width: 880px;
}

.borough-description {
    font-size: 1.125rem;
    line-height: 1.8;
    color: #374151;
}

.borough-description h2 {
    font-size: 1.875rem;
    font-weight: 700;
    margin: var(--space-8) 0 var(--space-4);
    color: var(--borough-dark);
}

.borough-description h3 {
    font-size: 1.5rem;
    font-weight: 600;
    margin: var(--space-6) 0 var(--space-3);
    color: var(--borough-dark);
}

.borough-description p {
    margin-bottom: var(--space-4);
}

.borough-description ul,
.borough-description ol {
    margin: var(--space-4) 0;
    padding-left: var(--space-6);
}

.borough-description li {
    margin-bottom: var(--space-2);
}

/* Sidebar */
.borough-sidebar {
    position: sticky;
    top: 80px;
    max-height: calc(100vh - 100px);
    overflow-y: auto;
    padding-right: var(--space-2);
}

/* Custom Scrollbar */
.borough-sidebar::-webkit-scrollbar {
    width: 6px;
}

.borough-sidebar::-webkit-scrollbar-track {
    background: transparent;
}

.borough-sidebar::-webkit-scrollbar-thumb {
    background: var(--borough-border);
    border-radius: var(--radius-full);
}

.borough-sidebar::-webkit-scrollbar-thumb:hover {
    background: var(--borough-gray);
}

/* Sidebar Widgets */
.sidebar-widget {
    background: var(--borough-light-gray);
    border-radius: var(--radius-md);
    padding: var(--space-5);
    margin-bottom: var(--space-5);
    border: 1px solid var(--borough-border);
}

.sidebar-widget .widget-title {
    font-size: 1.125rem;
    font-weight: 700;
    margin: 0 0 var(--space-4);
    color: var(--borough-dark);
    display: flex;
    align-items: center;
    gap: var(--space-2);
}

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

.widget-item {
    margin-bottom: var(--space-4);
}

.widget-item:last-child {
    margin-bottom: 0;
}

.widget-item-link {
    display: flex;
    gap: var(--space-3);
    text-decoration: none;
    color: inherit;
    transition: opacity var(--transition-fast);
}

.widget-item-link:hover {
    opacity: 0.8;
}

.widget-item-image {
    position: relative;
    width: 70px;
    height: 70px;
    border-radius: 50%;
    overflow: hidden;
    flex-shrink: 0;
    background: var(--borough-border);
}

.widget-item-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.widget-item-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--borough-gray);
    font-size: 1.5rem;
}

.widget-rating-badge,
.widget-stars-badge {
    position: absolute;
    bottom: -5px;
    right: -5px;
    background: var(--borough-primary);
    color: white;
    font-size: 0.75rem;
    font-weight: 600;
    padding: 2px 6px;
    border-radius: var(--radius-sm);
    border: 2px solid white;
}

.widget-stars-badge {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    display: flex;
    gap: 1px;
}

.widget-stars-badge .star {
    font-size: 10px;
}

.widget-item-content {
    flex: 1;
    min-width: 0;
}

.widget-item-title {
    font-size: 0.9375rem;
    font-weight: 600;
    margin: 0 0 var(--space-1);
    line-height: 1.4;
    color: var(--borough-dark);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.widget-item-date,
.widget-item-price {
    font-size: 0.875rem;
    color: var(--borough-gray);
}

.widget-item-price {
    font-weight: 600;
    color: var(--borough-primary);
}

/* Newsletter Widget */
.widget-newsletter {
    background: linear-gradient(135deg, var(--borough-primary) 0%, #0052a3 100%);
    color: white;
    border: none;
}

.widget-newsletter .widget-title {
    color: white;
}

.widget-newsletter-text {
    font-size: 0.9375rem;
    margin-bottom: var(--space-4);
    opacity: 0.95;
    line-height: 1.6;
}

.newsletter-form {
    display: flex;
    gap: var(--space-2);
}

.newsletter-form input[type="email"] {
    flex: 1;
    padding: var(--space-3) var(--space-4);
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: var(--radius-sm);
    background: rgba(255, 255, 255, 0.1);
    color: white;
    font-size: 0.9375rem;
    outline: none;
}

.newsletter-form input[type="email"]::placeholder {
    color: rgba(255, 255, 255, 0.7);
}

.btn-newsletter {
    padding: 0 var(--space-5);
    background: white;
    color: var(--borough-primary);
    border: none;
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: all var(--transition-fast);
    display: flex;
    align-items: center;
    justify-content: center;
}

.btn-newsletter:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

/* =================================================================
   3. AD SPACES
   ================================================================= */
.ad-space {
    padding: var(--space-10) 0;
    background: var(--borough-light-gray);
}

.ad-space.ad-horizontal {
    text-align: center;
}

.ad-placeholder {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 90px;
    min-width: 728px;
    background: white;
    border: 2px dashed var(--borough-border);
    border-radius: var(--radius-md);
    color: var(--borough-gray);
    font-size: 0.875rem;
    font-weight: 500;
}

/* =================================================================
   4. SWIPER SECTION
   ================================================================= */
.borough-swiper-section {
    padding: var(--space-20) 0;
    background: white;
    overflow: hidden;
}

.borough-swiper-section .section-title {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: var(--space-8);
    color: var(--borough-dark);
}

.swiper-container {
    position: relative;
    width: 100%;
    overflow: visible;
}

.swiper-wrapper {
    display: flex;
}

.swiper-slide {
    width: 300px;
    flex-shrink: 0;
}

.swiper-card {
    background: white;
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-md);
    transition: all var(--transition-base);
    height: 100%;
}

.swiper-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-xl);
}

.swiper-card-link {
    text-decoration: none;
    color: inherit;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.swiper-card-image {
    position: relative;
    width: 100%;
    height: 200px;
    background-size: cover;
    background-position: center;
}

.swiper-card-badge {
    position: absolute;
    top: var(--space-3);
    right: var(--space-3);
    padding: var(--space-2) var(--space-3);
    border-radius: var(--radius-sm);
    font-size: 0.75rem;
    font-weight: 600;
    color: white;
}

.badge-post {
    background: #3b82f6;
}

.badge-hotel {
    background: #f59e0b;
}

.badge-experience {
    background: #10b981;
}

.swiper-card-content {
    padding: var(--space-5);
    flex: 1;
    display: flex;
    flex-direction: column;
}

.swiper-card-title {
    font-size: 1.125rem;
    font-weight: 600;
    margin: 0 0 var(--space-3);
    line-height: 1.4;
    color: var(--borough-dark);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.swiper-card-excerpt {
    font-size: 0.9375rem;
    color: var(--borough-gray);
    margin-bottom: var(--space-4);
    line-height: 1.6;
    flex: 1;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.swiper-card-link-text {
    color: var(--borough-primary);
    font-weight: 600;
    font-size: 0.9375rem;
    display: flex;
    align-items: center;
    gap: var(--space-2);
}

/* Swiper Navigation */
.swiper-button-prev,
.swiper-button-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 48px;
    height: 48px;
    background: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 10;
    box-shadow: var(--shadow-lg);
    transition: all var(--transition-fast);
    color: var(--borough-dark);
}

.swiper-button-prev {
    left: -24px;
}

.swiper-button-next {
    right: -24px;
}

.swiper-button-prev:hover,
.swiper-button-next:hover {
    background: var(--borough-primary);
    color: white;
}

/* Swiper Pagination */
.swiper-pagination {
    text-align: center;
    margin-top: var(--space-8);
}

.swiper-pagination-bullet {
    width: 12px;
    height: 12px;
    background: var(--borough-border);
    border-radius: 50%;
    display: inline-block;
    margin: 0 var(--space-1);
    cursor: pointer;
    transition: all var(--transition-fast);
}

.swiper-pagination-bullet-active {
    background: var(--borough-primary);
    width: 32px;
    border-radius: var(--radius-full);
}

/* =================================================================
   5. GRID SECTIONS (Hotels, Experiences, Posts)
   ================================================================= */
.borough-grid-section {
    padding: var(--space-20) 0;
    background: var(--borough-light-gray);
}

.borough-grid-section:nth-of-type(even) {
    background: white;
}

.borough-grid-section .section-title {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: var(--space-8);
    color: var(--borough-dark);
}

.borough-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: var(--space-6);
    margin-bottom: var(--space-8);
}

/* Load More Button */
.load-more-wrapper {
    text-align: center;
}

.btn-load-more {
    display: inline-flex;
    align-items: center;
    gap: var(--space-2);
    padding: var(--space-4) var(--space-8);
    background: white;
    color: var(--borough-dark);
    border: 2px solid var(--borough-border);
    border-radius: var(--radius-full);
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: all var(--transition-base);
}

.btn-load-more:hover {
    background: var(--borough-primary);
    color: white;
    border-color: var(--borough-primary);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.btn-load-more.loading {
    opacity: 0.6;
    cursor: not-allowed;
}

.btn-load-more.loading i {
    animation: spin 1s linear infinite;
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* =================================================================
   RESPONSIVE DESIGN
   ================================================================= */

/* Tablet (768px - 1239px) */
@media (max-width: 1239px) {
    .hero-title {
        font-size: 2.5rem;
    }

    .content-sidebar-grid {
        grid-template-columns: 1fr;
        gap: var(--space-8);
    }

    .borough-sidebar {
        position: static;
        max-height: none;
        overflow-y: visible;
    }

    .borough-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .swiper-slide {
        width: 280px;
    }
}

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

    .hero-subtitle {
        font-size: 1rem;
    }

    .hero-indicators {
        flex-direction: column;
        align-items: stretch;
    }

    .indicator-card {
        justify-content: center;
    }

    .borough-grid {
        grid-template-columns: 1fr;
    }

    .swiper-slide {
        width: 260px;
    }

    .swiper-button-prev,
    .swiper-button-next {
        display: none;
    }

    .ad-placeholder {
        min-width: 100%;
        max-width: 100%;
    }
}

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

    .container-1240 {
        padding: 0 var(--space-4);
    }
}
