/* Modern Art Gallery - Bold, Clear, Dynamic */

@font-face {
    font-family: 'Walter Turncoat';
    font-style: normal;
    font-weight: 400;
    font-display: swap;
    src: url('fonts/walter-turncoat.ttf') format('truetype');
}

:root {
    --bg-primary: #ffffff;
    --bg-secondary: #f8f8f8;
    --accent-orange: #ff6b35;
    --accent-blue: #0077cc;
    --accent-yellow: #ffd23f;
    --accent-pink: #ff4b8b;
    --text-primary: #1a1a1a;
    --text-secondary: #666666;
    --card-bg: transparent;
    --transition-fast: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-smooth: 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Walter Turncoat', cursive;
    background: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    min-height: 100vh;
    font-weight: 400;
    letter-spacing: 0.02em;
}

/* Navigation */
.main-nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    z-index: 1000;
    transform: translateY(0);
    transition: transform var(--transition-smooth);
}

.nav-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 1.5rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-family: 'Walter Turncoat', cursive;
    font-size: 1.5rem;
    font-weight: 400;
    color: var(--text-primary);
    letter-spacing: 0.05em;
    position: relative;
    text-decoration: none;
    display: inline-block;
}

.logo::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 50%;
    height: 3px;
    background: linear-gradient(90deg, var(--accent-orange), var(--accent-pink));
    transition: width var(--transition-smooth);
}

.logo:hover::after {
    width: 100%;
}

.nav-menu {
    display: flex;
    gap: 2rem;
    list-style: none;
}

.nav-menu a {
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 300;
    font-size: 0.9rem;
    padding: 0.5rem 0;
    transition: all var(--transition-fast);
    position: relative;
    letter-spacing: 0.05em;
}

.nav-menu a::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--accent-orange), var(--accent-pink));
    transition: width var(--transition-smooth);
}

.nav-menu a:hover::after,
.nav-menu a.active::after {
    width: 100%;
}

.nav-menu a:hover,
.nav-menu a.active {
    color: var(--text-primary);
}

/* Main Content */
.content {
    margin-top: 100px;
    padding: 2rem;
    min-height: calc(100vh - 100px);
}

/* Gallery Container */
.gallery-container {
    max-width: 1400px;
    margin: 0 auto;
}

/* Masonry Grid */
.masonry-grid {
    column-count: 1;
    column-gap: 2rem;
    padding: 3rem 0;
}

@media (min-width: 600px) {
    .masonry-grid {
        column-count: 2;
    }
}

@media (min-width: 900px) {
    .masonry-grid {
        column-count: 3;
    }
}

@media (min-width: 1200px) {
    .masonry-grid {
        column-count: 4;
    }
}

.masonry-item {
    opacity: 0;
    animation: fadeInUp 0.6s ease forwards;
    cursor: pointer;
    break-inside: avoid;
    margin-bottom: 2rem;
    display: inline-block;
    width: 100%;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.artwork-card {
    background: transparent;
    overflow: visible;
    transition: all var(--transition-smooth);
    position: relative;
}

.artwork-card:hover {
    transform: scale(1.05);
    z-index: 10;
}

.artwork-image-wrapper {
    width: 100%;
    height: auto;
    overflow: hidden;
    background: var(--bg-secondary);
    position: relative;
    margin-bottom: 1.5rem;
}

.artwork-image-wrapper img {
    width: 100%;
    height: auto;
    display: block;
    transition: opacity var(--transition-fast);
}

.artwork-card:hover .artwork-image-wrapper img {
    opacity: 0.85;
}

.artwork-info {
    padding: 0;
}

.artwork-title {
    font-size: 1.1rem;
    font-weight: 400;
    margin-bottom: 0.75rem;
    color: var(--text-primary);
    line-height: 1.4;
    letter-spacing: 0.02em;
    position: relative;
    display: inline-block;
    padding-bottom: 0.25rem;
}

.artwork-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--accent-orange), var(--accent-pink));
    transition: width var(--transition-smooth);
}

.artwork-card:hover .artwork-title::after {
    width: 100%;
}

.artwork-details {
    font-size: 0.85rem;
    color: var(--text-secondary);
    margin-bottom: 0.3rem;
    font-weight: 300;
    line-height: 1.6;
}

.artwork-meta {
    font-size: 0.8rem;
    color: var(--text-secondary);
    font-weight: 300;
}

/* Modal */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.98);
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity var(--transition-smooth);
    backdrop-filter: blur(20px);
}

.modal.active {
    opacity: 1;
}

.modal-content {
    max-width: 100vw;
    max-height: 98vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
}

.modal-image-wrapper {
    max-width: 100%;
    max-height: 98vh;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 0.5rem;
    position: relative;
}

.modal-image-wrapper img {
    max-width: 100vw;
    max-height: 98vh;
    object-fit: contain;
    transition: opacity 0.3s ease;
}

.zooming-image {
    will-change: transform, top, left, width, height, filter, opacity;
    pointer-events: none;
}

.zooming-image.closing {
    transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1),
                filter 0.6s ease-out,
                opacity 0.6s ease-out;
}

.modal-info {
    text-align: center;
    max-width: 600px;
}

.modal-info h2 {
    font-size: 1.5rem;
    font-weight: 400;
    margin-bottom: 1rem;
    color: var(--text-primary);
    letter-spacing: 0.02em;
}

.modal-info p {
    font-size: 0.95rem;
    font-weight: 300;
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
}

.modal-close,
.modal-prev,
.modal-next {
    position: fixed;
    background: transparent;
    border: 1px solid var(--text-secondary);
    color: var(--text-primary);
    font-size: 1.5rem;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    cursor: pointer;
    transition: all var(--transition-fast);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2001;
}

.modal-close {
    top: 2rem;
    right: 2rem;
}

.modal-prev {
    left: 2rem;
    top: 50%;
    transform: translateY(-50%);
}

.modal-next {
    right: 2rem;
    top: 50%;
    transform: translateY(-50%);
}

.modal-close:hover,
.modal-prev:hover,
.modal-next:hover {
    background: var(--text-primary);
    border-color: var(--text-primary);
    color: white;
}

.modal-prev:hover {
    transform: translateY(-50%) translateX(-3px);
}

.modal-next:hover {
    transform: translateY(-50%) translateX(3px);
}

/* Page Content (CV & Exhibitions) */
.page-content {
    max-width: 900px;
    margin: 0 auto;
    animation: fadeInUp 0.6s ease;
}

.page-title {
    font-size: 2.5rem;
    font-weight: 300;
    margin-bottom: 3rem;
    text-align: center;
    color: var(--text-primary);
    letter-spacing: 0.05em;
}

.cv-section,
.exhibitions-section {
    background: transparent;
    padding: 2rem 0;
    margin-bottom: 2rem;
    border-left: 2px solid var(--accent-orange);
    padding-left: 2rem;
}

.cv-section h2,
.exhibitions-section h2 {
    font-size: 1.5rem;
    font-weight: 400;
    margin-bottom: 2rem;
    color: var(--text-primary);
    letter-spacing: 0.03em;
}

.timeline-item,
.exhibition-item {
    display: flex;
    gap: 2rem;
    margin-bottom: 2rem;
    padding-bottom: 2rem;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.timeline-item:last-child,
.exhibition-item:last-child {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

.timeline-year,
.exhibition-year {
    font-size: 1.2rem;
    font-weight: 400;
    color: var(--text-primary);
    min-width: 100px;
}

.timeline-content h3,
.exhibition-details h3 {
    font-size: 1.1rem;
    font-weight: 400;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
}

.exhibition-location {
    color: var(--text-secondary);
    font-weight: 300;
    font-size: 0.9rem;
}

.exhibition-description {
    color: var(--text-secondary);
    line-height: 1.8;
    font-weight: 300;
    font-size: 0.9rem;
}

/* Responsive Design */
@media (max-width: 768px) {
    .nav-container {
        flex-direction: column;
        gap: 1rem;
        padding: 1rem;
    }

    .nav-menu {
        gap: 1rem;
    }

    .content {
        margin-top: 140px;
        padding: 1rem;
    }

    .masonry-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .page-title {
        font-size: 2rem;
    }

    .timeline-item,
    .exhibition-item {
        flex-direction: column;
        gap: 0.5rem;
    }

    .modal-prev,
    .modal-next {
        display: none;
    }
}

/* Loading Animation */
.artwork-image-wrapper img[loading="lazy"] {
    opacity: 1;
}

/* Footer */
.main-footer {
    background: var(--bg-secondary);
    border-top: 1px solid rgba(0, 0, 0, 0.05);
    padding: 2rem;
    margin-top: 4rem;
}

.footer-content {
    max-width: 1400px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}

.footer-made-with {
    font-size: 0.9rem;
    color: var(--text-secondary);
    font-weight: 300;
}

.footer-links {
    display: flex;
    gap: 1.5rem;
    list-style: none;
}

.footer-links a {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 300;
    transition: color var(--transition-fast);
}

.footer-links a:hover {
    color: var(--text-primary);
}

@media (max-width: 768px) {
    .footer-content {
        flex-direction: column;
        text-align: center;
    }
}
