/* Import modern fonts */
@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600;700&family=Playfair+Display:wght@400;500;600;700&display=swap');

/* CSS Variables for theming */
:root {
    --primary-color: #2c5282;
    --secondary-color: #4a90e2;
    --accent-color: #f56565;
    --text-dark: #2d3748;
    --text-light: #718096;
    --background-light: #f7fafc;
    --background-dark: #1a202c;
    --transition: all 0.3s ease;
    --shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    --border-radius: 8px;
}

/* Base styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    /*font-family: 'Poppins', sans-serif;*/
    line-height: 1.6;
    color: var(--text-dark);
    background-color: var(--background-light);
    overflow-x: hidden;
}

/* Hero section styling */
.hero-container {
    position: relative;
    width: 100%;
    height: 80vh;
    min-height: 400px;
    overflow: hidden;
    margin-top: 100px;
}

.hero-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('https://elitewebforge.com/public/our-recent-work/our-recent-work-banner.png');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    filter: brightness(0.5);
    transform: scale(1.05);
    transition: transform 0.5s ease;
}

.hero-content {
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    height: 100%;
    padding: 2rem;
    text-align: center;
    z-index: 1;
}

.hero-title {
    font-family: 'Playfair Display', serif;
    font-size: clamp(2.5rem, 8vw, 5rem);
    font-weight: 700;
    color: white;
    margin-bottom: 1.5rem;
    opacity: 0;
    transform: translateY(30px);
    animation: fadeInUp 1s ease forwards 0.3s;
    position: relative;
    text-shadow: 2px 2px 15px rgba(0, 0, 0, 0.3);
}

.title-accent {
    position: relative;
    display: inline-block;
}

.title-accent::after {
    content: '';
    position: absolute;
    bottom: -15px;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 5px;
    background-color: var(--accent-color);
    border-radius: 5px;
    animation: expandWidth 1.5s ease forwards 0.8s;
    transform-origin: center;
    opacity: 0;
}

.hero-subtitle {
    font-size: clamp(1rem, 3vw, 1.25rem);
    font-weight: 300;
    color: rgba(255, 255, 255, 0.9);
    max-width: 700px;
    margin: 1.5rem auto 0;
    opacity: 0;
    transform: translateY(20px);
    animation: fadeInUp 1s ease forwards 0.6s;
}

.scroll-indicator {
    position: absolute;
    bottom: 10px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    color: white;
    opacity: 0;
    animation: fadeIn 1s ease forwards 1.2s;
    /*margin-top: 20px;*/
}

.scroll-indicator p {
    margin-bottom: 10px;
    font-size: 0.9rem;
    letter-spacing: 1px;
    text-transform: uppercase;
    /*margin-top: 30px;*/
}

.scroll-icon {
    font-size: 1.2rem;
    animation: bounce 2s infinite;
}

/* Portfolio grid styling */
.portfolio-section {
    padding: 5rem 0;
    background-color: var(--background-light);
}

.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
}

.section-title {
    font-family: 'Playfair Display', serif;
    text-align: center;
    margin-bottom: 3rem;
    position: relative;
    color: var(--text-dark);
}

.section-title h2 {
    font-size: clamp(2rem, 5vw, 2.5rem);
    margin-bottom: 1rem;
    position: relative;
    display: inline-block;
}

.section-title h2::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 3px;
    background-color: var(--accent-color);
}

.section-title p {
    color: var(--text-light);
    max-width: 700px;
    margin: 0 auto;
    font-size: 1.1rem;
}

.portfolio-filter {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    margin-bottom: 3rem;
    gap: 10px;
}

.filter-btn {
    padding: 8px 20px;
    border: none;
    background-color: transparent;
    color: var(--text-light);
    cursor: pointer;
    font-weight: 500;
    font-size: 0.95rem;
    border-radius: 30px;
    transition: var(--transition);
    border: 1px solid #e2e8f0;
}

.filter-btn:hover, .filter-btn.active {
    background-color: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 25px;
}

.portfolio-item {
    position: relative;
    /*height: 550px;*/
    overflow: hidden;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    cursor: pointer;
    opacity: 0;
    transform: translateY(20px);
        border: 1px solid red;
    margin: 25px;
}

.portfolio-item.animate {
    animation: fadeInUp 0.8s ease forwards;
}

.portfolio-item:nth-child(2) {
    animation-delay: 0.2s;
}

.portfolio-item:nth-child(3) {
    animation-delay: 0.4s;
}

.portfolio-item:nth-child(4) {
    animation-delay: 0.6s;
}

.portfolio-item:nth-child(5) {
    animation-delay: 0.8s;
}

.portfolio-item:nth-child(6) {
    animation-delay: 1s;
}

.portfolio-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

.portfolio-item:hover img {
    transform: scale(1.1);
}

.portfolio-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.7), transparent);
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 1.5rem;
    opacity: 0;
    transition: var(--transition);
}

.portfolio-item:hover .portfolio-overlay {
    opacity: 1;
}

.portfolio-overlay h3 {
    color: white;
    font-size: 1.3rem;
    margin-bottom: 0.5rem;
    transform: translateY(20px);
    transition: var(--transition);
}

.portfolio-item:hover .portfolio-overlay h3 {
    transform: translateY(0);
}

.portfolio-overlay p {
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.9rem;
    margin-bottom: 1rem;
    transform: translateY(20px);
    transition: var(--transition);
    transition-delay: 0.1s;
}

.portfolio-item:hover .portfolio-overlay p {
    transform: translateY(0);
}

.portfolio-overlay .view-project {
    display: inline-flex;
    align-items: center;
    color: white;
    font-size: 0.9rem;
    text-decoration: none;
    transform: translateY(20px);
    transition: var(--transition);
    transition-delay: 0.2s;
}

.portfolio-item:hover .portfolio-overlay .view-project {
    transform: translateY(0);
}

.view-project i {
    margin-left: 5px;
    transition: var(--transition);
}

.view-project:hover i {
    transform: translateX(5px);
}

.load-more {
    display: block;
    margin: 3rem auto 0;
    padding: 12px 30px;
    background-color: var(--primary-color);
    color: white;
    border: none;
    border-radius: 30px;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.load-more:hover {
    background-color: var(--secondary-color);
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
}

/* Animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes expandWidth {
    from {
        width: 0;
        opacity: 0;
    }
    to {
        width: 80px;
        opacity: 1;
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateY(0);
    }
    40% {
        transform: translateY(-10px);
    }
    60% {
        transform: translateY(-5px);
    }
}

/* Responsive styles */
@media (max-width: 1024px) {
    .portfolio-grid {
        grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    }
}

@media (max-width: 768px) {
    .hero-container {
        height: 60vh;
    }

    .portfolio-grid {
        grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
        gap: 20px;
    }

    .portfolio-filter {
        margin-bottom: 2rem;
    }
}

@media (max-width: 576px) {
    .hero-container {
        height: 50vh;
    }

    .title-accent::after {
        bottom: -10px;
        height: 4px;
        width: 60px;
    }

    .portfolio-filter {
        flex-direction: row;
        overflow-x: auto;
        padding-bottom: 10px;
        justify-content: flex-start;
        margin-bottom: 1.5rem;
    }

    .filter-btn {
        flex: 0 0 auto;
        font-size: 0.85rem;
        padding: 6px 15px;
    }

    .portfolio-grid {
        grid-template-columns: repeat(auto-fill, minmax(100%, 1fr));
        gap: 15px;
    }

    .portfolio-section {
        padding: 3rem 0;
    }

    .section-title h2 {
        font-size: 1.8rem;
    }

    .section-title p {
        font-size: 0.95rem;
    }
}