/* ==========================================================================
   ACTUAL SOURCE–INSPIRED DESIGN SYSTEM
   Monospace · Black & White · Editorial · Swiss Grid
   ========================================================================== */

/* Reset */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    font-size: 16px;
    scroll-behavior: smooth;
}

body {
    font-family: 'Space Mono', 'Courier New', monospace;
    font-weight: 400;
    line-height: 1.5;
    color: #000;
    background-color: #fff;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

a {
    text-decoration: none;
    color: inherit;
    transition: opacity 0.2s ease;
}

a:hover {
    opacity: 0.5;
}

img {
    max-width: 100%;
    height: auto;
}

/* ==========================================================================
   HEADER
   ========================================================================== */

.header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: #fff;
    border-bottom: 1px solid #000;
}

.header-inner {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 40px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 60px;
}

.logo {
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    white-space: nowrap;
}

.logo-img {
    display: none;
}

.nav {
    display: flex;
    align-items: center;
}

.nav-list {
    list-style: none;
    display: flex;
    gap: 32px;
}

.nav-link {
    font-size: 11px;
    font-weight: 400;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    position: relative;
    padding: 4px 0;
}

.nav-link.active {
    font-weight: 700;
}

.nav-link.active::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 0;
    right: 0;
    height: 1px;
    background-color: #000;
}

.social-links {
    display: flex;
    gap: 20px;
    align-items: center;
}

.social-link {
    font-size: 10px;
    font-weight: 400;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    opacity: 0.6;
}

.social-link:hover {
    opacity: 1;
}

.social-icon {
    height: 16px;
    width: auto;
    vertical-align: middle;
    filter: grayscale(100%);
}

/* ==========================================================================
   MAIN
   ========================================================================== */

.main {
    min-height: 100vh;
}

/* ==========================================================================
   PORTFOLIO GRID — INDEX PAGE
   ========================================================================== */

.portfolio-grid {
    max-width: 1400px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1px;
    padding: 0 40px;
    background: #fff;
    border-top: none;
}

.portfolio-item {
    position: relative;
    overflow: hidden;
    background: #fff;
    opacity: 0;
    animation: fadeIn 0.8s ease forwards;
}

.portfolio-item:nth-child(1)  { animation-delay: 0.05s; }
.portfolio-item:nth-child(2)  { animation-delay: 0.10s; }
.portfolio-item:nth-child(3)  { animation-delay: 0.15s; }
.portfolio-item:nth-child(4)  { animation-delay: 0.20s; }
.portfolio-item:nth-child(5)  { animation-delay: 0.25s; }
.portfolio-item:nth-child(6)  { animation-delay: 0.30s; }
.portfolio-item:nth-child(7)  { animation-delay: 0.35s; }
.portfolio-item:nth-child(8)  { animation-delay: 0.40s; }
.portfolio-item:nth-child(9)  { animation-delay: 0.45s; }
.portfolio-item:nth-child(10) { animation-delay: 0.50s; }
.portfolio-item:nth-child(11) { animation-delay: 0.55s; }
.portfolio-item:nth-child(12) { animation-delay: 0.60s; }
.portfolio-item:nth-child(13) { animation-delay: 0.65s; }
.portfolio-item:nth-child(14) { animation-delay: 0.70s; }

.portfolio-image {
    width: 100%;
    aspect-ratio: 1920 / 1080;
    background-color: #000;
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.portfolio-title {
    font-size: 11px;
    font-weight: 400;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    padding: 14px 20px;
    border-top: 1px solid #e0e0e0;
}

/* ==========================================================================
   VIDEO ITEMS
   ========================================================================== */

.video-item {
    cursor: pointer;
}

.video-item .portfolio-image {
    position: relative;
    overflow: hidden;
}

.video-thumbnail {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.4s ease;
    z-index: 2;
}

.thumbnail-overlay {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 56px;
    height: 56px;
    border: 1.5px solid #fff;
    border-radius: 50%;
    background: transparent;
    transition: all 0.3s ease;
    opacity: 0;
}

.video-item:hover .thumbnail-overlay {
    opacity: 1;
}

.play-icon {
    font-size: 1rem;
    color: #fff;
    margin-left: 3px;
}

.video-item:hover .video-thumbnail {
    opacity: 0;
    pointer-events: none;
}

.video-embed {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.video-embed video {
    width: 100%;
    height: 100%;
    object-fit: fill;
}

.video-item:hover .portfolio-image {
    transform: none;
}

/* ==========================================================================
   FADE IN ANIMATION
   ========================================================================== */

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

/* ==========================================================================
   FOOTER
   ========================================================================== */

.footer {
    border-top: 1px solid #000;
    padding: 20px 40px;
    max-width: 1400px;
    margin: 0 auto;
}

.footer p {
    font-size: 10px;
    font-weight: 400;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    opacity: 0.5;
}

/* ==========================================================================
   ABOUT PAGE
   ========================================================================== */

.about-content {
    max-width: 1400px;
    margin: 0 auto;
    padding: 60px 40px 15px;
    display: flex;
    gap: 80px;
    align-items: flex-start;
}

.about-left {
    flex: 1;
    max-width: 50%;
}

.about-right {
    flex: 1;
    max-width: 50%;
}

.about-image-stack {
    position: relative;
    width: 100%;
}

.about-bg-image {
    width: 60%;
    display: block;
}

.about-headshot {
    position: absolute;
    width: 55%;
    right: 10%;
    top: 50%;
    transform: translateY(-50%);
}

.about-text {
    font-size: 13px;
    line-height: 1.7;
    margin-bottom: 1.2em;
    letter-spacing: 0.01em;
}

.about-text a {
    text-decoration: underline;
    text-underline-offset: 3px;
    color: #000;
}

.about-text a:hover {
    opacity: 0.5;
}

.about-text strong {
    font-weight: 700;
    letter-spacing: 0.08em;
    font-size: 10px;
    text-transform: uppercase;
}

.about-contact {
    margin-top: 40px;
    padding-top: 40px;
    border-top: 1px solid #e0e0e0;
}

.about-contact a {
    font-size: 13px;
}

.about-quote {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 40px 60px;
}

.about-quote img {
    max-width: 100%;
    height: auto;
}

/* ==========================================================================
   SCRAPBOOK — LOADING OVERLAY
   ========================================================================== */

.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #fff;
    z-index: 999;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    transition: opacity 0.5s ease;
}

.loading-overlay.loaded {
    opacity: 0;
    pointer-events: none;
}

.loading-text {
    font-size: 10px;
    font-weight: 400;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: #000;
    margin-top: 24px;
}

.loading-text::after {
    content: '';
    animation: ellipsis 1.5s steps(4, end) infinite;
}

@keyframes ellipsis {
    0%  { content: ''; }
    25% { content: '.'; }
    50% { content: '..'; }
    75% { content: '...'; }
}

/* Loading Symbol Animation */
.loading-symbol {
    width: 80px;
    height: 80px;
    object-fit: contain;
}

/* ==========================================================================
   SCRAPBOOK PAGE
   ========================================================================== */

.scrapbook-heading {
    max-width: 1400px;
    margin: 0 auto;
    padding: 40px 40px 24px;
    font-size: 13px;
    font-weight: 400;
    letter-spacing: 0.02em;
}

.scrapbook-feed {
    column-count: 4;
    column-gap: 4px;
    padding: 0 40px 40px;
    max-width: 1400px;
    margin: 0 auto;
}

.scrapbook-item {
    break-inside: avoid;
    -webkit-column-break-inside: avoid;
    margin-bottom: 4px;
    overflow: hidden;
    line-height: 0;
    display: block;
    width: 100%;
    background-color: #f0f0f0;
}

.scrapbook-item img,
.scrapbook-item video {
    width: 100%;
    height: auto;
    display: block;
    opacity: 0;
    transition: opacity 0.4s ease;
}

.scrapbook-item img.loaded,
.scrapbook-item video.loaded {
    opacity: 1;
}

/* ==========================================================================
   RESPONSIVE — TABLET
   ========================================================================== */

@media (max-width: 1024px) {
    .scrapbook-feed {
        column-count: 3;
    }
}

@media (max-width: 768px) {
    .header-inner {
        flex-wrap: wrap;
        height: auto;
        padding: 16px 24px;
        gap: 12px;
    }

    .logo {
        width: 100%;
        text-align: center;
        font-size: 11px;
    }

    .nav {
        width: 100%;
        justify-content: center;
    }

    .nav-list {
        gap: 20px;
    }

    .social-links {
        width: 100%;
        justify-content: center;
    }

    .portfolio-grid {
        grid-template-columns: 1fr;
        padding: 0 24px;
    }

    .portfolio-title {
        padding: 12px 16px;
    }

    .about-content {
        flex-direction: column;
        padding: 40px 24px 10px;
        gap: 40px;
    }

    .about-left {
        max-width: 100%;
    }

    .about-right {
        max-width: 100%;
    }

    .about-image-stack {
        display: flex;
        justify-content: center;
    }

    .about-headshot {
        right: 2%;
    }

    .about-quote {
        padding: 0 24px 40px;
    }

    .footer {
        padding: 20px 24px;
    }

    .scrapbook-heading {
        padding: 32px 24px 20px;
    }

    .scrapbook-feed {
        column-count: 2;
        padding: 0 24px 24px;
    }
}

/* ==========================================================================
   RESPONSIVE — MOBILE
   ========================================================================== */

@media (max-width: 480px) {
    .header-inner {
        padding: 14px 16px;
    }

    .nav-list {
        gap: 16px;
        flex-wrap: wrap;
        justify-content: center;
    }

    .social-links {
        gap: 16px;
    }

    .portfolio-grid {
        padding: 0 16px;
    }

    .portfolio-title {
        padding: 10px 12px;
        font-size: 10px;
    }

    .about-content {
        padding: 32px 16px 8px;
    }

    .about-quote {
        padding: 0 16px 32px;
    }

    .about-contact {
        margin-top: 32px;
        padding-top: 32px;
    }

    .footer {
        padding: 16px;
    }

    .scrapbook-heading {
        padding: 24px 16px 16px;
    }

    .scrapbook-feed {
        column-count: 1;
        padding: 0 16px 16px;
    }
}
