/* Global Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    /* Dark theme variables (now default) */
    --primary-color: #6d8eff;
    --secondary-color: #3d4b75;
    --accent-color: #ff7a7a;
    --bg-color: #121212;
    --card-bg: #1e1e1e;
    --text-color: #ffffff;
    --text-secondary: #b0b0b0;
    --light-gray: #333;
    --dark-gray: #999;
    --border-color: #444;
    --shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
    
    /* Progress bar colors */
    --easy-color: #43a047;
    --medium-color: #fb8c00;
    --hard-color: #e91e63;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background-color: var(--bg-color);
}

a {
    text-decoration: none;
    color: var(--primary-color);
    transition: color 0.3s ease;
}

.btn {
    display: inline-block;
    padding: 0.8rem 1.5rem;
    background-color: var(--primary-color);
    color: white;
    border-radius: 4px;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
    font-size: 1rem;
    text-align: center;
    font-weight: 500;
    letter-spacing: 0.5px;
}

.btn:hover {
    background-color: var(--secondary-color);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.btn-outline {
    background-color: transparent;
    border: 2px solid var(--primary-color);
    color: var(--primary-color);
}

.btn-outline:hover {
    background-color: var(--primary-color);
    color: white;
}

.section-title {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
    position: relative;
    color: var(--text-color);
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 4px;
    background-color: var(--accent-color);
}

.section-description {
    text-align: center;
    color: var(--text-secondary);
    margin-bottom: 2rem;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
    padding: 0 1rem;
}

/* Header & Navigation */
header {
    background-color: rgba(17, 17, 17, 0.9);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.4);
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 100;
    transition: all 0.3s ease;
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.7rem 4%;
    max-width: 1600px;
    margin: 0 auto;
    height: 65px;
}

.logo h1 {
    font-size: 1.5rem;
    color: var(--primary-color);
    font-weight: 600;
    letter-spacing: 0.5px;
}

.menu-toggle {
    display: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--text-color);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: none;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    z-index: 110;
}

.menu-toggle:hover {
    background-color: rgba(255, 255, 255, 0.1);
    color: var(--primary-color);
}

.nav-links {
    display: flex;
    list-style: none;
}

.nav-links li {
    margin-left: 2rem;
}

.nav-links a {
    color: var(--text-color);
    font-weight: 500;
    font-size: 0.95rem;
    transition: color 0.3s ease;
    position: relative;
}

.nav-links a:after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: -5px;
    left: 0;
    background-color: var(--primary-color);
    transition: width 0.3s ease;
}

.nav-links a:hover {
    color: var(--primary-color);
}

.nav-links a:hover:after {
    width: 100%;
}

/* Add a down arrow indicating to scroll down at the bottom of the hero section */
.scroll-indicator {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    text-align: center;
    animation: bounce 2s infinite;
    cursor: pointer;
}

.scroll-indicator i {
    font-size: 1.8rem;
    color: var(--text-color);
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateY(0) translateX(-50%);
    }
    40% {
        transform: translateY(-15px) translateX(-50%);
    }
    60% {
        transform: translateY(-7px) translateX(-50%);
    }
}

/* Hero Section */
.hero {
    min-height: 100vh;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    margin-top: 0;
    background: linear-gradient(rgba(0, 0, 0, 0.7), rgba(0, 0, 0, 0.7)), url('https://images.unsplash.com/photo-1549692520-acc6669e2f0c?q=80&w=1974&auto=format&fit=crop') no-repeat center center/cover;
    color: white;
    position: relative;
}

.hero-content {
    max-width: 1400px;
    width: 100%;
    display: grid;
    grid-template-columns: 3fr 2fr;
    gap: 3rem;
    align-items: center;
    padding: 0 4%;
    margin-top: 65px; /* Adjust for fixed header */
}

.hero-text {
    text-align: left;
}

.hero h1 {
    font-size: 3.8rem;
    margin-bottom: 1rem;
    line-height: 1.2;
}

.hero h2 {
    font-size: 2.2rem;
    margin-bottom: 1.5rem;
    font-weight: 400;
}

.hero p {
    font-size: 1.3rem;
    margin-bottom: 2rem;
}

/* News Ticker */
.news-ticker-container {
    width: 100%;
    background-color: rgba(25, 25, 35, 0.95);
    display: flex;
    position: relative;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    z-index: 10;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.2);
    overflow: hidden;
}

.news-ticker-label {
    min-width: 140px;
    padding: 12px 20px;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: white;
    position: relative;
    box-shadow: 5px 0 15px rgba(0, 0, 0, 0.2);
    z-index: 2;
    cursor: pointer;
    transition: all 0.3s ease;
}

.news-ticker-label:hover {
    background: linear-gradient(135deg, var(--secondary-color), var(--primary-color));
    transform: translateY(-2px);
}

.news-ticker-label::after {
    content: '';
    position: absolute;
    right: -15px;
    top: 0;
    border-top: 20px solid transparent;
    border-bottom: 20px solid transparent;
    border-left: 15px solid var(--secondary-color);
    z-index: 2;
}

.news-ticker {
    flex: 1;
    overflow: hidden;
    padding: 12px 0;
    position: relative;
}

.news-ticker::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 50px;
    height: 100%;
    background: linear-gradient(to right, rgba(25, 25, 35, 0.95), transparent);
    z-index: 1;
}

.news-ticker::after {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 50px;
    height: 100%;
    background: linear-gradient(to left, rgba(25, 25, 35, 0.95), transparent);
    z-index: 1;
}

.news-ticker-content {
    display: flex;
    animation: marquee 20s linear infinite;
    white-space: nowrap;
    padding-right: 50px;
}

.ticker-item {
    display: inline-flex;
    align-items: center;
    margin-right: 120px;
    color: var(--text-color);
    font-size: 1rem;
    padding: 0 10px;
}

.ticker-item i {
    margin-right: 10px;
    color: var(--accent-color);
}

.ticker-item a {
    color: var(--primary-color);
    text-decoration: none;
    transition: color 0.2s ease, text-decoration 0.2s ease;
    margin: 0 5px;
}

.ticker-item a:hover {
    color: var(--accent-color);
    text-decoration: underline;
}

.ticker-date {
    display: inline-block;
    margin-left: 10px;
    font-size: 0.8rem;
    background-color: rgba(255, 255, 255, 0.05);
    padding: 2px 8px;
    border-radius: 10px;
    color: var(--text-secondary);
    font-weight: 500;
}

@keyframes marquee {
    0% {
        transform: translateX(100%);
    }
    100% {
        transform: translateX(-100%);
    }
}

.news-ticker:hover .news-ticker-content {
    animation-play-state: paused;
}

@media (max-width: 768px) {
    .news-ticker-label {
        min-width: 120px;
        font-size: 0.8rem;
        padding: 12px 15px;
    }
    
    .ticker-item {
        font-size: 0.9rem;
    }
}

@media (max-width: 480px) {
    .news-ticker-container {
        flex-direction: column;
        height: auto;
        overflow: visible;
    }
    
    .news-ticker-label {
        width: 100%;
        padding: 12px 15px;
        position: relative;
        z-index: 20;
        border-radius: 0;
        display: flex;
        background: linear-gradient(135deg, var(--accent-color), var(--primary-color));
        box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
        font-weight: bold;
    }
    
    .news-ticker-label::after {
        display: none;
    }
    
    /* Add an explicit tap/click indicator for mobile */
    .news-ticker-label::before {
        content: '\f0a9'; /* Font Awesome arrow icon */
        font-family: 'Font Awesome 5 Free';
        font-weight: 900;
        margin-right: 8px;
        font-size: 0.9rem;
    }
    
    .news-ticker-label span {
        display: flex;
        align-items: center;
        justify-content: center;
        width: 100%;
    }
    
    .news-ticker {
        padding: 8px 10px;
        width: 100%;
        height: auto;
        max-height: 100px;
        overflow: hidden;
    }
    
    .news-ticker-content {
        animation: marquee-mobile-compact 25s linear infinite;
        padding-right: 20px;
        white-space: nowrap;
    }
    
    @keyframes marquee-mobile-compact {
        0% {
            transform: translateX(100%);
        }
        100% {
            transform: translateX(-200%);
        }
    }
    
    .ticker-item {
        font-size: 0.8rem;
        margin-right: 40px;
        white-space: nowrap;
        display: inline-flex;
        align-items: center;
        line-height: 1.3;
        flex-shrink: 0;
        max-width: none;
    }
    
    /* Compact mobile news layout */
    .ticker-item .news-logo {
        width: 16px;
        height: 16px;
        margin-right: 6px;
    }
    
    .ticker-item i:not(.fa-bell) {
        font-size: 0.8rem;
        margin-right: 6px;
    }
    
    .ticker-date {
        font-size: 0.7rem;
        padding: 1px 6px;
        margin-left: 6px;
    }
}

@media (max-width: 992px) {
    .hero-content {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .hero-text {
        text-align: center;
    }
    
    .hero-buttons {
        justify-content: center;
    }
}

.hero-buttons {
    display: flex;
    gap: 1rem;
}

.highlight {
    color: var(--accent-color);
}

.hero-image {
    display: flex;
    justify-content: center;
    align-items: center;
}

.profile-img-placeholder {
    width: 280px;
    height: 280px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    border: 4px solid var(--accent-color);
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.3);
    overflow: hidden;
}

.profile-img-placeholder i {
    font-size: 8rem;
    color: rgba(255, 255, 255, 0.8);
}

.profile-img-placeholder img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* About section */
.about {
    padding: 5rem 1rem;
    padding-top: 120px; /* Extra padding for fixed header */
    background-color: var(--bg-color);
    position: relative;
}

.about-content {
    max-width: 900px;
    margin: 3rem auto 0;
}

.about-text p {
    margin-bottom: 1.5rem;
    font-size: 1.1rem;
    color: var(--text-color);
}

.tech-stack {
    display: flex;
    flex-wrap: wrap;
    gap: 0.8rem;
    margin: 1.5rem 0;
}

.tech-tag {
    background-color: var(--light-gray);
    color: var(--text-color);
    padding: 0.5rem 1rem;
    border-radius: 30px;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.tech-tag:hover {
    background-color: var(--primary-color);
    color: white;
    transform: translateY(-3px);
}

/* Education section */
.education {
    padding: 5rem 1rem;
    padding-top: 120px; /* Extra padding for fixed header */
    background-color: var(--bg-color);
    position: relative;
}

.education-container {
    max-width: 900px;
    margin: 3rem auto 0;
    display: flex;
    flex-direction: column;
    gap: 2.5rem;
}

.education-card {
    display: flex;
    background: linear-gradient(145deg, rgba(30, 30, 30, 0.6), rgba(20, 20, 20, 0.8));
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    transition: all 0.3s ease;
    position: relative;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.education-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 40px rgba(109, 142, 255, 0.1);
    border-color: rgba(109, 142, 255, 0.2);
}

.education-card::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    height: 100%;
    width: 3px;
    background: linear-gradient(to bottom, var(--primary-color), var(--accent-color));
}

.education-logo {
    flex: 0 0 160px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
    background-color: white;
    border-right: 1px solid rgba(255, 255, 255, 0.05);
}

.education-logo img {
    max-width: 120px;
    height: auto;
    transition: transform 0.3s ease;
    filter: drop-shadow(0 4px 6px rgba(0, 0, 0, 0.1));
}

.education-card:hover .education-logo img {
    transform: scale(1.05);
}

.education-details {
    flex: 1;
    padding: 2rem;
    position: relative;
}

.education-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    margin-bottom: 1rem;
}

.education-header h3 {
    font-size: 1.6rem;
    font-weight: 600;
    color: var(--text-color);
    margin: 0;
    padding: 0;
}

.education-year {
    color: var(--primary-color);
    font-size: 1.1rem;
    font-weight: 500;
    background-color: rgba(109, 142, 255, 0.1);
    padding: 0.3rem 1rem;
    border-radius: 20px;
    margin-left: 1rem;
}

.education-divider {
    width: 100%;
    height: 1px;
    background: linear-gradient(to right, var(--primary-color), transparent);
    margin: 1rem 0;
}

.education-institution {
    font-size: 1.2rem;
    color: var(--text-secondary);
    margin-bottom: 1.2rem;
    font-weight: 500;
    letter-spacing: 0.5px;
}

.education-content {
    margin-top: 1.5rem;
    color: var(--text-secondary);
    font-size: 1.1rem;
}

.education-achievement {
    display: inline-block;
    background-color: rgba(255, 255, 255, 0.05);
    padding: 0.8rem 1.5rem;
    border-radius: 8px;
    margin-top: 0.5rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    border-left: 3px solid var(--accent-color);
}

.achievement-label {
    font-weight: 600;
    color: var(--text-secondary);
}

.achievement-value {
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--accent-color);
}

@media (max-width: 768px) {
    .education-card {
        flex-direction: column;
    }
    
    .education-card::before {
        width: 100%;
        height: 3px;
        top: 0;
        left: 0;
        background: linear-gradient(to right, var(--primary-color), var(--accent-color));
    }
    
    .education-logo {
        padding: 1.5rem;
        border-right: none;
        border-bottom: 1px solid rgba(255, 255, 255, 0.05);
        flex: unset;
        width: 100%;
    }
    
    .education-header {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .education-year {
        margin-left: 0;
        margin-top: 0.5rem;
    }
}

@media (max-width: 480px) {
    .education-details {
        padding: 1.5rem;
    }
    
    .education-header h3 {
        font-size: 1.3rem;
    }
    
    .education-logo img {
        max-width: 100px;
    }
}

/* Course Work section */
.course-work {
    padding: 2.5rem 1rem;
    padding-top: 100px; /* Reduced padding for fixed header */
    background-color: var(--bg-color); /* Single color background */
    position: relative;
}

.course-work-content {
    max-width: 800px;
    margin: 1.5rem auto 0;
}

.tech-certifications {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2.5rem;
    justify-content: center;
    align-items: center;
    max-width: 600px;
    margin: 0 auto;
    position: relative;
    padding: 1.5rem 0;
}

/* Offset every other row to create diamond pattern */
.tech-certifications .cert-item:nth-child(4n-2),
.tech-certifications .cert-item:nth-child(4n-1) {
    transform: translateY(1.5rem);
}

.cert-item {
    text-align: center;
    transition: all 0.3s ease;
    position: relative;
    perspective: 1000px;
}

.cert-item:hover {
    transform: translateY(-10px) scale(1.1);
    z-index: 5;
}

/* Reset the hover for the offset items to maintain diamond pattern */
.tech-certifications .cert-item:nth-child(4n-2):hover,
.tech-certifications .cert-item:nth-child(4n-1):hover {
    transform: translateY(-10px) scale(1.1);
}

.cert-logo {
    width: 60px;
    height: 60px;
    filter: grayscale(20%); /* Consistent styling */
    opacity: 0.9;
    transition: all 0.3s ease;
    background-color: rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    padding: 10px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    transform-style: preserve-3d;
}

.cert-item:hover .cert-logo {
    filter: grayscale(0%);
    opacity: 1;
    box-shadow: 0 8px 16px rgba(109, 142, 255, 0.2);
    background-color: rgba(255, 255, 255, 0.08);
    transform: translateZ(20px) rotateY(10deg);
}

.cert-item::before {
    content: '';
    position: absolute;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at center, rgba(109, 142, 255, 0.1), transparent 70%);
    top: 0;
    left: 0;
    opacity: 0;
    transition: opacity 0.3s ease;
    border-radius: 12px;
    pointer-events: none;
    z-index: -1;
}

.cert-item:hover::before {
    opacity: 1;
}

.cert-item:hover::after {
    content: attr(data-tooltip);
    position: absolute;
    top: -40px;
    left: 50%;
    transform: translateX(-50%);
    background-color: var(--primary-color);
    color: white;
    padding: 6px 12px;
    border-radius: 4px;
    font-size: 0.8rem;
    white-space: nowrap;
    opacity: 0;
    animation: fadeIn 0.3s forwards;
    z-index: 10;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

@keyframes fadeIn {
    to {
        opacity: 1;
    }
}

/* Enable title tooltip on hover via JavaScript for better UX */
.cert-item img {
    cursor: pointer;
}

@media (max-width: 768px) {
    .tech-certifications {
        grid-template-columns: repeat(3, 1fr);
        gap: 2rem;
    }
    
    /* Reset diamond pattern on tablets */
    .tech-certifications .cert-item:nth-child(4n-2),
    .tech-certifications .cert-item:nth-child(4n-1) {
        transform: translateY(0);
    }
    
    /* Create new diamond pattern for 3 column layout */
    .tech-certifications .cert-item:nth-child(3n-1) {
        transform: translateY(1.5rem);
    }
    
    .tech-certifications .cert-item:nth-child(3n-1):hover {
        transform: translateY(-10px) scale(1.1);
    }
}

@media (max-width: 576px) {
    .course-work {
        padding: 2rem 0.5rem;
    }
    
    .tech-certifications {
        grid-template-columns: repeat(2, 1fr);
        gap: 1.5rem;
    }
    
    /* Reset all offset patterns */
    .tech-certifications .cert-item:nth-child(4n-2),
    .tech-certifications .cert-item:nth-child(4n-1),
    .tech-certifications .cert-item:nth-child(3n-1) {
        transform: translateY(0);
    }
    
    .cert-logo {
        width: 50px;
        height: 50px;
        padding: 8px;
    }
    
    .section-title {
        margin-bottom: 0.3rem;
    }
}

/* Projects section */
.projects {
    padding: 5rem 1rem;
    padding-top: 120px; /* Extra padding for fixed header */
    background-color: var(--light-gray);
}

.project-grid {
    max-width: 1200px;
    margin: 3rem auto 0;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 2rem;
}

.project-card {
    background-color: var(--bg-color);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
}

.project-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
}

.project-card h3 {
    font-size: 1.5rem;
    margin-bottom: 0.8rem;
    color: var(--text-color);
}

.project-card p {
    margin-bottom: 1.5rem;
    color: var(--text-secondary);
    flex-grow: 1;
}

.project-links {
    display: flex;
    gap: 1rem;
    margin-top: auto;
}

.project-links .btn {
    padding: 0.5rem 1rem;
    font-size: 0.9rem;
}

.loading {
    text-align: center;
    padding: 2rem;
    color: var(--text-secondary);
}

/* Coding Profiles Section */
.coding-profiles {
    padding: 5rem 1rem;
    padding-top: 120px; /* Extra padding for fixed header */
    background-color: var(--bg-color);
}

.profiles-container {
    max-width: 1000px;
    margin: 3rem auto;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 5rem;
}

.profile-link {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-decoration: none;
    color: var(--text-color);
    transition: transform 0.3s ease;
}

.profile-link:hover {
    transform: translateY(-10px);
}

.profile-logo {
    width: 70px;
    height: 70px;
    margin-bottom: 1rem;
    object-fit: contain;
    transition: transform 0.3s ease;
}

/* Specific logo styling */
.github-logo {
    background-color: #fff;
    border-radius: 50%;
    padding: 5px;
}

.leetcode-logo {
    border-radius: 10px;
}

.codeforces-logo {
    border-radius: 10px;
}

.profile-link span {
    font-size: 1.1rem;
    font-weight: 500;
    letter-spacing: 0.5px;
    margin-top: 0.5rem;
    color: #fff;
}

/* Media query for smaller screens */
@media (max-width: 768px) {
    .profiles-container {
        gap: 3rem;
        flex-wrap: wrap;
    }
    
    .profile-logo {
        width: 60px;
        height: 60px;
    }
}

@media (max-width: 576px) {
    .profiles-container {
        gap: 2rem;
    }
    
    .profile-logo {
        width: 50px;
        height: 50px;
    }
}

/* Featured Project Section */
.featured-project {
    padding: 5rem 1rem;
    padding-top: 120px; /* Extra padding for fixed header */
    background-color: var(--bg-color);
}

.featured-project-container {
    max-width: 1000px;
    margin: 3rem auto 0;
    position: relative;
}

/* Project Slider Styles */
.featured-project-slider {
    width: 100%;
    overflow: hidden;
    position: relative;
    display: flex;
    transition: transform 0.5s ease;
}

.project-card {
    flex: 0 0 100%;
    background-color: rgba(255, 255, 255, 0.03);
    border-radius: 12px;
    box-shadow: var(--shadow);
    margin-bottom: 2rem;
    overflow: hidden;
    position: relative;
    transition: all 0.3s ease;
}

.project-card:not(:first-child) {
    display: none;
}

.project-preview {
    padding: 2rem;
    cursor: pointer;
    position: relative;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    background: linear-gradient(to bottom, rgba(255, 255, 255, 0.05), transparent);
}

.project-preview h3 {
    font-size: 1.8rem;
    margin-bottom: 1rem;
    color: var(--primary-color);
    transition: color 0.3s ease;
}

.project-details {
    padding: 0 2rem 2rem;
    display: none;
    animation: fadeInUp 0.5s ease forwards;
}

.project-details h3 {
    font-size: 1.6rem;
    margin-bottom: 1rem;
    color: var(--primary-color);
    margin-top: 2rem;
}

.award-badge {
    display: inline-block;
    color: #ffcc00;
    padding: 0.5rem 0;
    font-size: 0.95rem;
    margin-bottom: 1.5rem;
    font-weight: 500;
}

.project-description {
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
    font-size: 1.1rem;
    line-height: 1.7;
}

.expand-btn, .collapse-btn {
    background: none;
    border: none;
    color: var(--primary-color);
    font-size: 1.2rem;
    cursor: pointer;
    margin-top: 1rem;
    padding: 0.5rem;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    background-color: rgba(255, 255, 255, 0.05);
}

.expand-btn:hover, .collapse-btn:hover {
    background-color: var(--primary-color);
    color: white;
    transform: translateY(-3px);
}

.slider-controls {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1.5rem;
    margin-top: 1rem;
}

.slider-btn {
    background: none;
    border: none;
    color: var(--text-color);
    font-size: 1.2rem;
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    background-color: rgba(255, 255, 255, 0.05);
}

.slider-btn:hover {
    background-color: var(--primary-color);
    color: white;
    transform: translateY(-2px);
}

.slider-dots {
    display: flex;
    gap: 0.5rem;
    align-items: center;
}

.dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background-color: var(--light-gray);
    cursor: pointer;
    transition: all 0.3s ease;
}

.dot.active {
    background-color: var(--primary-color);
    transform: scale(1.2);
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Fix Button Styling */
.btn {
    display: inline-block;
    padding: 0.8rem 1.8rem;
    background-color: var(--primary-color);
    color: white;
    border-radius: 50px;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
    font-size: 0.95rem;
    text-align: center;
    font-weight: 500;
    letter-spacing: 0.5px;
    box-shadow: 0 4px 12px rgba(109, 142, 255, 0.2);
    position: relative;
    overflow: hidden;
}

.btn:hover {
    background-color: var(--secondary-color);
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
}

.btn:active {
    transform: translateY(-1px);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
}

.btn::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 120%;
    height: 120%;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    transform: translate(-50%, -50%) scale(0);
    opacity: 0;
    transition: transform 0.4s ease, opacity 0.3s ease;
}

.btn:hover::after {
    transform: translate(-50%, -50%) scale(1);
    opacity: 1;
}

.project-links .btn {
    padding: 0.7rem 1.6rem;
    font-size: 0.9rem;
    margin-top: 0.5rem;
}

/* Media Queries */

/* Media Queries */

/* Internships Section */
.internships {
    padding: 5rem 1rem;
    padding-top: 120px; /* Extra padding for fixed header */
    background-color: var(--bg-color); /* Changed to match main background */
    position: relative;
}

.internships-container {
    max-width: 1000px;
    margin: 3rem auto 0;
    display: flex;
    flex-direction: column;
    gap: 2.5rem;
}

.internship-card {
    background-color: var(--bg-color);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--shadow);
    display: flex;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    position: relative;
}

.internship-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.2);
}

.company-logo {
    flex: 0 0 180px;
    padding: 1.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: rgba(255, 255, 255, 0.03);
    border-right: 1px solid rgba(255, 255, 255, 0.05);
}

.styled-logo {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 120px;
    height: 120px;
    border-radius: 12px;
    overflow: hidden;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.2);
    transition: all 0.3s ease;
    padding: 1rem;
    text-align: center;
}

.nms-logo {
    background: linear-gradient(135deg, #3d4b75, #6d8eff);
}

.ineuron-logo {
    background: linear-gradient(135deg, #0f2027, #203a43, #2c5364);
}

.logo-text {
    font-size: 2rem;
    font-weight: 700;
    color: white;
    letter-spacing: 1px;
    margin-bottom: 0.3rem;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.logo-subtext {
    font-size: 0.9rem;
    font-weight: 400;
    color: rgba(255, 255, 255, 0.9);
    letter-spacing: 0.5px;
}

.internship-card:hover .styled-logo {
    transform: scale(1.05);
    box-shadow: 0 12px 24px rgba(0, 0, 0, 0.3);
}

.company-img {
    width: 100%;
    max-width: 120px;
    height: auto;
    object-fit: contain;
    filter: grayscale(20%);
    transition: filter 0.3s ease;
}

.internship-card:hover .company-img {
    filter: grayscale(0%);
}

.internship-details {
    flex: 1;
    padding: 1.5rem 2rem;
}

.internship-details h3 {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
    color: var(--primary-color);
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}

.internship-tag {
    font-size: 0.8rem;
    font-weight: 500;
    padding: 0.2rem 0.8rem;
    background-color: var(--secondary-color);
    color: white;
    border-radius: 20px;
    display: inline-block;
}

.company-name {
    font-size: 1.1rem;
    color: var(--text-secondary);
    margin-bottom: 1rem;
    font-weight: 400;
}

.internship-description {
    margin-bottom: 1.5rem;
    color: var(--text-secondary);
    line-height: 1.6;
}

.internship-links {
    display: flex;
    gap: 1rem;
    margin-top: 1.5rem;
}

@media (max-width: 768px) {
    .internship-card {
        flex-direction: column;
    }
    
    .company-logo {
        flex: 0;
        padding: 2rem;
        border-right: none;
        border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    }
    
    .company-img {
        max-width: 100px;
    }
}

/* Chart and Progress Bar Styles */
.leetcode-distribution {
    margin-top: 1.5rem;
    width: 100%;
}

.difficulty-bar {
    margin-bottom: 1rem;
}

.difficulty-label {
    font-size: 0.9rem;
    margin-bottom: 0.3rem;
    color: var(--text-secondary);
    display: block;
}

.progress-container {
    background-color: var(--light-gray);
    border-radius: 20px;
    height: 10px;
    position: relative;
    overflow: hidden;
    width: 100%;
}

.progress-bar {
    height: 100%;
    border-radius: 20px;
    transition: width 1s ease;
}

.progress-bar.easy {
    background-color: var(--easy-color);
}

.progress-bar.medium {
    background-color: var(--medium-color);
}

.progress-bar.hard {
    background-color: var(--hard-color);
}

.progress-text {
    position: absolute;
    right: 5px;
    top: -20px;
    font-size: 0.8rem;
    color: var(--text-secondary);
}

/* Chart containers */
.chart-container {
    width: 100%;
    height: 150px;
    background-color: rgba(255, 255, 255, 0.05);
    border-radius: 8px;
    margin-top: 1.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-secondary);
}

/* GitHub Stats Section */
.github-stats {
    padding: 5rem 1rem;
    padding-top: 120px; /* Extra padding for fixed header */
    background-color: var(--bg-color);
}

.github-stats-container {
    max-width: 1000px;
    margin: 3rem auto 0;
}

.github-readme-stats {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 2rem;
    margin-bottom: 2rem;
}

.github-stats-card-img {
    border-radius: 12px;
    box-shadow: var(--shadow);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    max-width: 100%;
    height: auto;
}

.github-stats-card-img:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.3);
}

@media (max-width: 768px) {
    .github-readme-stats {
        flex-direction: column;
        align-items: center;
    }
    
    .github-stats-card-img {
        max-width: 100%;
    }
}

/* Coding Profiles Section */
@media (max-width: 992px) {
    .hero-content {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .hero-text {
        text-align: center;
    }
    
    .hero-buttons {
        justify-content: center;
    }
}

/* Mobile menu animations and styling */
@media (max-width: 768px) {
    .menu-toggle {
        display: flex;
    }
    
    .section-title {
        font-size: 2rem;
    }
    
    .nav-links {
        position: fixed;
        top: 65px;
        left: -100%;
        width: 100%;
        height: calc(100vh - 65px);
        background-color: rgba(17, 17, 17, 0.98);
        flex-direction: column;
        align-items: center;
        justify-content: flex-start;
        padding-top: 2rem;
        transition: all 0.4s cubic-bezier(0.77, 0.2, 0.05, 1.0);
        z-index: 99;
        backdrop-filter: blur(10px);
        -webkit-backdrop-filter: blur(10px);
    }
    
    .nav-links.active {
        left: 0;
        box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    }
    
    .nav-links li {
        margin: 0;
        width: 80%;
        opacity: 0;
        transform: translateY(20px);
        transition: opacity 0.4s ease, transform 0.4s ease;
        transition-delay: 0.1s;
    }
    
    .nav-links.active li {
        opacity: 1;
        transform: translateY(0);
    }
    
    .nav-links li:nth-child(2) {
        transition-delay: 0.15s;
    }
    
    .nav-links li:nth-child(3) {
        transition-delay: 0.2s;
    }
    
    .nav-links li:nth-child(4) {
        transition-delay: 0.25s;
    }
    
    .nav-links li:nth-child(5) {
        transition-delay: 0.3s;
    }
    
    .nav-links li:nth-child(6) {
        transition-delay: 0.35s;
    }
    
    .nav-links li:nth-child(7) {
        transition-delay: 0.4s;
    }
    
    .nav-links a {
        display: block;
        padding: 1rem 0;
        text-align: center;
        font-size: 1.1rem;
        width: 100%;
        border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    }
    
    .nav-links a:after {
        bottom: -2px;
    }
    
    /* Hamburger Icon Animation */
    .menu-toggle {
        position: relative;
    }
    
    .menu-toggle i {
        transition: all 0.3s ease;
    }
    
    .menu-toggle.active i.fa-bars {
        transform: rotate(90deg);
        opacity: 0;
    }
    
    .menu-toggle.active:before {
        content: '\f00d';
        font-family: 'Font Awesome 5 Free';
        font-weight: 900;
        position: absolute;
        font-size: 1.5rem;
        color: var(--primary-color);
        animation: rotateIn 0.3s ease;
    }
    
    @keyframes rotateIn {
        from {
            transform: rotate(-90deg);
            opacity: 0;
        }
        to {
            transform: rotate(0);
            opacity: 1;
        }
    }
    
    /* Restore other mobile styles */
    .hero h1 {
        font-size: 2.5rem;
    }
    
    .hero h2 {
        font-size: 1.5rem;
    }
    
    .hero-image {
        margin-top: 2rem;
    }
    
    .profile-img-placeholder {
        width: 200px;
        height: 200px;
    }
    
    .tech-stack {
        justify-content: center;
    }
}

@media (max-width: 576px) {
    .section-title {
        font-size: 1.8rem;
    }
    
    .hero h1 {
        font-size: 2rem;
    }
    
    .hero h2 {
        font-size: 1.2rem;
    }
    
    .hero p {
        font-size: 1rem;
    }
    
    .about-text p {
        font-size: 1rem;
    }
    
    .profile-img-placeholder {
        width: 180px;
        height: 180px;
    }
} 

/* News Section */
.news-section {
    width: 100%;
    background-color: rgba(25, 25, 35, 0.95);
    padding: 25px 0;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.2);
}

.news-header {
    text-align: center;
    margin-bottom: 20px;
}

.news-header h3 {
    display: inline-block;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    padding: 8px 25px;
    border-radius: 30px;
    font-size: 1.2rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.news-items {
    max-width: 1000px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.news-item {
    display: flex;
    align-items: center;
    background-color: rgba(255, 255, 255, 0.03);
    border-radius: 8px;
    padding: 15px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border-left: 3px solid var(--primary-color);
}

.news-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
    background-color: rgba(255, 255, 255, 0.05);
}

.news-item i {
    font-size: 1.4rem;
    color: var(--accent-color);
    margin-right: 15px;
}

.news-content {
    flex: 1;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
}

.news-content p {
    margin: 0;
    font-size: 1rem;
    color: var(--text-color);
}

.news-date {
    font-size: 0.85rem;
    background-color: rgba(255, 255, 255, 0.05);
    padding: 3px 10px;
    border-radius: 20px;
    color: var(--text-secondary);
    white-space: nowrap;
}

.news-item a {
    color: var(--primary-color);
    text-decoration: none;
    transition: color 0.2s ease, text-decoration 0.2s ease;
}

.news-item a:hover {
    color: var(--accent-color);
    text-decoration: underline;
}

@media (max-width: 768px) {
    .news-content {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .news-item {
        padding: 12px;
    }
    
    .news-date {
        align-self: flex-start;
    }
}

@media (max-width: 480px) {
    .news-item i {
        font-size: 1.2rem;
        margin-right: 10px;
    }
    
    .news-content p {
        font-size: 0.9rem;
    }
} 

/* Modal Styles */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(5px);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.modal.show {
    display: block;
    opacity: 1;
}

.modal-content {
    background-color: var(--card-bg);
    margin: 5vh auto;
    width: 90%;
    max-width: 1000px;
    border-radius: 10px;
    box-shadow: 0 5px 30px rgba(0, 0, 0, 0.5);
    animation: modalFadeIn 0.5s ease;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
}

.modal-header {
    padding: 20px 25px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.modal-header h2 {
    margin: 0;
    color: var(--primary-color);
    font-size: 1.5rem;
}

.close-modal {
    color: var(--text-secondary);
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
}

.close-modal:hover {
    color: var(--accent-color);
    transform: scale(1.1);
}

.modal-body {
    padding: 20px 25px;
    overflow-y: auto;
    flex: 1;
}

.modal-footer {
    padding: 10px 25px;
    text-align: center;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.table-container {
    width: 100%;
    overflow-x: auto;
}

.events-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
}

.events-table th,
.events-table td {
    padding: 12px 15px;
    text-align: left;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.events-table th {
    background-color: rgba(0, 0, 0, 0.3);
    color: var(--primary-color);
    font-weight: 600;
    text-transform: uppercase;
    font-size: 0.8rem;
    letter-spacing: 1px;
}

.events-table tr {
    background-color: rgba(255, 255, 255, 0.02);
    transition: background-color 0.3s ease;
}

.events-table tr:nth-child(odd) {
    background-color: rgba(255, 255, 255, 0.04);
}

.events-table tr:hover {
    background-color: rgba(255, 255, 255, 0.08);
}

.events-table td a.btn-sm {
    display: inline-block;
    padding: 5px 12px;
    background-color: var(--primary-color);
    color: white;
    font-size: 0.8rem;
    border-radius: 20px;
    transition: all 0.3s ease;
    text-decoration: none;
    text-align: center;
}

.events-table td a.btn-sm:hover {
    background-color: var(--accent-color);
    transform: translateY(-2px);
}

@keyframes modalFadeIn {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Mobile Optimizations */
@media (max-width: 992px) {
    .modal-content {
        width: 95%;
        margin: 3vh auto;
    }
    
    .modal-header h2 {
        font-size: 1.3rem;
    }
}

@media (max-width: 768px) {
    .news-ticker-label {
        min-width: 120px;
        font-size: 0.8rem;
        padding: 12px 15px;
    }
    
    .ticker-item {
        font-size: 0.9rem;
    }
    
    .events-table th,
    .events-table td {
        padding: 10px;
        font-size: 0.9rem;
    }
    
    /* Stack columns on mobile */
    .events-table thead {
        display: none;
    }
    
    .events-table tr {
        margin-bottom: 15px;
        display: block;
        border: 1px solid rgba(255, 255, 255, 0.1);
        border-radius: 8px;
        padding: 10px;
    }
    
    .events-table td {
        display: flex;
        text-align: right;
        padding: 8px 10px;
        border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    }
    
    .events-table td:last-child {
        border-bottom: none;
    }
    
    .events-table td::before {
        content: attr(data-label);
        font-weight: bold;
        text-align: left;
        color: var(--primary-color);
        padding-right: 10px;
        flex: 1;
    }
}

@media (max-width: 480px) {
    .news-ticker-container {
        flex-direction: column;
    }
    
    .news-ticker-label {
        width: 100%;
        padding: 15px 20px;
        position: relative;
        z-index: 20;
        border-radius: 0;
        min-height: 48px; /* Ensure minimum touch target size */
        touch-action: manipulation; /* Optimize for touch */
        -webkit-tap-highlight-color: rgba(109, 142, 255, 0.3); /* Add tap highlight */
        user-select: none; /* Prevent text selection on touch */
    }
    
    .news-ticker-label::after {
        display: none;
    }
    
    /* Add an explicit tap/click indicator for mobile */
    .news-ticker-label::before {
        content: '\f0a9'; /* Font Awesome arrow icon */
        font-family: 'Font Awesome 5 Free';
        font-weight: 900;
        margin-right: 8px;
        font-size: 0.9rem;
    }
    
    .news-ticker-label span {
        display: flex;
        align-items: center;
        justify-content: center;
        width: 100%;
        pointer-events: none; /* Let parent handle all events */
    }
    
    /* Improve mobile button interaction */
    .news-ticker-label:active {
        background: linear-gradient(135deg, var(--secondary-color), var(--primary-color));
        transform: scale(0.98);
    }
    
    /* Ensure ticker items are visible on mobile */
    .ticker-item {
        font-size: 0.85rem;
        white-space: normal;
        display: inline-block;
        padding: 5px 0;
        line-height: 1.4;
    }
    
    /* Ensure proper display of ticker content on mobile */
    .news-ticker {
        padding: 15px 0;
        overflow-x: hidden;
    }
    
    /* Ensure the ticker content stays visible */
    .news-ticker-content {
        animation-duration: 30s !important;
        display: flex;
        align-items: center;
    }
    
    .modal-content {
        width: 100%;
        height: 100%;
        max-height: none;
        margin: 0;
        border-radius: 0;
    }
    
    .modal-body {
        padding: 15px;
    }
    
    .events-table td {
        font-size: 0.85rem;
        padding: 6px 8px;
    }
} 

/* --- News Ticker Enhancements --- */
.animated-badge {
  animation: bellPulse 1.2s infinite alternate;
  color: var(--accent-color);
  margin-left: 6px;
}
@keyframes bellPulse {
  0% { filter: drop-shadow(0 0 0px var(--accent-color)); }
  100% { filter: drop-shadow(0 0 8px var(--accent-color)); }
}
.news-badge {
  display: inline-block;
  background: var(--accent-color);
  color: #fff;
  font-size: 0.7em;
  border-radius: 50%;
  width: 16px;
  height: 16px;
  text-align: center;
  line-height: 16px;
  margin-left: 8px;
  box-shadow: 0 0 8px var(--accent-color);
  animation: badgeGlow 1.5s infinite alternate;
}
@keyframes badgeGlow {
  0% { box-shadow: 0 0 8px var(--accent-color); }
  100% { box-shadow: 0 0 16px var(--accent-color); }
}
.news-logo {
  width: 22px;
  height: 22px;
  object-fit: contain;
  border-radius: 4px;
  margin-right: 8px;
  vertical-align: middle;
  box-shadow: 0 1px 4px rgba(0,0,0,0.10);
}
/* --- Modal Enhancements --- */
.modal-badge {
  display: inline-block;
  background: var(--accent-color);
  color: #fff;
  font-size: 0.7em;
  border-radius: 12px;
  padding: 2px 10px;
  margin-left: 10px;
  vertical-align: middle;
  animation: badgeGlow 1.5s infinite alternate;
}
.news-logo-table {
  width: 18px;
  height: 18px;
  object-fit: contain;
  border-radius: 3px;
  margin-right: 5px;
  vertical-align: middle;
}
/* --- Highlight most recent row in modal --- */
.highlight-row {
  background: rgba(255, 255, 255, 0.08);
  font-weight: 600;
  border-left: 4px solid var(--accent-color);
} 