/* Custom CSS for Suhail's Portfolio */

.glow-border {
    position: relative;
}
.glow-border::after {
    content: '';
    position: absolute;
    inset: -1px;
    border-radius: 0.75rem; /* xl border radius matching tailwind rounded-xl */
    background: linear-gradient(45deg, transparent, rgba(16, 185, 129, 0.3), transparent);
    z-index: -1;
}

.active-nav {
    color: #4edea3 !important;
    font-weight: 700;
}

.material-symbols-outlined {
    font-display: block;
}

/* Scroll Reveal Animations */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s ease-out;
}

.reveal.active {
    opacity: 1;
    transform: translateY(0);
}

.reveal-delay-200 {
    transition-delay: 200ms;
}

/* Portfolio Filter transitions */
.portfolio-item {
    transition: all 0.4s ease;
}

/* Service Card Active State (Mobile Scroll) */
.service-card.active {
    background-color: #4edea3 !important; /* bg-primary */
    border-color: transparent !important;
}

.service-card.active h3,
.service-card.active p,
.service-card.active .material-symbols-outlined {
    color: #003824 !important; /* text-on-primary */
}

.service-card.active .material-symbols-outlined {
    transform: scale(1.1);
}

/* Dynamic Image Floating Animation */
@keyframes float {
    0% { transform: translateY(0px); }
    50% { transform: translateY(-15px); }
    100% { transform: translateY(0px); }
}

.dynamic-img {
    animation: float 4s ease-in-out infinite;
    will-change: transform;
}

/* 3D Pop-out effect for service cards */
.service-card {
    transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1), box-shadow 0.5s ease, background-color 0.5s ease;
    transform-style: preserve-3d;
}

.service-card:hover {
    transform: perspective(1000px) rotateX(8deg) rotateY(-8deg) translateY(-10px) scale(1.02);
    box-shadow: 20px 20px 40px -10px rgba(16, 185, 129, 0.2), 
               -20px -20px 40px -10px rgba(255,255,255,0.02);
}

.service-card > * {
    transition: transform 0.5s ease;
}

.service-card:hover > * {
    transform: translateZ(40px);
}

/* 3D Pop-out effect for portfolio items */
.portfolio-item {
    transition: all 0.5s ease;
    perspective: 1000px;
}

.portfolio-item:hover .card-3d {
    transform: rotateX(5deg) rotateY(-5deg) translateY(-10px) scale(1.02);
    box-shadow: 20px 20px 40px -10px rgba(16, 185, 129, 0.3);
}

.portfolio-item:hover .item-content-3d {
    transform: translateY(-5px);
}

/* Dynamic Rotating Border for Hero Image */
.hero-img-container {
    position: relative;
    padding: 4px; /* Professional border width */
    border-radius: 1.5rem; 
    overflow: hidden;
    background-color: #111827; /* Matches website background */
}

.hero-img-container::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: conic-gradient(transparent, rgba(78, 222, 163, 0.1), #4edea3);
    animation: border-spin 4s linear infinite;
    z-index: 0;
}

.hero-img-container::after {
    content: '';
    position: absolute;
    inset: 4px; /* Matches padding */
    background: #111827; /* Matches website background */
    border-radius: calc(1.5rem - 4px);
    z-index: 1;
}

.hero-img-container img {
    position: relative;
    z-index: 2;
    border-radius: calc(1.5rem - 4px);
}

.hero-img-container .img-overlay {
    position: absolute;
    inset: 4px;
    background: linear-gradient(to top, #111827 0%, rgba(17, 24, 39, 0.1) 40%, transparent 100%);
    z-index: 3;
    border-radius: calc(1.5rem - 4px);
    pointer-events: none;
}

@keyframes border-spin {
    100% {
        transform: rotate(360deg);
    }
}

