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

:root {
    --primary-color: #667eea;
    --secondary-color: #764ba2;
    --accent-color: #f093fb;
    --text-primary: #2d3748;
    --text-secondary: #4a5568;
    --text-light: #a0aec0;
    --bg-primary: #ffffff;
    --bg-secondary: #f7fafc;
    --bg-dark: #1a202c;
    --gradient: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    --shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
    --shadow-hover: 0 20px 40px rgba(0, 0, 0, 0.15);
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    line-height: 1.6;
    color: var(--text-primary);
    overflow-x: hidden;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: 80px;
}

/* Navigation */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    z-index: 1000;
    padding: 1rem 0;
    transition: all 0.3s ease;
}

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

.logo {
    font-size: 1.5rem;
    font-weight: 700;
    background: var(--gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

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

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

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

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--gradient);
    transition: width 0.3s ease;
}

.nav-links a:hover::after,
.nav-links a.active::after {
    width: 100%;
}

/*
.portfolio-link {
    background: rgba(102, 126, 234, 0.1) !important;
    padding: 0.5rem 1rem !important;
    border-radius: 20px !important;
    font-weight: 600 !important;
}
*/

.mobile-menu-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--text-primary);
}

/* Hero Section */
.hero {
    min-height: 100vh;
    background: var(--gradient);
    display: flex;
    align-items: center;
    position: relative;
    overflow: hidden;
    padding-top: 80px;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grid" width="10" height="10" patternUnits="userSpaceOnUse"><path d="M 10 0 L 0 0 0 10" fill="none" stroke="rgba(255,255,255,0.1)" stroke-width="0.5"/></pattern></defs><rect width="100" height="100" fill="url(%23grid)"/></svg>');
    animation: float 20s ease-in-out infinite;
}

.hero-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    color: white;
    z-index: 2;
    position: relative;
    text-align: center;
}

.hero h1 {
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
    animation: fadeInUp 1s ease-out;
}

.hero p {
    font-size: 1.25rem;
    margin-bottom: 2rem;
    opacity: 0.9;
    animation: fadeInUp 1s ease-out 0.2s both;
}

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

.cta-button {
    display: inline-block;
    padding: 1rem 2rem;
    background: rgba(255, 255, 255, 0.2);
    color: white;
    text-decoration: none;
    border-radius: 50px;
    font-weight: 600;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
    border: 2px solid rgba(255, 255, 255, 0.3);
    animation: fadeInUp 1s ease-out 0.4s both;
}

.cta-button:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: translateY(-2px);
}

@keyframes float {

    0%,
    100% {
        transform: translateY(0px);
    }

    50% {
        transform: translateY(-20px);
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Section Styles */
section {
    padding: 5rem 0;
    scroll-margin-top: 80px;
}

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

.section-title {
    text-align: center;
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 3rem;
    position: relative;
}

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

/* About Section */
.about {
    background: var(--bg-secondary);
}

.about-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: flex-start;
    /* Change from 'center' to 'flex-start' */
}

/* Ensure no top padding or top margin */
.about-text {
    font-size: 1.1rem;
    line-height: 1.8;
    color: var(--text-secondary);
    padding-top: 0;
    margin-top: 0;
}

.about-text p {
    margin-bottom: 1.5rem;
}

/* Ensure first paragraph has no top margin */
.about-text p:first-child {
    margin-top: 0;
}

/* Remove top margin 2rem to 0 to align with text */
.skills {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    margin-top: 0;
}

.skill-card {
    background: white;
    padding: 1.5rem;
    border-radius: 10px;
    box-shadow: var(--shadow);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    text-align: center;
}

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

.skill-card .icon {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

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

.skill-card p {
    font-size: 0.9rem;
    color: var(--text-light);
}

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

.timeline::before {
    content: '';
    position: absolute;
    left: 50%;
    top: 0;
    bottom: 0;
    width: 2px;
    background: var(--gradient);
    transform: translateX(-50%);
}

.timeline-item {
    margin: 2rem 0;
    position: relative;
}

.timeline-content {
    background: white;
    padding: 2rem;
    border-radius: 10px;
    box-shadow: var(--shadow);
    width: calc(50% - 30px);
    position: relative;
    transition: transform 0.3s ease;
}

.timeline-content:hover {
    transform: scale(1.02);
}

.timeline-item:nth-child(odd) .timeline-content {
    margin-left: auto;
}

.timeline-item:nth-child(even) .timeline-content {
    margin-right: auto;
}

.timeline-dot {
    position: absolute;
    left: 50%;
    top: 2rem;
    width: 20px;
    height: 20px;
    background: var(--gradient);
    border-radius: 50%;
    transform: translateX(-50%);
    z-index: 1;
    border: 4px solid white;
}

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

.timeline-title {
    font-size: 1.3rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.timeline-company {
    color: var(--text-light);
    margin-bottom: 1rem;
    font-style: italic;
}

/* Blog Section */
.blog-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    margin-top: 2rem;
    align-items: stretch;
}

.blog-card {
    background: white;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.blog-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-hover);
}

.blog-image {
    height: 200px;
    background: var(--gradient);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 3rem;
    flex-shrink: 0;
}

.blog-content {
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
    height: 100%;
}

.blog-title {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
    min-height: 3.0rem;
    height: 3.0rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    line-height: 1.2;
}

.blog-excerpt {
    color: var(--text-secondary);
    font-size: 0.9rem;
    line-height: 1.6;
    flex-grow: 1;
    margin-bottom: 1rem;
}

.blog-excerpt.clamp {
    display: -webkit-box;
    -webkit-line-clamp: 4;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
}

.blog-excerpt.expanded {
    -webkit-line-clamp: unset;
    overflow: visible;
}

.toggle-excerpt {
    margin-top: 1rem;
    background: none;
    border: 0;
    padding: 0;
    color: var(--primary-color);
    text-decoration: underline;
    cursor: pointer;
    align-self: flex-start;
    font-size: 0.85rem;
    font-weight: 500;
    flex-shrink: 0;
}

.toggle-excerpt:hover {
    color: var(--secondary-color);
}

.blog-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: auto;
    padding-top: 1rem;
    color: var(--text-light);
    font-size: 0.8rem;
    border-top: 1px solid #f0f0f0;
    flex-shrink: 0;
}

.blog-content a:not(.toggle-excerpt) {
    color: inherit;
    text-decoration: underline;
    text-decoration-color: currentColor;
}

.blog-content a:not(.toggle-excerpt):hover {
    color: var(--primary-color);
    text-decoration-color: var(--primary-color);
}

.read-more {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
}

.read-more:hover {
    color: var(--secondary-color);
}

/* Contact Section */
.contact {
    background: var(--bg-dark);
    color: white;
}

.contact-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
}

.contact-info h3 {
    margin-bottom: 1rem;
    font-size: 1.5rem;
}

.contact-info p {
    margin-bottom: 2rem;
    opacity: 0.9;
}

/* Reduce space between contact items (was 1rem) */
.contact-item {
    display: flex;
    align-items: center;
    margin-bottom: 0.5rem;
    gap: 1rem;
}

.contact-item .icon {
    font-size: 1.2rem;
    width: 30px;
}

.contact-form {
    background: rgba(255, 255, 255, 0.1);
    padding: 2rem;
    border-radius: 15px;
    backdrop-filter: blur(10px);
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 0.75rem;
    border: none;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.1);
    color: white;
    font-size: 1rem;
    transition: background 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    background: rgba(255, 255, 255, 0.2);
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: rgba(255, 255, 255, 0.7);
}

.submit-btn {
    background: var(--gradient);
    color: white;
    padding: 0.75rem 2rem;
    border: none;
    border-radius: 25px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.3s ease;
}

.submit-btn:hover {
    transform: translateY(-2px);
}

/* Footer */
.footer {
    background: #0d1117;
    color: white;
    text-align: center;
    padding: 2rem 0;
}

.footer p {
    margin-bottom: 1rem;
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-top: 1rem;
}

.footer-links a {
    color: var(--text-light);
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-links a:hover {
    color: white;
}

/* Scroll animations */
.fade-in {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.6s ease;
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Back to top button */
.back-to-top {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    background: var(--gradient);
    color: white;
    width: 50px;
    height: 50px;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    font-size: 1.2rem;
    transition: all 0.3s ease;
    opacity: 0;
    visibility: hidden;
    z-index: 1000;
}

.back-to-top.visible {
    opacity: 1;
    visibility: visible;
}

.back-to-top:hover {
    transform: translateY(-3px);
}

/* Loading indicator */
.loading {
    text-align: center;
    padding: 4rem 2rem;
    font-size: 1.2rem;
    color: var(--text-light);
    background: var(--bg-secondary);
    min-height: 50vh;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    margin: 2rem;
}

/* Smooth scrolling */
.smooth-scroll-page main {
    padding-top: 0 !important;
}

.smooth-scroll-page #all-sections {
    padding: 0 !important;
    max-width: none !important;
    margin: 0 !important;
    width: 100% !important;
}

.smooth-scroll-page section {
    min-height: 100vh !important;
    padding: 0 !important;
    margin: 0 !important;
    width: 100% !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    scroll-margin-top: 80px !important;
}

.smooth-scroll-page section .container,
.smooth-scroll-page section .hero-content {
    max-width: 1200px !important;
    width: 100% !important;
    margin: 0 auto !important;
    padding: 2rem !important;
}

.smooth-scroll-page section .hero-content {
    text-align: center !important;
    position: relative !important;
    z-index: 2 !important;
}

.smooth-scroll-page section#home {
    background: var(--gradient) !important;
    color: white !important;
    position: relative !important;
    overflow: hidden !important;
}

.smooth-scroll-page section#home::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grid" width="10" height="10" patternUnits="userSpaceOnUse"><path d="M 10 0 L 0 0 0 10" fill="none" stroke="rgba(255,255,255,0.1)" stroke-width="0.5"/></pattern></defs><rect width="100" height="100" fill="url(%23grid)"/></svg>');
    animation: float 20s ease-in-out infinite;
    z-index: 1;
}

/* Added animation here */
.smooth-scroll-page section#home h1 {
    font-size: 3.5rem !important;
    font-weight: 700 !important;
    margin-bottom: 1rem !important;
    line-height: 1.1 !important;
    animation: none !important;
    opacity: 1 !important;
    transform: none !important;
}

/* Change position font here */
.smooth-scroll-page section#home p {
    font-size: 1.5rem !important;
    margin-bottom: 2rem !important;
    opacity: 0.9 !important;
}

.smooth-scroll-page section#about {
    background: var(--bg-secondary) !important;
}

.smooth-scroll-page section#experience {
    background: var(--bg-primary) !important;
}

.smooth-scroll-page section#blog {
    background: var(--bg-secondary) !important;
}

.smooth-scroll-page section#contact {
    background: var(--bg-dark) !important;
    color: white !important;
}

.smooth-scroll-page section#contact .section-title,
.smooth-scroll-page section#contact h2,
.smooth-scroll-page section#contact h3 {
    color: white !important;
}

/* Mobile Responsiveness */
@media (max-width: 768px) {
    .nav-links {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background: rgba(255, 255, 255, 0.98);
        flex-direction: column;
        padding: 1rem;
        box-shadow: var(--shadow);
    }

    .nav-links.active {
        display: flex;
    }

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

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

    .hero p {
        font-size: 1.1rem;
    }

    .cta-buttons {
        flex-direction: column;
        align-items: center;
    }

    .about-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .timeline::before {
        left: 20px;
    }

    .timeline-content {
        width: calc(100% - 60px);
        margin-left: 40px !important;
    }

    .timeline-dot {
        left: 20px;
        transform: none;
    }

    .contact-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .section-title {
        font-size: 2rem;
    }

    .skills {
        grid-template-columns: 1fr;
    }

    .blog-grid {
        grid-template-columns: 1fr;
    }

    .blog-title {
        min-height: auto;
        -webkit-line-clamp: unset;
    }

    .smooth-scroll-page section#home h1 {
        font-size: 2.5rem !important;
    }

    .smooth-scroll-page section#home p {
        font-size: 1.3rem !important;
    }

    .smooth-scroll-page section .container,
    .smooth-scroll-page section .hero-content {
        padding: 1rem !important;
    }
}

/* Two column on tablets only */
@media (min-width: 769px) and (max-width: 992px) {
    .blog-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

.privacy-note {
    font-size: 0.9rem;
    opacity: 0.85;
    margin-top: 0.5rem;
}

.consent {
    display: flex;
    gap: .5rem;
    align-items: flex-start;
    font-size: 0.9rem;
    margin: .5rem 0;
}