:root {
  --bg: #fffdf6;
  --surface: #ffffff;
  --surface-soft: #fff8e1;
  --text: #1f2937;
  --muted: #5a6675;
  --line: #f4e5a8;
  --accent: #facc15;
  --accent-dark: #ca8a04;
  --accent-alt: #f59e0b;
  --accent-soft: #fef9c3;
  --radius: 8px;
  --shadow: 0 16px 34px rgba(30, 41, 59, 0.1);
  --shadow-strong: 0 24px 48px rgba(30, 41, 59, 0.18);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: "Manrope", Arial, sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at 8% 8%, rgba(250, 204, 21, 0.2), transparent 32%),
    radial-gradient(circle at 92% 16%, rgba(59, 130, 246, 0.11), transparent 28%),
    var(--bg);
  line-height: 1.6;
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
}

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

.section {
  padding: 88px 0;
  scroll-margin-top: 88px;
}

.section-alt {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.32), rgba(255, 255, 255, 0.32)),
    var(--surface-soft);
}

.eyebrow {
  margin: 0 0 12px;
  color: var(--accent);
  font-weight: 700;
  letter-spacing: 0;
  text-transform: uppercase;
  font-size: 0.82rem;
}

h1,
h2,
h3,
p {
  margin: 0;
}

h1 {
  font-size: clamp(2rem, 3.8vw, 3.5rem);
  line-height: 1.1;
  margin-bottom: 18px;
}

h2 {
  font-size: clamp(1.5rem, 2.6vw, 2.35rem);
  line-height: 1.15;
}

h3 {
  font-size: 1.12rem;
}

h1,
h2,
h3 {
  font-family: "Sora", "Manrope", Arial, sans-serif;
}

p {
  color: var(--muted);
}

.reveal {
  opacity: 0;
  transform: translateY(22px) scale(0.985);
  filter: blur(5px);
  transition:
    opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1),
    transform 0.7s cubic-bezier(0.16, 1, 0.3, 1),
    filter 0.7s cubic-bezier(0.16, 1, 0.3, 1);
  transition-delay: var(--reveal-delay, 0ms);
}

.reveal.in-view {
  opacity: 1;
  transform: translateY(0) scale(1);
  filter: blur(0);
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(255, 253, 246, 0.88);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(10px);
}

.nav-wrap {
  min-height: 74px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}

.nav-contacts {
  display: flex;
  align-items: center;
  gap: 8px;
}

.contact-icon {
  width: 36px;
  aspect-ratio: 1 / 1;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: #ffffff;
  color: #334155;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 8px 18px rgba(30, 41, 59, 0.08);
  transition:
    transform 0.3s cubic-bezier(0.16, 1, 0.3, 1),
    color 0.25s ease,
    border-color 0.25s ease,
    background-color 0.25s ease,
    box-shadow 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.contact-icon i {
  font-size: 0.92rem;
}

.contact-icon:hover {
  transform: translateY(-2px);
  color: #111827;
  border-color: #e6c854;
  background: linear-gradient(135deg, #fde68a, #facc15);
  box-shadow: 0 14px 26px rgba(250, 204, 21, 0.25);
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 22px;
}

.site-nav a {
  font-weight: 600;
  color: #334155;
}

.site-nav a:hover {
  color: var(--accent-dark);
}

.menu-toggle {
  border: 1px solid var(--line);
  background: #fff;
  width: 44px;
  height: 44px;
  border-radius: 8px;
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 4px;
  cursor: pointer;
}

.menu-toggle span {
  width: 19px;
  height: 2px;
  background: var(--text);
}

.btn,
.project-card,
.value-list article,
.quick-info li,
.language-grid article,
.contact-card,
.contact-links a,
.chip-list span {
  transition:
    transform 0.35s cubic-bezier(0.16, 1, 0.3, 1),
    box-shadow 0.35s cubic-bezier(0.16, 1, 0.3, 1),
    border-color 0.25s ease,
    background-color 0.25s ease,
    color 0.25s ease;
}

.hero {
  padding-top: 48px;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 28px;
  align-items: center;
}

.hero-copy > p {
  margin-bottom: 24px;
  max-width: 66ch;
}

.hero-title-stack {
  position: relative;
  display: inline-block;
  margin-bottom: 14px;
  padding-bottom: 6px;
  isolation: isolate;
}

.hero-role {
  display: block;
  margin: 0 0 10px;
  font-size: clamp(0.86rem, 1.2vw, 1rem);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #8b6d00;
  border: 0;
  border-radius: 0;
  padding: 0;
  background: transparent;
  min-height: 0;
}

.hero-name {
  margin: 0;
  line-height: 1.02;
  text-wrap: balance;
  color: #111827;
}

.hero-ghost-track {
  position: absolute;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
}

.hero-ghost {
  --ghost-body: #fffdf0;
  width: clamp(22px, 2.3vw, 32px);
  height: clamp(30px, 3.3vw, 44px);
  position: absolute;
  top: clamp(2px, 0.6vw, 10px);
  left: 105%;
  border-radius: 100% / 70% 70% 0% 0%;
  background-color: var(--ghost-body);
  background-image:
    radial-gradient(ellipse at 35% 40%, #111 8%, transparent 0%),
    radial-gradient(ellipse at 65% 40%, #111 8%, transparent 0%),
    radial-gradient(ellipse at 50% 60%, #111 8%, transparent 0%);
  opacity: 0.9;
  mix-blend-mode: exclusion;
  transform: rotate(-90deg);
  animation: heroGhostCruise 5.6s ease-out infinite;
}

.hero-ghost div {
  position: absolute;
  width: 20%;
  background-color: var(--ghost-body);
}

.hero-ghost div:nth-of-type(1) {
  height: 58%;
  left: 0;
  bottom: -50%;
  border-radius: 100% / 0% 0% 50% 50%;
}

.hero-ghost div:nth-of-type(2),
.hero-ghost div:nth-of-type(4) {
  height: 34%;
  left: 20%;
  bottom: -24%;
  border-radius: 100% / 50% 50% 0% 0%;
  background-color: transparent;
}

.hero-ghost div:nth-of-type(3) {
  height: 34%;
  left: 40%;
  bottom: -31%;
  border-radius: 100% / 0% 0% 60% 60%;
}

.hero-ghost div:nth-of-type(4) {
  left: 60%;
}

.hero-ghost div:nth-of-type(5) {
  height: 26%;
  left: 80%;
  bottom: -23%;
  border-radius: 100% / 0% 0% 70% 70%;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 30px;
}

.btn {
  min-height: 48px;
  padding: 12px 16px;
  border-radius: 8px;
  border: 1px solid transparent;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-weight: 700;
}

.btn svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 2;
}

.btn-primary {
  background: linear-gradient(135deg, var(--accent), var(--accent-alt));
  color: #111827;
  box-shadow: 0 12px 24px rgba(250, 204, 21, 0.34);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 18px 30px rgba(245, 158, 11, 0.42);
}

.btn-secondary {
  background: var(--surface);
  border-color: var(--line);
  color: var(--text);
}

.btn-secondary:hover {
  transform: translateY(-2px);
  border-color: var(--accent-dark);
  color: var(--accent-dark);
}

.quick-info {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.quick-info li {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 12px;
}

.quick-info strong {
  display: block;
  font-size: 0.84rem;
  color: var(--text);
}

.quick-info span {
  color: var(--muted);
  font-size: 0.92rem;
  overflow-wrap: anywhere;
}

.hero-visual {
  justify-self: end;
  position: relative;
  width: min(100%, 430px);
  aspect-ratio: 10 / 11;
  display: grid;
  place-items: end center;
  padding-top: 0;
  isolation: isolate;
}

.hero-visual img {
  width: min(100%, 420px);
  max-height: none;
  object-fit: contain;
  object-position: center bottom;
  margin: 0 auto;
  filter: drop-shadow(0 12px 24px rgba(15, 23, 42, 0.16));
  
}

.section-grid {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 32px;
}

.section-content > p {
  margin-bottom: 22px;
  max-width: 72ch;
}

.value-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.value-list article {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 16px;
}

.value-list article:hover,
.quick-info li:hover,
.project-card:hover,
.language-grid article:hover,
.contact-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-strong);
  border-color: #e7cb67;
}

.value-list h3 {
  margin-bottom: 8px;
}

.section-headline {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 18px;
  margin-bottom: 30px;
}

.section-headline p {
  max-width: 52ch;
}

.projects-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.project-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  overflow: hidden;
  box-shadow: var(--shadow);
}

.project-card img {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
}

.project-body {
  padding: 16px;
}

.project-body h3 {
  margin-bottom: 8px;
}

.project-body p {
  margin-bottom: 12px;
}

.project-body ul {
  margin: 0 0 14px;
  padding-left: 20px;
  color: #2b4256;
}

.project-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  border-top: 1px solid var(--line);
  padding-top: 12px;
}

.project-meta a {
  font-weight: 700;
  color: var(--accent);
}

.project-meta span {
  background: var(--accent-soft);
  border: 1px solid #f3df94;
  color: var(--accent-dark);
  font-weight: 700;
  border-radius: 999px;
  padding: 4px 10px;
  font-size: 0.8rem;
}

.chip-list {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 24px;
}

.chip-list span {
  border: 1px solid var(--line);
  background: var(--surface);
  border-radius: 999px;
  padding: 8px 12px;
  font-size: 0.92rem;
  color: #284158;
  font-weight: 600;
}

.chip-list span:hover {
  transform: translateY(-2px);
  border-color: #e7cb67;
  color: var(--accent-dark);
}

.skill-bars {
  display: grid;
  gap: 14px;
  margin-bottom: 22px;
}

.skill-line {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  margin-bottom: 6px;
}

.skill-line span {
  color: var(--muted);
  font-weight: 600;
  font-size: 0.9rem;
}

.bar {
  height: 10px;
  border-radius: 999px;
  background: #dde8f2;
  overflow: hidden;
}

.bar span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #facc15, #f59e0b);
}

.skill-bars > div.reveal .bar span {
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
  transition-delay: calc(var(--reveal-delay, 0ms) + 120ms);
}

.skill-bars > div.reveal.in-view .bar span {
  transform: scaleX(1);
}

.language-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.language-grid article {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  padding: 14px;
}

.language-grid p {
  color: #284158;
  font-weight: 600;
}

.timeline {
  border-left: 2px solid #c7d7e7;
  padding-left: 24px;
  display: grid;
  gap: 24px;
}

.timeline article {
  display: grid;
  grid-template-columns: 100px 1fr;
  gap: 14px;
  align-items: baseline;
}

.timeline-year {
  color: var(--accent);
  font-weight: 800;
}

.timeline-body p {
  margin-top: 6px;
}

.contact-layout {
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 18px;
  align-items: start;
}

.contact-layout > div > p {
  margin: 14px 0 0;
  max-width: 62ch;
}

.contact-links {
  margin-top: 22px;
  display: grid;
  gap: 10px;
}

.contact-links a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  color: #274056;
  font-weight: 600;
  overflow-wrap: anywhere;
}

.contact-links a:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 18px rgba(15, 23, 42, 0.08);
  border-color: var(--accent-dark);
  color: var(--accent-dark);
}

.contact-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  padding: 18px;
  box-shadow: var(--shadow);
}

.contact-card h3 {
  margin-bottom: 10px;
}

.contact-card ul {
  margin: 0;
  padding-left: 18px;
}

.contact-card li {
  margin-bottom: 6px;
  color: #2f465a;
}

.site-footer {
  padding: 22px 0;
  background: linear-gradient(135deg, #0f172a, #1f2937);
  color: #e9f0f7;
}

@keyframes heroGhostCruise {
  0% {
    left: 105%;
    transform: rotate(-90deg);
  }
  100% {
    left: -12%;
    transform: rotate(-90deg);
  }
}

@media (prefers-reduced-motion: reduce) {
  .reveal {
    opacity: 1;
    transform: none;
    filter: none;
    transition: none;
  }

  .btn,
  .project-card,
  .value-list article,
  .quick-info li,
  .language-grid article,
  .contact-card,
  .contact-links a,
  .chip-list span,
  .bar span {
    transition: none;
  }

  .hero-ghost {
    animation: none;
    opacity: 0;
  }
}

.footer-wrap {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.site-footer p {
  color: inherit;
}

@media (max-width: 1080px) {
  .hero-grid {
    grid-template-columns: 1fr;
  }

  .hero-visual {
    justify-self: start;
  }

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

  .projects-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

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

@media (max-width: 760px) {
  .nav-wrap {
    min-height: 72px;
    gap: 10px;
  }

  .nav-contacts {
    max-width: calc(100% - 56px);
    overflow-x: auto;
    padding-bottom: 2px;
    scrollbar-width: none;
  }

  .nav-contacts::-webkit-scrollbar {
    display: none;
  }

  .contact-icon {
    flex: 0 0 auto;
  }

  .menu-toggle {
    display: inline-flex;
  }

  .site-nav {
    position: absolute;
    top: 74px;
    left: 0;
    right: 0;
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    background: var(--surface);
    border-bottom: 1px solid var(--line);
  }

  .site-nav.is-open {
    display: flex;
  }

  .site-nav a {
    min-height: 48px;
    display: flex;
    align-items: center;
    padding: 0 16px;
    border-top: 1px solid var(--line);
  }

  .section {
    padding: 70px 0;
  }

  .quick-info {
    grid-template-columns: 1fr;
  }

  .value-list {
    grid-template-columns: 1fr;
  }

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

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

  .timeline article {
    grid-template-columns: 1fr;
    gap: 4px;
  }

  .footer-wrap {
    flex-direction: column;
  }
}
