/**
 * Visual Identity Innovations - Bhavyam Infotech
 * Modern, Fresh, and Intuitive Design Enhancements
 * Created: January 2026
 */

/* ========================================
   1. PARALLAX SCROLLING EFFECTS
   ======================================== */

/* Hero Section with Depth Layers */
.tj-hero-section-three {
    position: relative;
    overflow: hidden;
    min-height: 100vh;
}

/* Parallax Background Layers */
.hero-parallax-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 120%;
    background-size: cover;
    background-position: center;
    will-change: transform;
    transition: transform 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* Floating Elements Animation */
.floating-element {
    position: absolute;
    animation: float 6s ease-in-out infinite;
    opacity: 0.1;
}

@keyframes float {
    0%, 100% {
        transform: translateY(0px) rotate(0deg);
    }
    50% {
        transform: translateY(-30px) rotate(5deg);
    }
}

/* Geometric Shapes */
.hero-shape-1 {
    position: absolute;
    top: 15%;
    right: 10%;
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, var(--color-brown), var(--color-gold));
    border-radius: 20px;
    animation: float 5s ease-in-out infinite;
    opacity: 0.15;
}

.hero-shape-2 {
    position: absolute;
    bottom: 20%;
    left: 8%;
    width: 60px;
    height: 60px;
    border: 3px solid var(--color-gold);
    border-radius: 50%;
    animation: float 7s ease-in-out infinite 1s;
    opacity: 0.12;
}

.hero-shape-3 {
    position: absolute;
    top: 40%;
    left: 15%;
    width: 40px;
    height: 40px;
    background: var(--color-gold);
    transform: rotate(45deg);
    animation: float 6s ease-in-out infinite 2s;
    opacity: 0.1;
}

/* ========================================
   2. GLASSMORPHISM DESIGN
   ======================================== */

/* Glass Card Effect */
.glass-card {
    background: rgba(255, 255, 255, 0.75);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border: 1px solid rgba(255, 255, 255, 0.3);
    box-shadow: 0 8px 32px rgba(55, 28, 21, 0.1),
                inset 0 1px 1px rgba(255, 255, 255, 0.5);
    border-radius: var(--radius-lg);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.glass-card:hover {
    background: rgba(255, 255, 255, 0.85);
    transform: translateY(-8px);
    box-shadow: 0 16px 48px rgba(55, 28, 21, 0.15),
                inset 0 1px 1px rgba(255, 255, 255, 0.6);
}

/* Glass Navigation - Applied to Header */
.glass-header {
    background: rgba(255, 255, 255, 0.8) !important;
    backdrop-filter: blur(15px) saturate(180%);
    -webkit-backdrop-filter: blur(15px) saturate(180%);
    box-shadow: 0 4px 30px rgba(55, 28, 21, 0.08);
    border-bottom: 1px solid rgba(255, 255, 255, 0.3);
}

/* Glass CTA Buttons */
.glass-button {
    background: rgba(196, 115, 0, 0.15);
    backdrop-filter: blur(10px);
    border: 2px solid rgba(196, 115, 0, 0.3);
    color: var(--color-brown);
    position: relative;
    overflow: hidden;
}

.glass-button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
    transition: left 0.5s;
}

.glass-button:hover::before {
    left: 100%;
}

.glass-button:hover {
    background: rgba(196, 115, 0, 0.25);
    border-color: var(--color-brown);
    transform: translateY(-3px);
}

/* ========================================
   3. 3D MICRO-INTERACTIONS
   ======================================== */

/* 3D Card Tilt Effect */
.tilt-card {
    perspective: 1000px;
    transform-style: preserve-3d;
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.tilt-card-inner {
    transform-style: preserve-3d;
    transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.tilt-card:hover .tilt-card-inner {
    transform: rotateY(5deg) rotateX(-5deg) translateZ(20px);
}

/* Floating Shadow Effect */
.floating-shadow {
    position: relative;
}

.floating-shadow::after {
    content: '';
    position: absolute;
    bottom: -20px;
    left: 10%;
    right: 10%;
    height: 20px;
    background: radial-gradient(ellipse, rgba(55, 28, 21, 0.2), transparent);
    filter: blur(10px);
    opacity: 0;
    transition: all 0.4s ease;
}

.floating-shadow:hover::after {
    opacity: 1;
    bottom: -30px;
}

/* 3D Button Press Effect */
.press-button {
    transform-style: preserve-3d;
    transition: all 0.2s ease;
}

.press-button:active {
    transform: translateZ(-10px) scale(0.98);
    box-shadow: 0 2px 10px rgba(55, 28, 21, 0.2);
}

/* Isometric Card Effect */
.isometric-card {
    transform: rotateX(15deg) rotateY(-15deg);
    transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.isometric-card:hover {
    transform: rotateX(0deg) rotateY(0deg) translateZ(30px);
}

/* ========================================
   4. SCROLL-TRIGGERED ANIMATIONS
   ======================================== */

/* Fade In Up Animation */
.fade-in-up {
    opacity: 0;
    transform: translateY(60px);
    transition: opacity 0.8s cubic-bezier(0.4, 0, 0.2, 1),
                transform 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.fade-in-up.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Stagger Animation for Multiple Elements */
.stagger-item {
    opacity: 0;
    transform: translateY(40px);
}

.stagger-item.visible {
    animation: staggerFadeIn 0.8s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

.stagger-item:nth-child(1) { animation-delay: 0.1s; }
.stagger-item:nth-child(2) { animation-delay: 0.2s; }
.stagger-item:nth-child(3) { animation-delay: 0.3s; }
.stagger-item:nth-child(4) { animation-delay: 0.4s; }
.stagger-item:nth-child(5) { animation-delay: 0.5s; }
.stagger-item:nth-child(6) { animation-delay: 0.6s; }

@keyframes staggerFadeIn {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Slide In From Left */
.slide-in-left {
    opacity: 0;
    transform: translateX(-60px);
    transition: opacity 0.8s cubic-bezier(0.4, 0, 0.2, 1),
                transform 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.slide-in-left.visible {
    opacity: 1;
    transform: translateX(0);
}

/* Slide In From Right */
.slide-in-right {
    opacity: 0;
    transform: translateX(60px);
    transition: opacity 0.8s cubic-bezier(0.4, 0, 0.2, 1),
                transform 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.slide-in-right.visible {
    opacity: 1;
    transform: translateX(0);
}

/* Scale In Animation */
.scale-in {
    opacity: 0;
    transform: scale(0.8);
    transition: opacity 0.6s cubic-bezier(0.4, 0, 0.2, 1),
                transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.scale-in.visible {
    opacity: 1;
    transform: scale(1);
}

/* Rotate In Animation */
.rotate-in {
    opacity: 0;
    transform: rotate(-10deg) scale(0.9);
    transition: opacity 0.7s cubic-bezier(0.4, 0, 0.2, 1),
                transform 0.7s cubic-bezier(0.4, 0, 0.2, 1);
}

.rotate-in.visible {
    opacity: 1;
    transform: rotate(0deg) scale(1);
}

/* ========================================
   5. ANIMATED GRADIENT BACKGROUNDS
   ======================================== */

/* Gradient Shift Animation */
.gradient-shift {
    background: linear-gradient(-45deg,
        var(--color-dark-brown),
        var(--color-brown),
        var(--color-gold),
        #d4a574);
    background-size: 400% 400%;
    animation: gradientShift 15s ease infinite;
}

@keyframes gradientShift {
    0% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0% 50%;
    }
}

/* Mesh Gradient Background */
.mesh-gradient {
    background:
        radial-gradient(at 20% 30%, rgba(196, 115, 0, 0.15) 0%, transparent 50%),
        radial-gradient(at 80% 70%, rgba(185, 179, 90, 0.15) 0%, transparent 50%),
        radial-gradient(at 40% 80%, rgba(55, 28, 21, 0.1) 0%, transparent 50%);
    background-color: #fefdfb;
    animation: meshMove 20s ease-in-out infinite;
}

@keyframes meshMove {
    0%, 100% {
        background-position: 0% 50%, 100% 50%, 50% 100%;
    }
    50% {
        background-position: 100% 50%, 0% 50%, 50% 0%;
    }
}

/* Holographic Effect */
.holographic {
    position: relative;
    overflow: hidden;
}

.holographic::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(
        45deg,
        transparent 30%,
        rgba(255, 255, 255, 0.1) 50%,
        transparent 70%
    );
    animation: holographicMove 3s linear infinite;
}

@keyframes holographicMove {
    0% {
        transform: translateX(-100%) translateY(-100%);
    }
    100% {
        transform: translateX(100%) translateY(100%);
    }
}

/* ========================================
   6. CUSTOM CURSOR EFFECTS
   ======================================== */

/* Custom Cursor Dot */
.custom-cursor {
    width: 40px;
    height: 40px;
    border: 2px solid var(--color-brown);
    border-radius: 50%;
    position: fixed;
    pointer-events: none;
    transition: all 0.15s ease;
    transform: translate(-50%, -50%);
    z-index: 99999;
    mix-blend-mode: difference;
}

.custom-cursor.active {
    transform: translate(-50%, -50%) scale(1.5);
    background: rgba(196, 115, 0, 0.2);
}

.custom-cursor-dot {
    width: 8px;
    height: 8px;
    background: var(--color-brown);
    border-radius: 50%;
    position: fixed;
    pointer-events: none;
    transform: translate(-50%, -50%);
    z-index: 99998;
    transition: width 0.2s ease, height 0.2s ease;
}

/* Cursor Magnetic Effect */
.magnetic-area {
    position: relative;
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ========================================
   7. ADVANCED HOVER EFFECTS
   ======================================== */

/* Neon Glow Effect */
.neon-hover {
    position: relative;
    transition: all 0.3s ease;
}

.neon-hover:hover {
    box-shadow: 0 0 20px rgba(196, 115, 0, 0.4),
                0 0 40px rgba(196, 115, 0, 0.2),
                0 0 60px rgba(196, 115, 0, 0.1);
    transform: translateY(-5px);
}

/* Ripple Effect */
.ripple-effect {
    position: relative;
    overflow: hidden;
}

.ripple-effect::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.5);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.ripple-effect:active::after {
    width: 300px;
    height: 300px;
}

/* Shine Effect */
.shine-effect {
    position: relative;
    overflow: hidden;
}

.shine-effect::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 50%;
    height: 100%;
    background: linear-gradient(90deg,
        transparent,
        rgba(255, 255, 255, 0.4),
        transparent);
    transition: left 0.5s;
}

.shine-effect:hover::before {
    left: 100%;
}

/* ========================================
   8. LOADING ANIMATIONS
   ======================================== */

/* Skeleton Loading */
.skeleton {
    background: linear-gradient(90deg,
        #f0f0f0 25%,
        #e0e0e0 50%,
        #f0f0f0 75%);
    background-size: 200% 100%;
    animation: skeletonLoading 1.5s ease-in-out infinite;
    border-radius: 4px;
}

@keyframes skeletonLoading {
    0% {
        background-position: 200% 0;
    }
    100% {
        background-position: -200% 0;
    }
}

/* Pulse Loading */
.pulse-loading {
    animation: pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

@keyframes pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.5;
    }
}

/* Spinner */
.spinner {
    width: 50px;
    height: 50px;
    border: 4px solid rgba(196, 115, 0, 0.1);
    border-top-color: var(--color-brown);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

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

/* ========================================
   9. TEXT ANIMATIONS
   ======================================== */

/* Gradient Text */
.gradient-text {
    background: linear-gradient(135deg, var(--color-brown), var(--color-gold));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: gradientTextShift 5s ease infinite;
    background-size: 200% auto;
}

@keyframes gradientTextShift {
    0%, 100% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
}

/* Typewriter Effect */
.typewriter {
    overflow: hidden;
    border-right: 3px solid var(--color-brown);
    white-space: nowrap;
    animation: typing 3.5s steps(40) 1s 1 normal both,
               blinkCursor 0.75s step-end infinite;
}

@keyframes typing {
    from {
        width: 0;
    }
    to {
        width: 100%;
    }
}

@keyframes blinkCursor {
    from, to {
        border-color: transparent;
    }
    50% {
        border-color: var(--color-brown);
    }
}

/* Text Reveal Animation */
.text-reveal {
    position: relative;
    overflow: hidden;
}

.text-reveal::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--color-brown);
    transform: translateX(-100%);
}

.text-reveal.visible::after {
    animation: textReveal 1.5s cubic-bezier(0.77, 0, 0.18, 1) forwards;
}

@keyframes textReveal {
    0% {
        transform: translateX(-100%);
    }
    50% {
        transform: translateX(0);
    }
    100% {
        transform: translateX(100%);
    }
}

/* ========================================
   10. PARTICLE EFFECTS
   ======================================== */

/* Floating Particles Container */
.particles-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    pointer-events: none;
}

.particle {
    position: absolute;
    width: 4px;
    height: 4px;
    background: var(--color-gold);
    border-radius: 50%;
    opacity: 0.3;
    animation: particleFloat 15s linear infinite;
}

@keyframes particleFloat {
    0% {
        transform: translateY(100vh) translateX(0) rotate(0deg);
        opacity: 0;
    }
    10% {
        opacity: 0.3;
    }
    90% {
        opacity: 0.3;
    }
    100% {
        transform: translateY(-100px) translateX(100px) rotate(360deg);
        opacity: 0;
    }
}

/* Generate multiple particles with different delays */
.particle:nth-child(1) { left: 10%; animation-delay: 0s; }
.particle:nth-child(2) { left: 25%; animation-delay: 2s; animation-duration: 18s; }
.particle:nth-child(3) { left: 40%; animation-delay: 4s; animation-duration: 12s; }
.particle:nth-child(4) { left: 55%; animation-delay: 1s; animation-duration: 16s; }
.particle:nth-child(5) { left: 70%; animation-delay: 3s; animation-duration: 14s; }
.particle:nth-child(6) { left: 85%; animation-delay: 5s; animation-duration: 20s; }

/* ========================================
   11. SCROLL PROGRESS INDICATOR
   ======================================== */

.scroll-progress {
    position: fixed;
    top: 0;
    left: 0;
    width: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--color-brown), var(--color-gold));
    z-index: 99999;
    transition: width 0.2s ease;
    box-shadow: 0 0 10px rgba(196, 115, 0, 0.5);
}

/* ========================================
   12. ENHANCED SECTION DIVIDERS
   ======================================== */

/* Section divider - wave removed, using clean accent lines */
.section-divider {
    display: none;
}

.wave-divider {
    display: none;
}

/* Diagonal Divider */
.diagonal-divider {
    position: relative;
    height: 80px;
}

.diagonal-divider::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--color-white);
    transform: skewY(-2deg);
    transform-origin: top left;
}

/* ========================================
   13. INTERACTIVE ELEMENTS
   ======================================== */

/* Hover Lift Effect */
.hover-lift {
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1),
                box-shadow 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.hover-lift:hover {
    transform: translateY(-12px);
    box-shadow: 0 20px 60px rgba(55, 28, 21, 0.2);
}

/* Hover Expand Effect */
.hover-expand {
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.hover-expand:hover {
    transform: scale(1.05);
}

/* Border Animation */
.border-animate {
    position: relative;
}

.border-animate::before,
.border-animate::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    background: var(--color-brown);
    transition: width 0.4s ease;
}

.border-animate::before {
    top: 0;
    left: 0;
}

.border-animate::after {
    bottom: 0;
    right: 0;
}

.border-animate:hover::before,
.border-animate:hover::after {
    width: 100%;
}

/* ========================================
   14. RESPONSIVE ADJUSTMENTS
   ======================================== */

@media (max-width: 991px) {
    .custom-cursor,
    .custom-cursor-dot {
        display: none;
    }

    .hero-shape-1,
    .hero-shape-2,
    .hero-shape-3 {
        display: none;
    }

    .tilt-card:hover .tilt-card-inner {
        transform: none;
    }

    .isometric-card {
        transform: none;
    }

    .glass-card {
        backdrop-filter: blur(10px);
    }
}

@media (max-width: 767px) {
    .gradient-shift {
        animation: none;
        background: var(--color-brown);
    }

    .mesh-gradient {
        animation: none;
    }

    .particles-container {
        display: none;
    }

    .section-divider {
        height: 50px;
    }
}

/* ========================================
   15. PERFORMANCE OPTIMIZATIONS
   ======================================== */

/* Reduced Motion for Accessibility */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }

    .custom-cursor,
    .custom-cursor-dot {
        display: none;
    }
}

/* GPU Acceleration */
.gpu-accelerated {
    transform: translateZ(0);
    will-change: transform;
}
