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

body {
    font-family: 'Arial', sans-serif;
    background-color: #f8f8f8;
    color: #333;
    line-height: 1.6;
    overflow-x: hidden;
}

/* Full-screen alternating background sections */
.bg-section {
    width: 100vw;
    height: 100vh;
    position: absolute;
    top: 0;
    left: 0;
    transition: opacity 0.8s ease-in-out;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

.bg-section.active {
    opacity: 1;
    z-index: 1;
}

.bg-section.inactive {
    opacity: 0;
    z-index: 0;
}

.bg-light {
    background-image: url('assets/Back1.jpg');
}

.bg-dark {
    background-image: url('assets/Back2.webp');
}

.bg-warm {
    background-image: url('assets/Back3.jpg');
}

.bg-cool {
    background-image: url('assets/Back4.jpg');
}

/* Background container that holds all alternating sections */
.background-container {
    height: 100vh;
    width: 100vw;
    position: relative;
    overflow: hidden;
}

/* Header */
header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: transparent;
    z-index: 1000;
    padding: 20px 0;
    transition: opacity 0.3s ease;
    opacity: 1;
}

header.hidden {
    opacity: 0;
    pointer-events: none;
}

header .logo,
.menu-button {
    color: white;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
    transition: color 0.3s ease;
}

.header-content {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    padding: 0 40px;
    position: relative;
}

.logo {
    text-decoration: none;
    display: flex;
    align-items: center;
    justify-content: center;
}

.logo-image {
    height: 87px;
    width: auto;
    filter: brightness(0) invert(1);
    transition: opacity 0.3s ease;
}

.logo-image:hover {
    opacity: 0.8;
}

/* Menu Button */
.menu-button {
    position: absolute;
    right: 40px;
    background: none;
    border: none;
    color: white;
    cursor: pointer;
    padding: 12px;
    transition: all 0.3s ease;
    width: 48px;
    height: 48px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 4px;
}



/* Hamburger icon lines */
.menu-button::before,
.menu-button::after,
.menu-button span {
    content: '';
    display: block;
    width: 20px;
    height: 2px;
    background-color: white;
    transition: all 0.3s ease;
    border-radius: 1px;
}

.menu-button span {
    width: 20px;
    height: 2px;
    background-color: white;
    border-radius: 1px;
}

/* Menu Popup Overlay */
.menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(20px);
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.4s ease;
}

.menu-overlay.active {
    opacity: 1;
    visibility: visible;
}

/* Menu Popup */
.menu-popup {
    background: transparent;
    padding: 60px 80px;
    text-align: center;
    transform: scale(0.8) translateY(50px);
    transition: all 0.4s ease;
    position: relative;
    max-width: 500px;
    width: 90%;
}

.menu-overlay.active .menu-popup {
    transform: scale(1) translateY(0);
}

/* Close Button */
.close-button {
    position: absolute;
    top: 20px;
    right: 20px;
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: white;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.close-button:hover {
    background: rgba(0, 0, 0, 0.1);
    transform: rotate(90deg);
}

/* Menu Items */
.menu-items {
    list-style: none;
}

.menu-items li {
    margin: 30px 0;
}

.menu-items a {
    text-decoration: none;
    font-size: 24px;
    font-weight: 300;
    color: white;
    letter-spacing: 2px;
    transition: all 0.3s ease;
    position: relative;
    display: inline-block;
    padding: 10px 20px;
    border-radius: 10px;
}

.menu-items a:hover {
    transform: translateY(-3px);
}

/* Main Content - appears after scroll */
.content-section {
    background-color: #f8f8f8;
    min-height: 100vh;
    position: relative;
    z-index: 10;
}

main {
    padding: 60px 40px 40px;
    max-width: 1400px;
    margin: 0 auto;
    position: relative;
}

.hero-text {
    font-size: 24px;
    font-weight: 300;
    line-height: 1.4;
    margin-bottom: 80px;
    max-width: 600px;
    color: #555;
}

/* Project Grid */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 60px 40px;
}

/* Updated Project Item Styling for Links */
.project-item {
    cursor: pointer;
    transition: transform 0.4s ease, opacity 0.3s ease;
    text-decoration: none;
    color: inherit;
    display: block;
}

.project-link {
    text-decoration: none;
    color: inherit;
}

.project-item:hover {
    transform: translateY(-5px);
    opacity: 0.9;
}

.project-image {
    width: 100%;
    height: 300px;
    background-color: #ddd;
    background-size: cover;
    background-position: center;
    margin-bottom: 20px;
    transition: filter 0.3s ease;
}

.project-item:hover .project-image {
    filter: brightness(1.05);
}

.project-title {
    font-size: 16px;
    font-weight: 400;
    letter-spacing: 0.5px;
    color: #333;
    text-decoration: none;
}

.project-link:hover .project-title {
    color: #555;
}

/* Project Images */
.red-rock { 
    background-image: url('assets/About.png');
    background-size: cover;
    background-position: center;
}
.miner-road { 
    background-image: url('assets/Services.webp');
    background-size: cover;
    background-position: center;
}
.campout { 
    background-image: url('assets/Suppliers.jpg');
    background-size: cover;
    background-position: center;
}
.big-barn { 
    background-image: url('assets/Products.jpg');
    background-size: cover;
    background-position: center;
}
.noe-valley { 
    background-image: url('assets/aboutI2.png');
    background-size: cover;
    background-position: center;
}
.long-bay { 
    background-image: url('assets/Contact.png');
    background-size: cover;
    background-position: center;
}


/* Mobile Responsiveness */
@media (max-width: 768px) {
    .header-content {
        padding: 0 20px;
    }

    .menu-button {
        right: 20px;
    }

    .back-home {
        left: 20px;
        padding: 10px 20px;
        font-size: 12px;
    }

    .menu-popup {
        padding: 40px 30px;
        margin: 20px;
    }

    .menu-items a {
        font-size: 20px;
    }

    main {
        padding: 40px 20px 20px;
    }

    .page-content {
        padding: 100px 20px 40px;
    }

    .page-title {
        font-size: 36px;
    }

    .hero-text {
        font-size: 20px;
        margin-bottom: 60px;
    }

    .projects-grid {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .content-grid {
        grid-template-columns: 1fr;
        gap: 30px;
    }

    .content-card {
        padding: 30px 20px;
    }

    .project-image {
        height: 250px;
    }
}

/* Smooth scrolling */
html {
    scroll-behavior: smooth;
}

/* Loading animation */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in {
    animation: fadeInUp 0.8s ease forwards;
}

.fade-in-delay {
    opacity: 0;
    animation: fadeInUp 0.8s ease forwards;
}

.fade-in-delay:nth-child(1) { animation-delay: 0.1s; }
.fade-in-delay:nth-child(2) { animation-delay: 0.2s; }
.fade-in-delay:nth-child(3) { animation-delay: 0.3s; }
.fade-in-delay:nth-child(4) { animation-delay: 0.4s; }
.fade-in-delay:nth-child(5) { animation-delay: 0.5s; }
.fade-in-delay:nth-child(6) { animation-delay: 0.6s; }