:root {
    --bg-color: #f8f9fa;
    --text-color: #333;
    --subtitle-color: #666;
    --card-bg: rgba(255, 255, 255, 0.9);
    --header-bg: rgba(255, 255, 255, 0.9);
    --footer-bg: rgba(52, 58, 64, 0.95);
    --footer-text: white;
    --card-shadow: rgba(0, 0, 0, 0.08);
    --card-hover-shadow: rgba(0, 0, 0, 0.15);
    --header-shadow: rgba(0, 0, 0, 0.1);
    --particle-color: #007bff;
    --line-color: #007bff;
}

.dark-mode {
    --bg-color: #121212;
    --text-color: #f1f1f1;
    --subtitle-color: #bbbbbb;
    --card-bg: rgba(45, 45, 45, 0.9);
    --header-bg: rgba(30, 30, 30, 0.9);
    --footer-bg: rgba(20, 20, 20, 0.95);
    --footer-text: #f1f1f1;
    --card-shadow: rgba(0, 0, 0, 0.3);
    --card-hover-shadow: rgba(0, 0, 0, 0.5);
    --header-shadow: rgba(0, 0, 0, 0.5);
    --particle-color: #4f8eff;
    --line-color: #4f8eff;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: var(--bg-color);
    color: var(--text-color);
    margin: 0;
    padding: 0;
    overflow-x: hidden;
    position: relative;
    transition: background-color 0.3s ease;
}

/* Particles container */
#particles-js {
    position: fixed;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    z-index: -1;
    background-color: var(--bg-color);
    transition: background-color 0.3s ease;
}

main {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    position: relative;
    z-index: 1;
}

header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 50px;
    background-color: var(--header-bg);
    backdrop-filter: blur(5px);
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1000;
    box-shadow: 0 4px 15px var(--header-shadow);
    transform: translateY(-100%);
    animation: slideDown 0.8s ease forwards;
    transition: background-color 0.3s ease, box-shadow 0.3s ease;
}

.header-left {
    display: flex;
    align-items: center;
}

.header-logo {
    max-width: 130px;
    height: auto;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

header a {
    text-decoration: none;
    color: var(--text-color);
    font-weight: bold;
    padding: 0.5rem;
    border-radius: 4px;
    transition: all 0.3s ease;
    font-size: 0.9rem;
}

header a:hover {
    background-color: rgba(128, 128, 128, 0.1);
    color: #007bff;
}

.theme-toggle {
    cursor: pointer;
    padding: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background-color: rgba(128, 128, 128, 0.1);
    color: var(--text-color);
    transition: all 0.3s ease;
    border: none;
}

.theme-toggle:hover {
    background-color: rgba(128, 128, 128, 0.2);
}

.welcome-section {
    text-align: center;
    padding: 1rem;
    margin-bottom: 1rem;
}

.typewriter {
    font-size: clamp(1.5rem, 5vw, 2.5rem);
    font-weight: 600;
    color: var(--text-color);
    margin-bottom: 1rem;
    display: inline-block;
    overflow: hidden;
    border-right: 3px solid var(--text-color);
    white-space: nowrap;
    margin: 0 auto;
    letter-spacing: 0.1em;
    animation: typing 3.5s steps(40, end), blink-caret 0.75s step-end infinite;
    transition: color 0.3s ease;
}

.subtitle {
    font-size: clamp(0.9rem, 3vw, 1.2rem);
    color: var(--subtitle-color);
    max-width: 800px;
    margin: 1rem auto 0;
    opacity: 0;
    animation: fadeIn 1s ease forwards;
    animation-delay: 3.5s;
    transition: color 0.3s ease;
    padding: 0 1rem;
}

.wrapper {
    max-width: 1200px;
    margin: 30px auto 50px;
    padding: 0 20px;
    width: 100%;
    flex-grow: 1;
}

.card {
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 6px 15px var(--card-shadow);
    transition: transform 0.5s ease, box-shadow 0.5s ease, background-color 0.3s ease;
    opacity: 0;
    transform: translateY(50px);
    animation: fadeInUp 1s ease forwards;
    animation-delay: calc(4s + (var(--index) * 0.2s));
    background-color: var(--card-bg);
    backdrop-filter: blur(5px);
    color: var(--text-color);
}

.card:hover {
    transform: translateY(-10px);
    box-shadow: 0 12px 20px var(--card-hover-shadow);
}

.card-img-top {
    height: 200px;
    object-fit: cover;
}

.card-title {
    color: var(--text-color);
    transition: color 0.3s ease;
    font-size: clamp(1.1rem, 3vw, 1.25rem);
}

.card-text {
    color: var(--subtitle-color);
    transition: color 0.3s ease;
    font-size: clamp(0.9rem, 2vw, 1rem);
}

.card-footer {
    background-color: rgba(0, 0, 0, 0.03);
    transition: background-color 0.3s ease;
    font-size: clamp(0.75rem, 2vw, 0.875rem);
}

.dark-mode .card-footer {
    background-color: rgba(255, 255, 255, 0.05);
}

.footer {
    background-color: var(--footer-bg);
    backdrop-filter: blur(5px);
    color: var(--footer-text);
    padding: 2rem 0;
    margin-top: auto;
    position: relative;
    z-index: 2;
    transition: background-color 0.3s ease;
}

.social-icons {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    margin-bottom: 1rem;
}

.social-icons a {
    color: var(--footer-text);
    font-size: 1.5rem;
    transition: transform 0.3s ease, color 0.3s ease;
}

.social-icons a:hover {
    transform: translateY(-5px);
    color: #17a2b8;
}

.footer-bottom {
    text-align: center;
    padding-top: 1rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    font-size: clamp(0.8rem, 2vw, 1rem);
}

.cursor, .cursor2 {
    position: fixed;
    border-radius: 50%;
    pointer-events: none;
    transform: translate(-50%, -50%);
}

.cursor {
    width: 8px;
    height: 8px;
    background-color: var(--text-color);
    z-index: 10000;
    transition: background-color 0.3s ease;
}

.cursor2 {
    width: 35px;
    height: 35px;
    border: 2px solid rgba(51, 51, 51, 0.5);
    z-index: 9999;
    transition: all 0.3s ease;
}

.dark-mode .cursor2 {
    border: 2px solid rgba(255, 255, 255, 0.5);
}
a{
    text-decoration: none;
}

/* Mobile responsiveness */
@media (max-width: 768px) {
    header {
        padding: 0.75rem;
    }

    .header-logo {
        max-width: 100px;
    }

    .wrapper {
        margin-top: 90px;
    }

    .typewriter {
        white-space: normal;
        border-right: none;
        animation: fadeIn 1s ease forwards;
        text-align: center;
        padding: 0 0.5rem;
    }

    @keyframes fadeIn {
        from {
            opacity: 0;
        }
        to {
            opacity: 1;
        }
    }
}

@media (max-width: 480px) {
    .header-right a {
        font-size: 0.8rem;
        padding: 0.4rem;
    }

    .theme-toggle {
        width: 32px;
        height: 32px;
        font-size: 1rem;
    }
}

@keyframes slideDown {
    from {
        transform: translateY(-100%);
    }
    to {
        transform: translateY(0);
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(50px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes typing {
    from { width: 0 }
    to { width: 100% }
}

@keyframes blink-caret {
    from, to { border-color: transparent }
    50% { border-color: var(--text-color) }
}