/* Alperen Türker — portfolio
   ------------------------------------------------- */

:root {
  --bg: #0a0c11;
  --bg-alt: #0e1118;
  --surface: #12151d;
  --surface-2: #171b25;
  --line: #222736;
  --line-soft: #1a1e29;
  --text: #e9ecf3;
  --muted: #98a1b5;
  --muted-2: #6f7890;
  --accent: #5b8cff;
  --accent-2: #38d6c6;
  --accent-soft: rgba(91, 140, 255, .14);
  --radius: 16px;
  --radius-sm: 10px;
  --maxw: 1140px;
  --shadow: 0 20px 50px -24px rgba(0, 0, 0, .9);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; scroll-padding-top: 88px; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  font-size: 16px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
h1, h2, h3 { line-height: 1.2; letter-spacing: -.02em; margin: 0 0 .5em; font-weight: 700; }
p { margin: 0 0 1em; }
ul, ol { margin: 0; padding: 0; list-style: none; }

.wrap { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }

.skip {
  position: absolute; left: -9999px; top: 0; z-index: 100;
  background: var(--accent); color: #fff; padding: 10px 16px; border-radius: 0 0 8px 0;
}
.skip:focus { left: 0; }

/* ---------- nav ---------- */

.nav {
  position: sticky; top: 0; z-index: 50;
  background: rgba(10, 12, 17, .72);
  backdrop-filter: saturate(180%) blur(14px);
  -webkit-backdrop-filter: saturate(180%) blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color .25s ease, background .25s ease;
}
.nav.scrolled { border-bottom-color: var(--line-soft); }

.nav-inner { display: flex; align-items: center; gap: 24px; height: 72px; }

.brand { display: flex; align-items: center; gap: 12px; margin-right: auto; }
.brand-mark {
  width: 38px; height: 38px; flex: none;
  display: grid; place-items: center;
  border-radius: 11px;
  background: linear-gradient(140deg, var(--accent), var(--accent-2));
  color: #07090d; font-weight: 800; font-size: 14px; letter-spacing: -.02em;
}
.brand-text { display: flex; flex-direction: column; line-height: 1.25; }
.brand-text strong { font-size: 15px; font-weight: 650; letter-spacing: -.01em; }
.brand-text em { font-style: normal; font-size: 12px; color: var(--muted-2); }

.nav-links { display: flex; gap: 28px; }
.nav-links a {
  font-size: 14.5px; color: var(--muted); font-weight: 500;
  transition: color .18s ease;
}
.nav-links a:hover { color: var(--text); }

.lang { display: flex; gap: 2px; padding: 3px; border: 1px solid var(--line); border-radius: 999px; }
.lang button {
  border: 0; background: none; color: var(--muted-2); cursor: pointer;
  font: inherit; font-size: 12.5px; font-weight: 600; letter-spacing: .04em;
  padding: 4px 11px; border-radius: 999px; transition: .18s ease;
}
.lang button.on { background: var(--surface-2); color: var(--text); }
.lang button:hover { color: var(--text); }

.menu-btn { display: none; }

/* ---------- hero ---------- */

.hero { position: relative; padding: 96px 0 84px; overflow: hidden; }
.hero-bg {
  position: absolute; inset: -40% -20% auto; height: 760px; pointer-events: none;
  background:
    radial-gradient(48% 42% at 22% 42%, rgba(91, 140, 255, .20), transparent 70%),
    radial-gradient(38% 38% at 78% 30%, rgba(56, 214, 198, .13), transparent 70%);
  filter: blur(8px);
}

.hero-inner { position: relative; }

.eyebrow {
  display: inline-flex; align-items: center; gap: 9px;
  font-size: 13px; color: var(--muted); font-weight: 500;
  border: 1px solid var(--line); border-radius: 999px;
  padding: 6px 14px 6px 11px; margin: 0 0 26px;
  background: rgba(255, 255, 255, .02);
}
.dot {
  width: 7px; height: 7px; border-radius: 50%; background: var(--accent-2);
  box-shadow: 0 0 0 3px rgba(56, 214, 198, .16);
}

h1 {
  font-size: clamp(34px, 5.6vw, 60px);
  font-weight: 800; letter-spacing: -.035em;
  max-width: 17ch; margin-bottom: 24px;
}

.hero-lead { max-width: 62ch; color: var(--muted); font-size: 17.5px; }

.hero-cta { display: flex; flex-wrap: wrap; gap: 12px; margin: 30px 0 0; }

.btn {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 12px 22px; border-radius: 11px;
  font-size: 15px; font-weight: 600; letter-spacing: -.01em;
  border: 1px solid transparent; cursor: pointer;
  transition: transform .16s ease, background .18s ease, border-color .18s ease;
}
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--accent); color: #05070c; }
.btn-primary:hover { background: #7aa1ff; }
.btn-ghost { border-color: var(--line); color: var(--text); background: rgba(255, 255, 255, .015); }
.btn-ghost:hover { border-color: #333b50; background: rgba(255, 255, 255, .04); }
.btn.sm { padding: 9px 16px; font-size: 14px; border-radius: 9px; }

.stats {
  display: grid; grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px; margin-top: 60px;
  border-top: 1px solid var(--line-soft); padding-top: 30px;
}
.stats li { display: flex; flex-direction: column; gap: 3px; }
.stats strong {
  font-size: clamp(22px, 2.6vw, 30px); font-weight: 750; letter-spacing: -.03em;
  background: linear-gradient(120deg, var(--text), var(--muted));
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.stats span { font-size: 13.5px; color: var(--muted-2); }

/* ---------- sections ---------- */

.section { padding: 92px 0; border-top: 1px solid var(--line-soft); }
.section-alt { background: var(--bg-alt); }

.sec-head { max-width: 64ch; margin-bottom: 44px; }
.sec-kicker {
  font-size: 12.5px; font-weight: 700; letter-spacing: .13em; text-transform: uppercase;
  color: var(--accent); margin: 0 0 12px;
}
.sec-head h2 { font-size: clamp(26px, 3.6vw, 38px); letter-spacing: -.03em; }
.sec-lead { color: var(--muted); font-size: 16.5px; margin: 0; }

/* ---------- filters ---------- */

.filters { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 28px; }
.filters button {
  border: 1px solid var(--line); background: transparent; color: var(--muted);
  font: inherit; font-size: 13.5px; font-weight: 500; cursor: pointer;
  padding: 7px 15px; border-radius: 999px; transition: .18s ease;
}
.filters button:hover { color: var(--text); border-color: #333b50; }
.filters button.on { background: var(--accent-soft); border-color: rgba(91, 140, 255, .45); color: #b9cbff; }

/* ---------- app grid ---------- */

.grid {
  display: grid; gap: 16px;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
}

.app-card {
  display: flex; gap: 16px; align-items: flex-start;
  background: var(--surface);
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  padding: 18px;
  transition: transform .2s ease, border-color .2s ease, background .2s ease;
}
.app-card:hover {
  transform: translateY(-3px);
  border-color: #2c3346;
  background: var(--surface-2);
  box-shadow: var(--shadow);
}
.app-icon {
  width: 62px; height: 62px; flex: none;
  border-radius: 14px; border: 1px solid rgba(255, 255, 255, .07);
  background: #0c0e14;
}
.app-body { min-width: 0; flex: 1; }
.app-name {
  font-size: 15.5px; font-weight: 650; letter-spacing: -.015em; margin: 0 0 6px;
  display: flex; align-items: center; gap: 8px;
}
.app-desc { font-size: 13.8px; color: var(--muted); margin: 0 0 12px; line-height: 1.55; }
.app-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.chip {
  font-size: 11.5px; font-weight: 600; letter-spacing: .02em;
  padding: 3px 9px; border-radius: 6px;
  background: rgba(255, 255, 255, .045); color: var(--muted-2);
  border: 1px solid var(--line-soft);
}
.chip.ver { color: var(--muted-2); }
.app-link {
  margin-left: auto; font-size: 12.8px; font-weight: 600; color: var(--accent);
  white-space: nowrap; transition: color .18s ease;
}
.app-card:hover .app-link { color: #8fb0ff; }

.grid-note { margin: 30px 0 0; }
.link-arrow { font-size: 14.5px; font-weight: 600; color: var(--accent); }
.link-arrow:hover { color: #8fb0ff; }

/* ---------- pipeline ---------- */

.pipe-grid { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }
.pipe-card {
  background: var(--surface); border: 1px solid var(--line-soft);
  border-radius: var(--radius); padding: 22px;
}
.pipe-status {
  display: inline-flex; align-items: center; gap: 7px;
  font-size: 11.5px; font-weight: 600; letter-spacing: .04em; text-transform: uppercase;
  color: var(--accent-2); margin-bottom: 12px;
}
.pipe-status::before {
  content: ''; width: 6px; height: 6px; border-radius: 50%;
  background: var(--accent-2); box-shadow: 0 0 0 3px rgba(56, 214, 198, .15);
}
.pipe-card h3 { font-size: 17px; margin-bottom: 8px; }
.pipe-card p { font-size: 14px; color: var(--muted); margin: 0 0 14px; }
.pipe-tech { display: flex; flex-wrap: wrap; gap: 6px; }

/* ---------- about ---------- */

.about-grid { display: grid; grid-template-columns: 1.35fr .95fr; gap: 56px; align-items: start; }
.about-grid h2 { font-size: clamp(24px, 3.2vw, 34px); margin-bottom: 20px; }
.about-grid p { color: var(--muted); font-size: 16px; }
.about-cta { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 26px; }

.card-info {
  background: var(--surface); border: 1px solid var(--line-soft);
  border-radius: var(--radius); padding: 28px;
}
.card-info h3 { font-size: 15px; letter-spacing: .01em; margin-bottom: 18px; }
.ticks li {
  position: relative; padding-left: 26px; margin-bottom: 12px;
  font-size: 14.2px; color: var(--muted); line-height: 1.5;
}
.ticks li::before {
  content: ''; position: absolute; left: 0; top: 7px;
  width: 14px; height: 8px; border-left: 2px solid var(--accent-2);
  border-bottom: 2px solid var(--accent-2); transform: rotate(-45deg);
}

/* ---------- timeline ---------- */

.timeline { position: relative; padding-left: 0; }
.timeline > li {
  position: relative; display: grid; grid-template-columns: 220px 1fr; gap: 32px;
  padding: 28px 0; border-top: 1px solid var(--line-soft);
}
.timeline > li:first-child { border-top: 0; padding-top: 0; }
.tl-date { font-size: 13.5px; color: var(--muted-2); font-weight: 500; padding-top: 3px; }
.tl-body h3 { font-size: 18px; margin-bottom: 4px; }
.tl-body h3 span { color: var(--muted); font-weight: 500; font-size: 15.5px; letter-spacing: -.01em; }
.tl-meta { font-size: 13px; color: var(--muted-2); margin: 0 0 14px; }
.tl-body ul li {
  position: relative; padding-left: 18px; margin-bottom: 8px;
  font-size: 14.5px; color: var(--muted);
}
.tl-body ul li::before {
  content: ''; position: absolute; left: 2px; top: 10px;
  width: 5px; height: 5px; border-radius: 50%; background: #39415a;
}
.tl-proj { font-size: 13.5px; color: var(--muted-2); margin: 14px 0 0; }
.tl-proj span { color: var(--muted); font-weight: 600; }

/* ---------- skills ---------- */

.skills-grid { display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(270px, 1fr)); }
.skill-card {
  background: var(--surface); border: 1px solid var(--line-soft);
  border-radius: var(--radius-sm); padding: 20px 22px;
}
.skill-card h3 { font-size: 14.5px; margin-bottom: 8px; letter-spacing: -.01em; }
.skill-card p { font-size: 13.8px; color: var(--muted); margin: 0; line-height: 1.6; }

/* ---------- contact ---------- */

.contact-grid { display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
.contact-card {
  background: var(--surface); border: 1px solid var(--line-soft);
  border-radius: var(--radius); padding: 22px;
  display: flex; flex-direction: column; gap: 6px;
  transition: border-color .2s ease, transform .2s ease, background .2s ease;
}
.contact-card:not(.static):hover {
  border-color: #2c3346; transform: translateY(-2px); background: var(--surface-2);
}
.cc-label { font-size: 12px; letter-spacing: .09em; text-transform: uppercase; color: var(--muted-2); font-weight: 600; }
.contact-card strong { font-size: 15.5px; font-weight: 600; letter-spacing: -.01em; word-break: break-word; }

/* ---------- footer ---------- */

.footer { border-top: 1px solid var(--line-soft); padding: 40px 0; background: var(--bg); }
.footer-inner { display: flex; flex-wrap: wrap; gap: 22px; align-items: center; justify-content: space-between; }
.f-brand { font-weight: 650; margin: 0 0 2px; font-size: 15px; }
.f-sub { font-size: 13.2px; color: var(--muted-2); margin: 0; }
.f-links { display: flex; gap: 22px; }
.f-links a { font-size: 13.5px; color: var(--muted); }
.f-links a:hover { color: var(--text); }
.f-copy { font-size: 13px; color: var(--muted-2); margin: 0; }

/* ---------- legal pages ---------- */

.doc { padding: 64px 0 88px; }
.doc h1 { font-size: clamp(28px, 4vw, 40px); max-width: none; margin-bottom: 8px; }
.doc .updated { color: var(--muted-2); font-size: 13.5px; margin-bottom: 40px; }
.doc h2 { font-size: 20px; margin: 40px 0 12px; }
.doc p, .doc li { color: var(--muted); font-size: 15.5px; }
.doc ul li { position: relative; padding-left: 18px; margin-bottom: 8px; }
.doc ul li::before {
  content: ''; position: absolute; left: 2px; top: 11px;
  width: 5px; height: 5px; border-radius: 50%; background: #39415a;
}
.doc a { color: var(--accent); }
.doc a:hover { color: #8fb0ff; }
.doc .back { display: inline-block; margin-bottom: 28px; font-size: 14px; color: var(--muted); }
.doc .back:hover { color: var(--text); }

/* ---------- responsive ---------- */

@media (max-width: 900px) {
  .about-grid { grid-template-columns: 1fr; gap: 36px; }
  .timeline > li { grid-template-columns: 1fr; gap: 10px; }
  .stats { grid-template-columns: repeat(2, 1fr); gap: 24px 18px; }
}

@media (max-width: 760px) {
  .nav-links {
    position: fixed; inset: 72px 0 auto; flex-direction: column; gap: 0;
    background: var(--bg-alt); border-bottom: 1px solid var(--line);
    padding: 8px 24px 20px; display: none;
  }
  .nav-links.open { display: flex; }
  .nav-links a { padding: 13px 0; border-bottom: 1px solid var(--line-soft); font-size: 15.5px; }
  .menu-btn {
    display: flex; flex-direction: column; justify-content: center; gap: 5px;
    width: 40px; height: 40px; padding: 0 9px; cursor: pointer;
    background: none; border: 1px solid var(--line); border-radius: 10px;
  }
  .menu-btn span { display: block; height: 1.6px; background: var(--text); border-radius: 2px; }
  .brand-text strong { white-space: nowrap; font-size: 14.5px; }
  .brand-text em { font-size: 11.5px; white-space: nowrap; }
  .nav-inner { gap: 12px; }
  .hero { padding: 64px 0 56px; }
  .section { padding: 64px 0; }
  .app-card { padding: 16px; gap: 14px; }
  .app-icon { width: 54px; height: 54px; border-radius: 12px; }
  .grid { grid-template-columns: 1fr; }
  .footer-inner { flex-direction: column; align-items: flex-start; }
}

@media (max-width: 400px) {
  .brand-text em { display: none; }
  .brand-mark { width: 34px; height: 34px; border-radius: 10px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; animation: none !important; }
}
