/* =========================================
   Catppuccin Mocha Theme
   ========================================= */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Sekuya', cursive;
    background-color: #1e1e2e; /* Base */
    padding: 20px;
    color: #cdd6f4; /* Text */
    line-height: 1.6;
}

h1 {
    text-align: center;
    margin-bottom: 30px;
    font-size: 2.5rem;
    color: #cba6f7; /* Mauve */
    font-family: 'Sekuya', cursive;
}

.gallery-container {
    display: flex;
    gap: 30px;
    max-width: 1400px;
    margin: 0 auto;
    background: #313244; /* Surface0 */
    padding: 25px;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}


.thumbnail-grid {
    flex: 1;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
    gap: 15px;
}

.gallery-item {
    cursor: pointer;
    border: 3px solid transparent;
    border-radius: 8px;
    overflow: hidden;
    transition: all 0.25s ease;
    opacity: 0.7;
    background: #181825; /* Mantle */
}

.gallery-item:hover {
    opacity: 1;
    transform: scale(1.03);
    box-shadow: 0 3px 10px rgba(137, 180, 250, 0.2); /* Blue glow */
}

.gallery-item.active {
    border-color: #cba6f7; /* Mauve */
    opacity: 1;
    box-shadow: 0 4px 12px rgba(203, 166, 247, 0.4);
}

.gallery-item img {
    width: 100%;
    height: 110px;
    object-fit: cover;
    display: block;
}

.display-area {
    flex: 2;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    background: #181825; /* Mantle */
    border-radius: 8px;
    padding: 20px;
    min-height: 450px;
}

.display-area img {
    max-width: 100%;
    max-height: 500px;
    height: auto;
    border-radius: 4px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
    margin-bottom: 15px;
    /* Smooth fade transition handled by JS */
    transition: opacity 0.2s ease-in-out;
}

.display-area figcaption {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    width: 100%;
    border-top: 1px solid #45475a; /* Surface1 */
    padding-top: 15px;
    gap: 8px; /* Space between lines */
}

.caption-title {
    font-family: Verdana, Geneva, Tahoma, sans-serif;
    font-size: 1.5rem;
    color: #cba6f7; /* Mauve */
    font-weight: normal;
    line-height: 1.2;
}

.caption-meta {
    font-family: 'Inter', sans-serif;
    font-size: 0.95rem;
    color: #a6adc8; /* Subtext0 */
    font-weight: 400;
    letter-spacing: 0.5px;
    opacity: 0.9;
}

footer {
    text-align: center;
    margin-top: 40px;
    padding: 20px;
    color: #6c7086; /* Overlay0 */
    font-size: 0.9rem;
    font-family: 'Inter', sans-serif;
}

footer a {
    color: #89b4fa; /* Blue */
    text-decoration: none;
}

footer a:hover {
    text-decoration: underline;
}

/* Mobile Responsiveness */
@media (max-width: 900px) {
    .gallery-container {
        flex-direction: column;
    }
    
    .display-area {
        order: -1;
        min-height: 350px;
    }
    
    .thumbnail-grid {
        grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
    }
}

@media (max-width: 600px) {
    h1 {
        font-size: 1.8rem;
    }
    
    .gallery-container {
        padding: 15px;
    }
    
    .display-area {
        min-height: 280px;
    }
    
    .display-area img {
        max-height: 350px;
    }
    
    .caption-title {
        font-size: 1.3rem;
    }
    
    .caption-meta {
        font-size: 0.85rem;
    }
}

/* Navigation - Catppuccin Mocha Theme */

nav {
    /* Surface0 with slight transparency for depth */
    background-color: rgba(49, 50, 68, 0.8); 
    padding: 15px;
    border-radius: 8px;
    margin: 20px 0;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px;
    backdrop-filter: blur(5px); /* Optional: adds a nice blur effect behind the nav */
}

nav a {
    display: inline-block;
    padding: 12px 24px;
    /* Text color: Subtext0 (slightly dimmed for links) or Text for high contrast */
    color: #a6adc8; 
    text-decoration: none;
    font-size: 1rem;
    border-radius: 5px;
    transition: all 0.3s ease;
    text-align: center;
    font-family: 'Inter', sans-serif; /* Ensures consistency with the rest of your site */
}

nav a:hover {
    /* Surface1 for hover background */
    background-color: rgba(69, 71, 90, 0.6); 
    /* Blue for hover text to make it pop */
    color: #89b4fa; 
    transform: translateY(-2px); /* Optional: subtle lift effect */
}

/* Secondary Navigation Variant */
nav.secondary {
    text-align: right;
    /* More transparent Surface0 */
    background-color: rgba(49, 50, 68, 0.5);
}