@import url('https://fonts.googleapis.com/css2?family=Be+Vietnam+Pro:ital,wght@0,300;0,400;0,500;0,600;0,700;0,800;1,400;1,600&family=Playfair+Display:ital,wght@0,600;0,700;0,900;1,600;1,700&display=swap');

/* ==========================================================================
   DESIGN SYSTEM TOKENS & COLOR PALETTE
   ========================================================================== */
:root {
    --primary-red: #c8102e;
    --primary-red-hover: #a30b22;
    --dark-red: #8b0000;
    --gold: #d4af37;
    --gold-light: #fff9eb;
    --gold-hover: #b89726;
    --accent-gold: #e5a93b;
    
    /* BẢNG MÀU HOÀNG GIA & TRANG NHÃ (WARM IVORY, SILK & AMBER GOLD) */
    --bg-main: #fbf9f5;
    --bg-mesh: radial-gradient(circle at 20% 20%, #fffdfa 0%, #f8f4ec 55%, #ede4d4 100%);
    --bg-card: rgba(255, 255, 255, 0.94);
    --bg-card-hover: #ffffff;
    --border-glass: rgba(212, 175, 55, 0.25);
    
    --text-dark: #1f1d1d;
    --text-gray: #4a4545;
    --text-muted: #6e6767;
    --text-light: #ffffff;
    
    --shadow-soft: 0 10px 30px rgba(0, 0, 0, 0.06);
    --shadow-medium: 0 16px 36px rgba(184, 15, 10, 0.14);
    --shadow-glow: 0 0 25px rgba(212, 175, 55, 0.45);
    
    --radius-sm: 8px;
    --radius-md: 14px;
    --radius-lg: 24px;
    --radius-full: 9999px;
    
    --font-heading: 'Playfair Display', serif;
    --font-body: 'Be Vietnam Pro', 'Roboto', sans-serif;
    --transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

/* ==========================================================================
   RESET & BASE STYLES
   ========================================================================== */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
    overflow-x: hidden;
}

body {
    background: var(--bg-mesh);
    background-attachment: fixed;
    color: var(--text-dark);
    font-family: var(--font-body);
    line-height: 1.7;
    overflow-x: hidden;
    width: 100%;
    min-height: 100vh;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

a {
    color: inherit;
    text-decoration: none;
    transition: var(--transition);
}

.container {
    max-width: 1300px;
    margin: 0 auto;
    padding: 0 20px;
    width: 100%;
}

.text-center {
    text-align: center;
}

/* ==========================================================================
   PROGRESS BAR & BACK-TO-TOP BUTTON
   ========================================================================== */
#scroll-progress {
    position: fixed;
    top: 0;
    left: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--gold) 0%, var(--primary-red) 100%);
    width: 0%;
    z-index: 10001;
    transition: width 0.1s ease-out;
    box-shadow: 0 0 10px var(--gold);
}

#back-to-top {
    position: fixed;
    bottom: 25px;
    right: 25px;
    width: 48px;
    height: 48px;
    background: var(--primary-red);
    color: #ffffff;
    border: 2px solid var(--gold);
    border-radius: var(--radius-full);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 999;
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    transition: var(--transition);
    box-shadow: 0 8px 20px rgba(0,0,0,0.25);
    font-size: 20px;
    font-weight: bold;
}

#back-to-top.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

#back-to-top:hover {
    background: var(--gold);
    color: var(--primary-red);
    transform: translateY(-4px);
    box-shadow: var(--shadow-glow);
}

/* ==========================================================================
   HEADER & NAVIGATION SYSTEM
   ========================================================================== */
.main-header {
    background: var(--primary-red);
    box-shadow: 0 4px 20px rgba(0,0,0,0.18);
    position: sticky;
    top: 0;
    z-index: 1000;
    width: 100%;
}

.header-container {
    max-width: 1400px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 20px;
    gap: 15px;
}

.brand {
    display: flex;
    align-items: center;
    gap: 14px;
    text-decoration: none;
}

.logo-img {
    height: 52px;
    width: 52px;
    object-fit: cover;
    border: 2px solid var(--gold);
    background-color: #ffffff;
    border-radius: 50%;
    box-shadow: 0 0 12px rgba(255, 193, 7, 0.5);
    flex-shrink: 0;
}

.brand-title {
    color: var(--gold);
    font-size: 22px;
    font-weight: 900;
    white-space: nowrap;
    text-transform: uppercase;
    font-family: var(--font-heading);
    letter-spacing: 0.3px;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
}

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

.nav-links {
    list-style: none;
    display: flex;
    align-items: center;
    gap: 4px;
}

.nav-item {
    position: relative;
}

.nav-links li a {
    color: #ffffff;
    font-size: 14px;
    font-weight: 600;
    padding: 10px 14px;
    display: flex;
    align-items: center;
    gap: 5px;
    text-transform: uppercase;
    border-radius: var(--radius-sm);
    transition: var(--transition);
}

.nav-links li a:hover, .nav-links li a.active-link {
    color: var(--gold);
    background-color: rgba(0, 0, 0, 0.18);
}

.caret {
    font-size: 10px;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}

.search-trigger-btn {
    background: rgba(0, 0, 0, 0.18);
    border: 1px solid rgba(255, 193, 7, 0.5);
    color: #ffffff;
    padding: 8px 13px;
    border-radius: var(--radius-full);
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    font-weight: 600;
    transition: var(--transition);
    white-space: nowrap;
}

.search-trigger-btn:hover {
    background: var(--gold);
    color: var(--primary-red);
    box-shadow: var(--shadow-glow);
}

.search-shortcut-badge {
    background: rgba(0, 0, 0, 0.3);
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 10.5px;
    font-family: monospace;
}

/* DROPDOWN MENU */
.dropdown-menu {
    visibility: hidden;
    opacity: 0;
    position: absolute;
    top: 100%;
    left: 0;
    background: #ffffff;
    min-width: 330px;
    list-style: none;
    border-radius: var(--radius-md);
    box-shadow: 0 15px 35px rgba(0,0,0,0.2);
    transition: var(--transition);
    border-top: 3px solid var(--gold);
    transform: translateY(12px);
    overflow: hidden;
    z-index: 100;
}

.dropdown-menu li a {
    color: var(--text-dark) !important;
    text-transform: none;
    font-size: 14.5px;
    padding: 13px 20px;
    border-bottom: 1px solid #eeeeee;
    border-radius: 0;
}

.dropdown-menu li a:hover {
    background-color: var(--gold-light) !important;
    color: var(--primary-red) !important;
    padding-left: 25px;
}

.dropdown:hover .dropdown-menu {
    visibility: visible;
    opacity: 1;
    transform: translateY(0);
}

/* Mobile Hamburger Toggle */
.mobile-nav-toggle {
    display: none;
    background: rgba(255, 255, 255, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.3);
    color: #ffffff;
    font-size: 18px;
    cursor: pointer;
    width: 40px;
    height: 40px;
    border-radius: var(--radius-full);
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(10px);
    transition: var(--transition);
}

.mobile-nav-toggle:hover, .mobile-nav-toggle:active {
    background: var(--gold);
    color: var(--primary-red);
    border-color: var(--gold);
    transform: scale(1.05);
}

/* Mobile Drawer Navigation */
.mobile-drawer {
    position: fixed;
    top: 0;
    right: -100%;
    width: 300px;
    max-width: 85vw;
    height: 100vh;
    background: rgba(255, 255, 255, 0.96);
    backdrop-filter: blur(25px);
    -webkit-backdrop-filter: blur(25px);
    z-index: 10002;
    padding: 25px 20px;
    transition: right 0.35s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: -15px 0 35px rgba(0, 0, 0, 0.2);
    border-left: 3px solid var(--gold);
    overflow-y: auto;
}

.mobile-drawer.open {
    right: 0;
}

.mobile-drawer-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
    padding-bottom: 15px;
    border-bottom: 2px solid rgba(218, 37, 29, 0.15);
}

.mobile-drawer-title {
    color: var(--primary-red);
    font-family: var(--font-heading);
    font-size: 18px;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 8px;
}

.mobile-drawer-title i {
    color: var(--gold);
    font-size: 18px;
}

.mobile-drawer-close {
    background: rgba(218, 37, 29, 0.1);
    border: none;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    font-size: 18px;
    color: var(--primary-red);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.mobile-drawer-close:hover {
    background: var(--primary-red);
    color: #ffffff;
    transform: rotate(90deg);
}

.mobile-nav-links {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.mobile-nav-links a {
    color: var(--text-dark);
    font-weight: 600;
    font-size: 15px;
    padding: 12px 16px;
    display: flex;
    align-items: center;
    gap: 12px;
    border-radius: var(--radius-md);
    background: rgba(0, 0, 0, 0.02);
    border: 1px solid rgba(0, 0, 0, 0.04);
    transition: var(--transition);
}

.mobile-nav-links a i {
    width: 22px;
    text-align: center;
    color: var(--primary-red);
    font-size: 16px;
    transition: var(--transition);
}

.mobile-nav-links a:hover,
.mobile-nav-links a.active {
    background: linear-gradient(135deg, rgba(218, 37, 29, 0.08) 0%, rgba(255, 193, 7, 0.15) 100%);
    color: var(--primary-red);
    border-left: 4px solid var(--primary-red);
    padding-left: 20px;
    box-shadow: 0 4px 12px rgba(218, 37, 29, 0.08);
}

.mobile-nav-links a:hover i,
.mobile-nav-links a.active i {
    color: var(--primary-red);
    transform: scale(1.15);
}

.drawer-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0,0,0,0.6);
    backdrop-filter: blur(4px);
    z-index: 10001;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
}

.drawer-backdrop.show {
    opacity: 1;
    visibility: visible;
}

/* ==========================================================================
   HERO BANNER (GIỮ NGUYÊN 100% ẢNH BÁC HỒ RÕ NÉT - KHÔNG HỘP MỜ CHE ẢNH)
   ========================================================================== */
.banner {
    position: relative;
    height: 85vh;
    min-height: 600px;
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
    background: url('../images/anh_bacho.png') no-repeat center center;
    background-size: cover;
    border-radius: var(--radius-lg);
    margin: 20px auto;
    max-width: 1350px;
    box-shadow: 0 15px 40px rgba(0,0,0,0.2);
    overflow: hidden;
    width: calc(100% - 30px);
}

.particles-layer {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
    pointer-events: none;
}

/* CHỮ TRỰC TIẾP TRÊN NỀN ẢNH BÁC HỒ - KHÔNG HỘP MỜ DÙNG CHO BANNER */
.banner-text-wrapper {
    position: relative;
    z-index: 10;
    width: 100%;
    max-width: 850px;
    margin: 0 auto;
    padding: 20px;
    background: transparent;
}

.hero-title {
    color: var(--primary-red);
    font-size: 42px;
    line-height: 1.4;
    font-family: var(--font-heading);
    font-weight: 900;
    text-shadow: 2px 2px 4px rgba(255,255,255,0.9), -1px -1px 0 rgba(255, 255, 255, 0.8);
    margin-bottom: 15px;
}

.hero-subtitle {
    color: var(--text-dark);
    font-size: 22px;
    font-weight: 700;
    min-height: 38px;
    text-shadow: 1px 1px 2px rgba(255,255,255,0.9);
    margin-bottom: 25px;
}

.btn-primary {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 13px 34px;
    background: var(--primary-red);
    color: #ffffff;
    font-weight: 700;
    font-size: 15px;
    border-radius: var(--radius-full);
    text-transform: uppercase;
    border: 2px solid var(--primary-red);
    box-shadow: 0 6px 20px rgba(218, 37, 29, 0.35);
    cursor: pointer;
    transition: var(--transition);
}

.btn-primary:hover {
    background: #ffffff;
    color: var(--primary-red);
    transform: translateY(-3px);
    box-shadow: var(--shadow-medium);
}

/* ==========================================================================
   SECTIONS & TYPOGRAPHY
   ========================================================================== */
.section {
    padding: 75px 0;
    position: relative;
}

.bg-alt {
    background: rgba(255, 255, 255, 0.45);
    backdrop-filter: blur(8px);
}

.section-title {
    font-family: var(--font-heading);
    font-size: 34px;
    color: var(--primary-red);
    margin-bottom: 10px;
    font-weight: 900;
    text-transform: uppercase;
    text-shadow: 1px 1px 2px rgba(255,255,255,0.8);
}

.title-line {
    width: 80px;
    height: 4px;
    background: var(--primary-red);
    margin-bottom: 40px;
    border-radius: var(--radius-full);
}

.center-line {
    margin: 0 auto 40px auto;
}

/* ==========================================================================
   QUOTES SECTION
   ========================================================================== */
.quote-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 25px;
}

.quote-card {
    background: var(--bg-card);
    backdrop-filter: blur(10px);
    padding: 32px 28px;
    border-left: 6px solid var(--primary-red);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-soft);
    font-style: italic;
    font-size: 17px;
    color: var(--primary-red);
    font-family: var(--font-heading);
    line-height: 1.65;
    position: relative;
    transition: var(--transition);
    border-top: 1px solid var(--border-glass);
    border-right: 1px solid var(--border-glass);
    border-bottom: 1px solid var(--border-glass);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    overflow: hidden;
}

.quote-card::before {
    content: "“";
    position: absolute;
    top: 5px;
    right: 18px;
    font-size: 88px;
    line-height: 1;
    color: rgba(212, 175, 55, 0.16);
    font-family: var(--font-heading);
    pointer-events: none;
}

.quote-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-medium);
    border-color: rgba(212, 175, 55, 0.5);
}

.quote-author {
    display: block;
    margin-top: 18px;
    font-size: 13.5px;
    font-style: normal;
    color: var(--text-gray);
    font-weight: 700;
    font-family: var(--font-body);
}

/* ==========================================================================
   TIMELINE SECTION
   ========================================================================== */
.timeline-section {
    background: linear-gradient(160deg, #9e1410 0%, #7d0e0a 50%, #5c0704 100%) !important;
    color: #ffffff !important;
    position: relative;
    overflow: hidden;
    box-shadow: inset 0 8px 24px rgba(0,0,0,0.25), inset 0 -8px 24px rgba(0,0,0,0.25);
}

.timeline-filter-nav {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 35px;
}

.timeline-tab {
    padding: 7px 16px;
    background: rgba(255, 255, 255, 0.18);
    border: 1px solid var(--gold);
    color: #ffffff;
    border-radius: var(--radius-full);
    font-weight: 600;
    font-size: 13.5px;
    cursor: pointer;
    transition: var(--transition);
}

.timeline-tab:hover, .timeline-tab.active {
    background: var(--gold);
    color: var(--primary-red);
    box-shadow: var(--shadow-glow);
}

.v-timeline {
    display: flex;
    flex-direction: column;
    position: relative;
    max-width: 1050px;
    margin: 0 auto;
    padding: 30px 0;
}

/* Trục dọc trung tâm cho Desktop */
.v-timeline::before {
    content: '';
    position: absolute;
    top: 0;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 4px;
    background-color: var(--gold);
    z-index: 1;
    border-radius: var(--radius-full);
}

.v-timeline-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    margin-bottom: 50px;
    position: relative;
    z-index: 2;
}

.v-timeline-item:nth-child(even) {
    flex-direction: row-reverse;
}

.text-box {
    width: 45%;
    background: #ffffff;
    padding: 24px 28px;
    border-radius: var(--radius-md);
    box-shadow: 0 5px 20px rgba(0,0,0,0.15);
    border-top: 4px solid var(--gold);
    color: var(--text-dark);
    transition: var(--transition);
}

.v-timeline-date {
    color: var(--primary-red);
    font-size: 24px;
    font-weight: 900;
    margin-bottom: 6px;
    font-family: var(--font-heading);
}

.image-box {
    width: 45%;
    background: #ffffff;
    padding: 10px;
    border-radius: var(--radius-md);
    box-shadow: 0 5px 20px rgba(0,0,0,0.15);
    border: 1px solid #e4dccb;
    cursor: pointer;
}

.image-box img {
    width: 100%;
    height: 220px;
    object-fit: cover;
    display: block;
    border-radius: var(--radius-sm);
}

.v-timeline-dot {
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    width: 28px;
    height: 28px;
    background-color: var(--gold);
    border: 5px solid #ffffff;
    border-radius: 50%;
    box-shadow: 0 0 0 4px var(--primary-red);
    z-index: 3;
    transition: var(--transition);
    cursor: pointer;
}

.v-timeline-dot:hover {
    transform: translate(-50%, -50%) scale(1.3);
    background-color: var(--primary-red);
    box-shadow: 0 0 15px 5px var(--gold);
    border-color: var(--gold);
}

/* ==========================================================================
   WORKS CARDS & ONLINE BOOKS
   ========================================================================== */
.cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 25px;
}

.work-card {
    background: var(--bg-card);
    backdrop-filter: blur(10px);
    border: 1px solid var(--border-glass);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-soft);
    transition: var(--transition);
    height: 100%;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.work-card:hover {
    border-color: var(--primary-red);
    transform: translateY(-6px);
    box-shadow: var(--shadow-medium);
}

.card-img {
    height: 220px;
    background-size: cover;
    background-position: center;
    border-bottom: 3px solid var(--primary-red);
}

.card-content {
    padding: 25px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.badge {
    background: var(--primary-red);
    color: #ffffff;
    padding: 5px 12px;
    font-size: 12.5px;
    font-weight: 700;
    display: inline-block;
    margin-bottom: 12px;
    width: max-content;
    border-radius: var(--radius-full);
}

.card-content h4 {
    font-family: var(--font-heading);
    font-size: 21px;
    color: var(--primary-red);
    margin-bottom: 8px;
    line-height: 1.35;
}

.card-content p {
    color: var(--text-gray);
    margin-bottom: 20px;
    font-size: 14.5px;
    flex-grow: 1;
}

.btn-text {
    color: var(--primary-red);
    font-weight: 700;
    font-size: 14px;
    text-transform: uppercase;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    margin-top: auto;
}

.btn-text:hover {
    color: var(--gold);
    transform: translateX(4px);
}

/* ==========================================================================
   SONG LIST SECTION
   ========================================================================== */
.song-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
    gap: 20px;
}

.song-card {
    display: flex;
    align-items: center;
    background: var(--bg-card);
    backdrop-filter: blur(10px);
    padding: 18px 22px;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-soft);
    transition: var(--transition);
    cursor: pointer;
    border: 1px solid var(--border-glass);
}

.song-card:hover {
    transform: translateY(-4px);
    border-color: var(--primary-red);
    box-shadow: var(--shadow-medium);
}

.play-icon {
    width: 46px;
    height: 46px;
    background: var(--primary-red);
    color: #ffffff;
    display: flex;
    justify-content: center;
    align-items: center;
    border-radius: 50%;
    margin-right: 18px;
    font-size: 16px;
    flex-shrink: 0;
    transition: var(--transition);
}

.song-card:hover .play-icon {
    background: var(--gold);
    color: var(--primary-red);
    transform: scale(1.1);
}

.song-card h4 {
    color: var(--primary-red);
    font-size: 17.5px;
    margin-bottom: 4px;
    font-family: var(--font-heading);
    font-weight: 700;
}

.song-card p {
    color: var(--text-gray);
    font-size: 13.5px;
    margin: 0;
}

/* ==========================================================================
   PHOTO GALLERY
   ========================================================================== */
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

@media (max-width: 992px) {
    .gallery-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 576px) {
    .gallery-grid {
        grid-template-columns: 1fr;
    }
}

.gallery-item {
    height: 250px;
    background-size: cover;
    background-position: center;
    border: 4px solid #ffffff;
    border-radius: var(--radius-md);
    transition: var(--transition);
    cursor: pointer;
    box-shadow: var(--shadow-soft);
    position: relative;
    overflow: hidden;
}

.gallery-item::after {
    content: '🔍 Phóng to';
    position: absolute;
    inset: 0;
    background: rgba(218, 37, 29, 0.75);
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 15px;
    opacity: 0;
    transition: var(--transition);
}

.gallery-item:hover::after {
    opacity: 1;
}

.gallery-item:hover {
    transform: scale(1.04);
    box-shadow: var(--shadow-medium);
    border-color: var(--primary-red);
}

/* ==========================================================================
   FOOTER
   ========================================================================== */
.main-footer {
    padding: 50px 20px 0 20px;
    background-color: var(--primary-red);
    color: #ffffff;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 40px;
    margin-bottom: 40px;
    max-width: 1250px;
    margin: 0 auto 40px auto;
}

.footer-col h4 {
    color: var(--gold);
    font-size: 18px;
    font-family: var(--font-heading);
    margin-bottom: 20px;
    text-transform: uppercase;
}

.footer-col p, .footer-col ul li a {
    color: #fdfdfd;
    font-size: 14.5px;
    line-height: 2.1;
}

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

.footer-col ul li a:hover {
    color: var(--gold);
    text-decoration: underline;
}

.footer-bottom {
    text-align: center;
    padding: 22px;
    background-color: var(--dark-red);
    color: #ffffff;
    font-size: 14px;
    margin: 0 -20px;
}

/* ==========================================================================
   MODALS
   ========================================================================== */
.modal-overlay {
    display: none;
    position: fixed;
    z-index: 99999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.75);
    backdrop-filter: blur(8px);
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
    padding: 15px;
}

.modal-overlay.show {
    display: flex;
    opacity: 1;
}

.modal-content {
    background: #ffffff;
    width: 95%;
    max-width: 800px;
    max-height: 90vh;
    border-radius: var(--radius-lg);
    padding: 35px;
    position: relative;
    box-shadow: 0 20px 60px rgba(0,0,0,0.4);
    transform: translateY(-30px);
    transition: transform 0.3s ease;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.modal-overlay.show .modal-content {
    transform: translateY(0);
}

.close-modal {
    position: absolute;
    top: 15px;
    right: 20px;
    color: var(--text-gray);
    font-size: 32px;
    font-weight: 700;
    cursor: pointer;
    transition: var(--transition);
    line-height: 1;
}

.close-modal:hover {
    color: var(--primary-red);
}

.player-header {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 15px;
}

.vinyl-disc {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: radial-gradient(circle, #333 20%, #111 60%, #444 100%);
    border: 2px solid var(--gold);
    animation: spinVinyl 8s linear infinite;
    flex-shrink: 0;
}

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

.player-controls-nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 15px;
    gap: 10px;
}

.player-btn {
    padding: 8px 16px;
    background: var(--primary-red);
    color: #ffffff;
    border: none;
    border-radius: var(--radius-full);
    cursor: pointer;
    font-weight: 600;
    font-size: 13px;
    transition: var(--transition);
}

.player-btn:hover {
    background: var(--gold);
    color: var(--primary-red);
}

/* SEARCH PALETTE MODAL */
.search-modal-content {
    max-width: 650px;
    padding: 25px;
}

.search-input-wrapper {
    position: relative;
    margin-bottom: 18px;
}

.search-input-wrapper input {
    width: 100%;
    padding: 14px 18px 14px 45px;
    font-size: 16px;
    border: 2px solid var(--primary-red);
    border-radius: var(--radius-md);
    background: var(--bg-main);
    color: var(--text-dark);
    outline: none;
}

.search-icon-inside {
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 18px;
    color: var(--primary-red);
}

.search-results-list {
    max-height: 50vh;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.search-item-result {
    padding: 12px 16px;
    background: rgba(0,0,0,0.03);
    border-radius: var(--radius-sm);
    border-left: 4px solid var(--primary-red);
    cursor: pointer;
    transition: var(--transition);
}

.search-item-result:hover {
    background: var(--gold-light);
    transform: translateX(4px);
}

.search-item-title {
    font-weight: 700;
    color: var(--primary-red);
    font-size: 15px;
    margin-bottom: 3px;
}

.search-item-desc {
    font-size: 13px;
    color: var(--text-gray);
}

/* ==========================================================================
   PREMIUM LIGHTBOX MODAL
   ========================================================================== */
#lightbox-modal {
    background-color: rgba(10, 8, 8, 0.92);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    padding: 20px;
}

.lightbox-dialog {
    position: relative;
    max-width: 900px;
    width: 95%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    outline: none;
    margin: auto;
    transform: scale(0.94);
    transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

.modal-overlay.show .lightbox-dialog {
    transform: scale(1);
}

.lightbox-figure {
    position: relative;
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    max-width: 100%;
}

.lightbox-img-wrapper {
    position: relative;
    border-radius: 16px;
    background: #000000;
    border: 2px solid rgba(212, 175, 55, 0.45);
    box-shadow: 0 25px 80px rgba(0, 0, 0, 0.95), 0 0 40px rgba(0, 0, 0, 0.8);
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 250px;
}

.lightbox-img {
    display: block;
    max-width: 86vw;
    max-height: 72vh;
    min-width: 340px;
    width: auto;
    height: auto;
    object-fit: contain;
    border-radius: 14px;
    transition: opacity 0.25s ease;
}

.lightbox-close-btn {
    position: absolute;
    top: -16px;
    right: -16px;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--primary-red);
    color: #ffffff;
    border: 2px solid #ffffff;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    cursor: pointer;
    transition: var(--transition);
    z-index: 100;
}

.lightbox-close-btn:hover {
    background: var(--gold);
    color: #1f1d1d;
    transform: scale(1.1) rotate(90deg);
}

.lightbox-nav-btn {
    position: fixed;
    top: 50%;
    transform: translateY(-50%);
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: rgba(30, 20, 20, 0.82);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    color: #ffffff;
    border: 2px solid rgba(212, 175, 55, 0.6);
    font-size: 22px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition);
    z-index: 95;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.6);
}

.lightbox-nav-btn:hover {
    background: var(--primary-red);
    border-color: #ffffff;
    transform: translateY(-50%) scale(1.12);
}

.lightbox-prev {
    left: 30px;
}

.lightbox-next {
    right: 30px;
}

.lightbox-caption-wrapper {
    margin-top: 18px;
    text-align: center;
    max-width: 800px;
    padding: 0 15px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}

.lightbox-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--gold);
    background: rgba(212, 175, 55, 0.15);
    padding: 4px 14px;
    border-radius: var(--radius-full);
    border: 1px solid rgba(212, 175, 55, 0.3);
}

.lightbox-caption-text {
    color: #ffffff;
    font-size: 16px;
    font-weight: 500;
    line-height: 1.5;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.8);
}

.lightbox-counter {
    font-size: 13px;
    color: rgba(255, 255, 255, 0.65);
    font-weight: 600;
}

@media (max-width: 992px) {
    .lightbox-prev {
        left: 12px;
        width: 46px;
        height: 46px;
        font-size: 18px;
    }
    .lightbox-next {
        right: 12px;
        width: 46px;
        height: 46px;
        font-size: 18px;
    }
}

@media (max-width: 768px) {
    .lightbox-img {
        min-width: 250px;
    }
    .lightbox-close-btn {
        top: -12px;
        right: -10px;
        width: 36px;
        height: 36px;
        font-size: 15px;
    }
    .lightbox-prev {
        left: 8px;
        width: 40px;
        height: 40px;
        font-size: 16px;
    }
    .lightbox-next {
        right: 8px;
        width: 40px;
        height: 40px;
        font-size: 16px;
    }
    .lightbox-caption-text {
        font-size: 14px;
    }
}

/* ==========================================================================
   MOBILE & TABLET RESPONSIVE FIXES
   ========================================================================== */

/* Tablet & Laptop nhỏ (Max-width: 992px) */
@media (max-width: 992px) {
    .main-nav { display: none; }
    .mobile-nav-toggle { display: flex; }
    .brand-title { font-size: 18px; }
    .logo-img { height: 44px; width: 44px; }
    .footer-grid { grid-template-columns: 1fr 1fr; gap: 30px; }

    /* FIX CẤU TRÚC TIMELINE 1 CỘT TỪ MÀN HÌNH 992PX TRỞ XUỐNG */
    .v-timeline::before { left: 20px; transform: none; width: 4px; }
    .v-timeline-item, .v-timeline-item:nth-child(even) {
        flex-direction: column !important;
        align-items: flex-start !important;
        width: 100% !important;
        margin-bottom: 35px;
        position: relative;
        padding-left: 45px;
        box-sizing: border-box !important;
    }
    .text-box, .image-box {
        width: 100% !important;
        max-width: 100% !important;
        margin: 5px 0 !important;
        box-sizing: border-box !important;
    }
    .v-timeline-dot {
        left: 20px !important;
        top: 25px !important;
        transform: translate(-50%, 0) !important;
    }
}

/* Điện thoại di động (Max-width: 768px) */
@media (max-width: 768px) {
    .header-container { padding: 10px 14px; gap: 10px; }
    .brand { gap: 10px; }
    .brand-title { font-size: 13px; white-space: normal; line-height: 1.25; font-weight: 700; }
    .logo-img { height: 38px; width: 38px; border-radius: 50%; border: 2px solid var(--gold); }
    
    .search-trigger-btn span { display: none; }
    .search-trigger-btn { padding: 0; border-radius: 50%; width: 38px; height: 38px; display: flex; align-items: center; justify-content: center; font-size: 16px; background: rgba(255,255,255,0.15); border: 1px solid rgba(255,255,255,0.3); color: #ffffff; }
    .search-shortcut-badge { display: none; }
    
    /* CAO CẤP HÓA HERO BANNER TRÊN ĐIỆN THOẠI - KHÔNG BỊ XÉN MẶT BÁC HỒ */
    .banner {
        height: auto;
        min-height: 500px;
        margin: 12px auto;
        width: calc(100% - 24px);
        border-radius: var(--radius-lg);
        background: linear-gradient(180deg, rgba(0,0,0,0.1) 0%, rgba(0,0,0,0.55) 100%), url('../images/anh_bacho.png') no-repeat center 20%;
        background-size: cover;
        display: flex;
        align-items: flex-end;
        justify-content: center;
        padding: 30px 14px 25px 14px;
        box-shadow: 0 12px 30px rgba(0,0,0,0.2);
    }
    
    /* KHUNG THẺ KÍNH MỜ SANG TRỌNG DƯỚI BỨC ẢNH BÁC HỒ */
    .banner-text-wrapper {
        padding: 22px 18px;
        width: 100%;
        max-width: 100%;
        background: rgba(255, 255, 255, 0.92);
        backdrop-filter: blur(20px);
        -webkit-backdrop-filter: blur(20px);
        border-radius: var(--radius-md);
        border: 1px solid rgba(255, 255, 255, 0.8);
        box-shadow: 0 12px 30px rgba(0, 0, 0, 0.25);
        text-align: center;
    }
    
    .hero-title {
        font-size: 21px !important;
        margin-bottom: 12px;
        line-height: 1.35;
        color: var(--primary-red) !important;
        text-shadow: none !important;
        font-weight: 900;
    }
    
    .hero-subtitle {
        font-size: 14px !important;
        min-height: 44px;
        margin-bottom: 18px;
        color: var(--text-dark) !important;
        text-shadow: none !important;
        font-weight: 600;
    }
    
    .btn-primary {
        padding: 12px 26px;
        font-size: 14px;
        font-weight: 700;
        border-radius: var(--radius-full);
        box-shadow: 0 6px 18px rgba(218, 37, 29, 0.3);
    }

    .section { padding: 45px 0; }
    .section-title { font-size: 22px !important; }
    .title-line { margin-bottom: 25px; }
    
    /* FIX TIMELINE TRÊN ĐIỆN THOẠI */
    .v-timeline { padding: 10px 0; }
    .v-timeline::before { left: 16px; transform: none; width: 3px; }
    
    .v-timeline-item, .v-timeline-item:nth-child(even) {
        padding-left: 36px !important;
        margin-bottom: 30px;
    }
    
    .v-timeline-dot {
        left: 16px !important;
        top: 20px !important;
        width: 22px !important;
        height: 22px !important;
        border-width: 3px !important;
    }
    
    .text-box {
        padding: 18px 20px !important;
        border-radius: var(--radius-md) !important;
    }

    .image-box {
        padding: 10px !important;
        border-radius: var(--radius-md) !important;
    }
    
    .v-timeline-date { font-size: 19px !important; margin-bottom: 4px; }
    .text-box p { font-size: 14px !important; line-height: 1.6; }
    .image-box img { height: 190px !important; object-fit: cover; }

    /* Chuyển tất cả Grid thành 1 cột trên Mobile */
    .quote-grid, .cards-grid, .song-list, .footer-grid { grid-template-columns: 1fr !important; gap: 18px; }
    .quote-card { padding: 22px 18px; font-size: 15px; border-left: 4px solid var(--primary-red); border-radius: var(--radius-md); }
    .gallery-grid { grid-template-columns: repeat(2, 1fr) !important; gap: 10px; }
    .gallery-item { height: 160px !important; border-radius: var(--radius-sm); }

    .footer-grid { text-align: center; }
    
    /* Fix Popup Modals trên di động */
    .modal-content { width: 94%; padding: 24px 18px; border-radius: var(--radius-lg); }
    .close-modal { top: 12px; right: 14px; font-size: 22px; width: 32px; height: 32px; display: flex; align-items: center; justify-content: center; background: rgba(0,0,0,0.06); border-radius: 50%; }
}

/* Điện thoại màn hình siêu nhỏ (Max-width: 400px) */
@media (max-width: 400px) {
    .brand-title { font-size: 12px; }
    .hero-title { font-size: 18px !important; }
    .gallery-grid { grid-template-columns: 1fr !important; }
    .banner { min-height: 460px; padding: 20px 10px 18px 10px; }
    .banner-text-wrapper { padding: 18px 14px; }
}

/* ==========================================================================
   QUICK BOOK SWITCHER TABS (DOC-SACH.HTML)
   ========================================================================== */
.book-tabs-nav {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    margin-bottom: 20px;
}

.book-tab-btn {
    background: #ffffff;
    border: 1.5px solid rgba(212, 175, 55, 0.4);
    color: var(--text-dark);
    padding: 8px 18px;
    border-radius: var(--radius-full);
    font-size: 13.5px;
    font-weight: 600;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: var(--transition);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

.book-tab-btn:hover {
    background: var(--gold-light);
    color: var(--primary-red);
    border-color: var(--gold);
    transform: translateY(-2px);
}

.book-tab-btn.active {
    background: linear-gradient(135deg, var(--primary-red) 0%, var(--primary-red-hover) 100%);
    color: #ffffff;
    border-color: var(--primary-red);
    box-shadow: 0 4px 14px rgba(200, 16, 46, 0.35);
}