@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;600;700&display=swap');

:root {
    --primary-color: #667eea;
    --secondary-color: #764ba2;
    --text-color: #2d3748;
    --bg-color: #ffffff;
    --card-bg: #f7fafc;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --accent-color: #48bb78;
    --border-color: rgba(102, 126, 234, 0.15);
    --shadow-light: 0 4px 20px rgba(0, 0, 0, 0.08);
    --shadow-medium: 0 8px 32px rgba(0, 0, 0, 0.12);
    --shadow-heavy: 0 16px 48px rgba(0, 0, 0, 0.16);
    --border-radius: 12px;
    --section-padding: 80px 0;
    --glass-bg: rgba(255, 255, 255, 0.25);
    --glass-border: rgba(255, 255, 255, 0.18);
    --glass-blur: blur(16px);
}

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

/* Scroll Progress Indicator */
.scroll-progress {
    position: fixed;
    top: 0;
    left: 0;
    width: 0%;
    height: 4px;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    z-index: 9999;
    transition: width 0.1s ease;
    box-shadow: 0 0 10px rgba(102, 126, 234, 0.5);
}

.scroll-progress::after {
    content: '';
    position: absolute;
    top: 0;
    right: -10px;
    width: 10px;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(102, 126, 234, 0.8));
    border-radius: 0 2px 2px 0;
}

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

/* Enhanced selection styling */
::selection {
    background: var(--primary-color);
    color: white;
}

::-moz-selection {
    background: var(--primary-color);
    color: white;
}

body {
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background: var(--bg-color);
    transition: var(--transition);
    font-size: 16px;
    font-weight: 400;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    scroll-behavior: smooth;
    overflow-x: hidden;
}

/* Page Loading Animation */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--bg-color);
    z-index: 10000;
    opacity: 1;
    visibility: visible;
    transition: opacity 0.5s ease, visibility 0.5s ease;
    pointer-events: none;
}

body.loaded::before {
    opacity: 0;
    visibility: hidden;
}

/* Image Loading States */
.img-loading {
    background: linear-gradient(
        90deg,
        rgba(102, 126, 234, 0.1) 0%,
        rgba(102, 126, 234, 0.2) 50%,
        rgba(102, 126, 234, 0.1) 100%
    );
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
    border-radius: var(--border-radius);
}

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

.img-loaded {
    animation: fadeIn 0.3s ease-in-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: scale(0.95);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* Skeleton Loading States */
.skeleton {
    background: linear-gradient(
        90deg,
        rgba(102, 126, 234, 0.08) 0%,
        rgba(102, 126, 234, 0.15) 50%,
        rgba(102, 126, 234, 0.08) 100%
    );
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
    border-radius: 8px;
}

.skeleton-text {
    height: 16px;
    margin-bottom: 8px;
}

.skeleton-title {
    height: 24px;
    width: 70%;
    margin-bottom: 12px;
}

.skeleton-paragraph {
    height: 14px;
    margin-bottom: 6px;
}

.skeleton-paragraph:last-child {
    width: 80%;
}

/* Dark Mode Styles */
.dark-mode {
    --text-color: #e2e8f0;
    --bg-color: #1a202c;
    --card-bg: #2d3748;
    --border-color: rgba(255, 255, 255, 0.1);
    --shadow-light: 0 4px 20px rgba(0, 0, 0, 0.4);
    --shadow-medium: 0 8px 32px rgba(0, 0, 0, 0.5);
    --shadow-heavy: 0 16px 48px rgba(0, 0, 0, 0.6);
    --glass-bg: rgba(45, 55, 72, 0.4);
    --glass-border: rgba(255, 255, 255, 0.1);
}

.dark-mode nav ul li a:hover {
    color: var(--primary-color);
}

/* Header Styles */
header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    padding: 12px 40px;
    background: var(--glass-bg);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border-bottom: 1px solid var(--glass-border);
    z-index: 1000;
    transition: var(--transition);
    box-shadow: var(--shadow-light);
    height: 70px;
    display: flex;
    align-items: center;
}

header.scrolled {
    padding: 8px 40px;
    height: 60px;
    background: rgba(255, 255, 255, 0.95);
    box-shadow: var(--shadow-medium);
}

.dark-mode header.scrolled {
    background: rgba(26, 32, 44, 0.95);
}

@media (max-width: 768px) {
    header {
        padding: 8px 20px;
        height: 60px;
    }
}

.dark-mode header {
    background: rgba(26, 32, 44, 0.95);
    border-bottom-color: rgba(255, 255, 255, 0.1);
}

.dark-mode .logo {
    color: var(--primary-color);
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

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

@media (min-width: 769px) {
    .nav-links {
        position: static !important;
        flex-direction: row !important;
        background: none !important;
        height: auto !important;
        width: auto !important;
        clip-path: none !important;
        -webkit-clip-path: none !important;
        pointer-events: all !important;
    }
    
    .nav-links li {
        opacity: 1 !important;
        margin-left: 30px;
    }
}

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

/* Remove duplicate nav ul styles - handled above */

nav ul li a {
    text-decoration: none;
    color: var(--text-color);
    font-weight: 600;
    transition: var(--transition);
    position: relative;
    padding: 8px 16px;
    border-radius: 8px;
}

nav ul li a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: 4px;
    left: 50%;
    background: var(--primary-color);
    transition: all 0.3s ease;
    transform: translateX(-50%);
}

nav ul li a:hover {
    color: var(--primary-color);
}

nav ul li a:hover::after {
    width: 60%;
    transform: translateX(-50%);
}

.theme-toggle {
    background: none;
    border: 2px solid transparent;
    color: var(--text-color);
    font-size: 1.2rem;
    cursor: pointer;
    transition: var(--transition);
    padding: 8px;
    border-radius: 50%;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.theme-toggle:hover {
    color: var(--primary-color);
    background: rgba(102, 126, 234, 0.1);
    border-color: var(--primary-color);
}

.theme-toggle:focus {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* Hero Section Styles */
.hero {
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 2rem 20px;
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    position: relative;
    overflow: hidden;
}

.hero-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 90%;
    max-width: 1200px;
    gap: 4rem;
    z-index: 2;
    position: relative;
}

/* Ensure desktop layout stays side-by-side */
@media (min-width: 901px) {
    .hero-content {
        flex-direction: row !important;
    }
    
    .profile-container {
        order: 0 !important;
        margin: 0 !important;
    }
    
    .hero-text {
        order: 0 !important;
        text-align: left;
    }
}

.hero h1 {
    font-size: 4rem;
    margin-bottom: 20px;
    color: #fff;
}

.subtitle {
    font-size: 1.2rem;
    margin-bottom: 2rem;
    color: rgba(255, 255, 255, 0.9);
    line-height: 1.6;
    font-weight: 400;
    max-width: 500px;
}

/* Button Styles */
.cta-button, .submit-btn, .download-cv {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 14px 28px;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: #fff;
    text-decoration: none;
    border-radius: 12px;
    font-weight: 600;
    transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    border: none;
    cursor: pointer;
    font-size: 1rem;
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.3);
    position: relative;
    overflow: hidden;
    letter-spacing: 0.5px;
    text-align: center;
}

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

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

.cta-button:hover, .submit-btn:hover, .download-cv:hover {
    background: linear-gradient(135deg, var(--accent-color), var(--primary-color));
    transform: translateY(-3px) scale(1.05);
    box-shadow: 0 12px 35px rgba(102, 126, 234, 0.4), 0 0 0 2px rgba(255, 255, 255, 0.1);
}

.cta-button:active, .submit-btn:active, .download-cv:active {
    transform: translateY(0) scale(0.98);
}

/* Portfolio Section Styles */
.portfolio {
    padding: var(--section-padding);
    background: var(--bg-color);
    position: relative;
}

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

.section-header {
    text-align: center;
    margin-bottom: 3rem;
}

.section-title {
    font-size: clamp(2rem, 4vw, 2.5rem);
    font-weight: 700;
    margin-bottom: 1rem;
    color: var(--primary-color);
    line-height: 1.2;
    position: relative;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 3px;
    background: var(--accent-color);
    border-radius: 2px;
}

.section-subtitle {
    font-size: 1.1rem;
    color: var(--text-color);
    opacity: 0.8;
    max-width: 600px;
    margin: 0 auto;
    line-height: 1.6;
}

/* Responsive section title sizes */
@media (min-width: 576px) {
    .section-title {
        font-size: 2.75rem;
    }
}

@media (min-width: 768px) {
    .section-title {
        font-size: 3rem;
    }
}

@media (min-width: 992px) {
    .section-title {
        font-size: 3.25rem;
        margin-bottom: 3rem;
    }
}

.reveal-text {
    display: inline-block;
    position: relative;
    color: var(--primary-color);
    transition: color 0.3s ease;
    margin-bottom: 3rem;
}

.reveal-text::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: var(--bg-color);
    transform: scaleX(0);
    transform-origin: left;
}

.portfolio:hover .reveal-text {
    animation: textReveal 2s forwards;
}

.portfolio:hover .reveal-text::after {
    animation: coverReveal 2s forwards;
}

@keyframes textReveal {
    0%, 100% { color: var(--primary-color); }
    50% { color: var(--bg-color); }
}

@keyframes coverReveal {
    0% { transform: scaleX(0); transform-origin: left; }
    50% { transform: scaleX(1); transform-origin: left; }
    50.1% { transform: scaleX(1); transform-origin: right; }
    100% { transform: scaleX(0); transform-origin: right; }
}

/* Project grid styles */
.project-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2rem;
    padding: 0 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

.project-card {
    width: 100%;
}

@media (min-width: 768px) {
    .project-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Project Card Styles */
.project-card, .cert-card {
    position: relative;
    border-radius: var(--border-radius);
    overflow: hidden;
    height: 360px;
    box-shadow: var(--shadow-light);
    transition: var(--transition);
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
}

.project-content {
    position: relative;
    height: 100%;
    background-size: cover;
    background-position: top center;
}

.project-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(to bottom, rgba(0,0,0,0.2), rgba(0,0,0,0.8));
    opacity: 0;
    transition: var(--transition);
}

.project-card:hover,
.project-card:focus-within {
    transform: translateY(-8px) scale(1.02);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15), 0 0 0 1px rgba(102, 126, 234, 0.2);
    transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.project-card:hover::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.1), rgba(118, 75, 162, 0.1));
    z-index: 1;
    pointer-events: none;
    opacity: 1;
    transition: opacity 0.3s ease;
}

.project-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.05), rgba(118, 75, 162, 0.05));
    z-index: 1;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.project-card:focus {
    outline: 2px solid var(--primary-color);
    outline-offset: 4px;
}

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

.project-info {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 20px;
    color: #fff;
    transform: translateY(100%);
    transition: var(--transition);
    background: rgba(26, 32, 44, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.3);
}

.project-card:hover .project-info {
    transform: translateY(0);
}

.project-info h3 {
    font-size: 1.4rem;
    margin-bottom: 12px;
    font-weight: 700;
    line-height: 1.3;
    color: #ffffff;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
}

.project-info p {
    font-size: 0.95rem;
    margin-bottom: 16px;
    line-height: 1.5;
    color: rgba(255, 255, 255, 0.9);
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

.project-tech-stack {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 15px;
    list-style-type: none;
    padding: 0;
}

.project-tech-stack li {
    background-color: rgba(102, 126, 234, 0.8);
    color: #ffffff;
    padding: 3px 6px;
    border-radius: 10px;
    font-size: 0.7rem;
    font-weight: 500;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.project-links {
    display: flex;
    gap: 15px;
}

.project-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 8px 16px;
    background-color: var(--primary-color);
    color: #fff;
    text-decoration: none;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 600;
    transition: var(--transition);
    border: 2px solid transparent;
}

.project-link:hover,
.project-link:focus {
    background-color: var(--secondary-color);
    transform: translateY(-2px);
    box-shadow: var(--shadow-light);
}

.project-link:focus {
    outline: 2px solid #fff;
    outline-offset: 2px;
}

.link-text {
    font-size: 0.85rem;
    font-weight: 500;
}

.view-more-container {
    text-align: center;
    margin-top: 4rem;
    display: flex;
    justify-content: center;
    align-items: center;
}


@media (max-width: 768px) {
    .project-grid {
        grid-template-columns: 1fr;
        padding: 0 1rem;
        gap: 2rem;
    }

    .hero-content {
        width: 100%;
        gap: 2rem;
    }

    .hero {
        padding: 0 1rem !important;
        min-height: 90vh;
    }

    .section-title {
        font-size: 2.2rem !important;
        margin-bottom: 2rem !important;
    }

    .contact-container {
        padding: 2rem 1.5rem !important;
        margin: 0 1rem;
    }

    .about-list {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    .about-list li {
        padding: 14px;
    }
}

/* About Section Styles */
.about {
    padding: var(--section-padding);
    background: var(--bg-color);
    position: relative;
}

.about-content {
    max-width: 900px;
    margin: 0 auto;
    padding: 0 2rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 48px;
    text-align: center;
}

.profile-pic {
    width: 200px;
    height: 200px;
    border-radius: 50%;
    object-fit: cover;
}

.about-text {
    flex: 1;
}

.about-text h2 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    color: var(--primary-color);
}

.about-text p {
    margin-bottom: 1rem;
    line-height: 1.6;
}

.about-list {
    list-style-type: none;
    padding-left: 0;
    margin-bottom: 1rem;
}

.about-list li {
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
}

.about-list li i {
    color: var(--primary-color);
    margin-right: 0.5rem;
}

.cta-container {
    display: flex;
    gap: 20px;
    margin-top: 0;
}

/* Removed duplicate - using main definition above */

.download-cv i {
    margin-right: 10px;
}

/* Contact Section Styles */
.contact {
    background: var(--bg-color);
    padding: var(--section-padding);
    position: relative;
}

.contact-container {
    max-width: 600px;
    margin: 0 auto;
    padding: 2rem 2rem;
    background: rgba(255, 255, 255, 0.05);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-medium);
    border: 1px solid rgba(102, 126, 234, 0.1);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
}

.dark-mode .contact-container {
    background: rgba(45, 55, 72, 0.3);
    border-color: rgba(255, 255, 255, 0.1);
}

.section-title {
    font-size: 3rem;
    font-weight: 700;
    text-align: center;
    margin-bottom: 40px;
    position: relative;
    overflow: hidden;
    color: var(--primary-color) !important;
}

.contact-description {
    text-align: center;
    margin-bottom: 2rem;
    color: var(--text-color);
}

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

/* Using floating-label styles instead */

.submit-btn {
    background-color: var(--primary-color);
    color: #fff;
    border: none;
    padding: 12px 24px;
    font-size: 1rem;
    border-radius: 30px;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-weight: 600;
}

.submit-btn:hover {
    background-color: var(--secondary-color);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.submit-btn:active {
    transform: translateY(1px);
}

.btn-icon {
    font-size: 0.9em;
}

.form-status {
    margin-top: 1rem;
    padding: 0.75rem;
    border-radius: 8px;
    text-align: center;
    font-weight: 500;
    display: none;
    transition: all 0.3s ease;
    border: 1px solid transparent;
}

.form-status.success {
    background-color: rgba(72, 187, 120, 0.1);
    color: #38a169;
    border-color: rgba(72, 187, 120, 0.3);
    display: block;
}

.form-status.error {
    background-color: rgba(245, 101, 101, 0.1);
    color: #e53e3e;
    border-color: rgba(245, 101, 101, 0.3);
    display: block;
}

.form-status.info {
    background-color: rgba(102, 126, 234, 0.1);
    color: var(--primary-color);
    border-color: rgba(102, 126, 234, 0.3);
    display: block;
}

.btn-spinner {
    width: 16px;
    height: 16px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top: 2px solid white;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    display: none;
}

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

/* Micro-interactions */
.social-link:hover {
    animation: bounce 0.6s ease;
}

@keyframes bounce {
    0%, 20%, 60%, 100% {
        transform: translateY(0) scale(1);
    }
    40% {
        transform: translateY(-8px) scale(1.1);
    }
    80% {
        transform: translateY(-4px) scale(1.05);
    }
}

/* Smooth reveal animations */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.6s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.reveal.revealed {
    opacity: 1;
    transform: translateY(0);
}

/* Enhanced hover states */
.project-link:hover {
    animation: pulse 0.8s ease-in-out;
}

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

/* Staggered animations */
.tech-chip:nth-child(1) { animation-delay: 0.1s; }
.tech-chip:nth-child(2) { animation-delay: 0.2s; }
.tech-chip:nth-child(3) { animation-delay: 0.3s; }
.tech-chip:nth-child(4) { animation-delay: 0.4s; }
.tech-chip:nth-child(5) { animation-delay: 0.5s; }

/* Smooth transitions for theme switching */
* {
    transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease;
}

/* Reduced motion preferences */
@media (prefers-reduced-motion: reduce) {
    .reveal,
    .tech-chip,
    .project-card,
    .cta-button {
        animation: none !important;
        transition: none !important;
    }
}

/* Form Styles */
.form-group {
    position: relative;
    margin-bottom: 30px;
}

input, textarea {
    width: 100%;
    padding: 10px 0;
    font-size: 16px;
    color: var(--text-color);
    border: none;
    border-bottom: 1px solid var(--text-color);
    outline: none;
    background: transparent;
}

label {
    position: absolute;
    top: 0;
    left: 0;
    padding: 10px 0;
    font-size: 16px;
    color: var(--text-color);
    pointer-events: none;
    transition: var(--transition);
}

input:focus ~ label,
input:valid ~ label,
textarea:focus ~ label,
textarea:valid ~ label {
    top: -20px;
    font-size: 12px;
    color: var(--primary-color);
}

.submit-btn {
    padding: 10px 20px;
    background-color: var(--primary-color);
    color: #fff;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: var(--transition);
}

.submit-btn:hover {
    background-color: var(--secondary-color);
}

/* Footer Styles */
footer {
    background: var(--card-bg);
    color: var(--text-color);
    text-align: center;
    padding: 40px 20px;
    border-top: 1px solid var(--border-color);
    margin-top: 40px;
}

footer p {
    margin: 8px 0;
    opacity: 0.8;
    font-size: 0.95rem;
}

footer a {
    color: var(--primary-color);
    text-decoration: none;
    transition: var(--transition);
}

footer a:hover {
    color: var(--accent-color);
    text-decoration: underline;
}

.social-links {
    margin-bottom: 10px;
}

.social-links a {
    color: var(--text-color);
    font-size: 1.5rem;
    margin: 0 10px;
    transition: var(--transition);
}

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

.glitch {
    position: relative;
}

.glitch::before,
.glitch::after {
    content: attr(data-text);
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.glitch::before {
    left: 2px;
    text-shadow: -2px 0 #ff00c1;
    clip: rect(44px, 450px, 56px, 0);
    animation: glitch-anim 5s infinite linear alternate-reverse;
}

.glitch::after {
    left: -2px;
    text-shadow: -2px 2px #00fff9, 2px 2px #ff00c1;
    animation: glitch-anim2 1s infinite linear alternate-reverse;
}

@keyframes glitch-anim {
    0% { clip: rect(31px, 9999px, 94px, 0); }
    4.166666667% { clip: rect(91px, 9999px, 43px, 0); }
    8.333333333% { clip: rect(65px, 9999px, 59px, 0); }
    12.5% { clip: rect(30px, 9999px, 67px, 0); }
    16.66666667% { clip: rect(75px, 9999px, 67px, 0); }
    20.83333333% { clip: rect(82px, 9999px, 41px, 0); }
    25% { clip: rect(22px, 9999px, 73px, 0); }
    29.16666667% { clip: rect(67px, 9999px, 61px, 0); }
    33.33333333% { clip: rect(96px, 9999px, 38px, 0); }
    37.5% { clip: rect(43px, 9999px, 59px, 0); }
    41.66666667% { clip: rect(45px, 9999px, 73px, 0); }
    45.83333333% { clip: rect(47px, 9999px, 30px, 0); }
    50% { clip: rect(64px, 9999px, 55px, 0); }
    54.16666667% { clip: rect(84px, 9999px, 52px, 0); }
    58.33333333% { clip: rect(38px, 9999px, 86px, 0); }
    62.5% { clip: rect(4px, 9999px, 15px, 0); }
    66.66666667% { clip: rect(74px, 9999px, 39px, 0); }
    70.83333333% { clip: rect(89px, 9999px, 55px, 0); }
    75% { clip: rect(84px, 9999px, 4px, 0); }
    79.16666667% { clip: rect(75px, 9999px, 57px, 0); }
    83.33333333% { clip: rect(78px, 9999px, 93px, 0); }
    87.5% { clip: rect(32px, 9999px, 23px, 0); }
    91.66666667% { clip: rect(18px, 9999px, 96px, 0); }
    95.83333333% { clip: rect(57px, 9999px, 84px, 0); }
    100% { clip: rect(20px, 9999px, 59px, 0); }
}

@keyframes glitch-anim2 {
    0% { clip: rect(65px, 9999px, 100px, 0); }
    100% { clip: rect(93px, 9999px, 56px, 0); }
}

.profile-container {
    position: relative;
    width: 300px;
    height: 300px;
    animation: float 3s ease-in-out infinite;
}

.profile-image {
    transition: transform 0.6s cubic-bezier(.25,.8,.25,1), box-shadow 0.6s, clip-path 0.6s cubic-bezier(.25,.8,.25,1);
    width: 100%;
    height: 100%;
    object-fit: cover;
    clip-path: polygon(25% 0%, 100% 0%, 75% 100%, 0% 100%);
}

.profile-container:hover .profile-image {
    clip-path: polygon(0% 0%, 100% 0%, 100% 100%, 0% 100%);
}

.profile-outline {
    position: absolute;
    top: -10px;
    left: -10px;
    right: -10px;
    bottom: -10px;
    border: 2px solid var(--primary-color);
    clip-path: polygon(25% 0%, 100% 0%, 75% 100%, 0% 100%);
    transition: clip-path 0.5s ease, transform 0.5s ease;
}

.profile-container:hover .profile-outline {
    clip-path: polygon(0% 0%, 100% 0%, 100% 100%, 0% 100%);
    transform: rotate(5deg) scale(1.05);
}

.profile-dots {
    position: absolute;
    top: -20px;
    left: -20px;
    right: -20px;
    bottom: -20px;
    background-image: radial-gradient(var(--secondary-color) 1px, transparent 1px);
    background-size: 10px 10px;
    opacity: 0.5;
    clip-path: polygon(25% 0%, 100% 0%, 75% 100%, 0% 100%);
    transition: clip-path 0.5s ease, opacity 0.5s ease;
}

.profile-container:hover .profile-dots {
    clip-path: polygon(0% 0%, 100% 0%, 100% 100%, 0% 100%);
    opacity: 0.8;
}

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

.about {
    padding: 80px 0;
    background-color: var(--bg-color);
}

.about-content {
    max-width: 800px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 40px;
}

.about h2 {
    font-size: 2.5rem;
    margin-bottom: 20px;
    color: var(--primary-color);
}

.highlight {
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    background-clip: text;
    -webkit-background-clip: text;
    font-weight: 700;
    font-size: 2.8rem;
    letter-spacing: 1px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    display: inline-block;
}

.highlight:hover {
    transform: scale(1.1);
    text-shadow: 4px 4px 8px rgba(0, 0, 0, 0.2);
}

.highlight span {
    display: inline-block;
    transition: transform 0.3s ease;
}

.about:hover .highlight span {
    animation: wave 0.5s ease-in-out infinite;
}

.about:hover .highlight span:nth-child(even) {
    animation-delay: 0.1s;
}

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

.about p {
    margin-bottom: 24px;
    line-height: 1.7;
    font-size: 1.1rem;
    color: var(--text-color);
    opacity: 0.9;
}

.about-list {
    list-style-type: none;
    padding-left: 0;
    margin-bottom: 32px;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 16px;
    text-align: left;
}

.about-list li {
    display: flex;
    align-items: center;
    padding: 16px;
    background: var(--glass-bg);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-light);
    border: 1px solid var(--glass-border);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    transition: var(--transition);
}

.about-list li:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-medium);
}

.about-list li i {
    color: var(--accent-color);
    margin-right: 16px;
    font-size: 1.3rem;
    min-width: 24px;
}


/* Removed duplicate - using main definition above */

.download-cv i {
    margin-right: 10px;
}

@media (max-width: 768px) {

    .about h2 {
        font-size: 2rem;
    }

    .cta-container {
        flex-direction: column;
        align-items: center !important;
        justify-content: center !important;
        text-align: center !important;
    }

    .cta-button, .download-cv, .submit-btn {
        width: 100%;
        max-width: 350px;
        padding: 14px 28px;
    }

    .view-more-container {
        padding-inline: 2rem;
    }
}

/* Hamburger menu styles */
.hamburger {
    display: none;
    cursor: pointer;
    width: 32px;
    height: 24px;
    position: relative;
    z-index: 1001;
    padding: 4px;
    border-radius: 8px;
    transition: var(--transition);
    background: transparent;
    border: none;
}

.hamburger:hover {
    background: rgba(102, 126, 234, 0.1);
    transform: scale(1.05);
}

.hamburger span {
    display: block;
    position: absolute;
    height: 3px;
    width: 100%;
    background: var(--text-color);
    border-radius: 3px;
    opacity: 1;
    left: 0;
    transform: rotate(0deg);
    transition: .2s ease-in-out;
}

.hamburger span:nth-child(1) {
    top: 0px;
}

.hamburger span:nth-child(2) {
    top: 8px;
}

.hamburger span:nth-child(3) {
    top: 16px;
}

.hamburger.open span:nth-child(1) {
    top: 8px;
    transform: rotate(135deg);
}

.hamburger.open span:nth-child(2) {
    opacity: 0;
    left: -60px;
}

.hamburger.open span:nth-child(3) {
    top: 8px;
    transform: rotate(-135deg);
}

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

    .nav-links {
        position: fixed;
        top: 0;
        left: 0;
        height: 100vh;
        width: 100%;
        background: rgba(255, 255, 255, 0.98);
        backdrop-filter: blur(20px);
        -webkit-backdrop-filter: blur(20px);
        display: flex;
        flex-direction: column;
        justify-content: center;
        align-items: center;
        clip-path: circle(100px at 90% -20%);
        -webkit-clip-path: circle(100px at 90% -20%);
        transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1);
        pointer-events: none;
        z-index: 999;
        box-shadow: 0 0 50px rgba(0, 0, 0, 0.1);
    }
    
    .dark-mode .nav-links {
        background: rgba(26, 32, 44, 0.98);
    }

    .nav-links.open {
        clip-path: circle(1500px at 90% -10%);
        -webkit-clip-path: circle(1500px at 90% -10%);
        pointer-events: all;
    }

    .nav-links li {
        opacity: 0;
        margin-left: 0;
    }

    .nav-links li a {
        font-size: 25px;
    }

    .nav-links li:nth-child(1) {
        transition: all 0.3s ease 0.1s;
    }
    .nav-links li:nth-child(2) {
        transition: all 0.3s ease 0.2s;
    }
    .nav-links li:nth-child(3) {
        transition: all 0.3s ease 0.3s;
    }
    .nav-links li:nth-child(4) {
        transition: all 0.3s ease 0.4s;
    }
    .nav-links li:nth-child(5) {
        transition: all 0.3s ease 0.5s;
    }
    .nav-links li:nth-child(6) {
        transition: all 0.3s ease 0.6s;
    }

    .nav-links.open li {
        opacity: 1;
    }
}

/* Ensure hamburger is hidden on desktop */
@media (min-width: 769px) {
    .hamburger {
        display: none !important;
    }
}


.section-title {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    text-align: center;
    color: #333;
}

.contact-description {
    text-align: center;
    margin-bottom: 2rem;
    color: #666;
}

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

/* Using floating-label styles instead */

.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.submit-btn {
    background-color: #007bff;
    color: white;
    border: none;
    padding: 12px 24px;
    font-size: 1rem;
    border-radius: 8px;
    cursor: pointer;
    transition: background-color 0.3s, transform 0.1s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.submit-btn:hover {
    background-color: #0056b3;
}

.submit-btn:active {
    transform: translateY(1px);
}

.btn-icon {
    font-size: 0.9em;
}

.form-status {
    margin-top: 1rem;
    text-align: center;
    font-weight: bold;
}

.hamburger span {
    display: block;
    position: absolute;
    height: 3px;
    width: 100%;
    background: var(--text-color);
    border-radius: 3px;
    opacity: 1;
    left: 0;
    transform: rotate(0deg);
    transition: .2s ease-in-out;
}

.hamburger span:nth-child(1) {
    top: 0px;
}

.hamburger span:nth-child(2) {
    top: 8px;
}

.hamburger span:nth-child(3) {
    top: 16px;
}

.hamburger.open span:nth-child(1) {
    top: 8px;
    transform: rotate(135deg);
}

.hamburger.open span:nth-child(2) {
    opacity: 0;
    left: -60px;
}

.hamburger.open span:nth-child(3) {
    top: 8px;
    transform: rotate(-135deg);
}

/* Contact buttons now use main CTA style */

.certifications {
    padding: var(--section-padding);
    background: var(--bg-color);
    position: relative;
}

.certifications h3 {
    font-size: 2.5rem;
    margin-bottom: 3rem;
    text-align: center;
    color: var(--primary-color);
}

.cert-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2.5rem;
    perspective: 1000px;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

.cert-card {
    width: 300px;
    height: 350px;
    position: relative;
    transition: all 0.3s ease;
    cursor: pointer;
    transform: translateY(20px);
    opacity: 0;
    border-radius: 10px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.2);
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    transition: transform 0.3s ease, box-shadow 0.3s ease, opacity 0.5s ease;
}

.cert-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.cert-card:hover .cert-front {
    opacity: 0;
}

.cert-card:hover .cert-back {
    opacity: 1;
}



.cert-front,
.cert-back {
    position: absolute;
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    border-radius: 15px;
    padding: 2rem;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    transition: opacity 0.5s ease;
    backface-visibility: hidden;
}

.cert-back {
    background: linear-gradient(145deg, var(--primary-color), var(--secondary-color));
    color: white;
    opacity: 0;
}


.cert-back h4 {
    font-size: 1.3rem;
    margin-bottom: 0.5rem;
    text-align: center;
}

.cert-back p {
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
    text-align: center;
}

.cert-link {
    margin-top: 1rem;
    padding: 0.5rem 1rem;
    background-color: white;
    color: var(--primary-color);
    text-decoration: none;
    border-radius: 20px;
    transition: all 0.3s ease;
}

.cert-link:hover {
    background-color: var(--primary-color);
    color: white;
}

@media (max-width: 768px) {
    .cert-container {
        grid-template-columns: 1fr;
        justify-items: center;
        gap: 2rem;
        padding: 0 1rem;
        max-width: 400px;
    }
    
    .cert-card {
        width: 280px;
        height: 320px;
    }
    
    .certifications h3 {
        font-size: 2rem;
        margin-bottom: 2rem;
    }
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: #1e1e24;
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(45deg, #ff8785, #6ce5dc);
}

.cert-front {
    position: absolute;
    width: 100%;
    height: 100%;
    backface-visibility: hidden;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    border-radius: 15px;
    padding: 2rem;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    overflow: hidden;
}

.cert-card[data-cert="cert1"] .cert-front {
    background-image: url('resources/cert1.webp');
}

.cert-card[data-cert="cert2"] .cert-front {
    background-image: url('resources/cert2.webp');
}

.cert-card[data-cert="cert3"] .cert-front {
    background-image: url('resources/cert3.webp');
}

.cert-front::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0);  /* semi-transparent white overlay */
    z-index: 1;
}

/* Modal styles */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0,0,0,0.8);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.modal.show {
    opacity: 1;
}

#certImage {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    max-width: 90vw;
    max-height: 90vh;
    width: auto;
    height: auto;
    display: block;
    border-radius: 8px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
    z-index: 1001;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.modal.show #certImage {
    opacity: 1;
}

.close {
    color: #aaa;
    position: fixed;
    top: 10px;
    right: 20px;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    z-index: 1010;
    background-color: rgba(255, 255, 255, 0.7);
    width: 40px;  /* Set a fixed width */
    height: 40px; /* Set a fixed height equal to the width */
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    line-height: 1; /* Ensure the X is vertically centered */
}

.close:hover,
.close:focus {
    color: #000;
    text-decoration: none;
    cursor: pointer;
}

/* Certificate image styling moved to main modal-content section */

@media (max-width: 768px) {
    #certImage {
        max-width: 95vw;
        max-height: 85vh;
        border-radius: 4px;
    }

    .close {
        top: 5px;
        right: 10px;
        font-size: 24px;
        width: 35px;  /* Slightly smaller for mobile */
        height: 35px;
    }
}

@media (max-width: 768px) {
    .hero {
        align-items: flex-start;
        margin-top: 2rem; /* Increase top padding */
    }

    .hero-content {
        flex-direction: column;
    }

    .hero h1 {
        font-size: 2.5rem; /* Reduce font size */
        margin-top: 1rem; /* Add some top margin */
    }

    .subtitle {
        font-size: 1.2rem; /* Reduce subtitle font size */
    }

    .profile-container {
        margin-top: 1rem; /* Add space above the profile image */
    }

    .cta-button {
        font-size: 1rem !important; /* Reduce font size */
        height: 3rem !important;
    }
}

/* === Enhanced Hero Section === */
.hero-2025 {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: none;
    overflow: hidden;
    padding: 120px 20px 80px;
}

.hero-bg-gradient {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    z-index: 0;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 50%, #8b5cf6 100%);
    opacity: 0.95;
    animation: gradientShift 8s ease-in-out infinite;
}

@keyframes gradientShift {
    0%, 100% {
        background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 50%, #8b5cf6 100%);
    }
    50% {
        background: linear-gradient(135deg, #8b5cf6 0%, var(--primary-color) 50%, var(--secondary-color) 100%);
    }
}

.hero-pattern {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    z-index: 1;
    background-image: 
        radial-gradient(circle at 20% 20%, rgba(255,255,255,0.08) 1px, transparent 1px),
        radial-gradient(circle at 80% 80%, rgba(255,255,255,0.08) 1px, transparent 1px),
        radial-gradient(circle at 40% 60%, rgba(255,255,255,0.05) 2px, transparent 2px);
    background-size: 80px 80px, 60px 60px, 120px 120px;
    animation: patternMove 25s linear infinite;
}

@keyframes patternMove {
    0% { transform: translate(0, 0) rotate(0deg); }
    50% { transform: translate(30px, 30px) rotate(180deg); }
    100% { transform: translate(60px, 60px) rotate(360deg); }
}
.hero-headline-2025 {
    font-size: clamp(2.8rem, 6vw, 4.5rem);
    font-weight: 800;
    letter-spacing: -1.5px;
    margin-bottom: 1.5rem;
    position: relative;
    z-index: 2;
    line-height: 1.05;
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
}

.headline-gradient {
    background: linear-gradient(135deg, #ffffff 0%, rgba(255,255,255,0.9) 50%, #ffffff 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    color: transparent;
    display: block;
    position: relative;
    text-shadow: 0 2px 4px rgba(0,0,0,0.1);
    animation: textGlow 3s ease-in-out infinite alternate;
}

@keyframes textGlow {
    0% {
        filter: drop-shadow(0 0 5px rgba(255,255,255,0.3));
    }
    100% {
        filter: drop-shadow(0 0 15px rgba(255,255,255,0.5));
    }
}

.headline-gradient::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 0;
    width: 80px;
    height: 4px;
    background: linear-gradient(90deg, var(--accent-color), rgba(72, 187, 120, 0.6));
    border-radius: 2px;
    animation: expandLine 2s ease-out;
}

@keyframes expandLine {
    0% {
        width: 0;
        opacity: 0;
    }
    100% {
        width: 80px;
        opacity: 1;
    }
}
.profile-container {
    position: relative;
    z-index: 2;
    max-width: 350px;
    flex-shrink: 0;
}

.profile-wrapper {
    position: relative;
    display: inline-block;
}

.profile-image {
    width: 320px;
    height: 320px;
    border-radius: 50%;
    object-fit: cover;
    box-shadow: 0 25px 50px rgba(0,0,0,0.4);
    border: 4px solid rgba(255,255,255,0.3);
    transition: var(--transition);
    filter: brightness(1.05) contrast(1.1);
}

.profile-badge {
    position: absolute;
    bottom: 25px;
    right: 25px;
    background: var(--accent-color);
    color: #fff;
    padding: 10px 18px;
    border-radius: 25px;
    font-size: 0.9rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.6rem;
    box-shadow: 0 6px 20px rgba(0,0,0,0.3);
    animation: pulse 2s infinite;
}

.profile-badge i {
    font-size: 0.8rem;
}

.profile-wrapper:hover .profile-image {
    transform: scale(1.05) rotate(2deg);
    box-shadow: 0 30px 60px rgba(0,0,0,0.5);
    filter: brightness(1.1) contrast(1.15);
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
        box-shadow: 0 6px 20px rgba(0,0,0,0.3);
    }
    50% {
        transform: scale(1.05);
        box-shadow: 0 8px 25px rgba(72, 187, 120, 0.4);
    }
}
.hero-stats {
    display: flex;
    gap: 2.5rem;
    margin: 2.5rem 0;
    z-index: 2;
    position: relative;
    justify-content: center;
    flex-wrap: wrap;
}

.stat-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.stat-number {
    font-size: clamp(1.1rem, 2.5vw, 1.4rem);
    font-weight: 700;
    color: #fff;
    margin-bottom: 0.5rem;
    text-shadow: 0 2px 4px rgba(0,0,0,0.3);
    text-align: center;
    line-height: 1.2;
}

.stat-label {
    font-size: 0.85rem;
    color: rgba(255,255,255,0.7);
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 500;
}

.hero-actions {
    display: flex;
    gap: 1.5rem;
    flex-wrap: wrap;
    z-index: 2;
    position: relative;
    margin-top: 2.5rem;
}

.cta-primary {
    background: rgba(255,255,255,0.25);
    backdrop-filter: blur(12px);
    border: 2px solid rgba(255,255,255,0.4);
    color: #fff;
    font-weight: 600;
    padding: 14px 28px;
    font-size: 1rem;
}

.cta-secondary {
    background: transparent;
    border: 2px solid rgba(255,255,255,0.4);
    color: #fff;
    font-weight: 600;
    padding: 14px 28px;
    font-size: 1rem;
}

.cta-outline {
    background: transparent;
    border: 2px solid var(--primary-color);
    color: var(--primary-color);
    gap: 0.5rem;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.2);
}

.cta-outline:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none !important;
}

.cta-outline:disabled:hover {
    background: transparent;
    color: var(--primary-color);
    transform: none;
}

.cta-primary:hover {
    background: rgba(255,255,255,0.35);
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(255,255,255,0.2);
    border-color: rgba(255,255,255,0.6);
}

.cta-secondary:hover {
    background: rgba(255,255,255,0.15);
    border-color: rgba(255,255,255,0.6);
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(255,255,255,0.1);
}

.cta-outline:hover {
    background: var(--primary-color);
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.3);
}

.cta-icon {
    margin-left: 0.5rem;
    transition: transform 0.3s ease;
}

.cta-button:hover .cta-icon {
    transform: translateX(4px);
}
@media (max-width: 900px) {
    .hero-2025 {
        min-height: 100vh;
        padding: 140px 15px 100px;
        align-items: flex-start;
        justify-content: flex-start;
    }
    
    .hero-content {
        flex-direction: column !important;
        gap: 2rem;
        width: 100%;
        text-align: center;
        margin-top: 2rem;
    }
    
    .hero-text {
        max-width: 100%;
        order: 2 !important;
        text-align: center !important;
    }
    
    .hero-headline-2025 {
        font-size: clamp(2.2rem, 8vw, 3rem);
        margin-bottom: 1rem;
    }
    
    .subtitle {
        font-size: 1rem;
        margin-bottom: 1.5rem;
        line-height: 1.5;
    }
    
    .hero-stats {
        justify-content: center;
        gap: 1rem;
        flex-wrap: wrap;
        margin: 1.5rem 0;
    }
    
    .stat-item {
        min-width: 100px;
        flex: 1;
        max-width: 130px;
    }
    
    .stat-number {
        font-size: clamp(0.9rem, 3vw, 1.1rem);
    }
    
    .stat-label {
        font-size: 0.75rem;
    }
    
    .hero-actions {
        gap: 1rem;
        margin-top: 1.5rem;
        flex-direction: column;
        width: 100%;
    }
    
    .cta-button {
        width: 100%;
        max-width: 280px;
        margin: 0 auto;
        justify-content: center;
    }
    
    .profile-container {
        order: 1 !important;
        margin-bottom: 0;
        max-width: 280px;
        margin: 0 auto;
    }
    
    .profile-image {
        width: 240px;
        height: 240px;
    }
    
    .profile-badge {
        bottom: 15px;
        right: 15px;
        padding: 8px 14px;
        font-size: 0.8rem;
    }
}

/* === 2025 Portfolio Glassmorphism & Chips === */
.glass-card {
    background: var(--glass-bg);
    box-shadow: var(--shadow-medium);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border-radius: var(--border-radius);
    border: 1px solid var(--glass-border);
    transition: var(--transition);
    will-change: transform;
}
.glass-card:hover {
    box-shadow: 0 16px 48px 0 rgba(31, 38, 135, 0.25);
    transform: translateY(-8px) scale(1.03);
}
.tech-chip {
    display: inline-block;
    padding: 4px 8px;
    border-radius: 16px;
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.1), rgba(118, 75, 162, 0.1));
    color: var(--primary-color);
    font-weight: 600;
    font-size: 0.75rem;
    margin: 2px 2px 2px 0;
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.1);
    transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    border: 1px solid rgba(102, 126, 234, 0.15);
    cursor: default;
}

.tech-chip:hover {
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.2), rgba(118, 75, 162, 0.2));
    transform: translateY(-1px) scale(1.02);
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.2);
    border-color: var(--primary-color);
}
.project-title {
    font-family: 'Inter', 'Poppins', sans-serif;
    font-weight: 900;
    letter-spacing: -1px;
    font-size: 1.7rem;
}

/* === Certifications Flip Animation === */
.cert-card {
    perspective: 1200px;
    transition: transform 0.5s cubic-bezier(.25,.8,.25,1);
}
.cert-card {
    transform-style: preserve-3d;
}
.cert-card:hover .cert-front {
    transform: rotateY(180deg);
    opacity: 0;
}
.cert-card:hover .cert-back {
    transform: rotateY(0deg);
    opacity: 1;
}
.cert-front, .cert-back {
    transition: transform 0.6s cubic-bezier(.25,.8,.25,1), opacity 0.6s;
    backface-visibility: hidden;
}
.cert-front {
    transform: rotateY(0deg);
    z-index: 2;
}
.cert-back {
    transform: rotateY(180deg);
    z-index: 3;
}

/* === About Section Animation === */
.about-animate {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.7s cubic-bezier(.25,.8,.25,1), transform 0.7s cubic-bezier(.25,.8,.25,1);
}
.about-animate.visible {
    opacity: 1;
    transform: translateY(0);
}

/* === Floating Labels for Contact === */
.floating-label {
    position: relative;
    margin-bottom: 2rem;
}
.floating-label input,
.floating-label textarea {
    background: var(--bg-color);
    border: 2px solid rgba(102, 126, 234, 0.2);
    border-radius: 8px;
    padding: 16px 16px;
    font-size: 1rem;
    color: var(--text-color);
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
    box-shadow: none;
}

.dark-mode .floating-label input,
.dark-mode .floating-label textarea {
    background: var(--card-bg);
    border-color: rgba(255, 255, 255, 0.2);
    color: var(--text-color);
}

.dark-mode .floating-label input:focus,
.dark-mode .floating-label textarea:focus {
    border-color: var(--primary-color);
    background: var(--card-bg);
    color: var(--text-color);
}
.floating-label input:focus,
.floating-label textarea:focus {
    border-color: var(--primary-color);
    background: var(--bg-color);
    color: var(--text-color);
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
    outline: none;
}

.floating-label input:invalid:not(:focus),
.floating-label textarea:invalid:not(:focus) {
    border-color: #e53e3e;
}

.floating-label input:valid:not(:focus),
.floating-label textarea:valid:not(:focus) {
    border-color: var(--accent-color);
}
.floating-label label {
    position: absolute;
    left: 16px;
    top: 16px;
    color: rgba(102, 126, 234, 0.6);
    font-size: 1rem;
    pointer-events: none;
    background: transparent;
    transition: 0.2s ease;
    padding: 0;
}

.dark-mode .floating-label label {
    color: rgba(226, 232, 240, 0.6);
}

.dark-mode .floating-label input:focus + label,
.dark-mode .floating-label input:not(:placeholder-shown) + label,
.dark-mode .floating-label textarea:focus + label,
.dark-mode .floating-label textarea:not(:placeholder-shown) + label {
    color: var(--primary-color);
    background: var(--bg-color);
}
.floating-label input:focus + label,
.floating-label input:not(:placeholder-shown) + label,
.floating-label textarea:focus + label,
.floating-label textarea:not(:placeholder-shown) + label {
    top: -10px;
    left: 12px;
    font-size: 0.85rem;
    color: var(--primary-color);
    background: var(--bg-color);
    padding: 0 4px;
    font-weight: 500;
}

/* === Enhanced Form Validation States === */
.form-group.error input,
.form-group.error textarea {
    border-color: #ef4444 !important;
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.1) !important;
}

.form-group.valid input,
.form-group.valid textarea {
    border-color: #22c55e !important;
    box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.1) !important;
}

.form-group.error label {
    color: #ef4444 !important;
}

.form-group.valid label {
    color: #22c55e !important;
}

.form-group::after {
    content: '';
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    width: 16px;
    height: 16px;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.form-group.error::after {
    content: '⚠';
    color: #ef4444;
    opacity: 1;
    font-size: 14px;
}

.form-group.valid::after {
    content: '✓';
    color: #22c55e;
    opacity: 1;
    font-size: 14px;
    font-weight: bold;
}

/* === Loading Button States === */
.submit-btn.loading {
    pointer-events: none;
    opacity: 0.7;
}

.submit-btn.loading .btn-text {
    opacity: 0;
}

.submit-btn.loading .btn-spinner {
    display: inline-block !important;
    opacity: 1;
}

/* === Enhanced Accessibility & Focus Indicators === */
.btn:focus,
.cta-button:focus,
.nav-links a:focus,
.cert-link:focus,
.project-link:focus,
.social-link:focus,
.timeline-toggle:focus {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
    border-radius: 4px;
}

.floating-label input:focus,
.floating-label textarea:focus {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
}

/* High contrast focus for dark mode */
.dark-mode .btn:focus,
.dark-mode .cta-button:focus,
.dark-mode .nav-links a:focus,
.dark-mode .cert-link:focus,
.dark-mode .project-link:focus,
.dark-mode .social-link:focus {
    outline-color: #fff;
}

/* Skip links enhancement */
.skip-links a:focus {
    outline: 3px solid var(--accent-color);
    outline-offset: 0;
    background: var(--bg-color);
    color: var(--primary-color);
    padding: 12px 16px;
    border-radius: 8px;
    font-weight: 600;
    text-decoration: none;
}

/* Interactive elements hover states */
.timeline-dot:hover,
.timeline-dot:focus {
    transform: scale(1.1);
    box-shadow: 0 4px 12px rgba(72, 187, 120, 0.3);
    outline: none;
}

.timeline-dot:focus {
    outline: 2px solid var(--primary-color);
    outline-offset: 4px;
}

/* Certificate modal navigation accessibility */
.cert-prev:focus,
.cert-next:focus {
    outline: 2px solid #fff;
    outline-offset: 2px;
    background: rgba(0,0,0,0.8);
}

/* Form status message styling */
.form-status {
    padding: 12px 16px;
    border-radius: 8px;
    margin-top: 1rem;
    font-weight: 500;
    font-size: 0.9rem;
    display: none;
}

.form-status.success {
    background: rgba(34, 197, 94, 0.1);
    color: #22c55e;
    border: 1px solid rgba(34, 197, 94, 0.2);
}

.form-status.error {
    background: rgba(239, 68, 68, 0.1);
    color: #ef4444;
    border: 1px solid rgba(239, 68, 68, 0.2);
}

.form-status.info {
    background: rgba(59, 130, 246, 0.1);
    color: #3b82f6;
    border: 1px solid rgba(59, 130, 246, 0.2);
}

/* Dark mode form status */
.dark-mode .form-status.success {
    background: rgba(34, 197, 94, 0.2);
    color: #4ade80;
}

.dark-mode .form-status.error {
    background: rgba(239, 68, 68, 0.2);
    color: #f87171;
}

.dark-mode .form-status.info {
    background: rgba(59, 130, 246, 0.2);
    color: #60a5fa;
}

/* === Button Spinner & Feedback === */
.submit-btn .btn-spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid #fff;
    border-top: 3px solid #6c5ce7;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-left: 10px;
    vertical-align: middle;
}
@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* === Font and Global Improvements === */
body, .project-title, .section-title, .cert-title, .highlight {
    font-family: 'Inter', 'Poppins', sans-serif;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

/* Improved focus styles for accessibility */
*:focus-visible {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
    border-radius: 4px;
}

/* Performance optimizations */
.project-img,
.profile-image,
.cert-front {
    content-visibility: auto;
    contain-intrinsic-size: 350px 200px;
}

.profile-image {
    contain-intrinsic-size: 300px 300px;
}

/* Loading states */
.loading {
    opacity: 0.7;
    pointer-events: none;
    position: relative;
}

.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    margin: -10px 0 0 -10px;
    border: 2px solid var(--border-color);
    border-top: 2px solid var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

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

/* Scroll padding for fixed header */
:target {
    scroll-margin-top: 80px;
}

/* Optimize animations for better performance */
@media (prefers-reduced-motion: no-preference) {
    .glass-card,
    .project-card,
    .cta-button,
    .social-link {
        will-change: transform;
    }
}

/* Remove will-change after animations */
.glass-card:not(:hover),
.project-card:not(:hover):not(:focus),
.cta-button:not(:hover):not(:focus),
.social-link:not(:hover):not(:focus) {
    will-change: auto;
}

/* Improve text rendering */
body {
    text-rendering: optimizeSpeed;
}

h1, h2, h3, h4, h5, h6 {
    text-rendering: optimizeLegibility;
}

/* Optimize images */
img {
    height: auto;
    max-width: 100%;
    will-change: auto;
}

/* Performance optimizations */
.project-card,
.skill-card,
.cert-card,
.cta-button {
    contain: layout style;
    transform: translateZ(0);
}

/* Reduce GPU layer creation */
.project-card:not(:hover),
.skill-card:not(:hover),
.cert-card:not(:hover),
.cta-button:not(:hover) {
    will-change: auto;
}

/* Critical CSS optimizations */
* {
    -webkit-tap-highlight-color: transparent;
}

/* Improved focus states for accessibility */
:focus-visible {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
    border-radius: 4px;
}

.skip-links {
    position: absolute;
    top: -100px;
    left: 0;
    z-index: 10001;
}

.skip-link:focus {
    position: absolute;
    top: 0;
    left: 0;
    background: var(--primary-color);
    color: white;
    padding: 8px 16px;
    text-decoration: none;
    border-radius: 0 0 4px 0;
    z-index: 10001;
}

/* Keyboard navigation improvements */
.project-card:focus-within,
.skill-card:focus-within,
.cert-card:focus-within {
    transform: translateY(-4px) scale(1.01);
    box-shadow: var(--shadow-heavy);
    transition: all 0.3s ease;
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    :root {
        --primary-color: #0000ff;
        --secondary-color: #000080;
        --text-color: #000000;
        --bg-color: #ffffff;
    }
}

.project-img {
    object-fit: cover;
    background-color: var(--card-bg);
}

/* Critical resource hints */
@media (prefers-reduced-motion: reduce) {
    .hero-pattern {
        animation: none;
    }
    
    .hero-bg-gradient {
        animation: none;
    }
}

/* === Soft Shadows & Spacing === */
section, .glass-card {
    box-shadow: 0 2px 16px rgba(108, 92, 231, 0.04);
    border-radius: 18px;
}

.contact-container {
    box-shadow: none;
    border-radius: 18px;
    padding: 2rem;
}

@media (max-width: 700px) {
    .glass-card, .cert-card {
        border-radius: 12px;
    }
    .project-title {
        font-size: 1.2rem;
    }
}

/* === Theme Customizer & Accessibility === */
#themeColorPicker {
    border-radius: 50%;
    box-shadow: 0 2px 8px rgba(108, 92, 231, 0.08);
    outline: none;
    transition: box-shadow 0.2s;
}
#themeColorPicker:focus-visible {
    box-shadow: 0 0 0 3px var(--accent-color);
}

.skip-links {
    position: absolute;
    top: 0;
    left: 0;
    z-index: 10000;
}

.skip-link {
    position: absolute;
    left: -9999px;
    top: 16px;
    background: var(--accent-color);
    color: #fff;
    padding: 8px 16px;
    border-radius: 4px;
    font-weight: 600;
    text-decoration: none;
    font-size: 0.9rem;
    transition: var(--transition);
    box-shadow: var(--shadow-medium);
}

.skip-link:focus {
    left: 16px;
    outline: 2px solid #fff;
    outline-offset: 2px;
}

.hero-blob-bg {
    position: absolute;
    top: 0; left: 0;
    width: 100vw;
    height: 100vh;
    z-index: 1;
    pointer-events: none;
    filter: blur(0.5px) saturate(1.1);
    opacity: 0.7;
    transition: opacity 0.5s;
}
.parallax-img {
    will-change: transform;
    transition: transform 0.5s cubic-bezier(.25,.8,.25,1);
    z-index: 3;
}
@media (max-width: 900px) {
    .hero-blob-bg {
        height: 80vw;
        min-height: 300px;
    }
}

.tilt-card {
    position: relative;
    background: rgba(255,255,255,0.18);
    border-radius: 18px;
    box-shadow: 0 8px 32px 0 rgba(31, 38, 135, 0.18);
    border: 3px solid transparent;
    background-clip: padding-box;
    transition: box-shadow 0.3s, transform 0.3s, border 0.3s;
    z-index: 1;
}
.tilt-card::before {
    content: '';
    position: absolute;
    inset: -3px;
    border-radius: 20px;
    z-index: -1;
    background: linear-gradient(120deg, #a18cd1, #fbc2eb, #fad0c4, #6c5ce7, #00b894);
    background-size: 300% 300%;
    animation: borderGradientMove 6s linear infinite;
    opacity: 0.7;
    transition: opacity 0.3s;
}
@keyframes borderGradientMove {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}
.tilt-card:hover {
    box-shadow: 0 16px 48px 0 rgba(31, 38, 135, 0.25);
    transform: rotateY(8deg) rotateX(4deg) scale(1.03);
    border-color: transparent;
}
.tilt-card:hover::before {
    opacity: 1;
}
.project-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 16px 16px 0 0;
    box-shadow: 0 2px 12px rgba(108, 92, 231, 0.08);
    margin-bottom: 0.5rem;
    background: #f1f2f6;
    transition: box-shadow 0.3s;
    display: block;
}
@media (max-width: 700px) {
    .project-img {
        height: 100%;
    }
}

.cert-download {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-left: 0.5rem;
    background: #fff;
    color: var(--primary-color);
    border-radius: 50%;
    width: 36px;
    height: 36px;
    font-size: 1.1rem;
    box-shadow: 0 2px 8px rgba(108, 92, 231, 0.08);
    transition: background 0.2s, color 0.2s, transform 0.2s;
    border: none;
    text-decoration: none;
}
.cert-download:hover {
    background: var(--accent-color);
    color: #fff;
    transform: scale(1.1);
}

.cert-prev, .cert-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: #fff;
    color: var(--primary-color);
    border: none;
    border-radius: 50%;
    width: 44px;
    height: 44px;
    font-size: 1.3rem;
    box-shadow: 0 2px 8px rgba(108, 92, 231, 0.08);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1011;
    cursor: pointer;
    transition: background 0.2s, color 0.2s, transform 0.2s;
}
.cert-prev {
    left: 16px;
}
.cert-next {
    right: 16px;
}
.cert-prev:hover, .cert-next:hover, .cert-prev:focus, .cert-next:focus {
    background: var(--accent-color);
    color: #fff;
    transform: scale(1.1) translateY(-50%);
    outline: none;
}
@media (max-width: 700px) {
    .cert-prev, .cert-next {
        width: 36px;
        height: 36px;
        font-size: 1rem;
    }
    .cert-prev { left: 4px; }
    .cert-next { right: 4px; }
}

.timeline-section {
    padding: 80px 0;
    background: var(--bg-color);
    position: relative;
    z-index: 2;
}
.timeline {
    position: relative;
    max-width: 700px;
    margin: 2rem auto;
    padding-left: 24px;
    border-left: 3px solid var(--accent-color);
}
.timeline-item {
    position: relative;
    margin-bottom: 48px;
    padding-left: 16px;
    animation: fadeInUp 0.7s both;
}
.timeline-dot {
    position: absolute;
    left: -35px;
    top: 30px;
    width: 22px;
    height: 22px;
    background: #fff;
    border: 4px solid var(--accent-color);
    border-radius: 50%;
    box-shadow: 0 2px 8px rgba(108, 92, 231, 0.10);
    z-index: 2;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: box-shadow 0.2s;
}
@media (max-width: 768px) {
    .timeline {
        border-left: none;
        padding-left: 0;
        max-width: 100%;
        margin: 1rem auto;
    }
    
    .timeline-item {
        padding-left: 0;
        margin-bottom: 2rem;
        animation: fadeInUp 0.5s both;
    }
    
    .timeline-dot {
        position: relative;
        left: auto;
        top: auto;
        margin: 0 auto 1rem;
        width: 20px;
        height: 20px;
        border-width: 3px;
    }
    
    .timeline-content {
        padding: 1.2rem;
        text-align: center;
        border-radius: 12px;
    }
    
    .timeline-header {
        flex-direction: column;
        text-align: center;
        gap: 0.5rem;
    }
    
    .timeline-role {
        font-size: 1.1rem;
    }
    
    .timeline-meta,
    .timeline-date,
    .timeline-location {
        font-size: 0.85rem;
    }
    
    .timeline-list {
        text-align: left;
        padding-left: 1rem;
        font-size: 0.9rem;
    }
}
.timeline-content {
    background: rgba(255,255,255,0.18);
    border-radius: 18px;
    box-shadow: 0 8px 32px 0 rgba(31, 38, 135, 0.10);
    border: 1.5px solid rgba(255,255,255,0.22);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    padding: 1.5rem 1.5rem 1.2rem 1.5rem;
    position: relative;
    z-index: 1;
    transition: box-shadow 0.3s, transform 0.3s;
}

.timeline-content:hover {
    box-shadow: 0 16px 48px 0 rgba(31, 38, 135, 0.18);
    transform: translateY(-3px);
}
.timeline-role {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 0.2rem;
}
.timeline-meta {
    font-size: 1.05rem;
    color: var(--accent-color);
    margin-bottom: 0.1rem;
}
.timeline-date {
    font-size: 0.98rem;
    color: #888;
    margin-bottom: 0.1rem;
}
.timeline-location {
    font-size: 0.98rem;
    color: #888;
    margin-bottom: 0.7rem;
}
.timeline-list {
    padding-left: 1.2rem;
    margin: 0;
    color: var(--text-color);
    font-size: 1rem;
    line-height: 1.7;
}
.timeline-list li {
    margin-bottom: 0.5rem;
}
@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(40px); }
    to { opacity: 1; transform: translateY(0); }
}

.current-badge {
    display: inline-block;
    background: var(--accent-color);
    color: #fff;
    font-size: 0.85rem;
    font-weight: 700;
    border-radius: 8px;
    padding: 2px 10px;
    margin-left: 10px;
    vertical-align: middle;
    letter-spacing: 0.5px;
    box-shadow: 0 2px 8px rgba(108, 92, 231, 0.10);
}
.timeline-header {
    display: flex;
    align-items: center;
    gap: 0.7rem;
    margin-bottom: 0.2rem;
}
.timeline-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: #f1f2f6;
    color: var(--primary-color);
    font-size: 1.3rem;
    box-shadow: 0 2px 8px rgba(108, 92, 231, 0.08);
}
.timeline-dot[data-tooltip]:hover::after,
.timeline-dot[data-tooltip]:focus::after {
    content: attr(data-tooltip);
    position: absolute;
    left: 32px;
    top: 50%;
    transform: translateY(-50%);
    background: #222;
    color: #fff;
    font-size: 0.95rem;
    padding: 6px 14px;
    border-radius: 8px;
    white-space: nowrap;
    z-index: 10;
    opacity: 0.95;
    pointer-events: none;
    box-shadow: 0 2px 8px rgba(0,0,0,0.12);
}
.timeline-progress {
    width: 100%;
    height: 7px;
    background: #ececec;
    border-radius: 6px;
    margin: 1.1rem 0 0.7rem 0;
    overflow: hidden;
}
.timeline-progress-bar {
    height: 100%;
    background: linear-gradient(90deg, var(--accent-color), var(--primary-color));
    border-radius: 6px;
    transition: width 0.7s cubic-bezier(.25,.8,.25,1);
}
.timeline-progress-bar.current {
    background: linear-gradient(90deg, var(--primary-color), var(--accent-color));
    box-shadow: 0 2px 8px rgba(108, 92, 231, 0.10);
}
.timeline-toggle {
    background: none;
    border: none;
    color: var(--primary-color);
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    margin: 0.5rem 0 0.2rem 0;
    padding: 0;
    transition: color 0.2s;
    outline: none;
    display: inline-block;
    margin-top: 1rem;
}
.timeline-toggle:hover, .timeline-toggle:focus {
    color: var(--accent-color);
    text-decoration: underline;
}
.timeline-list[hidden] {
    display: none !important;
}

/* === Skills & Tools Section === */
.skills-section {
    padding: 80px 0 60px 0;
    background: var(--bg-color);
    position: relative;
    z-index: 2;
}
.skills-section .section-title {
    display: flex;
    align-items: center;
    gap: 1rem;
    font-size: 2.4rem;
    margin-bottom: 2.5rem;
    justify-content: center;
}
.skills-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2.2rem;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}
.skill-card {
    padding: 2.2rem 1.5rem 1.7rem 1.5rem;
    min-height: 220px;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    background: rgba(255,255,255,0.18);
    box-shadow: 0 8px 32px 0 rgba(31, 38, 135, 0.10);
    border-radius: 18px;
    border: 1.5px solid rgba(255,255,255,0.22);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    transition: box-shadow 0.3s, transform 0.3s;
    margin-bottom: 0.5rem;
}
.skill-card:hover {
    box-shadow: 0 16px 48px 0 rgba(31, 38, 135, 0.18);
    transform: translateY(-6px) scale(1.025);
}
.skill-header {
    display: flex;
    align-items: center;
    gap: 0.7rem;
    margin-bottom: 1.1rem;
    font-size: 1.25rem;
    color: var(--primary-color);
    font-weight: 700;
}
.skill-header i {
    font-size: 1.5rem;
    color: var(--accent-color);
}
.skill-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 0.2rem;
}
.skill-bars {
    width: 100%;
    margin-top: 0.2rem;
}
.skill-bar {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 0.7rem;
    font-size: 1rem;
    font-weight: 600;
}
.skill-bar span {
    min-width: 90px;
    color: var(--primary-color);
    font-size: 1rem;
}
.bar {
    flex: 1;
    height: 12px;
    background: #ececec;
    border-radius: 8px;
    overflow: hidden;
    position: relative;
}
.progress {
    height: 100%;
    background: linear-gradient(90deg, var(--accent-color), var(--primary-color));
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(108, 92, 231, 0.10);
    transition: width 1.2s cubic-bezier(.25,.8,.25,1);
    min-width: 8%;
}
.focus-list {
    list-style: none;
    padding: 0;
    margin: 0.5rem 0 0 0;
}
.focus-list li {
    display: flex;
    align-items: center;
    gap: 0.7rem;
    margin-bottom: 0.6rem;
    font-size: 1rem;
    color: var(--text-color);
}
.focus-list li i {
    color: var(--accent-color);
    font-size: 1.1rem;
}
@media (max-width: 1100px) {
    .skills-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}
@media (max-width: 700px) {
    .skills-grid {
        grid-template-columns: 1fr;
        gap: 1.2rem;
        padding: 0 0.5rem;
    }
    .skills-section {
        padding: 50px 0 30px 0;
    }
    .skill-card {
        padding: 1.3rem 1rem 1.1rem 1rem;
    }
    .skills-section .section-title {
        font-size: 1.5rem;
    }
}

/* === Testimonial blockquote: black text in dark mode === */
.dark-mode .testimonial-card blockquote {
    color: var(--text-color);
}

/* === Timeline details: proper text in dark mode === */
.dark-mode .timeline-list {
    color: var(--text-color);
}

.dark-mode .timeline-list li {
    color: var(--text-color);
}

/* === Section titles: match color with .reveal-text (accent/primary color) === */
.section-title {
    color: var(--primary-color) !important;
}

/* === Project Modal: proper text in dark mode === */
.dark-mode .modal-content {
    color: var(--text-color);
    background: var(--bg-color);
}
.dark-mode .modal-content h2,
.dark-mode .modal-content p,
.dark-mode .modal-content a {
    color: var(--text-color);
}

/* ======================
   Contact Social Links
   ====================== */
.contact-divider {
    display: flex;
    align-items: center;
    text-align: center;
    margin: 2.5rem 0;
    color: var(--text-color);
    opacity: 0.8;
    font-size: 1rem;
    font-weight: 500;
    letter-spacing: 0.5px;
}

.contact-divider::before,
.contact-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--border-color, rgba(0,0,0,0.1)));
}

.contact-divider::after {
    background: linear-gradient(90deg, var(--border-color, rgba(0,0,0,0.1)), transparent);
}

.contact-divider span {
    padding: 0 1.5rem;
    position: relative;
    top: 1px;
}

.contact-social {
    display: flex;
    justify-content: center;
    gap: 1.8rem;
    margin: 2rem 0 1rem;
    flex-wrap: wrap;
}

.contact-social .social-link {
    color: var(--text-color);
    font-size: 1.2rem;
    transition: var(--transition);
    opacity: 0.9;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 12px 16px;
    border-radius: 8px;
    background: var(--glass-bg);
    backdrop-filter: var(--glass-blur);
    border: 1px solid var(--glass-border);
    box-shadow: var(--shadow-light);
    text-decoration: none;
    font-weight: 500;
}

.social-link:hover,
.social-link:focus {
    color: var(--accent-color);
    opacity: 1;
    transform: translateY(-2px);
    box-shadow: var(--shadow-medium);
    border-color: var(--accent-color);
}

.social-link:focus {
    outline: 2px solid var(--accent-color);
    outline-offset: 2px;
}

.social-text {
    font-size: 0.9rem;
    font-weight: 500;
}

/* Dark mode adjustments for contact section */
.dark-mode .contact-social .social-link,
.dark-mode .contact-social .social-link i {
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.1);
    color: var(--text-color);
}

/* Keep contact divider text color consistent in dark mode */
.dark-mode .contact-divider,
.dark-mode .contact-divider span {
    color: var(--text-color);
}

.dark-mode .contact-divider::before,
.dark-mode .contact-divider::after {
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2));
}

.dark-mode .contact-divider::after {
    background: linear-gradient(90deg, rgba(255, 255, 255, 0.2), transparent);
}

/* Ensure social icons are visible */
.dark-mode .contact-social .social-link i {
    color: var(--text-color);
}

.dark-mode .contact-social .social-link:hover {
    background: var(--primary-color);
    color: #ffffff;
}

.dark-mode .contact-social .social-link:hover i {
    color: #ffffff;
}


/* Mobile-first responsive optimizations */
@media (max-width: 768px) {
    :root {
        --section-padding: 60px 0;
        --glass-blur: blur(8px);
    }
    
    .hero-2025 {
        padding: 160px 15px 120px;
        min-height: 100vh;
    }
    
    .hero-content {
        margin-top: 0;
        gap: 1.5rem;
        height: auto;
        justify-content: center;
    }
    
    .profile-image {
        width: 220px;
        height: 220px;
    }
    
    .hero-headline-2025 {
        font-size: clamp(2rem, 7vw, 2.6rem);
    }
    
    /* Disable expensive effects on mobile */
    .tilt-card {
        transform: none !important;
    }
    
    .hero-pattern {
        opacity: 0.3;
        animation: none;
    }
    
    .textGlow {
        animation: none;
    }
}

/* Extra small screens */
@media (max-width: 480px) {
    .hero-2025 {
        padding: 180px 10px 140px;
    }
    
    .hero-content {
        gap: 1rem;
    }
    
    .profile-image {
        width: 200px;
        height: 200px;
    }
    
    .hero-headline-2025 {
        font-size: clamp(1.8rem, 6vw, 2.2rem);
    }
    
    .subtitle {
        font-size: 0.9rem;
        padding: 0 1rem;
    }
    
    .cert-container {
        padding: 0 0.5rem;
        max-width: 320px;
    }
    
    .cert-card {
        width: 260px;
        height: 300px;
    }
    
    .certifications h3 {
        font-size: 1.8rem;
        margin-bottom: 1.5rem;
    }
    
    .hero-stats {
        gap: 0.8rem;
        margin: 1rem 0;
    }
    
    .stat-item {
        min-width: 80px;
        max-width: 100px;
    }
    
    .stat-number {
        font-size: 0.85rem;
    }
    
    .stat-label {
        font-size: 0.7rem;
    }
    
    .hero-actions {
        margin-top: 1rem;
    }
    
    .cta-button, .submit-btn, .download-cv {
        max-width: 280px;
        padding: 12px 24px;
        font-size: 0.9rem;
    }
    
    /* Hero Section */
    .hero {
        align-items: flex-start;
        padding-top: 140px;
        min-height: 100vh;
    }
    
    .hero-content {
        flex-direction: column;
        align-items: center;
        text-align: center;
        width: 95%;
        margin: 0 auto;
        padding-top: 2rem;
    }
    
    .hero-headline-2025 {
        font-size: 2.8rem !important;
        line-height: 1.2;
        margin-bottom: 1.5rem;
    }
    
    .headline-gradient {
        -webkit-background-clip: text;
        -webkit-text-fill-color: transparent;
        background-clip: text;
    }
    
    .subtitle {
        font-size: 1.2rem;
        margin-bottom: 2rem;
    }
    
    .profile-container {
        margin-top: 1rem;
    }
    
    .cta-button, .submit-btn, .download-cv {
        font-size: 1rem;
        min-height: 3rem;
        padding: 12px 20px;
    }
    
    /* Contact Section */
    .contact-social {
        gap: 1.2rem;
    }
    
    .contact-social .social-link {
        width: 44px;
        height: 44px;
        font-size: 1.4rem;
    }
    
    .contact-divider {
        margin: 2rem 0;
        font-size: 0.9rem;
    }
    
    /* Modal */
    /* Certificate image styling handled above */

    .close {
        top: 5px;
        right: 10px;
        font-size: 24px;
        width: 35px;
        height: 35px;
    }
}
