:root {
  --bg: #070b14;
  --bg-alt: rgba(8, 12, 22, 0.78);
  --card: rgba(15, 23, 42, 0.86);
  --border: rgba(255, 255, 255, 0.11);
  --text: #f1f5f9;
  --text-muted: #c2cedc;
  --accent: #38bdf8;
  --accent-strong: #0284c7;
  --terminal: #22c55e;
  --nav-bg: rgba(7, 11, 20, 0.85);
  --shadow: 0 14px 36px rgba(0, 0, 0, 0.45);
}

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

html {
  scroll-behavior: smooth;
  overflow-x: clip;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  background-color: var(--bg);
  color: var(--text);
  line-height: 1.65;
  position: relative;
  overflow-x: clip;
}

/* Tüm sayfanın arkasına sabitlenmiş penguenli terminal görseli */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  background: url('../img/linux_terminal_wallpaper.png') center center / cover no-repeat;
  z-index: -2;
  pointer-events: none;
}

/* Okunabilirliği artıran koyu katman */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  background: linear-gradient(
    180deg,
    rgba(6, 9, 17, 0.48) 0%,
    rgba(6, 9, 17, 0.72) 50%,
    rgba(6, 9, 17, 0.88) 100%
  );
  z-index: -1;
  pointer-events: none;
}

.container {
  width: 100%;
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 1.25rem;
}

a { color: inherit; text-decoration: none; }

code {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.88em;
}

/* Üst Menü */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: var(--nav-bg);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}

.nav-container {
  height: 68px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-family: 'JetBrains Mono', monospace;
  font-weight: 600;
  font-size: 1rem;
  min-width: 0;
}

.brand-logo {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  object-fit: cover;
  background: #ffffff;
  padding: 2px;
  flex-shrink: 0;
}

.accent { color: var(--accent); }

.nav-links {
  display: flex;
  gap: 1.5rem;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text-muted);
}

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

.menu-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: transparent;
  border: 0;
  cursor: pointer;
  padding: 4px;
  flex-shrink: 0;
}

.menu-toggle span {
  width: 22px;
  height: 2px;
  background: var(--text);
  border-radius: 2px;
}

/* Hero Bölümü (Ortalanmış) */
.hero {
  position: relative;
  min-height: 92vh;
  min-height: 100svh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 6rem 0 3.5rem;
}

.hero-content {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: 780px;
  margin: 0 auto;
  text-align: center;
  background: rgba(10, 15, 28, 0.76);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 2.5rem 2.5rem;
  backdrop-filter: blur(12px);
  box-shadow: var(--shadow);
}

.terminal-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  max-width: 100%;
  padding: 0.4rem 0.9rem;
  border-radius: 999px;
  background: rgba(7, 11, 20, 0.78);
  border: 1px solid var(--border);
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-bottom: 1.25rem;
}

.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--terminal);
  box-shadow: 0 0 8px var(--terminal);
  flex-shrink: 0;
}

.hero-title {
  font-size: clamp(2rem, 5.5vw, 3.6rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.15;
  min-height: 1.15em;
  margin-bottom: 0.85rem;
}

.hero-subtitle {
  font-family: 'JetBrains Mono', monospace;
  font-size: clamp(0.9rem, 3.2vw, 1.08rem);
  color: var(--accent);
  min-height: 1.75em;
  margin-bottom: 1.2rem;
}

.prompt-prefix {
  color: var(--terminal);
  margin-right: 0.45rem;
  font-weight: 600;
}

.cursor-blink {
  color: var(--terminal);
  font-weight: 400;
  animation: blink 0.9s steps(1) infinite;
}

@keyframes blink {
  0%, 50% { opacity: 1; }
  51%, 100% { opacity: 0; }
}

.hero-desc {
  font-size: 1.03rem;
  color: #dbe4ef;
  max-width: 640px;
  margin: 0 auto 1.85rem;
}

.hero-buttons {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.85rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.75rem 1.4rem;
  border-radius: 10px;
  font-weight: 600;
  font-size: 0.92rem;
  transition: transform 0.15s ease, background-color 0.2s ease;
}

.btn:hover { transform: translateY(-2px); }

.btn-primary {
  background: var(--accent);
  color: #070b14;
}

.btn-outline {
  border: 1px solid var(--border);
  background: rgba(7, 11, 20, 0.75);
  color: var(--text);
}

/* Bölümler */
.section { padding: 5rem 0; }

.section-alt {
  background: var(--bg-alt);
  backdrop-filter: blur(5px);
}

.section-header {
  margin-bottom: 2.5rem;
  text-align: center;
}

.section-tag {
  display: inline-block;
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.82rem;
  color: var(--accent);
  margin-bottom: 0.4rem;
}

.section-header h2 {
  font-size: clamp(1.55rem, 3.5vw, 1.95rem);
  font-weight: 700;
  letter-spacing: -0.02em;
}

.section-sub {
  color: var(--text-muted);
  margin: 0.4rem auto 0;
  max-width: 580px;
}

/* Hakkımda */
.about-grid {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 2.25rem;
  align-items: start;
}

.about-photo-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 0.65rem;
  box-shadow: var(--shadow);
  backdrop-filter: blur(10px);
}

.about-photo {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  border-radius: 12px;
  display: block;
}

.about-text {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 1.75rem;
  backdrop-filter: blur(10px);
}

.about-text p { color: var(--text-muted); margin-bottom: 1.1rem; }
.about-text strong { color: var(--text); }

.edu-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr));
  gap: 1rem;
  margin-top: 1.5rem;
}

.edu-item {
  background: rgba(7, 11, 20, 0.65);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1rem 1.15rem;
}

.edu-year {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.78rem;
  color: var(--accent);
  display: block;
  margin-bottom: 0.35rem;
}

.edu-item h4 { font-size: 0.98rem; margin-bottom: 0.15rem; }
.edu-item p { font-size: 0.88rem; margin-bottom: 0; }

/* Deneyim Zaman Çizelgesi */
.timeline {
  position: relative;
  padding-left: 1.75rem;
  border-left: 2px solid var(--border);
  display: flex;
  flex-direction: column;
  gap: 1.75rem;
}

.timeline-item { position: relative; }

.timeline-dot {
  position: absolute;
  left: -2.22rem;
  top: 1.35rem;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--text-muted);
  border: 2px solid #0b0f17;
}

.timeline-dot.active {
  background: var(--terminal);
  box-shadow: 0 0 0 4px rgba(34, 197, 94, 0.25);
}

.timeline-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 1.4rem 1.55rem;
  backdrop-filter: blur(10px);
}

.timeline-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-bottom: 0.9rem;
}

.timeline-top h3 { font-size: 1.08rem; }
.company { color: var(--accent); font-size: 0.92rem; font-weight: 500; }

.date-badge {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.78rem;
  padding: 0.28rem 0.65rem;
  border-radius: 8px;
  background: rgba(7, 11, 20, 0.7);
  border: 1px solid var(--border);
  color: var(--text-muted);
}

.date-badge.current {
  color: var(--terminal);
  border-color: rgba(34, 197, 94, 0.4);
}

.timeline-card ul {
  padding-left: 1.15rem;
  color: var(--text-muted);
  font-size: 0.94rem;
}

.timeline-card li + li { margin-top: 0.45rem; }

/* Öne Çıkan Çalışmalar */
.highlights-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 290px), 1fr));
  gap: 1.25rem;
}

.highlight-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 1.5rem;
  border-top: 3px solid var(--accent);
  backdrop-filter: blur(10px);
}

.highlight-card h3 {
  font-size: 1.05rem;
  margin-bottom: 0.65rem;
}

.highlight-card p {
  color: var(--text-muted);
  font-size: 0.93rem;
}

/* Tech Stack */
.skills-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 290px), 1fr));
  gap: 1.25rem;
}

.skill-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 1.35rem;
  backdrop-filter: blur(10px);
}

.skill-card h3 { font-size: 1rem; margin-bottom: 1rem; }

.tags { display: flex; flex-wrap: wrap; gap: 0.48rem; }

.tags span {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.78rem;
  padding: 0.32rem 0.62rem;
  border-radius: 8px;
  background: rgba(7, 11, 20, 0.7);
  border: 1px solid var(--border);
  color: var(--text);
}

/* Galeri (Masonry - Dikey/Yatay kırpmasız) */
.gallery-filters {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.6rem;
  margin-bottom: 1.75rem;
}

.filter-btn {
  background: var(--card);
  border: 1px solid var(--border);
  color: var(--text-muted);
  padding: 0.45rem 0.95rem;
  border-radius: 999px;
  font-size: 0.85rem;
  font-weight: 500;
  cursor: pointer;
}

.filter-btn.active {
  background: var(--accent);
  color: #070b14;
  border-color: var(--accent);
}

.gallery-grid {
  column-count: 3;
  column-gap: 1.25rem;
}

.gallery-card {
  break-inside: avoid;
  margin-bottom: 1.25rem;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 14px;
  overflow: hidden;
  cursor: pointer;
  backdrop-filter: blur(10px);
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.gallery-card:hover { transform: translateY(-4px); border-color: var(--accent); }

.gallery-card img {
  width: 100%;
  height: auto;
  display: block;
}

.gallery-info { padding: 0.95rem 1.1rem; }
.gallery-info h4 { font-size: 0.98rem; margin-bottom: 0.2rem; }
.gallery-info p { font-size: 0.82rem; color: var(--text-muted); }

.gallery-empty {
  column-span: all;
  background: var(--card);
  border: 1px dashed var(--border);
  border-radius: 14px;
  padding: 2.5rem;
  text-align: center;
  color: var(--text-muted);
  backdrop-filter: blur(10px);
}

/* İletişim */
.contact-box {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 2.5rem;
  text-align: center;
  box-shadow: var(--shadow);
  backdrop-filter: blur(10px);
}

.contact-box p {
  color: var(--text-muted);
  max-width: 560px;
  margin: 0.75rem auto 1.75rem;
}

.contact-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.85rem;
}

.contact-pill {
  padding: 0.65rem 1.15rem;
  border-radius: 10px;
  background: rgba(7, 11, 20, 0.7);
  border: 1px solid var(--border);
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.85rem;
  word-break: break-word;
  transition: border-color 0.2s ease, color 0.2s ease;
}

.contact-pill:hover { border-color: var(--accent); color: var(--accent); }

.footer {
  background: rgba(7, 11, 20, 0.85);
  border-top: 1px solid var(--border);
  padding: 1.75rem 0;
  text-align: center;
  color: var(--text-muted);
  font-size: 0.88rem;
}

/* Lightbox */
.lightbox {
  position: fixed;
  inset: 0;
  background: rgba(5, 8, 15, 0.92);
  z-index: 200;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
}

.lightbox.open { display: flex; }

.lightbox-content {
  max-width: 960px;
  max-height: 90vh;
  text-align: center;
}

.lightbox-content img {
  max-width: 100%;
  max-height: 75vh;
  border-radius: 12px;
  object-fit: contain;
}

.lightbox-caption { margin-top: 0.9rem; color: #f8fafc; }
.lightbox-caption p { color: #cbd5e1; font-size: 0.9rem; }

.lightbox-close,
.lightbox-nav {
  position: absolute;
  background: rgba(255, 255, 255, 0.14);
  border: 0;
  color: #ffffff;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  font-size: 1.4rem;
  cursor: pointer;
}

.lightbox-close { top: 1.25rem; right: 1.25rem; }
.lightbox-prev { left: 1.25rem; }
.lightbox-next { right: 1.25rem; }

/* Tablet ve Mobil Ölçekleme */
@media (max-width: 900px) {
  .gallery-grid { column-count: 2; }
}

@media (max-width: 768px) {
  .section { padding: 3.5rem 0; }

  .nav-links {
    position: absolute;
    top: 68px;
    left: 0;
    right: 0;
    background: rgba(7, 11, 20, 0.96);
    border-bottom: 1px solid var(--border);
    flex-direction: column;
    padding: 1.25rem;
    gap: 1rem;
    display: none;
  }

  .nav-links.active { display: flex; }
  .menu-toggle { display: flex; }

  .hero { padding: 5.5rem 0 2.75rem; }
  .hero-content { padding: 1.6rem 1.25rem; border-radius: 16px; }
  .terminal-badge { font-size: 0.72rem; padding: 0.35rem 0.75rem; }
  .hero-desc { font-size: 0.96rem; }

  .about-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .about-photo-card {
    max-width: 240px;
    margin: 0 auto;
  }

  .about-text { padding: 1.35rem; }

  .timeline { padding-left: 1.2rem; }
  .timeline-dot { left: -1.65rem; }
  .timeline-card { padding: 1.15rem 1.2rem; }

  .contact-box { padding: 1.75rem 1.25rem; }

  .lightbox { padding: 1rem; }
  .lightbox-close,
  .lightbox-nav { width: 38px; height: 38px; font-size: 1.2rem; }
  .lightbox-prev { left: 0.65rem; }
  .lightbox-next { right: 0.65rem; }
}

@media (max-width: 560px) {
  .gallery-grid { column-count: 1; }

  .hero-buttons {
    flex-direction: column;
  }

  .hero-buttons .btn {
    width: 100%;
  }
}