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

body {
    background-color: #0d1117;
    color: #c9d1d9;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji";
    margin: 0;
    line-height: 1.6;
}

header {
    background-color: rgba(13, 17, 23, 0.8);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid #30363d;
    padding: 1rem;
    position: sticky;
    top: 0;
    z-index: 10;
}

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

.logo {
    display: flex;
    align-items: center;
    color: #c9d1d9; /* Match nav links */
    text-decoration: none; /* Match nav links */
    font-weight: 600; /* Match nav links */
    padding: 0.5rem 1rem;
    border-radius: 5px;
    transition: all 0.3s ease;
    cursor: pointer;
}

.logo:hover {
    color: #ffffff; /* Match nav links hover */
    background-color: #58a6ff; /* Match nav links hover */
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.logo img {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    margin-right: 10px;
    border: 2px solid #30363d;
}

.logo span {
    font-weight: 600;
    font-size: 1.2rem;
}

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

nav ul li {
    margin-left: 20px;
}

nav ul li a {
    color: #c9d1d9;
    text-decoration: none;
    font-weight: 600;
    padding: 0.5rem 1rem;
    border-radius: 5px;
    transition: all 0.3s ease;
}

nav ul li a:hover {
    color: #ffffff;
    background-color: #58a6ff;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

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

.hero {
    text-align: center;
    padding: 6rem 0;
    position: relative;
    overflow: hidden;
    mask-image: linear-gradient(to bottom, rgba(0,0,0,0) 0%, rgba(0,0,0,1) 20%, rgba(0,0,0,1) 80%, rgba(0,0,0,0) 100%);
    -webkit-mask-image: linear-gradient(to bottom, rgba(0,0,0,0) 0%, rgba(0,0,0,1) 20%, rgba(0,0,0,1) 80%, rgba(0,0,0,0) 100%);
}

#vanta-globe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
}

.hero h1 {
    font-size: 3.5rem;
    margin-bottom: 1rem;
    font-weight: 700;
}

.hero p {
    font-size: 1.25rem;
    color: #8b949e;
}

.projects {
    padding: 4rem 0;
}

.projects h2 {
    font-size: 2.5rem;
    margin-bottom: 3rem;
    border-bottom: 1px solid #30363d;
    padding-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 1rem;
}

.project-grid {
    column-count: 3; /* Adjust number of columns as needed */
    column-gap: 2rem;
}

.card {
    background-color: #161b22;
    border: 1px solid #30363d;
    border-radius: 8px;
    padding: 2rem;
    margin-bottom: 2rem; /* Add margin-bottom to separate cards within columns */
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: inline-block; /* Important for column-count to work */
    width: 100%; /* Ensure cards take full width of their column */
    break-inside: avoid; /* Prevent cards from breaking across columns */
    box-sizing: border-box; /* Include padding and border in the element's total width and height */
}

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

.card h3 {
    margin-top: 0;
    font-size: 1.5rem;
    margin-bottom: 1rem;
}

.card a {
    text-decoration: none;
    color: #58a6ff;
    font-weight: 600;
}

.card ul {
    padding-left: 20px;
    flex-grow: 1;
}

.card li {
    margin-bottom: 0.5rem;
}

.loader {
    border: 4px solid #30363d;
    border-top: 4px solid #58a6ff;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
    margin: 50px auto;
}

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

.connect-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 2rem;
}

.social-card {
    background-color: #161b22;
    border: 1px solid #30363d;
    border-radius: 8px;
    padding: 2rem;
    text-align: center;
    flex: 1 1 250px; /* Allow cards to grow and shrink, with a base of 250px */
    max-width: 300px; /* Limit max width for larger screens */
    transition: transform 0.3s ease, box-shadow 0.3s ease, background-color 0.3s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.social-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.4);
}

.social-card i {
    margin-bottom: 1rem;
    font-size: 3.5rem; /* Slightly larger icons */
    color: #58a6ff;
    transition: color 0.3s ease;
}

.social-card h3 {
    margin-top: 0.5rem;
    font-size: 1.3rem;
}

.social-card:hover i {
    color: #ffffff;
}

.social-card.linkedin:hover {
    background-color: #0A66C2; /* LinkedIn blue */
}

.social-card.twitter:hover {
    background-color: #1DA1F2; /* Twitter blue */
}

.social-card.email:hover {
    background-color: #EA4335; /* Google red */
}

footer {
    text-align: center;
    padding: 2rem;
    border-top: 1px solid #30363d;
    color: #8b949e;
    position: relative;
    overflow: hidden;
}



footer p {
    position: relative;
    z-index: 1;
}

#footer-canvas {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    opacity: 0.8;
    mask-image: linear-gradient(to top, rgba(0,0,0,0) 0%, rgba(0,0,0,1) 20%, rgba(0,0,0,1) 80%, rgba(0,0,0,0) 100%);
    -webkit-mask-image: linear-gradient(to top, rgba(0,0,0,0) 0%, rgba(0,0,0,1) 20%, rgba(0,0,0,1) 80%, rgba(0,0,0,0) 100%);
}

.sidebar-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    z-index: 999;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease;
}

.sidebar-overlay.active {
    opacity: 1;
    visibility: visible;
}

.sidebar {
    position: fixed;
    top: 0;
    left: -350px; /* Start fully hidden */
    width: 350px;
    height: 100%;
    background-color: #0d1117;
    border-right: 1px solid #30363d;
    z-index: 1000;
    box-shadow: 5px 0 15px rgba(0, 0, 0, 0.3);
    transition: left 0.1s linear; /* Animate 'left' property */
    display: flex;
    flex-direction: column;
}

.sidebar.active {
    left: 0; /* Fully open when active */
}

.sidebar-header {
    padding: 1rem;
    /* border-bottom: 1px solid #30363d; */ /* Removed border */
    display: flex;
    justify-content: flex-end;
}

.close-btn {
    background: none;
    border: none;
    font-size: 2rem;
    color: #c9d1d9;
    cursor: pointer;
    transition: color 0.3s ease;
}

.close-btn:hover {
    color: #58a6ff;
}

.sidebar-content {
    padding: 2rem;
    overflow-y: auto;
    flex-grow: 1;
    background-color: #161b22; /* Card style background */
    margin: 1rem;
    border-radius: 8px;
    border: 1px solid #30363d;
    text-align: center;
}

.sidebar-avatar {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    border: 3px solid #58a6ff;
    margin-bottom: 1.5rem;
}

.sidebar-content h2 {
    font-size: 2rem;
    margin-bottom: 0.5rem;
}

.sidebar-tagline {
    color: #8b949e;
    font-size: 1.1rem;
    margin-bottom: 1.5rem;
}

.sidebar-social-links a {
    color: #c9d1d9;
    margin: 0 10px;
    font-size: 1.8rem;
    transition: color 0.3s ease;
}

.sidebar-social-links a:hover {
    color: #58a6ff;
}