/* Modern Home Page Styles */

/* Section Headers */
.section-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    margin-bottom: 1.5rem;
    padding: 0 4px;
}

.section-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--color-text);
    margin-bottom: 0;
    letter-spacing: -0.02em;
}

.section-more-link {
    font-size: 0.9rem;
    color: var(--color-text-muted);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 4px;
    transition: color 0.2s;
}

.section-more-link:hover {
    color: var(--color-primary);
}

/* Custom More Button */
.btn-more-custom {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 16px;
    background-color: #c4d9ed;
    color: #495057;
    border-radius: 50px;
    /* Pill shape */
    font-size: 0.9rem;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.2s cubic-bezier(0.25, 0.8, 0.25, 1);
    border: 1px solid transparent;
}

.btn-more-custom i {
    font-size: 0.9em;
    transition: transform 0.2s;
}

.btn-more-custom:hover {
    background-color: var(--color-primary);
    color: white;
    transform: translateY(-1px);
    box-shadow: 0 4px 10px rgba(var(--color-primary-rgb), 0.3);
    border-color: transparent;
}

.btn-more-custom:hover i {
    transform: translateX(3px);
}

/* More Button Wrapper (New Layout) */
.section-more-wrap {
    display: flex;
    justify-content: flex-end;
    margin-bottom: 1.5rem;
    padding-right: 4px;
}

/* Styled Section Header */

/* Styled Section Header */
/* Styled Section Header */
/* Styled Section Header */
.styled-section-header {
    position: relative;
    padding-left: 16px;
    border-left: 4px solid var(--color-primary);
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
}

.styled-section-header .section-title {
    display: flex;
    align-items: center;
    font-size: 1.4rem;
    font-weight: 800;
}

.styled-section-header .section-title i {
    font-size: 1.3rem;
    padding-bottom: 2px;
}

/* Poster Card Styles (Trip.com style) */
.poster-card {
    position: relative;
    border-radius: 12px;
    overflow: hidden;
    aspect-ratio: 3/4;
    background-color: #f0f0f0;
    cursor: pointer;
    transition: transform 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.poster-card:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
}

.poster-card::after {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 12px;
    box-shadow: inset 0 0 0 2px rgba(255, 255, 255, 0.2);
    opacity: 0;
    transition: opacity 0.3s;
    pointer-events: none;
}

.poster-card:hover::after {
    opacity: 1;
}

.poster-card-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

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

.poster-card-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 80px 16px 16px 16px;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.8) 0%, rgba(0, 0, 0, 0.4) 60%, rgba(0, 0, 0, 0) 100%);
    color: white;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    pointer-events: none;
}

.poster-card-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    background: rgba(255, 255, 255, 0.95);
    color: #333;
    font-size: 0.75rem;
    font-weight: 700;
    padding: 4px 8px;
    border-radius: 4px;
    z-index: 2;
    display: flex;
    align-items: center;
    gap: 4px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.poster-card-badge i {
    color: var(--color-primary);
}

.poster-card-like {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 32px;
    height: 32px;
    background: rgba(255, 255, 255, 0.9);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #333;
    z-index: 2;
    cursor: pointer;
    transition: all 0.2s;
}

.poster-card-like:hover {
    background: white;
    transform: scale(1.1);
}

.poster-card-title {
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 4px;
    line-height: 1.3;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.poster-card-info {
    font-size: 0.85rem;
    opacity: 0.9;
    display: flex;
    align-items: center;
    gap: 6px;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

/* Swiper Tweaks */
.swiper-container-padding {
    padding: 10px 4px 40px 4px !important;
}

.custom-swiper-button {
    width: 40px;
    height: 40px;
    background: white;
    border-radius: 50%;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    color: #333;
}

.custom-swiper-button::after {
    font-size: 1rem;
}

/* Section Spacing */
.section {
    padding: 2rem 0;
}

/* Home Specific Section Spacing (Reduced Top) */
.home-section {
    padding-top: 0;
    padding-bottom: 20px;
}

/* News Section (Horizontal Cards) */
.news-card {
    display: flex;
    background: white;
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid var(--color-border);
    height: 100%;
    transition: all 0.3s;
}

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

.news-card-img {
    width: 120px;
    height: 100%;
    object-fit: cover;
    flex-shrink: 0;
}

.news-card-body {
    padding: 16px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.news-card-title {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 8px;
    color: var(--color-text);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.news-card-date {
    font-size: 0.8rem;
    color: var(--color-text-muted);
}

/* Landscape Card Styles (News Section) */
.landscape-card {
    position: relative;
    border-radius: 12px;
    overflow: hidden;
    aspect-ratio: 4/3;
    background-color: #f0f0f0;
    cursor: pointer;
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275), box-shadow 0.4s ease;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.landscape-card:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
}

.landscape-card-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

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

.landscape-card-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 60px 16px 16px 16px;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.8) 0%, rgba(0, 0, 0, 0.4) 60%, rgba(0, 0, 0, 0) 100%);
    color: white;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    pointer-events: none;
}

.landscape-card-title {
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 4px;
    line-height: 1.3;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Override main wrapper padding for Home Page to reduce top spacing */
.main-wrapper>.section {
    padding-top: 0px !important;
    /* Removed padding to fit banner */
    padding-bottom: 20px !important;
}

/* Ensure vertical stacking */
.home-page-wrapper {
    display: block;
    width: 100%;
}

/* Critical Banner Styles (Fallback) */
.top-banner-section {
    width: 100%;
    height: 130px;
    background-image: url('/images/banner_urban.png');
    background-size: cover;
    background-position: center;
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    margin-bottom: 2rem;
    background-color: #667eea;
    /* Fallback color */
}

.top-banner-section::before {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.4);
    z-index: 1;
}

.top-banner-content {
    text-align: center;
    color: white;
    z-index: 2;
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.top-banner-title {
    font-size: 2.2rem;
    font-weight: 800;
    margin: 0;
    letter-spacing: -0.5px;
    text-transform: uppercase;
    background: linear-gradient(to right, #fff, #e0e0e0);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    color: white;
    /* Fallback */
}

.top-banner-subtitle {
    font-size: 1.1rem;
    opacity: 1;
    margin-top: 0.2rem;
    font-weight: 500;
    text-shadow: 0 1px 4px rgba(0, 0, 0, 0.5);
    color: #f8f9fa;
}

@media (max-width: 768px) {
    .main-wrapper>.section {
        padding-top: 0px !important;
    }

    .top-banner-title {
        font-size: 1.2rem;
    }
}

/* Rolling Banner Styles */
.swiper-banner {
    width: 100%;
    height: 150px;
    /* Match existing banner height */
    overflow: hidden;
}

.banner-content-wrapper {
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    position: relative;
}

/* Add overlay for better text readability on bright images */
.banner-content-wrapper::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.3);
    /* Slight dark overlay */
    z-index: 1;
}

.banner-content-wrapper .top-banner-content {
    position: relative;
    z-index: 2;
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

/* Hide navigation buttons for the banner swiper specifically */
.swiper-banner .swiper-button-next,
.swiper-banner .swiper-button-prev {
    display: none !important;
}

/* Mobile Stacked Layout (Disable Swiper Visuals) */
@media (max-width: 767px) {

    /* Target specific swipers to stack */
    .swiper-festival .swiper-wrapper,
    .swiper-concert .swiper-wrapper,
    .swiper-news .swiper-wrapper {
        flex-direction: column !important;
        gap: 16px !important;
        transform: none !important;
        box-sizing: border-box !important;
    }

    .swiper-festival .swiper-slide,
    .swiper-concert .swiper-slide,
    .swiper-news .swiper-slide {
        width: 100% !important;
        margin-right: 0 !important;
        /* Increase card size/touch area if needed, but 100% width handles it */
    }

    /* Hide navigation buttons on mobile for these sections */
    .swiper-festival .swiper-button-next,
    .swiper-festival .swiper-button-prev,
    .swiper-concert .swiper-button-next,
    .swiper-concert .swiper-button-prev,
    .swiper-news .swiper-button-next,
    .swiper-news .swiper-button-prev {
        display: none !important;
    }

    /* Ensure padding is consistent */
    .swiper-container-padding {
        padding: 0 0 20px 0 !important;
    }

    /* Mobile Adjustments */
    .styled-section-header {
        margin-bottom: 0.5rem;
    }
}