html {
    scroll-behavior: smooth;
}

body { -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.8;
    margin: 0;
    padding: 0;
    background: #f9f9f9;
    color: #333;
}

header {
    background: #fff;
    color: #333;
    padding: 2rem 0;
    text-align: center;
    border-bottom: 1px solid #eee;
}

header h1 {
    margin: 0;
    font-size: 2.5em;
}

header p {
    margin: 0;
    color: #666;
}

main {
    display: block;
    margin: 0 auto;
    padding: 20px;
    max-width: 1200px; /* Increased max-width for grid */
}

section {
    scroll-margin-top: 80px; /* Adjust scroll position for anchor links */
    background: #fff;
    margin-bottom: 30px;
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 2px 15px rgba(0,0,0,0.05);
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.5s ease-out, transform 0.5s ease-out;
}

.profile-body {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.profile-pic {
    width: 150px;
    height: 150px;
    border-radius: 50%;
    object-fit: cover;
    border: 5px solid #fff;
    box-shadow: 0 0 10px rgba(0,0,0,0.1);
    flex-shrink: 0;
    margin-left: 30px;
}

h2 {
    font-size: 1.8em;
    border-bottom: 3px solid #333;
    padding-bottom: 15px;
    margin-bottom: 30px;
}

h3 {
    font-size: 1.4em;
    margin-bottom: 10px;
    color: #333;
}

.experience-item {
    margin-bottom: 30px;
}

.experience-item:last-child {
    margin-bottom: 0;
}

/* Separator lines for items */
.experience-item:not(:last-child),
.education-item:not(:last-child) {
    border-bottom: 1px solid #ccc;
    padding-bottom: 30px;
}

strong {
    font-weight: 600;
}

ul {
    padding-left: 20px;
    list-style-type: disc;
}

footer {
    text-align: center;
    padding: 30px;
    margin-top: 30px;
    font-size: 0.9em;
    color: #777;
}

a {
    color: #007BFF;
    text-decoration: none;
    transition: color 0.3s ease;
}

a:hover {
    color: #0056b3;
    text-decoration: underline;
}


/* Animation for sections */
.section-visible {
    opacity: 1;
    transform: translateY(0);
}

/* Scroll Navigation */
#scroll-nav {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background: rgba(255, 255, 255, 0.9);
    border-radius: 10px;
    padding: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.15);
    z-index: 1000;
}

#scroll-nav a {
    display: block;
    padding: 8px 12px;
    color: #333;
    text-decoration: none;
    font-size: 14px;
    border-radius: 5px;
    transition: background-color 0.3s ease;
}

#scroll-nav a:hover {
    background-color: #eee;
}

#scroll-nav a.active {
    background-color: #007BFF;
    color: #fff;
}

.skills-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 30px;
}

/* --- Projects Section Grid --- */
#projects {
    background: none;
    box-shadow: none;
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 30px;
}

.project-card {
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
    overflow: hidden;
    transition: transform 0.3s, box-shadow 0.3s;
    display: flex;
    flex-direction: column;
}

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

.project-card a.card-link-wrapper {
    text-decoration: none;
    color: inherit;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.project-card-img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    border-bottom: 1px solid #eee;
}

.project-card-content {
    padding: 20px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.project-card-content h3 {
    margin-top: 0;
    font-size: 1.5em;
    color: #333;
}

.project-card-content p {
    font-size: 1em;
    line-height: 1.6;
    color: #555;
    flex-grow: 1;
}

.project-card-tags {
    margin-top: 15px;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.project-card-tags .tech-tag {
    background-color: #e9ecef;
    color: #495057;
    padding: 5px 10px;
    border-radius: 15px;
    font-size: 0.85em;
}


@media (max-width: 768px) {
    .skills-grid {
        grid-template-columns: 1fr;
    }
    main {
        padding: 10px;
    }
}
