/* Font Face Declarations */
@font-face {
    font-family: 'DFVN TAN - KINDRED';
    src: url('fonts/DFVN TAN - KINDRED.otf') format('opentype'),
         url('fonts/DFVN TAN - KINDRED.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}

/* Reset and base styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', sans-serif;
    line-height: 1.6;
    color: #fff;
    overflow-x: hidden;
    background: linear-gradient(135deg, #1a4d3a 0%, #2d5016 50%, #8B4513 100%);
    min-height: 100vh;
    position: relative;
}

/* Background styling */
.background-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('backgrnew.png') center/cover no-repeat;
    z-index: -2;
}

.background-overlay::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        135deg,
        rgba(26, 77, 58, 0.8) 0%,
        rgba(45, 80, 22, 0.7) 50%,
        rgba(139, 69, 19, 0.6) 100%
    );
    z-index: -1;
}

/* Container */
.container {
    margin: 0 auto;
    padding: 0 20px;
    position: relative;
    z-index: 1;
}

/* Header Section */
.header {
    text-align: center;
    padding: 40px 0 30px;
    position: relative;
}

.header-content {
    position: relative;
    z-index: 2;
}

.main-title {
    font-family: "Dancing Script", "Dancing Script Fallback", cursive;
    font-weight: 700; /* Adjusted for Dancing Script */
    line-height: 1.1;
    margin-bottom: 20px;
    text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.7); /* Deeper shadow */
    letter-spacing: 1px; /* Adjusted for style */
    font-style: italic;
    font-size: 48px;

}

.title-line {
    display: block;
    background: linear-gradient(45deg, #FFD700, #FFA500, #FF6347);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.title-line:first-child {
    font-style: italic;
    animation: titleGlow 3s ease-in-out infinite alternate;
}

.highlight {
    font-size: 1em;
    font-weight: 800;
    text-shadow: 0 0 20px rgba(255, 215, 0, 0.5);
    letter-spacing: 2px;
}

.subtitle {
    font-size: 1.2rem;
    color: #E6E6FA;
    font-weight: 300;
    max-width: 600px;
    margin: 0 auto;
    opacity: 0.9;
}

/* Main Content - Poster Section */
.main-content {
    padding: 20px 0;
    display: flex;
    justify-content: center;
}

.poster-container {
    position: relative;
    width: 100%;
    max-width: 700px;
    margin: 0 auto;
}

.poster-frame {
    background: linear-gradient(145deg, #8B4513, #A0522D);
    padding: 20px;
    border-radius: 20px;
    box-shadow:
        0 20px 40px rgba(0, 0, 0, 0.3),
        inset 0 2px 4px rgba(255, 255, 255, 0.1);
    position: relative;
    overflow: hidden;
}

.poster-frame::before {
    content: '';
    position: absolute;
    top: 10px;
    left: 10px;
    right: 10px;
    bottom: 10px;
    border: 2px solid #FFD700;
    border-radius: 15px;
    pointer-events: none;
}

.poster-display {
    position: relative;
    aspect-ratio: 4/3;
    border-radius: 15px;
    overflow: hidden;
    background: #2c2c2c;
}

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

.poster-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(transparent, rgba(0, 0, 0, 0.8));
    padding: 30px 20px 20px;
    color: white;
}

.poster-title {
    font-family: 'Playfair Display', serif;
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 5px;
    color: #FFD700;
}

.poster-description {
    font-size: 0.9rem;
    opacity: 0.9;
}

/* Poster Navigation */
.poster-nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 15px;
    padding: 0 10px;
}

.nav-btn {
    background: rgba(255, 215, 0, 0.2);
    border: 2px solid #FFD700;
    color: #FFD700;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    font-size: 1.5rem;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.nav-btn:hover {
    background: #FFD700;
    color: #8B4513;
    transform: scale(1.1);
}

.poster-indicators {
    display: flex;
    gap: 10px;
}

.indicator {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: rgba(255, 215, 0, 0.3);
    border: 2px solid #FFD700;
    cursor: pointer;
    transition: all 0.3s ease;
}

.indicator.active {
    background: #FFD700;
    transform: scale(1.2);
}

/* Decorative Elements */
.decorative-elements {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    pointer-events: none;
    z-index: -1;
}

.pattern-left,
.pattern-right {
    position: absolute;
    width: 100px;
    height: 100px;
    background: radial-gradient(circle, rgba(255, 215, 0, 0.1) 0%, transparent 70%);
    border-radius: 50%;
}

.pattern-left {
    top: -50px;
    left: -50px;
    animation: float 6s ease-in-out infinite;
}

.pattern-right {
    bottom: -50px;
    right: -50px;
    animation: float 6s ease-in-out infinite reverse;
}

/* CTA Section */
.cta-section {
    text-align: center;
    padding: 30px 0 30px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.cta-content {
    position: relative;
}

/* --- CTA Button - Ancient Compass --- */
.cta-button {
    position: relative;
    width: 200px;
    height: 200px;
    border-radius: 50%;
    background: radial-gradient(circle at center, #222 0%, #000 70%);
    border: 2px solid #444;
    color: white;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
    font-family: 'Lora', serif;
    font-size: 1.3em;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 1px;
    z-index: 10;
    outline: none;
    transition: all 0.4s ease-in-out;
    box-shadow:
        0 0 10px rgba(0, 0, 0, 0.8),
        inset 0 0 15px rgba(0, 0, 0, 0.9);
}

.cta-text {
    position: relative;
    z-index: 10;
    color: #ffd700;
    text-shadow:
        0 0 5px rgba(255, 217, 0, 0.7),
        0 0 10px rgba(255, 165, 0, 0.5);
    transition: all 0.4s ease;
    line-height: 1.2;
}

.cta-blade {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 95%;
    height: 4px;
    background: linear-gradient(90deg, transparent, #ffd700, transparent);
    box-shadow: 0 0 8px #ffd700;
    transform: translate(-50%, -50%);
    transform-origin: center;
    transition: all 0.5s cubic-bezier(0.68, -0.55, 0.27, 1.55);
    z-index: 1;
}

.cta-blade:nth-child(1) {
    animation: rotate1 8s linear infinite;
}

.cta-blade:nth-child(2) {
    animation: rotate2 12s linear infinite reverse;
}

.cta-blade:nth-child(3) {
    animation: rotate3 15s linear infinite;
}

.cta-button:hover {
    background: radial-gradient(circle at center, #333 0%, #111 70%);
    border-color: #ffd700;
    box-shadow:
        0 0 20px rgba(255, 217, 0, 0.5),
        inset 0 0 20px rgba(0, 0, 0, 1);
}

.cta-button:hover .cta-text {
    transform: scale(1.1);
    color: #fff;
    text-shadow:
        0 0 8px #fff,
        0 0 15px #ffd700;
}

.cta-button:hover .cta-blade {
    animation-play-state: paused;
    background: linear-gradient(90deg, transparent, #fff, transparent);
    box-shadow: 0 0 12px #fff;
}

.cta-button:hover .cta-blade:nth-child(1) {
    transform: translate(-50%, -50%) rotate(90deg) scaleX(1.1);
}
.cta-button:hover .cta-blade:nth-child(2) {
    transform: translate(-50%, -50%) rotate(0deg) scaleX(1.1);
}
.cta-button:hover .cta-blade:nth-child(3) {
    transform: translate(-50%, -50%) rotate(45deg) scaleX(0.8);
}


@keyframes rotate1 {
    from { transform: translate(-50%, -50%) rotate(0deg); }
    to { transform: translate(-50%, -50%) rotate(360deg); }
}

@keyframes rotate2 {
    from { transform: translate(-50%, -50%) rotate(0deg); }
    to { transform: translate(-50%, -50%) rotate(360deg); }
}

@keyframes rotate3 {
    from { transform: translate(-50%, -50%) rotate(0deg); }
    to { transform: translate(-50%, -50%) rotate(360deg); }
}

.cta-subtitle {
    color: #E6E6FA;
    font-size: 1rem;
    opacity: 0.8;
    max-width: 400px;
    margin: 0 auto;
}

/* Floating Particles */
.particles {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
}

.particle {
    position: absolute;
    width: 4px;
    height: 4px;
    background: #FFD700;
    border-radius: 50%;
    opacity: 0.6;
    animation: particleFloat 8s linear infinite;
}

.particle:nth-child(1) { left: 10%; animation-delay: 0s; }
.particle:nth-child(2) { left: 30%; animation-delay: 2s; }
.particle:nth-child(3) { left: 50%; animation-delay: 4s; }
.particle:nth-child(4) { left: 70%; animation-delay: 6s; }
.particle:nth-child(5) { left: 90%; animation-delay: 1s; }

/* Animations */
@keyframes titleGlow {
    0% { filter: brightness(1) drop-shadow(0 0 10px rgba(255, 215, 0, 0.3)); }
    100% { filter: brightness(1.2) drop-shadow(0 0 20px rgba(255, 215, 0, 0.6)); }
}

@keyframes float {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    50% { transform: translateY(-20px) rotate(180deg); }
}

@keyframes particleFloat {
    0% { transform: translateY(100vh) rotate(0deg); opacity: 0; }
    10% { opacity: 0.6; }
    90% { opacity: 0.6; }
    100% { transform: translateY(-10vh) rotate(360deg); opacity: 0; }
}


/* Info Sections */
.info-section {
    padding: 60px 0;
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
    border-bottom: 1px solid rgba(255, 215, 0, 0.2);
}

.info-section:last-of-type {
    border-bottom: none;
}

.section-title {
    font-family: 'Playfair Display', serif;
    font-size: 2.5rem;
    color: #FFD700;
    margin-bottom: 20px;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.5);
}

.section-text {
    font-size: 1.1rem;
    color: #E6E6FA;
    line-height: 1.8;
    opacity: 0.9;
}

.activities-list {
    list-style: none;
    padding: 0;
    display: inline-block;
    text-align: left;
}

.activities-list li {
    background: rgba(255, 215, 0, 0.1);
    margin: 10px 0;
    padding: 15px 25px;
    border-radius: 10px;
    border-left: 4px solid #FFD700;
    transition: all 0.3s ease;
}

.activities-list li:hover {
    transform: translateX(10px);
    background: rgba(255, 215, 0, 0.2);
}

/* Gallery Section */
.gallery-section {
    padding: 20px 0;
    text-align: center;
    overflow: hidden; /* Hide overflowing images for scroll effect */
}

.gallery-title {
    font-family: "Dancing Script", "Dancing Script Fallback", cursive;
    font-weight: 700; /* Adjusted for Dancing Script */
    line-height: 1.1;
    margin-bottom: 20px;
    text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.7); /* Deeper shadow */
    letter-spacing: 1px; /* Adjusted for style */
    font-style: italic;
    font-size: 48px;

}

.gallery-grid {
    display: flex; /* Changed from grid to flex for animation */
    gap: 20px;
    margin-top: 30px;
    animation: scroll 30s linear infinite;
}

.gallery-item {
    flex-shrink: 0;
    width: 280px; /* Set a fixed width for consistent scrolling */
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
    position: relative;
    cursor: pointer;
}

@keyframes scroll {
    0% {
        transform: translateX(0);
    }
    100% {
        /* (width + gap) * number of original items */
        transform: translateX(calc(-300px * 4));
    }
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease, filter 0.4s ease;
}

.gallery-item:hover img {
    transform: scale(1.1);
    filter: brightness(0.8);
}

.gallery-item::after {
    content: 'Xem ảnh';
    font-family: 'Playfair Display', serif;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: #FFD700;
    font-size: 1.5rem;
    opacity: 0;
    transition: opacity 0.4s ease;
    text-shadow: 1px 1px 2px black;
}

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


/* Image Modal */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    padding-top: 60px;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.9);
}

.modal-content {
    margin: auto;
    display: block;
    width: 80%;
    max-width: 800px;
    animation: zoomIn 0.6s;
}

#modal-caption {
    margin: auto;
    display: block;
    width: 80%;
    max-width: 700px;
    text-align: center;
    color: #ccc;
    padding: 10px 0;
    height: 150px;
}

.close-modal {
    position: absolute;
    top: 15px;
    right: 35px;
    color: #f1f1f1;
    font-size: 40px;
    font-weight: bold;
    transition: 0.3s;
    cursor: pointer;
}

.close-modal:hover,
.close-modal:focus {
    color: #bbb;
    text-decoration: none;
}

@keyframes zoomIn {
    from {transform: scale(0)}
    to {transform: scale(1)}
}

/* Responsive Design */
@media (max-width: 768px) {
    .container { padding: 0 15px; }
    .header { padding: 60px 0 40px; }
    .main-title { font-size: 2.5rem; }
    .subtitle { font-size: 1rem; }
    .poster-container { max-width: 100%; }
    .cta-button { padding: 15px 30px; font-size: 1.1rem; }
}

@media (max-width: 480px) {
    .main-title { font-size: 2rem; }
    .poster-container { max-width: 100%; }
    .poster-frame { padding: 15px; }
    .cta-button { padding: 12px 25px; font-size: 1rem; }
}
