html, body {
    margin: 0;
    padding: 0;
    height: 100%;
    overflow-x: hidden; /* Yatay kaydırmayı engelle */
    scroll-behavior: smooth;
}

* {
    box-sizing: border-box;
}

:root {
    /* Açık Tema Renkleri */
    --primary-color: #007BFF;
    --secondary-color: #343a40;
    --background-color: #ffffff;
    --text-color: #6c757d;
    --link-color: #0056b3;
    --container-bg: rgba(255, 255, 255, 0.5);
    --shadow-color: rgba(0, 0, 0, 0.1);
    --icon-color: #343a40;
    --button-text-color: #343a40;
}

/* Karanlık Tema Renkleri */
.dark-mode {
    --primary-color: #00aaff;
    --secondary-color: #f8f9fa;
    --background-color: #212529;
    --text-color: lightgray;
    --link-color: #4da6ff;
    --container-bg: rgba(52, 58, 64, 0.5);
    --shadow-color: rgba(255, 255, 255, 0.1);
    --icon-color: #e9ecef;
    --button-text-color: #e9ecef;
}

html, body {
    margin: 0;
    padding: 0;
    height: 100%;
    overflow-x: hidden;
    scroll-behavior: smooth;
}

body {
    font-family: 'Roboto', sans-serif;
    background-color: var(--background-color);
    color: var(--text-color);
    line-height: 1.8;
    font-size: 1.1em;
    position: relative;
    transition: background-color 0.3s ease, color 0.3s ease;
}

#particles-js {
    position: fixed;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    z-index: -1;
}

.content-wrapper {
    display: flex;
    width: 400vw;
    height: 100%;
    transition: transform 0.5s ease-in-out;
    margin-top: 0;
    z-index: 5;
}

section {
    width: 100vw;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    padding: 40px 20px;
    box-sizing: border-box;
    background-color: var(--container-bg);
    box-shadow: 0 4px 6px var(--shadow-color);
    transition: background-color 0.3s ease, box-shadow 0.3s ease;
    overflow-y: auto;
    text-align: center;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Poppins', sans-serif;
    color: var(--secondary-color);
    transition: color 0.3s ease;
}

#anasayfa {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    min-height: 100vh;
}

#anasayfa header {
    text-align: center;
}

#anasayfa h1 {
    font-size: 2.5em;
    margin-bottom: 5px;
}

#anasayfa p {
    color: var(--primary-color);
    font-size: 1.2em;
    font-weight: bold;
}

#anasayfa .profile-image {
    width: 250px;
    height: 250px;
    border-radius: 50%;
    object-fit: cover;
    margin-bottom: 20px;
    border: 5px solid var(--primary-color);
    box-shadow: 0 0 20px var(--shadow-color);
    transition: all 0.3s ease-in-out;
}

#anasayfa .social-links {
    margin-top: 20px;
    display: flex;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap;
}

h2 {
    border-bottom: 2px solid var(--primary-color);
    padding-bottom: 5px;
    margin-top: 0;
    font-size: 2em;
}

p {
    margin-bottom: 1.5em;
}

.portfolio-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: stretch;
    gap: 20px;
    overflow-x: hidden;
    padding: 20px;
}

.portfolio-item {
    background-color: var(--container-bg);
    padding: 20px;
    border-radius: 15px;
    box-shadow: 0 0 8px 2px var(--primary-color);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    min-width: 280px;
    max-width: 350px;
    flex: 1 1 45%;
    box-sizing: border-box;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
    overflow: hidden;
    gap: 15px;
}

.portfolio-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 0 16px 4px var(--primary-color);
}

.logo-area {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.portfolio-logo {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid var(--primary-color);
    box-shadow: 0 2px 8px var(--shadow-color);
}

@media (max-width: 768px) {
    .portfolio-logo {
        width: 80px;
        height: 80px;
    }
}

.portfolio-date {
    font-size: 0.8em;
    color: var(--text-color);
    font-style: italic;
    margin-top: 5px;
    text-align: center;
}

.portfolio-text {
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    text-align: center;
}

.portfolio-item h3 {
    text-align: center;
    margin-top: 0;
    margin-bottom: 0.2em;
    font-size: 1.1em;
}

.portfolio-item h5 {
    text-align: center;
    margin-top: 0;
    margin-bottom: 0.5em;
    font-size: 0.9em;
    color: var(--text-color);
}

.portfolio-item p {
    font-size: 0.9em;
    line-height: 1.5;
    margin-top: 0;
    margin-bottom: 0;
    text-align: center;
}

.skills-list {
    list-style: none;
    padding: 0;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: center;
}

.skills-list li {
    background-color: var(--primary-color);
    color: white;
    padding: 8px 15px;
    border-radius: 20px;
    font-weight: bold;
    font-size: 0.9em;
}

#iletisim p {
    font-size: 1.2em;
    margin-bottom: 0.8em;
    line-height: 1.5;
}

.social-links a {
    color: var(--link-color);
    text-decoration: none;
    margin: 0 10px;
    transition: color 0.3s ease;
}

.social-links a:hover {
    text-decoration: underline;
}

.page-header {
    position: fixed;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 100;
    padding: 0;
}

.navbar {
    background-color: var(--container-bg);
    border-radius: 50px;
    box-shadow: 0 2px 10px var(--shadow-color);
    padding: 10px 20px;
    transition: all 0.5s ease-in-out, background-color 0.3s ease, box-shadow 0.3s ease;
}

.nav-menu {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    gap: 20px;
}

.nav-menu a {
    text-decoration: none;
    color: var(--secondary-color);
    font-family: 'Poppins', sans-serif;
    font-weight: bold;
    padding: 5px 10px;
    border-radius: 20px;
    transition: background-color 0.3s ease, color 0.3s ease;
}

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

.menu-toggle {
    display: none;
}

/* Masaüstü için sabit tema düğmesi */
.theme-toggle {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 101;
    display: flex;
    align-items: center;
    gap: 10px;
}

/* Mobil için menü içindeki tema düğmesi */
.theme-toggle-mobile {
    display: none; /* Masaüstü görünümde gizli */
}

.theme-toggle-btn {
    width: 40px;
    height: 40px;
    background-color: transparent;
    border: 2px solid var(--icon-color);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: border-color 0.3s ease;
    cursor: pointer;
}

.theme-toggle-btn svg {
    fill: var(--icon-color);
    width: 20px;
    height: 20px;
    transition: fill 0.3s ease;
}

/* Butonun anlasilir olmasi icin ikon gorunurlugu */
.light-mode .dark-mode-icon {
    display: none;
}

.dark-mode:not(.light-mode) .light-mode-icon {
    display: none;
}

.theme-text {
    display: none;
}

footer {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    height: auto;
    text-align: center;
    color: var(--text-color);
    font-size: 0.8em;
    opacity: 0.7;
    padding: 5px 0;
    background-color: transparent;
    box-shadow: none;
    transition: background-color 0.3s ease, color 0.3s ease;
    z-index: 99;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

/* FOOTER LİNK STİLİ */
footer a {
    color: inherit; /* Metnin rengini miras al */
    text-decoration: none; /* Alt çizgiyi kaldır */
    transition: color 0.3s ease;
}

footer a:hover {
    color: var(--primary-color); /* Fare üzerine geldiğinde ana renk */
    text-decoration: underline; /* Fare üzerine geldiğinde alt çizgi */
}

.custom-scrollbar-container {
    position: fixed;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 70vw;
    height: 4px;
    background-color: rgba(0, 0, 0, 0.2);
    border-radius: 2px;
    z-index: 100;
}

.custom-scrollbar-thumb {
    height: 100%;
    background-color: var(--primary-color);
    border-radius: 2px;
    transition: transform 0.3s ease, width 0.3s ease;
}

@media (max-width: 768px) {
    /* Menü açıldığında sayfa kaydırmasını engelleme */
    body.menu-open {
        overflow: hidden;
    }

    .page-header {
        transform: translateY(-100%);
        transition: transform 0.4s ease-in-out;
        box-shadow: none;
        position: fixed;
        width: 100%;
        top: 0;
        left: 0;
        height: 100%;
        z-index: 1000;
        background-color: var(--background-color);
    }

    .page-header.open {
        transform: translateY(0);
    }

    .navbar {
        background-color: transparent;
        box-shadow: none;
        padding: 0;
        height: 100%;
        display: flex;
        flex-direction: column;
        justify-content: center;
    }

    .nav-menu {
        flex-direction: column;
        justify-content: center;
        align-items: center;
        margin: 0;
        padding: 0;
        width: 100%;
    }

    .nav-menu a {
        font-size: 1.5em;
        padding: 15px 30px;
        width: 100%;
        text-align: center;
        border-radius: 0;
    }

    .nav-menu a.active {
        background-color: var(--primary-color);
        color: white;
    }

    /* Tam Ekran Menü Arka Planı (Overlay) */
    .menu-overlay {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: rgba(0, 0, 0, 0.5);
        z-index: 999;
        opacity: 0;
        visibility: hidden;
        transition: opacity 0.4s ease-in-out, visibility 0.4s ease-in-out;
    }

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

    /* Mobil için menü içi tema düğmesi */
    .theme-toggle-mobile {
        display: flex;
        justify-content: center;
        align-items: center;
        margin-top: 20px;
        flex-direction: row;
        gap: 10px;
    }

    .theme-text {
        display: flex;
        color: var(--secondary-color);
        font-weight: bold;
    }

    .theme-toggle-btn {
        background-color: var(--container-bg);
    }

    .menu-toggle {
        display: block;
        position: fixed;
        bottom: 20px;
        right: 20px;
        z-index: 1001;
        width: 60px;
        height: 60px;
        background-color: var(--primary-color);
        border: none;
        border-radius: 50%;
        cursor: pointer;
        display: flex;
        justify-content: center;
        align-items: center;
        box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
        transition: background-color 0.3s ease;
    }

    .menu-toggle.active {
        background-color: var(--secondary-color);
    }

    .hamburger,
    .hamburger::before,
    .hamburger::after {
        content: '';
        display: block;
        width: 30px;
        height: 3px;
        background-color: #fff;
        transition: transform 0.3s ease-in-out, background-color 0.3s ease-in-out;
    }

    .hamburger {
        position: relative;
        top: 0;
    }

    .hamburger::before {
        position: absolute;
        top: -10px;
    }

    .hamburger::after {
        position: absolute;
        top: 10px;
    }

    .menu-toggle.active .hamburger {
        background-color: transparent;
    }

    .menu-toggle.active .hamburger::before {
        transform: rotate(45deg) translate(7px, 7px);
    }

    .menu-toggle.active .hamburger::after {
        transform: rotate(-45deg) translate(7px, -7px);
    }

    .theme-toggle {
        display: none;
    }

    footer {
        position: relative;
        bottom: auto;
        left: auto;
        transform: none;
        padding: 20px;
        box-shadow: 0 -2px 5px rgba(0, 0, 0, 0.1);
        background-color: var(--container-bg);
    }

    .custom-scrollbar-container {
        display: none;
    }

    .content-wrapper {
        width: 100vw;
        display: block;
        transform: none !important;
        height: auto;
    }

    section {
        height: auto;
        min-height: 100vh;
        overflow-y: visible;
    }
}