:root {
    --primary-gradient: linear-gradient(135deg, #0f172a 0%, #1e3a5f 50%, #0ea5e9 100%);
    --accent-color: #0ea5e9;
    --accent-hover: #38bdf8;
    --dark-bg: #0f172a;
    --card-bg: #ffffff;
    --text-primary: #1e293b;
    --text-muted: #64748b;
}

body {
    font-family: 'Inter', 'Segoe UI', system-ui, -apple-system, sans-serif;
    line-height: 1.7;
    margin-top: 56px;
    color: var(--text-primary);
    background-color: #f8fafc;
}

/* Modern Navbar */
.navbar {
    backdrop-filter: blur(12px);
    background: rgba(15, 23, 42, 0.9) !important;
    border-bottom: 1px solid rgba(255,255,255,0.05);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.1);
}

.navbar-brand {
    font-weight: 700;
    letter-spacing: -0.5px;
}

.nav-link {
    font-weight: 500;
    transition: color 0.3s ease;
}

.nav-link:hover, .nav-link.active {
    color: var(--accent-color) !important;
}

/* Hero Section */
.hero-section {
    background: var(--primary-gradient);
    height: 100vh;
    position: relative;
    overflow: hidden;
    margin-top: -56px; /* Offset for navbar */
    padding-top: 56px;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(circle at 20% 80%, rgba(14, 165, 233, 0.15) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(56, 189, 248, 0.1) 0%, transparent 50%);
    pointer-events: none;
}

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

.hero-section h1 {
    font-weight: 800;
    letter-spacing: -2px;
    text-shadow: 0 4px 20px rgba(0,0,0,0.3);
    margin-bottom: 1rem;
}

.hero-section .lead {
    font-size: 1.5rem;
    font-weight: 300;
    min-height: 2.5rem;
    color: rgba(255,255,255,0.9);
}

.social-links a {
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    opacity: 0.8;
    display: inline-block;
}

.social-links a:hover {
    transform: scale(1.2) translateY(-3px);
    opacity: 1;
    color: var(--accent-color) !important;
}

/* Sections General */
section {
    scroll-margin-top: 56px;
    position: relative;
}

h2 {
    font-weight: 700;
    color: var(--dark-bg);
    position: relative;
    display: inline-block;
}

h2::after {
    content: '';
    display: block;
    width: 60px;
    height: 4px;
    background: var(--accent-color);
    margin: 10px auto 0;
    border-radius: 2px;
}

/* Cards Common */
.card, .expertise-card, .info-card {
    background: white;
    border-radius: 16px;
    border: none;
    box-shadow: 0 4px 20px rgba(0,0,0,0.04);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Expertise Cards */
.expertise-section {
    background: white;
    border-radius: 24px;
    padding: 3rem;
    box-shadow: 0 10px 40px rgba(0,0,0,0.03);
}

.expertise-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 30px rgba(14, 165, 233, 0.15);
}

.expertise-card i {
    color: var(--accent-color);
}

.expertise-card h5 {
    font-weight: 600;
    margin-bottom: 0.5rem;
}

/* Timeline */
.timeline {
    position: relative;
    max-width: 800px;
    margin: 0 auto;
}

.timeline::after {
    content: '';
    position: absolute;
    width: 4px;
    background-color: #e2e8f0;
    top: 0;
    bottom: 0;
    left: 50%;
    margin-left: -2px;
    border-radius: 2px;
}

.timeline-item {
    padding: 10px 40px;
    position: relative;
    background-color: inherit;
    width: 50%;
}

.timeline-item::after {
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    right: -10px;
    background-color: white;
    border: 4px solid var(--accent-color);
    top: 24px;
    border-radius: 50%;
    z-index: 1;
    transition: background-color 0.3s;
}

.timeline-item.left {
    left: 0;
}

.timeline-item.right {
    left: 50%;
}

.timeline-item.left::before {
    content: " ";
    height: 0;
    position: absolute;
    top: 26px;
    width: 0;
    z-index: 1;
    right: 30px;
    border: medium solid white;
    border-width: 10px 0 10px 10px;
    border-color: transparent transparent transparent white;
}

.timeline-item.right::before {
    content: " ";
    height: 0;
    position: absolute;
    top: 26px;
    width: 0;
    z-index: 1;
    left: 30px;
    border: medium solid white;
    border-width: 10px 10px 10px 0;
    border-color: transparent white transparent transparent;
}

.timeline-item.right::after {
    left: -10px;
}

.timeline-item .content {
    padding: 20px 25px;
    background-color: white;
    position: relative;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
    transition: transform 0.3s;
}

.timeline-item:hover .content {
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.08);
}

.timeline-item:hover::after {
    background-color: var(--accent-color);
}

.timeline .date {
    display: inline-block;
    padding: 4px 10px;
    background: #e0f2fe;
    color: var(--accent-color);
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

/* Projects */
.project-card {
    border: 1px solid rgba(0,0,0,0.05);
}

.project-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(14, 165, 233, 0.12);
}

.project-card.featured {
    border: 1px solid var(--accent-color);
    background: linear-gradient(135deg, #f0f9ff 0%, #ffffff 100%);
}

.tech-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 1rem;
}

.tech-tags .badge {
    font-weight: 500;
    padding: 0.5em 0.9em;
    border-radius: 20px;
    font-size: 0.75rem;
}

.badge.bg-primary {
    background: linear-gradient(135deg, #0ea5e9, #0284c7) !important;
}

.badge.bg-info {
    background: linear-gradient(135deg, #06b6d4, #0891b2) !important;
    color: white;
}

/* Patents & Info Cards */
.info-card h4 {
    border-bottom: 1px solid #f1f5f9;
    padding-bottom: 1rem;
}

.info-card h6 {
    color: var(--dark-bg);
}

/* Contact */
.btn-primary {
    background-color: var(--accent-color);
    border-color: var(--accent-color);
    transition: all 0.3s;
}

.btn-primary:hover {
    background-color: #0284c7;
    border-color: #0284c7;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(14, 165, 233, 0.3);
}

.btn-outline-dark:hover {
    background-color: var(--dark-bg);
    transform: translateY(-2px);
}

/* Responsive Timeline */
@media screen and (max-width: 768px) {
    .timeline::after {
        left: 31px;
    }
    
    .timeline-item {
        width: 100%;
        padding-left: 70px;
        padding-right: 25px;
    }
    
    .timeline-item::before {
        left: 60px;
        border: medium solid white;
        border-width: 10px 10px 10px 0;
        border-color: transparent white transparent transparent;
    }

    .timeline-item.left::after, .timeline-item.right::after {
        left: 21px;
    }
    
    .timeline-item.right {
        left: 0%;
    }

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