/* --- BIẾN VÀ CẤU HÌNH CHUNG --- */
:root {
    --bg-base: #0b1325;
    --bg-card: #152036;
    --bg-border: #1e2c48;
    --bg-dark: #050a14;
    --color-gold: #d4af37;
    --color-gold-light: #f3e5ab;
    --text-main: #e2e8f0;
    --text-muted: #94a3b8;
    
    --font-serif: "Playfair Display", serif;
    --font-body: "Lora", serif;
    --font-sans: "Inter", sans-serif;
}

* {
    box-sizing: border-box;
}

body {
    background-color: var(--bg-base);
    color: var(--text-main);
    font-family: var(--font-body);
    margin: 0;
    margin-top: 45px;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

img {
    max-width: 100%;
    display: block;
    height: auto;
}

::selection {
    background: var(--color-gold);
    color: var(--bg-base);
}

/* --- HEADER SOHA NAV --- */
.sp-sticky-header {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    width: 100%;
    height: 45px !important;
    background-color: #000 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    z-index: 99999 !important;
    box-shadow: 0 2px 5px rgba(0,0,0,0.5) !important;
    font-family: Arial, sans-serif !important;
}

.left-group, .right-group {
    display: flex;
    align-items: center;
    height: 100%;
}

.sp-back-to-soha-new {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 45px;
    height: 45px;
    background-color: #007f74;
    color: white;
    cursor: pointer;
    transition: all 0.3s ease;
}

.sp-back-to-soha-new:hover { background-color: #00665d; }
.emg-icon-svg { fill: currentColor; width: 20px; height: 20px; }
.sp-mag-logo-new { margin-left: 15px; display: flex; align-items: center; }
.sp-mag-logo-new img { height: 24px; width: auto; }

.center-logo {
    position: absolute; left: 50%; transform: translateX(-50%);
    pointer-events: none; user-select: none;
    display: flex; align-items: center; justify-content: center;
}
.center-logo img { height: 26px; width: auto; }

.mobile-emag-logo { display: none; height: 24px; width: auto; margin-right: 15px; }
.fb-custom-btn {
    display: flex; align-items: center; gap: 6px; color: white;
    font-size: 13px; font-weight: bold; cursor: pointer; opacity: 0.9;
    margin-right: 15px; transition: all 0.3s ease; text-decoration: none;
}
.fb-custom-btn:hover { opacity: 1; text-decoration: underline; }

@media (max-width: 768px) {
    .center-logo, .fb-custom-btn { display: none !important; }
    .mobile-emag-logo { display: block !important; }
}

/* --- PROGRESS BAR --- */
#progress-bar {
    position: fixed; top: 45px; left: 0; height: 4px;
    background: linear-gradient(90deg, #d4af37, #fff6d9);
    width: 0%; z-index: 99998; transition: width 0.1s;
}

/* --- LIGHTBOX --- */
.lightbox {
    position: fixed; inset: 0; z-index: 999999;
    background-color: rgba(11, 19, 37, 0.95);
    display: flex; items-center: center; justify-content: center;
    padding: 1rem; cursor: zoom-out;
    transition: opacity 0.3s;
}
.lightbox.hidden { display: none; }
.lightbox img {
    max-width: 100%; max-height: 90vh;
    object-fit: contain;
    box-shadow: 0 10px 40px rgba(0,0,0,0.8);
    border-radius: 0.5rem;
    pointer-events: none;
}

/* --- ANIMATIONS --- */
.fade-in-up {
    opacity: 0; transform: translateY(40px);
    transition: opacity 1.2s cubic-bezier(0.16, 1, 0.3, 1), transform 1.2s cubic-bezier(0.16, 1, 0.3, 1);
}
.fade-in-up.visible { opacity: 1; transform: translateY(0); }

@keyframes bounce {
    0%, 100% { transform: translateY(-25%); animation-timing-function: cubic-bezier(0.8,0,1,1); }
    50% { transform: translateY(0); animation-timing-function: cubic-bezier(0,0,0.2,1); }
}

/* --- COVER SECTION --- */
.cover-section {
    position: relative; width: 100%;
    display: flex; flex-direction: column;
    align-items: center; justify-content: center;
    background-color: var(--bg-dark);
}
.cover-container {
    width: 100%; max-width: 1920px;
    position: relative;
}
.cover-img { width: 100%; height: auto; object-fit: contain; }
.cover-gradient {
    position: absolute; bottom: 0; left: 0;
    width: 100%; height: 8rem;
    background: linear-gradient(to top, #0b1325, rgba(11,19,37,0.7), transparent);
    pointer-events: none;
}
@media(min-width: 768px) { .cover-gradient { height: 14rem; } }

/* --- SAPO SECTION --- */
.sapo-section {
    background-color: var(--bg-base);
    padding: 2rem 1.5rem 1rem;
    position: relative; z-index: 10;
}
.container {
    max-width: 64rem; /* ~5xl */
    margin: 0 auto;
}
.text-center { text-align: center; }
.sapo-text {
    font-size: 1.5rem; color: var(--color-gold);
    font-family: var(--font-serif); font-style: italic;
    line-height: 1.6; margin: 0;
    text-shadow: 0 1px 2px rgba(0,0,0,0.1);
}
@media(min-width: 640px) { .sapo-text { font-size: 1.875rem; } }

.scroll-indicator {
    margin-top: 2rem; margin-bottom: 0.5rem;
    display: flex; flex-direction: column;
    align-items: center; justify-content: center;
    animation: bounce 1s infinite;
}
.scroll-text {
    font-size: 0.75rem; color: var(--text-muted);
    text-transform: uppercase; letter-spacing: 0.1em;
    margin-bottom: 0.5rem;
}
.scroll-icon { width: 1.5rem; height: 1.5rem; color: var(--color-gold); }

/* --- MAIN CONTENT TYPOGRAPHY --- */
.main-content {
    position: relative; z-index: 10;
    background-color: var(--bg-base);
    padding-bottom: 2rem;
}
.article-content {
    max-width: 48rem; /* 3xl */
    margin: 0 auto;
    padding: 0 1.5rem;
    font-size: 1.15rem; line-height: 2.1;
    color: var(--text-main); font-weight: 300;
}
@media(min-width: 640px) { .article-content { font-size: 1.25rem; } }
@media(min-width: 1024px) { .article-content { padding: 0; } }

.mt-large { margin-top: 4rem; }
.mt-medium { margin-top: 2rem; }
.pb-small { padding-bottom: 1rem; }
.mb-large { margin-bottom: 3rem; }

p { margin-bottom: 2.25rem; text-align: justify; }

.section-header { margin-top: 1rem; margin-bottom: 2.5rem; text-align: center; }
.section-title {
    font-family: var(--font-serif);
    font-size: 1.875rem; color: var(--color-gold);
    font-weight: 700; letter-spacing: 0.05em;
    line-height: 1.375; text-transform: uppercase;
    text-shadow: 0 4px 8px rgba(0,0,0,0.6);
    margin: 0;
}
@media(min-width: 640px) { .section-title { font-size: 2.25rem; } }
@media(min-width: 768px) { .section-title { font-size: 2.75rem; } }

.section-divider {
    width: 5rem; height: 4px; background-color: var(--color-gold);
    margin: 2rem auto 0;
}

.drop-cap::first-letter {
    float: left; font-size: 5.5rem; line-height: 0.8;
    padding-top: 0.2rem; padding-right: 0.75rem; padding-left: 0;
    color: var(--color-gold);
    font-family: var(--font-serif); font-weight: 700;
}

.highlight-point {
    font-family: var(--font-serif);
    font-size: 1.5rem;
    color: var(--color-gold-light);
    display: block; margin-bottom: 0.5rem;
}
.text-white { color: white; font-weight: bold; }

/* --- FIGURES & ALBUMS --- */
.album-container {
    margin: 3rem auto; width: 100%; max-width: 1440px;
    padding: 0 1rem;
}
@media(min-width: 1024px) { .album-container { padding: 0 2rem; } }

.grid-layout-3 {
    display: grid; grid-template-columns: 1fr; gap: 0.75rem;
}
@media(min-width: 768px) {
    .grid-layout-3 { grid-template-columns: repeat(2, 1fr); gap: 1rem; }
}

.grid-item {
    overflow: hidden; border-radius: 0.75rem;
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
    border: 1px solid var(--bg-border);
    position: relative; background-color: black;
}
.grid-item img {
    width: 100%; height: 100%;
    object-fit: cover; transition: opacity 0.3s;
    cursor: zoom-in;
}
/* Giữ tỷ lệ khung hình */
.grid-item img { aspect-ratio: 4/3; }
@media(min-width: 640px) { .grid-item img { aspect-ratio: 16/9; } }

/* Ảnh đầu tiên của grid 3 chiếm 2 cột */
.item-main { }
@media(min-width: 768px) {
    .item-main { grid-column: span 2; }
    .item-main img { max-height: 75vh; width: 100%; height: auto; aspect-ratio: auto; }
}

.grid-layout-2x2 {
    display: grid; grid-template-columns: 1fr; gap: 0.75rem;
}
@media(min-width: 768px) {
    .grid-layout-2x2 { grid-template-columns: repeat(2, 1fr); gap: 1rem; }
}

.img-zoomable:hover { opacity: 0.9; }

.caption {
    text-align: center; font-size: 0.875rem;
    color: var(--text-muted); margin-top: 1.25rem;
    font-style: italic; font-family: var(--font-serif);
}
@media(min-width: 640px) { .caption { font-size: 1rem; } }

/* --- FULL WIDTH IMAGE BLOCKS --- */
.full-width-image-container {
    width: 100%; position: relative;
    margin: 2.5rem 0;
    background-color: var(--bg-dark);
    display: flex; flex-direction: column;
    align-items: center; justify-content: center;
}
.max-width-wrapper {
    max-width: 1920px; width: 100%;
}
.block-img {
    width: 100%; height: auto;
    object-fit: contain;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    border-top: 1px solid var(--bg-border);
    border-bottom: 1px solid var(--bg-border);
}
.block-img-tall { max-height: 90vh; }

/* --- STANDARD CENTERED FIGURE --- */
.standard-figure {
    width: 100%; max-width: 980px;
    margin: 3rem auto; padding: 0 1rem;
}
@media(min-width: 1024px) { .standard-figure { padding: 0; } }

.rounded-img {
    border-radius: 0.75rem;
    box-shadow: 0 20px 50px rgba(0,0,0,0.5);
    border: 1px solid var(--bg-border);
}
.relative-container {
    position: relative; width: 100%; overflow: hidden;
}

/* --- QUOTE BLOCK --- */
.quote-block {
    margin: 3rem auto; padding: 2.5rem 1.5rem;
    width: 100%; max-width: 980px;
    position: relative;
}
@media(min-width: 640px) { .quote-block { padding: 2.5rem 4rem; } }

.quote-bg {
    position: absolute; inset: 0;
    background-color: rgba(21, 32, 54, 0.6);
    border-radius: 1.5rem;
    border: 1px solid rgba(212, 175, 55, 0.2);
    transform: skewX(-2deg);
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    margin: 0 1rem;
}
@media(min-width: 640px) { .quote-bg { margin: 0; } }

.quote-mark-start, .quote-mark-end {
    position: absolute;
    font-size: 6rem;
    font-family: var(--font-serif);
    color: var(--color-gold); opacity: 0.1;
    line-height: 1; pointer-events: none;
}
@media(min-width: 640px) {
    .quote-mark-start, .quote-mark-end { font-size: 8rem; }
}

.quote-mark-start { top: 0; left: 2rem; }
.quote-mark-end { bottom: 0; right: 2rem; transform: rotate(180deg); }

.quote-content, .quote-content-small {
    position: relative; z-index: 10;
    font-family: var(--font-serif);
    color: var(--color-gold-light);
    font-style: italic; text-align: center;
    text-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    margin: 0; padding: 0 0.5rem;
}
.quote-content { font-size: 1.5rem; line-height: 1.625; }
.quote-content-small { font-size: 1.25rem; line-height: 1.625; }

@media(min-width: 640px) {
    .quote-content { font-size: 1.875rem; padding: 0 2rem; }
    .quote-content-small { font-size: 1.5rem; padding: 0 2rem; }
}

/* --- SLIDER (BẢN ĐỒ) --- */
.slider-container {
    width: 100%; position: relative;
    margin: 3rem 0; padding: 2.5rem 0;
    background-color: var(--bg-base);
    display: flex; flex-direction: column;
    align-items: center; border-top: 1px solid var(--bg-border);
    border-bottom: 1px solid var(--bg-border);
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    overflow: hidden;
}
.slider-track {
    display: flex; overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-behavior: smooth;
    position: relative; z-index: 0;
    /* Hide scrollbar */
    -ms-overflow-style: none; scrollbar-width: none;
}
.slider-track::-webkit-scrollbar { display: none; }

.slider-img {
    width: 100%; height: 60vh;
    flex-shrink: 0; scroll-snap-align: center;
    object-fit: contain; background: transparent;
}
@media(min-width: 768px) { .slider-img { height: 85vh; } }

.nav-btn {
    position: absolute; top: 50%; transform: translateY(-50%);
    background-color: rgba(0,0,0,0.7);
    color: white; border: none;
    padding: 0.75rem; border-radius: 9999px;
    opacity: 0.8; z-index: 20; cursor: pointer;
    transition: all 0.3s;
    box-shadow: 0 0 20px rgba(0,0,0,0.8);
}
@media(min-width: 768px) {
    .nav-btn { padding: 1rem; opacity: 0; }
    .slider-container:hover .nav-btn { opacity: 1; }
}
.nav-btn:hover { background-color: var(--color-gold); color: black; }
.nav-prev { left: 0.5rem; }
.nav-next { right: 0.5rem; }
@media(min-width: 768px) {
    .nav-prev { left: 2rem; }
    .nav-next { right: 2rem; }
}
.icon-nav { width: 1.5rem; height: 1.5rem; }
@media(min-width: 768px) { .icon-nav { width: 2rem; height: 2rem; } }

/* --- MAP STYLES --- */
.map-wrapper {
    position: relative; width: 100%; max-width: 1920px;
    margin: 3rem auto; height: 75vh;
    border-top: 1px solid var(--bg-border);
    border-bottom: 1px solid var(--bg-border);
    background-color: #f3f4f6; overflow: hidden;
    box-shadow: 0 20px 50px rgba(0,0,0,0.6);
    font-family: var(--font-sans);
}
@media(min-width: 768px) { .map-wrapper { height: 85vh; } }

#map { height: 100%; width: 100%; z-index: 1; }
.ui-layer { z-index: 1000; pointer-events: none; position: absolute; }
.pointer-events-auto { pointer-events: auto; }

.map-header-container {
    top: 0; left: 0; width: 100%; padding: 1rem;
    display: flex; justify-content: space-between; align-items: flex-start;
}
@media(min-width: 768px) { .map-header-container { padding: 1.5rem; } }

.map-card {
    background-color: rgba(255,255,255,0.95);
    backdrop-filter: blur(4px);
    border-radius: 1rem;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    padding: 1rem; border: 1px solid rgba(255,255,255,0.2);
    max-width: 24rem;
}
@media(min-width: 768px) { .map-card { padding: 1.25rem; } }

.map-title {
    font-size: 1.25rem; font-weight: 700; color: #1f2937;
    line-height: 1.25; margin: 0;
}
@media(min-width: 768px) { .map-title { font-size: 1.5rem; } }

.map-legend { margin-top: 1rem; display: flex; flex-direction: column; gap: 0.5rem; }
.legend-dot {
    width: 1rem; height: 1rem; border-radius: 50%;
    background-color: #ef4444; border: 2px solid white;
    box-shadow: 0 0 5px rgba(239,68,68,0.8);
    display: inline-block; vertical-align: middle; margin-right: 0.5rem;
}
.legend-text { font-size: 0.875rem; font-weight: 500; color: #374151; }
.map-note { margin-top: 1rem; font-size: 0.75rem; color: #9ca3af; font-style: italic; }

/* Panel Info */
.panel-container {
    top: 0; right: 0; height: 100%; width: 100%;
    padding: 1rem;
    display: flex; align-items: center; justify-content: center;
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.3s ease;
}
@media(min-width: 768px) {
    .panel-container { width: 24rem; justify-content: flex-end; padding: 1.5rem; }
}

.panel-hidden { transform: translateX(120%); opacity: 0; }

.panel-content {
    background-color: white; width: 100%; max-height: 90vh;
    border-radius: 1.5rem;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    overflow-y: auto;
    display: flex; flex-direction: column;
    position: relative; border: 1px solid #f3f4f6;
}

.panel-close-btn {
    position: absolute; top: 1rem; right: 1rem; z-index: 10;
    background-color: rgba(255,255,255,0.8);
    backdrop-filter: blur(4px);
    color: #1f2937;
    border: none; padding: 0.5rem;
    border-radius: 9999px; box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1);
    cursor: pointer; transition: background 0.2s;
}
.panel-close-btn:hover { background-color: #f3f4f6; }

.panel-image-wrapper {
    position: relative; height: 14rem; width: 100%;
    background-color: #e5e7eb; flex-shrink: 0;
}
.panel-img {
    width: 100%; height: 100%; object-fit: cover;
    border-top-left-radius: 1.5rem; border-top-right-radius: 1.5rem;
}
.panel-overlay {
    position: absolute; bottom: 0; left: 0; width: 100%; height: 50%;
    background: linear-gradient(to top, rgba(0,0,0,0.6), transparent);
}
.panel-badge {
    position: absolute; bottom: 1rem; left: 1rem;
    padding: 0.25rem 0.75rem;
    border-radius: 9999px; font-size: 0.75rem; font-weight: 700;
    color: white; border: 1px solid rgba(255,255,255,0.2);
    background-color: rgba(239, 68, 68, 0.9);
    backdrop-filter: blur(4px); box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
}

.panel-text-area {
    padding: 1.5rem; flex: 1; display: flex; flex-direction: column; gap: 1rem;
}
.panel-heading {
    font-size: 1.5rem; font-weight: 700; color: #111827;
    line-height: 1.25; margin: 0;
}
.panel-sub-info {
    display: flex; align-items: center; gap: 0.5rem;
    margin-top: 0.5rem; color: #6b7280; font-size: 0.875rem;
}
.panel-divider { width: 100%; height: 1px; background-color: #f3f4f6; }
.panel-desc { color: #4b5563; font-size: 0.875rem; leading-relaxed; }

.hotspot-main {
    width: 24px; height: 24px;
    background-color: #ef4444;
    border-radius: 50%; border: 3px solid white;
    box-shadow: 0 0 10px rgba(239, 68, 68, 0.8);
    animation: pulse-red 2s infinite; cursor: pointer;
}

@keyframes pulse-red {
    0% { box-shadow: 0 0 0 0 rgba(239, 68, 68, 0.7); }
    70% { box-shadow: 0 0 0 15px rgba(239, 68, 68, 0); }
    100% { box-shadow: 0 0 0 0 rgba(239, 68, 68, 0); }
}

/* --- FOOTER --- */
.footer-section {
    background-color: var(--bg-base);
    padding: 2.5rem 1.5rem;
    display: flex; flex-direction: column;
    align-items: center; justify-content: center;
    border-top: 1px solid var(--bg-border);
    margin-top: 1rem; margin-left: auto; margin-right: auto;
    width: 100%;
}
@media(min-width: 768px) { .footer-section { width: 50%; } }

.footer-title {
    font-size: 1.25rem; color: var(--color-gold);
    text-transform: uppercase; letter-spacing: 0.2em;
    font-family: var(--font-serif); font-weight: 700;
    margin-bottom: 1rem; margin-top: 0;
}
@media(min-width: 640px) { .footer-title { font-size: 1.5rem; } }

.footer-info p {
    font-size: 0.875rem; color: var(--text-muted);
    font-weight: 300; text-transform: uppercase;
    letter-spacing: 0.1em; text-align: center;
    margin-bottom: 0.25rem; margin-top: 0;
}