/* ============================================================
   Eren Rıza Turan — Portfolyo
   Premium dark theme · statik · Cloudflare Pages
   ============================================================ */

:root {
    --bg:        #0a0b0f;
    --bg-alt:    #0e0f15;
    --card:      rgba(255, 255, 255, 0.025);
    --card-hover: rgba(255, 255, 255, 0.045);
    --border:    rgba(255, 255, 255, 0.08);
    --border-2:  rgba(255, 255, 255, 0.14);
    --text:      #f2f3f7;
    --text-dim:  #9aa0ad;
    --text-faint:#6a7080;

    --violet:    #7c5cff;
    --blue:      #5b8cff;
    --teal:      #2dd4bf;
    --grad:      linear-gradient(120deg, #7c5cff 0%, #5b8cff 50%, #2dd4bf 100%);
    --grad-soft: linear-gradient(120deg, rgba(124,92,255,0.16), rgba(45,212,191,0.16));

    --radius:    20px;
    --radius-sm: 14px;
    --maxw:      1160px;
    --ease:      cubic-bezier(0.22, 1, 0.36, 1);
}

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

html { scroll-behavior: smooth; }

body {
    font-family: "Plus Jakarta Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.65;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
::selection { background: rgba(124, 92, 255, 0.35); color: #fff; }

::-webkit-scrollbar { width: 11px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb { background: #23262f; border-radius: 99px; border: 3px solid var(--bg); }
::-webkit-scrollbar-thumb:hover { background: #313542; }

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

/* ---------- Arka plan dekorasyonu ---------- */
.bg-grid {
    position: fixed; inset: 0; z-index: -2; pointer-events: none;
    background-image:
        linear-gradient(rgba(255,255,255,0.022) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,0.022) 1px, transparent 1px);
    background-size: 60px 60px;
    mask-image: radial-gradient(ellipse 100% 60% at 50% 0%, #000 30%, transparent 80%);
}
.bg-glow {
    position: fixed; z-index: -1; pointer-events: none; border-radius: 50%;
    filter: blur(120px); opacity: 0.5;
}
.bg-glow--1 { top: -180px; left: -140px; width: 520px; height: 520px; background: #7c5cff; opacity: 0.28; }
.bg-glow--2 { top: 18%; right: -160px; width: 460px; height: 460px; background: #2dd4bf; opacity: 0.16; }
.bg-glow--3 { bottom: -200px; left: 30%; width: 560px; height: 560px; background: #5b8cff; opacity: 0.14; }

/* ---------- Butonlar ---------- */
.btn {
    display: inline-flex; align-items: center; gap: 9px;
    padding: 14px 28px; border-radius: 999px; font-weight: 600; font-size: 0.96rem;
    cursor: pointer; font-family: inherit;
    transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease), background 0.25s, border-color 0.25s;
    -webkit-tap-highlight-color: transparent;
}
.btn:focus { outline: none; }
.btn:focus-visible { outline: 2px solid var(--violet); outline-offset: 2px; }
.btn__arrow { transition: transform 0.25s var(--ease); }
.btn:hover .btn__arrow { transform: translateX(4px); }
.btn--primary {
    background: var(--grad); color: #0a0b0f; border: 1px solid transparent;
    -webkit-background-clip: padding-box; background-clip: padding-box;
    box-shadow: 0 8px 30px rgba(124, 92, 255, 0.35);
}
.btn--primary:hover { transform: translateY(-3px); box-shadow: 0 14px 40px rgba(124, 92, 255, 0.5); }
.btn--ghost { background: rgba(255,255,255,0.03); color: var(--text); border: 1px solid var(--border-2); }
.btn--ghost:hover { transform: translateY(-3px); border-color: var(--violet); background: rgba(124,92,255,0.08); }

.grad {
    background: var(--grad); -webkit-background-clip: text; background-clip: text;
    -webkit-text-fill-color: transparent; color: transparent;
}

/* ---------- NAV ---------- */
.nav {
    position: fixed; top: 0; left: 0; right: 0; z-index: 100;
    transition: background 0.35s, border-color 0.35s, backdrop-filter 0.35s;
    border-bottom: 1px solid transparent;
}
.nav.scrolled {
    background: rgba(10, 11, 15, 0.7);
    backdrop-filter: saturate(160%) blur(16px);
    border-bottom-color: var(--border);
}
.nav__inner { display: flex; align-items: center; justify-content: space-between; height: 70px; }
.nav__logo { font-family: "JetBrains Mono", monospace; font-size: 1.25rem; font-weight: 500; letter-spacing: 1px; }
.nav__logo span { color: var(--violet); }
.nav__links { display: flex; gap: 32px; }
.nav__links a { color: var(--text-dim); font-weight: 500; font-size: 0.9rem; position: relative; transition: color 0.2s; }
.nav__links a::after {
    content: ""; position: absolute; left: 0; bottom: -6px; width: 0; height: 2px;
    background: var(--grad); border-radius: 2px; transition: width 0.3s var(--ease);
}
.nav__links a:hover { color: var(--text); }
.nav__links a:hover::after { width: 100%; }
.nav__right { display: flex; align-items: center; gap: 16px; }
.nav__cta {
    padding: 9px 20px; border: 1px solid var(--border-2); border-radius: 999px;
    font-size: 0.86rem; font-weight: 600; color: var(--text); transition: all 0.25s var(--ease);
}
.nav__cta:hover { border-color: var(--violet); background: rgba(124,92,255,0.1); transform: translateY(-2px); }
.nav__burger { display: none; background: none; border: none; color: var(--text); font-size: 1.5rem; cursor: pointer; }

/* ---------- HERO ---------- */
.hero { min-height: 100vh; display: flex; align-items: center; position: relative; padding: 130px 0 90px; }
.hero__inner { display: grid; grid-template-columns: 1.25fr 1fr; gap: 56px; align-items: center; }

.status {
    display: inline-flex; align-items: center; gap: 9px;
    padding: 7px 16px; border: 1px solid var(--border); border-radius: 999px;
    background: rgba(45, 212, 191, 0.06); font-size: 0.82rem; font-weight: 500; color: var(--text-dim);
    margin-bottom: 26px;
}
.status__dot { width: 8px; height: 8px; border-radius: 50%; background: var(--teal); box-shadow: 0 0 0 0 rgba(45,212,191,0.6); animation: pulse 2s infinite; }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(45,212,191,0.5); } 70% { box-shadow: 0 0 0 10px rgba(45,212,191,0); } 100% { box-shadow: 0 0 0 0 rgba(45,212,191,0); } }

.hero__hi { color: var(--text-dim); font-size: 1.1rem; font-weight: 500; }
.hero__name { font-size: clamp(2.6rem, 6vw, 4.4rem); font-weight: 800; line-height: 1.05; letter-spacing: -1.5px; margin: 6px 0 10px; }
.hero__role { font-size: clamp(1.3rem, 3vw, 2rem); font-weight: 600; color: var(--text-dim); min-height: 1.4em; letter-spacing: -0.5px; }
.hero__role-text { color: var(--text); }
.caret { color: var(--violet); font-weight: 400; animation: blink 1s step-end infinite; margin-left: 2px; }
@keyframes blink { 50% { opacity: 0; } }
.hero__bio { color: var(--text-dim); font-size: 1.08rem; max-width: 520px; margin: 22px 0 32px; }
.hero__actions { display: flex; gap: 14px; flex-wrap: wrap; }
.hero__socials { display: flex; gap: 22px; margin-top: 34px; }
.hero__socials a {
    font-family: "JetBrains Mono", monospace; font-size: 0.85rem; color: var(--text-faint);
    position: relative; transition: color 0.25s;
}
.hero__socials a:hover { color: var(--text); }
.hero__socials a::before { content: "↗"; opacity: 0; margin-right: 2px; transition: opacity 0.25s; }
.hero__socials a:hover::before { opacity: 1; }

/* avatar */
.hero__visual { display: flex; justify-content: center; }
.avatar-ring { position: relative; width: clamp(260px, 32vw, 360px); aspect-ratio: 1; }
.avatar-ring__spin {
    position: absolute; inset: -3px; border-radius: 50%;
    background: conic-gradient(from 0deg, #7c5cff, #5b8cff, #2dd4bf, #7c5cff);
    animation: spin 7s linear infinite; filter: blur(2px); opacity: 0.9;
}
@keyframes spin { to { transform: rotate(360deg); } }
.avatar-ring__inner {
    position: absolute; inset: 7px; border-radius: 50%; overflow: hidden;
    background: var(--bg-alt); border: 4px solid var(--bg);
}
.avatar-ring__inner img { width: 100%; height: 100%; object-fit: cover; }
.avatar-badge {
    position: absolute; padding: 8px 14px; border-radius: 12px; font-family: "JetBrains Mono", monospace;
    font-size: 0.8rem; font-weight: 500; background: rgba(14,15,21,0.85); border: 1px solid var(--border-2);
    backdrop-filter: blur(8px); box-shadow: 0 8px 24px rgba(0,0,0,0.4); animation: float 4s ease-in-out infinite;
}
.avatar-badge--1 { top: 12%; left: -14%; color: var(--violet); }
.avatar-badge--2 { top: 48%; right: -16%; color: var(--blue); animation-delay: 1.3s; }
.avatar-badge--3 { bottom: 10%; left: 2%; color: var(--teal); animation-delay: 2.4s; }
@keyframes float { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-12px); } }

.scroll-cue { position: absolute; bottom: 30px; left: 50%; transform: translateX(-50%); width: 26px; height: 42px; border: 2px solid var(--border-2); border-radius: 14px; display: flex; justify-content: center; padding-top: 8px; }
.scroll-cue span { width: 4px; height: 8px; border-radius: 4px; background: var(--text-dim); animation: scroll 1.6s ease-in-out infinite; }
@keyframes scroll { 0% { opacity: 0; transform: translateY(0); } 40% { opacity: 1; } 80% { opacity: 0; transform: translateY(12px); } }

/* ---------- STATS ---------- */
.stats { padding: 10px 0 30px; }
.stats__inner {
    display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px;
    padding: 36px; border: 1px solid var(--border); border-radius: var(--radius);
    background: var(--grad-soft); position: relative; overflow: hidden;
}
.stats__inner::before { content: ""; position: absolute; inset: 0; background: rgba(10,11,15,0.55); z-index: 0; }
.stat { position: relative; z-index: 1; text-align: center; }
.stat__num { display: block; font-size: clamp(2rem, 4vw, 2.8rem); font-weight: 800; line-height: 1; letter-spacing: -1px; background: var(--grad); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.stat__label { display: block; margin-top: 8px; color: var(--text-dim); font-size: 0.88rem; font-weight: 500; }

/* ---------- SECTIONS ---------- */
.section { padding: 100px 0; position: relative; }
.section--alt { background: var(--bg-alt); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.section__eyebrow { font-family: "JetBrains Mono", monospace; font-size: 0.82rem; color: var(--teal); letter-spacing: 1px; margin-bottom: 12px; }
.section__title { font-size: clamp(1.9rem, 4vw, 2.8rem); font-weight: 800; letter-spacing: -1px; margin-bottom: 48px; }

/* reveal */
.reveal { opacity: 0; transform: translateY(34px); transition: opacity 0.7s var(--ease), transform 0.7s var(--ease); }
.reveal.show { opacity: 1; transform: none; }

/* ---------- HAKKIMDA ---------- */
.about { display: grid; grid-template-columns: 1.5fr 1fr; gap: 48px; align-items: start; }
.about__text { color: var(--text-dim); font-size: 1.06rem; margin-bottom: 18px; }
.about__main { max-width: 600px; }
.about__meta { list-style: none; display: flex; flex-direction: column; gap: 2px; border: 1px solid var(--border); border-radius: var(--radius-sm); overflow: hidden; }
.about__meta li { display: flex; flex-direction: column; gap: 3px; padding: 16px 20px; background: var(--card); border-bottom: 1px solid var(--border); font-weight: 600; }
.about__meta li:last-child { border-bottom: none; }
.about__meta span { color: var(--text-faint); font-size: 0.78rem; text-transform: uppercase; letter-spacing: 0.5px; font-weight: 500; }
.about__meta a { color: var(--blue); }
.about__meta a:hover { text-decoration: underline; }

/* ---------- YETENEKLER ---------- */
.skills { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.skill-group { background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); padding: 26px; transition: border-color 0.3s, transform 0.3s var(--ease); }
.skill-group:hover { border-color: var(--border-2); transform: translateY(-4px); }
.skill-group__title { font-size: 0.84rem; font-family: "JetBrains Mono", monospace; color: var(--teal); text-transform: uppercase; letter-spacing: 1px; margin-bottom: 22px; }
.skill { margin-bottom: 18px; }
.skill:last-child { margin-bottom: 0; }
.skill__head { display: flex; justify-content: space-between; margin-bottom: 8px; font-size: 0.92rem; }
.skill__name { font-weight: 600; }
.skill__level { color: var(--text-faint); font-family: "JetBrains Mono", monospace; font-size: 0.82rem; }
.skill__bar { height: 7px; border-radius: 99px; background: rgba(255,255,255,0.06); overflow: hidden; }
.skill__fill { height: 100%; width: 0; border-radius: 99px; background: var(--grad); transition: width 1.1s var(--ease); }

/* ---------- PROJELER ---------- */
.projects { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 26px; }
.project {
    display: flex; flex-direction: column; background: var(--card); border: 1px solid var(--border);
    border-radius: var(--radius); overflow: hidden; transition: transform 0.35s var(--ease), border-color 0.35s, box-shadow 0.35s;
    position: relative;
}
.project::before {
    content: ""; position: absolute; inset: 0; border-radius: var(--radius); padding: 1px;
    background: var(--grad); -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
    -webkit-mask-composite: xor; mask-composite: exclude; opacity: 0; transition: opacity 0.35s; pointer-events: none;
}
.project:hover { transform: translateY(-6px); box-shadow: 0 20px 50px rgba(0,0,0,0.4); }
.project:hover::before { opacity: 1; }
.project__media { position: relative; border: none; padding: 0; cursor: pointer; background: #000; aspect-ratio: 16/10; overflow: hidden; display: block; }
.project__media img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.5s var(--ease); }
.project__media:hover img { transform: scale(1.06); }
.project__count { position: absolute; bottom: 12px; right: 12px; padding: 5px 12px; border-radius: 999px; background: rgba(10,11,15,0.8); backdrop-filter: blur(6px); font-size: 0.76rem; font-weight: 600; border: 1px solid var(--border-2); }
.project__body { padding: 24px; display: flex; flex-direction: column; flex: 1; }
.project__top { display: flex; justify-content: space-between; align-items: center; margin-bottom: 14px; }
.project__icon { font-size: 1.3rem; color: var(--violet); }
.project__links { display: flex; gap: 14px; margin-left: auto; }
.project__links a { font-family: "JetBrains Mono", monospace; font-size: 0.82rem; color: var(--text-dim); transition: color 0.2s; }
.project__links a:hover { color: var(--teal); }
.project__name { font-size: 1.3rem; font-weight: 700; letter-spacing: -0.4px; margin-bottom: 10px; }
.project__desc { color: var(--text-dim); font-size: 0.96rem; margin-bottom: 18px; flex: 1; }
.project__tags { display: flex; flex-wrap: wrap; gap: 8px; }
.tag { font-family: "JetBrains Mono", monospace; font-size: 0.76rem; padding: 5px 11px; border-radius: 8px; background: rgba(124,92,255,0.08); border: 1px solid rgba(124,92,255,0.18); color: #b9a9ff; }

/* ---------- TIMELINE ---------- */
.timeline { position: relative; max-width: 760px; margin-left: 8px; }
.timeline::before { content: ""; position: absolute; left: 7px; top: 8px; bottom: 8px; width: 2px; background: linear-gradient(var(--violet), var(--teal)); opacity: 0.4; }
.tl-item { position: relative; padding: 0 0 40px 40px; }
.tl-item:last-child { padding-bottom: 0; }
.tl-item::before { content: ""; position: absolute; left: 0; top: 5px; width: 16px; height: 16px; border-radius: 50%; background: var(--bg); border: 3px solid var(--violet); box-shadow: 0 0 0 4px rgba(124,92,255,0.12); }
.tl-date { font-family: "JetBrains Mono", monospace; font-size: 0.8rem; color: var(--teal); margin-bottom: 6px; }
.tl-role { font-size: 1.2rem; font-weight: 700; letter-spacing: -0.3px; }
.tl-company { color: var(--blue); font-size: 0.92rem; font-weight: 600; margin: 3px 0 10px; }
.tl-desc { color: var(--text-dim); font-size: 0.96rem; }

/* ---------- REFERANSLAR ---------- */
.refs { display: grid; grid-template-columns: repeat(auto-fit, minmax(340px, 1fr)); gap: 24px; max-width: 720px; }
.ref { position: relative; background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); padding: 32px 28px 26px; }
.ref__quote { position: absolute; top: 6px; right: 24px; font-size: 5rem; line-height: 1; color: var(--violet); opacity: 0.18; font-family: Georgia, serif; }
.ref__stars { color: #ffce4f; letter-spacing: 2px; margin-bottom: 14px; }
.ref__msg { color: var(--text-dim); font-size: 1rem; font-style: italic; margin-bottom: 22px; }
.ref__who { display: flex; align-items: center; gap: 14px; }
.ref__avatar { width: 52px; height: 52px; border-radius: 50%; object-fit: cover; border: 2px solid var(--border-2); }
.ref__name { font-weight: 700; }
.ref__title { color: var(--text-faint); font-size: 0.84rem; }

/* ---------- ILETISIM ---------- */
.contact { display: grid; grid-template-columns: 1fr 1.2fr; gap: 52px; align-items: start; }
.contact__lead { color: var(--text-dim); font-size: 1.06rem; margin-bottom: 30px; }
.contact__info { list-style: none; display: flex; flex-direction: column; gap: 16px; margin-bottom: 28px; }
.contact__info li { display: flex; align-items: center; gap: 14px; font-weight: 500; }
.contact__info a:hover { color: var(--teal); }
.ico { display: inline-flex; align-items: center; justify-content: center; width: 42px; height: 42px; border-radius: 12px; background: var(--grad-soft); border: 1px solid var(--border); color: var(--text); font-size: 1.1rem; }
.contact__socials { display: flex; gap: 12px; }
.contact__socials a { padding: 8px 18px; border: 1px solid var(--border-2); border-radius: 999px; font-size: 0.85rem; font-weight: 600; transition: all 0.25s var(--ease); }
.contact__socials a:hover { border-color: var(--violet); background: rgba(124,92,255,0.1); transform: translateY(-2px); }

.contact__form { background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); padding: 32px; }
.contact__row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.field { display: flex; flex-direction: column; gap: 8px; margin-bottom: 18px; }
.field label { font-size: 0.84rem; font-weight: 600; color: var(--text-dim); }
.field input, .field textarea {
    background: rgba(255,255,255,0.03); border: 1px solid var(--border); border-radius: 12px;
    padding: 13px 15px; color: var(--text); font-family: inherit; font-size: 0.96rem; resize: vertical;
    transition: border-color 0.25s, background 0.25s, box-shadow 0.25s;
}
.field input:focus, .field textarea:focus { outline: none; border-color: var(--violet); background: rgba(124,92,255,0.05); box-shadow: 0 0 0 3px rgba(124,92,255,0.12); }
.contact__form .btn { width: 100%; justify-content: center; margin-top: 4px; }
.contact__status { margin-top: 16px; font-size: 0.9rem; min-height: 1.2em; text-align: center; }
.contact__status.ok { color: var(--teal); }
.contact__status.err { color: #ff6b6b; }

/* ---------- FOOTER ---------- */
.footer { border-top: 1px solid var(--border); padding: 32px 0; }
.footer__inner { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 12px; }
.footer__name { font-weight: 700; }
.footer__copy { color: var(--text-faint); font-size: 0.86rem; }

/* ---------- LIGHTBOX ---------- */
.lightbox { position: fixed; inset: 0; z-index: 1000; background: rgba(5,6,9,0.92); backdrop-filter: blur(10px); display: none; align-items: center; justify-content: center; opacity: 0; transition: opacity 0.3s; }
.lightbox.open { display: flex; opacity: 1; }
.lightbox__img { max-width: 86vw; max-height: 84vh; border-radius: 12px; box-shadow: 0 30px 80px rgba(0,0,0,0.6); }
.lightbox__close, .lightbox__nav { position: absolute; background: rgba(255,255,255,0.08); border: 1px solid var(--border-2); color: #fff; cursor: pointer; border-radius: 50%; display: flex; align-items: center; justify-content: center; transition: background 0.2s, transform 0.2s; }
.lightbox__close { top: 24px; right: 24px; width: 46px; height: 46px; font-size: 1.4rem; }
.lightbox__nav { top: 50%; transform: translateY(-50%); width: 54px; height: 54px; font-size: 2rem; }
.lightbox__prev { left: 24px; }
.lightbox__next { right: 24px; }
.lightbox__close:hover, .lightbox__nav:hover { background: rgba(124,92,255,0.4); }
.lightbox__count { position: absolute; bottom: 26px; left: 50%; transform: translateX(-50%); font-family: "JetBrains Mono", monospace; font-size: 0.85rem; color: var(--text-dim); }

/* ---------- RESPONSIVE ---------- */
@media (max-width: 900px) {
    .hero__inner { grid-template-columns: 1fr; gap: 40px; text-align: center; }
    .hero__visual { order: -1; }
    .hero__actions, .hero__socials { justify-content: center; }
    .hero__bio { margin-left: auto; margin-right: auto; }
    .about { grid-template-columns: 1fr; gap: 32px; }
    .skills { grid-template-columns: 1fr; }
    .contact { grid-template-columns: 1fr; gap: 36px; }
    .stats__inner { grid-template-columns: repeat(2, 1fr); gap: 28px; }
}
@media (max-width: 720px) {
    .nav__links {
        position: fixed; top: 70px; left: 0; right: 0; flex-direction: column; gap: 0;
        background: rgba(10,11,15,0.96); backdrop-filter: blur(16px); border-bottom: 1px solid var(--border);
        padding: 0; max-height: 0; overflow: hidden; transition: max-height 0.4s var(--ease);
    }
    .nav__links.open { max-height: 360px; padding: 12px 0; }
    .nav__links a { padding: 14px 28px; }
    .nav__links a::after { display: none; }
    .nav__burger { display: block; }
    .nav__cta { display: none; }
    .section { padding: 72px 0; }
    .contact__row { grid-template-columns: 1fr; }
}
@media (max-width: 440px) {
    .container { padding: 0 18px; }
    .stats__inner { grid-template-columns: 1fr 1fr; padding: 26px 18px; }
    .avatar-badge--1 { left: -6%; }
    .avatar-badge--2 { right: -6%; }
}

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

.project__media--contain { background: #0a0b0f; }
.project__media--contain img { object-fit: contain; }
