/* =========================================================
   ESRA SEYREK — PORTFOLYO
   Tasarim Tokenlari
   ========================================================= */
:root {
  --ink: #17140f;
  --ink-soft: #221e17;
  --paper: #ece6d6;
  --paper-dim: #b9b2a0;
  --signal: #e0a73e;
  --signal-dim: #a9791f;
  --line: rgba(236, 230, 214, 0.14);

  --font-display: "Fraunces", "Iowan Old Style", Georgia, serif;
  --font-body: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;

  --container: 1180px;
  --gutter: clamp(20px, 5vw, 64px);
}

* { box-sizing: border-box; }
html { scroll-behavior: auto; }
html, body { background: var(--ink); }

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--paper);
  background: var(--ink);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }

:focus-visible {
  outline: 2px solid var(--signal);
  outline-offset: 3px;
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
}

.wrap {
  max-width: var(--container);
  margin: 0 auto;
  padding-left: var(--gutter);
  padding-right: var(--gutter);
}

.section { padding: clamp(64px, 10vw, 140px) 0; position: relative; }
.section + .section { border-top: 1px solid var(--line); }

.eyebrow {
  font-size: 0.8rem;
  letter-spacing: 0.02em;
  color: var(--signal);
  margin: 0 0 14px;
  font-weight: 600;
}

h1, h2, h3 { font-family: var(--font-display); margin: 0; font-weight: 500; }

.section-title {
  font-size: clamp(1.8rem, 3.4vw, 2.8rem);
  max-width: 20ch;
  line-height: 1.12;
  margin-bottom: 40px;
}

/* ---------------- Header ---------------- */
.site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 22px var(--gutter);
  mix-blend-mode: difference;
}

.logo {
  font-family: var(--font-display);
  font-size: 1.4rem;
  letter-spacing: 0.02em;
}
.logo img { height: 34px; width: auto; }

.nav-links { display: flex; gap: clamp(16px, 2.6vw, 36px); list-style: none; margin: 0; padding: 0; }
.nav-links a {
  font-size: 0.92rem;
  position: relative;
  padding-bottom: 2px;
}
.nav-links a::after {
  content: "";
  position: absolute; left: 0; bottom: -2px;
  width: 0; height: 1px;
  background: currentColor;
  transition: width 0.35s ease;
}
.nav-links a:hover::after { width: 100%; }

.nav-toggle { display: none; }

/* ---------------- Hero ---------------- */
.hero {
  position: relative;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  overflow: hidden;
}

#hero-canvas {
  position: absolute;
  inset: 0;
  z-index: 0;
  opacity: 0.9;
}

.hero-content { position: relative; z-index: 1; }

.hero-title {
  font-size: clamp(2.6rem, 8vw, 6.4rem);
  line-height: 0.98;
  white-space: pre-line;
  max-width: 16ch;
}

.hero-title .word { display: inline-block; overflow: hidden; }
.hero-title .word span { display: inline-block; will-change: transform; }

.hero-subtitle {
  margin-top: 28px;
  max-width: 46ch;
  font-size: clamp(1rem, 1.4vw, 1.2rem);
  color: var(--paper-dim);
}

.hero-scroll-cue {
  position: absolute;
  bottom: 40px; left: var(--gutter);
  font-size: 0.75rem;
  color: var(--paper-dim);
  display: flex; align-items: center; gap: 10px;
}
.hero-scroll-cue::before {
  content: "";
  width: 1px; height: 34px;
  background: var(--paper-dim);
  transform-origin: top;
  animation: scrollcue 2.2s ease-in-out infinite;
}
@keyframes scrollcue { 0%,100% { transform: scaleY(1); opacity: .3; } 50% { transform: scaleY(0.4); opacity: 1; } }

/* ---------------- About ---------------- */
.about-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: clamp(32px, 6vw, 80px);
  align-items: start;
}
.about-text { font-size: 1.05rem; color: var(--paper-dim); max-width: 56ch; }

.skills-list { list-style: none; margin: 30px 0 0; padding: 0; display: grid; gap: 16px; }
.skill-row { display: grid; grid-template-columns: 120px 1fr; align-items: center; gap: 16px; font-size: 0.88rem; }
.skill-bar { height: 3px; background: var(--line); position: relative; }
.skill-bar span { position: absolute; inset: 0; width: 0; background: var(--signal); transition: width 1.1s cubic-bezier(.22,.8,.28,1); }

.cv-button {
  display: inline-flex; align-items: center; gap: 10px;
  margin-top: 34px;
  padding: 14px 26px;
  border: 1px solid var(--paper);
  font-size: 0.9rem;
  transition: background 0.3s ease, color 0.3s ease;
}
.cv-button:hover { background: var(--paper); color: var(--ink); }

/* ---------------- Timeline (Deneyim) ---------------- */
.timeline { position: relative; margin-top: 20px; padding-left: 40px; }
.timeline::before {
  content: "";
  position: absolute; left: 0; top: 0; bottom: 0; width: 1px;
  background: var(--line);
}
.timeline-fill {
  position: absolute; left: 0; top: 0; width: 1px; height: 0;
  background: var(--signal);
}
.timeline-item { position: relative; padding-bottom: 52px; }
.timeline-item:last-child { padding-bottom: 0; }
.timeline-item::before {
  content: "";
  position: absolute; left: -44px; top: 4px;
  width: 9px; height: 9px; border-radius: 50%;
  background: var(--ink); border: 1px solid var(--signal);
}
.timeline-type {
  font-size: 0.72rem; text-transform: none;
  color: var(--signal-dim); margin-bottom: 6px;
}
.timeline-title { font-family: var(--font-display); font-size: 1.3rem; margin-bottom: 4px; }
.timeline-org { color: var(--paper-dim); font-size: 0.9rem; margin-bottom: 10px; }
.timeline-desc { color: var(--paper-dim); font-size: 0.92rem; max-width: 58ch; }

/* ---------------- Portfolio Grid ---------------- */
.portfolio-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 2px;
  background: var(--line);
}
.portfolio-card {
  background: var(--ink);
  cursor: pointer;
  position: relative;
  aspect-ratio: 4 / 5;
  overflow: hidden;
  perspective: 900px;
}
.portfolio-card img {
  width: 100%; height: 100%; object-fit: cover;
  transform: scale(1.02);
  transition: transform 0.6s ease;
}
.portfolio-card:hover img { transform: scale(1.08); }
.portfolio-card .card-glare {
  position: absolute; inset: 0;
  background: linear-gradient(120deg, rgba(255,255,255,0.16), transparent 60%);
  opacity: 0; transition: opacity 0.3s ease;
  pointer-events: none;
}
.portfolio-card:hover .card-glare { opacity: 1; }
.portfolio-card .card-caption {
  position: absolute; left: 0; right: 0; bottom: 0;
  padding: 18px 20px;
  background: linear-gradient(to top, rgba(0,0,0,0.65), transparent);
}
.portfolio-card .card-caption .cat { font-size: 0.72rem; color: var(--signal); display:block; margin-bottom: 4px; }
.portfolio-card .card-caption .title { font-family: var(--font-display); font-size: 1.05rem; }

/* ---------------- Lightbox ---------------- */
.lightbox {
  position: fixed; inset: 0; z-index: 200;
  display: none;
  align-items: center; justify-content: center;
  background: rgba(10, 9, 6, 0.92);
  padding: 40px;
}
.lightbox.is-open { display: flex; }
.lightbox-inner { max-width: 900px; max-height: 86vh; }
.lightbox-inner img { max-height: 78vh; width: auto; margin: 0 auto; }
.lightbox-caption { margin-top: 18px; text-align: center; color: var(--paper-dim); }
.lightbox-close {
  position: absolute; top: 26px; right: var(--gutter);
  font-size: 0.9rem; border: 1px solid var(--paper); padding: 8px 16px;
}

/* ---------------- Contact / Footer ---------------- */
.contact-title { font-size: clamp(1.9rem, 5vw, 3.4rem); max-width: 16ch; }
.contact-email { color: var(--signal); font-size: clamp(1.1rem, 2vw, 1.4rem); display: inline-block; margin-top: 24px; }
.social-list { display: flex; gap: 26px; margin-top: 40px; list-style: none; padding: 0; font-size: 0.9rem; }

.site-footer {
  padding: 28px var(--gutter);
  display: flex; justify-content: space-between; align-items: center;
  font-size: 0.8rem; color: var(--paper-dim);
  border-top: 1px solid var(--line);
  flex-wrap: wrap; gap: 12px;
}

/* ---------------- Reveal on scroll ---------------- */
.reveal { opacity: 0; transform: translateY(30px); filter: blur(6px); }
.reveal.is-visible {
  opacity: 1; transform: translateY(0); filter: blur(0);
  transition: opacity 0.9s ease, transform 0.9s ease, filter 0.9s ease;
}

@media (max-width: 900px) {
  .about-grid { grid-template-columns: 1fr; }
  .nav-links { display: none; }
}
