/* Base Styles */
:root {
    --primary-color: #6a3093;
    --secondary-color: #a044ff;
    --accent-color: #e53e3e; /* Changed to match footer's accent color */
    --dark-color: #18181b;
    --light-color: #f8f9fa;
    --gradient: linear-gradient(to right, var(--primary-color), var(--secondary-color));
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Poppins', sans-serif;
    background-image: url('../../images/pageback.png');
    background-repeat: repeat-y !important;
    background-size: 100% !important;
    background-position: top center !important;
    background-attachment: fixed !important;
    min-height: 100vh;
    width: 100%;
    overflow-x: hidden;
    color: white;
    margin: 0;
}

.container {
    width: 95%;
    max-width: 1600px;
    margin: 0 auto;
    padding: 0 20px;
}

@media (max-width: 576px) {
    .container {
        width: 100%;
        padding: 0 10px;
    }
}

.container:after {
    content: "";
    display: table;
    clear: both;
}

a {
    text-decoration: none;
    color: inherit;
}

/* Navigation Bar */
.main-nav {
    background-color: rgba(255, 255, 255, 0);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
    padding: 15px 0;
}

.main-nav .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo img {
    height: 50px;
}

.nav-links ul {
    display: flex;
    list-style: none;
}

.nav-links li {
    margin-left: 30px;
}

.nav-links a {
    color: #333;
    font-weight: 500;
    transition: color 0.3s;
    position: relative;
}

.nav-links a:hover,
.nav-links a.active {
    color: var(--primary-color);
}

.nav-links a.active::after,
.nav-links a:hover::after {
    content: '';
    position: absolute;
    width: 100%;
    height: 2px;
    background: var(--gradient);
    bottom: -5px;
    left: 0;
    transform-origin: right;
    transform: scaleX(1);
    transition: transform 0.3s ease;
}

.nav-links a::after {
    transform: scaleX(0);
    transform-origin: left;
}

.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
}

.hamburger span {
    display: block;
    width: 25px;
    height: 3px;
    background-color: #333;
    margin-bottom: 5px;
    transition: all 0.3s ease;
}

/* Hero Section */
.hero-section {
    padding: 100px 0 80px;
    background: transparent;
    color: white;
    text-align: center;
    margin-top: -2px; /* Fix potential gap */
}

.headline {
    font-size: 3rem;
    margin-bottom: 20px;
    letter-spacing: 1px;
    text-transform: uppercase;
    font-weight: 700;
}

.subheadline {
    font-size: 1.2rem;
    max-width: 600px;
    margin: 0 auto;
    opacity: 0.9;
}

/* Instagram Feed Section */
.instagram-feed {
    padding: 80px 0;
    background-color: rgba(255, 255, 255, 0);
    padding-top: 0;
    padding-bottom: 50px !important;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 40px;
    flex-wrap: wrap;
}

.section-header h2 {
    font-size: 2rem;
    color: white;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    gap: 12px;
}

.insta-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: linear-gradient(45deg, #f09433 0%, #e6683c 25%, #dc2743 50%, #cc2366 75%, #bc1888 100%);
    color: white;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
}

.insta-icon i {
    font-size: 1.3rem;
}

.follow-btn {
    padding: 10px 20px;
    border-radius: 30px;
    font-weight: 600;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.95rem;
    background: linear-gradient(45deg, #f09433 0%, #e6683c 25%, #dc2743 50%, #cc2366 75%, #bc1888 100%);
    color: white;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    text-decoration: none !important;
}

.follow-btn:hover,
.follow-btn:focus,
.follow-btn:active {
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.3);
    color: white !important;
    text-decoration: none !important;
    border: none !important;
    outline: none !important;
}

/* Instagram Grid Styles */
.instagram-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 25px;
    margin-bottom: 50px !important;
    padding-bottom: 20px !important;
    position: relative !important;
    z-index: 1 !important;
    width: 100%; /* Ensure the grid uses full available width */
    max-width: 100%; /* Prevent grid from overflowing its container */
    overflow: hidden; /* Prevent horizontal scrolling */
}

@media screen and (max-width: 100vw) {
    .instagram-grid {
        grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
        width: 100%;
        padding-left: 10px;
        padding-right: 10px;
    }
    
    .instagram-post {
        width: 100%;
        min-width: 280px;
        max-width: 100%;
    }
}

@media (min-width: 1600px) {
    .instagram-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

@media (max-width: 1400px) {
    .instagram-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 20px;
    }
}

@media (max-width: 1200px) {
    .instagram-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 20px;
    }
}

@media (max-width: 992px) {
    .instagram-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
    }
    
    .instagram-post {
        height: 320px; /* Slightly smaller on medium screens */
    }
}

@media (max-width: 768px) {
    .instagram-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
    }
    
    .instagram-post {
        height: 300px;
    }
    
    .section-header {
        flex-direction: column;
        text-align: center;
        gap: 15px;
        margin-bottom: 25px;
    }
    
    .section-header h2 {
        font-size: 1.6rem;
        justify-content: center;
    }
    
    .headline {
        font-size: 2.2rem;
    }
    
    .subheadline {
        font-size: 1rem;
    }
    
    .clear-cache-link {
        margin: 5px 0 0;
    }
}

@media (max-width: 576px) {
    .instagram-grid {
        grid-template-columns: repeat(1, 1fr);
        gap: 15px;
    }
    
    .instagram-post {
        height: 350px; /* Taller on mobile for better viewing */
    }
    
    .headline {
        font-size: 1.8rem;
        margin-bottom: 10px;
    }
    
    .hero-section {
        padding: 60px 0 40px;
    }
    
    .instagram-feed {
        padding: 40px 0;
    }
    
    .post-overlay {
        opacity: 1; /* Always show overlay on mobile */
        background: linear-gradient(to bottom, transparent 0%, transparent 40%, rgba(0, 0, 0, 0.8) 100%);
    }
}

@media (max-width: 360px) {
    .instagram-post {
        height: 320px;
    }
    
    .headline {
        font-size: 1.5rem;
    }
    
    .subheadline {
        font-size: 0.9rem;
    }
    
    .section-header h2 {
        font-size: 1.4rem;
    }
}

/* Improved post layout */
.instagram-post {
    transition: all 0.3s ease;
    position: relative;
    border-radius: 15px;
    overflow: hidden;
    background: rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
    height: 350px; /* Fixed height for all grid items */
    display: flex;
    flex-direction: column;
    justify-content: flex-end; /* Align content to the bottom */
    width: 100%; /* Ensure full width */
    min-width: 280px; /* Minimum width to prevent collapsing */
    z-index: 1; /* Base z-index */
}

.instagram-post:hover {
    z-index: 5; /* Higher z-index on hover to prevent overlap issues */
    transform: translateY(-5px);
}

/* Fix for desktop mode on mobile */
@media (min-width: 992px) {
    body.desktop-mode .instagram-grid {
        grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)) !important;
    }
}

/* Fix for desktop mode on mobile */
body.desktop-mode .instagram-grid {
    display: grid !important;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)) !important;
    gap: 15px !important;
    width: 100% !important;
    max-width: 100% !important;
    overflow: hidden !important;
    transform: none !important;
}

body.desktop-mode .instagram-post {
    transform: none !important;
    transition: none !important;
    position: relative !important;
    z-index: 1 !important;
    height: 350px !important;
    width: 100% !important;
    min-width: 280px !important;
    max-width: 100% !important;
    margin-bottom: 15px !important;
}

body.desktop-mode .instagram-post:hover {
    transform: none !important;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2) !important;
}

/* Prevent any parallax or animation effects in desktop mode */
body.desktop-mode .instagram-post {
    animation: none !important;
}

/* Fix for extra narrow screens in desktop mode */
@media screen and (max-width: 500px) {
    body.desktop-mode .instagram-grid {
        grid-template-columns: 1fr !important;
    }
}

/* Ensure proper stacking in all modes */
.instagram-post {
    position: relative;
    z-index: 1;
}

.instagram-post:hover,
.instagram-post:focus,
.instagram-post:active {
    z-index: 5;
}

/* Completely disable parallax effect on smaller screens */
@media (max-width: 992px) {
    .instagram-post {
        transform: none !important;
    }
}

/* Additional responsive fixes */
@media screen and (max-width: 992px) {
    .container {
        width: 100%;
        max-width: 100%;
        padding-left: 15px;
        padding-right: 15px;
    }
    
    .instagram-grid {
        grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    }
}

/* Fix for very narrow screens in desktop mode */
@media screen and (max-width: 400px) {
    .instagram-grid {
        grid-template-columns: 1fr !important;
    }
    
    .instagram-post {
        width: 100% !important;
        min-width: 100% !important;
    }
}

/* Enhanced fixes for desktop mode on mobile */
body.desktop-mode {
    /* Override important styles for desktop mode */
    overflow-x: hidden !important;
}

body.desktop-mode * {
    /* Prevent any unexpected animations in desktop mode */
    animation-play-state: paused !important;
}

body.desktop-mode .instagram-grid {
    display: grid !important;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)) !important;
    gap: 20px !important;
    width: 100% !important;
    max-width: 100% !important;
    overflow: visible !important;
    transform: none !important;
    position: relative !important;
    z-index: 1 !important;
}

body.desktop-mode .instagram-post {
    transform: none !important;
    transition: none !important;
    animation: none !important;
    position: relative !important;
    z-index: 1 !important;
    height: 350px !important;
    width: 100% !important;
    min-width: 280px !important;
    max-width: 100% !important;
    margin-bottom: 15px !important;
    top: 0 !important;
    left: 0 !important;
}

/* Forcefully disable any hover effects in desktop mode */
body.desktop-mode .instagram-post:hover {
    transform: none !important;
    z-index: 1 !important;
}

body.desktop-mode .instagram-post:hover .post-media img {
    transform: none !important;
}

/* Force post overlays to be visible in desktop mode on mobile */
body.desktop-mode .post-overlay {
    opacity: 1 !important;
    background: linear-gradient(to bottom, transparent 0%, rgba(0, 0, 0, 0.7) 100%) !important;
}

/* Additional fix for narrow screens in desktop mode */
@media screen and (max-width: 500px) {
    body.desktop-mode .instagram-grid {
        grid-template-columns: 1fr !important;
    }
    
    body.desktop-mode .instagram-post {
        width: 100% !important;
        min-width: 0 !important;
    }
}

/* Stronger fixes for desktop mode on mobile to prevent any card movement */
body.desktop-mode {
    /* Disable any global animations or transitions */
    animation: none !important;
    transition: none !important;
    overflow-x: hidden !important;
}

body.desktop-mode * {
    /* Stop all animations globally in desktop mode */
    animation: none !important;
    animation-play-state: paused !important;
    transition: none !important;
}

body.desktop-mode .instagram-grid {
    /* Force grid to be completely static */
    display: grid !important;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)) !important;
    gap: 20px !important;
    width: 100% !important;
    max-width: 100% !important;
    overflow: visible !important;
    transform: none !important;
    position: relative !important;
    z-index: 1 !important;
    animation: none !important;
    transition: none !important;
    margin-bottom: 30px !important;
}

body.desktop-mode .instagram-post {
    /* Completely disable any movement or transform effects */
    transform: none !important;
    transition: none !important;
    animation: none !important;
    position: relative !important;
    z-index: 1 !important;
    height: 350px !important;
    width: 100% !important;
    min-width: 280px !important;
    max-width: 100% !important;
    margin-bottom: 20px !important;
    top: 0 !important;
    left: 0 !important;
}

/* Force post to remain static even on scroll */
body.desktop-mode .instagram-post {
    transform: translate(0, 0) !important;
    -webkit-transform: translate(0, 0) !important;
    -moz-transform: translate(0, 0) !important;
    -ms-transform: translate(0, 0) !important;
    -o-transform: translate(0, 0) !important;
}

/* Disable hover effects completely in desktop mode */
body.desktop-mode .instagram-post:hover,
body.desktop-mode .instagram-post:active,
body.desktop-mode .instagram-post:focus {
    transform: none !important;
    z-index: 1 !important;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15) !important;
}

body.desktop-mode .instagram-post:hover .post-media img {
    transform: none !important;
}

/* Disable animations on all individual post elements in desktop mode */
body.desktop-mode .instagram-post * {
    animation: none !important;
    transition: none !important;
    transform: none !important;
}

/* Better video responsive behavior */
.playable-video video {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Make videos more accessible on mobile */
@media (max-width: 576px) {
    .playable-video video {
        object-fit: contain;
    }
    
    .post-media.video .post-overlay {
        bottom: 60px; /* More room for video controls on mobile */
    }
    
    video::-webkit-media-controls-panel {
        opacity: 0.8; /* Semi-transparent controls for better visibility */
    }
}

/* Better touch experience for mobile */
@media (hover: none) {
    .instagram-post:hover .post-media img {
        transform: none; /* Remove hover scale effect on touch devices */
    }
    
    .post-overlay {
        opacity: 1; /* Always show overlay on touch devices */
    }
    
    .follow-btn, .clear-cache-link {
        padding: 12px 20px; /* Larger touch targets */
    }
}

/* Fix for extra small devices */
@media (max-width: 320px) {
    .post-caption {
        font-size: 0.75rem;
        margin-bottom: 5px;
    }
    
    .post-meta {
        font-size: 0.75rem;
    }
    
    .post-meta a {
        padding: 5px 0;
    }
    
    .instagram-post {
        height: 280px;
    }
}

/* Fix overlap issues between posts and footer */
.instagram-grid {
    padding-bottom: 30px !important;
}

footer {
    margin-top: 30px !important;
}

/* Ensure media fits within the fixed height */
.post-media {
    flex-grow: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.post-media img,
.post-media video {
    width: 100%;
    height: 100%;
    object-fit: cover; /* Ensure media scales properly */
}

.post-media.video {
    position: relative;
    overflow: hidden;
    cursor: pointer;
}

.post-media.video::before {
    content: "VIDEO";
    position: absolute;
    top: 10px;
    left: 10px;
    background: rgba(225, 48, 108, 0.85);
    color: white;
    font-size: 10px;
    font-weight: 700;
    padding: 4px 8px;
    border-radius: 4px;
    z-index: 8;
    letter-spacing: 1px;
}

/* Overlay positioning */
.post-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to bottom, transparent 0%, rgba(0, 0, 0, 0.8) 100%);
    color: white;
    padding: 15px;
    opacity: 0;
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    z-index: 3;
    pointer-events: none; /* Make sure overlays don't interfere with clicks */
}

.post-media.video .post-overlay {
    bottom: 40px; /* Make room for video controls */
}

/* Hide captions for video posts only */
.post-media.video + .post-overlay .post-caption {
    display: none !important;
}

/* Adjust meta position for video posts */
.post-media.video + .post-overlay .post-meta {
    margin-top: 0;
}

.post-overlay .post-bottom {
    pointer-events: auto; /* Allow clicks on the bottom section */
}

.instagram-post:hover .post-overlay {
    opacity: 1;
}

/* Caption and meta styling */
.post-caption {
    margin-bottom: 10px;
    font-size: 0.9rem;
    font-weight: 300;
    line-height: 1.4;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.8);
}

.post-meta {
    display: flex;
    align-items: center;
    font-size: 0.85rem;
    font-weight: 600;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.8);
    margin-top: 5px;
}

.post-meta a {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    color: white !important;
    font-weight: 600;
    transition: all 0.2s ease;
    opacity: 0.9;
    text-decoration: none !important;
    border: none !important;
}

.post-meta a:hover,
.post-meta a:focus,
.post-meta a:active {
    opacity: 1;
    transform: translateY(-1px);
    color: white !important;
    text-decoration: none !important;
    border: none !important;
}

/* Override any theme-specific a tag styles */
.post-meta a::before,
.post-meta a::after,
.follow-btn::before,
.follow-btn::after {
    display: none !important;
}

/* Clear cache link styling */
.clear-cache-link {
    text-decoration: none !important;
    border: none !important;
    box-shadow: none !important;
}

.clear-cache-link:hover,
.clear-cache-link:focus,
.clear-cache-link:active {
    text-decoration: none !important;
    border: none !important;
}

/* Responsive adjustments */
@media (max-width: 992px) {
    .instagram-grid {
        grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    }
}

@media (max-width: 768px) {
    .instagram-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 576px) {
    .instagram-grid {
        grid-template-columns: 1fr;
    }
}

/* Hidden posts */
.hidden-post {
    display: none !important;
    height: 0 !important;
    padding: 0 !important;
    margin: 0 !important;
    overflow: hidden !important;
}

.shown-post {
    display: block !important;
    height: auto !important;
    animation: fadeIn 0.8s ease forwards;
}

/* Load more button styling */
.load-more-container {
    text-align: center;
    margin-top: 40px;
    margin-bottom: 40px;
}

.load-more-btn {
    padding: 12px 30px;
    background: linear-gradient(45deg, #f09433 0%, #e6683c 25%, #dc2743 50%, #cc2366 75%, #bc1888 100%);
    background-size: 200% 200%;
    color: white;
    border: none;
    border-radius: 30px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
    animation: gradientMove 3s ease infinite;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

/* Clear cache button styling */
.clear-cache-link {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 8px 15px;
    background: rgba(255, 255, 255, 0.15);
    border-radius: 20px;
    color: white;
    font-size: 0.9rem;
    transition: all 0.3s ease;
    margin-left: 10px;
}

.clear-cache-link:hover {
    background: rgba(255, 255, 255, 0.25);
    transform: translateY(-2px);
}

@media (max-width: 768px) {
    .clear-cache-link {
        margin: 10px 0 0;
    }
}

/* Video player styling */
.post-media video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    background-color: #000;
    transition: transform 0.3s ease;
    cursor: pointer;
}

.playable-video {
    position: relative;
    width: 100%;
    height: 100%;
    cursor: pointer;
    overflow: hidden;
    background-color: #000;
}

.playable-video video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
    cursor: pointer;
}

/* Remove play button styles - no longer needed */
.video-play-button {
    display: none !important;
}

.instagram-post:hover .post-media img {
    transform: scale(1.08);
}

/* Video player styling - enhanced for in-page playback */
/* Playable video container */
.playable-video {
    position: relative;
    width: 100%;
    height: 100%;
    cursor: pointer;
    overflow: hidden;
    background-color: #000;
}

/* Fix for mobile devices */
@media (max-width: 768px) {
    .video-play-button {
        width: 60px;
        height: 60px;
    }
    
    .video-play-button i {
        font-size: 24px;
    }
}

/* Active video state */
.playable-video.playing video {
    object-fit: contain; /* Show full video when playing */
}

/* Video post - expanded state when playing */
.instagram-post.playing-video {
    z-index: 50;
    transform: none !important; /* Override parallax effect during playback */
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.instagram-post.playing-video .post-overlay {
    opacity: 0; /* Hide overlay during playback */
    pointer-events: none;
}

/* Video controls */
.video-controls {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.7), transparent);
    padding: 15px 10px 10px;
    display: flex;
    align-items: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.playable-video.playing .video-controls,
.playable-video:hover .video-controls {
    opacity: 1;
}

.video-progress {
    flex-grow: 1;
    height: 4px;
    background: rgba(255,255,255,0.3);
    position: relative;
    margin: 0 10px;
    cursor: pointer;
    border-radius: 2px;
}

.video-progress-bar {
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    background: #E1306C;
    border-radius: 2px;
    width: 0%;
}

.video-time {
    color: white;
    font-size: 12px;
    min-width: 50px;
    text-align: right;
}

/* Pause effect for video overlay */
.post-media.video .post-overlay {
    pointer-events: none; /* Allow clicks to pass through to video */
}

/* Fix clearfix issues */
.container:after {
    content: "";
    display: table;
    clear: both;
}

/* Load more button animation */
.load-more-btn:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    transform: scale(0.95);
}

.loading-btn {
    position: relative;
    color: transparent !important; /* Hide text while loading */
}

.loading-btn::after {
    content: "";
    position: absolute;
    width: 20px;
    height: 20px;
    top: 50%;
    left: 50%;
    margin-left: -10px;
    margin-top: -10px;
    border-radius: 50%;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: white;
    animation: spin 0.8s linear infinite;
}

/* Post-animation state to prevent transform conflicts */
.instagram-post.animated {
    opacity: 1;
    transform: translateY(0);
}

/* Loading and placeholders */
.loading-placeholder {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    background-color: rgba(0, 0, 0, 0.1);
    z-index: 2;
}

.loading-spinner {
    width: 40px;
    height: 40px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: #E1306C;
    animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Video and carousel indicators */
.video-icon, .carousel-icon {
    position: absolute;
    top: 15px;
    right: 15px;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background-color: rgba(0, 0, 0, 0.7);
    color: white;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 2;
    font-size: 0.8rem;
}

/* Instagram post animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.instagram-post:nth-child(1) { animation-delay: 0.1s; }
.instagram-post:nth-child(2) { animation-delay: 0.2s; }
.instagram-post:nth-child(3) { animation-delay: 0.3s; }
.instagram-post:nth-child(4) { animation-delay: 0.4s; }
.instagram-post:nth-child(5) { animation-delay: 0.5s; }
.instagram-post:nth-child(6) { animation-delay: 0.6s; }
.instagram-post:nth-child(7) { animation-delay: 0.7s; }
.instagram-post:nth-child(8) { animation-delay: 0.8s; }
.instagram-post:nth-child(9) { animation-delay: 0.9s; }

/* Responsive adjustments */
@media (max-width: 1200px) {
    .instagram-grid {
        grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
        gap: 20px;
    }
}

@media (max-width: 992px) {
    .instagram-grid {
        grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
        gap: 15px;
    }
}

@media (max-width: 768px) {
    .section-header {
        flex-direction: column;
        text-align: center;
        gap: 20px;
    }
    
    .section-header h2 {
        font-size: 1.8rem;
        justify-content: center;
    }
    
    .instagram-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
    }
}

@media (max-width: 576px) {
    .instagram-grid {
        grid-template-columns: repeat(1, 1fr);
        gap: 15px;
    }
}

@media (max-width: 480px) {
    .instagram-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .post-caption {
        font-size: 0.8rem;
    }
    
    .follow-btn {
        padding: 8px 16px;
        font-size: 0.9rem;
    }
}

/* Reset any conflicting footer styles */
footer, 
footer *, 
.footer, 
.footer * {
    box-sizing: border-box !important;
}

/* Make sure the footer is on top of Instagram content */
footer, .footer {
    position: relative !important;
    z-index: 5 !important;
    clear: both !important;
}
