/* ── CSS VARIABLES ── */
:root {
    /* Renkler */
    --color-bg: #ffffff;
    --color-bg-alt: #f8fafc;
    --color-text: #1e293b;
    --color-text-muted: #64748b;
    --color-primary: #2563eb;
    --color-primary-hover: #1d4ed8;
    --color-border: #e2e8f0;
    
    /* Tipografi */
    --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    --font-mono: 'SF Mono', 'Fira Code', monospace;
    
    /* Boyutlar */
    --container-width: 1100px;
    --section-padding: 6rem 1.5rem;
    --border-radius: 8px;
    
    /* Animasyon */
    --transition: 200ms ease;
}

@media (prefers-color-scheme: dark) {
    :root {
        --color-bg: #0f172a;
        --color-bg-alt: #1e293b;
        --color-text: #f1f5f9;
        --color-text-muted: #94a3b8;
        --color-border: #334155;
    }
}

/* ── RESET & BASE ── */
*, *::before, *::after {
    margin: 0; padding: 0; box-sizing: border-box;
}

html { scroll-behavior: smooth; }

body {
    font-family: var(--font-sans);
    background: var(--color-bg);
    color: var(--color-text);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

/* Erişilebilirlik */
.skip-link {
    position: absolute;
    top: -40px; left: 0;
    background: var(--color-primary);
    color: white;
    padding: 0.5rem 1rem;
    z-index: 1000;
    transition: top var(--transition);
}
.skip-link:focus { top: 0; }

:focus-visible {
    outline: 2px solid var(--color-primary);
    outline-offset: 2px;
}

/* ── UTILITIES ── */
.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 1.5rem;
}

.section { padding: var(--section-padding); }
.section-alt { background: var(--color-bg-alt); }

.section-title {
    font-size: 1.75rem;
    font-weight: 700;
    margin-bottom: 2.5rem;
    position: relative;
    padding-bottom: 0.75rem;
}
.section-title::after {
    content: '';
    position: absolute;
    bottom: 0; left: 0;
    width: 3rem;
    height: 3px;
    background: var(--color-primary);
    border-radius: 2px;
}

.section-intro {
    max-width: 720px;
    margin: -1rem 0 2.5rem;
    color: var(--color-text-muted);
}

/* ── BUTTONS ── */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    border-radius: var(--border-radius);
    font-weight: 500;
    text-decoration: none;
    transition: all var(--transition);
    cursor: pointer;
    border: none;
    font-size: 0.95rem;
}

.btn-primary {
    background: var(--color-primary);
    color: white;
}
.btn-primary:hover {
    background: var(--color-primary-hover);
    transform: translateY(-2px);
}

.btn-outline {
    background: transparent;
    color: var(--color-text);
    border: 1px solid var(--color-border);
}
.btn-outline:hover {
    border-color: var(--color-primary);
    color: var(--color-primary);
}

/* ── NAVBAR ── */
.navbar {
    position: sticky; top: 0;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--color-border);
    z-index: 100;
    padding: 1rem 0;
}
@media (prefers-color-scheme: dark) {
    .navbar { background: rgba(15, 23, 42, 0.9); }
}

.nav-container {
    display: flex; justify-content: space-between; align-items: center;
}

.logo {
    font-weight: 700; font-size: 1.25rem;
    text-decoration: none; color: var(--color-text);
}
.logo span { color: var(--color-primary); }

.nav-menu {
    display: flex; gap: 2rem; list-style: none;
}
.nav-menu a {
    text-decoration: none; color: var(--color-text-muted);
    font-weight: 500; transition: color var(--transition);
}
.nav-menu a:hover, .nav-menu a.active { color: var(--color-primary); }

.nav-toggle { display: none; background: none; border: none; cursor: pointer; }
.hamburger {
    display: block; width: 24px; height: 2px;
    background: var(--color-text); position: relative;
}
.hamburger::before, .hamburger::after {
    content: ''; position: absolute; left: 0;
    width: 24px; height: 2px; background: var(--color-text);
}
.hamburger::before { top: -8px; }
.hamburger::after { top: 8px; }

/* ── HERO ── */
.hero {
    padding: 8rem 1.5rem 6rem;
    text-align: center;
}
.hero-greeting {
    font-family: var(--font-mono);
    color: var(--color-primary);
    margin-bottom: 1rem;
}
.hero-title {
    font-size: clamp(2.5rem, 5vw, 3.5rem);
    font-weight: 700;
    margin-bottom: 1rem;
    line-height: 1.1;
}
.hero-subtitle {
    font-size: 1.1rem;
    color: var(--color-text-muted);
    max-width: 600px;
    margin: 0 auto 2rem;
}
.hero-actions {
    display: flex; gap: 1rem; justify-content: center; flex-wrap: wrap;
}

/* ── ABOUT ── */
.about-grid {
    display: grid; gap: 2rem;
    grid-template-columns: 1fr;
}
@media (min-width: 768px) {
    .about-grid { grid-template-columns: 2fr 1fr; }
}
.about-text p { margin-bottom: 1rem; color: var(--color-text-muted); }
.about-stats {
    display: grid; gap: 1.5rem;
    padding: 1.5rem;
    background: var(--color-bg-alt);
    border-radius: var(--border-radius);
    border: 1px solid var(--color-border);
}
.stat-number {
    display: block;
    font-size: 2rem; font-weight: 700;
    color: var(--color-primary);
}
.stat-label {
    font-size: 0.9rem; color: var(--color-text-muted);
}

/* ── SKILLS ── */
.skills-grid {
    display: grid; gap: 2rem;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
}
.skill-category h3 {
    font-size: 1.1rem; margin-bottom: 1rem; color: var(--color-text);
}
.skill-tags {
    display: flex; flex-wrap: wrap; gap: 0.5rem;
}
.skill-tag {
    font-family: var(--font-mono);
    font-size: 0.8rem;
    padding: 0.35rem 0.75rem;
    background: var(--color-bg-alt);
    border: 1px solid var(--color-border);
    border-radius: 4px;
    color: var(--color-text-muted);
}

/* ── PROJECTS ── */
.projects-grid {
    display: grid; gap: 2rem;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
}
.project-card {
    background: var(--color-bg);
    border: 1px solid var(--color-border);
    border-radius: var(--border-radius);
    overflow: hidden;
    transition: transform var(--transition), box-shadow var(--transition);
}
.project-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.08);
}
.project-content {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    padding: 1.5rem;
}
.project-content h3 {
    font-size: 1.15rem;
    line-height: 1.3;
}
.project-content p {
    color: var(--color-text-muted);
}
/* ── PROJECT IMAGES (Tüm görsel görünsün) ── */
.project-image {
    aspect-ratio: 16/9;
    background: var(--color-bg-alt);
    overflow: hidden;
}

.project-image img {
    width: 100%; 
    height: 100%;
    object-fit: cover;              
    object-position: center top;    
    transition: transform 300ms ease;
}


.project-card:hover .project-image {
    border-color: var(--color-primary);
}
.project-tech {
    display: flex; flex-wrap: wrap; gap: 0.5rem;
    margin-bottom: 1rem;
}
.project-tech span {
    font-family: var(--font-mono);
    font-size: 0.75rem;
    color: var(--color-primary);
    background: rgba(37, 99, 235, 0.1);
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
}
.project-links {
    display: flex; gap: 1rem; flex-wrap: wrap;
}
.project-links a {
    font-size: 0.9rem; font-weight: 500;
    text-decoration: none; color: var(--color-text);
    transition: color var(--transition);
}
.project-links a:hover { color: var(--color-primary); }

/* ── CONTACT ── */
.contact-container { text-align: center; }
.contact-text {
    color: var(--color-text-muted);
    max-width: 600px;
    margin: 0 auto 2.5rem;
}
.contact-links {
    display: flex; flex-direction: column; gap: 1rem;
    max-width: 400px; margin: 0 auto;
}
.contact-link {
    display: flex; align-items: center; gap: 0.75rem;
    padding: 1rem;
    background: var(--color-bg);
    border: 1px solid var(--color-border);
    border-radius: var(--border-radius);
    text-decoration: none;
    color: var(--color-text);
    transition: all var(--transition);
}
.contact-link:hover {
    border-color: var(--color-primary);
    transform: translateX(4px);
}
.contact-link .icon { font-size: 1.2rem; }

/* ── FOOTER ── */
.footer {
    padding: 2rem 1.5rem;
    border-top: 1px solid var(--color-border);
    text-align: center;
    font-size: 0.9rem;
    color: var(--color-text-muted);
}
.footer a { color: var(--color-primary); text-decoration: none; }
.footer-note { margin-top: 0.5rem; font-size: 0.85rem; }

/* ── RESPONSIVE ── */
@media (max-width: 768px) {
    .nav-toggle { display: block; }
    
    .nav-menu {
        position: fixed;
        top: 70px; left: 0; right: 0;
        background: var(--color-bg);
        flex-direction: column;
        padding: 2rem;
        border-bottom: 1px solid var(--color-border);
        transform: translateY(-150%);
        transition: transform var(--transition);
    }
    .nav-menu.active { transform: translateY(0); }
    
    .hero-actions { flex-direction: column; align-items: center; }
    .btn { width: 100%; justify-content: center; }
}

/* ── ANIMATIONS (Subtle) ── */
@media (prefers-reduced-motion: no-preference) {
    .project-card {
        animation: fadeInUp 0.5s ease both;
    }
    .project-card:nth-child(2) { animation-delay: 0.1s; }
    .project-card:nth-child(3) { animation-delay: 0.2s; }
    
    @keyframes fadeInUp {
        from { opacity: 0; transform: translateY(20px); }
        to { opacity: 1; transform: translateY(0); }
    }
}
/* ── PROJECT ANIMATIONS (6 kart için) ── */
@media (prefers-reduced-motion: no-preference) {
    .project-card {
        opacity: 0;
        transform: translateY(20px);
        animation: fadeInUp 0.5s ease forwards;
    }
    
    /* Tüm 6 kart için stagger delay */
    .project-card:nth-child(1) { animation-delay: 0.0s; }
    .project-card:nth-child(2) { animation-delay: 0.1s; }
    .project-card:nth-child(3) { animation-delay: 0.2s; }
    .project-card:nth-child(4) { animation-delay: 0.3s; }  
    .project-card:nth-child(5) { animation-delay: 0.4s; }  
    .project-card:nth-child(6) { animation-delay: 0.5s; }  
    .project-card:nth-child(7) { animation-delay: 0.6s; }  
    @keyframes fadeInUp {
        to { opacity: 1; transform: translateY(0); }
    }
}
