/* Portfolio Animated Shapes */
.portfolio-animated-bg {
    overflow: hidden;
    position: relative;
}

.animated-shapes {
    position: relative;
    width: 100%;
    height: 100%;
    min-height: 280px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    padding: 25px;
}

.animated-shapes::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.35);
    z-index: 1;
    transition: all 0.4s ease;
}

.latest-portfolio-card:hover .animated-shapes::before {
    background: rgba(0, 0, 0, 0.45);
}

.animated-shapes .portfolio-overlay-content {
    position: absolute;
    z-index: 10;
    color: white;
    text-align: center;
    width: 100%;
    max-width: 100%;
    margin: 0 auto;
    transform: translateY(20px);
    opacity: 1;
    transition: all 0.4s ease;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
}

.animated-shapes .portfolio-overlay-content .project-title {
    font-size: 26px;
    font-weight: 700;
    margin-bottom: 12px;
    margin-left: 0;
    margin-right: 0;
    color: white;
    transform: translateY(0);
    transition: transform 0.4s ease;
    text-align: center;
    text-shadow: 0 3px 12px rgba(0, 0, 0, 0.7);
    letter-spacing: -0.5px;
    line-height: 1.2;
}

.animated-shapes .portfolio-overlay-content .project-description {
    font-size: 15px;
    margin: 0;
    margin-bottom: 16px;
    color: rgba(255, 255, 255, 0.95);
    transform: translateY(0);
    transition: transform 0.4s ease;
    text-align: center;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.6);
    font-weight: 500;
    line-height: 1.5;
}

.animated-shapes .portfolio-overlay-content .tech-stack {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.85);
    display: block;
    margin-top: 8px;
    margin-bottom: 20px;
    text-shadow: 0 2px 6px rgba(0, 0, 0, 0.5);
    font-weight: 400;
    letter-spacing: 0.5px;
    opacity: 0.9;
}

/* Visit Button Styles */
.animated-shapes .portfolio-overlay-content .visit-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 28px;
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(10px);
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 50px;
    color: white;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    opacity: 0;
    transform: translateY(10px);
    margin-top: 12px;
    letter-spacing: 0.3px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.visit-btn svg {
    transition: transform 0.3s ease;
}

.visit-btn:hover {
    background: rgba(255, 255, 255, 0.95);
    color: #1a1a1a;
    border-color: rgba(255, 255, 255, 0.95);
    transform: translateY(8px) scale(1.05);
    box-shadow: 0 6px 25px rgba(0, 0, 0, 0.35);
}

.visit-btn:hover svg {
    transform: translateX(4px);
}

.latest-portfolio-card:hover .visit-btn {
    opacity: 1;
    transform: translateY(0);
    transition-delay: 0.1s;
}

/* Hover Effects for Text */
.latest-portfolio-card:hover .portfolio-overlay-content {
    transform: translateY(-8px);
    opacity: 1;
}

.latest-portfolio-card:hover .portfolio-overlay-content .project-title {
    transform: translateY(-5px);
}

.latest-portfolio-card:hover .portfolio-overlay-content .project-description {
    transform: translateY(-3px);
}

/* Gradient Backgrounds */
.gradient-1 {
    background: linear-gradient(135deg, #5568d3 0%, #6a3d8f 100%);
}

.gradient-2 {
    background: linear-gradient(135deg, #e579e5 0%, #e03e52 100%);
}

.gradient-3 {
    background: linear-gradient(135deg, #3a8ee6 0%, #00d4e6 100%);
}

.gradient-4 {
    background: linear-gradient(135deg, #2ec66a 0%, #1fd4b8 100%);
}

.gradient-5 {
    background: linear-gradient(135deg, #e85b82 0%, #f0cf2a 100%);
}

.gradient-6 {
    background: linear-gradient(135deg, #1ea7a8 0%, #2a0850 100%);
}

/* Shape Base Styles */
.shape {
    position: absolute;
    opacity: 0.3;
    transition: all 0.3s ease;
}

/* Circles */
.circle-1, .circle-2, .circle-3, .circle-4, .circle-5 {
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
}

.circle-1 {
    width: 90px;
    height: 90px;
    top: 5%;
    left: 8%;
    animation: float 6s ease-in-out infinite;
}

.circle-2 {
    width: 60px;
    height: 60px;
    bottom: 10%;
    right: 12%;
    animation: float 8s ease-in-out infinite reverse;
}

.circle-3 {
    width: 75px;
    height: 75px;
    top: 15%;
    right: 8%;
    animation: float 7s ease-in-out infinite;
}

.circle-4 {
    width: 70px;
    height: 70px;
    bottom: 25%;
    left: 5%;
    animation: float 9s ease-in-out infinite;
}

.circle-5 {
    width: 85px;
    height: 85px;
    top: 60%;
    right: 5%;
    animation: float 5s ease-in-out infinite reverse;
}

/* Squares */
.square-1, .square-2, .square-3, .square-4 {
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(5px);
}

.square-1 {
    width: 45px;
    height: 45px;
    bottom: 35%;
    left: 70%;
    animation: rotate 10s linear infinite, float 5s ease-in-out infinite;
}

.square-2 {
    width: 50px;
    height: 50px;
    top: 8%;
    left: 50%;
    animation: rotate 12s linear infinite reverse, float 6s ease-in-out infinite;
}

.square-3 {
    width: 40px;
    height: 40px;
    top: 70%;
    right: 25%;
    animation: rotate 8s linear infinite, float 7s ease-in-out infinite reverse;
}

.square-4 {
    width: 48px;
    height: 48px;
    bottom: 8%;
    right: 40%;
    animation: rotate 11s linear infinite reverse, float 6s ease-in-out infinite;
}

/* Triangles */
.triangle-1, .triangle-2, .triangle-3, .triangle-4 {
    width: 0;
    height: 0;
    border-left: 30px solid transparent;
    border-right: 30px solid transparent;
    border-bottom: 55px solid rgba(255, 255, 255, 0.2);
}

.triangle-1 {
    top: 40%;
    right: 10%;
    animation: rotate 15s linear infinite, float 8s ease-in-out infinite;
}

.triangle-2 {
    bottom: 5%;
    right: 65%;
    animation: rotate 13s linear infinite reverse, float 7s ease-in-out infinite reverse;
}

.triangle-3 {
    top: 10%;
    left: 28%;
    animation: rotate 14s linear infinite, float 9s ease-in-out infinite;
}

.triangle-4 {
    top: 55%;
    right: 50%;
    animation: rotate 16s linear infinite reverse, float 6s ease-in-out infinite reverse;
}

/* Hexagons */
.hexagon-1, .hexagon-2, .hexagon-3 {
    width: 60px;
    height: 35px;
    background: rgba(255, 255, 255, 0.2);
    position: relative;
}

.hexagon-1::before, .hexagon-2::before, .hexagon-3::before,
.hexagon-1::after, .hexagon-2::after, .hexagon-3::after {
    content: "";
    position: absolute;
    width: 0;
    border-left: 30px solid transparent;
    border-right: 30px solid transparent;
}

.hexagon-1::before, .hexagon-2::before, .hexagon-3::before {
    bottom: 100%;
    border-bottom: 17.5px solid rgba(255, 255, 255, 0.2);
}

.hexagon-1::after, .hexagon-2::after, .hexagon-3::after {
    top: 100%;
    border-top: 17.5px solid rgba(255, 255, 255, 0.2);
}

.hexagon-1 {
    top: 75%;
    left: 15%;
    animation: rotate 20s linear infinite, float 10s ease-in-out infinite;
}

.hexagon-2 {
    bottom: 50%;
    left: 85%;
    animation: rotate 18s linear infinite reverse, float 8s ease-in-out infinite reverse;
}

.hexagon-3 {
    top: 35%;
    left: 65%;
    animation: rotate 22s linear infinite, float 9s ease-in-out infinite;
}

/* Animations */
@keyframes float {
    0%, 100% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(-20px);
    }
}

@keyframes rotate {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

/* Hover Effects */
.latest-portfolio-card:hover .shape {
    opacity: 0.6;
    transform: scale(1.15);
}

.latest-portfolio-card:hover .animated-shapes {
    transform: scale(1.02);
}

/* Responsive */
@media (max-width: 768px) {
    .animated-shapes {
        min-height: 250px;
        padding: 20px;
    }

    .animated-shapes .portfolio-overlay-content .project-title {
        font-size: 22px;
    }

    .animated-shapes .portfolio-overlay-content .project-description {
        font-size: 14px;
    }

    .visit-btn {
        padding: 10px 22px;
        font-size: 13px;
    }

    .circle-1, .circle-2, .circle-3, .circle-4, .circle-5 {
        width: 60px;
        height: 60px;
    }

    .square-1, .square-2, .square-3, .square-4 {
        width: 40px;
        height: 40px;
    }

    .hexagon-1, .hexagon-2, .hexagon-3 {
        width: 50px;
        height: 29px;
    }

    .hexagon-1::before, .hexagon-2::before, .hexagon-3::before,
    .hexagon-1::after, .hexagon-2::after, .hexagon-3::after {
        border-left: 25px solid transparent;
        border-right: 25px solid transparent;
    }

    .hexagon-1::before, .hexagon-2::before, .hexagon-3::before {
        border-bottom: 14.5px solid rgba(255, 255, 255, 0.2);
    }

    .hexagon-1::after, .hexagon-2::after, .hexagon-3::after {
        border-top: 14.5px solid rgba(255, 255, 255, 0.2);
    }
}
