/* Membrane Template — Work Detail Styles */

.work-detail {
    max-width: 960px;
}

/* Back Link */
.back-link {
    display: inline-flex;
    align-items: center;
    gap: var(--spacing-sm);
    color: var(--muted-color);
    font-size: 13px;
    margin-bottom: var(--spacing-2xl);
    transition: color 0.3s ease;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.back-link::before {
    content: '\2190';
    font-size: 16px;
}

.back-link:hover {
    color: var(--accent-color);
    text-shadow: 0 0 8px rgba(139, 92, 246, 0.3);
}

/* Work Header */
.work-header {
    margin-bottom: var(--spacing-2xl);
}

.work-title {
    font-family: var(--font-display);
    font-size: 48px;
    font-weight: 700;
    line-height: 1.1;
    margin-bottom: var(--spacing-lg);
    color: var(--primary-color);
    text-shadow: 0 0 40px rgba(139, 92, 246, 0.15);
}

.work-metadata {
    display: flex;
    flex-wrap: wrap;
    gap: var(--spacing-xl);
    font-size: 14px;
    padding-bottom: var(--spacing-xl);
    border-bottom: 1px solid var(--border-color);
    position: relative;
}

.work-metadata::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 0;
    width: 80px;
    height: 1px;
    background: var(--glow-gradient);
    box-shadow: var(--glow-sm);
}

.work-metadata dt {
    font-weight: 500;
    color: var(--secondary-color);
    margin-bottom: 2px;
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

.work-metadata dd {
    color: var(--text-color);
}

/* Status badges */
.work-metadata dd[data-status="for_sale"] { color: #4ADE80; font-weight: 500; }
.work-metadata dd[data-status="sold"] { color: #F87171; font-weight: 500; }
.work-metadata dd[data-status="on_loan"] { color: #FBBF24; font-weight: 500; }
.work-metadata dd[data-status="nfs"] { color: var(--muted-color); font-weight: 500; }

/* Work Images */
.work-images {
    margin-bottom: var(--spacing-2xl);
}

.featured-image {
    margin-bottom: var(--spacing-xl);
    border: 1px solid rgba(139, 92, 246, 0.15);
    transition: box-shadow 0.4s ease, border-color 0.4s ease;
    position: relative;
    overflow: hidden;
}

.featured-image::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: var(--glow-gradient);
    opacity: 0;
    transition: opacity 0.4s ease;
    box-shadow: 0 0 12px rgba(139, 92, 246, 0.4);
}

.featured-image:hover {
    box-shadow: var(--glow-lg);
    border-color: rgba(139, 92, 246, 0.3);
}

.featured-image:hover::after {
    opacity: 1;
}

.featured-image img {
    width: 100%;
    height: auto;
    display: block;
    cursor: pointer;
}

.image-gallery {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--spacing-lg);
}

.gallery-image {
    position: relative;
    background: var(--placeholder-bg);
    cursor: pointer;
    border: 1px solid rgba(139, 92, 246, 0.1);
    overflow: hidden;
    transition: box-shadow 0.4s ease, border-color 0.4s ease, transform 0.4s ease;
}

.gallery-image:hover {
    border-color: rgba(139, 92, 246, 0.4);
    box-shadow: var(--glow-md);
    transform: translateY(-2px);
}

.gallery-image img {
    width: 100%;
    height: auto;
    display: block;
    transition: transform 0.6s ease, filter 0.4s ease;
    filter: saturate(0.9);
}

.gallery-image:hover img {
    transform: scale(1.03);
    filter: saturate(1.1);
}

/* Work Description */
.work-description {
    max-width: 720px;
    margin-bottom: var(--spacing-2xl);
}

.work-description p {
    font-size: 16px;
    line-height: 1.8;
    color: var(--text-color);
    margin-bottom: var(--spacing-md);
}

/* Navigation */
.work-navigation {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: var(--spacing-xl);
    border-top: 1px solid var(--border-color);
    margin-top: var(--spacing-2xl);
}

.nav-link {
    display: flex;
    flex-direction: column;
    gap: 4px;
    text-decoration: none;
    color: var(--secondary-color);
    transition: color 0.3s ease;
}

.nav-link:hover {
    color: var(--accent-color);
    text-shadow: 0 0 8px rgba(139, 92, 246, 0.2);
}

.nav-link.prev { align-items: flex-start; }
.nav-link.next { align-items: flex-end; text-align: right; }

.nav-label {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--text-light-color);
}

.nav-title {
    font-weight: 500;
    font-size: 14px;
    color: var(--primary-color);
}

/* Lightbox — Dark overlay */
.lightbox {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(10, 10, 15, 0.96);
    z-index: 1000;
    display: none;
    align-items: center;
    justify-content: center;
    padding: var(--spacing-xl);
}

.lightbox.active {
    display: flex;
}

.lightbox-image {
    max-width: 90%;
    max-height: 90vh;
    object-fit: contain;
    box-shadow: var(--glow-lg);
}

.lightbox-close {
    position: absolute;
    top: var(--spacing-xl);
    right: var(--spacing-xl);
    background: none;
    border: none;
    font-size: 28px;
    color: var(--primary-color);
    cursor: pointer;
    transition: color 0.3s ease, text-shadow 0.3s ease;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.lightbox-close:hover {
    color: var(--accent-color);
    text-shadow: 0 0 12px rgba(139, 92, 246, 0.5);
}

/* Responsive */
@media (max-width: 768px) {
    .work-title { font-size: 36px; }
    .work-metadata { gap: var(--spacing-lg); }
    .image-gallery { grid-template-columns: 1fr; }
    .work-navigation { flex-direction: column; gap: var(--spacing-lg); }
    .nav-link.next { align-items: flex-start; text-align: left; }
}

/* Video Embed */
.work-video { margin: 2rem 0; }
.video-container { position: relative; padding-bottom: 56.25%; height: 0; overflow: hidden; }
.video-container iframe { position: absolute; top: 0; left: 0; width: 100%; height: 100%; }
