/* ================= TOKENS ================= */
:root {
  --bg: #f7f7f5;
  --bg-2: #ffffff;
  --text: #111214;
  --muted: #6b6f76;
  --line: #e4e4e1;
  --card: rgba(255, 255, 255, 0.82);
  --accent: #111214;
  --accent-2: #2f6bff;
  --btn-text: #ffffff;
  --shadow: 0 10px 30px -12px rgba(0, 0, 0, 0.18);
  --topo: rgba(0, 0, 0, 0.07);
  --outline: rgba(0, 0, 0, 0.08);
  --radius: 18px;
}
[data-theme="dark"] {
  --bg: #070b14;
  --bg-2: #0d1322;
  --text: #f2f4f8;
  --muted: #8d96a8;
  --line: #1c2436;
  --card: rgba(16, 23, 40, 0.78);
  --accent: #2f6bff;
  --accent-2: #2f6bff;
  --btn-text: #ffffff;
  --shadow: 0 14px 40px -14px rgba(0, 0, 0, 0.7);
  --topo: rgba(120, 150, 210, 0.11);
  --outline: rgba(255, 255, 255, 0.07);
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  font-family: "Poppins", system-ui, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  overflow-x: hidden;
  transition: background 0.5s, color 0.5s;
}
body.loading { overflow: hidden; }
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
button { font: inherit; cursor: pointer; border: 0; background: none; color: inherit; }
::selection { background: var(--accent-2); color: #fff; }

#topo {
  position: fixed; inset: 0; width: 100%; height: 100%;
  z-index: -1; pointer-events: none;
}

/* ================= PRELOADER ================= */
#preloader {
  position: fixed; inset: 0; z-index: 100;
  background: var(--bg);
  display: grid; place-content: center; justify-items: center; gap: 14px;
  transition: opacity 0.6s, visibility 0.6s;
}
#preloader.done { opacity: 0; visibility: hidden; }
.pre-name { font-weight: 800; letter-spacing: 0.3em; font-size: 0.85rem; color: var(--muted); }
.pre-bar { width: 200px; height: 2px; background: var(--line); overflow: hidden; border-radius: 2px; }
.pre-bar span { display: block; height: 100%; width: 0; background: var(--text); transition: width 0.15s; }
.pre-pct { font-size: 0.7rem; color: var(--muted); font-variant-numeric: tabular-nums; }

/* ================= NAV ================= */
.nav-wrap {
  position: fixed; top: 18px; left: 0; right: 0; z-index: 50;
  display: flex; justify-content: center; padding: 0 16px;
}
.nav {
  width: min(1040px, 100%);
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 10px 14px 10px 26px;
  background: var(--card);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  border: 1px solid var(--line);
  border-radius: 999px;
  box-shadow: var(--shadow);
}
.logo { font-weight: 800; font-size: 1.1rem; letter-spacing: -0.02em; }
.nav-links { list-style: none; display: flex; gap: 4px; position: relative; }
.nav-links a {
  position: relative; z-index: 1;
  display: block; padding: 7px 16px; border-radius: 999px;
  font-size: 0.88rem; color: var(--muted); transition: color 0.3s;
}
.nav-links a.active, .nav-links a:hover { color: var(--text); }
[data-theme="dark"] .nav-links a.active { color: #fff; }
.nav-indicator {
  position: absolute; top: 0; height: 100%; border-radius: 999px;
  background: var(--line);
  transition: left 0.45s cubic-bezier(.6,.05,.2,1), width 0.45s cubic-bezier(.6,.05,.2,1);
}
[data-theme="dark"] .nav-indicator { background: var(--accent-2); box-shadow: 0 6px 18px -4px rgba(47,107,255,.7); }
.theme-toggle {
  width: 38px; height: 38px; border-radius: 50%;
  display: grid; place-items: center; transition: background 0.3s, transform 0.5s;
}
.theme-toggle:hover { background: var(--line); transform: rotate(40deg); }
.theme-toggle svg { width: 19px; height: 19px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }
.theme-toggle .moon { display: none; }
[data-theme="dark"] .theme-toggle .sun { display: none; }
[data-theme="dark"] .theme-toggle .moon { display: block; }
.burger { display: none; width: 38px; height: 38px; position: relative; }
.burger span { position: absolute; left: 10px; right: 10px; height: 2px; background: currentColor; transition: 0.3s; }
.burger span:first-child { top: 15px; } .burger span:last-child { top: 22px; }
.burger.open span:first-child { top: 18px; transform: rotate(45deg); }
.burger.open span:last-child { top: 18px; transform: rotate(-45deg); }

/* ================= COMMON ================= */
.section { width: min(1100px, 100% - 40px); margin: 0 auto; padding: 120px 0 40px; }
.eyebrow { text-align: center; font-size: 0.72rem; letter-spacing: 0.35em; color: var(--muted); font-weight: 600; }
.section-title {
  text-align: center; font-size: clamp(2.2rem, 5vw, 3.4rem);
  font-weight: 800; letter-spacing: -0.03em; margin-bottom: 56px;
}
.card {
  background: var(--card); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 28px;
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  box-shadow: var(--shadow);
}
.btn {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 13px 24px; border-radius: 10px; font-size: 0.88rem; font-weight: 500;
  transition: transform 0.25s, box-shadow 0.25s, background 0.3s;
}
.btn span { transition: transform 0.25s; }
.btn:hover { transform: translateY(-2px); }
.btn:hover span { transform: translateX(3px); }
.btn-dark { background: var(--accent); color: var(--btn-text); box-shadow: var(--shadow); }
.btn-ghost { border: 1px solid var(--line); background: var(--bg-2); }
.btn.full { width: 100%; justify-content: center; letter-spacing: 0.15em; font-size: 0.78rem; }
.pills { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 12px; }
.pills span {
  font-size: 0.68rem; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase;
  padding: 4px 10px; border-radius: 6px; background: var(--line);
}

.reveal { opacity: 0; transform: translateY(36px); transition: opacity 0.9s ease, transform 0.9s cubic-bezier(.2,.7,.2,1); }
.reveal.in { opacity: 1; transform: none; }

/* ================= HERO ================= */
.hero {
  min-height: 100vh;
  width: min(1100px, 100% - 40px); margin: 0 auto;
  display: grid; grid-template-columns: 1.1fr 1fr; align-items: center; gap: 40px;
  padding-top: 110px;
}
.hero-title { font-size: clamp(2.8rem, 6.5vw, 5rem); font-weight: 800; line-height: 1.05; letter-spacing: -0.04em; }
[data-theme="dark"] .hero-title .accent { color: var(--accent-2); }
.hero-role { font-size: clamp(1.2rem, 2.4vw, 1.7rem); font-weight: 600; margin: 14px 0 20px; min-height: 1.6em; }
.caret { animation: blink 0.9s steps(1) infinite; font-weight: 300; margin-left: 2px; }
@keyframes blink { 50% { opacity: 0; } }
.hero-desc { color: var(--muted); max-width: 470px; font-size: 0.95rem; }
.hero-btns { display: flex; gap: 12px; margin: 32px 0 44px; flex-wrap: wrap; }
.connect small { font-size: 0.65rem; letter-spacing: 0.3em; color: var(--muted); font-weight: 600; }
.socials { display: flex; gap: 8px; margin-top: 10px; }
.socials a {
  width: 38px; height: 38px; display: grid; place-items: center;
  border: 1px solid var(--line); border-radius: 10px; font-size: 1.05rem;
  transition: background 0.3s, transform 0.3s;
}
.socials a:hover { background: var(--text); color: var(--bg); transform: translateY(-3px); }
.socials svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; }

.hero-right { position: relative; display: grid; place-items: center; min-height: 460px; }
.photo-ring {
  width: min(380px, 80vw); aspect-ratio: 1; border-radius: 50%;
  padding: 10px; background: var(--bg-2); border: 1px solid var(--line);
  box-shadow: var(--shadow);
}
.photo { width: 100%; height: 100%; object-fit: cover; border-radius: 50%; filter: grayscale(1) contrast(1.05); transition: filter 0.6s; }
.photo-ring:hover .photo { filter: grayscale(0); }
.chip {
  position: absolute; display: flex; align-items: center; gap: 10px;
  padding: 10px 16px; border-radius: 12px; font-size: 0.78rem; font-weight: 500;
  background: var(--card); border: 1px solid var(--line); box-shadow: var(--shadow);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  animation: float 5s ease-in-out infinite; white-space: nowrap;
}
.chip-ic {
  width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center;
  background: var(--accent); color: #fff; font-size: 0.7rem; font-weight: 700;
}
.chip-1 { left: -10px; bottom: 30%; }
.chip-2 { left: 4%; bottom: 14%; animation-delay: -1.6s; }
.chip-3 { right: -6px; top: 14%; animation-delay: -3.2s; }
@keyframes float { 50% { transform: translateY(-12px); } }

/* ================= MARQUEE ================= */
.marquee { padding: 30px 0; overflow: hidden; user-select: none; }
.marquee-row { overflow: hidden; white-space: nowrap; }
.track { display: inline-flex; animation: slide 40s linear infinite; }
.marquee-row.reverse .track { animation-direction: reverse; }
.track span {
  font-size: clamp(3rem, 9vw, 7.5rem); font-weight: 800; letter-spacing: -0.03em;
  color: var(--outline); padding-right: 0.6em; line-height: 1.15;
}
.marquee-row.reverse .track span { color: transparent; -webkit-text-stroke: 1.5px var(--outline); }
@keyframes slide { to { transform: translateX(-50%); } }

/* ================= ABOUT ================= */
.about-grid { display: grid; grid-template-columns: 0.85fr 1.4fr; gap: 56px; align-items: start; }
.about-photo {
  border-radius: 22px; overflow: hidden; aspect-ratio: 4 / 5;
  border: 1px solid var(--line); box-shadow: var(--shadow); background: var(--bg-2);
}
.about-photo img { width: 100%; height: 100%; object-fit: cover; filter: grayscale(1); transition: transform 0.8s, filter 0.8s; }
.about-photo:hover img { transform: scale(1.04); filter: grayscale(0); }
.about-cols { display: grid; grid-template-columns: 1fr 1fr; gap: 32px; }
.about-cols h3 { font-size: 1.05rem; margin-bottom: 10px; padding-bottom: 10px; border-bottom: 1px solid var(--line); }
.about-cols p { color: var(--muted); font-size: 0.9rem; }
.details { margin-top: 44px; }
.details-title { border-left: 3px solid var(--text); padding-left: 14px; font-size: 1.05rem; margin-bottom: 22px; }
.details-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px 32px; }
.details-grid small { font-size: 0.65rem; letter-spacing: 0.2em; color: var(--muted); font-weight: 600; }
.details-grid p { font-weight: 500; font-size: 0.95rem; }
.details-grid a { border-bottom: 1px solid var(--muted); }

/* ================= JOURNEY ================= */
.journey { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; }
.tl-head { font-size: 1.2rem; margin-bottom: 22px; }
.timeline { position: relative; }
.tl-item { position: relative; padding-left: 50px; margin-bottom: 18px; }
.tl-item::before {
  content: ""; position: absolute; left: 15px; top: 34px; bottom: -18px; width: 2px; background: var(--line);
}
.tl-item:last-child::before { display: none; }
.tl-num {
  position: absolute; left: 0; top: 4px; width: 32px; height: 32px; border-radius: 50%;
  display: grid; place-items: center; font-size: 0.78rem; font-weight: 700;
  background: var(--bg-2); border: 2px solid var(--text); transition: 0.3s;
}
.tl-item:hover .tl-num { background: var(--accent); color: #fff; border-color: var(--accent); }
.tl-card {
  background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 18px 20px;
  transition: transform 0.3s, box-shadow 0.3s;
}
.tl-item:hover .tl-card { transform: translateX(6px); box-shadow: var(--shadow); }
.tl-top { display: flex; justify-content: space-between; align-items: center; gap: 10px; font-size: 0.85rem; }
.tag { font-size: 0.68rem; padding: 3px 10px; border-radius: 999px; border: 1px solid var(--line); color: var(--muted); white-space: nowrap; }
.tl-card h4 { font-size: 1rem; margin: 8px 0 4px; }
.tl-card p { font-size: 0.85rem; color: var(--muted); }

/* Folders */
.folders { display: grid; grid-template-columns: repeat(3, 1fr); gap: 32px; margin-top: 90px; }
.folder { position: relative; height: 210px; display: block; perspective: 800px; }
.folder-back {
  position: absolute; inset: 18px 0 0; border-radius: 6px 16px 16px 16px;
  background: #1b2130;
}
.folder-back::before {
  content: ""; position: absolute; left: 0; top: -18px; width: 42%; height: 26px;
  background: #1b2130; border-radius: 12px 12px 0 0;
}
.papers span {
  position: absolute; left: 12%; right: 12%; top: 14px; height: 140px; border-radius: 8px;
  background: #fff; box-shadow: 0 4px 14px rgba(0,0,0,.2);
  transition: transform 0.5s cubic-bezier(.2,.8,.2,1);
}
.papers span:nth-child(1) { background: linear-gradient(135deg, #ffe9b3, #fff7e0); transform: rotate(-6deg); }
.papers span:nth-child(2) { background: linear-gradient(135deg, #cfe0ff, #f2f6ff); transform: rotate(4deg); }
.papers span:nth-child(3) { background: linear-gradient(135deg, #ffffff, #eef0f4); }
.folder:hover .papers span:nth-child(1) { transform: translateY(-40px) rotate(-12deg) translateX(-20px); }
.folder:hover .papers span:nth-child(2) { transform: translateY(-46px) rotate(10deg) translateX(20px); }
.folder:hover .papers span:nth-child(3) { transform: translateY(-30px); }
.folder-front {
  position: absolute; left: 0; right: 0; bottom: 0; height: 128px; padding: 18px 20px;
  border-radius: 16px; color: #fff;
  background: linear-gradient(180deg, rgba(45,53,72,.92), rgba(22,27,40,.97));
  backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
  border-top: 1px solid rgba(255,255,255,.12);
  display: flex; flex-direction: column; justify-content: flex-end;
  transform-origin: bottom; transition: transform 0.5s cubic-bezier(.2,.8,.2,1);
}
.folder:hover .folder-front { transform: rotateX(-14deg); }
.folder-front b { font-size: 1.9rem; line-height: 1; }
.folder-front small { font-size: 0.78rem; opacity: 0.7; }
.folder-front i {
  position: absolute; right: 16px; bottom: 18px; width: 34px; height: 34px; border-radius: 50%;
  display: grid; place-items: center; font-style: normal; background: rgba(255,255,255,.1);
}

/* ================= SKILLS ================= */
.skill-group {
  display: grid; grid-template-columns: 1fr 2fr; gap: 32px; align-items: center;
  padding: 32px 0; border-bottom: 1px solid var(--line);
}
.skill-group:last-child { border-bottom: 0; }
.skill-info h3 { font-size: 1.15rem; margin-bottom: 6px; }
.skill-info p { color: var(--muted); font-size: 0.85rem; }
.skill-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(118px, 1fr)); gap: 12px; }
.skill {
  display: grid; justify-items: center; gap: 10px; padding: 20px 10px;
  background: var(--card); border: 1px solid var(--line); border-radius: 14px;
  font-size: 0.8rem; font-weight: 500; transition: transform 0.3s, box-shadow 0.3s;
}
.skill i { font-size: 1.9rem; filter: grayscale(1); opacity: 0.8; transition: 0.3s; }
.skill:hover { transform: translateY(-5px); box-shadow: var(--shadow); }
.skill:hover i { filter: none; opacity: 1; transform: scale(1.12); }

/* ================= BIG WORD ================= */
.big-word { overflow: hidden; padding: 80px 0 0; text-align: center; }
.big-word h2 {
  font-size: clamp(4rem, 17vw, 15rem); font-weight: 900; letter-spacing: -0.04em; line-height: 0.9;
  background: linear-gradient(180deg, #ffffff 0%, #c9ced8 35%, #6d7484 60%, #e9edf3 78%, #8a91a0 100%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
  filter: drop-shadow(0 8px 18px rgba(0,0,0,.25));
  transform: scale(var(--s, 0.7)); opacity: var(--o, 0.2);
  will-change: transform;
}
[data-theme="light"] .big-word h2 {
  background: linear-gradient(180deg, #2b2e35 0%, #8a8f99 40%, #1a1c21 62%, #a4a9b3 80%, #34373e 100%);
  -webkit-background-clip: text; background-clip: text;
}

/* ================= PROJECTS ================= */
.works { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.work {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; display: flex; flex-direction: column;
  transition: transform 0.4s, box-shadow 0.4s;
}
.work:hover { transform: translateY(-8px); box-shadow: var(--shadow); }
.work-shot { aspect-ratio: 16 / 10; display: grid; place-items: center; overflow: hidden; }
.shot-1 { background: linear-gradient(135deg, #111827, #374151); }
.shot-2 { background: linear-gradient(135deg, #0b1324, #2f6bff); }
.shot-3 { background: linear-gradient(135deg, #e5e7eb, #9ca3af); }
.mock {
  width: 72%; height: 64%; border-radius: 8px; background: rgba(255,255,255,.9);
  display: grid; grid-template-rows: 14px 1fr 1fr; gap: 8px; padding: 10px;
  transition: transform 0.6s; box-shadow: 0 20px 40px -10px rgba(0,0,0,.4);
}
.mock i { display: block; border-radius: 4px; background: #e5e7eb; }
.mock i:first-child { background: #d1d5db; width: 40%; }
.work:hover .mock { transform: scale(1.06) rotate(-1.5deg); }
.work-body { padding: 22px; display: flex; flex-direction: column; flex: 1; }
.work-body h3 { font-size: 1.15rem; }
.work-body p { font-size: 0.86rem; color: var(--muted); margin-top: 6px; }
.btn-outline {
  margin-top: auto; padding-top: 0; align-self: stretch; text-align: center;
  border: 1px solid var(--text); border-radius: 8px; padding: 10px;
  font-size: 0.72rem; letter-spacing: 0.15em; font-weight: 600; transition: 0.3s;
}
.work-body .pills { margin-bottom: 18px; }
.btn-outline:hover { background: var(--text); color: var(--bg); }

/* ================= GALLERY ================= */
.scatter { position: relative; height: 460px; }
.polaroid {
  position: absolute; width: 190px; padding: 10px 10px 0; background: #fff;
  border-radius: 6px; box-shadow: 0 16px 34px -10px rgba(0,0,0,.35);
  cursor: grab; transition: box-shadow 0.3s; user-select: none; touch-action: none;
}
.polaroid:active { cursor: grabbing; box-shadow: 0 26px 50px -10px rgba(0,0,0,.45); }
.polaroid figcaption { color: #333; font-size: 0.78rem; text-align: center; padding: 8px 0 10px; font-weight: 500; }
.ph { aspect-ratio: 4 / 3; border-radius: 3px; }
.g1 { background: linear-gradient(135deg, #fde68a, #f59e0b); }
.g2 { background: linear-gradient(135deg, #93c5fd, #1d4ed8); }
.g3 { background: linear-gradient(135deg, #d1d5db, #4b5563); }
.g4 { background: linear-gradient(135deg, #fecaca, #b91c1c); }
.g5 { background: linear-gradient(135deg, #a7f3d0, #047857); }
.p1 { left: 4%; top: 30px; transform: rotate(-8deg); }
.p2 { left: 24%; top: 160px; transform: rotate(5deg); }
.p3 { left: 42%; top: 20px; transform: rotate(-3deg); }
.p4 { left: 60%; top: 170px; transform: rotate(9deg); }
.p5 { left: 76%; top: 40px; transform: rotate(-6deg); }
.hint { text-align: center; color: var(--muted); font-size: 0.8rem; }

/* ================= CONTACT ================= */
.contact-grid { display: grid; grid-template-columns: 1fr 1.5fr; gap: 22px; }
.contact-side { display: grid; gap: 22px; align-content: start; }
.card h3 { font-size: 1.3rem; margin-bottom: 8px; }
.card > p { color: var(--muted); font-size: 0.9rem; }
.find {
  display: flex; align-items: center; gap: 14px; padding: 12px; border-radius: 12px;
  margin-top: 8px; transition: background 0.3s;
}
.find:hover { background: var(--line); }
.find i, .find b {
  width: 40px; height: 40px; display: grid; place-items: center; border-radius: 10px;
  background: var(--text); color: var(--bg); font-size: 1.1rem; font-style: normal;
}
.find span { display: grid; font-weight: 600; font-size: 0.9rem; line-height: 1.3; }
.find small { color: var(--muted); font-weight: 400; font-size: 0.76rem; }
.contact-form h3 { margin-bottom: 22px; }
.contact-form label { display: grid; gap: 6px; font-size: 0.65rem; letter-spacing: 0.2em; font-weight: 600; color: var(--muted); margin-bottom: 16px; }
.contact-form input, .contact-form textarea {
  font: inherit; font-size: 0.9rem; letter-spacing: 0; color: var(--text);
  background: var(--bg); border: 1px solid var(--line); border-radius: 10px; padding: 12px 14px;
  outline: none; transition: border 0.3s, box-shadow 0.3s; resize: vertical;
}
.contact-form input:focus, .contact-form textarea:focus { border-color: var(--accent-2); box-shadow: 0 0 0 3px rgba(47,107,255,.15); }

.footer { text-align: center; padding: 60px 20px 40px; color: var(--muted); font-size: 0.8rem; }

/* ================= CHAT ================= */
.chat-fab {
  position: fixed; right: 24px; bottom: 24px; z-index: 60;
  width: 56px; height: 56px; border-radius: 50%; display: grid; place-items: center;
  background: var(--accent); color: #fff; box-shadow: 0 12px 30px -8px rgba(0,0,0,.45);
  transition: transform 0.3s;
}
.chat-fab:hover { transform: scale(1.08); }
.chat-fab svg { width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linejoin: round; stroke-linecap: round; }
.ai-badge {
  position: absolute; top: -4px; right: -4px; font-size: 0.6rem; font-weight: 700;
  background: var(--accent-2); color: #fff; padding: 2px 6px; border-radius: 999px; border: 2px solid var(--bg);
}
[data-theme="light"] .ai-badge { background: #22c55e; }
.chat {
  position: fixed; right: 24px; bottom: 92px; z-index: 60;
  width: min(360px, calc(100vw - 32px)); height: min(500px, 70vh);
  display: flex; flex-direction: column;
  background: var(--bg-2); border: 1px solid var(--line); border-radius: 20px;
  box-shadow: 0 30px 60px -20px rgba(0,0,0,.4);
  transform: translateY(20px) scale(0.96); opacity: 0; visibility: hidden;
  transform-origin: bottom right; transition: 0.35s cubic-bezier(.2,.8,.2,1);
}
.chat.open { transform: none; opacity: 1; visibility: visible; }
.chat-head { display: flex; align-items: center; gap: 12px; padding: 16px; border-bottom: 1px solid var(--line); }
.chat-head > div:nth-child(2) { flex: 1; display: grid; line-height: 1.3; }
.chat-head strong { font-size: 0.92rem; }
.chat-head small { font-size: 0.72rem; color: #22c55e; display: flex; align-items: center; gap: 5px; }
.chat-head small i { width: 7px; height: 7px; border-radius: 50%; background: #22c55e; }
.chat-av { width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; background: var(--line); font-weight: 700; font-size: 0.8rem; }
#chatClose { width: 30px; height: 30px; border-radius: 50%; }
#chatClose:hover { background: var(--line); }
.chat-body { flex: 1; overflow-y: auto; padding: 16px; display: flex; flex-direction: column; gap: 10px; }
.msg { max-width: 85%; padding: 10px 14px; border-radius: 14px; font-size: 0.84rem; line-height: 1.5; animation: pop 0.3s ease; }
.msg.bot { background: var(--bg); border: 1px solid var(--line); border-bottom-left-radius: 4px; }
.msg.user { align-self: flex-end; background: var(--accent); color: #fff; border-bottom-right-radius: 4px; }
.msg time { display: block; font-size: 0.62rem; opacity: 0.55; margin-top: 4px; }
.typing span { display: inline-block; width: 6px; height: 6px; margin-right: 3px; border-radius: 50%; background: var(--muted); animation: dot 1s infinite; }
.typing span:nth-child(2) { animation-delay: 0.15s; } .typing span:nth-child(3) { animation-delay: 0.3s; }
@keyframes dot { 50% { transform: translateY(-4px); opacity: 0.4; } }
@keyframes pop { from { opacity: 0; transform: translateY(6px); } }
.chat-quick { display: flex; gap: 6px; flex-wrap: wrap; padding: 0 16px 10px; }
.chat-quick button { font-size: 0.72rem; padding: 5px 10px; border: 1px solid var(--line); border-radius: 999px; }
.chat-quick button:hover { background: var(--line); }
.chat-input { display: flex; gap: 8px; padding: 12px; border-top: 1px solid var(--line); }
.chat-input input { flex: 1; font: inherit; font-size: 0.85rem; color: var(--text); background: var(--bg); border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; outline: none; }
.chat-input button { width: 40px; border-radius: 10px; background: var(--accent); color: #fff; }

/* ================= RESPONSIVE ================= */
@media (max-width: 900px) {
  .burger { display: block; }
  .nav { padding-left: 20px; flex-wrap: wrap; border-radius: 26px; }
  .nav-links {
    order: 3; width: 100%; flex-direction: column; gap: 2px;
    max-height: 0; overflow: hidden; transition: max-height 0.4s;
  }
  .nav-links.open { max-height: 300px; padding-bottom: 8px; }
  .nav-indicator { display: none; }
  .nav-links a.active { background: var(--line); }
  [data-theme="dark"] .nav-links a.active { background: var(--accent-2); }
  .theme-toggle { margin-left: auto; }
  .hero { grid-template-columns: 1fr; text-align: left; padding-top: 130px; }
  .hero-right { min-height: 380px; }
  .about-grid, .journey, .contact-grid { grid-template-columns: 1fr; }
  .about-photo { max-width: 360px; }
  .works { grid-template-columns: 1fr 1fr; }
  .skill-group { grid-template-columns: 1fr; }
  .folders { gap: 16px; }
  .scatter { height: 620px; }
  .p1 { left: 2%; } .p2 { left: 40%; top: 120px; } .p3 { left: 8%; top: 280px; } .p4 { left: 48%; top: 330px; } .p5 { left: 20%; top: 450px; }
}
@media (max-width: 600px) {
  .about-cols, .details-grid { grid-template-columns: 1fr; }
  .works { grid-template-columns: 1fr; }
  .folders { grid-template-columns: 1fr; gap: 40px; }
  .chip { font-size: 0.7rem; padding: 8px 12px; }
  .chip-1 { left: 0; } .chip-3 { right: 0; }
  .polaroid { width: 150px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.001ms !important; transition-duration: 0.001ms !important; }
  .reveal { opacity: 1; transform: none; }
}

/* ===== additions for real content ===== */
.ic-txt {
  width: 1.9rem; height: 1.9rem; display: grid; place-items: center;
  font-size: 1.3rem; line-height: 1; opacity: 0.8; transition: 0.3s;
}
.skill:hover .ic-txt { opacity: 1; transform: scale(1.12); }
.ic-svg { width: 1.9rem; height: 1.9rem; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; opacity: .8; transition: .3s; }
.skill:hover .ic-svg { opacity: 1; transform: scale(1.12); }
.pills.soft { margin-top: 16px; }
.pills.soft span { text-transform: none; letter-spacing: 0; font-size: 0.78rem; font-weight: 500; padding: 6px 12px; border-radius: 999px; }
.folder-front b { white-space: nowrap; }
.ph { display: grid; place-items: center; }
.ph span { color: rgba(255,255,255,.92); font-weight: 800; font-size: 1.15rem; letter-spacing: .04em; text-shadow: 0 2px 8px rgba(0,0,0,.25); }
.polaroid figcaption { font-size: 0.72rem; line-height: 1.35; padding: 8px 4px 10px; }
.g6 { background: linear-gradient(135deg, #c4b5fd, #6d28d9); }
.g7 { background: linear-gradient(135deg, #99f6e4, #0f766e); }

/* ===== badges + real certificates ===== */
.sub-head { text-align: center; font-size: 1.05rem; margin: 10px 0 26px; color: var(--muted); font-weight: 600; letter-spacing: .02em; }
.badges { display: flex; flex-wrap: wrap; justify-content: center; gap: 22px; margin-bottom: 70px; }
.badge { width: 128px; text-align: center; }
.badge img {
  width: 112px; height: 112px; margin: 0 auto; border-radius: 22px;
  box-shadow: 0 12px 26px -12px rgba(0,0,0,.45);
  transition: transform .4s cubic-bezier(.2,.8,.2,1), box-shadow .4s;
}
.badge:hover img { transform: translateY(-8px) rotate(-4deg) scale(1.06); box-shadow: 0 22px 36px -14px rgba(0,0,0,.5); }
.badge figcaption { font-size: .72rem; font-weight: 600; line-height: 1.35; margin-top: 12px; }
.badge small, .polaroid small { display: block; font-weight: 400; color: var(--muted); font-size: .68rem; margin-top: 2px; }
.polaroid small { color: #777; }
.polaroid { width: 250px; }
.ph-img { width: 100%; aspect-ratio: 1014 / 698; object-fit: cover; border-radius: 3px; display: block; pointer-events: none; border: 1px solid #eee; }
.scatter { height: 660px; }
.p1 { left: 0%;   top: 14px;  transform: rotate(-5deg); }
.p2 { left: 24.5%; top: 0;    transform: rotate(3deg); }
.p3 { left: 49%;  top: 22px;  transform: rotate(-2deg); }
.p4 { left: 74%;  top: 6px;   transform: rotate(4deg); }
.p5 { left: 1.5%; top: 330px; transform: rotate(3deg); }
.p6 { left: 26%;  top: 345px; transform: rotate(-4deg); }
.p7 { left: 50.5%; top: 320px; transform: rotate(5deg); }
.p8 { left: 75%;  top: 340px; transform: rotate(-3deg); }
@media (max-width: 900px) {
  .scatter { height: 1250px; }
  .polaroid { width: 200px; }
  .p1 { left: 2%;  top: 0; }     .p2 { left: 48%; top: 60px; }
  .p3 { left: 4%;  top: 280px; } .p4 { left: 50%; top: 340px; }
  .p5 { left: 2%;  top: 560px; } .p6 { left: 48%; top: 620px; }
  .p7 { left: 4%;  top: 840px; } .p8 { left: 50%; top: 900px; }
}
@media (max-width: 600px) {
  .polaroid { width: 160px; }
  .badge { width: 100px; } .badge img { width: 90px; height: 90px; }
}

/* ===== projects ===== */
.work-filter { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin: -24px 0 36px; }
.work-filter button {
  padding: 8px 16px; border-radius: 999px; border: 1px solid var(--line); background: var(--card);
  font-size: .82rem; font-weight: 500; color: var(--muted); transition: .3s;
}
.work-filter button span { font-size: .7rem; opacity: .6; margin-left: 4px; }
.work-filter button:hover { color: var(--text); }
.work-filter button.active { background: var(--accent); border-color: var(--accent); color: #fff; }
.work.hide { display: none; }
button.work-shot { display: block; width: 100%; padding: 0; border: 0; cursor: zoom-in; position: relative; background: var(--line); }
.work-shot img { width: 100%; height: 100%; object-fit: cover; object-position: top; transition: transform .7s cubic-bezier(.2,.8,.2,1), opacity .18s; }
.work-shot img.swap { opacity: 0; }
.shot-count {
  position: absolute; right: 12px; bottom: 12px; padding: 4px 10px; border-radius: 999px;
  background: rgba(0,0,0,.65); color: #fff; font-size: .68rem; font-weight: 600; letter-spacing: .02em;
  backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px);
}
.lb-nav {
  position: absolute; top: 50%; transform: translateY(-50%); width: 48px; height: 48px; border-radius: 50%;
  background: rgba(255,255,255,.14); color: #fff; font-size: 1.8rem; line-height: 1; display: none; place-items: center;
}
.lb-nav:hover { background: rgba(255,255,255,.28); }
.lb-prev { left: 20px; } .lb-next { right: 20px; }
.lightbox.multi .lb-nav { display: grid; }
/* project galleries: one fixed 16:10 frame for every screenshot */
.lightbox.gallery img {
  width: min(1100px, 86vw, calc(78vh * 1.6)); max-width: none; max-height: none;
  aspect-ratio: 16 / 10; object-fit: cover; object-position: top; background: #111;
}
.work:hover .work-shot img { transform: scale(1.05); }
.work-cat { font-size: .66rem; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); font-weight: 600; margin-bottom: 4px; }
.work-links { margin-top: auto; display: flex; gap: 8px; }
.work-links .btn-outline { flex: 1; }
.work-body .pills { margin-bottom: 18px; }

.shot-store { background: radial-gradient(circle at 70% 20%, #4c1d95, #0b0b1a 70%); }
.shot-gym   { background: linear-gradient(135deg, #064e3b, #10b981); }
.shot-trec  { background: linear-gradient(135deg, #14532d, #4ade80); }
.shot-biz   { background: linear-gradient(135deg, #0f172a, #0d9488); }
.shot-hr    { background: linear-gradient(135deg, #1e293b, #6366f1); }
.ui-mock {
  width: 74%; padding: 16px 18px; border-radius: 12px; background: rgba(255,255,255,.94); color: #111;
  box-shadow: 0 20px 40px -10px rgba(0,0,0,.45); display: grid; gap: 8px; transition: transform .6s;
}
.ui-mock.dark { background: rgba(15,15,35,.92); color: #fff; border: 1px solid rgba(139,92,246,.4); }
.work:hover .ui-mock { transform: scale(1.05) rotate(-1.5deg); }
.ui-mock b { font-size: 1rem; letter-spacing: -.01em; }
.ui-mock small { font-size: .7rem; opacity: .6; margin-top: -6px; }
.ui-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(0, 1fr)); gap: 6px; }
.ui-row i { height: 26px; border-radius: 6px; background: #e5e7eb; }
.ui-mock.dark .ui-row i { background: rgba(139,92,246,.25); }
.ui-table { display: grid; gap: 4px; }
.ui-table i { height: 8px; border-radius: 3px; background: #e5e7eb; }
.ui-bars { display: flex; align-items: flex-end; gap: 6px; height: 54px; }
.ui-bars i { flex: 1; height: var(--h); border-radius: 4px 4px 0 0; background: linear-gradient(#34d399, #059669); }
.shot-biz .ui-bars i { background: linear-gradient(#2dd4bf, #0d9488); }

/* ===== CV viewer ===== */
.cv-modal {
  position: fixed; inset: 0; z-index: 95; display: flex; flex-direction: column; align-items: center;
  background: rgba(5, 8, 15, .86); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
  opacity: 0; visibility: hidden; transition: .3s;
}
.cv-modal.open { opacity: 1; visibility: visible; }
.cv-bar {
  width: min(860px, 94vw); display: flex; align-items: center; gap: 12px; padding: 16px 4px 12px; color: #fff;
}
.cv-bar strong { font-size: .95rem; }
.cv-bar span { font-size: .8rem; opacity: .6; flex: 1; }
.cv-close { width: 40px; height: 40px; border-radius: 50%; background: rgba(255,255,255,.14); color: #fff; font-size: 1rem; }
.cv-close:hover { background: rgba(255,255,255,.28); }
.cv-scroll {
  width: 100%; flex: 1; min-height: 0; padding: 0 16px 20px;
  display: flex; justify-content: center; align-items: flex-start; overflow: hidden; overscroll-behavior: contain;
}
/* fit: the whole A4 page is visible without scrolling */
.cv-scroll img {
  height: 100%; width: auto; max-width: 100%; object-fit: contain; cursor: zoom-in;
  border-radius: 6px; background: #fff; box-shadow: 0 30px 80px rgba(0,0,0,.5);
  user-select: none; -webkit-user-select: none; -webkit-touch-callout: none;
  transform: translateY(16px); transition: transform .35s;
}
/* zoomed: full width, scroll to read */
.cv-modal.zoomed .cv-scroll { overflow-y: auto; }
.cv-modal.zoomed .cv-scroll img { height: auto; width: min(900px, 100%); cursor: zoom-out; }
.cv-hint { font-size: .72rem; opacity: .55; margin-right: 4px; }
.cv-modal.open .cv-scroll img { transform: none; }
body.no-scroll { overflow: hidden; }

.hero-fullname {
  font-size: .78rem; letter-spacing: .28em; text-transform: uppercase; font-weight: 600;
  color: var(--muted); margin-bottom: 14px; display: flex; align-items: center; gap: 12px;
}
.hero-fullname::before { content: ""; width: 28px; height: 1px; background: currentColor; }

/* ===== 404 page ===== */
.nf-page { min-height: 100vh; display: grid; place-items: center; text-align: center; padding: 24px; }
.nf h1 { font-size: clamp(2.4rem, 7vw, 4.5rem); font-weight: 800; letter-spacing: -0.03em; margin: 8px 0 12px; }
.nf p { color: var(--muted); margin-bottom: 28px; }
.nf .eyebrow { margin: 0; }

/* real profile photo framing */
.photo { object-position: 50% 30%; }
.about-photo img { object-position: 50% 20%; }

.lightbox {
  position: fixed; inset: 0; z-index: 90; display: grid; place-content: center; justify-items: center; gap: 14px;
  background: rgba(5, 8, 15, .82); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
  opacity: 0; visibility: hidden; transition: .3s; padding: 20px; cursor: zoom-out;
}
.lightbox.open { opacity: 1; visibility: visible; }
.lightbox img { max-width: min(1000px, 92vw); max-height: 80vh; border-radius: 8px; box-shadow: 0 30px 80px rgba(0,0,0,.6); transform: scale(.94); transition: transform .35s; cursor: default; }
.lightbox.open img { transform: none; }
.lightbox p { color: #fff; font-weight: 600; font-size: .95rem; text-align: center; }
.lb-close { position: absolute; top: 20px; right: 24px; width: 42px; height: 42px; border-radius: 50%; background: rgba(255,255,255,.12); color: #fff; font-size: 1.1rem; }
.lb-close:hover { background: rgba(255,255,255,.25); }
