/* Professional Color Palette */
:root {
    /* Core Colors */
    --primary: #4F46E5;
    --secondary: #7C3AED;
    --accent: #e74c3c;
    --bg-white: #FFFFFF;
    --bg-light: #F3F4F6;
    --bg-dark: #1a1a1a;
    
    /* Text Colors */
    --text-dark: #1F2937;
    --text-gray: #6c757d;
    --text-light: #6B7280;
    
    /* Transitions */
    --transition-smooth: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    
    /* Shadows */
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
}

/* Modern Reset */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

/* Base Styles */
body {
    font-family: 'Inter', sans-serif;
    line-height: 1.6;
    color: var(--text-dark);
    background: var(--bg-light);
    margin: 0;
    padding: 0;
    min-height: 100vh;
}

/* Navigation */
.nav-container {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(10px);
    z-index: 1000;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

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

.logo {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary);
    text-decoration: none;
}

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

.nav-links a {
    color: white;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
    padding: 0.5rem 0;
}

.nav-links a:hover {
    color: var(--primary);
}

/* Mobile Menu Button */
.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
}

.mobile-menu-btn span {
    display: block;
    width: 25px;
    height: 2px;
    background: var(--text-dark);
    margin: 5px 0;
    transition: all 0.3s ease;
}

/* Hero Section */
.hero {
    min-height: 100vh;
    position: relative;
    display: flex;
    align-items: center;
    overflow: hidden;
    background-color: var(--bg-dark); /* Fallback color */
}

.hero-background {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: linear-gradient(
        rgba(0, 0, 0, 0.7),
        rgba(0, 0, 0, 0.7)
    ), url('../images/carl-heyerdahl-KE0nC8-58MQ-unsplash.jpg');
    background-size: cover;
    background-position: center;
    z-index: -1;
}

.hero-content {
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
    padding: 2rem;
    color: white;
    position: relative;
}

.hero-text {
    width: 100%;
    max-width: 100%;
    margin: 0;
    background: rgba(0, 0, 0, 0.4);
    padding: 4rem;
    border-radius: 0;
    backdrop-filter: blur(10px);
    border: none;
    box-shadow: none;
    text-align: left;
}

.hero-content-left {
    flex: 1;
    max-width: 50%;
}

.hero-content-right {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 2rem;
}

.profile-preview {
    width: 100%;
    max-width: 450px;
    aspect-ratio: 1;
    border-radius: 20px;
    overflow: hidden;
    position: relative;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.profile-preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.profile-preview:hover img {
    transform: scale(1.05);
}

.achievement-cards {
    width: 100%;
    max-width: 450px;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.achievement-card {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(5px);
    padding: 1.5rem;
    border-radius: 15px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    transition: all 0.3s ease;
}

.achievement-card h4 {
    font-size: 1.2rem;
    margin-bottom: 0.5rem;
    color: var(--primary);
}

.achievement-card p {
    color: rgba(255, 255, 255, 0.9);
    font-size: 0.95rem;
}

.hero-text h1 {
    font-size: 3.5rem;
    margin-bottom: 1rem;
    color: white;
}

.highlight {
    background: linear-gradient(120deg, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    text-shadow: none;
    position: relative;
    display: inline-block;
}

.typewriter {
    font-size: 2rem;
    margin: 1.5rem 0;
    min-height: 3rem;
    color: var(--primary);
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.5);
}

.hero-description {
    max-width: 600px;
    font-size: 1.2rem;
    margin-bottom: 2rem;
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.9);
}

.hero-cta {
    text-align: left;
}

.tech-stack {
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.2);
    text-align: left;
}

.tech-label {
    display: block;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 1rem;
    color: rgba(255, 255, 255, 0.7);
}

.tech-icons {
    display: flex;
    justify-content: flex-start;
    gap: 2.5rem;
    font-size: 2.5rem;
    color: white;
}

.tech-icons i {
    transition: all 0.3s ease;
    cursor: pointer;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
    opacity: 0.8;
}

.tech-icons i:hover {
    color: var(--primary);
    transform: translateY(-5px) scale(1.1);
    opacity: 1;
}

/* Update Stats Section Styles */
.quick-stats {
    background: var(--bg-white);
    padding: 6rem 2rem;
    position: relative;
}

.quick-stats::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--primary), var(--secondary));
}

.stats-container {
    max-width: 1400px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2.5rem;
}

.stat-item {
    background: white;
    padding: 2.5rem;
    border-radius: 20px;
    text-align: center;
    transition: all 0.3s ease;
    border: 1px solid rgba(0, 0, 0, 0.05);
    position: relative;
    overflow: hidden;
}

.stat-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--primary), var(--secondary));
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

.stat-item:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}

.stat-item:hover::before {
    transform: scaleX(1);
}

.stat-icon {
    font-size: 2.5rem;
    color: var(--primary);
    margin-bottom: 1.5rem;
    height: 60px;
    width: 60px;
    line-height: 60px;
    border-radius: 50%;
    background: rgba(79, 70, 229, 0.1);
    margin: 0 auto 1.5rem;
}

.stat-value {
    display: flex;
    align-items: baseline;
    justify-content: center;
    gap: 0.25rem;
    margin-bottom: 0.5rem;
}

.stat-number {
    font-size: 3.5rem;
    font-weight: 700;
    color: var(--primary);
    line-height: 1;
}

.stat-plus {
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary);
}

.stat-label {
    display: block;
    color: var(--text-dark);
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 1rem;
}

.stat-description {
    color: var(--text-gray);
    font-size: 0.95rem;
    margin-bottom: 1.5rem;
    line-height: 1.6;
}

.stat-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    justify-content: center;
}

.stat-tags span {
    padding: 0.4rem 1rem;
    background: rgba(79, 70, 229, 0.1);
    color: var(--primary);
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 500;
    transition: all 0.3s ease;
}

.stat-tags span:hover {
    background: var(--primary);
    color: white;
    transform: translateY(-2px);
}

@media (max-width: 1024px) {
    .stats-container {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .stats-container {
        grid-template-columns: 1fr;
    }
    
    .stat-item {
        padding: 2rem;
    }
}

/* Page Transitions */
.page-transition {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--bg-dark);
    z-index: 9999;
    transform: translateY(100%);
    transition: transform 0.6s cubic-bezier(0.77, 0, 0.175, 1);
}

.page-transition.active {
    transform: translateY(0);
}

/* Section Animation */
.fade-in {
    opacity: 1 !important;
    transform: none !important;
}

/* Section Headers */
section h2 {
    color: var(--text-dark);
    font-size: 2rem;
    font-weight: 600;
    margin-bottom: 2rem;
    position: relative;
    padding-bottom: 0.5rem;
}

section h2::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 60px;
    height: 3px;
    background: var(--secondary);
}

/* Timeline/Experience Section */
.timeline-content {
    background: var(--bg-white);
    border-radius: 8px;
    padding: 2rem;
    margin-bottom: 1.5rem;
    box-shadow: var(--shadow-sm);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.timeline-content:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.timeline-content h3 {
    color: var(--primary);
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.timeline-content .position {
    color: var(--secondary);
    font-weight: 500;
    margin-bottom: 0.5rem;
}

.timeline-content .location {
    color: var(--text-gray);
    font-size: 0.9rem;
}

/* Skills Section */
.skill-category-card {
    background: var(--bg-white);
    border-radius: 8px;
    padding: 1.5rem;
    box-shadow: var(--shadow-sm);
    margin-bottom: 1.5rem;
}

.skill-progress {
    height: 8px;
    background: var(--bg-gray);
    border-radius: 4px;
    overflow: hidden;
}

.skill-progress .progress {
    background: var(--secondary);
    transition: width 0.3s ease;
}

/* Contact Section */
.contact-form {
    background: var(--bg-white);
    padding: 2rem;
    border-radius: 8px;
    box-shadow: var(--shadow-md);
}

.form-input {
    border: 1px solid #dee2e6;
    border-radius: 4px;
    padding: 0.75rem;
    width: 100%;
    transition: border-color 0.3s ease;
}

.form-input:focus {
    border-color: var(--secondary);
    outline: none;
    box-shadow: 0 0 0 2px rgba(52, 152, 219, 0.2);
}

/* Buttons */
.submit-btn, .liquid-button {
    background: var(--secondary);
    color: white;
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 4px;
    font-weight: 500;
    transition: background-color 0.3s ease;
}

.submit-btn:hover, .liquid-button:hover {
    background: #2980b9;
    transform: translateY(-2px);
}

/* Statistics Cards */
.stat-card {
    background: var(--bg-white);
    padding: 1.5rem;
    border-radius: 8px;
    text-align: center;
    box-shadow: var(--shadow-sm);
}

.stat-number {
    color: var(--secondary);
    font-size: 2.5rem;
    font-weight: bold;
    margin-bottom: 0.5rem;
}

/* Social Links */
.social-links a {
    color: var(--text-gray);
    transition: color 0.3s ease;
    margin: 0 0.5rem;
}

.social-links a:hover {
    color: var(--secondary);
}

/* Responsive Design */
@media (max-width: 768px) {
    .mobile-menu-btn {
        display: block;
    }

    .nav-links {
        position: fixed;
        top: 70px;
        left: 0;
        right: 0;
        background: white;
        flex-direction: column;
        padding: 2rem;
        gap: 1.5rem;
        transform: translateY(-100%);
        opacity: 0;
        transition: all 0.3s ease;
    }

    .nav-links.active {
        transform: translateY(0);
        opacity: 1;
    }

    .mobile-menu-btn.active span:nth-child(1) {
        transform: rotate(45deg) translate(5px, 5px);
    }

    .mobile-menu-btn.active span:nth-child(2) {
        opacity: 0;
    }

    .mobile-menu-btn.active span:nth-child(3) {
        transform: rotate(-45deg) translate(7px, -7px);
    }

    .hero h1 {
        font-size: 3rem;
    }
    
    .hero p {
        font-size: 1.25rem;
    }
    
    section {
        padding: 2rem 1rem;
    }
    
    .timeline-content {
        padding: 1.5rem;
    }
    
    section h2 {
        font-size: 1.75rem;
    }
}

/* Common styles */
.fade-in {
    opacity: 1 !important;
    transform: none !important;
}

/* Page sections */
section {
    padding: 4rem 2rem;
}

h1 {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 1rem;
}

.lead {
    font-size: 1.25rem;
    color: var(--text-light);
    margin-bottom: 2rem;
}

/* Buttons */
.primary-btn, .secondary-btn {
    display: inline-block;
    padding: 0.75rem 1.5rem;
    border-radius: 0.5rem;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
}

.primary-btn {
    background: var(--primary);
    color: white;
    padding: 1rem 2rem;
    border-radius: 50px;
    font-weight: 600;
    box-shadow: 0 4px 15px rgba(79, 70, 229, 0.4);
    transition: all 0.3s ease;
}

.primary-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(79, 70, 229, 0.6);
}

.secondary-btn {
    background: transparent;
    color: white;
    border: 2px solid white;
    padding: 1rem 2rem;
    border-radius: 50px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.secondary-btn:hover {
    background: white;
    color: var(--primary);
    transform: translateY(-2px);
}

/* Ensure text visibility */
h1, h2, h3, p {
    opacity: 1;
}

/* Hero social links */
.hero-social {
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.2);
    text-align: left;
}

.social-label {
    display: block;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 1rem;
    text-align: left;
}

.social-icons {
    display: flex;
    justify-content: flex-start;
    gap: 2rem;
}

.social-icons a {
    color: white;
    font-size: 1.5rem;
    transition: all 0.3s ease;
}

.social-icons a:hover {
    color: var(--primary);
    transform: translateY(-3px);
}

/* Scroll indicator */
.scroll-indicator {
    position: absolute;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
}

.mouse {
    width: 30px;
    height: 50px;
    border: 2px solid white;
    border-radius: 15px;
    position: relative;
}

.wheel {
    width: 4px;
    height: 8px;
    background: white;
    border-radius: 2px;
    position: absolute;
    top: 8px;
    left: 50%;
    transform: translateX(-50%);
    animation: scroll 2s infinite;
}

.arrows {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 5px;
}

.arrows span {
    width: 10px;
    height: 10px;
    border-right: 2px solid white;
    border-bottom: 2px solid white;
    transform: rotate(45deg);
    animation: arrows 2s infinite;
}

.arrows span:nth-child(2) {
    animation-delay: 0.2s;
}

.arrows span:nth-child(3) {
    animation-delay: 0.4s;
}

@keyframes scroll {
    0% { transform: translate(-50%, 0); opacity: 1; }
    100% { transform: translate(-50%, 20px); opacity: 0; }
}

@keyframes arrows {
    0% { opacity: 0; transform: rotate(45deg) translate(-5px, -5px); }
    50% { opacity: 1; }
    100% { opacity: 0; transform: rotate(45deg) translate(5px, 5px); }
}

/* Add floating animation to stats */
@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

.floating-elements {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1;
}

.floating-card {
    position: absolute;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(5px);
    border-radius: 15px;
    padding: 1.5rem;
    border: 1px solid rgba(255, 255, 255, 0.2);
    animation: float 6s infinite ease-in-out;
    z-index: 2;
}

.floating-card.card-1 {
    top: -50px;
    right: 20%;
    animation-delay: 0s;
}

.floating-card.card-2 {
    bottom: -50px;
    right: 30%;
    animation-delay: 1s;
}

.floating-card.card-3 {
    top: 40%;
    left: -50px;
    animation-delay: 2s;
}

.floating-card h4 {
    color: white;
    margin-bottom: 1rem;
    font-size: 1.1rem;
}

.skill-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.skill-badge {
    padding: 0.5rem 1rem;
    background: rgba(79, 70, 229, 0.2);
    border-radius: 20px;
    color: white;
    font-size: 0.9rem;
}

/* Responsive design */
@media (max-width: 1200px) {
    .hero-text {
        flex-direction: column;
        gap: 3rem;
    }

    .hero-content-left {
        max-width: 100%;
    }

    .hero-content-right {
        align-items: center;
    }

    .floating-card {
        position: static;
        margin: 1rem 0;
    }

    .floating-elements {
        position: static;
        display: flex;
        flex-wrap: wrap;
        gap: 1rem;
        margin-bottom: 2rem;
    }
}

@media (max-width: 768px) {
    .hero-text {
        padding: 2rem;
    }

    .profile-preview, 
    .achievement-cards {
        max-width: 100%;
    }

    .hero-text h1 {
        font-size: 2.5rem;
    }

    .typewriter {
        font-size: 1.5rem;
    }
}

/* Optional: Add a subtle gradient overlay to the background */
.hero-background::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(
        90deg,
        rgba(0, 0, 0, 0.8) 0%,
        rgba(0, 0, 0, 0.6) 50%,
        rgba(0, 0, 0, 0.4) 100%
    );
}

/* Enhanced hero section animations */
.hero-content h1 {
    animation: slideUpFade 0.8s ease-out;
    position: relative;
}

.hero-content h1::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 0;
    width: 60px;
    height: 4px;
    background: var(--primary);
    border-radius: 2px;
    animation: expandWidth 1s ease-out forwards;
}

.hero-content p {
    animation: slideUpFade 1s ease-out 0.2s backwards;
}

/* Animated background gradient */
.hero-section {
    position: relative;
    overflow: hidden;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(
        45deg,
        rgba(240, 128, 128, 0.1) 25%,
        transparent 25%,
        transparent 50%,
        rgba(240, 128, 128, 0.1) 50%,
        rgba(240, 128, 128, 0.1) 75%,
        transparent 75%
    );
    background-size: 60px 60px;
    animation: gradientMove 30s linear infinite;
    opacity: 0.5;
    z-index: 0;
}

/* Floating animation for profile image */
.profile-image {
    animation: float 6s ease-in-out infinite;
    position: relative;
}

.profile-image::after {
    content: '';
    position: absolute;
    bottom: -20px;
    left: 50%;
    transform: translateX(-50%);
    width: 70%;
    height: 20px;
    background: radial-gradient(ellipse at center, rgba(0,0,0,0.1) 0%, transparent 70%);
    border-radius: 50%;
    animation: shadowPulse 6s ease-in-out infinite;
}

/* Social links hover effect */
.social-links a {
    position: relative;
    overflow: hidden;
}

.social-links a::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(240,128,128,0.2) 0%, transparent 70%);
    transform: translate(-100%, -100%) rotate(45deg);
    transition: 0.5s ease;
}

.social-links a:hover::before {
    transform: translate(0, 0) rotate(45deg);
}

/* Typing animation for role/designation */
.typed-text {
    border-right: 3px solid var(--primary);
    animation: typing 3.5s steps(40, end), blink-caret 0.75s step-end infinite;
    white-space: nowrap;
    overflow: hidden;
}

/* New animations */
@keyframes slideUpFade {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes expandWidth {
    from { width: 0; }
    to { width: 60px; }
}

@keyframes gradientMove {
    0% { transform: translate(-50%, -50%) rotate(0deg); }
    100% { transform: translate(-50%, -50%) rotate(360deg); }
}

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-15px); }
}

@keyframes shadowPulse {
    0%, 100% { opacity: 0.3; transform: translateX(-50%) scale(1); }
    50% { opacity: 0.2; transform: translateX(-50%) scale(0.8); }
}

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

@keyframes blink-caret {
    from, to { border-color: transparent }
    50% { border-color: var(--primary) }
}

/* Smooth scroll behavior */
html {
    scroll-behavior: smooth;
}

/* Enhanced button hover effects */
.cta-button {
    position: relative;
    overflow: hidden;
}

.cta-button::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255,255,255,0.3) 0%, transparent 60%);
    transform: translate(-100%, -100%) rotate(45deg);
    transition: 0.5s ease;
}

.cta-button:hover::after {
    transform: translate(0, 0) rotate(45deg);
} 