
/* ========================================
   FIELD NOTES — PHOTOGRAPHY PORTFOLIO
   ======================================== */

@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:ital,wght@0,400;0,500;0,600;1,400;1,500&family=DM+Sans:wght@400;500;600&display=swap');


/* COLOR PALETTE */

:root {
    --cream: #f5f1e8;
    --sand: #d8d0c1;
    --sage: #858d76;
    --forest: #283d32;
    --charcoal: #292824;
    --white: #ffffff;

    --serif: 'Cormorant Garamond', Georgia, serif;
    --sans: 'DM Sans', Arial, sans-serif;
}


/* GENERAL SETTINGS */

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

html {
    scroll-behavior: smooth;
    scroll-padding-top: 100px;
}

body {
    background: var(--cream);
    color: var(--charcoal);
    font-family: var(--sans);
    line-height: 1.7;
}

img {
    display: block;
    max-width: 100%;
}

a {
    color: inherit;
    text-decoration: none;
}

button {
    font-family: var(--sans);
    cursor: pointer;
}

[hidden] {
    display: none !important;
}

::selection {
    background: var(--sage);
    color: white;
}


/* NAVIGATION */

header {
    position: sticky;
    top: 0;
    z-index: 100;

    display: flex;
    align-items: center;
    justify-content: space-between;

    padding: 22px 6%;
    background: var(--cream);
    border-bottom: 1px solid var(--sand);
}

.brand {
    font-family: var(--serif);
    font-size: 27px;
    font-weight: 600;
    letter-spacing: 4px;
    line-height: 1.1;
    color: var(--forest);
}

.brand small {
    display: block;
    font-family: var(--sans);
    font-size: 9px;
    letter-spacing: 5px;
    margin-top: 7px;
}

nav {
    display: flex;
    gap: 35px;
}

nav a {
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 2px;
    position: relative;
}

nav a::after {
    content: '';
    position: absolute;
    bottom: -6px;
    left: 0;
    width: 0;
    height: 1px;
    background: var(--forest);
    transition: width 0.3s ease;
}

nav a:hover::after {
    width: 100%;
}


/* HOMEPAGE */

.hero {
    min-height: 85vh;

    background:
        linear-gradient(
            90deg,
            rgba(15, 24, 19, 0.65),
            rgba(15, 24, 19, 0.1)
        ),
        url('assets/images/photo-01.jpg');

    background-color: var(--forest);
    background-size: cover;
    background-position: center;

    display: flex;
    align-items: center;

    padding: 8%;
    color: var(--cream);
}

.hero-copy {
    max-width: 800px;
    animation: fade-in 1.5s ease;
}

.hero-copy span {
    font-size: 11px;
    letter-spacing: 4px;
    line-height: 2;
}

.hero h1 {
    font-family: var(--serif);
    font-weight: 400;
    font-size: clamp(80px, 12vw, 180px);
    line-height: 0.85;
    margin: 35px 0 45px;
}

.hero h1 i {
    font-weight: 400;
}


/* BUTTONS */

.button {
    display: inline-block;
    padding: 15px 28px;

    border: 1px solid currentColor;

    font-size: 11px;
    letter-spacing: 2px;
    text-transform: uppercase;

    transition: all 0.3s ease;
}

.button:hover {
    background: var(--forest);
    border-color: var(--forest);
    color: var(--cream);
}

.hero .button:hover {
    background: var(--cream);
    color: var(--forest);
    border-color: var(--cream);
}


/* PORTFOLIO SECTION */

#portfolio {
    padding: 110px 6%;
}

.intro {
    max-width: 700px;
    margin-bottom: 60px;
}

.intro span,
.about span,
#contact span,
#series-intro span {
    font-size: 11px;
    letter-spacing: 3px;
    text-transform: uppercase;
    color: var(--sage);
}

h2 {
    font-family: var(--serif);
    font-size: clamp(48px, 6vw, 90px);
    font-weight: 400;
    line-height: 1;
    color: var(--forest);
    margin: 20px 0;
}

.intro p {
    font-size: 15px;
    max-width: 500px;
}


/* PHOTOGRAPHY SERIES COVERS */

#series-covers {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 24px;
    margin-bottom: 90px;
}

.series-card {
    position: relative;
    display: block;
    width: 100%;
    aspect-ratio: 4 / 5;

    overflow: hidden;
    border: none;
    background: var(--forest);

    color: var(--white);
    text-align: left;
    cursor: pointer;
}

.series-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;

    transition: transform 0.8s ease;
}

.series-card::after {
    content: '';
    position: absolute;
    inset: 0;

    background: linear-gradient(
        transparent 30%,
        rgba(0, 0, 0, 0.75)
    );

    pointer-events: none;
}

.series-card:hover img {
    transform: scale(1.06);
}

.series-info {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;

    padding: 28px;
    z-index: 2;
}

.series-info span {
    font-size: 10px;
    letter-spacing: 3px;
    text-transform: uppercase;
}

.series-info h3 {
    font-family: var(--serif);
    font-size: clamp(28px, 3vw, 48px);
    font-weight: 400;
    line-height: 1.1;
    margin: 10px 0;
}

.series-info p {
    font-size: 12px;
    opacity: 0.85;
}


/* INDIVIDUAL SERIES INTRODUCTION */

#series-intro {
    max-width: 750px;
    margin: 70px auto 40px;
    text-align: center;
}

#series-intro h2 {
    margin-bottom: 25px;
}

#series-intro p {
    color: var(--charcoal);
    line-height: 1.9;
}


/* GALLERY FILTERS */

#filters {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 12px;

    margin: 40px 0;
}

#filters button {
    padding: 10px 20px;

    border: 1px solid var(--sand);
    background: transparent;
    color: var(--forest);

    font-size: 11px;
    letter-spacing: 1px;

    transition: all 0.3s ease;
}

#filters button:hover,
#filters button.active {
    background: var(--forest);
    border-color: var(--forest);
    color: var(--cream);
}


/* MASONRY PHOTOGRAPHY GALLERY */

#gallery {
    columns: 3;
    column-gap: 24px;
}

.photo-card {
    display: block;
    width: 100%;
    break-inside: avoid;

    margin-bottom: 24px;
    padding: 0;
    border: none;
    background: transparent;

    position: relative;
    overflow: hidden;
    cursor: zoom-in;
}

.photo-card img {
    width: 100%;
    height: auto;

    transition: transform 0.6s ease;
}

.photo-card:hover img {
    transform: scale(1.025);
}

.photo-info {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;

    padding: 25px 20px 15px;

    color: white;
    text-align: left;

    background: linear-gradient(
        transparent,
        rgba(0, 0, 0, 0.7)
    );

    opacity: 0;
    transition: opacity 0.3s ease;
}

.photo-card:hover .photo-info,
.photo-card:focus-visible .photo-info {
    opacity: 1;
}

.photo-info h3 {
    font-family: var(--serif);
    font-size: 25px;
    font-weight: 400;
}

.photo-info p {
    font-size: 10px;
    letter-spacing: 2px;
    text-transform: uppercase;
}


/* ABOUT THE PHOTOGRAPHER */

.about {
    display: grid;
    grid-template-columns: 1fr 1fr;
    align-items: center;
    gap: 8%;

    padding: 100px 8%;
    background: var(--sand);
}

.about img {
    width: 100%;
    height: 550px;
    object-fit: cover;
}

.about h2 {
    font-size: clamp(45px, 5vw, 75px);
}

.about p {
    margin: 22px 0;
    font-size: 15px;
    line-height: 1.9;
}

.about .note {
    font-family: var(--serif);
    font-size: 23px;
    font-style: italic;
    color: var(--forest);
}


/* CONTACT SECTION */

#contact {
    background: var(--forest);
    color: var(--cream);

    padding: 120px 8%;
    text-align: center;
}

#contact h2 {
    color: var(--cream);
}

#contact span {
    color: var(--sand);
}

#contact p {
    max-width: 500px;
    margin: 20px auto;
    font-size: 15px;
}

#contact .button {
    margin-top: 20px;
}

#contact .button:hover {
    background: var(--cream);
    color: var(--forest);
}


/* FOOTER */

footer {
    display: flex;
    justify-content: space-between;
    align-items: center;

    padding: 25px 6%;
    background: var(--charcoal);
    color: var(--cream);

    font-size: 10px;
    letter-spacing: 2px;
}


/* FULL-SCREEN PHOTO VIEWER */

#viewer {
    position: fixed;
    inset: 0;

    width: 100%;
    height: 100%;
    max-width: none;
    max-height: none;

    border: none;
    background: rgba(15, 15, 15, 0.98);
    color: white;
    padding: 50px 80px;
}

#viewer[open] {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

#viewer::backdrop {
    background: rgba(0, 0, 0, 0.95);
}

#large {
    max-width: 100%;
    max-height: 80vh;
    object-fit: contain;
}

#caption {
    margin-top: 20px;
    text-align: center;
    font-family: var(--serif);
    font-size: 25px;
}

#viewer button {
    position: absolute;

    background: transparent;
    border: none;
    color: white;

    font-size: 45px;
    padding: 10px 20px;

    transition: opacity 0.2s ease;
}

#viewer button:hover {
    opacity: 0.5;
}

#close {
    top: 15px;
    right: 20px;
}

#prev {
    left: 10px;
    top: 45%;
}

#next {
    right: 10px;
    top: 45%;
}


/* ANIMATIONS */

@keyframes fade-in {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

button:focus-visible,
a:focus-visible {
    outline: 2px solid var(--sage);
    outline-offset: 5px;
}


/* TABLET LAYOUT */

@media (max-width: 1000px) {

    #series-covers {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    #gallery {
        columns: 2;
    }

    .about {
        gap: 5%;
    }

    .about img {
        height: 450px;
    }
}


/* MOBILE LAYOUT */

@media (max-width: 650px) {

    header {
        flex-direction: column;
        gap: 20px;
        padding: 18px;
    }

    .brand {
        text-align: center;
        font-size: 24px;
    }

    nav {
        gap: 18px;
    }

    nav a {
        font-size: 10px;
        letter-spacing: 1px;
    }

    html {
        scroll-padding-top: 140px;
    }

    .hero {
        min-height: 75vh;
        padding: 7%;
    }

    .hero h1 {
        font-size: clamp(60px, 15vw, 100px);
    }

    .hero-copy span {
        font-size: 9px;
        letter-spacing: 2px;
    }

    #portfolio {
        padding: 65px 5%;
    }

    #series-covers {
        grid-template-columns: 1fr;
        gap: 20px;
        margin-bottom: 50px;
    }

    .series-card {
        aspect-ratio: 4 / 3;
    }

    #gallery {
        columns: 1;
    }

    .photo-info {
        opacity: 1;
    }

    .about {
        grid-template-columns: 1fr;
        padding: 60px 6%;
        gap: 35px;
    }

    .about img {
        height: 400px;
    }

    #contact {
        padding: 80px 6%;
    }

    footer {
        flex-direction: column;
        gap: 10px;
        text-align: center;
    }

    #viewer {
        padding: 60px 40px;
    }

    #viewer button {
        font-size: 35px;
        padding: 5px 10px;
    }

    #prev {
        left: 0;
    }

    #next {
        right: 0;
    }

    #caption {
        font-size: 20px;
    }
}


/* ACCESSIBILITY */

@media (prefers-reduced-motion: reduce) {

    html {
        scroll-behavior: auto;
    }

    *,
    *::before,
    *::after {
        animation: none !important;
        transition: none !important;
    }
}
