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

html,
body {
    width: 100%;
    height: 100%;
    overflow: hidden;
    font-family: Arial, Helvetica, sans-serif;
    background: #000;
}

/* NAVBAR */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    padding: 24px 50px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 100;
    background: rgba(0, 0, 0, 0);
    backdrop-filter: blur(6px);
}

.logo {
    color: white;
    font-size: 1.4rem;
    font-weight: bold;
    letter-spacing: 2px;
}

.nav-links {
    list-style: none;
    display: flex;
    gap: 40px;
}

.nav-links a {
    color: white;
    text-decoration: none;
    font-size: 0.95rem;
    letter-spacing: 1.5px;
    text-transform: uppercase;
}

.nav-links a:hover {
    opacity: 0.65;
}

/* FULL PAGE BACKGROUND */
.homepage-hero {
    position: fixed;
    inset: 0;
    width: 100vw;
    height: 100vh;
    background-image: url("images/landscapes/IMG_0909.jpg");
    background-size: cover;
    background-position: top center;
    background-repeat: no-repeat;
    overflow: hidden;
    z-index: 1;
}

/* DARK OVERLAY */
.homepage-hero::before {
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.35);
    z-index: 2;
    pointer-events: none;
}

/* CLICKABLE BACKGROUND */
.background-click-area {
    position: absolute;
    inset: 0;
    z-index: 3;
}

/* TEXT OVERLAY */
.hero-overlay {
    position: absolute;
    left: 60px;
    bottom: 90px;
    z-index: 10;
    color: white;
    max-width: 700px;
    pointer-events: none;
}

.hero-overlay h1 {
    font-size: 5rem;
    line-height: 1;
    letter-spacing: 4px;
    text-transform: uppercase;
    text-shadow: 0 4px 24px rgba(0, 0, 0, 0.85);
}

.hero-overlay p {
    margin-top: 20px;
    font-size: 1.25rem;
    letter-spacing: 1px;
    line-height: 1.6;
    text-shadow: 0 3px 14px rgba(0, 0, 0, 0.8);
}

/* ARROWS */
.slider-controls {
    position: absolute;
    right: 45px;
    bottom: 45px;
    display: flex;
    gap: 14px;
    z-index: 20;
}

.arrow-btn {
    width: 48px;
    height: 48px;
    border: 1px solid rgba(255, 255, 255, 0.75);
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.35);
    color: white;
    font-size: 1.6rem;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
}

.arrow-btn:hover {
    background: rgba(255, 255, 255, 0.2);
}

/* GALLERY PAGES (landscapes.html, wildlife.html) */
/* Update this selector to include body.blog-page */
body.gallery-page,
body.blog-page {
    overflow-x: hidden;
    overflow-y: auto;
    color: white;
}

.image-grid {
    width: 100dvw;
    min-height: 100vh;
    padding: 120px 40px 40px;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    background: #000;
}

.grid-photo {
    position: relative;
    display: block;
    width: 100%;
    height: 350px;
    overflow: hidden;
    border-radius: 6px;
    text-decoration: none;
    color: white;
    background: #111;
}

.grid-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    display: block;
    transition: transform 0.4s ease, filter 0.4s ease;
}

.grid-photo:hover img {
    transform: scale(1.1);
}

.grid-photo .photo-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 20px;
    background: rgba(0, 0, 0, 0.01);
    opacity: 0;
    transition: opacity 0.35s ease;
    z-index: 2;
}

.grid-photo:hover .photo-overlay {
    opacity: 1;
}

.grid-photo .photo-overlay h2 {
    font-size: 1.8rem;
    letter-spacing: 2px;
    text-transform: uppercase;
    margin-bottom: 10px;
}

.grid-photo .photo-overlay p {
    font-size: 0.95rem;
    letter-spacing: 1px;
}

/* BLOG LAYOUT (Blogger Style) */
.blog-container {
    max-width: 1100px;
    margin: 0 auto;            /* Changed from 40px auto */
    padding: 140px 20px 40px;  /* Added 140px top padding to clear the navbar */
    display: flex;
    gap: 40px;
}

.blog-main {
    flex: 2;
}

.blog-sidebar {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.blog-post {
    margin-bottom: 50px;
    padding-bottom: 30px;
    border-bottom: 1px solid #eee;
}

.post-title a {
    color: #fff;                 /* Changes post titles from dark grey to white */
    text-decoration: none;
    font-size: 1.8rem;
}

.post-title a:hover {
    color: #ccc;
}

.post-snippet p {
    line-height: 1.6;
    color: #ccc;                 /* Changes snippet text from dark grey to light grey */
}

.post-meta {
    font-size: 0.85rem;
    color: #888;
    margin: 8px 0 15px 0;
}

.post-featured-image img {
    width: 100%;
    max-height: 400px;
    object-fit: cover;
    border-radius: 4px;
    margin-bottom: 15px;
}

.read-more {
    display: inline-block;
    margin-top: 10px;
    color: #0066cc;
    text-decoration: none;
    font-weight: 500;
}

/* Sidebar Widgets styling */
.sidebar-widget {
    background: #222;            /* Changed from light grey/white to a dark grey-ish tone */
    padding: 20px;
    border-radius: 4px;
    border: 1px solid #333;      /* Changed border to blend with the pitch black background */
}

.sidebar-widget h3 {
    color: #fff;                 /* Forces the widget titles to be crisp white */
    margin-top: 0;
    border-bottom: 2px solid #555; /* Subtle grey bottom border line */
    padding-bottom: 5px;
    margin-bottom: 15px;
}

.sidebar-widget p {
    color: #ddd;                 /* Makes the "About Me" description text visible and light grey */
    line-height: 1.6;
}

.archive-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.archive-list li {
    margin-bottom: 8px;
}

.archive-list a {
    color: #ccc;                 /* Changes the text link color in the archive widget to be visible */
    text-decoration: none;
}

.archive-list a:hover {
    color: #fff;                 /* Brightens the links when you hover over them */
}

/* MEDIA QUERIES / RESPONSIVENESS */
@media (max-width: 1000px) {
    .image-grid {
        grid-template-columns: repeat(2, 1fr);
        padding: 130px 30px 35px;
    }

    .grid-photo {
        height: 280px;
    }
}

@media (max-width: 768px) {
    .navbar {
        padding: 18px 22px;
        flex-direction: column;
        gap: 14px;
    }

    .nav-links {
        gap: 22px;
    }

    .hero-overlay {
        left: 25px;
        right: 25px;
        bottom: 120px;
    }

    .hero-overlay h1 {
        font-size: 2.8rem;
    }

    .slider-controls {
        right: 25px;
        bottom: 35px;
    }

    .blog-container {
        flex-direction: column;
    }
}

@media (max-width: 600px) {
    .image-grid {
        grid-template-columns: 1fr;
        padding: 150px 20px 30px;
    }

    .grid-photo {
        height: 260px;
    }
}

/* INDIVIDUAL BLOG POST VIEW */
.blog-post-view {
    max-width: 900px;
    margin: 0 auto;
    padding: 140px 24px 60px; /* Top padding clears fixed navigation bar */
}

.post-header h1 {
    font-size: 2.5rem;
    letter-spacing: 1px;
    margin-bottom: 10px;
}

.post-body-text p {
    font-size: 1.1rem;
    line-height: 1.6;
    color: #ccc;
    margin-bottom: 30px;
}

/* 9-Image Gallery Layout */
.post-gallery-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
}

.post-gallery-item {
    aspect-ratio: 3 / 2;
    overflow: hidden;
    border-radius: 4px;
    background-color: #111;
}

.post-gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    cursor: pointer;
    transition: filter 0.2s ease;
    -webkit-tap-highlight-color: transparent; /* Fixes touch flash on iPhone */
}

.post-gallery-item img:hover {
    filter: brightness(85%);
}

/* FULLSCREEN LIGHTBOX CSS */
.lightbox-overlay {
    position: fixed;
    z-index: 2000; /* Higher than your 100 z-index navbar */
    inset: 0;
    background-color: rgba(0, 0, 0, 0.95);
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.lightbox-overlay.active {
    opacity: 1;
    pointer-events: auto;
}

.lightbox-content {
    max-width: 90%;
    max-height: 85%;
    object-fit: contain;
    border-radius: 2px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.5);
}

.lightbox-close {
    position: absolute;
    top: 30px;
    right: 40px;
    color: #fff;
    font-size: 40px;
    font-weight: bold;
    cursor: pointer;
    user-select: none;
    padding: 10px; /* Increases tap target for mobile thumbs */
}

/* Responsive adjustments for Tablets & iPhones */
@media (max-width: 768px) {
    .blog-post-view {
        padding-top: 160px; /* Accounts for stacked mobile navbar */
    }
    
    .post-header h1 {
        font-size: 1.8rem;
    }
    
    .post-gallery-grid {
        grid-template-columns: repeat(2, 1fr); /* 2 columns on small screens */
        gap: 10px;
    }
    
    .lightbox-close {
        top: 20px;
        right: 25px;
    }
}

@media (max-width: 480px) {
    .post-gallery-grid {
        grid-template-columns: 1fr; /* Single column on tiny phones */
    }
}

/* Minimalist Filter Bar Layout */
.filter-bar {
    max-width: 1200px;
    margin: 0 auto;
    padding: 100px 40px 10px; /* Top padding leaves space for fixed navbar */
    display: flex;
    gap: 30px;
    background: #000;
}

.filter-group {
    display: flex;
    align-items: center;
    gap: 10px;
}

.filter-group label {
    font-size: 0.85rem;
    color: #888;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.filter-group select {
    background: #111;
    color: #fff;
    border: 1px solid #333;
    padding: 6px 12px;
    border-radius: 4px;
    font-size: 0.9rem;
    cursor: pointer;
    outline: none;
    transition: border-color 0.2s;
}

.filter-group select:focus {
    border-color: #666;
}

/* Adjust image grid padding since filter bar is taking up top space */
.image-grid {
    padding-top: 20px !important; 
}

/* Responsive adjustment for small phone screens */
@media (max-width: 768px) {
    .filter-bar {
        padding-top: 150px; /* Push down further on mobile when navbar stacks */
        flex-direction: column;
        gap: 15px;
    }
}
