/* Base Reset & Variables */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --bg-color: #fbfaf8; /* Warm off-white */
    --text-color: #222222;
    --accent-color: #5a5a5a;
    --font-heading: 'Playfair Display', serif;
    --font-body: 'Inter', sans-serif;
}

html {
    scroll-behavior: smooth;
}

body {
    background-color: var(--bg-color);
    color: var(--text-color);
    font-family: var(--font-body);
    line-height: 1.6;
    overflow-x: hidden;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

/* Typography Overrides for Headers */
h1, h2, h3, h4, .logo {
    font-family: var(--font-heading);
    font-weight: 400;
}

/* Navbar */
.logo-numbers {
    font-family: 'Inter', sans-serif;
    font-weight: 500; 
    letter-spacing: 0px; 
}

.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    background-color: rgba(251, 250, 248, 0.95);
    backdrop-filter: blur(5px);
    z-index: 1000;
    padding: 1.5rem 0;
    border-bottom: 1px solid rgba(0,0,0,0.05);
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    text-decoration: none;
    color: var(--text-color);
    font-size: 1.5rem;
    letter-spacing: 2px;
}

.nav-links {
    list-style: none;
    display: flex;
    gap: 2rem;
}

.nav-links a {
    text-decoration: none;
    color: var(--text-color);
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: color 0.3s ease;
}

.nav-links a:hover {
    color: #888;
}

/* Mobile Hamburger Menu */
.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
    gap: 5px;
}

.hamburger span {
    width: 25px;
    height: 2px;
    background-color: var(--text-color);
    transition: all 0.3s ease;
}

/* Hero Section - Desktop */
.hero {
    position: relative;
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 0 2rem;
    overflow: hidden; /* Keeps the video from spilling out */
}

/* Styled Container Frame for the Hero Video */
.hero-video-container {
    position: absolute;
    top: 90px; 
    left: 50%;
    transform: translateX(-50%); 
    width: 95%; 
    height: calc(100% - 120px); 
    z-index: -1;
    border-radius: 30px; 
    overflow: hidden; 
    box-shadow: 0 15px 50px rgba(0, 0, 0, 0.1); 
    -webkit-mask-image: radial-gradient(white, black);
    mask-image: radial-gradient(white, black);
}

/* This applies the exact same massive scaling math to BOTH the video and the image */
.hero-video-container iframe,
.hero-video-container .fallback-img {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 100vw;
    height: 56.25vw;
    min-height: 100vh;
    min-width: 177.77vh; 
    transform: translate(-50%, -50%);
    pointer-events: none; 
    object-fit: cover; /* Ensures the image fills the space correctly */
}

/* Keep the fade-in strictly on the iframe */
.hero-video-container iframe {
    opacity: 0; 
    transition: opacity 0.4s ease; 
}

.hero-content {
    z-index: 1;
    color: #f6f5f1; /* White/Cream text for contrast */
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.hero-title-top, .hero-title-bottom {
    font-size: clamp(2rem, 4vw, 4.5rem); /* Made the max size smaller for desktop */
    line-height: 1.05;
    text-transform: uppercase;
    letter-spacing: -1px;
    font-family: var(--font-heading);
    font-weight: 400;
}

/* General Section Styles */
section {
    padding: 6rem 0;
}

.section-title {
    font-size: clamp(2rem, 4vw, 3.5rem);
    margin-bottom: 2rem;
    text-align: center;
}

/* About Section */
.about-logo {
    display: block;
    margin: 0 auto 1.5rem auto; /* Centers the logo and adds space below it */
    max-width: 80px; /* Keeps it small and elegant; adjust this number if needed */
    height: auto; /* Ensures the image doesn't stretch weirdly */
}

.about-text {
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
    font-size: 1.2rem;
    color: var(--accent-color);
}

/* Video Work Section */
.category-title {
    font-family: var(--font-heading);
    font-size: 1.5rem; /* Makes the title significantly bigger */
    margin-top: 5rem; /* Creates a large, elegant gap between the previous collection and this new title */
    margin-bottom: 1.5rem; /* Space between the title and its own videos below */
}

/* This keeps the very FIRST category from being pushed too far down from your main heading */
.category-title:first-of-type {
    margin-top: 2rem; 
}

.video-card {
    display: flex;
    flex-direction: column;
}

/* Container for 16:9 Video Embeds */
.video-embed-placeholder {
    position: relative;
    width: 100%;
    padding-top: 56.25%; /* 16:9 Aspect Ratio */
    background-color: #e8e6e1;
    margin-bottom: 1.5rem;
}

.video-embed-placeholder iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
}

.placeholder-text {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    color: #999;
    font-family: var(--font-body);
    font-size: 0.9rem;
    letter-spacing: 1px;
}

.video-info {
    text-align: left;
}

.couple-name {
    font-family: 'Inter', system-ui, -apple-system, sans-serif; 
    font-size: 1.2rem; 
    font-weight: 500; /* Medium weight looks incredibly clean in Inter */
    letter-spacing: 0.5px;
    margin-top: 0.75rem; 
    color: #333333; 
}

.video-desc {
    font-style: italic; /* This turns the description text into italics */
    font-size: 0.9rem;  /* Slightly scales down the text size */
    color: #666666;     /* Mutes the color slightly so it doesn't distract from the title */
    margin-top: 0.25rem; /* Adds a tiny bit of space between the couple's name and this description */
}

/* Contact Section */
.contact-subtitle {
    text-align: center;
    margin-bottom: 4rem;
    font-size: 1.1rem;
    color: var(--accent-color);
}

.contact-options {
    display: flex;
    flex-direction: column; /* Stacks the cards on top of each other for mobile */
    gap: 2rem;
    max-width: 900px;
    margin: 0 auto;
}

.contact-card {
    flex: 1;
    background-color: transparent;
    border: 1px solid rgba(0,0,0,0.1); /* Very subtle, elegant border */
    padding: 3rem 2rem;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    transition: transform 0.4s ease, box-shadow 0.4s ease, border-color 0.4s ease;
}

/* Soft hover effect to make the cards feel interactive */
.contact-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.04);
    border-color: rgba(0,0,0,0.2);
}

.contact-card h3 {
    font-size: 1.8rem;
    margin-bottom: 1rem;
    font-style: italic; /* Ties into your subheaders */
}

.contact-card p {
    color: var(--accent-color);
    margin-bottom: 2.5rem;
    font-size: 0.95rem;
    max-width: 300px;
}

/* Updated Button Styles to support links and secondary styling */
.btn {
    padding: 1rem 2rem;
    background-color: var(--text-color);
    color: var(--bg-color);
    border: 1px solid var(--text-color);
    font-family: var(--font-body);
    text-transform: uppercase;
    letter-spacing: 2px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none; /* Required so 'a' tags look like buttons */
    display: inline-block;
    font-size: 0.9rem;
}

.btn:hover {
    background-color: #444;
    border-color: #444;
}

/* Secondary "Ghost" button for the email option */
.btn-outline {
    background-color: transparent;
    color: var(--text-color);
}

.btn-outline:hover {
    background-color: var(--text-color);
    color: var(--bg-color);
}

/* Footer */
footer {
    background-color: var(--text-color);
    color: var(--bg-color);
    padding: 4rem 0;
    text-align: center;
}

.logo-footer {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    letter-spacing: 2px;
    margin-bottom: 1rem;
}

.footer-copy {
    font-size: 0.8rem;
    opacity: 0.7;
}

/* Footer Link Styling */
.footer-content a {
    color: var(--bg-color); /* Changes it to your warm off-white */
    text-decoration: none; /* Removes the default underline */
    font-size: 0.85rem; /* Makes it smaller and more delicate */
    text-transform: uppercase; 
    letter-spacing: 2px; /* Adds elegant spacing between letters */
    opacity: 0.7; /* Matches the slightly muted look of your copyright text */
    transition: opacity 0.3s ease; /* Smooth transition for the hover effect */
    display: inline-block;
    margin-bottom: 1rem;
}

/* Adds a soft glowing effect when someone hovers over it */
.footer-content a:hover {
    opacity: 1; 
}

/* Animation Classes */
.section-reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.section-reveal.active {
    opacity: 1;
    transform: translateY(0);
}

/* The Horizontal Scrolling Track */
.video-carousel {
    display: flex !important;
    flex-direction: row !important;
    flex-wrap: nowrap !important; /* Forces cards on ONE single row */
    overflow-x: auto !important; /* Enables horizontal swiping */
    overflow-y: hidden;
    gap: 2rem; /* Nice clean spacing between cards */
    padding-bottom: 2rem; 
    width: 100%;
    
    /* App-like scroll snapping layout rules */
    scroll-snap-type: x mandatory; 
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none; /* Firefox */
    -ms-overflow-style: none; /* IE/Edge */
}

/* Hides scrollbars for Chrome/Safari */
.video-carousel::-webkit-scrollbar {
    display: none; 
}

/* Individual Video Cards - Base Width Configurations */
.video-card {
    flex: 0 0 85% !important; 
    width: 85% !important;
    min-width: 85% !important; /* Bulletproof lock to prevent iframes from crushing the container width */
    scroll-snap-align: start; 
    box-sizing: border-box;
}

/* Media Queries for Tablets and Laptops */
@media (min-width: 768px) {
    /* Side-by-side Contact Cards */
    .contact-options {
        flex-direction: row;
        gap: 3rem;
    }

    /* Video Card layout adjustments for screens larger than Mobile */
    .video-card {
        flex: 0 0 40% !important; 
        width: 40% !important;
        min-width: 40% !important;
    }
}

/* Mobile-Specific Overrides (Max-Width Screen Boundary Rules) */
@media (max-width: 768px) {
    .hamburger {
        display: flex;
    }

    .nav-links {
        position: absolute;
        top: 100%;
        left: -100%;
        width: 100%;
        height: 100vh;
        background-color: var(--bg-color);
        flex-direction: column;
        align-items: center;
        padding-top: 4rem;
        transition: left 0.3s ease;
    }

    .nav-links.nav-active {
        left: 0;
    }

    .nav-links li {
        margin-bottom: 2rem;
    }

    .nav-links a {
        font-size: 1.2rem;
    }

    /* Hamburger Animation Configuration rules */
    .toggle .line1 { transform: rotate(-45deg) translate(-5px, 5px); }
    .toggle .line2 { opacity: 0; }
    .toggle .line3 { transform: rotate(45deg) translate(-5px, -5px); }

    /* Mobile Hero Structural Split Optimization */
    .hero {
        height: auto;
        min-height: 100vh;
        padding: 160px 0 3rem 0;
        flex-direction: column;
        justify-content: flex-start; 
        gap: 2rem;
    }

    .hero-content {
        display: contents; /* Allows pure re-ordering control */
    }

    .hero-title-top {
        order: 1;
        padding: 0 2rem;
        color: var(--text-color); /* Swapped back to dark theme text for mobile */
    }

    /* Mobile Iframe Hero Frame Config */
    .hero-video-container {
        order: 2;
        position: relative;
        top: 0; 
        left: 0; 
        transform: none; 
        width: 90%; 
        margin: 0 auto; 
        aspect-ratio: 16 / 9; /* The cleanest, most foolproof way to lock a widescreen shape */
        height: auto; 
        z-index: 1;
        border-radius: 24px; 
        overflow: hidden; 
        box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08); 
        -webkit-mask-image: radial-gradient(white, black);
        mask-image: radial-gradient(white, black);
    }

    /* Resets both the image and the video so they fit perfectly in the mobile card */
    .hero-video-container iframe,
    .hero-video-container .fallback-img {
        position: absolute !important;
        top: 0 !important;
        left: 0 !important;
        width: 100% !important;
        height: 100% !important;
        min-width: 0 !important;  
        min-height: 0 !important; 
        transform: none !important; 
        object-fit: cover !important;
    }

    .hero-title-bottom {
        order: 3;
        padding: 0 2rem;
        color: var(--text-color); /* Swapped back to dark theme text for mobile */
    }

    .hero-title-top, .hero-title-bottom {
        font-size: clamp(2.5rem, 10vw, 4rem); 
        letter-spacing: -2px;
    }
}