/* ===== BOTTOM TAB BAR ===== */
.bottom-tab-bar {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 75px;
    background: rgba(10, 10, 10, 0.95);
    backdrop-filter: blur(20px);
    border-top: 1px solid rgba(212, 175, 55, 0.2);
    z-index: 999;
    padding: 10px 0;
    box-shadow: 0 -5px 20px rgba(0, 0, 0, 0.5);
    display: none;
}

.tab-items {
    display: flex;
    height: 100%;
    align-items: center;
    justify-content: space-around;
    padding: 0 10px;
}

.tab-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 8px 12px;
    border-radius: 12px;
    transition: all 0.3s ease;
    text-decoration: none;
    flex: 1;
    height: 100%;
    position: relative;
    overflow: hidden;
    -webkit-tap-highlight-color: transparent; /* Loại bỏ highlight màu xanh trên mobile */
}

/* Hiệu ứng hover cho desktop */
.tab-item:hover {
    background: rgba(212, 175, 55, 0.08);
    transform: translateY(-2px);
}

/* Hiệu ứng active/click cho cả desktop và mobile */
.tab-item:active {
    transform: scale(0.95);
    background: rgba(212, 175, 55, 0.15);
    transition: transform 0.1s ease;
}

/* Hiệu ứng ripple khi click (cho mobile) */
.tab-item::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(212, 175, 55, 0.2);
    transform: translate(-50%, -50%);
    transition: width 0.3s, height 0.3s;
}

.tab-item:active::after {
    width: 100px;
    height: 100px;
    opacity: 0;
    transition: width 0.3s, height 0.3s, opacity 0.3s;
}

.tab-item.active {
    background: rgba(212, 175, 55, 0.15);
    transform: translateY(-2px);
}

.tab-icon {
    font-size: 20px;
    color: var(--text-tertiary);
    transition: all 0.3s ease;
}

.tab-item.active .tab-icon,
.tab-item:hover .tab-icon {
    color: var(--champagne);
    transform: scale(1.1);
}

.tab-label {
    font-size: 11px;
    font-weight: 600;
    color: var(--text-tertiary);
    transition: all 0.3s ease;
}

.tab-item.active .tab-label,
.tab-item:hover .tab-label {
    color: var(--champagne);
}

/* Hiệu ứng pulse cho tab active */
@keyframes pulse {
    0% {
        box-shadow: 0 0 0 0 rgba(212, 175, 55, 0.4);
    }
    70% {
        box-shadow: 0 0 0 6px rgba(212, 175, 55, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(212, 175, 55, 0);
    }
}

.tab-item.active {
    animation: pulse 2s infinite;
}

/* Tối ưu cho touch devices */
@media (hover: none) and (pointer: coarse) {
    .tab-item:hover {
        background: transparent;
        transform: none;
    }
    
    .tab-item:active {
        background: rgba(212, 175, 55, 0.15);
        transform: scale(0.92);
    }
    
    /* Tăng kích thước touch target cho dễ bấm */
    .tab-item {
        min-height: 44px; /* Kích thước tối thiểu cho touch */
    }
}

/* Safe Area Support for iOS */
@supports (padding: max(0px)) {
    .bottom-tab-bar {
        padding-bottom: max(10px, env(safe-area-inset-bottom));
        height: calc(75px + env(safe-area-inset-bottom));
    }
    
    .tab-items {
        padding-bottom: env(safe-area-inset-bottom);
    }
}

/* Hiển thị trên mobile */
@media (max-width: 767px) {
    .bottom-tab-bar {
        display: block;
    }
}

/* ===== BLOG SECTION - HORIZONTAL SCROLL LIKE EXPERIENCE ===== */
.blog-section {
    padding: 40px 0;
    background: var(--primary-black);
    position: relative;
}

.blog-section .section-header {
    text-align: center;
    margin-bottom: 30px;
    padding: 0 16px;
}

.blog-section .section-title {
    font-size: 28px;
    color: var(--champagne);
    margin-bottom: 10px;
}

.blog-section .section-subtitle {
    color: var(--text-tertiary);
    font-size: 16px;
    max-width: 600px;
    margin: 0 auto;
}

/* Container cho horizontal scroll */
.blog-horizontal-container {
    width: 100%;
    overflow-x: auto;
    overflow-y: hidden;
    padding: 20px 0 40px;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    position: relative;
}

.blog-horizontal-container::-webkit-scrollbar {
    display: none;
}

/* Row chứa các card blog */
.blog-horizontal-row {
    display: inline-flex;
    gap: 20px;
    padding: 0 16px 15px;
    min-width: min-content;
}

/* Blog Card giống với Experience Card */
.blog-horizontal-card {
    flex: 0 0 auto;
    width: 280px;
    background: rgba(20, 20, 20, 0.8);
    border: 1px solid rgba(212, 175, 55, 0.2);
    border-radius: 16px;
    padding: 0;
    backdrop-filter: blur(10px);
    transition: all 0.4s ease;
    position: relative;
    overflow: hidden;
    cursor: pointer;
}

.blog-horizontal-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        90deg,
        transparent,
        rgba(212, 175, 55, 0.1),
        transparent
    );
    transition: left 0.7s ease;
}

.blog-horizontal-card:hover::before {
    left: 100%;
}

.blog-horizontal-card:hover {
    transform: translateY(-8px) scale(1.02);
    border-color: rgba(212, 175, 55, 0.4);
    box-shadow: 0 15px 35px rgba(212, 175, 55, 0.15);
}

/* Blog Image */
.blog-card-image {
    position: relative;
    width: 100%;
    height: 160px;
    overflow: hidden;
}

.blog-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.blog-horizontal-card:hover .blog-card-image img {
    transform: scale(1.1);
}

.blog-card-category {
    position: absolute;
    top: 15px;
    left: 15px;
    background: var(--champagne);
    color: var(--primary-black);
    padding: 5px 15px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    z-index: 2;
}

/* Blog Card Content */
.blog-card-content {
    padding: 20px;
}

.blog-card-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 12px;
    font-size: 12px;
    color: var(--text-tertiary);
}

.blog-card-author {
    display: flex;
    align-items: center;
    gap: 5px;
}

.blog-card-author i {
    color: var(--champagne);
    font-size: 10px;
}

.blog-card-title {
    font-size: 18px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 12px;
    line-height: 1.3;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    overflow: hidden;
    min-height: 46px;
}

.blog-card-excerpt {
    color: var(--text-secondary);
    font-size: 13px;
    line-height: 1.5;
    margin-bottom: 15px;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    overflow: hidden;
    min-height: 58px;
}

.blog-card-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 15px;
}

.blog-card-tag {
    background: rgba(212, 175, 55, 0.1);
    color: var(--light-champagne);
    padding: 3px 10px;
    border-radius: 15px;
    font-size: 10px;
    border: 1px solid rgba(212, 175, 55, 0.2);
}

.blog-read-more {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--champagne);
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
    padding: 8px 0;
}

.blog-read-more:hover {
    gap: 12px;
    color: var(--light-champagne);
}

.blog-read-more i {
    font-size: 10px;
}

/* Scroll hint */
.blog-scroll-hint {
    text-align: center;
    margin-top: 15px;
    color: var(--text-tertiary);
    font-size: 13px;
    animation: pulse 2s infinite;
}

.blog-scroll-hint i {
    margin-left: 8px;
    color: var(--champagne);
}

/* CTA button */
.blog-cta {
    text-align: center;
    margin-top: 30px;
}

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

/* Desktop */
@media (min-width: 1024px) {
    .blog-horizontal-row {
        justify-content: center;
        flex-wrap: wrap;
        padding: 0;
        gap: 25px;
    }
    
    .blog-horizontal-card {
        width: 260px;
    }
    
    .blog-scroll-hint {
        display: none;
    }
}

/* Tablet */
@media (min-width: 768px) and (max-width: 1023px) {
    .blog-horizontal-container {
        padding: 20px 0 30px;
    }
    
    .blog-horizontal-row {
        gap: 15px;
        padding: 0 20px;
    }
    
    .blog-horizontal-card {
        width: 240px;
    }
    
    .blog-scroll-hint {
        display: block;
    }
}

/* Mobile */
@media (max-width: 767px) {
    .blog-section {
        padding: 30px 0;
    }
    
    .blog-section .section-title {
        font-size: 22px;
    }
    
    .blog-section .section-subtitle {
        font-size: 14px;
    }
    
    .blog-horizontal-container {
        padding: 15px 0 25px;
    }
    
    .blog-horizontal-row {
        gap: 12px;
        padding: 0 12px;
    }
    
    .blog-horizontal-card {
        width: 220px;
    }
    
    .blog-card-image {
        height: 140px;
    }
    
    .blog-card-content {
        padding: 15px;
    }
    
    .blog-card-title {
        font-size: 16px;
        min-height: 42px;
    }
    
    .blog-card-excerpt {
        font-size: 12px;
        min-height: 54px;
    }
    
    .blog-scroll-hint {
        display: block;
        font-size: 12px;
    }
    
    .blog-cta .btn {
        padding: 10px 20px;
        font-size: 14px;
    }
}

/* Small Mobile */
@media (max-width: 480px) {
    .blog-horizontal-row {
        gap: 10px;
    }
    
    .blog-horizontal-card {
        width: 200px;
    }
    
    .blog-card-image {
        height: 120px;
    }
    
    .blog-card-title {
        font-size: 15px;
        min-height: 38px;
    }
    
    .blog-card-excerpt {
        font-size: 11px;
        min-height: 49px;
    }
}

/* Blog loading state */
.loading-blog {
    grid-column: 1 / -1;
    text-align: center;
    padding: 60px;
    color: var(--text-tertiary);
    min-width: 300px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.loading-blog i {
    font-size: 32px;
    margin-bottom: 15px;
    color: var(--champagne);
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}
