* {
    font-family: 'Inter', sans-serif;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Poppins', sans-serif;
}

:root {
    --primary: #1e40af;
    --secondary: #0d397a;
    --accent: #38bdf8;
    --highlight: #60a5fa;
    --dark: #0b1d3a;
    --light: #f1f5f9;
}

/* Animated Gradient Background */
.gradient-bg {
    background: linear-gradient(135deg, #0d397a, #1e40af);
    background-size: 200% 200%;
    animation: gradient 12s ease infinite;
}

@keyframes gradient {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

/* Glassmorphism */
.glass {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 8px 32px 0 rgba(31, 38, 135, 0.37);
}

.glass-white {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.3);
}

/* 3D Card Effect */
.card-3d {
    transform-style: preserve-3d;
    transition: all 0.5s cubic-bezier(0.23, 1, 0.320, 1);
}

.card-3d:hover {
    transform: translateY(-10px) rotateX(5deg) rotateY(5deg);
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
}

/* Hero slideshow */
.hero-slideshow {
    position: absolute;
    inset: 0;
    overflow: hidden;
    z-index: 0;
}

.hero-slide {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    opacity: 0;
    transform: scale(1.05);
    animation: heroSlide 40s ease-in-out infinite;
}

.hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(13, 57, 122, 0.78), rgba(30, 64, 175, 0.72));
    z-index: 1;
    pointer-events: none;
}

.hero-shapes {
    z-index: 2;
    pointer-events: none;
}

/* Floating Animation */
@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-20px); }
}

.float-animation {
    animation: float 6s ease-in-out infinite;
}

/* Pulse Animation */
@keyframes pulse-slow {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

.pulse-slow {
    animation: pulse-slow 4s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

/* Smooth Gradient Text */
.gradient-text {
    background: linear-gradient(135deg, #0d397a 0%, #1e40af 50%, #60a5fa 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Section heading helper */
.section-heading {
    max-width: 48rem;
    margin-left: auto;
    margin-right: auto;
}

/* Modern Button */
.btn-modern {
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
}

.btn-modern::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
    transition: left 0.5s;
}

.btn-modern:hover::before {
    left: 100%;
}

/* Skill Bar Animation */
.skill-bar {
    height: 8px;
    background: #e5e7eb;
    border-radius: 10px;
    overflow: hidden;
    position: relative;
}

.skill-bar-fill {
    height: 100%;
    background: linear-gradient(90deg, #3b82f6, #8b5cf6);
    border-radius: 10px;
    transition: width 2s ease;
}

/* Parallax */
.parallax {
    background-attachment: fixed;
    background-position: center;
    background-repeat: no-repeat;
    background-size: cover;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: #1e293b;
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, #3b82f6, #8b5cf6);
    border-radius: 10px;
}

/* Navbar Blur Effect */
.navbar-blur {
    backdrop-filter: blur(20px);
    background: rgba(255, 255, 255, 0.8);
    border-bottom: 1px solid rgba(255, 255, 255, 0.3);
}

/* Icon Hover Effect */
.icon-hover {
    transition: all 0.3s ease;
}

.icon-hover:hover {
    transform: scale(1.2) rotate(10deg);
}

/* Typing Animation */
@keyframes typing {
    from { width: 0 }
    to { width: 100% }
}

/* Modern Shadow */
.shadow-modern {
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
}

.shadow-modern-lg {
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
}

/* Hover Glow Effect */
.hover-glow {
    transition: all 0.3s ease;
}

.hover-glow:hover {
    box-shadow: 0 0 30px rgba(30, 64, 175, 0.45);
}

@keyframes heroSlide {
    0% {
        opacity: 1;
        transform: scale(1.05);
    }
    20% {
        opacity: 1;
        transform: scale(1.1);
    }
    30% {
        opacity: 0;
        transform: scale(1.12);
    }
    90% {
        opacity: 0;
        transform: scale(1.15);
    }
    100% {
        opacity: 1;
        transform: scale(1.05);
    }
}

.hero-slide:nth-child(1) {
    animation-delay: 0s;
}

.hero-slide:nth-child(2) {
    animation-delay: 8s;
}

.hero-slide:nth-child(3) {
    animation-delay: 16s;
}

.hero-slide:nth-child(4) {
    animation-delay: 24s;
}

.hero-slide:nth-child(5) {
    animation-delay: 32s;
}

/* Scroll Spy Navigation */
.nav-link {
    position: relative;
    padding-bottom: 4px;
}

.nav-link::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(135deg, #0d397a, #1e40af);
    transition: width 0.3s ease;
}

.nav-link.active::after,
.nav-link:hover::after {
    width: 100%;
}

.nav-link.active {
    color: var(--primary);
    font-weight: 600;
}

/* Back to top button */
#backToTop {
    position: fixed;
    right: 24px;
    bottom: 32px;
    width: 52px;
    height: 52px;
    border-radius: 9999px;
    background: linear-gradient(135deg, #0d397a, #1e40af);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 20px 40px -12px rgba(14, 50, 112, 0.5);
    opacity: 0;
    pointer-events: none;
    transform: translateY(20px);
    transition: all 0.3s ease;
    z-index: 60;
}

#backToTop.visible {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
}

/* Validation Error Styles */
.text-validation-error {
    display: block;
    color: #ef4444;
    font-size: 0.875rem;
    margin-top: 0.25rem;
    font-weight: 500;
}

.input-validation-error {
    border-color: #ef4444 !important;
    background-color: #fef2f2 !important;
}

.field-validation-error {
    color: #ef4444;
    font-size: 0.875rem;
    display: block;
    margin-top: 0.25rem;
    font-weight: 500;
}

.field-validation-valid {
    display: none;
}
