/* ============================================== */
/* === GLOBAL & BASE STYLES === */
/* ============================================== */

/* Base setup for the entire page */
body {
    background-color: #F0F8FA; /* Soft cream background */
    color: #333; /* Default text color */
}

/* Ensure main content inherits the soft background and centers content */
main {
    background-color: #F0F8FA;
    text-align: center; /* Ensures h1, h2, and p tags centered by default */
}

/* --- Navigation Styles --- */
.main-nav {
    /* ADDED: Required for mobile-only positioning of the hamburger button */
    position: relative; 
    background-color: #333;
}

.main-nav ul {
    list-style-type: none;
    margin: 0;
    padding: 0;
    /* Background color moved to .main-nav for cleaner mobile button styling */
    overflow: hidden;
    display: flex;
    justify-content: center;
    width: 100%;
}

.main-nav li {
    display: block;
}

.main-nav li a {
    display: block;
    color: white;
    text-align: center;
    padding: 14px 16px;
    text-decoration: none;
}

.main-nav li a:hover {
    background-color: #0E6963; /* Teal hover */
}

/* Style for the header icon list item */
.main-nav ul .social-icon-header {
    /* FIX 3: Remove the 'margin-left: auto' that was pushing it to the far right */
    margin-left: 10px; /* Add a small margin to separate it from the last link */
    
    /* Keep it in line with the text links */
    line-height: 48px; /* Match the height of the standard navigation links */
}

/* Ensures the icon itself is white and stands out */
.main-nav ul .social-icon-header a {
    font-size: 1.5em; 
    padding: 0 10px;
    color: white; 
}

/* Hover effect for the Instagram icon in the header */
.main-nav ul .social-icon-header a:hover {
    color: #0E6963; 
    background-color: transparent; 
}

/* --- HAMBURGER MENU ADDITIONS (Desktop Hidden) --- */

.menu-toggle {
    display: none; /* Hide button by default on desktop */
    background: none;
    border: none;
    color: white;
    font-size: 30px;
    cursor: pointer;
    padding: 10px 15px;
    line-height: 1;
}

/* Class added by JS to show the menu */
.main-nav ul.is-open {
    display: flex !important; /* Forces the menu to show when toggled */
/* FIX: Make the menu drop down from the fixed header bar */
    position: fixed; /* Fixed so it stays over the content */
    top: 50px; /* Starts exactly below the 50px fixed header */
    left: 0;
    width: 100%;
    height: auto; /* Menu height collapses to content size */
    max-height: calc(100vh - 50px); /* Limits size to the screen */
    overflow-y: auto; /* Allows scrolling if links exceed screen height */
    
    /* Reset padding/margins from previous fixes */
    margin-top: 0;
    padding-top: 0; 
    
    z-index: 99;
}

/* --- Footer Styles --- */
footer {
	padding: 20px 0;
	text-align: center;
	background-color: #333;
	color: white;
}

footer p {
	margin: 0;
}

/* Container to help structure content within the footer */
.footer-content {
    max-width: 1200px; /* Keep consistent with main content width */
    margin: 0 auto;
    padding: 0 20px;
}

/* Style the social links section in the footer */
.social-links-footer {
    margin-top: 10px;
    padding-top: 10px;
    /* Adds a subtle line above the social link for separation */
    border-top: 1px solid rgba(255, 255, 255, 0.2); 
}

/* Style for the actual link in the footer */
.social-links-footer a {
    text-decoration: none;
    color: white; 
    font-size: 1.1em;
    transition: color 0.2s;
}

/* Hover effect to use your teal brand color */
.social-links-footer a:hover {
    color: #0E6963; 
}

/* Style for the icon within the footer link to give it a space */
.social-links-footer i {
    margin-right: 5px;
}

/* --- Call-to-Action (CTA) Button Styles --- */

/* **GLOBAL CTA DEFAULT** - All cta-buttons and store-links use this style */
.cta-button, .store-link {
    display: inline-block;
    padding: 10px 20px;
    background-color: #1a1a1a; /* Dark Grey background */
    color: white;
    text-decoration: none;
    border-radius: 5px;
    font-weight: bold;
    margin-top: 10px;
    /* Ensures buttons are handled correctly by the centering rules */
}

.cta-button:hover, .store-link:hover {
    background-color: #0E6963; /* Teal hover */
}

/* ============================================== */
/* === HOME PAGE SPECIFIC STYLES === */
/* ============================================== */

/* --- Hero Content --- */
main > h1 {
    margin-top: 25px; 
    margin-bottom: 5px;
	color: #0E6963;
	font-size: 38px;
}

main > h2 {
    margin-top: 0; 
    margin-bottom: 10px;
	color: #333;
}

main > p {
    margin-top: 0;
    margin-bottom: 15px;
}

/* --- Common Section Containers --- */
.value-proposition,
.product-spotlights,
.custom-process-summary {
    padding: 20px 20px;
    margin: 15px auto;
    max-width: 1200px;
}

/* --- Value Proposition Styles --- */
.value-proposition {
    display: flex;
    justify-content: space-around;
    gap: 25px;
}

.value-item {
    flex-basis: 30%;
    padding: 15px;
    border-radius: 8px;
    background-color: #FFFFFF;
    text-align: center;
}

.value-item h3 {
    color: #0E6963;
    margin-top: 0;
}

/* --- Product Spotlight Styles --- */
.product-spotlights h2 {
    margin-bottom: 30px;
	margin-top: 2px;
}

.spotlight-items {
    display: flex;
    flex-wrap: wrap; 
    justify-content: space-around;
    gap: 5px;
	background: #FFFFFF;
}

/* FIX: Added Flexbox and **Re-introduced fixed image height** for uniformity. */
.spotlight-item {
    flex-basis: calc((100% - 50px) / 3);
    display: flex;
    flex-direction: column;
    
    padding: 5px 5px 20px 5px;
    border: 1px solid #ddd;
    border-radius: 8px;
    text-align: center;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1); 
}

.spotlight-item img {
    width: 100%;
	transition: transform 0.3s ease, opacity 0.3s ease;
    height: 500px; /* FIX: **RESTORED FIXED HEIGHT** for uniform card appearance */
    object-fit: cover;
    border-radius: 4px;
    margin-bottom: 20px;
}

.spotlight-item .spotlight-image-link:hover img {
	transform: scale(1.03);
	opacity: 0.9;
}

.spotlight-item h3 {
	color: #0E6963;
}

/* Push CTA buttons to the bottom of the flex column */
.spotlight-item .cta-button {
    margin-top: auto;
}


/* --- Custom Process Summary Styles --- */
.custom-process-summary {
    background-color: #FFFFFF; 
    border-radius: 8px;
	padding-top: 2px;
}

.custom-process-summary h2 {
    margin-bottom: 0;
}

.process-steps {
    display: flex;
    justify-content: space-around;
    gap: 20px;
    margin-bottom: 0;
}

.process-step {
    flex-basis: 30%;
    padding: 10px;
    text-align: center;
}

.process-step h3 {
    color: #0E6963;
}

.custom-process-summary .cta-button {
    font-size: 1.1em;
}


/* ============================================== */
/* === GALLERY SPECIFIC STYLES === */
/* ============================================== */

.photo-gallery {
    display: grid; 
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px; 
    padding: 20px 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.gallery-item {
    border: 1px solid #ddd;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    text-align: center;
    padding-bottom: 10px;
	background-color: #FFFFFF;
    
    display: flex;
    flex-direction: column;
}

.gallery-item a {
    display: block;
}

.gallery-item img {
    width: 100%; 
    height: 400px;
    object-fit: cover; 
    display: block;
    margin-bottom: 10px;
}

.gallery-item p {
    margin: 0;
    padding: 5px;
    font-weight: bold;
    background-color: #FFFFFF;
    margin-top: auto;
}


/* ============================================== */
/* === POP-OUT/MODAL STYLES (CSS :target) === */
/* ============================================== */

/* Base style for the hidden pop-out modal */
.image-popout {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    z-index: 1000;
    
    display: flex;
    justify-content: center;
    align-items: center;
    
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease-in-out; 
}

/* Show the pop-out when targeted by the URL (#id) */
.image-popout:target {
    opacity: 1;
    pointer-events: auto;
}

/* Styling for the large image inside the pop-out */
.image-popout img {
    /* KEY CHANGE: Set position context for controls to be relative to the image */
    position: relative; 
    
    width: auto;
	max-width: 90%;
    max-height: 90%;
    object-fit: contain;
    border: 5px solid white;
	display: inline-block;
    
    /* Zoom effect styles are handled by JavaScript setting the 'transform' */
    transform: scale(1.0); /* Base size set by JS on reset */
    transition: transform 0.3s ease-in-out; 
    transform-origin: center center;
}

/* Styling for the image when it is zoomed to indicate panning is possible */
.image-popout img.can-pan {
    cursor: grab;
}

/* Close button style */
.popout-close {
    position: fixed;
    top: 20px;
    right: 30px;
    font-size: 40px;
    text-decoration: none;
    color: white;
    line-height: 1;
    font-family: Arial, sans-serif;
}

.popout-close:hover {
    color: #0E6963;
}

.image-popout.is-visible {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

/* ============================================== */
/* === POP-OUT ZOOM CONTROLS STYLES (NEW) === */
/* ============================================== */

/* Container for the buttons - Now positioned RELATIVE to the image itself's placement */
.popout-controls {
    /* Absolute positioning relative to the pop-out container (which is centered) */
    position: absolute; 
    
    /* NEW: Adjusting the position to visually align with the bottom-right corner of the image */
    /* This will require you to slightly test the values based on your image sizes. */
    /* These values are a good starting point to bring it closer to the image corner. */
    bottom: 5%; 
    right: 5%;
    
    /* Ensure the controls are always visible on top */
    z-index: 1010; 
    display: flex;
    gap: 10px;
}

/* Individual button styling */
.popout-controls button {
    background-color: rgba(0, 0, 0, 0.5); /* Semi-transparent background */
    color: white;
    border: 1px solid white;
    border-radius: 5px;
    width: 40px;
    height: 40px;
    font-size: 20px;
    line-height: 1;
    cursor: pointer;
    transition: background-color 0.2s;
    font-weight: bold;
    padding: 0;
}

.popout-controls button:hover {
    background-color: #0E6963; /* Teal hover */
    border-color: #0E6963;
}


/* ============================================== */
/* === ABOUT US SPECIFIC STYLES === */
/* ============================================== */

/* Main container and section styles */
.about-intro, 
.family-passion-section, 
.mission-statement,
.made-in-america-section,
.custom-solution-section {
    max-width: 900px;
    margin: 30px auto;
    padding: 0 20px;
    /* FIX: Removed explicit 'text-align: left;' to let content inherit center alignment */
}

/* Make the lead paragraph stand out */
.lead-paragraph {
    font-size: 1.15em;
    font-style: italic;
    color: #333;
    text-align: center;
}

/* Highlight text for key mission statement */
.highlight-text {
    font-size: 1.1em;
    font-weight: bold;
    color: #0E6963;
    padding: 10px 0;
    display: block;
    text-align: center;
}

/* Two Column Layout for Family Passion Section */
.two-column-flex {
    display: flex;
    gap: 30px;
    margin-top: 20px;
    text-align: left; /* Keep text left-aligned inside columns for better readability */
	background-color: #FFFFFF;
}

.two-column-flex .column-text {
    flex: 1;
    padding: 15px;
    border-left: 3px solid #0E6963;
}

/* Center main section headings */
.family-passion-section h2, 
.mission-statement h2,
.made-in-america-section h2,
.custom-solution-section h2 {
    text-align: center;
    color: #0E6963;
    margin-bottom: 20px;
}

.family-passion-section h3 {
    color: #0E6963;
}

/* ============================================== */
/* === MISC ORDERS PAGE STYLES (UPDATED) === */
/* ============================================== */

/* Styles for the custom order link to the contact page */
.contact-link {
    font-style: italic;
    font-weight: bold;
    color: #007bff;
    text-decoration: underline;
}

/* NEW: Wrapper to contain and center all content on the orders page for consistency */
.orders-content-wrapper {
    max-width: 900px; 
    margin: 30px auto;
    padding: 0 20px;
}

/* UPDATED: Styles for the main sections to add visual interest (less bland) */
.inventory-purchase,
.custom-orders,
.shop-policies,
.local-delivery { /* ADDED: .local-delivery to inherit white box styling */
    background-color: #FFFFFF;
    padding: 20px 30px 30px 30px; 
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1); 
    margin: 30px 0; 
    text-align: center;
}

/* NEW: Eliminates the default top margin on the H2 inside the section box. */
.inventory-purchase h2,
.custom-orders h2,
.shop-policies h2,
.shop-policies h3,
.local-delivery h2 { /* ADDED: .local-delivery h2 */
    margin-top: 0; 
    text-align: center; 
}

/* Ensure H3 still has some bottom margin for separation */
.shop-policies h3 {
    margin-bottom: 5px;
    margin-top: 20px;
    color: #0E6963;
}

/* NEW: Keep all paragraphs centered as requested */
.inventory-purchase p,
.custom-orders p,
.shop-policies p,
.local-delivery p { /* ADDED: .local-delivery p */
    text-align: center;
}

/* NEW: Fix the bullet point alignment issue by containing, centering the list block, and setting the list text back to left-align */
.inventory-purchase ul,
.shop-policies ul {
    max-width: 600px;
    margin: 20px auto; 
    padding-left: 20px;
    text-align: left;
}


/* ============================================== */
/* === MEDIA QUERIES (RESPONSIVENESS) === */
/* ============================================== */

/* Tablet/Mobile Styles */
@media (max-width: 800px) {
    /* Home Page Flex Stacking (already existed, but good to check) */
    .value-proposition,
    .spotlight-items, 
    .process-steps {
        flex-direction: column;
        align-items: center;
    }

    .value-item,
    .spotlight-item, 
    .process-step {
        flex-basis: 90%; 
        max-width: 400px; 
    }
    
    /* --- NEW HAMBURGER MENU STYLES (Mobile View) --- */
    
    /* 1. Show the hamburger button on mobile */
    .menu-toggle {
        display: block; 
        color: white
        /* Position the button inside the nav bar, aligned left */
        position: absolute;
        left: 0px; /* **FIXED POSITION:** Moved to the left side */
        /* Center the button vertically within the nav bar's implied space */
        top: 45%;
      /*  transform: translateY(-50%);
        z-index: 100; /* Ensure button is on top */
        padding: 10px; /* Adjust padding for better click target */
    }
	/* Color change for the button when the menu is active (expanded) */
    .menu-toggle[aria-expanded="true"] {
        color: white; 
    }

    /* 2. Hide the navigation list by default on mobile */
	.main-nav {
		position: fixed; 
		top: 0px;
		left: 0;
		width: 100%;
		height: 50px; /* Fixed height for the bar */
		z-index: 101; /* Ensure it is on top of everything */
}

	
	.main-nav ul {
        display: none; 
        width: 100%;
        background-color: #333; 
        
        /* Navigation Stacking */
        flex-direction: column;
        align-items: center; /* Center the stacked links */
    }
    
    .main-nav li {
        width: 100%;
        text-align: center;
        border-bottom: 1px solid #444; /* Optional separator for clarity */
    }

	
    .main-nav li:last-child {
        border-bottom: none;
    }

    .main-nav li a {
        padding: 12px 20px; /* Slightly more vertical padding for easier tapping */
    }
    
    .main-nav ul .social-icon-header {
        line-height: 1; /* Reset line-height */
        margin: 10px 0; /* Add vertical margin for spacing */
    }
    /* --- END HAMBURGER MENU STYLES --- */

    /* NEW: Home Page Image Height Adjustment */
    .spotlight-item img {
        height: 300px; /* Reduce fixed height for mobile screens */
    }

    /* NEW: Gallery Grid to Single Column & Image Adjustment */
    .photo-gallery {
        grid-template-columns: 1fr; /* Force single column */
        gap: 20px; /* Adjust gap */
    }
    
    .gallery-item img {
        height: 300px; /* Reduce fixed height for mobile screens */
    }
    
    /* NEW: Add general main padding to prevent content hugging the edge */
    main {
        padding: 0 10px;
		padding-top: 50px; /* Clears space for FIXED 50px header bar */
    }
}

/* Mobile-Specific Styles for About Page */
@media (max-width: 768px) {
    .two-column-flex {
        flex-direction: column;
    }
    
    .two-column-flex .column-text {
        border-left: none;
        border-top: 3px solid #0E6963;
    }
}