/* ============================================================================
   RAVIX — SINGLE PROJECT PAGE LAYOUT
   v4 — Gallery 48px inset, 2-col, images uncropped, mobile fixed
   ============================================================================ */

/* ── RESET: override global body padding so hero is full-screen ── */
body.page-template-template-hi-maintenance,
body.page-template-template-kalvara-equestrian,
body.page-template-template-wear-that,
body.page-template-template-danube-properties,
body.page-template-template-vox-cinemas,
body.page-template-template-yaro,
body.page-template-template-monogram-eyewear,
body.page-template-template-zey-mc {
    padding-top: 0 !important;
}

/* ── ENGINE WRAPPER ── */
.ravix-project-engine {
    background: #000;
    color: #fff;
    font-family: 'DM Sans', sans-serif;
    width: 100%;
    overflow-x: hidden;
}

/* ── PROJECT HERO ── */
.project-hero {
    position: relative;
    width: 100%;
    height: 100vh;
    overflow: hidden;
    background: #000;
}

.project-hero .hero-img-bg {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.hero-video-bg {
    position: relative;
    width: 100%;
    height: 100%;
}

.hero-video-bg iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
}

/* ── CONTENT CONTAINER ── */
.content-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 80px 60px;
}

/* ── PROJECT TITLE HEADER ── */
.project-title-header {
    margin-bottom: 40px;
}

.project-title-header span {
    display: block;
    font-size: 11px;
    letter-spacing: 4px;
    text-transform: uppercase;
    color: #666;
    margin-bottom: 12px;
}

.project-title-header h1 {
    font-size: clamp(40px, 6vw, 80px);
    font-weight: 700;
    color: #fff;
    margin: 0;
    line-height: 1.05;
    letter-spacing: -1px;
}

/* ── METADATA GRID ── */
.metadata-grid {
    display: flex;
    gap: 60px;
    margin-bottom: 60px;
    padding-bottom: 40px;
    border-bottom: 1px solid #1a1a1a;
    flex-wrap: wrap;
}

.meta-item {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.meta-item span {
    font-size: 10px;
    letter-spacing: 3px;
    text-transform: uppercase;
    color: #555;
}

.meta-value {
    font-size: 14px;
    color: #fff;
    font-weight: 500;
}

/* ── PROJECT NARRATIVE ── */
.project-narrative {
    max-width: 760px;
}

.project-narrative h2 {
    font-size: 11px;
    letter-spacing: 4px;
    text-transform: uppercase;
    color: #555;
    margin: 40px 0 12px;
    font-weight: 700;
}

.project-narrative h2:first-child {
    margin-top: 0;
}

.project-narrative p {
    font-size: 16px;
    line-height: 1.75;
    color: #ccc;
    margin: 0 0 20px;
}

/* ── NARRATIVE SPLIT ── */
.narrative-split {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: start;
}

/* ── SPECIAL REEL ── */
.special-reel {
    position: sticky;
    top: 120px;
}

.video-wrapper {
    position: relative;
    width: 100%;
    padding-bottom: 56.25%;
    height: 0;
    overflow: hidden;
}

.video-wrapper iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
}

.video-wrapper.vertical {
    padding-bottom: 177.78%;
}

/* ── CREW SECTION ── */
.crew-section {
    margin-top: 48px;
    padding-top: 32px;
    border-top: 1px solid #1a1a1a;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.crew-item {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.crew-item label {
    font-size: 10px;
    letter-spacing: 3px;
    text-transform: uppercase;
    color: #555;
}

.crew-value {
    font-size: 14px;
    color: #fff;
    font-weight: 500;
}

/* ── MASONRY GRID ── */
/* 48px inset — not touching edges */
.masonry-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    padding: 0 48px 48px;
    background: #000;
    box-sizing: border-box;
}

/* Full image always visible — fits viewport, no cropping, no scrolling through one image */
.asset-item {
    background: #000;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    max-height: 85vh;
    overflow: hidden;
}

.asset-item img {
    width: 100%;
    height: 100%;
    max-height: 85vh;
    object-fit: contain;
    display: block;
}

.asset-item video {
    width: 100%;
    height: 100%;
    max-height: 85vh;
    object-fit: contain;
    display: block;
}

/* Full-width mid item spans both columns */
.asset-item.mid {
    grid-column: 1 / -1;
}

/* Embedded video wrappers keep 16:9 aspect */
.asset-item .video-wrapper {
    position: relative;
    width: 100%;
    padding-bottom: 56.25%;
    height: 0;
    overflow: hidden;
    max-height: none;
}

.asset-item .video-wrapper iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
}

/* ── NEXT PROJECT NAV ── */
.next-project-nav {
    border-top: 1px solid #1a1a1a;
    padding: 0;
}

.next-project-nav .nav-container {
    display: flex;
    align-items: center;
    text-decoration: none;
    color: #fff;
    padding: 60px;
    gap: 40px;
    transition: background 0.3s ease;
}

.next-project-nav .nav-container:hover {
    background: #0a0a0a;
}

.nav-thumb {
    width: 160px;
    height: 100px;
    overflow: hidden;
    flex-shrink: 0;
}

.nav-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.nav-text {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.nav-text span {
    font-size: 10px;
    letter-spacing: 3px;
    text-transform: uppercase;
    color: #555;
}

.nav-text h3 {
    font-size: clamp(24px, 3vw, 40px);
    font-weight: 700;
    margin: 0;
    color: #fff;
    letter-spacing: -0.5px;
}

.nav-text p {
    font-size: 14px;
    color: #666;
    margin: 0;
    line-height: 1.5;
}

/* ── RESPONSIVE: Tablet ── */
@media (max-width: 1024px) {
    .content-container {
        padding: 60px 40px;
    }

    .narrative-split {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .special-reel {
        position: static;
    }

    .metadata-grid {
        gap: 30px;
    }

    .masonry-grid {
        padding: 0 32px 32px;
        gap: 10px;
    }
}

/* ── RESPONSIVE: Mobile ── */
@media (max-width: 768px) {
    .content-container {
        padding: 40px 20px;
    }

    .project-title-header h1 {
        font-size: 32px;
        letter-spacing: -0.5px;
    }

    .metadata-grid {
        gap: 16px;
        margin-bottom: 40px;
        padding-bottom: 30px;
    }

    .masonry-grid {
        grid-template-columns: 1fr;
        gap: 8px;
        padding: 0 16px 40px;
    }

    .asset-item.mid {
        grid-column: 1;
    }

    .next-project-nav .nav-container {
        padding: 32px 20px;
        gap: 16px;
        flex-wrap: nowrap;
    }

    .nav-thumb {
        width: 80px;
        height: 52px;
    }

    .nav-text h3 {
        font-size: 22px;
    }

    .nav-text p {
        display: none;
    }
}