/* =========================================================
   Sudenur Taştekin — Portfolio
   Modern, dark-first, glass + gradient, fully responsive
   ========================================================= */

:root {
  --bg: #0a0a14;
  --bg-soft: #0f1020;
  --surface: rgba(255, 255, 255, 0.04);
  --surface-strong: rgba(255, 255, 255, 0.08);
  --border: rgba(255, 255, 255, 0.08);
  --border-strong: rgba(255, 255, 255, 0.16);
  --text: #ecedf3;
  --text-muted: #a3a6b8;
  --text-dim: #6c6f80;

  --accent: #a78bfa;     /* violet 400 */
  --accent-2: #f472b6;   /* pink 400 */
  --accent-3: #38bdf8;   /* sky 400 */
  --accent-grad: linear-gradient(135deg, #a78bfa 0%, #f472b6 50%, #38bdf8 100%);
  --accent-glow: 0 0 40px rgba(167, 139, 250, 0.35);

  --radius: 16px;
  --radius-lg: 24px;
  --radius-pill: 999px;

  --shadow-card: 0 10px 30px -10px rgba(0, 0, 0, 0.5), 0 4px 12px -6px rgba(0, 0, 0, 0.3);
  --shadow-strong: 0 30px 60px -20px rgba(0, 0, 0, 0.6);

  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
  --ease-bounce: cubic-bezier(0.34, 1.56, 0.64, 1);

  --container: 1200px;
  --nav-h: 72px;

  --font-display: "Space Grotesk", "Inter", system-ui, sans-serif;
  --font-body: "Inter", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
}

html[data-theme="light"] {
  --bg: #f7f6fb;
  --bg-soft: #ffffff;
  --surface: rgba(10, 10, 30, 0.04);
  --surface-strong: rgba(10, 10, 30, 0.06);
  --border: rgba(10, 10, 30, 0.08);
  --border-strong: rgba(10, 10, 30, 0.14);
  --text: #14152b;
  --text-muted: #4d4f66;
  --text-dim: #8488a0;
  --accent-glow: 0 0 30px rgba(167, 139, 250, 0.25);
}

/* =================== reset =================== */
*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
html { scroll-behavior: smooth; overflow-x: hidden; max-width: 100vw; }
body {
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  font-size: 16px;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  min-height: 100vh;
  position: relative;
  max-width: 100vw;
  overflow-wrap: break-word;
  word-wrap: break-word;
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; border: 0; background: none; color: inherit; }
ul, ol { list-style: none; padding: 0; margin: 0; }
::selection { background: var(--accent); color: #0a0a14; }

/* =================== background =================== */
.bg-grid {
  position: fixed; inset: 0; z-index: -2; pointer-events: none;
  background-image:
    linear-gradient(var(--border) 1px, transparent 1px),
    linear-gradient(90deg, var(--border) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: radial-gradient(ellipse 80% 50% at 50% 0%, #000 30%, transparent 80%);
  opacity: 0.4;
}
html[data-theme="light"] .bg-grid { opacity: 0.6; }

.bg-blobs {
  position: fixed; inset: 0; z-index: -1; pointer-events: none; overflow: hidden;
}
.blob {
  position: absolute; border-radius: 50%; filter: blur(100px); opacity: 0.45;
  will-change: transform;
}
.blob-1 { width: 600px; height: 600px; top: -200px; left: -150px; background: #a78bfa; animation: float 18s ease-in-out infinite; }
.blob-2 { width: 500px; height: 500px; top: 30%; right: -200px; background: #f472b6; animation: float 22s ease-in-out infinite reverse; }
.blob-3 { width: 450px; height: 450px; bottom: -150px; left: 30%; background: #38bdf8; animation: float 26s ease-in-out infinite; }
html[data-theme="light"] .blob { opacity: 0.25; }

@keyframes float {
  0%, 100% { transform: translate(0, 0) scale(1); }
  33% { transform: translate(60px, -40px) scale(1.08); }
  66% { transform: translate(-40px, 50px) scale(0.95); }
}

/* =================== custom cursor =================== */
.cursor, .cursor-dot {
  position: fixed; top: 0; left: 0; pointer-events: none; z-index: 9999;
  border-radius: 50%;
  transform: translate(-50%, -50%);
  transition: width 0.25s var(--ease), height 0.25s var(--ease), opacity 0.3s var(--ease), background-color 0.25s var(--ease), border-color 0.25s var(--ease);
}
.cursor {
  width: 36px; height: 36px;
  border: 1.5px solid #fff;
  mix-blend-mode: difference;
  opacity: 0.7;
  display: grid; place-items: center;
}
.cursor-dot {
  width: 6px; height: 6px;
  background: #fff;
  mix-blend-mode: difference;
}
.cursor.is-hover { width: 64px; height: 64px; opacity: 1; }
.cursor.is-label {
  width: auto; height: auto;
  min-width: 100px; padding: 10px 18px;
  border-radius: 100px;
  background: var(--accent);
  border-color: var(--accent);
  mix-blend-mode: normal;
  opacity: 1;
}
.cursor__label {
  font-family: var(--font-mono); font-size: 12px; font-weight: 600;
  color: #0a0a14;
  white-space: nowrap;
  letter-spacing: 0.02em;
  opacity: 0;
  transform: scale(0.8);
  transition: opacity 0.2s var(--ease), transform 0.2s var(--ease);
}
.cursor.is-label .cursor__label { opacity: 1; transform: scale(1); }
.cursor.is-label + .cursor-dot { opacity: 0; }
@media (max-width: 768px), (hover: none) { .cursor, .cursor-dot { display: none; } }

/* =================== scroll progress =================== */
.scroll-progress {
  position: fixed; top: 0; left: 0; height: 3px; width: 0%;
  background: var(--accent-grad);
  z-index: 100; transition: width 0.05s linear;
  box-shadow: 0 0 20px rgba(167, 139, 250, 0.6);
}

/* =================== nav =================== */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 50;
  height: var(--nav-h);
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 32px;
  backdrop-filter: blur(20px) saturate(160%);
  -webkit-backdrop-filter: blur(20px) saturate(160%);
  background: color-mix(in srgb, var(--bg) 70%, transparent);
  border-bottom: 1px solid transparent;
  transition: border-color 0.3s var(--ease), background 0.3s var(--ease);
}
.nav.is-scrolled { border-bottom-color: var(--border); }

.nav__logo {
  display: flex; align-items: center; gap: 10px;
  font-family: var(--font-display); font-weight: 700;
}
.nav__logo-mark {
  width: 36px; height: 36px;
  display: grid; place-items: center;
  border-radius: 10px;
  background: var(--accent-grad);
  color: #0a0a14;
  font-weight: 800; font-size: 14px;
  box-shadow: var(--accent-glow);
}
.nav__logo-text { font-size: 16px; letter-spacing: -0.01em; }
.nav__logo-text span { color: var(--accent); }

.nav__links {
  display: flex; gap: 6px;
  background: var(--surface);
  border: 1px solid var(--border);
  padding: 6px;
  border-radius: var(--radius-pill);
  backdrop-filter: blur(10px);
}
.nav__links a {
  position: relative;
  padding: 8px 16px; font-size: 14px; font-weight: 500;
  border-radius: var(--radius-pill);
  color: var(--text-muted);
  transition: color 0.25s var(--ease), background 0.25s var(--ease);
}
.nav__links a:hover { color: var(--text); background: var(--surface-strong); }
.nav__links a.is-active { color: var(--text); background: var(--surface-strong); }

.nav__actions { display: flex; align-items: center; gap: 12px; }

.theme-toggle {
  width: 40px; height: 40px;
  display: grid; place-items: center;
  border-radius: 50%;
  background: var(--surface);
  border: 1px solid var(--border);
  color: var(--text);
  transition: transform 0.4s var(--ease-bounce), background 0.25s var(--ease);
}
.theme-toggle:hover { background: var(--surface-strong); transform: rotate(15deg) scale(1.05); }
.theme-toggle .icon-sun { display: none; }
html[data-theme="light"] .theme-toggle .icon-sun { display: block; }
html[data-theme="light"] .theme-toggle .icon-moon { display: none; }

.nav__cta {
  padding: 10px 18px;
  background: var(--text);
  color: var(--bg);
  font-weight: 600; font-size: 13px;
  border-radius: var(--radius-pill);
  transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease);
}

/* ============ language switcher ============ */
.lang-switch { position: relative; }
.lang-switch__btn {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 8px 12px;
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius-pill);
  font-family: var(--font-mono); font-size: 12px;
  font-weight: 600; letter-spacing: 0.04em;
  color: var(--text);
  transition: background 0.25s var(--ease), border-color 0.25s var(--ease);
}
.lang-switch__btn:hover { background: var(--surface-strong); border-color: var(--border-strong); }
.lang-switch__flag { font-size: 14px; line-height: 1; }
.lang-switch__caret { opacity: 0.6; transition: transform 0.25s var(--ease); }
.lang-switch.is-open .lang-switch__caret { transform: rotate(180deg); }
.lang-switch__menu {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  min-width: 160px;
  background: color-mix(in srgb, var(--bg-soft) 95%, transparent);
  backdrop-filter: blur(20px) saturate(160%);
  -webkit-backdrop-filter: blur(20px) saturate(160%);
  border: 1px solid var(--border-strong);
  border-radius: 14px;
  padding: 6px;
  box-shadow: var(--shadow-strong);
  opacity: 0; visibility: hidden;
  transform: translateY(-8px) scale(0.96);
  transition: opacity 0.22s var(--ease), transform 0.22s var(--ease), visibility 0.22s var(--ease);
  z-index: 60;
}
.lang-switch.is-open .lang-switch__menu {
  opacity: 1; visibility: visible;
  transform: translateY(0) scale(1);
}
.lang-switch__menu li button {
  width: 100%;
  display: flex; align-items: center; gap: 10px;
  padding: 9px 12px;
  background: none; border: 0;
  border-radius: 8px;
  font-family: var(--font-body); font-size: 13px;
  color: var(--text-muted);
  text-align: start;
  transition: background 0.2s var(--ease), color 0.2s var(--ease);
  cursor: pointer;
}
.lang-switch__menu li button span { font-size: 16px; }
.lang-switch__menu li button:hover { background: var(--surface-strong); color: var(--text); }

html[dir="rtl"] .lang-switch__menu { right: auto; left: 0; }

/* ============ RTL adjustments ============ */
html[dir="rtl"] body { font-family: var(--font-body); }
html[dir="rtl"] .nav__logo-mark { font-family: var(--font-display); }
html[dir="rtl"] .scroll-hint__line { /* keep */ }
html[dir="rtl"] .timeline { padding-left: 0; padding-right: 32px; }
html[dir="rtl"] .timeline::before { left: auto; right: 12px; }
html[dir="rtl"] .timeline__dot { left: auto; right: -28px; }
html[dir="rtl"] .timeline__card:hover { transform: translateX(-4px); }
html[dir="rtl"] .about__photo-tag { left: auto; right: 18px; }
html[dir="rtl"] .about__photo-sticker { right: auto; left: -22px; }
html[dir="rtl"] .project-card__glow { right: auto; left: -120px; }
html[dir="rtl"] .skill-card__list span { font-family: var(--font-mono); }
html[dir="rtl"] .marquee__track { animation-direction: reverse; }
html[dir="rtl"] .filter { direction: rtl; }
html[dir="rtl"] .to-top { right: auto; left: 28px; }

/* In RTL, swap the project link arrow direction visually */
html[dir="rtl"] .project-card__link svg { transform: scaleX(-1); }
html[dir="rtl"] .btn--primary svg,
html[dir="rtl"] .btn--ghost svg.arrow-rtl-swap { transform: scaleX(-1); }

/* keep emoji and tech chips LTR */
.title-emoji,
.orbit__ring .chip,
.project-card__stack li,
.field input,
.field textarea {
  direction: ltr;
}

@media (max-width: 768px) {
  .lang-switch__btn { padding: 7px 10px; font-size: 11px; }
  .lang-switch__code { display: none; }
  .lang-switch__menu { min-width: 150px; }
}
.nav__cta:hover { transform: translateY(-2px); box-shadow: 0 10px 30px -10px var(--text); }

.nav__burger {
  display: none;
  width: 40px; height: 40px;
  flex-direction: column; justify-content: center; align-items: center; gap: 5px;
  border-radius: 10px; background: var(--surface); border: 1px solid var(--border);
}
.nav__burger span {
  display: block; width: 18px; height: 2px; background: var(--text); border-radius: 2px;
  transition: transform 0.3s var(--ease), opacity 0.3s var(--ease);
}
.nav__burger.is-open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav__burger.is-open span:nth-child(2) { opacity: 0; }
.nav__burger.is-open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.mobile-menu {
  position: fixed; top: var(--nav-h); left: 0; right: 0; z-index: 49;
  background: color-mix(in srgb, var(--bg) 92%, transparent);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
  display: flex; flex-direction: column;
  padding: 20px; gap: 4px;
  transform: translateY(-110%);
  transition: transform 0.4s var(--ease);
}
.mobile-menu.is-open { transform: translateY(0); }
.mobile-menu a {
  padding: 14px 16px; font-size: 18px; font-weight: 500;
  border-radius: 12px; color: var(--text-muted);
  transition: background 0.2s var(--ease), color 0.2s var(--ease);
}
.mobile-menu a:hover { background: var(--surface); color: var(--text); }

/* =================== layout =================== */
.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 32px;
}

.section {
  padding: 120px 0;
  position: relative;
}
.section::before {
  content: ""; position: absolute; inset: 0;
  background: radial-gradient(500px circle at var(--mx, 50%) var(--my, -10%), rgba(167,139,250,0.08), transparent 60%);
  pointer-events: none; opacity: 0;
  transition: opacity 0.4s var(--ease);
}
.section:hover::before { opacity: 1; }
html[data-theme="light"] .section:hover::before { opacity: 0.6; }

.section__header {
  margin-bottom: 60px;
  max-width: 720px;
}
.section__header--row {
  display: flex; justify-content: space-between; align-items: flex-end; gap: 24px;
  max-width: none; flex-wrap: wrap;
}
.section__eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 6px 14px;
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius-pill);
  font-family: var(--font-mono); font-size: 12px;
  color: var(--accent);
  letter-spacing: 0.04em; text-transform: uppercase;
  margin-bottom: 18px;
}
.section__title {
  font-family: var(--font-display);
  font-size: clamp(2rem, 4vw, 3.5rem);
  font-weight: 700; line-height: 1.05;
  letter-spacing: -0.03em;
  margin: 0;
}
.gradient-text {
  background: var(--accent-grad);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent;
  display: inline-block;
}

/* =================== hero =================== */
.hero {
  min-height: 100vh;
  padding: calc(var(--nav-h) + 60px) 32px 80px;
  display: grid; place-items: center;
  position: relative;
  overflow: hidden;
}
.hero__canvas {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  z-index: 0; pointer-events: none;
  opacity: 0.85;
}
html[data-theme="light"] .hero__canvas { opacity: 0.65; }
.hero__inner {
  max-width: var(--container); width: 100%;
  display: grid;
  grid-template-columns: 1.3fr 1fr;
  gap: 60px; align-items: center;
  position: relative; z-index: 2;
}
.hero__badge {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 8px 16px;
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius-pill);
  font-size: 13px; color: var(--text-muted);
  margin-bottom: 28px;
  width: fit-content;
}
.hero__badge .dot {
  width: 8px; height: 8px; border-radius: 50%; background: #34d399;
  box-shadow: 0 0 12px #34d399;
  animation: pulse 2s ease-in-out infinite;
}
@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.5; } }

.hero__title {
  font-family: var(--font-display);
  font-size: clamp(2.5rem, 6vw, 5.5rem);
  font-weight: 700; line-height: 1.02;
  letter-spacing: -0.04em;
  margin: 0 0 28px 0;
}
.hero__title .line { display: block; }
.hero__title .subtitle {
  font-size: clamp(1.25rem, 2.4vw, 1.85rem);
  font-weight: 500; letter-spacing: -0.02em;
  color: var(--text-muted);
  margin-top: 12px; min-height: 1.2em;
}
.typewriter { color: var(--text); }
.caret {
  display: inline-block; width: 3px; height: 1em;
  background: var(--accent); margin-left: 4px;
  vertical-align: text-bottom;
  animation: blink 1s steps(2) infinite;
}
@keyframes blink { 50% { opacity: 0; } }

.hero__lead {
  font-size: clamp(1rem, 1.2vw, 1.125rem);
  color: var(--text-muted);
  max-width: 560px; margin: 0 0 36px 0;
  line-height: 1.7;
}
.hero__lead em { color: var(--text); font-style: normal; font-weight: 600; }

.hero__cta { display: flex; gap: 14px; flex-wrap: wrap; margin-bottom: 36px; }

.btn {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 14px 24px;
  font-weight: 600; font-size: 14px;
  border-radius: var(--radius-pill);
  transition: transform 0.45s var(--ease), box-shadow 0.25s var(--ease), background 0.25s var(--ease);
  position: relative; overflow: hidden;
  border: 1px solid transparent;
  white-space: nowrap;
  will-change: transform;
}
.btn[data-magnetic] .btn__label,
.btn[data-magnetic] svg {
  transition: transform 0.45s var(--ease);
  will-change: transform;
}
.btn--primary {
  background: var(--text); color: var(--bg);
}
.btn--primary:hover { transform: translateY(-3px); box-shadow: 0 18px 40px -15px var(--text); }
.btn--ghost {
  background: var(--surface); color: var(--text); border-color: var(--border);
  backdrop-filter: blur(10px);
}
.btn--ghost:hover { background: var(--surface-strong); border-color: var(--border-strong); transform: translateY(-3px); }
.btn--full { width: 100%; justify-content: center; padding: 16px 24px; }

.hero__socials {
  display: flex; gap: 14px;
}
.hero__socials a {
  width: 44px; height: 44px;
  display: grid; place-items: center;
  border-radius: 50%;
  background: var(--surface); border: 1px solid var(--border);
  color: var(--text-muted);
  transition: color 0.25s var(--ease), background 0.25s var(--ease), transform 0.25s var(--ease);
}
.hero__socials a:hover {
  color: var(--text); background: var(--surface-strong);
  transform: translateY(-3px) rotate(-6deg);
  border-color: var(--border-strong);
}

/* hero visual orbit */
.hero__visual {
  position: relative;
  display: grid; place-items: center;
  height: 480px;
}
.orbit {
  position: relative;
  width: 100%; height: 100%;
  display: grid; place-items: center;
}
.orbit__core {
  width: 160px; height: 160px;
  border-radius: 50%;
  background: var(--accent-grad);
  padding: 4px;
  display: grid; place-items: center;
  font-family: var(--font-display); font-size: 56px; font-weight: 700;
  color: #0a0a14;
  box-shadow: 0 0 80px rgba(167, 139, 250, 0.55), inset 0 0 40px rgba(255,255,255,0.2);
  position: relative; z-index: 2;
  animation: coreFloat 6s ease-in-out infinite;
  overflow: hidden;
}
.orbit__core .core-letter { display: none; }
.orbit__core--fallback .core-letter { display: block; }
.orbit__photo {
  width: 100%; height: 100%;
  border-radius: 50%;
  object-fit: cover;
  object-position: center 22%;
  display: block;
  transition: transform 0.6s var(--ease);
}
.orbit__core:hover .orbit__photo { transform: scale(1.08); }
@keyframes coreFloat {
  0%, 100% { transform: translateY(0) scale(1); }
  50% { transform: translateY(-10px) scale(1.03); }
}
.orbit__ring {
  position: absolute; inset: 0;
  border: 1px dashed var(--border-strong);
  border-radius: 50%;
  animation: spin 30s linear infinite;
}
.orbit__ring--1 { width: 220px; height: 220px; margin: auto; animation-duration: 14s; }
.orbit__ring--2 { width: 340px; height: 340px; margin: auto; animation-duration: 22s; animation-direction: reverse; }
.orbit__ring--3 { width: 460px; height: 460px; margin: auto; animation-duration: 32s; }
@keyframes spin { to { transform: rotate(360deg); } }

.orbit__ring .chip {
  position: absolute; top: -14px; left: 50%; transform: translateX(-50%);
  padding: 6px 12px; font-size: 12px; font-weight: 500;
  background: var(--bg-soft); border: 1px solid var(--border-strong);
  border-radius: var(--radius-pill);
  font-family: var(--font-mono);
  white-space: nowrap;
  animation: spin 14s linear infinite reverse;
}
.orbit__ring--1 .chip:nth-child(1) { transform: translateX(-50%) rotate(0deg) translateY(-110px) rotate(0deg); }
.orbit__ring--1 .chip:nth-child(2) { transform: translateX(-50%) rotate(180deg) translateY(-110px) rotate(-180deg); }
.orbit__ring--2 .chip:nth-child(1) { transform: translateX(-50%) rotate(0deg) translateY(-170px) rotate(0deg); }
.orbit__ring--2 .chip:nth-child(2) { transform: translateX(-50%) rotate(120deg) translateY(-170px) rotate(-120deg); }
.orbit__ring--2 .chip:nth-child(3) { transform: translateX(-50%) rotate(240deg) translateY(-170px) rotate(-240deg); }
.orbit__ring--3 .chip:nth-child(1) { transform: translateX(-50%) rotate(0deg) translateY(-230px) rotate(0deg); }
.orbit__ring--3 .chip:nth-child(2) { transform: translateX(-50%) rotate(90deg) translateY(-230px) rotate(-90deg); }
.orbit__ring--3 .chip:nth-child(3) { transform: translateX(-50%) rotate(180deg) translateY(-230px) rotate(-180deg); }
.orbit__ring--3 .chip:nth-child(4) { transform: translateX(-50%) rotate(270deg) translateY(-230px) rotate(-270deg); }

.scroll-hint {
  position: absolute; bottom: 30px; left: 50%; transform: translateX(-50%);
  display: flex; flex-direction: column; align-items: center; gap: 10px;
  font-family: var(--font-mono); font-size: 11px;
  color: var(--text-dim);
  letter-spacing: 0.1em; text-transform: uppercase;
}
.scroll-hint__line {
  width: 1px; height: 36px;
  background: linear-gradient(to bottom, transparent, var(--text-muted));
  animation: scrollLine 2s ease-in-out infinite;
}
@keyframes scrollLine {
  0% { transform: scaleY(0); transform-origin: top; }
  50% { transform: scaleY(1); transform-origin: top; }
  51% { transform: scaleY(1); transform-origin: bottom; }
  100% { transform: scaleY(0); transform-origin: bottom; }
}

/* =================== marquee =================== */
.marquee {
  overflow: hidden;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  padding: 22px 0;
  background: var(--bg-soft);
}
.marquee__track {
  display: flex; gap: 40px; white-space: nowrap;
  animation: marquee 40s linear infinite;
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 3vw, 2.5rem);
  font-weight: 600;
  color: var(--text-muted);
}
.marquee__track span:nth-child(odd) { color: var(--text); }
.marquee__track span { padding: 0 4px; }
@keyframes marquee {
  to { transform: translateX(-50%); }
}

/* =================== about =================== */
.about__grid {
  display: grid;
  grid-template-columns: minmax(260px, 0.85fr) 1.3fr;
  gap: 60px; align-items: start;
}
.about__content {
  display: flex; flex-direction: column; gap: 40px;
}
.about__text p {
  font-size: 1.0625rem; color: var(--text-muted);
  margin: 0 0 18px 0; line-height: 1.8;
}

/* About profile photo */
.about__photo {
  position: sticky;
  top: calc(var(--nav-h) + 32px);
  align-self: start;
  aspect-ratio: 4/5;
  border-radius: var(--radius-lg);
  overflow: visible;
  perspective: 1200px;
}
.about__photo-frame {
  position: relative;
  width: 100%; height: 100%;
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--border);
  background: linear-gradient(135deg, var(--surface), var(--bg-soft));
  box-shadow: 0 30px 60px -20px rgba(0,0,0,0.6), 0 0 0 1px var(--border);
  transform-style: preserve-3d;
  transition: transform 0.4s var(--ease), box-shadow 0.4s var(--ease);
}
.about__photo-frame::before {
  content: ""; position: absolute; inset: 0;
  border-radius: inherit;
  padding: 1px;
  background: linear-gradient(135deg, rgba(167,139,250,0.5), transparent 50%, rgba(56,189,248,0.5));
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
          mask-composite: exclude;
  pointer-events: none;
  z-index: 2;
}
.about__photo-frame::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, transparent 50%, rgba(10,10,20,0.6));
  pointer-events: none;
  border-radius: inherit;
}
.about__photo-frame img {
  width: 100%; height: 100%;
  object-fit: cover; object-position: center 30%;
  display: block;
  transition: transform 0.8s var(--ease), filter 0.8s var(--ease);
  filter: saturate(1.05) contrast(1.04);
}
.about__photo:hover .about__photo-frame img {
  transform: scale(1.06);
}
.about__photo.no-image .about__photo-frame {
  background:
    radial-gradient(circle at 30% 20%, rgba(167,139,250,0.4), transparent 60%),
    radial-gradient(circle at 80% 90%, rgba(244,114,182,0.3), transparent 60%),
    var(--bg-soft);
}
.about__photo.no-image .about__photo-frame::before { content: "📷  fotoğraf bekleniyor"; display: grid; place-items: center; padding: 0; background: none; mask: none; -webkit-mask: none; color: var(--text-muted); font-family: var(--font-mono); font-size: 13px; }

.about__photo-tag {
  position: absolute; bottom: 18px; left: 18px;
  z-index: 3;
  display: inline-flex; align-items: center; gap: 8px;
  padding: 8px 14px;
  background: rgba(20, 21, 43, 0.65);
  backdrop-filter: blur(20px) saturate(160%);
  -webkit-backdrop-filter: blur(20px) saturate(160%);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: var(--radius-pill);
  font-family: var(--font-mono); font-size: 12px;
  color: #fff;
  letter-spacing: 0.02em;
}
html[data-theme="light"] .about__photo-tag {
  background: rgba(255,255,255,0.85);
  border-color: rgba(0,0,0,0.08);
  color: var(--text);
}
.about__photo-tag .dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: #34d399;
  box-shadow: 0 0 12px #34d399;
  animation: pulse 2s ease-in-out infinite;
}

/* Rotating sticker over photo */
.about__photo-sticker {
  position: absolute;
  top: -22px; right: -22px;
  width: 100px; height: 100px;
  border-radius: 50%;
  background: var(--accent-grad);
  display: grid; place-items: center;
  z-index: 4;
  box-shadow: 0 14px 40px -10px rgba(167,139,250,0.55);
  animation: spin 14s linear infinite;
  font-family: var(--font-mono); font-size: 11px; font-weight: 600;
  color: #0a0a14; text-transform: uppercase;
  letter-spacing: 0.08em;
  text-align: center;
  line-height: 1.3;
}
.about__photo-sticker span {
  position: absolute;
  inset: 0;
  display: grid; place-items: center;
}
.about__photo-sticker span:nth-child(1) { transform: rotate(0deg) translateY(-38px); }
.about__photo-sticker span:nth-child(2) { transform: rotate(90deg) translateY(-38px); }
.about__photo-sticker span:nth-child(3) { transform: rotate(180deg) translateY(-38px); }
.about__photo-sticker span:nth-child(4) { transform: rotate(270deg) translateY(-38px); }
.about__photo-sticker::after {
  content: "✨";
  position: relative;
  font-size: 22px;
  z-index: 1;
  filter: drop-shadow(0 2px 6px rgba(0,0,0,0.3));
  animation: spin 14s linear infinite reverse;
}
.about__text em {
  color: var(--text); font-style: normal; font-weight: 600;
  background: linear-gradient(180deg, transparent 60%, rgba(167,139,250,0.35) 60%);
}
.about__stats {
  display: grid; grid-template-columns: 1fr 1fr; gap: 16px;
}
.stat-card {
  padding: 24px;
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius);
  display: flex; flex-direction: column; gap: 6px;
  transition: transform 0.3s var(--ease), border-color 0.3s var(--ease);
  backdrop-filter: blur(10px);
}
.stat-card:hover { transform: translateY(-4px); border-color: var(--border-strong); }
.stat-card__num {
  font-family: var(--font-display);
  font-size: 2.4rem; font-weight: 700;
  background: var(--accent-grad);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent;
  letter-spacing: -0.02em;
}
.stat-card__label { font-size: 13px; color: var(--text-muted); }
.stat-card--accent {
  grid-column: span 2;
  background: linear-gradient(135deg, rgba(167,139,250,0.15), rgba(244,114,182,0.1));
  border-color: rgba(167,139,250,0.25);
}
.stat-card__icon { font-size: 28px; }

/* =================== skills =================== */
.skills__grid {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px;
  perspective: 1200px;
}
.skill-card {
  padding: 28px;
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  backdrop-filter: blur(10px);
  position: relative; overflow: hidden;
  transition: transform 0.4s var(--ease), border-color 0.4s var(--ease);
  transform-style: preserve-3d;
  will-change: transform;
}
.skill-card > * { transform: translateZ(20px); }
.skill-card::before {
  content: ""; position: absolute; inset: 0;
  background: radial-gradient(600px circle at var(--mx, 50%) var(--my, 50%), rgba(167,139,250,0.12), transparent 40%);
  opacity: 0; transition: opacity 0.4s var(--ease);
  pointer-events: none;
}
.skill-card:hover { border-color: var(--border-strong); }
.skill-card[data-tilt] { transition: transform 0.2s var(--ease), border-color 0.4s var(--ease); }
.skill-card:hover::before { opacity: 1; }

.skill-card__head {
  display: flex; align-items: center; gap: 12px;
  margin-bottom: 22px; padding-bottom: 18px;
  border-bottom: 1px solid var(--border);
}
.skill-card__icon { font-size: 28px; }
.skill-card__head h3 {
  font-family: var(--font-display); font-size: 1.125rem; font-weight: 600;
  margin: 0; letter-spacing: -0.01em;
}
.skill-card__list { display: flex; flex-direction: column; gap: 14px; }
.skill-card__list li {
  display: flex; flex-direction: column; gap: 6px;
}
.skill-card__list span { font-size: 14px; color: var(--text-muted); font-family: var(--font-mono); }
.skill-card__list i {
  display: block; height: 4px; width: 100%;
  background: var(--surface-strong);
  border-radius: 4px; overflow: hidden;
  position: relative;
}
.skill-card__list i::after {
  content: ""; position: absolute; inset: 0;
  width: var(--lvl); background: var(--accent-grad);
  border-radius: 4px;
  transform: translateX(-100%);
  transition: transform 1.4s var(--ease);
}
.skill-card.is-revealed .skill-card__list i::after { transform: translateX(0); }

/* =================== projects =================== */
.filter {
  display: flex; gap: 6px;
  background: var(--surface); border: 1px solid var(--border);
  padding: 6px; border-radius: var(--radius-pill);
  flex-wrap: wrap;
}
.filter__btn {
  padding: 8px 16px; font-size: 13px; font-weight: 500;
  border-radius: var(--radius-pill);
  color: var(--text-muted);
  transition: color 0.25s var(--ease), background 0.25s var(--ease);
}
.filter__btn:hover { color: var(--text); }
.filter__btn.is-active {
  background: var(--text); color: var(--bg);
}

.projects__grid {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px;
  perspective: 1400px;
}
.project-card {
  position: relative;
  padding: 28px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  backdrop-filter: blur(10px);
  display: flex; flex-direction: column;
  min-height: 240px;
  overflow: hidden;
  transition: transform 0.4s var(--ease), border-color 0.4s var(--ease);
  transform-style: preserve-3d;
  will-change: transform;
}
.project-card > *:not(.project-card__shine) { transform: translateZ(28px); }
.project-card--lg {
  grid-column: span 2;
  min-height: 320px;
  background: linear-gradient(135deg, rgba(167,139,250,0.18), rgba(56,189,248,0.10));
  border-color: rgba(167,139,250,0.3);
}

/* ChicTemp / "Yakında" özel kart */
.project-card--soon {
  background:
    radial-gradient(circle at 20% 0%, rgba(244,114,182,0.22), transparent 50%),
    radial-gradient(circle at 80% 100%, rgba(56,189,248,0.18), transparent 50%),
    linear-gradient(135deg, rgba(167,139,250,0.12), rgba(244,114,182,0.06));
  border-color: rgba(244,114,182,0.35);
  position: relative;
}
.project-card--soon::after {
  content: ""; position: absolute; inset: 0;
  border-radius: inherit;
  padding: 1px;
  background: linear-gradient(120deg,
    transparent 0%,
    rgba(244,114,182,0.6) 25%,
    rgba(167,139,250,0.6) 50%,
    rgba(56,189,248,0.6) 75%,
    transparent 100%);
  background-size: 250% 250%;
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
          mask-composite: exclude;
  pointer-events: none;
  animation: shimmerBorder 4s linear infinite;
  opacity: 0.85;
}
@keyframes shimmerBorder {
  0% { background-position: 0% 50%; }
  100% { background-position: 250% 50%; }
}

.project-card__glow {
  position: absolute;
  width: 360px; height: 360px;
  top: -120px; right: -120px;
  background: radial-gradient(circle, rgba(244,114,182,0.35), transparent 70%);
  filter: blur(20px);
  pointer-events: none;
  animation: glowFloat 8s ease-in-out infinite;
  z-index: 0;
}
@keyframes glowFloat {
  0%, 100% { transform: translate(0, 0) scale(1); opacity: 0.6; }
  50%      { transform: translate(-30px, 30px) scale(1.1); opacity: 0.85; }
}

.project-card__badge--soon {
  background: linear-gradient(135deg, #f472b6, #fb923c) !important;
  color: #14152b !important;
  font-weight: 600 !important;
  display: inline-flex !important;
  align-items: center; gap: 7px;
  padding: 5px 12px !important;
  box-shadow: 0 4px 20px -4px rgba(244,114,182,0.55);
}
.pulse-dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: #14152b;
  position: relative;
}
.pulse-dot::after {
  content: ""; position: absolute; inset: 0;
  border-radius: 50%; background: #14152b;
  animation: pulseRing 1.6s ease-out infinite;
}
@keyframes pulseRing {
  0%   { transform: scale(1);   opacity: 0.6; }
  100% { transform: scale(2.6); opacity: 0; }
}

.project-card__title .title-emoji {
  display: inline-block;
  margin-left: 8px;
  font-size: 0.75em;
  animation: emojiBob 3.4s ease-in-out infinite;
  filter: drop-shadow(0 4px 14px rgba(244,114,182,0.5));
}
@keyframes emojiBob {
  0%, 100% { transform: translateY(0) rotate(-6deg); }
  50%      { transform: translateY(-6px) rotate(6deg); }
}

.project-card__link.is-disabled {
  color: var(--text-muted);
  cursor: default;
  border-bottom-color: transparent !important;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.04em; text-transform: uppercase;
  display: inline-flex; align-items: center; gap: 8px;
}
.project-card__link.is-disabled:hover {
  gap: 8px; border-color: transparent;
  color: var(--accent-2);
}
.project-card__link.is-disabled svg {
  animation: spinSlow 6s linear infinite;
  color: var(--accent-2);
}
@keyframes spinSlow { to { transform: rotate(360deg); } }

/* Filter dot for "Yakında" */
.filter__dot {
  display: inline-block;
  width: 7px; height: 7px;
  border-radius: 50%;
  background: linear-gradient(135deg, #f472b6, #fb923c);
  margin-right: 6px;
  vertical-align: middle;
  box-shadow: 0 0 8px rgba(244,114,182,0.7);
  animation: pulse 2s ease-in-out infinite;
}
.project-card:hover { border-color: var(--border-strong); }
.project-card[data-tilt] { transition: transform 0.2s var(--ease), border-color 0.4s var(--ease); }
.project-card__shine {
  position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(600px circle at var(--mx, 50%) var(--my, 50%), rgba(255,255,255,0.07), transparent 40%);
  opacity: 0; transition: opacity 0.4s var(--ease);
}
.project-card:hover .project-card__shine { opacity: 1; }

.project-card__top {
  display: flex; justify-content: space-between; align-items: center;
  margin-bottom: 18px;
}
.project-card__badge {
  font-family: var(--font-mono); font-size: 11px;
  padding: 4px 10px; border-radius: var(--radius-pill);
  background: var(--surface-strong); color: var(--text-muted);
  letter-spacing: 0.04em;
}
.project-card--lg .project-card__badge {
  background: var(--accent-grad); color: #0a0a14; font-weight: 600;
}
.project-card__year {
  font-family: var(--font-mono); font-size: 12px; color: var(--text-dim);
}

.project-card__title {
  font-family: var(--font-display);
  font-size: clamp(1.25rem, 2vw, 1.75rem);
  font-weight: 600; letter-spacing: -0.02em;
  margin: 0 0 10px 0;
}
.project-card--lg .project-card__title {
  font-size: clamp(1.75rem, 3vw, 2.5rem);
}
.project-card__desc {
  color: var(--text-muted); font-size: 14px; line-height: 1.65;
  margin: 0 0 20px 0; flex-grow: 1;
}
.project-card--lg .project-card__desc { font-size: 15px; max-width: 540px; }

.project-card__stack {
  display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 20px;
}
.project-card__stack li {
  font-family: var(--font-mono); font-size: 11px;
  padding: 4px 10px; border-radius: var(--radius-pill);
  background: var(--surface-strong); color: var(--text-muted);
  border: 1px solid var(--border);
}

.project-card__link {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 13px; font-weight: 600;
  color: var(--text);
  width: fit-content;
  padding-bottom: 2px;
  border-bottom: 1px solid transparent;
  transition: border-color 0.25s var(--ease), gap 0.25s var(--ease);
}
.project-card__link:hover { border-color: var(--text); gap: 12px; }

.projects__more {
  text-align: center; margin: 50px 0 0;
  color: var(--text-muted); font-size: 15px;
}
.projects__more a {
  color: var(--text); font-weight: 600;
  border-bottom: 1px solid var(--border-strong);
  padding-bottom: 1px;
  transition: border-color 0.25s var(--ease), color 0.25s var(--ease);
}
.projects__more a:hover { border-color: var(--accent); color: var(--accent); }

/* hidden by filter */
.project-card.is-hidden {
  display: none;
}

/* =================== timeline =================== */
.timeline {
  position: relative;
  display: flex; flex-direction: column; gap: 32px;
  max-width: 820px; margin: 0 auto;
  padding-left: 32px;
}
.timeline::before {
  content: ""; position: absolute;
  top: 8px; bottom: 8px; left: 12px; width: 1px;
  background: linear-gradient(to bottom, var(--accent), transparent);
}
.timeline__item { position: relative; }
.timeline__dot {
  position: absolute; left: -28px; top: 18px;
  width: 14px; height: 14px;
  border-radius: 50%;
  background: var(--accent-grad);
  box-shadow: 0 0 0 4px var(--bg), var(--accent-glow);
}
.timeline__card {
  padding: 26px 28px;
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  backdrop-filter: blur(10px);
  transition: transform 0.4s var(--ease), border-color 0.4s var(--ease);
}
.timeline__card:hover { transform: translateX(4px); border-color: var(--border-strong); }
.timeline__meta {
  display: flex; gap: 10px; flex-wrap: wrap;
  font-family: var(--font-mono); font-size: 12px;
  color: var(--accent);
  margin-bottom: 12px;
}
.timeline__type {
  color: var(--text-dim);
}
.timeline__card h3 {
  font-family: var(--font-display); font-size: 1.25rem; font-weight: 600;
  margin: 0 0 6px 0; letter-spacing: -0.01em;
}
.timeline__org {
  color: var(--text); font-size: 14px; font-weight: 500;
  margin: 0 0 10px 0;
}
.timeline__desc {
  color: var(--text-muted); font-size: 14px; line-height: 1.7;
  margin: 0;
}

/* =================== contact =================== */
.contact__inner {
  display: grid; grid-template-columns: 1.1fr 1fr; gap: 60px;
  padding: 48px;
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  backdrop-filter: blur(20px);
  position: relative; overflow: hidden;
}
.contact__inner::before {
  content: ""; position: absolute; top: -100px; right: -100px;
  width: 400px; height: 400px;
  background: radial-gradient(circle, rgba(167,139,250,0.2), transparent 70%);
  pointer-events: none;
}
.contact__lead {
  color: var(--text-muted); font-size: 17px;
  margin: 18px 0 28px; line-height: 1.7;
}
.contact__email {
  display: inline-flex; align-items: center; gap: 12px;
  font-family: var(--font-display);
  font-size: clamp(1.25rem, 2vw, 1.65rem); font-weight: 600;
  margin: 8px 0 30px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--border-strong);
  transition: gap 0.3s var(--ease), color 0.3s var(--ease);
}
.contact__email:hover { gap: 18px; color: var(--accent); }
.contact__socials {
  display: flex; flex-direction: column; gap: 4px;
}
.contact__socials a {
  display: flex; justify-content: space-between; align-items: center;
  padding: 14px 0; font-family: var(--font-mono); font-size: 14px;
  color: var(--text-muted);
  border-bottom: 1px solid var(--border);
  transition: color 0.25s var(--ease), padding 0.25s var(--ease);
}
.contact__socials a span { color: var(--text-dim); }
.contact__socials a:hover { color: var(--text); padding-left: 6px; }
.contact__socials a:hover span { color: var(--accent); }

.contact__form { display: flex; flex-direction: column; gap: 18px; position: relative; }
.field { display: flex; flex-direction: column; gap: 8px; }
.field label {
  font-family: var(--font-mono); font-size: 12px;
  color: var(--text-muted); letter-spacing: 0.04em; text-transform: uppercase;
}
.field input, .field textarea {
  font-family: var(--font-body); font-size: 15px;
  padding: 14px 16px;
  background: var(--bg-soft); border: 1px solid var(--border);
  border-radius: 12px;
  color: var(--text);
  transition: border-color 0.25s var(--ease), background 0.25s var(--ease);
  resize: vertical;
}
.field input:focus, .field textarea:focus {
  outline: none; border-color: var(--accent);
  background: var(--surface);
}
.form-status { font-size: 13px; color: var(--accent); margin: 0; min-height: 1em; }

/* =================== footer =================== */
.footer {
  border-top: 1px solid var(--border);
  padding: 36px 0;
  margin-top: 60px;
}
.footer__inner {
  display: flex; justify-content: space-between; align-items: center;
  flex-wrap: wrap; gap: 12px;
  font-size: 13px; color: var(--text-dim);
}
.footer__credit { font-family: var(--font-mono); font-size: 12px; }

/* =================== to-top =================== */
.to-top {
  position: fixed; bottom: 28px; right: 28px;
  width: 48px; height: 48px;
  display: grid; place-items: center;
  border-radius: 50%;
  background: var(--text); color: var(--bg);
  box-shadow: var(--shadow-strong);
  opacity: 0; visibility: hidden;
  transform: translateY(10px);
  transition: opacity 0.3s var(--ease), visibility 0.3s var(--ease), transform 0.3s var(--ease);
  z-index: 40;
}
.to-top.is-visible { opacity: 1; visibility: visible; transform: translateY(0); }
.to-top:hover { transform: translateY(-4px); }

/* =================== reveal animation =================== */
[data-reveal] {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.8s var(--ease), transform 0.8s var(--ease);
}
[data-reveal].is-revealed {
  opacity: 1;
  transform: translateY(0);
}

/* =================== responsive =================== */

/* ---- Tablet & smaller laptop (≤1024px) ---- */
@media (max-width: 1024px) {
  .container { padding-left: 28px; padding-right: 28px; }

  .hero { padding: calc(var(--nav-h) + 40px) 28px 60px; }
  .hero__inner { grid-template-columns: 1fr; gap: 40px; }
  .hero__title { font-size: clamp(2.25rem, 7vw, 4rem); }
  .hero__visual { height: 360px; order: -1; max-width: 420px; margin: 0 auto; }
  .orbit__core { width: 120px; height: 120px; }
  .orbit__ring--1 { width: 200px; height: 200px; }
  .orbit__ring--2 { width: 300px; height: 300px; }
  .orbit__ring--3 { width: 400px; height: 400px; }
  .orbit__ring--1 .chip:nth-child(1) { transform: translateX(-50%) rotate(0) translateY(-100px) rotate(0); }
  .orbit__ring--1 .chip:nth-child(2) { transform: translateX(-50%) rotate(180deg) translateY(-100px) rotate(-180deg); }
  .orbit__ring--2 .chip:nth-child(1) { transform: translateX(-50%) rotate(0) translateY(-150px) rotate(0); }
  .orbit__ring--2 .chip:nth-child(2) { transform: translateX(-50%) rotate(120deg) translateY(-150px) rotate(-120deg); }
  .orbit__ring--2 .chip:nth-child(3) { transform: translateX(-50%) rotate(240deg) translateY(-150px) rotate(-240deg); }
  .orbit__ring--3 .chip:nth-child(1) { transform: translateX(-50%) rotate(0) translateY(-200px) rotate(0); }
  .orbit__ring--3 .chip:nth-child(2) { transform: translateX(-50%) rotate(90deg) translateY(-200px) rotate(-90deg); }
  .orbit__ring--3 .chip:nth-child(3) { transform: translateX(-50%) rotate(180deg) translateY(-200px) rotate(-180deg); }
  .orbit__ring--3 .chip:nth-child(4) { transform: translateX(-50%) rotate(270deg) translateY(-200px) rotate(-270deg); }

  .nav__links { display: none; }
  .nav__burger { display: flex; }

  .about__grid { grid-template-columns: 1fr; gap: 48px; }
  .about__photo { position: static; max-width: 380px; margin: 0 auto; width: 100%; }

  .skills__grid { grid-template-columns: repeat(2, 1fr); }
  .projects__grid { grid-template-columns: repeat(2, 1fr); }
  .project-card--lg { grid-column: span 2; }

  .contact__inner { grid-template-columns: 1fr; padding: 36px; gap: 40px; }

  .section { padding: 96px 0; }
}

/* ---- Tablet portrait (≤768px) ---- */
@media (max-width: 768px) {
  :root { --nav-h: 64px; }
  .container { padding-left: 22px; padding-right: 22px; }

  .nav { padding: 0 18px; }
  .nav__cta { display: none; }
  .nav__logo-text { display: none; }

  .section { padding: 80px 0; }
  .section__header { margin-bottom: 44px; }
  .section__title { font-size: clamp(1.75rem, 5vw, 2.75rem); }
  .section__header--row { flex-direction: column; align-items: flex-start; gap: 18px; }

  .hero { padding: calc(var(--nav-h) + 32px) 22px 56px; }
  .hero__title { font-size: clamp(2rem, 8vw, 3rem); }
  .hero__title .subtitle { font-size: clamp(1.05rem, 3.5vw, 1.4rem); }
  .hero__lead { font-size: 0.9375rem; }
  .hero__cta { gap: 12px; }
  .btn { padding: 12px 20px; font-size: 13px; }
  .hero__visual { height: 320px; max-width: 360px; }
  .orbit__core { width: 110px; height: 110px; }
  .orbit__ring--3 { display: none; }
  .scroll-hint { display: none; }

  .marquee { padding: 16px 0; }
  .marquee__track { font-size: 1.4rem; gap: 28px; }

  .about__text p { font-size: 1rem; }
  .about__stats { grid-template-columns: 1fr 1fr; gap: 12px; }
  .stat-card { padding: 20px; }
  .stat-card__num { font-size: 2rem; }
  .stat-card--accent { grid-column: span 2; }

  .skills__grid { grid-template-columns: repeat(2, 1fr); gap: 14px; }
  .skill-card { padding: 22px; }

  .projects__grid { grid-template-columns: 1fr; }
  .project-card--lg { grid-column: span 1; min-height: 260px; }
  .project-card { padding: 22px; min-height: 220px; }
  .project-card__title { font-size: 1.2rem; }
  .project-card--lg .project-card__title { font-size: 1.6rem; }

  .filter {
    width: 100%; overflow-x: auto; flex-wrap: nowrap;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }
  .filter::-webkit-scrollbar { display: none; }
  .filter__btn { white-space: nowrap; flex-shrink: 0; }

  .timeline { padding-left: 24px; }
  .timeline__card { padding: 22px 22px; }
  .timeline__card h3 { font-size: 1.125rem; }

  .contact__inner { padding: 28px; }
  .contact__email { font-size: 1.15rem; }
  .field input, .field textarea { font-size: 14px; padding: 12px 14px; }

  .footer__inner { flex-direction: column; text-align: center; }
  .to-top { width: 44px; height: 44px; bottom: 20px; right: 20px; }
}

/* ---- Mobile (≤560px) ---- */
@media (max-width: 560px) {
  .container { padding-left: 18px; padding-right: 18px; }
  .nav { padding: 0 16px; }
  .hero { padding-left: 18px; padding-right: 18px; }

  .hero__title { font-size: clamp(1.875rem, 9vw, 2.5rem); line-height: 1.05; }
  .hero__title .subtitle { font-size: 0.95rem; }
  .hero__lead { font-size: 0.875rem; line-height: 1.65; }
  .hero__badge { font-size: 11px; padding: 6px 12px; }
  .hero__visual { height: 280px; max-width: 100%; }

  .orbit__core { width: 96px; height: 96px; }
  .orbit__ring--1 { width: 170px; height: 170px; }
  .orbit__ring--2 { width: 250px; height: 250px; }
  .orbit__ring--1 .chip:nth-child(1) { transform: translateX(-50%) rotate(0) translateY(-85px) rotate(0); }
  .orbit__ring--1 .chip:nth-child(2) { transform: translateX(-50%) rotate(180deg) translateY(-85px) rotate(-180deg); }
  .orbit__ring--2 .chip:nth-child(1) { transform: translateX(-50%) rotate(0) translateY(-125px) rotate(0); }
  .orbit__ring--2 .chip:nth-child(2) { transform: translateX(-50%) rotate(120deg) translateY(-125px) rotate(-120deg); }
  .orbit__ring--2 .chip:nth-child(3) { transform: translateX(-50%) rotate(240deg) translateY(-125px) rotate(-240deg); }
  .orbit__ring .chip { font-size: 10px; padding: 4px 9px; }

  .skills__grid { grid-template-columns: 1fr; }

  .about__photo { max-width: 320px; }
  .about__photo-sticker {
    width: 76px; height: 76px;
    top: -12px; right: -12px;
    font-size: 9px;
  }
  .about__photo-sticker span:nth-child(1) { transform: rotate(0deg) translateY(-28px); }
  .about__photo-sticker span:nth-child(2) { transform: rotate(90deg) translateY(-28px); }
  .about__photo-sticker span:nth-child(3) { transform: rotate(180deg) translateY(-28px); }
  .about__photo-sticker span:nth-child(4) { transform: rotate(270deg) translateY(-28px); }

  .marquee__track { font-size: 1.1rem; gap: 22px; }
  .section__eyebrow { font-size: 11px; padding: 5px 11px; }
}

/* ---- Small mobile (≤420px) ---- */
@media (max-width: 420px) {
  .container { padding-left: 16px; padding-right: 16px; }
  .hero { padding-left: 16px; padding-right: 16px; }

  .hero__cta { flex-direction: column; width: 100%; }
  .btn { width: 100%; justify-content: center; padding: 13px 20px; }
  [data-magnetic] { transform: none !important; }

  .about__stats { grid-template-columns: 1fr; }
  .stat-card--accent { grid-column: span 1; }

  .about__photo { max-width: 100%; }
  .about__photo-sticker { display: none; }

  .contact__inner { padding: 24px 18px; }
  .contact__email { font-size: 1rem; gap: 8px; }
  .nav__logo-mark { width: 32px; height: 32px; font-size: 12px; }

  .timeline { padding-left: 20px; }
  .timeline__dot { left: -22px; width: 12px; height: 12px; }

  .project-card__title .title-emoji { font-size: 0.6em; margin-left: 4px; }
}

/* ---- Disable heavy effects on touch devices ---- */
@media (hover: none) {
  [data-tilt] { transform: none !important; }
  [data-magnetic] { transform: none !important; }
  .hero__canvas { display: none; }
  .section::before { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  .orbit__ring, .blob, .marquee__track { animation: none !important; }
  [data-reveal] { opacity: 1; transform: none; }
}
