:root {
    --primary: #6366f1;
    --primary-dark: #4f46e5;
    --secondary: #ec4899;
    --accent: #06b6d4;
    --success: #10b981;
    --warning: #f59e0b;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    background-attachment: fixed;
    min-height: 100vh;
}

html {
    scroll-behavior: smooth;
}

/* Particles across whole page */
body::after {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grain" width="100" height="100" patternUnits="userSpaceOnUse"><circle cx="25" cy="25" r="1" fill="white" opacity="0.1"/><circle cx="75" cy="75" r="1" fill="white" opacity="0.1"/><circle cx="50" cy="10" r="1" fill="white" opacity="0.1"/><circle cx="10" cy="90" r="1" fill="white" opacity="0.1"/></pattern></defs><rect width="100" height="100" fill="url(%23grain)"/></svg>');
    animation: float 20s infinite linear;
    opacity: 0.1;
    pointer-events: none;
    z-index: 0;
}

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

/* Hero Section */
.hero-section {
    height: 100vh;
    background: transparent;
    display: flex;
    align-items: center;
    position: relative;
    overflow: hidden;
}

.hero-content {
    z-index: 2;
    position: relative;
}

.btn-custom {
    padding: 12px 30px;
    border-radius: 50px;
    font-weight: 600;
    transition: all 0.3s ease;
    border: none;
}

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

.btn-primary-custom:hover {
    background: var(--primary);
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(236, 72, 153, 0.3);
}

/* Section backgrounds with white containers */
.section-padding {
    padding: 5rem 0;
    background: transparent;
}

.section-padding.bg-light {
    background: transparent !important;
}

.section-padding .container {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    padding: 3rem 2rem;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.3);
}

/* Profile Image */
.profile-img-container {
    width: 300px;
    height: 300px;
    border-radius: 50%;
    overflow: hidden;
    background: linear-gradient(45deg, var(--primary), var(--secondary));
    padding: 4px;
    transition: transform 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto;
}

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

.profile-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
}

/* Skill Cards */
.skill-card {
    background: white;
    border-radius: 15px;
    padding: 2rem;
    box-shadow: 0 5px 25px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
    height: 100%;
    border: none;
}

.skill-card:hover {
    transform: translateY(-5px);
}

.skill-icon {
    width: 60px;
    height: 60px;
    border-radius: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.8rem;
    margin-bottom: 1rem;
}

.skill-icon.ml { background: linear-gradient(45deg, var(--primary), var(--accent)); }
.skill-icon.web { background: linear-gradient(45deg, var(--secondary), var(--warning)); }
.skill-icon.tools { background: linear-gradient(45deg, var(--success), var(--accent)); }

.skill-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    justify-content: flex-start;
}

.skill-tag {
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    color: #6c757d;
    padding: 0.4rem 1rem;
    border-radius: 20px;
    font-size: 0.9rem;
    white-space: nowrap;
}

/* OLD Project Cards (Legacy - Keep for compatibility) */
.project-card {
    background: white;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 5px 25px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    height: 100%;
    border: none;
}

.project-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.2);
}

.project-image {
    height: 150px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 3rem;
}

.project-image.ml { background: linear-gradient(45deg, var(--primary), var(--accent)); }
.project-image.web { background: linear-gradient(45deg, var(--secondary), var(--warning)); }
.project-image.data { background: linear-gradient(45deg, var(--success), var(--primary)); }

.tech-tag {
    background: var(--primary);
    color: white;
    padding: 0.3rem 0.8rem;
    border-radius: 15px;
    font-size: 0.8rem;
    margin: 0.2rem;
}

/* NEW Improved Project Cards - Jason-inspired styling */
.project-card-new {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.08);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    height: 100%;
    border: 1px solid rgba(0, 0, 0, 0.05);
    position: relative;
}

.project-card-new:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 40px rgba(0, 0, 0, 0.12);
}

.project-card-new.coming-soon {
    opacity: 0.85;
    border: 2px dashed rgba(99, 102, 241, 0.2);
}

/* Project Image */
.project-image-wrapper {
    position: relative;
    overflow: hidden;
    height: 240px;
}

.project-image-new {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.project-card-new:hover .project-image-new {
    transform: scale(1.05);
}

/* Category Labels */
.project-category {
    position: absolute;
    top: 16px;
    left: 16px;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    color: white;
    backdrop-filter: blur(10px);
    z-index: 2;
}

.project-category.ml {
    background: linear-gradient(135deg, var(--primary) 0%, var(--accent) 100%);
}

.project-category.web {
    background: linear-gradient(135deg, var(--secondary) 0%, var(--warning) 100%);
}

.project-category.iot {
    background: linear-gradient(135deg, var(--success) 0%, var(--accent) 100%);
}

.project-category.algo {
    background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
}

.project-category.future {
    background: linear-gradient(135deg, #6b7280 0%, #9ca3af 100%);
}

/* External Link */
.project-external-link {
    position: absolute;
    top: 16px;
    right: 16px;
    width: 36px;
    height: 36px;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary);
    text-decoration: none;
    font-size: 14px;
    opacity: 0;
    transform: scale(0.8);
    transition: all 0.3s ease;
    z-index: 3;
}

.project-card-new:hover .project-external-link {
    opacity: 1;
    transform: scale(1);
}

.project-external-link:hover {
    background: var(--primary);
    color: white;
    transform: scale(1.1);
}

/* Project Content */
.project-content-new {
    padding: 32px 28px 28px;
}

.project-title-new {
    font-size: 1.5rem;
    font-weight: 700;
    color: #1f2937;
    margin-bottom: 16px;
    line-height: 1.3;
    letter-spacing: -0.01em;
}

.project-description-new {
    font-size: 15px;
    line-height: 1.6;
    color: #6b7280;
    margin-bottom: 24px;
    font-weight: 400;
}

/* Tech Badges */
.project-tech-new {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 24px;
}

.tech-badge {
    background: #f3f4f6;
    color: #374151;
    padding: 6px 12px;
    border-radius: 16px;
    font-size: 12px;
    font-weight: 500;
    letter-spacing: 0.01em;
    border: 1px solid #e5e7eb;
    transition: all 0.2s ease;
}

.tech-badge:hover {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
    transform: translateY(-1px);
}

/* Project Link */
.project-link-new {
    color: var(--accent);
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
    letter-spacing: 0.01em;
    display: inline-flex;
    align-items: center;
    transition: all 0.2s ease;
    position: relative;
}

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

.project-link-new:hover {
    color: var(--primary);
    text-decoration: none;
}

.project-link-new:hover::after {
    width: 100%;
    background: var(--primary);
}

/* Grid spacing adjustment to match Jason's layout */
.row.g-5 {
    --bs-gutter-x: 2rem;
    --bs-gutter-y: 2.5rem;
}

/* Section Titles */
.section-title {
    position: relative;
    display: inline-block;
}

.section-title::after {
    content: '';
    position: absolute;
    width: 80px;
    height: 4px;
    background: linear-gradient(45deg, var(--primary), var(--secondary));
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    border-radius: 2px;
}

/* Footer */
footer {
    background: rgba(33, 37, 41, 0.95) !important;
    backdrop-filter: blur(10px);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    margin-top: 2rem;
}

footer .container {
    background: transparent !important;
    box-shadow: none !important;
    border: none !important;
    padding: 1rem !important;
}

/* All content positioned above particles */
.hero-section,
.section-padding,
.sidenav,
footer {
    position: relative;
    z-index: 1;
}

#particles-js {
    position: fixed;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    z-index: 0;
}

.visually-hidden-focusable {
  position: absolute;
  left: -9999px;
  top: auto;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.visually-hidden-focusable:focus {
  position: static;
  width: auto;
  height: auto;
  margin: 1rem;
  padding: 0.5rem;
  background: #000;
  color: #fff;
  z-index: 1000;
}

/* Sidenav styles */
.sidenav {
    position: fixed;
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(15px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 25px;
    padding: 20px 10px;
    z-index: 1000;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
    width: 60px;
}

.hamburger {
    display: none;
}

.nav-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
    width: 100%;
}

.nav-items {
    display: flex;
    flex-direction: column;
    gap: 15px;
    align-items: center;
}

.nav-item {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    text-decoration: none;
    font-size: 18px;
    transition: all 0.3s ease;
    position: relative;
}

.nav-item:hover {
    background: var(--primary);
    color: white;
    transform: scale(1.1);
}

.nav-item.active {
    background: var(--primary);
    color: white;
}

.social-links {
    display: flex;
    flex-direction: column;
    gap: 10px;
    align-items: center;
    padding-top: 15px;
    border-top: 1px solid rgba(255, 255, 255, 0.2);
}

.social-item {
    width: 35px;
    height: 35px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    text-decoration: none;
    font-size: 16px;
    transition: all 0.3s ease;
}

.social-item:hover {
    color: white;
    transform: scale(1.1);
}

.social-item:nth-child(1):hover {
    background: #333;
}

.social-item:nth-child(2):hover {
    background: #0077b5;
}

.social-item:nth-child(3):hover {
    background: var(--secondary);
}

/* Responsive adjustments */
@media (max-width: 992px) {
    .project-content-new {
        padding: 24px 20px 20px;
    }
    
    .project-title-new {
        font-size: 1.3rem;
        margin-bottom: 12px;
    }
    
    .project-description-new {
        font-size: 14px;
        margin-bottom: 20px;
    }
    
    .project-image-wrapper {
        height: 200px;
    }
}

@media (max-width: 768px) {
    .hero-section h1 {
        font-size: 2.5rem;
    }
    
    .profile-img-container {
        width: 200px;
        height: 200px;
        margin: 0 auto 2rem auto;
    }
    
    .section-padding .container {
        padding: 2rem 1.5rem;
    }
    
    .project-content-new {
        padding: 20px 16px 16px;
    }
    
    .project-title-new {
        font-size: 1.2rem;
        margin-bottom: 10px;
    }
    
    .project-description-new {
        font-size: 13px;
        margin-bottom: 16px;
        line-height: 1.5;
    }
    
    .project-tech-new {
        gap: 6px;
        margin-bottom: 20px;
    }
    
    .tech-badge {
        padding: 4px 8px;
        font-size: 11px;
    }
    
    .project-image-wrapper {
        height: 180px;
    }
    
    .row.g-5 {
        --bs-gutter-x: 1rem;
        --bs-gutter-y: 2rem;
    }
    
    /* Mobile sidenav */
    .sidenav {
        top: 20px;
        right: 20px;
        width: 50px;
        height: 50px;
        padding: 10px;
        transform: none;
        overflow: hidden;
        transition: all 0.3s ease;
        background: var(--primary);
        border: 1px solid rgba(255, 255, 255, 0.3);
    }
    
    .sidenav.open {
        width: 200px;
        height: auto;
        padding: 20px;
        border-radius: 15px;
        background: linear-gradient(135deg, var(--primary) 0%, rgb(95, 24, 121) 100%);
        box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    }
    
    .hamburger {
        display: flex;
        width: 30px;
        height: 30px;
        align-items: center;
        justify-content: center;
        color: white;
        cursor: pointer;
        font-size: 18px;
        transition: all 0.3s ease;
    }
    
    .hamburger:hover {
        transform: scale(1.1);
    }
    
    .nav-content {
        opacity: 0;
        visibility: hidden;
        transform: translateY(-20px);
        transition: all 0.3s ease;
        margin-top: 15px;
    }
    
    .sidenav.open .nav-content {
        opacity: 1;
        visibility: visible;
        transform: translateY(0);
    }
    
    .sidenav.open .nav-items {
        flex-direction: row;
        flex-wrap: wrap;
        justify-content: center;
        gap: 10px;
        margin-bottom: 15px;
    }
    
    .sidenav.open .social-links {
        flex-direction: row;
        justify-content: center;
        gap: 10px;
        padding-top: 15px;
        border-top: 1px solid rgba(255, 255, 255, 0.3);
    }
    
    .nav-item {
        width: 35px;
        height: 35px;
        font-size: 16px;
        background: rgba(255, 255, 255, 0.2);
        color: white;
        border: 1px solid rgba(255, 255, 255, 0.3);
    }
    
    .nav-item:hover {
        background: rgba(255, 255, 255, 0.3);
        color: white;
        transform: scale(1.1);
    }
    
    .social-item {
        width: 30px;
        height: 30px;
        font-size: 14px;
        background: rgba(255, 255, 255, 0.2);
        color: white;
        border: 1px solid rgba(255, 255, 255, 0.3);
    }
    
    .social-item:hover {
        color: white;
        transform: scale(1.1);
    }
    
    .social-item:nth-child(1):hover {
        background: rgba(51, 51, 51, 0.8);
    }
    
    .social-item:nth-child(2):hover {
        background: rgba(0, 119, 181, 0.8);
    }
    
    .social-item:nth-child(3):hover {
        background: rgba(128, 41, 144, 0.8);
    }
}

@media (max-width: 576px) {
    .profile-img-container {
        width: 180px;
        height: 180px;
    }
}