/* 1. RESET CORE CONTAINER FOR AN UNBROKEN VIEWPORT FRAME */
html, body {
    overflow-x: hidden;
    margin: 0;
    padding: 0;
}

.wp-site-blocks {
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 auto !important;
    padding-left: 10px !important;  /* Photos touch the absolute left screen line */
    padding-right: 60px !important; /* Photos touch the absolute right screen line */
    box-sizing: border-box !important;
}

/* 2. RE-TARGET THE LIST CONTAINER DIRECTLY TO RE-ALIGN COLUMNS */
.narrative-story-grid ul.wp-block-post-template {
    display: grid !important;
    grid-template-columns: repeat(3, 1fr) !important; /* Fixed 3 column strip layout */
    gap: 6px !important; /* Exact thin separation line from your reference site layout */
    width: 100% !important;
    max-width: 100% !important;
    margin: 40px auto 0 auto !important; /* Adds a beautiful 40px padding gap below the header */
    padding: 0 !important;
    list-style: none !important;
    box-sizing: border-box !important;
}

/* 3. STRIP BACKGROUND PANELS AND FORCED VERTICAL COMPRESSIONS */
.narrative-story-grid li.wp-block-post {
    display: flex !important;
    flex-direction: column !important;
    margin: 0 !important;
    padding: 0 !important;
    background: transparent !important; /* Eliminates the gray blocks permanently */
    width: 100% !important;
}

.narrative-story-grid .wp-block-post-featured-image {
    margin: 0 !important;
    padding: 0 !important;
    width: 100% !important;
}

/* 4. CHOOSE ONE ASPECT RATIO OPTION FOR FIXED PROPORTIONS */
.narrative-story-grid .wp-block-post-featured-image img {
    width: 100% !important;
    display: block !important;

    /* OPTION A: If you want standard 3:2 landscape bounding frames (Recommended) */
    height: auto !important;
    aspect-ratio: 3 / 2 !important;
    object-fit: cover !important;

    /* OPTION B: Delete the two lines above and uncomment this line if your raw files are natively cropped */
    /* height: auto !important; */
}

/* 5. PROTECT SITE NAVIGATION FROM SLIDING OFF THE COMPASS */
header, 
.site-header,
header.wp-block-template-part {
    width: 100% !important;
    max-width: 100% !important;
    padding-left: 40px !important;  
    padding-right: 40px !important; 
    box-sizing: border-box !important;
}
/* RESET ROOT HTML BOUNDARIES FOR SLIDESHOW EXTRACTION */
html, body {
    margin: 0;
    padding: 0;
    width: 100%;
    overflow-x: hidden;
}

/* FULL-SCREEN CONTAINER */
.homepage-hero-slideshow {
    position: relative;
    width: 100vw;
    height: 100vh; /* Takes up 100% of the browser's vertical height */
    overflow: hidden;
    margin-left: calc(-50vw + 50%); /* Forces past default alignment blocks to screen edges */
    margin-right: calc(-50vw + 50%);
    background-color: #000;
}

.slideshow-track {
    width: 100%;
    height: 100%;
    position: relative;
}

/* SLIDE PROPERTIES */
.slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    visibility: hidden;
    transition: opacity 1.2s ease-in-out, visibility 1.2s ease-in-out; /* Smooth cinematic fade effect */
    z-index: 1;
}

.slide.active {
    opacity: 1;
    visibility: visible;
    z-index: 2;
}

/* FULL RESOLUTION RESPONSIVE IMAGE FILL */
.slide img {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important; /* Crops cleanly across any screen monitor ratio */
    object-position: center !important;
}

/* SLIDE TEXT OVERLAY (Centering Typography) */
.slide-overlay {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    color: #ffffff;
    z-index: 3;
    text-shadow: 0px 4px 15px rgba(0, 0, 0, 0.4); /* Makes text legible over bright images */
    width: 80%;
    max-width: 800px;
}

.slide-overlay h1 {
    font-size: clamp(2.5rem, 6vw, 5rem); /* Dynamically shrinks/grows with screen size */
    margin-bottom: 1rem;
    font-weight: 300;
    letter-spacing: 2px;
}

.slide-overlay p {
    font-size: clamp(1rem, 2vw, 1.5rem);
    font-weight: 400;
    opacity: 0.9;
}

/* DOTS NAVIGATION STYLING */
.slideshow-dots {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 4;
    display: flex;
    gap: 12px;
}

.dot {
    width: 10px;
    height: 10px;
    background-color: rgba(255, 255, 255, 0.4);
    border-radius: 50%;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.dot.active, .dot:hover {
    background-color: #ffffff;
}

/* ==========================================
   Default Page template readable column.
   Scoped ONLY to .narrative-page-container
   (the default "Page" template's content area) --
   does not touch the Hero or Gallery templates,
   or anything else above in this file.
========================================== */
.narrative-page-container {
    max-width: 760px !important;
    margin-left: auto !important;
    margin-right: auto !important;
    padding-left: 1.5rem !important;
    padding-right: 1.5rem !important;
    box-sizing: border-box !important;
}

/* Manually-resized images (WordPress bakes a literal pixel width like
   "width:2560px" into these) otherwise ignore their container and
   overflow it. Force them back down to fit, regardless of that inline
   value. Scoped to the default Page template only. */
.narrative-page-container img {
    max-width: 100% !important;
    width: auto !important;
    height: auto !important;
}
