/* ── General Reset ── */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    height: 100%;
}

body {
    font-family: 'Montserrat', sans-serif;
    background-color: #f5f2ee;
    color: #333333;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* ── Navigation ── */
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background-color: #2c2c2c;
    padding: 18px 40px;
    position: sticky;
    top: 0;
    z-index: 100;
    flex-wrap: wrap;
    gap: 12px;
}

.nav-logo {
    color: #f0e6d3;
    font-family: 'Montserrat', sans-serif;
    font-size: 1.4rem;
    font-weight: 700;
    letter-spacing: 1px;
}

.nav-links {
    list-style: none;
    display: flex;
    gap: 30px;
    flex-wrap: wrap;
}

.nav-links a {
    color: #cccccc;
    text-decoration: none;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.95rem;
    letter-spacing: 0.5px;
    transition: color 0.3s;
}

.nav-links a:hover,
.nav-links a.active {
    color: #f0e6d3;
    border-bottom: 2px solid #f0e6d3;
    padding-bottom: 3px;
}

/* ── Hero Banner (Puzzle only) ── */
.puzzle-hero {
    background-color: #2c2c2c;
    color: #f0e6d3;
    text-align: center;
    padding: 28px 40px;
}

.puzzle-hero-title {
    font-family: 'Montserrat', sans-serif;
    font-size: 1.4rem;
    font-weight: 700;
    margin-bottom: 8px;
    letter-spacing: 0.5px;
    line-height: 1.3;
    color: #f0e6d3;
}

.puzzle-hero-sub {
    font-family: 'Montserrat', sans-serif;
    font-size: 0.85rem;
    color: #bbbbbb;
    line-height: 1.7;
}

/* ── Gallery Section ── */
.gallery-section {
    padding: 40px 40px;
    max-width: 900px;
    margin: 0 auto;
    width: 100%;
    flex: 1;
}

/* ── Artwork Cards ── */
.artwork-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-bottom: 120px;
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.9s ease, transform 0.9s ease;
}

.artwork-card.visible {
    opacity: 1;
    transform: translateY(0);
}

.artwork-card.fading {
    opacity: 0;
    transform: translateY(-30px);
}

/* ── Image Wrap + Vignette ── */
.artwork-image-wrap {
    position: relative;
    width: 100%;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.15);
    cursor: pointer;
}

.artwork-image-wrap img {
    width: 100%;
    height: auto;
    display: block;
    transition: transform 0.6s ease;
}

.artwork-image-wrap:hover img {
    transform: scale(1.02);
}

.vignette {
    position: absolute;
    inset: 0;
    border-radius: 10px;
    background: radial-gradient(
        ellipse at center,
        transparent 55%,
        rgba(0, 0, 0, 0.45) 100%
    );
    pointer-events: none;
    transition: opacity 0.6s ease;
}

.artwork-image-wrap:hover .vignette {
    opacity: 0.4;
}

/* ── Artwork Info ── */
.artwork-info {
    margin-top: 24px;
    text-align: center;
    max-width: 680px;
}

.artwork-info h3 {
    font-family: 'Montserrat', sans-serif;
    font-size: 1.3rem;
    font-weight: 700;
    margin-bottom: 12px;
    color: #2c2c2c;
}

.artwork-info p {
    font-family: 'Montserrat', sans-serif;
    font-size: 0.97rem;
    color: #666666;
    line-height: 1.8;
}

/* ──────────────────────────────────────────
   Per-Painting Centering
────────────────────────────────────────── */

#card-directions .artwork-image-wrap img {
    object-fit: cover;
    height: 85vw;
    max-height: 720px;
    object-position: 47% 44%;
}

#card-icecream .artwork-image-wrap img {
    object-fit: cover;
    height: 85vw;
    max-height: 720px;
    object-position: 50% 50%;
}

#card-secondtrail .artwork-image-wrap img {
    object-fit: cover;
    height: 85vw;
    max-height: 720px;
    object-position: 48% 43%;
}

#card-starpoint .artwork-image-wrap img {
    object-fit: cover;
    height: 85vw;
    max-height: 720px;
    object-position: 50% 50%;
}

#card-trail .artwork-image-wrap img {
    object-fit: cover;
    height: 85vw;
    max-height: 720px;
    object-position: 53% 44%;
}

#card-ukraine .artwork-image-wrap img {
    object-fit: cover;
    height: 85vw;
    max-height: 720px;
    object-position: 50% 50%;
}

#card-secondukraine .artwork-image-wrap img {
    object-fit: cover;
    height: 85vw;
    max-height: 720px;
    object-position: 53% 43%;
}

/* ── Parallel Series Images ── */
.parallel-wrap img {
    object-fit: cover;
    height: 75vw;
    max-height: 700px;
    object-position: center center;
}

/* ── About Page ── */
.about-section {
    padding: 80px 40px;
    max-width: 900px;
    margin: 0 auto;
    width: 100%;
    flex: 1;
}

.about-container {
    display: flex;
    gap: 60px;
    align-items: flex-start;
    flex-wrap: wrap;
}

.about-photo {
    flex: 0 0 200px;
}

.about-me-img {
    width: 200px;
    height: 200px;
    border-radius: 50%;
    object-fit: cover;
    object-position: center top;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
    display: block;
}

.about-text {
    flex: 1;
}

.about-text h2 {
    font-family: 'Montserrat', sans-serif;
    font-size: 1.9rem;
    font-weight: 700;
    margin-bottom: 16px;
    color: #2c2c2c;
}

.about-text p {
    font-family: 'Montserrat', sans-serif;
    font-size: 1.05rem;
    color: #555555;
    line-height: 1.85;
}

.about-p2 {
    margin-top: 16px;
}

/* ── Kirengatal Definition ── */
.kirengatal-definition {
    margin-top: 32px;
    padding-top: 28px;
    border-top: 1px solid #ddd;
    margin-bottom: 28px;
}

.definition-word {
    font-family: 'Montserrat', sans-serif;
    font-size: 1.4rem;
    font-weight: 700;
    color: #2c2c2c;
    letter-spacing: 1px;
    margin-bottom: 4px;
}

.definition-meta {
    font-family: 'Montserrat', sans-serif;
    font-size: 0.88rem;
    color: #999999;
    margin-bottom: 10px;
    letter-spacing: 0.3px;
}

.definition-body {
    font-family: 'Montserrat', sans-serif;
    font-size: 0.97rem;
    color: #555555;
    line-height: 1.85;
}

/* ── Contact Links ── */
.about-contact {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.contact-link {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.97rem;
    font-weight: 600;
    transition: opacity 0.3s;
}

.contact-link:hover {
    opacity: 0.75;
}

.instagram-link {
    color: #c13584;
}

.email-link {
    color: #2c2c2c;
}

.instagram-icon,
.email-icon {
    width: 22px;
    height: 22px;
    flex-shrink: 0;
}

/* ── Puzzle Page ── */
.puzzle-section {
    display: flex;
    flex-direction: column;
    align-items: center;
}

#puzzle-image-wrap img {
    object-fit: cover;
    height: 70vw;
    max-height: 600px;
    object-position: 50% 50%;
}

.puzzle-info {
    margin-top: 24px;
    text-align: center;
    max-width: 700px;
}

.puzzle-info h3 {
    font-family: 'Montserrat', sans-serif;
    font-size: 1.3rem;
    font-weight: 700;
    margin-bottom: 14px;
    color: #2c2c2c;
}

.puzzle-info p {
    font-family: 'Montserrat', sans-serif;
    font-size: 0.97rem;
    color: #666666;
    line-height: 1.85;
}

.puzzle-address {
    margin-top: 28px;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.97rem;
    color: #444444;
    line-height: 1.7;
}

.puzzle-contact {
    margin-top: 18px;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.97rem;
    color: #666666;
    line-height: 1.85;
}

.inline-email {
    color: #2c2c2c;
    font-weight: 600;
    text-decoration: none;
    border-bottom: 1px solid #2c2c2c;
    transition: opacity 0.3s;
}

.inline-email:hover {
    opacity: 0.6;
}

/* ── Footer ── */
.footer {
    background-color: #2c2c2c;
    color: #888888;
    text-align: center;
    padding: 20px;
    font-size: 0.85rem;
    font-family: 'Montserrat', sans-serif;
    position: sticky;
    bottom: 0;
    z-index: 100;
}

/* ── Responsive ── */
@media (max-width: 768px) {
    .navbar {
        flex-direction: column;
        align-items: flex-start;
        padding: 16px 20px;
        gap: 10px;
    }

    .nav-links {
        gap: 20px;
    }

    .puzzle-hero {
        padding: 20px 20px;
    }

    .puzzle-hero-title {
        font-size: 1.1rem;
    }

    .puzzle-hero-sub {
        font-size: 0.8rem;
    }

    .gallery-section {
        padding: 24px 20px;
    }

    .artwork-card {
        margin-bottom: 70px;
    }

    .artwork-info h3 {
        font-size: 1.15rem;
    }

    .artwork-info p {
        font-size: 0.93rem;
    }

    #card-directions .artwork-image-wrap img,
    #card-icecream .artwork-image-wrap img,
    #card-secondtrail .artwork-image-wrap img,
    #card-starpoint .artwork-image-wrap img,
    #card-trail .artwork-image-wrap img,
    #card-ukraine .artwork-image-wrap img,
    #card-secondukraine .artwork-image-wrap img {
        height: 95vw;
        max-height: none;
    }

    #puzzle-image-wrap img {
        height: 90vw;
        max-height: none;
    }

    .parallel-wrap img {
        height: 90vw;
        max-height: none;
    }

    .about-section {
        padding: 40px 20px;
    }

    .about-container {
        flex-direction: column;
        align-items: center;
        text-align: center;
        gap: 30px;
    }

    .about-photo {
        flex: 0 0 auto;
    }

    .about-me-img {
        width: 150px;
        height: 150px;
    }

    .about-text h2 {
        font-size: 1.5rem;
    }

    .about-text p {
        font-size: 0.97rem;
    }

    .about-contact {
        align-items: center;
    }

    .puzzle-info p {
        font-size: 0.93rem;
    }
}

@media (max-width: 400px) {
    .nav-logo {
        font-size: 1.1rem;
    }

    .nav-links a {
        font-size: 0.85rem;
    }

    .about-me-img {
        width: 120px;
        height: 120px;
    }
}
