/* Modern Background & Color Palette */
:root {
    --bg-primary: #ffffff;
    --bg-secondary: #f8fafc;
    --text-primary: #0f172a;
    --text-secondary: #475569;
    --accent: #6366f1;
    --gradient-start: #e0e7ff;
    --gradient-end: #f0f9ff;
    --card-bg: rgba(255, 255, 255, 0.8);
    --border: #e2e8f0;
}

[data-theme="dark"] {
    --bg-primary: #0f172a;
    --bg-secondary: #1e293b;
    --text-primary: #f8fafc;
    --text-secondary: #94a3b8;
    --accent: #818cf8;
    --gradient-start: #1e1b4b;
    --gradient-end: #312e81;
    --card-bg: rgba(30, 41, 59, 0.8);
    --border: #334155;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    transition: background-color 0.3s ease, color 0.3s ease;
    overflow-x: hidden;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

/* Navigation */
.nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: rgba(255, 255, 255, 0.3);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
}

[data-theme="dark"] .nav {
    background: rgba(10, 10, 10, 0.3);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.3);
}

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

.nav-logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    text-decoration: none;
    color: var(--text-primary);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    font-size: 1.25rem;
    font-weight: 600;
}

.nav-logo:hover {
    opacity: 0.9;
}

.logo-icon {
    flex-shrink: 0;
    color: var(--accent);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.1));
}

[data-theme="dark"] .logo-icon {
    color: var(--accent);
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.3));
}

.nav-logo:hover .logo-icon {
    transform: scale(1.08) rotate(-2deg);
    color: var(--accent);
}

.logo-icon path,
.logo-icon circle {
    transition: all 0.3s ease;
}

.nav-logo:hover .logo-icon path {
    stroke-width: 2.8;
}

.nav-logo:hover .logo-icon circle {
    opacity: 0.8;
    transform: scale(1.2);
}

.logo-text {
    font-weight: 500;
    letter-spacing: 0.02em;
    color: var(--text-primary);
    transition: all 0.3s ease;
}

.nav-logo:hover .logo-text {
    color: var(--accent);
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 2rem;
}

.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    justify-content: space-around;
    width: 28px;
    height: 24px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 0;
    z-index: 1001;
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
    position: relative;
}

.mobile-menu-toggle span {
    width: 100%;
    height: 3px;
    background: var(--text-primary);
    border-radius: 3px;
    transition: all 0.3s ease;
    transform-origin: center;
}

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

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

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

.mobile-menu-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 999;
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
}

.mobile-menu-overlay.active {
    display: block;
    opacity: 1;
    pointer-events: auto;
}

@media (max-width: 768px) {
    .mobile-menu-overlay {
        display: block;
    }
}

.nav-link {
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
    position: relative;
}

.nav-link:hover {
    color: var(--text-primary);
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--accent);
    transition: width 0.3s ease;
}

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

.theme-toggle {
    background: transparent;
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 0.5rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-primary);
    transition: all 0.3s ease;
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
    position: relative;
    z-index: 10;
}

.theme-toggle:hover {
    background: var(--bg-secondary);
    transform: rotate(15deg);
}

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

/* Enhanced Hero Background */
.hero {
    min-height: 100vh;
    height: 100vh;
    max-height: 100vh;
    display: flex;
    align-items: center;
    padding: 8rem 2rem 4rem;
    background: var(--bg-primary);
    position: relative;
    overflow: hidden;
    z-index: 0;
    box-sizing: border-box;
}

@media (max-width: 768px) {
    .hero {
        height: auto;
        min-height: auto;
        max-height: none;
    }
}

/* Refined Video Overlay */
.hero-video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: -2;
    opacity: 0.05; /* More subtle */
    mix-blend-mode: overlay;
}

@media (max-width: 768px) {
    .hero-video {
        opacity: 0.3;
    }
}

/* Animated Mesh Gradient Background */
.hero::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle at 50% 50%, 
        rgba(99, 102, 241, 0.15) 0%, 
        rgba(168, 85, 247, 0.15) 25%, 
        rgba(236, 72, 153, 0.15) 50%, 
        rgba(56, 189, 248, 0.15) 75%, 
        transparent 100%);
    filter: blur(60px);
    animation: rotateBackground 20s linear infinite;
    z-index: -1;
}

.hero::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%236366f1' fill-opacity='0.05'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
    z-index: -1;
    opacity: 0.5;
}

@keyframes rotateBackground {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

[data-theme="dark"] .hero::before {
    background: radial-gradient(circle at 50% 50%, 
        rgba(99, 102, 241, 0.25) 0%, 
        rgba(168, 85, 247, 0.25) 25%, 
        rgba(236, 72, 153, 0.25) 50%, 
        rgba(56, 189, 248, 0.25) 75%, 
        transparent 100%);
}

.hero-container {
    max-width: 1200px;
    margin: 0 auto;
    width: 100%;
    position: relative;
    z-index: 2;
}

.hero-content {
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
}

.hero-title {
    font-size: clamp(2.75rem, 6vw, 5.5rem);
    font-weight: 200;
    line-height: 1.15;
    margin-bottom: 2rem;
    color: var(--text-primary);
    text-align: center;
    letter-spacing: -0.02em;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen', 'Ubuntu', 'Cantarell', 'Fira Sans', 'Droid Sans', 'Helvetica Neue', sans-serif;
    text-rendering: optimizeLegibility;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

.hero-description {
    font-size: clamp(1rem, 1.5vw, 1.125rem);
    line-height: 1.7;
    color: rgb(39, 21, 34);
    margin: 0 auto 2rem;
    max-width: 800px;
    font-weight: 300;
    opacity: 0;
    animation: fadeIn 1s ease 0.6s forwards;
}

[data-theme="dark"] .hero-description {
    color: #cbd5e1; /* Light color for dark mode visibility */
}

.hero-line {
    display: block;
    opacity: 0;
    transform: translateY(30px);
    animation: fadeInUp 0.9s cubic-bezier(0.16, 1, 0.3, 1) forwards;
    margin-bottom: 0.25rem;
}

.hero-line:nth-child(1) {
    animation-delay: 0.1s;
}

.hero-line:nth-child(2) {
    animation-delay: 0.25s;
}

.hero-line strong {
    font-weight: 700;
    color: var(--accent);
}

.hand-icon {
    display: inline-block;
    margin: 0 0.3rem;
    font-size: 1.15em;
    animation: wave 2.5s ease-in-out infinite;
    transform-origin: 70% 70%;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.1));
}

@keyframes wave {
    0%, 100% {
        transform: rotate(0deg);
    }
    10%, 30% {
        transform: rotate(14deg);
    }
    20% {
        transform: rotate(-8deg);
    }
    40% {
        transform: rotate(-4deg);
    }
    50% {
        transform: rotate(10deg);
    }
    60% {
        transform: rotate(0deg);
    }
}

.hero-name {
    font-weight: 300;
    background: linear-gradient(135deg, #3b82f6 0%, #8b5cf6 50%, #ec4899 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    background-size: 200% 200%;
    animation: gradientShift 8s ease infinite;
    letter-spacing: -0.01em;
    position: relative;
    display: inline-block;
}

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

.text-light {
    color: rgba(82, 86, 86, 0.7);
    font-weight: 300;
    letter-spacing: 0.01em;
}

[data-theme="dark"] .text-light {
    color: #94a3b8; /* Lighter color for dark mode visibility */
}

.building-text {
    display: inline-block;
    position: relative;
}

/* Character-by-character building animation */
.building-text .char {
    display: inline-block;
    opacity: 0;
    transform: translateY(-20px); /* Start from above */
    animation: buildChar 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards; /* Snap effect */
}

.building-text .char-space {
    display: inline-block;
    width: 0.25em;
}

@keyframes buildChar {
    0% {
        opacity: 0;
        transform: translateY(-20px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}


.hero-subtitle-container {
    display: inline-block;
    padding: 0;
    margin-bottom: 2.5rem;
    opacity: 0;
    animation: fadeIn 1s ease 0.7s forwards;
    text-align: center;
}


.hero-subtitle {
    font-size: 1.25rem;
    color: #252323;
    margin: 0;
    font-weight: 200;
}

[data-theme="dark"] .hero-subtitle {
    color: #e2e8f0; /* Lighter color for better visibility */
    font-weight: 200;
}

@keyframes fadeIn {
    to {
        opacity: 1;
    }
}

.hero-cta {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    justify-content: center;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.875rem 1.75rem;
    border-radius: 8px;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.3s ease;
    cursor: pointer;
    border: none;
    font-size: 1rem;
    position: relative;
    z-index: 10;
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
    user-select: none;
}

.btn-primary {
    background: var(--accent);
    color: white;
}

.btn-primary:hover {
    background: var(--accent-hover);
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(37, 99, 235, 0.3);
}

.btn-secondary {
    background: var(--bg-secondary);
    color: var(--text-primary);
    border: 1px solid var(--border);
}

.btn-secondary:hover {
    background: var(--bg-primary);
    transform: translateY(-2px);
    box-shadow: 0 8px 20px var(--shadow-hover);
}

/* Section Styles */
section {
    padding: 6rem 0;
    scroll-margin-top: 100px;
    position: relative;
    z-index: 1;
}

.section-title {
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 300;
    line-height: 1.3;
    margin-bottom: 4rem;
    color: var(--text-primary);
    max-width: 900px;
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

[data-theme="dark"] .section-title {
    color: #f8fafc; /* Ensure section titles are visible */
}

.text-grey {
    color: rgba(255, 255, 255, 0.5);
    font-weight: 300;
}

.experience .text-grey {
    color: var(--text-secondary);
}

[data-theme="dark"] .experience .text-grey {
    color: #94a3b8; /* Lighter gray for better visibility */
}

/* About section title animations handled by JavaScript on scroll */

/* About Section Redesign */
.about {
    background: linear-gradient(180deg, var(--token-a703e911-33dd-4e81-9b21-c3a4ab54bbd5, #b8b8b8) -26%, #fff 51.244%);
    padding-top: 8rem;
    padding-bottom: 6rem;
    position: relative;
    z-index: 2;
    margin-top: 0;
}

[data-theme="dark"] .about {
    background: linear-gradient(180deg, #1a1a1a 0%, #0f0f0f 100%);
}

@media (max-width: 768px) {
    .about {
        padding-top: 4rem;
    }
}

[data-theme="dark"] .about-title .title-normal {
    color: #cbd5e1; /* Light gray for visibility */
}

[data-theme="dark"] .about-title .title-emphasis {
    color: #ffffff; /* White for emphasis */
}

.about-title {
    display: block;
    line-height: 1.3;
    margin-bottom: 5rem;
    max-width: 800px;
}

.about-title .title-normal {
    color: #525252;
    font-weight: 300;
    display: block;
    font-size: clamp(2rem, 4vw, 3rem);
}

.about-title .title-emphasis {
    color: #1a1a1a;
    font-weight: 400; /* Lighter weight as requested */
    display: block;
    font-size: clamp(2rem, 4vw, 3rem);
}

.about-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2rem;
    position: relative;
    z-index: 2;
}

@media (min-width: 1200px) {
    .about-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 768px) {
    .about-grid {
        grid-template-columns: 1fr;
    }
}

.about-card {
    padding: 2rem;
    background: #f5f5f5;
    border-radius: 12px;
    transition: all 0.3s ease;
    opacity: 0;
    transform: translateY(20px);
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
}

[data-theme="dark"] .about-card {
    background: #2a2a2a;
}

[data-theme="dark"] .card-title {
    color: #ffffff;
}

/* About card animations handled by JavaScript on scroll */

.about-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

[data-theme="dark"] .about-card:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.card-title {
    font-size: 1.5rem;
    font-weight: 400; /* Match experience badge font weight */
    color: #1a1a1a;
    margin-bottom: 1rem;
    letter-spacing: -0.01em;
    line-height: 1.2;
}

.card-text {
    color: var(--text-primary);
    line-height: 1.6;
    margin: 0;
    font-size: 1rem;
    font-weight: 400;
    transition: margin-bottom 0.4s ease;
}

[data-theme="dark"] .card-text {
    color: #e2e8f0; /* Light color for better visibility */
}

.about-card {
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.about-card:hover:not(.expanded) {
    transform: translateY(-4px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

[data-theme="dark"] .about-card:hover:not(.expanded) {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.about-card.expanded {
    padding-bottom: 2rem;
    background: rgba(255, 255, 255, 0.8);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
}

[data-theme="dark"] .about-card.expanded {
    background: rgba(40, 40, 40, 0.8);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
}

.about-card.expanded .card-text {
    margin-bottom: 1rem;
}

.about-expanded {
    max-height: 0;
    height: 0;
    overflow: hidden;
    transition: max-height 0.5s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.5s ease, margin-top 0.5s ease, padding 0.5s ease;
    opacity: 0;
    margin-top: 0;
    margin-bottom: 0;
    padding-top: 0;
    padding-bottom: 0;
    visibility: hidden;
    pointer-events: none;
}

.about-card.expanded .about-expanded {
    max-height: 500px;
    height: auto;
    opacity: 1;
    margin-top: 1rem;
    visibility: visible;
    pointer-events: auto;
    padding-top: 1rem;
    border-top: 1px solid rgba(0, 0, 0, 0.1);
}

[data-theme="dark"] .about-card.expanded .about-expanded {
    border-top-color: rgba(255, 255, 255, 0.1);
}

.about-card:not(.expanded) .about-expanded {
    max-height: 0 !important;
    height: 0 !important;
    opacity: 0 !important;
    margin-top: 0 !important;
    margin-bottom: 0 !important;
    padding-top: 0 !important;
    padding-bottom: 0 !important;
    visibility: hidden !important;
    pointer-events: none !important;
    border: none !important;
}

.expanded-text {
    color: var(--text-secondary);
    line-height: 1.7;
    margin: 0;
    font-size: 0.95rem;
}

[data-theme="dark"] .expanded-text {
    color: #cbd5e1; /* Lighter color for better visibility */
}

/* Experience Section */
.experience {
    background: linear-gradient(291deg, #fafaf9 0%, #ffffff 50%, #ffffff 100%);
}

[data-theme="dark"] .experience {
    background: linear-gradient(135deg, #1a1a1a 0%, #2a2a2a 50%, #1f1f1f 100%);
}

.experience-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 1.5rem;
}

.experience .section-title {
    color: var(--text-primary);
}

.experience-item {
    padding: 2.5rem;
    background: rgba(255, 255, 255, 0.6);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border-radius: 16px;
    border: 1px solid rgba(255, 255, 255, 0.3);
    box-shadow: 
        0 8px 32px rgba(0, 0, 0, 0.08),
        inset 0 1px 0 rgba(255, 255, 255, 0.5);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    opacity: 0;
    transform: translateY(30px);
    cursor: pointer;
    position: relative;
    overflow: hidden;
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
}

[data-theme="dark"] .experience-item {
    background: rgba(30, 30, 30, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.15);
    box-shadow: 
        0 8px 32px rgba(0, 0, 0, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.experience-item.visible {
    opacity: 1;
    transform: translateY(0);
    animation: fadeInUp 0.6s ease forwards;
}

.experience-item:hover {
    transform: translateY(-6px);
    background: rgba(255, 255, 255, 0.75);
    backdrop-filter: blur(25px) saturate(200%);
    -webkit-backdrop-filter: blur(25px) saturate(200%);
    box-shadow: 
        0 16px 48px rgba(0, 0, 0, 0.12),
        inset 0 1px 0 rgba(255, 255, 255, 0.7);
    border-color: rgba(255, 255, 255, 0.4);
}

[data-theme="dark"] .experience-item:hover {
    background: rgba(40, 40, 40, 0.75);
    backdrop-filter: blur(25px) saturate(200%);
    -webkit-backdrop-filter: blur(25px) saturate(200%);
    box-shadow: 
        0 16px 48px rgba(0, 0, 0, 0.5),
        inset 0 1px 0 rgba(255, 255, 255, 0.15);
    border-color: rgba(255, 255, 255, 0.2);
}

.experience-item.expanded {
    padding-bottom: 2.5rem;
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(30px) saturate(200%);
    -webkit-backdrop-filter: blur(30px) saturate(200%);
}

[data-theme="dark"] .experience-item.expanded {
    background: rgba(45, 45, 45, 0.8);
}

.experience-badge {
    display: block;
    padding: 0;
    background: transparent;
    border-radius: 0;
    font-size: 1.5rem;
    font-weight: 400;
    margin-bottom: 1.5rem;
    line-height: 1.2;
}

.badge-1 {
    color: #5b8fc9;
}

.badge-2 {
    color: #c97a7a;
}

.badge-3 {
    color: #d49a6a;
}

[data-theme="dark"] .badge-1 {
    color: #7ba8d4;
}

[data-theme="dark"] .badge-2 {
    color: #d89696;
}

[data-theme="dark"] .badge-3 {
    color: #e0b088;
}

.experience-text {
    color: var(--text-secondary);
    line-height: 1.7;
    margin-bottom: 0;
    transition: all 0.4s ease;
}

[data-theme="dark"] .experience-text {
    color: #cbd5e1; /* Lighter color for better visibility */
}

.experience-expanded {
    max-height: 0;
    height: 0;
    overflow: hidden;
    transition: max-height 0.4s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.4s ease, margin-top 0.4s ease, padding 0.4s ease;
    opacity: 0;
    margin-top: 0;
    margin-bottom: 0;
    padding-top: 0;
    padding-bottom: 0;
    visibility: hidden;
    pointer-events: none;
}

.experience-item.expanded .experience-expanded {
    max-height: 500px;
    height: auto;
    opacity: 1;
    margin-top: 1.5rem;
    visibility: visible;
    pointer-events: auto;
}

/* Ensure collapsed items are definitely hidden and take no space */
.experience-item:not(.expanded) .experience-expanded {
    max-height: 0 !important;
    height: 0 !important;
    opacity: 0 !important;
    margin-top: 0 !important;
    margin-bottom: 0 !important;
    padding-top: 0 !important;
    padding-bottom: 0 !important;
    visibility: hidden !important;
    pointer-events: none !important;
    border: none !important;
}

.experience-item:not(.expanded) .experience-outcomes {
    padding-top: 0 !important;
    padding-bottom: 0 !important;
    border-top: none !important;
    margin: 0 !important;
}

.experience-outcomes {
    padding-top: 1.5rem;
    border-top: 1px solid var(--border);
    transition: padding 0.4s ease, border 0.4s ease;
}

.outcomes-title {
    color: var(--text-primary);
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 1.25rem;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    font-size: 0.875rem;
}

[data-theme="dark"] .outcomes-title {
    color: #f8fafc; /* Ensure visibility in dark mode */
}

.outcomes-metrics {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
}

.metric-item {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.metric-value {
    color: rgb(49, 99, 49);
    font-size: 1.75rem;
    font-weight: 200;
    line-height: 1;
    margin-bottom: 0.5rem;
}

.metric-label {
    color: var(--text-secondary);
    font-size: 0.875rem;
    font-weight: 400;
    line-height: 1.4;
}

[data-theme="dark"] .metric-label {
    color: #cbd5e1; /* Lighter color for better visibility */
}

@media (max-width: 768px) {
    .outcomes-metrics {
        grid-template-columns: 1fr;
        gap: 1.25rem;
    }
    
    .metric-value {
        font-size: 1.75rem;
    }
}

/* Skills Section */
.skills {
    background: linear-gradient(291deg, #cdcd1845 0%, #6cb7e7f7 50%, #c9eb9d 100%);
}

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

.skill-tag {
    padding: 0.75rem 1.5rem;
    background: var(--bg-primary);
    border: 1px solid var(--border);
    border-radius: 8px;
    font-size: 0.9375rem;
    font-weight: 500;
    color: var(--text-primary);
    transition: all 0.3s ease;
    opacity: 0;
    transform: scale(0.8);
    animation: fadeInScale 0.5s ease forwards;
}

.skill-tag:nth-child(1) { animation-delay: 0.1s; }
.skill-tag:nth-child(2) { animation-delay: 0.15s; }
.skill-tag:nth-child(3) { animation-delay: 0.2s; }
.skill-tag:nth-child(4) { animation-delay: 0.25s; }
.skill-tag:nth-child(5) { animation-delay: 0.3s; }
.skill-tag:nth-child(6) { animation-delay: 0.35s; }
.skill-tag:nth-child(7) { animation-delay: 0.4s; }
.skill-tag:nth-child(8) { animation-delay: 0.45s; }
.skill-tag:nth-child(9) { animation-delay: 0.5s; }
.skill-tag:nth-child(10) { animation-delay: 0.55s; }
.skill-tag:nth-child(11) { animation-delay: 0.6s; }
.skill-tag:nth-child(12) { animation-delay: 0.65s; }
.skill-tag:nth-child(13) { animation-delay: 0.7s; }
.skill-tag:nth-child(14) { animation-delay: 0.75s; }
.skill-tag:nth-child(15) { animation-delay: 0.8s; }
.skill-tag:nth-child(16) { animation-delay: 0.85s; }

@keyframes fadeInScale {
    to {
        opacity: 1;
        transform: scale(1);
    }
}

.skill-tag:hover {
    background: var(--accent);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.3);
}

/* Contact Section */
.contact {
    background: linear-gradient(135deg, var(--gradient-start) 0%, var(--gradient-end) 100%);
}

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

/* Footer */
footer.footer {
    background: #5576f6;
    border-top: 1px solid var(--border);
    padding: 1rem 0;
    margin: 0;
    box-sizing: border-box;
    overflow: hidden;
    position: relative;
    will-change: transform;
    /* Ensure footer doesn't expand - fixed height based on content */
    height: auto;
    min-height: auto;
    max-height: none;
    /* Prevent layout shift during animation */
    contain: layout style;
}

.footer .container {
    padding: 0 2rem;
    max-width: 1200px;
    margin: 0 auto;
    box-sizing: border-box;
}

.footer-text {
    text-align: center;
    color: rgba(255, 255, 255, 0.9);
    font-size: 0.875rem;
    margin: 0;
    padding: 0;
    line-height: 1.5;
}

[data-theme="dark"] .footer-text {
    color: rgba(255, 255, 255, 0.9);
}

/* Responsive Design */
@media (max-width: 768px) {
    .nav-container {
        padding: 1rem 1.5rem;
    }

    .mobile-menu-toggle {
        display: flex;
    }

    .nav-links {
        position: fixed;
        top: 0;
        right: -100%;
        width: 280px;
        height: 100vh;
        background: var(--bg-secondary);
        backdrop-filter: blur(20px);
        flex-direction: column;
        align-items: flex-start;
        justify-content: flex-start;
        padding: 5rem 2rem 2rem;
        gap: 2rem;
        transition: right 0.3s ease;
        box-shadow: -4px 0 20px rgba(0, 0, 0, 0.1);
        z-index: 1000;
        overflow-y: auto;
    }

    [data-theme="dark"] .nav-links {
        background: rgba(20, 20, 20, 0.95);
        box-shadow: -4px 0 20px rgba(0, 0, 0, 0.5);
    }

    .nav-links.active {
        right: 0;
    }

    .nav-link {
        font-size: 1.125rem;
        width: 100%;
        padding: 0.75rem 0;
        border-bottom: 1px solid var(--border);
    }

    .nav-link::after {
        display: none;
    }

    .theme-toggle {
        margin-top: 1rem;
        width: 100%;
        justify-content: flex-start;
        padding: 0.75rem 0;
        border: none;
        border-bottom: 1px solid var(--border);
        border-radius: 0;
    }

    .hero {
        padding: 6rem 1.5rem 3rem;
        min-height: 100vh;
        height: auto;
    }

    .hero-title {
        font-size: clamp(2rem, 6vw, 3rem);
    }

    .hero-subtitle-container {
        padding: 0.75rem 1.5rem;
        margin-bottom: 2rem;
    }
    
    .hero-subtitle {
        font-size: 0.9375rem;
    }

    .container {
        padding: 0 1.5rem;
    }

    section {
        padding: 4rem 0;
    }

    .section-title {
        font-size: clamp(1.5rem, 5vw, 2.5rem);
        margin-bottom: 2.5rem;
    }

    .about-grid,
    .experience-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .about-card,
    .experience-item {
        padding: 2rem;
    }
    
    .experience-badge {
        font-size: 1.25rem;
        margin-bottom: 1.25rem;
    }

    .hero-cta,
    .contact-cta {
        flex-direction: column;
    }

    .btn {
        width: 100%;
        justify-content: center;
    }

    .skills-container {
        gap: 0.75rem;
    }

    .skill-tag {
        font-size: 0.875rem;
        padding: 0.625rem 1.25rem;
    }

    .about-title {
        font-size: clamp(1.5rem, 5vw, 2.5rem);
    }

    .hand-icon {
        font-size: 1em;
        margin: 0 0.2rem;
    }
}

@media (max-width: 480px) {
    .nav-logo {
        font-size: 1rem;
        gap: 0.625rem;
    }
    
    .logo-icon {
        width: 28px;
        height: 28px;
    }

    .nav-container {
        padding: 1rem;
    }

    .nav-links {
        width: 100%;
        right: -100%;
    }

    .hero {
        padding: 5rem 1rem 2rem;
    }

    .hero-title {
        font-size: clamp(1.75rem, 7vw, 2.5rem);
        line-height: 1.3;
    }
    
    .hero-subtitle-container {
        padding: 0.625rem 1.25rem;
        margin-bottom: 1.5rem;
    }
    
    .hero-subtitle {
        font-size: 0.875rem;
    }

    .container {
        padding: 0 1rem;
    }

    section {
        padding: 3rem 0;
    }

    .section-title {
        font-size: clamp(1.25rem, 6vw, 2rem);
        margin-bottom: 2rem;
    }

    .about-card,
    .experience-item {
        padding: 1.5rem;
    }
    
    .experience-badge {
        font-size: 1.125rem;
        margin-bottom: 1rem;
    }
    
    .experience-text,
    .experience-question {
        font-size: 0.9375rem;
    }

    .card-text,
    .experience-text {
        font-size: 0.9375rem;
    }
}

/* Smooth scroll behavior */
html {
    scroll-padding-top: 100px;
    scroll-behavior: smooth;
}

/* Ensure sections don't overlap */
section:not(.hero) {
    position: relative;
    z-index: 2;
    clear: both;
}

/* Prevent hero from overlapping next sections */
.hero + section {
    margin-top: 0;
    padding-top: 8rem;
}

/* Loading animation */
@keyframes shimmer {
    0% {
        background-position: -1000px 0;
    }
    100% {
        background-position: 1000px 0;
    }
}

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

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

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

@keyframes fadeInScale {
    from {
        opacity: 0;
        transform: scale(0.9);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes slideInDown {
    from {
        opacity: 0;
        transform: translateY(-30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Initial hidden state for animated elements */
.animate-on-load {
    opacity: 0;
}

.animate-fade-in-up {
    animation: fadeInUp 0.8s ease-out forwards;
}

.animate-fade-in-left {
    animation: fadeInLeft 0.8s ease-out forwards;
}

.animate-fade-in-right {
    animation: fadeInRight 0.8s ease-out forwards;
}

.animate-fade-in-scale {
    animation: fadeInScale 0.8s ease-out forwards;
}

.animate-slide-in-down {
    animation: slideInDown 0.8s ease-out forwards;
}

/* Navigation animation */
.nav {
    animation: slideInDown 0.6s ease-out;
}

/* Hero section animations - handled by JavaScript */

/* Skills, Contact, and Footer animations - handled by JavaScript */
