/* Root genel ayarlar */

:root {
    --primary-color: #2196F3;
    --secondary-color: #E3F2FD;
    --text-color: #333;
    --light-bg: #FFFFFF;
    --light-grey: #F5F5F5;
    --border-color: #DDD;
}

/* margin ve paddingleri sifirlar */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* body ayarlari */

body {
    font-family: 'Arial', sans-serif;
    line-height: 1,6;
    color: var(--text-color);
    background-color: var(--light-bg);
    scroll-behavior: smooth;
}

/* icerik genisligini sinirlayan ve ortalayan kapsayici sinif */

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* baslik stilleri */

h1, h2, h3 {
    color: var(--primary-color);
    margin-bottom: 15px;
}

h1 {
    font-size: 3,5em;
}

h2 {
    font-size: 2.5em;
    text-align: center;
    margin-bottom: 40px;
}

h3 {
    font-size: 1.8em;
}

/* buton stilleri */

.btn {
    display: inline-block;
    background-color: var(--primary-color);
    color: var(--light-bg);
    padding: 12px 25px;
    text-decoration: none;
    border-radius: 5px;
    transition: background-color 0.3s ease;
    border: none;
    cursor: pointer;
}

.btn:hover {
    background-color: #1976D2;
}

/* navigasyon menusu (header) stilleri */

header {
    background-color: var(--light-bg);
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.nav-brand {
    font-size: 1.8em;
    color: var(--primary-color);
    text-decoration: none;
    font-weight: bold;
    margin-right: 100px;
}

.nav-links {
    list-style: none;
    display: flex;    
}

.nav-links li {
    list-style: none;
    display: flex;
    margin-left: 20px;
}

.nav-links a {
    color: var(--text-color);
    text-decoration: none;
    font-weight: 500;
    transition: 0.3s ease;
}

.nav-links a:hover {
    color: var(--primary-color);
}

/* mobil icin ikon */

.burger {
    display: none;
    cursor: pointer;
}

.burger div {
    width: 25px;
    height: 3px;
    background-color: var(--text-color);
    margin: 5px;
    transition: 0.3s ease;
}

/* giris bolumu */

.hero-section {
    background-color: var(--secondary-color);
    color: var(--text-color);
    height: 80vh;
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 0 20px;
    background-image: url('images/test.jpg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-attachment: fixed;
}

.hero-content {
    max-width: 800px;
}

.hero-content h1 {
    font-size: 3.5em;
    margin-bottom: 15px;
    color: var(--primary-color);
}

.hero-content p {
    font-size: 1.4em;
    margin-bottom: 30px;
}

/* bolumlerin ortak stilleri */
section {
    padding: 80px 0;;
}

section:nth-child(even) {
    background-color: var(--light-grey);
}

/* hakkimda bolumu */

.about-section .container {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 40px;
}

.about.text {
    flex: 2;
    min-width: 300px;
}

.about-image {
    flex: 1;
    min-width: 200px;
}

.about-image img {
    max-width: 25%;
    border-radius: 50px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

/* projeler bolumu */

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

.project-card {
    background-color: var(--light-bg);
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    transition: transform 0.3s ease;
    text-align: center;
    padding-bottom: 20px;
}

.project-card:hover {
    transform: translateY(-5px);
}

.project-card img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    display: block;
    border-bottom: 1px solid var(--border-color);
}

.project-card h3 {
    margin: 20px 0 10px;
    color: var(--primary-color);
}

.project-card p {
    padding: 0 20px;
    margin-bottom: 20px;
    font-size: 0.95em;
}

.project-card .github-link {
    display: inline-flex;
    align-items: center;
    color: var(--primary-color);
    text-decoration: none;
    font-weight: bold;
}

.project-card .github-link i {
    margin-right: 8px;
    font-size: 1.2em;
}

.project-card .github-link:hover {
    text-decoration: underline;
}

/* iletisim bolumu */

.contact-section {
    text-align: center;
}

.contact-links {
    margin-top: 30px;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 25px;
}

.contact-icon {
    display: flex;
    align-items: center;
    color: var(--text-color);
    text-decoration: none;
    font-size: 1.1em;
    transition: color 0.3s ease;
}

.contact-icon i {
    font-size: 1.8em;
    margin-right: 10px;
    color: var(--primary-color)
}

.contact-icon:hover {
    color: var(--primary-color);
}

/* sayfa sonu */

footer {
    background-color: var(--text-color);
    color: var(--light-bg);
    text-align: center;
    padding: 25px 0;
    font-size: 0.9em;
}

/* mobil uyumluluk */

@media (max-width: 768px) {
    .navbar {
        padding: 15px 20px;
    }

    .nav-links {
        position: fixed; /* Sabit konumda */
        right: 0;
        top: 60px; /* Header yüksekliğine göre ayarlanmalı */
        height: calc(100vh - 60px); /* Kalan ekran yüksekliği */
        background-color: var(--light-bg);
        display: flex;
        flex-direction: column; /* Linkleri alt alta sırala */
        align-items: center;
        width: 70%; /* Ekranın %70'ini kaplar */
        transform: translateX(100%); /* Başlangıçta ekranın dışında gizle */
        transition: transform 0.5s ease-in; /* Açılış animasyonu */
        box-shadow: -2px 0 5px rgba(0, 0, 0, 0.1); /* Gölge */
        padding-top: 50px;
    }

    .nav-links li {
        margin: 25px 0; /* Linkler arası boşluk */
    }

    .nav-links.nav-active {
        transform: translateX(0%); /* Menü açıldığında görünür yap */
    }

    .burger {
        display: block; /* Hamburger ikonunu göster */
    }

    .hero-content .welcome-image {
        max-width: 120px;
        height: auto;
        margin-bottom: 20px;
        border-radius: 50%;
        box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
    }

   
    .hero-content h1 {
        font-size: 2.5em; /* Mobil için başlığı küçült */
    }

    .hero-content p {
        font-size: 1.2em;
    }

    .about-section .container {
        flex-direction: column; /* Elemanları alt alta sırala */
        text-align: center;
    }

    .about-image {
        order: -1; /* Resmi metnin üstüne alır */
        margin-bottom: 20px;
    }

    .project-grid {
        grid-template-columns: 1fr; /* Projeleri tek sütun halinde göster */
    }

    .contact-links {
        flex-direction: column;
        align-items: center;
    }
}

/* Burger Animasyonu (JavaScript ile kontrol edilir) */
.toggle .line1 {
    transform: rotate(-45deg) translate(-5px, 6px);
}
.toggle .line2 {
    opacity: 0;
}
.toggle .line3 {
    transform: rotate(45deg) translate(-5px, -6px);
}

