/*
Theme Name: Courtney Weddings Theme
Author: Courtney Creatives
Description: A bespoke, editorial WordPress theme.
Version: 1.0
*/

/* ==========================================================================
   Table of Contents
   ==========================================================================
   1. Reset
   2. Base Styles
   3. Header & Logo
   4. Navigation & Overlay
   5. Contact Trigger
   6. Footer
   7. Portrait Grid
   8. Portfolio Content Type
   ========================================================================== */


/* ==========================================================================
   1. Reset
   ========================================================================== */
*, *::before, *::after {
    box-sizing: border-box;
}
html, body {
    margin: 0;
    padding: 0;
    width: 100%;
    height: 100%;
}
main, section, article {
    display: block;
    margin: 0;
    padding: 0;
}
h3, p {
    margin: 0;
    padding: 0;
}
img {
    max-width: 100%;
    display: block; 
    height: auto;
}
a {
    text-decoration: none;
    color: inherit;
}


/* ==========================================================================
   2. Base Styles
   ========================================================================== */
html {
    scroll-behavior: smooth;
}
@media (prefers-reduced-motion: no-preference) {
    html {
        scroll-behavior: smooth;
    }
}
body {
    font-family: 'Inter Tight', sans-serif;
    font-weight: 300;
    color: #333;
    background-color: #fff;
}
section {
    scroll-margin-top: 80px;
}


/* ==========================================================================
   3. Header & Logo
   ========================================================================== */
#site-logo {
    position: fixed;
    top: 20px;
    left: 20px;
    z-index: 997;
    mix-blend-mode: difference;
    isolation: auto;
}
#site-logo a {
    color: #fff;
    font-family: 'Inter Tight', sans-serif;
    font-weight: 700;
    font-size: 1.2rem;
    text-transform: uppercase;
    text-decoration: none;
    line-height: 1;
    display: block;
}


/* ==========================================================================
   4. Navigation & Overlay
   ========================================================================== */
#menu-trigger {
    position: fixed;
    top: 85px;
    right: 20px;
    z-index: 998;
    background: none;
    border: none;
    color: #fff;
    font-weight: 700;
    font-size: 1.2rem;
    cursor: pointer;
    transform: rotate(90deg);
    transform-origin: top right;
    mix-blend-mode: difference;
    isolation: auto; 
}
#nav-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #000;
    z-index: 1000;
    display: flex;
    justify-content: center;
    align-items: center;
    visibility: hidden;
    transition: opacity 0.4s ease, visibility 0.4s;
    opacity: 0;
}
#nav-overlay.is-active {
    visibility: visible;
    opacity: 1;
    transition-delay: 0s; 
}
#nav-overlay:not(.is-active) {
    transition-delay: 0s, 0.4s;
}
#menu-close {
    position: absolute;
    top: 85px;
    right: 20px;
    z-index: 1001;
    background: none;
    border: none;
    color: #fff;
    mix-blend-mode: normal; 
    font-weight: 700;
    font-size: 1.2rem;
    cursor: pointer;
    transform: rotate(90deg);
    transform-origin: top right;
    padding: 0;
    line-height: 1;
}
#nav-overlay .nav-content {
    width: 90%;
    display: flex;
    justify-content: flex-end;
}
#nav-overlay ul {
    list-style: none;
    padding: 0;
    text-align: right;
    transition: transform 0.4s ease;
    transform: scale(0.95);
}
#nav-overlay.is-active ul {
    transform: scale(1);
}
#nav-overlay li a {
    opacity: 1;
    transition: opacity 0.4s ease;
    color: #fff;
    font-size: clamp(3rem, 12vh, 10rem);
    font-weight: 700;
    text-transform: uppercase;
    display: block;
    line-height: 0.9;
    padding: 10px 0;
    text-decoration: none;
    word-wrap: break-word;
}
@media (max-width: 768px) {
    #nav-overlay li a {
        font-size: 2.5rem;
        padding-left: 10px;
        padding-right: 10px;
    }
}
@media (hover: hover) {
    #nav-overlay ul:hover li a {
        opacity: 0.3;
    }
    #nav-overlay ul li a:hover {
        opacity: 1;
    }
}


/* ==========================================================================
   5. Contact Trigger
   ========================================================================== */
#contact-trigger {
    position: fixed;
    bottom: 50px;
    right: 10px;
    z-index: 996;
    background: none;
    border: none;
    color: #fff;
    font-weight: 700;
    font-size: 1.2rem;
    cursor: pointer;
    transform: rotate(90deg);
    transform-origin: top right;
    mix-blend-mode: difference;
    transition: opacity 0.4s ease;
    isolation: auto;
}
#contact-trigger.fade-out {
    opacity: 0;
    pointer-events: none;
}


/* ==========================================================================
   6. Footer
   ========================================================================== */
#site-footer {
    padding: 100px 20px 20px;
    background: #fff;
    color: #000;
    text-transform: uppercase;
    font-weight: 700;
}
.footer-inner {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    flex-wrap: wrap;
    gap: 40px;
}
.footer-left {
    display: flex;
    flex-direction: column;
    transition: opacity 0.3s ease;
}
.footer-left a {
    display: block;
    color: #000;
    text-decoration: none;
    font-size: 3rem;
    line-height: 1.2;
    transition: opacity 0.3s ease;
    opacity: 1;
    text-transform: uppercase;
}
.footer-left:hover a {
    opacity: 0.3;
}
.footer-left:hover a:hover {
    opacity: 1;
}
.footer-right p {
    font-size: 1rem;
    line-height: 1.2;
    margin: 0;
    text-align: right;
    text-transform: uppercase;
}
@media (max-width: 768px) {
    .footer-inner {
        flex-direction: column;
        align-items: flex-start;
        gap: 20px;
    }
    .footer-right p {
        text-align: left;
    }
    .footer-left a {
        font-size: 2rem;
    }
}


/* ==========================================================================
   7. Portrait Grid
   ========================================================================== */
.portrait-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0;
    width: 100%;
}
@media (min-width: 1024px) {
    .portrait-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}
@media (min-width: 1440px) {
    .portrait-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}
.grid-item {
    position: relative;
    width: 100%;
    overflow: hidden;
    display: block;
    aspect-ratio: 2 / 3;
}
.grid-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    display: block;
    transition: transform 0.6s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}
.card-link {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10;
}
.hover-content {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    padding: 30px 20px 20px;
    background: linear-gradient(to top, rgba(0,0,0,0.85) 0%, rgba(0,0,0,0) 100%);
    color: #fff;
    opacity: 0;
    transition: opacity 0.4s ease;
    pointer-events: none;
    z-index: 5;
}
@media (hover: hover) {
    .grid-item:hover img {
        transform: scale(1.08);
    }
    .grid-item:hover .hover-content {
        opacity: 1;
    }
}



/* ==========================================================================
   8. Portfolio Content Type
   ========================================================================== */
.portfolio-page {
    padding-top: 100px;
}
.max-width-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 40px;
}
.portfolio-header {
    margin-bottom: 60px;
}
.portfolio-header h1 {
    max-width: 500px;
    font-size: 2rem;
    text-transform: uppercase;
    margin-bottom: 10px;
}
.portfolio-subtitle {
    font-size: 1.2rem;
    margin-bottom: 20px;
    font-weight: 600;
}
.portfolio-wysiwyg {
    max-width: 700px;
    font-size: 1rem;
    line-height: 1.6;
    color: #555;
}
.portfolio-page .portrait-grid {
    grid-template-columns: 1fr;
    gap: 30px;
}
@media (min-width: 1024px) {
    .portfolio-page .portrait-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}
.portfolio-page .grid-item img {
    transition: none;
}
.portfolio-page .grid-item:hover img {
    transform: none;
}
