/* ===== CSS RESET & BASE STYLES ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
    /* Better font rendering on mobile */
    -webkit-text-size-adjust: 100%;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    line-height: 1.6;
    color: #e2e8f0;
    background: linear-gradient(135deg, #0f172a 0%, #1e293b 50%, #334155 100%);
    overflow-x: hidden;
    transition: all 0.3s ease;
    /* Improved mobile performance */
    -webkit-overflow-scrolling: touch;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

/* Mobile-first button and link improvements */
button, 
.btn, 
a[role="button"] {
    /* Minimum touch target size for mobile accessibility */
    min-height: 44px;
    min-width: 44px;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
}

/* Improved input fields for mobile */
input, 
textarea, 
select {
    /* Better mobile input styling */
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    border-radius: 8px;
    font-size: 16px; /* Prevents zoom on iOS */
    line-height: 1.5;
}

/* Prevent horizontal scroll on small screens */
img, 
video, 
iframe {
    max-width: 100%;
    height: auto;
}

/* Better mobile container */
.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
}

/* Mobile-first section spacing */
section {
    padding: 4rem 0;
    position: relative;
}

/* Flexible grid systems */
.grid {
    display: grid;
    gap: 1rem;
    width: 100%;
}

.flex {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
}

/* Mobile-friendly text sizes */
h1, h2, h3, h4, h5, h6 {
    line-height: 1.2;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

p {
    max-width: none;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

/* ===== ACCESSIBILITY MENU ===== */
.accessibility-menu {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 10000;
    font-family: inherit;
}

.accessibility-toggle {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: linear-gradient(135deg, #3b82f6 0%, #1d4ed8 100%);
    border: none;
    color: white;
    font-size: 1.2rem;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(59, 130, 246, 0.3);
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.accessibility-toggle:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 20px rgba(59, 130, 246, 0.4);
}

.accessibility-panel {
    position: absolute;
    top: 60px;
    right: 0;
    background: rgba(15, 23, 42, 0.95);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(71, 85, 105, 0.3);
    border-radius: 10px;
    padding: 1rem;
    min-width: 200px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
}

.accessibility-panel.active {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.accessibility-panel h3 {
    color: #f8fafc;
    margin: 0 0 1rem 0;
    font-size: 1rem;
    text-align: center;
}

.accessibility-controls {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.5rem;
}

.accessibility-btn {
    background: rgba(59, 130, 246, 0.2);
    border: 1px solid rgba(59, 130, 246, 0.3);
    color: #e2e8f0;
    padding: 0.5rem;
    border-radius: 5px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 0.9rem;
}

.accessibility-btn:hover {
    background: rgba(59, 130, 246, 0.3);
    border-color: rgba(59, 130, 246, 0.5);
}

/* High Contrast Mode */
.high-contrast {
    filter: contrast(200%) brightness(150%);
}

.high-contrast .hero,
.high-contrast .about,
.high-contrast .projects,
.high-contrast .testimonials,
.high-contrast .contact {
    background: #000 !important;
    color: #fff !important;
}

/* No Animations Mode */
.no-animations * {
    animation: none !important;
    transition: none !important;
}

/* ===== TYPOGRAPHY ===== */
h1, h2, h3, h4, h5, h6 {
    font-weight: 600;
    line-height: 1.2;
    margin-bottom: 1rem;
    color: #f8fafc;
}

h1 {
    font-size: clamp(2.5rem, 5vw, 4rem);
    font-weight: 700;
}

h2 {
    font-size: clamp(2rem, 4vw, 3rem);
}

h3 {
    font-size: clamp(1.5rem, 3vw, 2rem);
}

p {
    margin-bottom: 1rem;
    color: #94a3b8;
}

/* ===== UTILITY CLASSES ===== */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

.btn {
    display: inline-block;
    padding: 1rem 2rem;
    border: none;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 500;
    font-size: 1rem;
    transition: all 0.3s ease;
    cursor: pointer;
    text-align: center;
}

.btn-primary {
    background: linear-gradient(135deg, #3b82f6 0%, #1d4ed8 100%);
    color: white;
    box-shadow: 0 4px 15px rgba(59, 130, 246, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(59, 130, 246, 0.4);
    background: linear-gradient(135deg, #2563eb 0%, #1e40af 100%);
}

.btn-secondary {
    background: transparent;
    color: #e2e8f0;
    border: 2px solid #475569;
}

.btn-secondary:hover {
    background: #475569;
    color: white;
    transform: translateY(-2px);
    border-color: #64748b;
}

.btn-full {
    width: 100%;
}

/* ===== NAVIGATION ===== */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: rgba(15, 23, 42, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    z-index: 1000;
    padding: 1rem 0;
    transition: all 0.3s ease;
    border-bottom: 1px solid rgba(71, 85, 105, 0.3);
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-logo a {
    font-size: clamp(1.25rem, 2.5vw, 1.5rem);
    font-weight: 700;
    color: #f8fafc;
    text-decoration: none;
    transition: color 0.3s ease;
}

.nav-logo a:hover {
    color: #3b82f6;
}

.nav-menu {
    display: flex;
    gap: 2rem;
    list-style: none;
    margin: 0;
    padding: 0;
}

.nav-link {
    color: #94a3b8;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
    padding: 0.75rem 1rem;
    border-radius: 8px;
    min-height: 44px;
    display: flex;
    align-items: center;
    position: relative;
}

.nav-link:hover {
    color: #3b82f6;
    background: rgba(59, 130, 246, 0.1);
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 2px;
    background: #3b82f6;
    transition: all 0.3s ease;
    transform: translateX(-50%);
}

.nav-link:hover::after {
    width: 80%;
}

.nav-toggle {
    display: none;
    flex-direction: column;
    cursor: pointer;
    background: none;
    border: none;
    padding: 0.5rem;
    border-radius: 4px;
    transition: all 0.3s ease;
    min-height: 44px;
    min-width: 44px;
    justify-content: center;
    align-items: center;
}

.nav-toggle:hover {
    background: rgba(255, 255, 255, 0.1);
}

.nav-toggle span {
    width: 25px;
    height: 3px;
    background: #f8fafc;
    margin: 2px 0;
    transition: 0.3s;
    border-radius: 2px;
}

/* Mobile hamburger menu animation */
.nav-toggle.active span:nth-child(1) {
    transform: rotate(-45deg) translate(-5px, 6px);
}

.nav-toggle.active span:nth-child(2) {
    opacity: 0;
}

.nav-toggle.active span:nth-child(3) {
    transform: rotate(45deg) translate(-5px, -6px);
}

/* Mobile Navigation Styles */
@media (max-width: 768px) {
    .nav-container {
        padding: 0 1rem;
    }
    
    .nav-toggle {
        display: flex;
    }
    
    .nav-menu {
        position: fixed;
        top: 100%;
        left: 0;
        width: 100%;
        background: rgba(15, 23, 42, 0.98);
        backdrop-filter: blur(20px);
        -webkit-backdrop-filter: blur(20px);
        flex-direction: column;
        gap: 0;
        padding: 1rem 0;
        border-top: 1px solid rgba(255, 255, 255, 0.1);
        transform: translateY(-100vh);
        transition: transform 0.3s ease;
        opacity: 0;
        visibility: hidden;
        box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    }
    
    .nav-menu.active {
        transform: translateY(0);
        opacity: 1;
        visibility: visible;
    }
    
    .nav-link {
        padding: 1rem 2rem;
        border-radius: 0;
        font-size: 1rem;
        justify-content: flex-start;
        border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    }
    
    .nav-link::after {
        display: none;
    }
    
    .nav-link:hover {
        background: rgba(59, 130, 246, 0.15);
        padding-left: 2.5rem;
    }
    
    .nav-link:last-child {
        border-bottom: none;
    }
}

/* ===== HERO SECTION ===== */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    background: linear-gradient(135deg, rgba(15, 23, 42, 0.8) 0%, rgba(30, 41, 59, 0.8) 100%), 
                url('image/backgrund.jpg') center/cover no-repeat;
    overflow: hidden;
}

/* Parallax Background */
.parallax-container {
    position: relative;
    overflow: hidden;
}

.parallax-bg {
    position: absolute;
    top: -20%;
    left: 0;
    width: 100%;
    height: 120%;
    background: linear-gradient(45deg, 
        rgba(59, 130, 246, 0.1) 0%, 
        rgba(29, 78, 216, 0.1) 25%,
        rgba(99, 102, 241, 0.1) 50%,
        rgba(168, 85, 247, 0.1) 75%,
        rgba(236, 72, 153, 0.1) 100%);
    z-index: 1;
    animation: parallax-float 20s ease-in-out infinite;
}

@keyframes parallax-float {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    25% { transform: translateY(-20px) rotate(1deg); }
    50% { transform: translateY(-10px) rotate(-1deg); }
    75% { transform: translateY(-15px) rotate(0.5deg); }
}

/* Ensure Vanta.js background covers the entire hero section */
#vanta-bg {
    position: relative;
    z-index: 1;
}

/* Make sure content is above the Vanta.js background */
.hero-container {
    position: relative;
    z-index: 2;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    width: 100%;
}

.hero-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    min-height: 80vh;
}

.hero-text {
    animation: fadeInUp 1s ease-out;
}

.hero-name {
    font-size: clamp(3.5rem, 8vw, 6rem);
    font-weight: 800;
    color: #f8fafc;
    margin-bottom: 1rem;
    animation: fadeInUp 1s ease-out 0.2s both;
    line-height: 1.1;
    letter-spacing: -0.02em;
}

/* Typing Effect Container */
.typing-container {
    font-size: clamp(1.5rem, 4vw, 2.5rem);
    font-weight: 600;
    margin-bottom: 1.5rem;
    animation: fadeInUp 1s ease-out 0.4s both;
    min-height: 3rem;
    display: flex;
    align-items: center;
    justify-content: flex-start;
}

.typing-text {
    color: #3b82f6;
    background: linear-gradient(135deg, #3b82f6 0%, #60a5fa 50%, #93c5fd 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-weight: 600;
    letter-spacing: 0.02em;
}

.typing-cursor {
    color: #3b82f6;
    font-weight: 300;
    animation: blink 1s infinite;
    margin-left: 2px;
    font-size: 1.2em;
}

@keyframes blink {
    0%, 50% {
        opacity: 1;
    }
    51%, 100% {
        opacity: 0;
    }
}

.hero-title {
    font-size: clamp(1.5rem, 4vw, 2.5rem);
    color: #3b82f6;
    font-weight: 600;
    margin-bottom: 1.5rem;
    animation: fadeInUp 1s ease-out 0.4s both;
}

.hero-description {
    font-size: 1.2rem;
    color: #94a3b8;
    margin-bottom: 2rem;
    animation: fadeInUp 1s ease-out 0.6s both;
}

.hero-buttons {
    display: flex;
    gap: 1rem;
    animation: fadeInUp 1s ease-out 0.8s both;
}

.hero-visual {
    display: flex;
    justify-content: center;
    align-items: center;
    animation: fadeInRight 1s ease-out 0.5s both;
}

/* Floating Shapes Animation */
.floating-shapes {
    position: relative;
    width: 400px;
    height: 400px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.shape {
    position: absolute;
    border-radius: 50%;
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.3) 0%, rgba(29, 78, 216, 0.3) 100%);
    animation: float 6s ease-in-out infinite;
}

.shape-1 {
    width: 80px;
    height: 80px;
    top: 20%;
    left: 20%;
    animation-delay: 0s;
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.4) 0%, rgba(147, 197, 253, 0.4) 100%);
}

.shape-2 {
    width: 60px;
    height: 60px;
    top: 60%;
    right: 30%;
    animation-delay: 1s;
    background: linear-gradient(135deg, rgba(29, 78, 216, 0.3) 0%, rgba(59, 130, 246, 0.3) 100%);
}

.shape-3 {
    width: 100px;
    height: 100px;
    bottom: 20%;
    left: 40%;
    animation-delay: 2s;
    background: linear-gradient(135deg, rgba(147, 197, 253, 0.2) 0%, rgba(59, 130, 246, 0.2) 100%);
}

.shape-4 {
    width: 45px;
    height: 45px;
    top: 10%;
    right: 20%;
    animation-delay: 3s;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.3) 0%, rgba(139, 92, 246, 0.3) 100%);
}

.shape-5 {
    width: 70px;
    height: 70px;
    top: 40%;
    left: 10%;
    animation-delay: 4s;
    background: linear-gradient(135deg, rgba(168, 85, 247, 0.2) 0%, rgba(236, 72, 153, 0.2) 100%);
}

@keyframes float {
    0%, 100% {
        transform: translateY(0px) rotate(0deg);
    }
    25% {
        transform: translateY(-20px) rotate(90deg);
    }
    50% {
        transform: translateY(-10px) rotate(180deg);
    }
    75% {
        transform: translateY(-15px) rotate(270deg);
    }
}

.hero-placeholder {
    width: 400px;
    height: 400px;
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.1) 0%, rgba(29, 78, 216, 0.1) 100%);
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    border: 1px solid rgba(71, 85, 105, 0.3);
    /* Placeholder for 3D elements */
}

.hero-placeholder::before {
    content: "3D Element Placeholder";
    color: #64748b;
    font-size: 1rem;
    text-align: center;
}

.hero-scroll {
    position: absolute;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    text-align: center;
    color: #94a3b8;
    animation: fadeIn 1s ease-out 1s both;
    z-index: 3;
}

.scroll-indicator {
    width: 2px;
    height: 30px;
    background: #3b82f6;
    margin: 0.5rem auto;
    animation: bounce 2s infinite;
}

/* ===== SECTION STYLES ===== */
.section-header {
    text-align: center;
    margin-bottom: 4rem;
}

.section-title {
    color: #f8fafc;
    margin-bottom: 1rem;
}

.section-subtitle {
    font-size: 1.2rem;
    color: #94a3b8;
}

/* ===== ABOUT SECTION ===== */
.about {
    padding: 6rem 0;
    background: linear-gradient(135deg, #1e293b 0%, #334155 50%, #475569 100%);
}

.about-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.about-text h3 {
    color: #f8fafc;
    margin-bottom: 1.5rem;
}

.about-text p {
    margin-bottom: 1.5rem;
}

.skills-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    margin-top: 2rem;
}

.skill-item {
    padding: 1.5rem;
    background: #334155;
    border-radius: 10px;
    transition: transform 0.3s ease;
    border: 1px solid rgba(71, 85, 105, 0.3);
}

.skill-item:hover {
    transform: translateY(-5px);
    background: #475569;
}

.skill-item h4 {
    color: #3b82f6;
    margin-bottom: 0.5rem;
}

.skill-item p {
    color: #94a3b8;
    margin: 0;
}

.about-visual {
    display: flex;
    justify-content: center;
    align-items: center;
}

/* Animated 3D Profile Card */
.profile-card {
    position: relative;
    width: 320px;
    height: 400px;
    perspective: 1000px;
    cursor: pointer;
}

.profile-image-container {
    width: 100%;
    height: 100%;
    position: relative;
    transform-style: preserve-3d;
    transition: all 0.6s ease;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.profile-card:hover .profile-image-container {
    transform: rotateY(10deg) rotateX(5deg) scale(1.05);
    box-shadow: 0 30px 60px rgba(59, 130, 246, 0.4);
}

.profile-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 20px;
    transition: all 0.6s ease;
    filter: brightness(0.9) contrast(1.1);
}

.profile-card:hover .profile-image {
    filter: brightness(1) contrast(1.2);
}

.profile-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, 
        rgba(59, 130, 246, 0.1) 0%, 
        rgba(29, 78, 216, 0.2) 50%, 
        rgba(99, 102, 241, 0.1) 100%);
    border-radius: 20px;
    opacity: 0;
    transition: all 0.6s ease;
}

.profile-card:hover .profile-overlay {
    opacity: 1;
}

.profile-glow {
    position: absolute;
    top: -10px;
    left: -10px;
    right: -10px;
    bottom: -10px;
    background: linear-gradient(135deg, 
        rgba(59, 130, 246, 0.3) 0%, 
        rgba(147, 197, 253, 0.3) 50%, 
        rgba(99, 102, 241, 0.3) 100%);
    border-radius: 30px;
    filter: blur(20px);
    opacity: 0;
    transition: all 0.6s ease;
    z-index: -1;
    animation: pulse-glow 4s ease-in-out infinite;
}

.profile-card:hover .profile-glow {
    opacity: 0.7;
    animation: pulse-glow 2s ease-in-out infinite;
}

@keyframes pulse-glow {
    0%, 100% {
        transform: scale(0.95);
        opacity: 0.3;
    }
    50% {
        transform: scale(1.05);
        opacity: 0.7;
    }
}

/* Floating animation for the entire card */
.profile-card {
    animation: float-profile 6s ease-in-out infinite;
}

@keyframes float-profile {
    0%, 100% {
        transform: translateY(0px);
    }
    33% {
        transform: translateY(-10px);
    }
    66% {
        transform: translateY(5px);
    }
}

.about-placeholder {
    width: 300px;
    height: 300px;
    background: linear-gradient(135deg, #334155 0%, #475569 100%);
    border-radius: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(71, 85, 105, 0.3);
    /* Placeholder for profile image or 3D element */
}

.about-placeholder::before {
    content: "Profile Image / 3D Element";
    color: #64748b;
    text-align: center;
}

/* ===== PROJECTS SECTION ===== */
.projects {
    padding: 6rem 0;
    background: linear-gradient(135deg, #0f172a 0%, #1e293b 50%, #334155 100%);
}

.projects-coming-soon {
    text-align: center;
    padding: 4rem 0;
}

.coming-soon-content {
    max-width: 600px;
    margin: 0 auto;
}

.fire-emoji {
    font-size: 4rem;
    margin-bottom: 1rem;
    animation: pulse 2s infinite;
}

.coming-soon-title {
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 700;
    color: #f8fafc;
    margin-bottom: 1.5rem;
    background: linear-gradient(135deg, #3b82f6 0%, #1d4ed8 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.coming-soon-description {
    font-size: 1.2rem;
    color: #94a3b8;
    margin-bottom: 2rem;
}

.coming-soon-cta {
    margin-top: 2rem;
}

.projects-grid-placeholder {
    margin-top: 4rem;
    padding: 2rem;
    border: 2px dashed #475569;
    border-radius: 10px;
    color: #64748b;
    background: rgba(51, 65, 85, 0.3);
    /* Placeholder for future project grid */
}

/* ===== 3D MODELS SHOWCASE ===== */
.model-showcase {
    display: flex;
    justify-content: space-around;
    align-items: center;
    gap: 2rem;
    flex-wrap: wrap;
    min-height: 300px;
}

.model-container {
    perspective: 1000px;
    width: 150px;
    height: 150px;
}

/* 3D Cube */
.model-cube {
    position: relative;
    width: 100%;
    height: 100%;
    transform-style: preserve-3d;
    animation: cube-rotate 10s infinite linear;
}

.cube-face {
    position: absolute;
    width: 150px;
    height: 150px;
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.8) 0%, rgba(29, 78, 216, 0.8) 100%);
    border: 2px solid rgba(59, 130, 246, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    color: white;
    font-size: 1.2rem;
}

.cube-face.front { transform: rotateY(0deg) translateZ(75px); }
.cube-face.back { transform: rotateY(180deg) translateZ(75px); }
.cube-face.right { transform: rotateY(90deg) translateZ(75px); }
.cube-face.left { transform: rotateY(-90deg) translateZ(75px); }
.cube-face.top { transform: rotateX(90deg) translateZ(75px); }
.cube-face.bottom { transform: rotateX(-90deg) translateZ(75px); }

@keyframes cube-rotate {
    from { transform: rotateX(0deg) rotateY(0deg); }
    to { transform: rotateX(360deg) rotateY(360deg); }
}

/* 3D Sphere with Rings */
.model-sphere {
    position: relative;
    width: 150px;
    height: 150px;
    border-radius: 50%;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.8) 0%, rgba(168, 85, 247, 0.8) 100%);
    animation: sphere-pulse 3s ease-in-out infinite;
}

.sphere-ring {
    position: absolute;
    border: 3px solid rgba(147, 197, 253, 0.6);
    border-radius: 50%;
    animation: ring-rotate 8s linear infinite;
}

.ring-1 {
    width: 120%;
    height: 120%;
    top: -10%;
    left: -10%;
    animation-delay: 0s;
}

.ring-2 {
    width: 140%;
    height: 140%;
    top: -20%;
    left: -20%;
    animation-delay: 2s;
}

.ring-3 {
    width: 160%;
    height: 160%;
    top: -30%;
    left: -30%;
    animation-delay: 4s;
}

@keyframes sphere-pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.1); }
}

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

/* 3D Pyramid */
.model-pyramid {
    position: relative;
    width: 150px;
    height: 150px;
    transform-style: preserve-3d;
    animation: pyramid-spin 12s infinite linear;
}

.pyramid-face {
    position: absolute;
    width: 0;
    height: 0;
    border-style: solid;
}

.pyramid-front {
    border-left: 75px solid transparent;
    border-right: 75px solid transparent;
    border-bottom: 130px solid rgba(236, 72, 153, 0.8);
    transform: rotateX(-30deg) translateZ(65px);
}

.pyramid-right {
    border-left: 75px solid transparent;
    border-right: 75px solid transparent;
    border-bottom: 130px solid rgba(219, 39, 119, 0.8);
    transform: rotateY(90deg) rotateX(-30deg) translateZ(65px);
}

.pyramid-back {
    border-left: 75px solid transparent;
    border-right: 75px solid transparent;
    border-bottom: 130px solid rgba(190, 24, 93, 0.8);
    transform: rotateY(180deg) rotateX(-30deg) translateZ(65px);
}

.pyramid-left {
    border-left: 75px solid transparent;
    border-right: 75px solid transparent;
    border-bottom: 130px solid rgba(157, 23, 77, 0.8);
    transform: rotateY(-90deg) rotateX(-30deg) translateZ(65px);
}

@keyframes pyramid-spin {
    from { transform: rotateY(0deg) rotateX(0deg); }
    to { transform: rotateY(360deg) rotateX(360deg); }
}

/* ===== TESTIMONIALS SECTION ===== */
.testimonials {
    padding: 6rem 0;
    background: linear-gradient(135deg, #1e293b 0%, #334155 50%, #475569 100%);
}

.testimonials-placeholder {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    max-width: 800px;
    margin: 0 auto;
}

.testimonial-item {
    background: #334155;
    padding: 2rem;
    border-radius: 15px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
    transition: transform 0.3s ease;
    border: 1px solid rgba(71, 85, 105, 0.3);
}

.testimonial-item:hover {
    transform: translateY(-5px);
    background: #475569;
}

.testimonial-content p {
    font-style: italic;
    margin-bottom: 1.5rem;
    color: #cbd5e1;
}

.author-info h4 {
    color: #f8fafc;
    margin-bottom: 0.25rem;
}

.author-info p {
    color: #3b82f6;
    margin: 0;
    font-size: 0.9rem;
}

/* ===== CONTACT SECTION ===== */
.contact {
    padding: 6rem 0;
    background: linear-gradient(135deg, #1e40af 0%, #1d4ed8 100%);
    color: white;
}

.contact .section-title,
.contact .section-subtitle {
    color: white;
}

.contact-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: start;
}

.contact-info h3 {
    color: white;
    margin-bottom: 1.5rem;
}

.contact-info p {
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 2rem;
}

.contact-details {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.contact-item h4 {
    color: white;
    margin-bottom: 0.5rem;
}

.contact-item p {
    color: rgba(255, 255, 255, 0.9);
    margin: 0;
}

.contact-form {
    background: rgba(255, 255, 255, 0.1);
    padding: 2rem;
    border-radius: 15px;
    backdrop-filter: blur(10px);
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    color: white;
    font-weight: 500;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 1rem;
    border: none;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.9);
    font-family: inherit;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    background: white;
    box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.3);
}

.form-group textarea {
    resize: vertical;
    min-height: 120px;
}

/* ===== FOOTER ===== */
.footer {
    padding: 3rem 0 1rem;
    background: #0f172a;
    color: white;
    border-top: 1px solid rgba(71, 85, 105, 0.3);
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 2rem;
    gap: 2rem;
}

.footer-brand h3 {
    color: white;
    margin-bottom: 0.5rem;
}

.footer-brand p {
    color: #ccc;
    margin: 0;
}

.footer-links {
    display: flex;
    gap: 2rem;
}

.footer-links a {
    color: #ccc;
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-links a:hover {
    color: #3b82f6;
}

.footer-social h4 {
    color: white;
    margin-bottom: 1rem;
    font-size: 1rem;
}

.social-icons {
    display: flex;
    gap: 1rem;
}

.social-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: rgba(71, 85, 105, 0.3);
    border-radius: 50%;
    color: #ccc;
    text-decoration: none;
    font-size: 1.2rem;
    transition: all 0.3s ease;
    border: 1px solid rgba(71, 85, 105, 0.5);
}

.social-icon:hover {
    background: #3b82f6;
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
    border-color: #3b82f6;
}

.social-icon i {
    transition: transform 0.3s ease;
}

.social-icon:hover i {
    transform: scale(1.1);
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid #555;
}

.footer-bottom p {
    color: #ccc;
    margin: 0.5rem 0;
}

.powered-by {
    font-size: 0.9rem;
    opacity: 0.8;
}

.powered-by a {
    color: #3b82f6;
    text-decoration: none;
    transition: color 0.3s ease;
}

.powered-by a:hover {
    color: #60a5fa;
    text-decoration: underline;
}

/* ===== ANIMATIONS ===== */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInRight {
    from {
        opacity: 0;
        transform: translateX(30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@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);
    }
}

@keyframes pulse {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.1);
    }
    100% {
        transform: scale(1);
    }
}

/* ===== RESPONSIVE DESIGN ===== */

/* Large Tablets and Small Laptops (768px) */
@media (max-width: 768px) {
    .nav-menu {
        display: none;
    }
    
    .nav-toggle {
        display: flex;
    }
    
    .hero-content {
        grid-template-columns: 1fr;
        gap: 2rem;
        text-align: center;
        padding: 2rem 1rem;
    }
    
    .hero-name {
        font-size: clamp(2.5rem, 12vw, 4rem);
    }
    
    .hero-title {
        font-size: clamp(1.2rem, 6vw, 1.8rem);
    }
    
    .floating-shapes {
        width: 300px;
        height: 300px;
    }
    
    .shape-1 { width: 60px; height: 60px; }
    .shape-2 { width: 45px; height: 45px; }
    .shape-3 { width: 80px; height: 80px; }
    .shape-4 { width: 35px; height: 35px; }
    .shape-5 { width: 55px; height: 55px; }
    
    .profile-card {
        width: 280px;
        height: 350px;
    }
    
    .hero-buttons {
        flex-direction: column;
        align-items: center;
        gap: 1rem;
        width: 100%;
    }
    
    .hero-buttons .btn {
        width: 100%;
        max-width: 300px;
        padding: 1rem 2rem;
        font-size: 1rem;
    }
    
    .about-content {
        grid-template-columns: 1fr;
        gap: 2rem;
        text-align: center;
    }
    
    .skills-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .contact-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .footer-content {
        flex-direction: column;
        gap: 2rem;
        text-align: center;
    }
    
    .footer-links {
        justify-content: center;
        flex-wrap: wrap;
        gap: 1rem;
    }
    
    .footer-social {
        text-align: center;
    }
    
    .social-icons {
        justify-content: center;
        gap: 1.5rem;
    }
    
    .container {
        padding: 0 1rem;
        max-width: 100%;
    }
    
    .model-showcase {
        flex-direction: column;
        gap: 1rem;
        align-items: center;
    }
    
    .model-container {
        width: 120px;
        height: 120px;
    }
    
    .cube-face {
        width: 120px;
        height: 120px;
        font-size: 1rem;
    }
    
    .cube-face.front { transform: rotateY(0deg) translateZ(60px); }
    .cube-face.back { transform: rotateY(180deg) translateZ(60px); }
    .cube-face.right { transform: rotateY(90deg) translateZ(60px); }
    .cube-face.left { transform: rotateY(-90deg) translateZ(60px); }
    .cube-face.top { transform: rotateX(90deg) translateZ(60px); }
    .cube-face.bottom { transform: rotateX(-90deg) translateZ(60px); }
    
    .model-sphere {
        width: 120px;
        height: 120px;
    }
    
    .accessibility-menu {
        top: 10px;
        right: 10px;
    }
    
    .accessibility-toggle {
        width: 45px;
        height: 45px;
        font-size: 1rem;
    }
    
    /* Form improvements for tablets */
    .contact-form {
        padding: 2rem 1.5rem;
    }
    
    .form-group {
        margin-bottom: 1.5rem;
    }
    
    .form-group input,
    .form-group textarea {
        padding: 1rem;
        font-size: 1rem;
        min-height: 44px; /* Minimum touch target size */
    }
    
    .btn-full {
        width: 100%;
        padding: 1rem;
        font-size: 1.1rem;
        min-height: 48px;
    }
    
    /* Section spacing for tablets */
    section {
        padding: 4rem 0;
    }
    
    .section-title {
        font-size: 2.5rem;
        margin-bottom: 1rem;
    }
    
    .section-subtitle {
        font-size: 1.1rem;
        margin-bottom: 2rem;
    }
}

/* Medium Mobile Devices (600px) */
@media (max-width: 600px) {
    .hero-container {
        padding: 1rem;
    }
    
    .hero-name {
        font-size: clamp(2rem, 10vw, 3.5rem);
        margin-bottom: 1rem;
    }
    
    .typing-container {
        font-size: clamp(1rem, 5vw, 1.5rem);
        margin-bottom: 1.5rem;
    }
    
    .hero-description {
        font-size: 1rem;
        line-height: 1.6;
        margin-bottom: 2rem;
    }
    
    .hero-buttons .btn {
        padding: 0.9rem 1.8rem;
        font-size: 0.95rem;
    }
    
    .section-title {
        font-size: 2rem;
    }
    
    .section-subtitle {
        font-size: 1rem;
    }
    
    .about-text h3 {
        font-size: 1.5rem;
        margin-bottom: 1rem;
    }
    
    .about-text p {
        font-size: 0.95rem;
        line-height: 1.6;
        margin-bottom: 1.5rem;
    }
    
    .skill-item {
        padding: 1.5rem;
        text-align: center;
    }
    
    .skill-item h4 {
        font-size: 1.1rem;
        margin-bottom: 0.5rem;
    }
    
    .contact-info h3 {
        font-size: 1.5rem;
        margin-bottom: 1rem;
    }
    
    .contact-details {
        margin-bottom: 2rem;
    }
    
    .contact-item {
        margin-bottom: 1.5rem;
        text-align: center;
    }
    
    .footer-brand h3 {
        font-size: 1.5rem;
        margin-bottom: 0.5rem;
    }
    
    .footer-links {
        gap: 0.8rem;
    }
    
    .footer-links a {
        padding: 0.5rem;
        font-size: 0.9rem;
    }
    
    .social-icon {
        width: 45px;
        height: 45px;
        font-size: 1.1rem;
    }
}

/* Small Mobile Devices (480px) */
@media (max-width: 480px) {
    .floating-shapes {
        width: 250px;
        height: 250px;
    }
    
    .shape-1 { width: 50px; height: 50px; }
    .shape-2 { width: 35px; height: 35px; }
    .shape-3 { width: 65px; height: 65px; }
    .shape-4 { width: 30px; height: 30px; }
    .shape-5 { width: 45px; height: 45px; }
    
    .profile-card {
        width: 250px;
        height: 300px;
    }
    
    .hero-name {
        font-size: clamp(1.8rem, 15vw, 2.8rem);
    }
    
    .hero-title {
        font-size: clamp(0.9rem, 8vw, 1.3rem);
    }
    
    .about-placeholder {
        width: 250px;
        height: 250px;
    }
    
    .btn {
        padding: 0.8rem 1.5rem;
        font-size: 0.9rem;
        min-height: 44px;
    }
    
    .contact-form {
        padding: 1.5rem 1rem;
        margin: 1rem;
    }
    
    .form-group input,
    .form-group textarea {
        padding: 0.9rem;
        font-size: 0.95rem;
        border-radius: 6px;
    }
    
    .form-group label {
        font-size: 0.9rem;
        margin-bottom: 0.4rem;
    }
    
    .container {
        padding: 0 0.8rem;
    }
    
    section {
        padding: 3rem 0;
    }
    
    .section-title {
        font-size: 1.8rem;
        margin-bottom: 0.8rem;
    }
    
    .section-subtitle {
        font-size: 0.9rem;
        margin-bottom: 1.5rem;
    }
    
    .hero-description {
        font-size: 0.9rem;
        padding: 0 1rem;
    }
    
    .about-text p {
        font-size: 0.9rem;
    }
    
    .skill-item {
        padding: 1.2rem;
    }
    
    .skill-item h4 {
        font-size: 1rem;
    }
    
    .skill-item p {
        font-size: 0.85rem;
    }
    
    .testimonial-item {
        margin-bottom: 2rem;
    }
    
    .testimonial-content {
        padding: 1.5rem;
    }
    
    .testimonial-content p {
        font-size: 0.9rem;
        line-height: 1.6;
    }
    
    .footer-content {
        gap: 1.5rem;
    }
    
    .footer-brand h3 {
        font-size: 1.3rem;
    }
    
    .footer-brand p {
        font-size: 0.85rem;
    }
    
    .footer-links {
        flex-direction: column;
        gap: 0.5rem;
    }
    
    .footer-links a {
        padding: 0.4rem;
        font-size: 0.85rem;
    }
    
    .social-icon {
        width: 42px;
        height: 42px;
        font-size: 1rem;
    }
    
    .footer-bottom {
        padding-top: 1.5rem;
    }
    
    .footer-bottom p {
        font-size: 0.8rem;
        margin: 0.3rem 0;
    }
}

/* Extra Small Devices (320px) */
@media (max-width: 320px) {
    .hero-name {
        font-size: clamp(1.5rem, 18vw, 2.2rem);
    }
    
    .typing-container {
        font-size: clamp(0.8rem, 10vw, 1.1rem);
    }
    
    .hero-description {
        font-size: 0.85rem;
        padding: 0 0.5rem;
    }
    
    .hero-buttons .btn {
        padding: 0.7rem 1.2rem;
        font-size: 0.85rem;
        max-width: 260px;
    }
    
    .container {
        padding: 0 0.5rem;
    }
    
    .section-title {
        font-size: 1.6rem;
    }
    
    .section-subtitle {
        font-size: 0.85rem;
    }
    
    .contact-form {
        padding: 1rem 0.8rem;
        margin: 0.5rem;
    }
    
    .form-group input,
    .form-group textarea {
        padding: 0.8rem;
        font-size: 0.9rem;
    }
    
    .btn-full {
        padding: 0.9rem;
        font-size: 0.9rem;
    }
    
    .social-icons {
        gap: 1rem;
    }
    
    .social-icon {
        width: 38px;
        height: 38px;
        font-size: 0.9rem;
    }
}

/* ===== THANK YOU PAGE ===== */
.thank-you {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
    padding: 6rem 0;
}

.thank-you-content {
    text-align: center;
    max-width: 600px;
    margin: 0 auto;
}

.thank-you-icon {
    font-size: 4rem;
    margin-bottom: 2rem;
    animation: pulse 2s infinite;
}

.thank-you h1 {
    color: #f8fafc;
    font-size: clamp(2.5rem, 5vw, 3.5rem);
    margin-bottom: 1.5rem;
}

.thank-you p {
    color: #94a3b8;
    font-size: 1.2rem;
    margin-bottom: 2.5rem;
}

.thank-you-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

/* ===== ACCESSIBILITY ===== */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    
    html {
        scroll-behavior: auto;
    }
}

/* ===== PRINT STYLES ===== */
@media print {
    .navbar,
    .hero-scroll,
    .btn,
    .contact-form {
        display: none;
    }
    
    body {
        background: white;
        color: black;
    }
    
    .hero,
    .contact {
        background: white;
    }
}

/* ===== MOBILE PERFORMANCE OPTIMIZATIONS ===== */
@media (max-width: 768px) {
    /* Reduce animations on mobile for better performance */
    .floating {
        animation-duration: 4s;
    }
    
    /* Simplify complex animations */
    .project-card:hover {
        transform: translateY(-2px) scale(1.01);
    }
    
    .testimonial-card:hover {
        transform: translateY(-2px);
    }
    
    /* Optimize background images */
    .hero {
        background-attachment: scroll; /* Better mobile performance */
    }
    
    /* Reduce backdrop blur on older devices */
    @supports not (backdrop-filter: blur()) {
        .navbar {
            background: rgba(15, 23, 42, 0.98);
        }
        
        .nav-menu {
            background: rgba(15, 23, 42, 0.98);
        }
    }
    
    /* Better touch scrolling */
    .testimonials-container {
        -webkit-overflow-scrolling: touch;
        scroll-behavior: smooth;
    }
    
    /* Optimize Vanta.js for mobile */
    #vanta-bg {
        transform: scale(1);
        opacity: 0.7; /* Reduce intensity on mobile */
    }
}

/* Extra small devices optimization */
@media (max-width: 480px) {
    /* Further reduce animations */
    * {
        animation-duration: 0.5s !important;
    }
    
    /* Simplify effects */
    .nav-link:hover {
        padding-left: 2rem;
    }
    
    /* Reduce backdrop blur */
    .navbar,
    .nav-menu {
        backdrop-filter: blur(10px);
        -webkit-backdrop-filter: blur(10px);
    }
}
