/* ============================================================
   Talha Soylu — Portfolyo
   3B kule sahnesi üzerine oturan cam panelli arayüz
   ============================================================ */

:root {
  --amber: #f5a524;
  --amber-bright: #ffc258;
  --violet: #7c5cff;
  --ink: #f4f0ff;
  --muted: #a79fc0;
  --surface: rgba(17, 12, 30, 0.86);
  --surface-solid: #150f24;
  --border: rgba(255, 255, 255, 0.09);
  --border-hot: rgba(245, 165, 36, 0.45);
  --radius: 20px;
  --shadow: 0 24px 60px -20px rgba(0, 0, 0, 0.85);
  --font-display: 'Grandstander', system-ui, sans-serif;
  --font-body: 'Inter', system-ui, -apple-system, sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink);
  background: #120a1f;
  line-height: 1.65;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
  text-rendering: optimizeLegibility;
}

/* Çentikli telefonlarda içerik kenarlara yapışmasın */
@supports (padding: max(0px)) {
  .nav { padding-left: max(1rem, env(safe-area-inset-left)); padding-right: max(1rem, env(safe-area-inset-right)); }
  .footer { padding-bottom: max(2.5rem, calc(env(safe-area-inset-bottom) + 1.5rem)); }
  #mascot { bottom: max(.8rem, calc(env(safe-area-inset-bottom) + .4rem)); left: max(.8rem, env(safe-area-inset-left)); }
}

/* WebGL yoksa: sahnenin yerine degrade */
body.no-webgl { background: linear-gradient(180deg, #120a1f 0%, #1a0b2e 45%, #2b1b52 100%); }
body.no-webgl #bg-canvas { display: none; }

#bg-canvas {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  display: block;
}

/* Sahne ile içerik arasında okunabilirlik katmanı:
   arka planı bastırır, metnin kontrastını garanti eder. */
#bg-veil {
  position: fixed; inset: 0; z-index: 1; pointer-events: none;
  background:
    radial-gradient(125% 85% at 50% 0%, rgba(10, 6, 18, 0) 0%, rgba(10, 6, 18, .3) 68%, rgba(10, 6, 18, .55) 100%),
    linear-gradient(180deg, rgba(10, 6, 18, .12) 0%, rgba(10, 6, 18, .38) 100%);
}

/* İçerik sahnenin üstünde akar */
.page { position: relative; z-index: 2; }

a { color: var(--amber); text-decoration: none; transition: color .2s; }
a:hover { color: var(--amber-bright); }
img { max-width: 100%; display: block; }
h1, h2, h3, h4 { font-family: var(--font-display); line-height: 1.15; margin: 0; }

:focus-visible { outline: 2px solid var(--amber); outline-offset: 3px; border-radius: 6px; }

.wrap { width: min(1180px, 92vw); margin: 0 auto; }

/* ---------- Üst çubuk ---------- */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.85rem clamp(1rem, 4vw, 2.5rem);
  background: rgba(12, 8, 22, 0);
  backdrop-filter: blur(0px);
  transition: background .3s, backdrop-filter .3s, border-color .3s;
  border-bottom: 1px solid transparent;
}
.nav.stuck {
  background: rgba(12, 8, 22, 0.82);
  backdrop-filter: blur(14px);
  border-bottom-color: var(--border);
}
.nav__brand {
  display: flex; align-items: center; gap: .6rem;
  font-family: var(--font-display); font-weight: 800; font-size: 1.05rem;
  color: var(--ink); letter-spacing: .01em;
}
.nav__brand img { width: 34px; height: 34px; border-radius: 10px; }
.nav__links { display: flex; align-items: center; gap: .35rem; }
.nav__links a {
  color: var(--muted); font-size: .9rem; font-weight: 500;
  padding: .45rem .8rem; border-radius: 10px; transition: all .2s;
}
.nav__links a:hover, .nav__links a.active { color: var(--ink); background: rgba(255,255,255,.07); }
.nav__side { display: flex; align-items: center; gap: .6rem; }

.lang {
  display: flex; border: 1px solid var(--border); border-radius: 10px; overflow: hidden;
  background: rgba(255,255,255,.04);
}
.lang button {
  border: 0; background: transparent; color: var(--muted);
  font: 600 .78rem var(--font-body); padding: .35rem .6rem; cursor: pointer; transition: all .2s;
}
.lang button.on { background: var(--amber); color: #17110a; }

.nav__burger {
  display: none; border: 1px solid var(--border); background: rgba(255,255,255,.05);
  color: var(--ink); width: 40px; height: 40px; border-radius: 11px; cursor: pointer; font-size: 1.05rem;
}

@media (max-width: 860px) {
  .nav__links {
    position: absolute; top: 100%; left: 0; right: 0;
    flex-direction: column; align-items: stretch; gap: 0;
    background: rgba(12, 8, 22, .97); backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--border);
    padding: .5rem; max-height: 0; overflow: hidden; transition: max-height .3s ease, padding .3s;
  }
  .nav__links.open { max-height: 320px; padding: .6rem; }
  .nav__links a { padding: .7rem .9rem; }
  .nav__burger { display: block; }
}

/* ---------- HUD: oyundaki kat sayacı ---------- */
.hud {
  position: fixed; right: clamp(.8rem, 3vw, 2rem); top: 50%;
  transform: translateY(-50%);
  z-index: 40; text-align: right; pointer-events: none;
  opacity: 0; transition: opacity .4s;
}
.hud.show { opacity: 1; }
.hud__label { font: 600 .62rem var(--font-body); letter-spacing: .22em; color: var(--muted); }
.hud__value {
  font-family: var(--font-display); font-weight: 800; font-size: clamp(1.8rem, 4vw, 2.6rem);
  color: var(--amber-bright);
  text-shadow: 0 0 22px rgba(245,165,36,.55);
  line-height: 1;
}
.hud__bar {
  width: 3px; height: min(30vh, 220px); margin-left: auto; margin-top: .7rem;
  background: rgba(255,255,255,.12); border-radius: 3px; overflow: hidden; position: relative;
}
.hud__fill {
  position: absolute; bottom: 0; left: 0; right: 0; height: 0%;
  background: linear-gradient(to top, var(--amber), var(--amber-bright));
  box-shadow: 0 0 14px rgba(245,165,36,.8);
}
.hud__combo {
  margin-top: .55rem; font-family: var(--font-display); font-weight: 800;
  font-size: .95rem; color: var(--amber-bright);
  opacity: 0; transform: scale(.7); transition: all .25s cubic-bezier(.34,1.56,.64,1);
}
.hud__combo.on { opacity: 1; transform: scale(1); }
@media (max-width: 860px) { .hud { display: none; } }

/* ---------- Bölüm iskeleti ---------- */
.section { position: relative; padding: clamp(4.5rem, 11vh, 8rem) 0; }

.floor-tag {
  display: inline-flex; align-items: center; gap: .7rem;
  font: 600 .68rem var(--font-body); letter-spacing: .25em; text-transform: uppercase;
  color: var(--amber); margin-bottom: 1.1rem;
}
.floor-tag::before {
  content: ''; width: 34px; height: 2px; border-radius: 2px;
  background: linear-gradient(90deg, transparent, var(--amber));
}
.section__title {
  font-size: clamp(2rem, 5.2vw, 3.2rem); font-weight: 800; margin-bottom: .7rem; letter-spacing: -.01em;
}
.section__lead { color: var(--muted); max-width: 60ch; font-size: 1.02rem; }

.glass {
  background: var(--surface);
  backdrop-filter: blur(18px) saturate(1.3);
  -webkit-backdrop-filter: blur(18px) saturate(1.3);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

/* Kaydırınca beliren animasyon */
.reveal { opacity: 0; transform: translateY(26px); transition: opacity .7s ease, transform .7s cubic-bezier(.22,1,.36,1); }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .reveal { opacity: 1; transform: none; transition: none; } }

/* ---------- Hero ---------- */
.hero {
  min-height: 100svh; display: flex; align-items: center;
  padding-top: 6rem; padding-bottom: 4rem;
  position: relative;
}
/* İmleci izleyen yumuşak ışık lekesi */
.hero::before {
  content: ''; position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(600px circle at var(--spot-x, 50%) var(--spot-y, 40%),
              rgba(245, 165, 36, .09), transparent 60%);
  transition: background .2s ease-out;
}
.hero__wrap {
  display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr);
  gap: clamp(1.5rem, 4vw, 3rem); align-items: center;
  position: relative; z-index: 1;
}
.hero__inner { max-width: 40rem; }

/* Karakter görseli */
.hero__art { position: relative; display: grid; place-items: center; }
.hero__art img {
  width: min(330px, 86%);
  filter: drop-shadow(0 30px 45px rgba(0, 0, 0, .75));
  animation: floaty 6s ease-in-out infinite;
  will-change: transform;
}
@keyframes floaty { 0%, 100% { margin-top: 0; } 50% { margin-top: -18px; } }
.hero__glow {
  position: absolute; width: 70%; aspect-ratio: 1; border-radius: 50%;
  background: radial-gradient(circle, rgba(245, 165, 36, .3), rgba(124, 92, 255, .16) 45%, transparent 70%);
  filter: blur(30px); z-index: -1;
}
@media (max-width: 900px) {
  .hero__wrap { grid-template-columns: 1fr; }
  .hero__art { order: -1; margin-bottom: .5rem; }
  .hero__art img { width: min(190px, 45%); animation: none; }
}
.hero__badge {
  display: inline-flex; align-items: center; gap: .55rem;
  padding: .4rem .9rem; border-radius: 999px;
  background: rgba(245,165,36,.12); border: 1px solid var(--border-hot);
  color: var(--amber-bright); font: 600 .74rem var(--font-body); letter-spacing: .13em; text-transform: uppercase;
  margin-bottom: 1.4rem;
}
.hero__badge .dot {
  width: 7px; height: 7px; border-radius: 50%; background: #33d778;
  box-shadow: 0 0 10px #33d778; animation: pulse 2s infinite;
}
@keyframes pulse { 0%,100% { opacity: 1; } 50% { opacity: .35; } }

.hero h1 {
  font-size: clamp(2.9rem, 9vw, 5.4rem);
  font-weight: 800; letter-spacing: -.025em; margin-bottom: .5rem;
  background: linear-gradient(135deg, #fff 20%, var(--amber-bright) 65%, var(--amber) 100%);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 6px 30px rgba(245,165,36,.28));
}
.hero__role {
  font-family: var(--font-display); font-weight: 700;
  font-size: clamp(1.05rem, 2.6vw, 1.5rem); color: var(--ink); margin-bottom: 1rem;
}
.hero__desc { color: var(--muted); font-size: clamp(1rem, 1.6vw, 1.1rem); max-width: 34rem; margin-bottom: 2rem; }
.hero__cta { display: flex; flex-wrap: wrap; gap: .8rem; margin-bottom: 2.4rem; }

.btn {
  display: inline-flex; align-items: center; gap: .6rem;
  padding: .85rem 1.5rem; border-radius: 13px;
  font: 700 .95rem var(--font-body); cursor: pointer; border: 1px solid transparent;
  transition: transform .2s, box-shadow .2s, background .2s, border-color .2s;
}
.btn:active { transform: translateY(1px); }
.btn--primary {
  background: linear-gradient(135deg, var(--amber-bright), var(--amber));
  color: #1a1206; box-shadow: 0 12px 30px -10px rgba(245,165,36,.7);
}
.btn--primary:hover { transform: translateY(-2px); box-shadow: 0 18px 40px -12px rgba(245,165,36,.85); color: #1a1206; }
.btn--ghost { background: rgba(255,255,255,.05); border-color: var(--border); color: var(--ink); }
.btn--ghost:hover { border-color: var(--border-hot); color: var(--amber-bright); background: rgba(245,165,36,.08); }

.hero__stats { display: flex; flex-wrap: wrap; gap: clamp(1.2rem, 4vw, 2.6rem); }
.stat__num {
  font-family: var(--font-display); font-weight: 800;
  font-size: clamp(1.5rem, 3.4vw, 2rem); color: var(--amber-bright); line-height: 1;
}
.stat__label { font-size: .78rem; color: var(--muted); letter-spacing: .04em; margin-top: .25rem; }

.scroll-hint {
  position: absolute; bottom: 2rem; left: 50%; transform: translateX(-50%);
  color: var(--muted); font-size: .72rem; letter-spacing: .2em; text-transform: uppercase;
  display: flex; flex-direction: column; align-items: center; gap: .5rem;
}
.scroll-hint i { animation: bob 1.8s ease-in-out infinite; font-size: 1rem; color: var(--amber); }
@keyframes bob { 0%,100% { transform: translateY(0); } 50% { transform: translateY(7px); } }

/* ---------- Hakkımda ---------- */
.about-grid { display: grid; grid-template-columns: 1.35fr 1fr; gap: 1.6rem; margin-top: 2.5rem; }
@media (max-width: 900px) { .about-grid { grid-template-columns: 1fr; } }
.about-card { padding: clamp(1.5rem, 3vw, 2.2rem); }
.about-card p { color: var(--muted); margin: 0 0 1rem; }
.about-card p:last-child { margin-bottom: 0; }
.about-card strong { color: var(--ink); font-weight: 600; }

.facts { display: flex; flex-direction: column; gap: .9rem; }
.fact {
  display: flex; gap: .9rem; align-items: flex-start;
  padding: 1rem 1.1rem; border-radius: 15px;
  background: rgba(255,255,255,.035); border: 1px solid var(--border);
}
.fact i { color: var(--amber); font-size: 1rem; margin-top: .2rem; width: 1.2rem; text-align: center; }
.fact b { display: block; font-size: .92rem; font-weight: 600; }
.fact span { font-size: .82rem; color: var(--muted); }

/* ---------- Öne çıkan oyun ---------- */
.featured { display: grid; grid-template-columns: 1fr auto; gap: clamp(1.5rem, 4vw, 3.5rem); align-items: center; padding: clamp(1.6rem, 3.5vw, 3rem); margin-top: 2.5rem; }
@media (max-width: 980px) { .featured { grid-template-columns: 1fr; } }
.featured__logo { width: min(340px, 78%); margin-bottom: 1.3rem; filter: drop-shadow(0 10px 30px rgba(0,0,0,.6)); }
.featured p { color: var(--muted); margin: 0 0 1rem; }
.tags { display: flex; flex-wrap: wrap; gap: .45rem; margin: 1.2rem 0 1.6rem; }
.tag {
  font: 600 .74rem var(--font-body); padding: .32rem .72rem; border-radius: 8px;
  background: rgba(124,92,255,.14); border: 1px solid rgba(124,92,255,.3); color: #c4b5ff;
}
.tag--amber { background: rgba(245,165,36,.13); border-color: var(--border-hot); color: var(--amber-bright); }

.phone {
  position: relative; width: min(310px, 80vw); aspect-ratio: 9/16;
  border-radius: 30px; border: 5px solid #241a3d;
  box-shadow: 0 0 0 2px #0d0818, 0 34px 70px -18px rgba(0,0,0,.9), 0 0 60px rgba(245,165,36,.14);
  overflow: hidden; background: #000; margin-inline: auto;
}
.phone iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.phone__cover { position: absolute; inset: 0; cursor: pointer; }
.phone__cover img { width: 100%; height: 100%; object-fit: cover; }
.phone__cover::after {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(10,6,18,.2), rgba(10,6,18,.8));
  transition: opacity .3s;
}
.phone__cover:hover::after { opacity: .6; }
.phone__play {
  position: absolute; top: 50%; left: 50%; transform: translate(-50%,-50%);
  width: 74px; height: 74px; border-radius: 50%; z-index: 2;
  background: linear-gradient(135deg, var(--amber-bright), var(--amber));
  color: #17110a; display: grid; place-items: center; font-size: 1.5rem;
  box-shadow: 0 0 34px rgba(245,165,36,.65); transition: transform .25s;
}
.phone__cover:hover .phone__play { transform: translate(-50%,-50%) scale(1.12); }
.phone__label {
  position: absolute; bottom: 1.5rem; left: 0; right: 0; z-index: 2; text-align: center;
  font-family: var(--font-display); font-weight: 700; font-size: 1.02rem; color: #fff;
  text-shadow: 0 2px 12px rgba(0,0,0,.9);
}
.phone-note { text-align: center; font-size: .76rem; color: var(--muted); margin-top: .9rem; }

/* ---------- Oyundan kareler (yatay şerit) ---------- */
.shots {
  display: flex; gap: .9rem; margin-top: 1.6rem;
  overflow-x: auto; padding-bottom: .7rem;
  scroll-snap-type: x mandatory; scrollbar-width: thin;
  scrollbar-color: var(--amber) rgba(255,255,255,.07);
}
.shots::-webkit-scrollbar { height: 7px; }
.shots::-webkit-scrollbar-track { background: rgba(255,255,255,.06); border-radius: 5px; }
.shots::-webkit-scrollbar-thumb { background: var(--amber); border-radius: 5px; }
.shot {
  flex: 0 0 auto; scroll-snap-align: start;
  width: clamp(220px, 30vw, 330px);
  padding: 0; border: 1px solid var(--border); border-radius: 14px;
  overflow: hidden; background: #0f0a1c; cursor: zoom-in;
  transition: transform .3s, border-color .3s;
}
.shot:hover { transform: translateY(-4px); border-color: var(--border-hot); }
.shot img { width: 100%; aspect-ratio: 16/9; object-fit: cover; display: block; }

/* Büyütülmüş görsel */
.lightbox {
  position: fixed; inset: 0; z-index: 95; display: none;
  align-items: center; justify-content: center; padding: 1.5rem;
  background: rgba(6,3,12,.9); backdrop-filter: blur(8px); cursor: zoom-out;
}
.lightbox.open { display: flex; animation: fade .25s ease; }
.lightbox img { max-width: 100%; max-height: 90vh; border-radius: 14px; border: 1px solid var(--border-hot); }

/* ---------- Proje ızgarası ---------- */
.projects { display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 1.3rem; margin-top: 2.5rem; }
.card {
  overflow: hidden; cursor: pointer; text-align: left;
  transition: transform .35s cubic-bezier(.22,1,.36,1), border-color .3s, box-shadow .35s;
  padding: 0; border: 1px solid var(--border); background: var(--surface);
  backdrop-filter: blur(18px); border-radius: var(--radius); box-shadow: var(--shadow);
  display: flex; flex-direction: column;
}
/* Eğilme JS ile satır içi yapılır; burada yalnızca kenar ve gölge değişir
   (transform verilirse mıknatıs/eğilme etkisiyle çakışır). */
.card:hover { border-color: var(--border-hot); box-shadow: 0 30px 60px -20px rgba(0,0,0,.9), 0 0 40px -18px rgba(245,165,36,.5); }
.card__media { position: relative; aspect-ratio: 16/9; overflow: hidden; background: #0f0a1c; }
.card__media img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s, opacity .4s; }
.card:hover .card__media img { transform: scale(1.06); }
.card__media iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; opacity: 0; transition: opacity .5s; }
.card__media iframe.on { opacity: 1; }
.card__badge {
  position: absolute; top: .7rem; left: .7rem; z-index: 3;
  font: 700 .66rem var(--font-body); letter-spacing: .08em; text-transform: uppercase;
  padding: .28rem .6rem; border-radius: 7px; backdrop-filter: blur(8px);
  background: rgba(10,6,18,.7); border: 1px solid var(--border); color: var(--amber-bright);
}
.card__body { padding: 1.1rem 1.25rem 1.35rem; flex: 1; display: flex; flex-direction: column; }
.card__title { font-size: 1.16rem; font-weight: 700; margin-bottom: .35rem; }
.card__desc { font-size: .87rem; color: var(--muted); flex: 1; }
.card__meta { display: flex; align-items: center; gap: .5rem; margin-top: .9rem; font-size: .74rem; color: var(--muted); }
.card__meta .chip { padding: .2rem .55rem; border-radius: 6px; background: rgba(255,255,255,.06); border: 1px solid var(--border); }

.protos { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 1rem; margin-top: 1.3rem; }
.proto { padding: 1.1rem; border-radius: 15px; background: rgba(255,255,255,.03); border: 1px solid var(--border); }
.proto b { font-size: .93rem; }
.proto span { display: block; font-size: .8rem; color: var(--muted); margin-top: .25rem; }

/* ---------- Deneyim zaman çizelgesi ---------- */
.timeline { margin-top: 2.5rem; position: relative; padding-left: 2rem; }
.timeline::before {
  content: ''; position: absolute; left: 6px; top: 8px; bottom: 8px; width: 2px;
  background: linear-gradient(180deg, var(--amber), rgba(124,92,255,.5), transparent);
}
.job { position: relative; padding-bottom: 2rem; }
.job:last-child { padding-bottom: 0; }
.job::before {
  content: ''; position: absolute; left: -2rem; top: .45rem;
  width: 14px; height: 14px; border-radius: 50%;
  background: var(--surface-solid); border: 3px solid var(--amber);
  box-shadow: 0 0 16px rgba(245,165,36,.6);
}
.job__head { display: flex; flex-wrap: wrap; align-items: baseline; gap: .3rem .8rem; }
.job__role { font-family: var(--font-display); font-weight: 700; font-size: 1.12rem; }
.job__co { color: var(--amber); font-weight: 600; font-size: .96rem; }
.job__date { font-size: .78rem; color: var(--muted); margin-left: auto; }
.job ul { margin: .6rem 0 0; padding-left: 1.1rem; color: var(--muted); font-size: .89rem; }
.job li { margin-bottom: .28rem; }
.job li::marker { color: var(--amber); }

/* ---------- Yetenekler ---------- */
.skills { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 1.2rem; margin-top: 2.5rem; }
.skill-card { padding: 1.5rem; }
.skill-card h3 { font-size: 1.05rem; margin-bottom: .9rem; display: flex; align-items: center; gap: .6rem; }
.skill-card h3 i { color: var(--amber); }
.skill-list { display: flex; flex-wrap: wrap; gap: .4rem; }

/* ---------- İletişim ---------- */
.contact { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 1rem; margin-top: 2.5rem; }
.contact-card {
  padding: 1.5rem 1.2rem; text-align: center; color: var(--ink);
  transition: transform .3s, border-color .3s;
}
.contact-card:hover { border-color: var(--border-hot); color: var(--ink); }
.contact-card i {
  font-size: 1.4rem; color: var(--amber); margin-bottom: .7rem;
  display: block; transition: transform .3s;
}
.contact-card:hover i { transform: scale(1.15); }
.contact-card b { display: block; font-size: .98rem; margin-bottom: .2rem; }
.contact-card span { font-size: .8rem; color: var(--muted); word-break: break-word; }

.footer {
  border-top: 1px solid var(--border); margin-top: 3rem;
  padding: 2rem 0 2.5rem; text-align: center; color: var(--muted); font-size: .84rem;
  background: rgba(10, 6, 18, .55); backdrop-filter: blur(12px);
}

/* ---------- Proje modalı ---------- */
.modal {
  position: fixed; inset: 0; z-index: 90; display: none;
  align-items: center; justify-content: center; padding: 1.2rem;
  background: rgba(6, 3, 12, .82); backdrop-filter: blur(10px);
}
.modal.open { display: flex; animation: fade .25s ease; }
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }
.modal__box {
  position: relative; width: min(760px, 100%); max-height: 88vh; overflow-y: auto;
  padding: clamp(1.4rem, 3vw, 2.3rem); border-radius: var(--radius);
  background: var(--surface-solid); border: 1px solid var(--border-hot);
  box-shadow: 0 40px 90px -20px rgba(0,0,0,.95);
  animation: pop .3s cubic-bezier(.34,1.56,.64,1);
}
@keyframes pop { from { transform: scale(.93) translateY(14px); opacity: 0; } to { transform: none; opacity: 1; } }
.modal__close {
  position: absolute; top: .9rem; right: .9rem; width: 36px; height: 36px;
  border-radius: 10px; border: 1px solid var(--border); background: rgba(255,255,255,.06);
  color: var(--ink); font-size: 1.2rem; cursor: pointer; line-height: 1;
}
.modal__close:hover { background: rgba(245,165,36,.18); border-color: var(--border-hot); }
.modal h3 { font-size: 1.6rem; margin-bottom: .3rem; color: var(--amber-bright); }
.modal .video {
  position: relative; padding-bottom: 56.25%; height: 0; margin-top: 1.2rem;
  border-radius: 13px; overflow: hidden; border: 1px solid var(--border);
}
.modal .video iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.modal ul { color: var(--muted); font-size: .92rem; padding-left: 1.2rem; }
.modal li::marker { color: var(--amber); }

/* ---------- Maskot asistan ---------- */
/* Maskot: hero'yu geçince sol altta belirir */
#mascot {
  position: fixed; left: clamp(.8rem, 2vw, 1.4rem); bottom: clamp(.8rem, 2vw, 1.4rem);
  z-index: 60; width: 68px; pointer-events: none;
  opacity: 0; transform: translateY(20px) scale(.85);
  transition: opacity .45s ease, transform .45s cubic-bezier(.34, 1.56, .64, 1);
}
#mascot.visible { opacity: 1; transform: none; }
#mascot .m-char {
  width: 100%; cursor: pointer; pointer-events: auto;
  filter: drop-shadow(0 8px 14px rgba(0,0,0,.7)); transition: transform .3s;
}
#mascot .m-char:hover { transform: scale(1.1) rotate(-5deg); }

#mascot .bubble {
  position: absolute; left: 6px; bottom: calc(100% + 12px);
  width: max-content; max-width: min(260px, 60vw);
  padding: .75rem .95rem; border-radius: 16px 16px 16px 4px;
  background: var(--surface-solid); border: 1px solid var(--border-hot);
  box-shadow: 0 16px 40px -10px rgba(0,0,0,.85);
  font-size: .84rem; color: var(--ink);
  opacity: 0; transform: translateY(8px) scale(.9); transform-origin: bottom left;
  transition: all .32s cubic-bezier(.34,1.56,.64,1); pointer-events: none;
}
#mascot .bubble.show { opacity: 1; transform: none; pointer-events: auto; }
#mascot .bubble::after {
  content: ''; position: absolute; left: 16px; top: 100%;
  border: 7px solid transparent; border-top-color: var(--border-hot);
}
#mascot .bubble a {
  display: inline-block; margin-top: .5rem; padding: .3rem .7rem; border-radius: 8px;
  background: var(--amber); color: #17110a; font-weight: 700; font-size: .78rem;
}
#mascot .bubble a:hover { background: var(--amber-bright); color: #17110a; }
@media (max-width: 600px) { #mascot { width: 58px; } }

/* ---------- Özel imleç ---------- */
body.has-cursor,
body.has-cursor a,
body.has-cursor button,
body.has-cursor .card,
body.has-cursor .shot { cursor: none; }

.cursor-dot, .cursor-ring {
  position: fixed; top: 0; left: 0; z-index: 999;
  pointer-events: none; border-radius: 50%;
  margin-left: -4px; margin-top: -4px;
}
.cursor-dot {
  width: 8px; height: 8px; background: var(--amber-bright);
  box-shadow: 0 0 12px rgba(245, 165, 36, .9);
}
.cursor-ring {
  width: 36px; height: 36px; margin-left: -18px; margin-top: -18px;
  border: 1.5px solid rgba(245, 165, 36, .55);
  transition: width .25s, height .25s, margin .25s, border-color .25s, opacity .25s, background .25s;
}
.cursor-ring.hot {
  width: 60px; height: 60px; margin-left: -30px; margin-top: -30px;
  border-color: rgba(245, 165, 36, .9);
  background: rgba(245, 165, 36, .1);
}
.cursor-ring.gone, .cursor-dot.gone { opacity: 0; }

/* Kart parlaması: imlecin durduğu noktada yumuşak ışık */
.card, .glass.skill-card, .proto {
  position: relative;
  transition: transform .25s cubic-bezier(.22, 1, .36, 1), border-color .3s, box-shadow .35s;
  will-change: transform;
}
.card::after, .glass.skill-card::after, .proto::after {
  content: ''; position: absolute; inset: 0; border-radius: inherit;
  pointer-events: none; opacity: 0; transition: opacity .3s;
  background: radial-gradient(320px circle at var(--shine-x, 50%) var(--shine-y, 50%),
              rgba(255, 255, 255, .07), transparent 65%);
}
.card:hover::after, .glass.skill-card:hover::after, .proto:hover::after { opacity: 1; }

/* ============================================================
   MOBİL DÜZENLEMELER
   Telefonda okunabilirlik ve dokunma hedefleri önceliklidir.
   ============================================================ */
@media (max-width: 700px) {
  .section { padding: clamp(3rem, 8vh, 4.5rem) 0; }
  .wrap { width: 90vw; }

  /* Hero: karakter üstte ve küçük, metin nefes alsın */
  .hero { padding-top: 5rem; padding-bottom: 3rem; min-height: auto; }
  .hero__art img { width: min(160px, 42%); }
  .hero h1 { font-size: clamp(2.4rem, 13vw, 3.4rem); }
  .hero__desc { font-size: .98rem; }
  .hero__cta { gap: .6rem; }
  .hero__cta .btn { flex: 1 1 100%; justify-content: center; }

  /* İstatistikler: 2'li ızgara, taşma yok */
  .hero__stats {
    display: grid; grid-template-columns: 1fr 1fr;
    gap: 1rem 1.2rem; width: 100%;
  }
  .stat__num { font-size: 1.6rem; }
  .stat__label { font-size: .74rem; }

  .section__title { font-size: clamp(1.7rem, 7.5vw, 2.2rem); }
  .section__lead { font-size: .95rem; }

  /* Öne çıkan oyun */
  .featured { padding: 1.3rem; gap: 1.6rem; }
  .featured__logo { width: min(250px, 70%); }
  .phone { width: min(260px, 74vw); }

  /* Kartlar tek sütun, görsel şeridi daha dar */
  .projects { grid-template-columns: 1fr; gap: 1rem; }
  .shot { width: clamp(190px, 62vw, 240px); }
  .protos { grid-template-columns: 1fr 1fr; gap: .7rem; }
  .proto { padding: .8rem; }
  .proto b { font-size: .85rem; }
  .proto span { font-size: .74rem; }

  /* Zaman çizelgesi: tarih alta insin, sıkışmasın */
  .timeline { padding-left: 1.5rem; }
  .job::before { left: -1.5rem; width: 12px; height: 12px; }
  .job__head { flex-direction: column; align-items: flex-start; gap: .15rem; }
  .job__date { margin-left: 0; }
  .job__role { font-size: 1.02rem; }
  .job ul { font-size: .86rem; }

  .skills { grid-template-columns: 1fr; }
  .contact { grid-template-columns: 1fr 1fr; }

  .modal__box { padding: 1.2rem; max-height: 85vh; }
  .modal h3 { font-size: 1.3rem; }

  /* Maskot ve balonu küçült, ekranı kaplamasın */
  #mascot { width: 54px; }
  #mascot .bubble { max-width: min(230px, 66vw); font-size: .8rem; }

  .scroll-hint { display: none; }
  .nav__brand span { font-size: .95rem; }
}

/* Çok dar ekranlar */
@media (max-width: 380px) {
  .hero__stats { gap: .8rem; }
  .contact { grid-template-columns: 1fr; }
  .protos { grid-template-columns: 1fr; }
}

/* Dokunmatik: hover'a bağlı süslemeler kapansın, dokunma hedefleri büyüsün */
@media (hover: none) {
  .card:hover, .shot:hover, .contact-card:hover { transform: none; }
  .card::after, .glass.skill-card::after, .proto::after { display: none; }
  .nav__links a { padding: .8rem .9rem; }
  .btn { padding: .9rem 1.4rem; }
}

/* Yazdırma: sahne ve süsler gitsin */
@media print {
  #bg-canvas, #bg-veil, #mascot, .hud, .nav, .scroll-hint,
  .cursor-dot, .cursor-ring, .hero__art { display: none !important; }
  body { background: #fff; color: #000; }
}
