:root {
  color-scheme: dark;
  --bg: #020617;
  --bg-soft: #07111f;
  --surface: rgba(255, 255, 255, 0.055);
  --surface-strong: rgba(255, 255, 255, 0.095);
  --line: rgba(255, 255, 255, 0.12);
  --text: #f8fafc;
  --muted: #9ca3af;
  --soft: #d1d5db;
  --accent: #34d399;
  --accent-soft: rgba(52, 211, 153, 0.1);
  --accent-line: rgba(52, 211, 153, 0.34);
  --shadow: 0 28px 90px rgba(0, 0, 0, 0.42);
  font-family:
    Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 112px;
}

body {
  margin: 0;
  min-width: 320px;
  color: var(--text);
  background:
    radial-gradient(circle at 50% -10%, rgba(52, 211, 153, 0.18), transparent 30rem),
    radial-gradient(circle at 12% 35%, rgba(52, 211, 153, 0.08), transparent 26rem),
    linear-gradient(180deg, #020617 0%, #050b17 48%, #020617 100%);
}

body::selection {
  color: #02120c;
  background: var(--accent);
}

.ambient-grid {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.028) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.028) 1px, transparent 1px);
  background-size: 82px 82px;
  mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 0.82), transparent 80%);
}

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

button,
input,
textarea {
  font: inherit;
}

.page-shell {
  width: min(1120px, calc(100% - 32px));
  margin: 0 auto;
}

.site-header {
  position: sticky;
  top: 12px;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 12px;
  padding: 10px 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(2, 6, 23, 0.82);
  -webkit-backdrop-filter: blur(20px) saturate(140%);
  backdrop-filter: blur(20px) saturate(140%);
  box-shadow: 0 10px 36px rgba(0, 0, 0, 0.22);
}

.brand {
  flex-shrink: 0;
}

.nav-toggle {
  display: none;
  width: 44px;
  height: 44px;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  color: var(--text);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 50%;
  cursor: pointer;
}

.close-icon,
.nav-toggle[aria-expanded="true"] .menu-icon {
  display: none;
}

.nav-toggle[aria-expanded="true"] .close-icon {
  display: block;
}

a:focus-visible,
button:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

.brand,
.nav-links,
.hero-actions,
.profile-links,
.status-pill,
.availability-badge {
  display: flex;
  align-items: center;
}

.brand-mark {
  display: inline-grid;
  width: 40px;
  height: 40px;
  place-items: center;
  border: 1px solid var(--accent-line);
  border-radius: 999px;
  color: #02120c;
  background: var(--accent);
  font-weight: 950;
  box-shadow: 0 0 32px rgba(52, 211, 153, 0.24);
}

.nav-links {
  gap: 2px;
  min-width: 0;
  flex-wrap: wrap;
  justify-content: center;
}

.nav-links a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 10px 12px;
  border-radius: 999px;
  color: var(--muted);
  font-size: 0.92rem;
}

.nav-links a:hover,
.nav-links a:focus-visible {
  color: var(--text);
  background: rgba(255, 255, 255, 0.08);
}

.status-pill,
.availability-badge {
  gap: 8px;
  color: var(--accent);
  font-weight: 850;
}

.status-pill {
  min-height: 44px;
  border: 1px solid var(--accent-line);
  border-radius: 999px;
  padding: 0 14px;
  background: var(--accent-soft);
  font-size: 0.88rem;
  white-space: nowrap;
}

.status-pill span,
.availability-badge span {
  flex-shrink: 0;
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: var(--accent);
  box-shadow: 0 0 16px rgba(52, 211, 153, 0.9);
}

.hero-section {
  display: grid;
  justify-items: center;
  min-height: calc(100vh - 86px);
  padding: 80px 0 106px;
  text-align: center;
}

.hero-avatar {
  width: 132px;
  height: 132px;
  margin-bottom: 28px;
  overflow: hidden;
  border: 1px solid var(--accent-line);
  border-radius: 999px;
  background: #0b1220;
  box-shadow:
    0 0 0 10px rgba(52, 211, 153, 0.06),
    0 28px 80px rgba(0, 0, 0, 0.42);
}

.hero-avatar img,
.about-photo img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.availability-badge {
  justify-content: center;
  margin: 0 0 22px;
  font-size: 0.96rem;
}

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

h1 {
  max-width: min(920px, 100%);
  margin-bottom: 16px;
  font-size: 6.4rem;
  letter-spacing: 0;
  line-height: 1.05;
  overflow-wrap: anywhere;
}

.hero-role {
  margin-bottom: 16px;
  color: var(--soft);
  font-size: 1.75rem;
  font-weight: 750;
}

.hero-lede,
.section-heading p,
.about-copy,
.offer-card p,
.contact-copy p {
  color: var(--muted);
  font-size: 1.08rem;
  line-height: 1.75;
}

.hero-lede {
  max-width: 780px;
}

.hero-actions {
  justify-content: center;
  flex-wrap: wrap;
  gap: 14px;
  margin: 32px 0 34px;
}

.button {
  display: inline-flex;
  min-height: 48px;
  align-items: center;
  justify-content: center;
  border: 1px solid transparent;
  border-radius: 999px;
  padding: 0 20px;
  font-weight: 850;
  cursor: pointer;
  transition:
    transform 180ms ease,
    border-color 180ms ease,
    background 180ms ease,
    color 180ms ease;
}

.button:hover,
.button:focus-visible {
  transform: translateY(-2px);
}

.button.primary {
  color: #02120c;
  background: var(--accent);
  box-shadow: 0 18px 52px rgba(52, 211, 153, 0.2);
}

.button.quiet,
.button.secondary {
  color: var(--soft);
  border-color: var(--line);
  background: rgba(255, 255, 255, 0.04);
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  width: min(760px, 100%);
  margin: 0;
}

.stat-card,
.service-card,
.project-card,
.skill-card,
.contact-form,
.offer-card,
.timeline-item {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow);
}

.stat-card {
  padding: 18px;
  text-align: left;
}

.stat-card dt {
  color: var(--muted);
  font-size: 0.86rem;
}

.stat-card dd {
  margin: 8px 0 0;
  color: var(--text);
  font-size: 1.35rem;
  font-weight: 950;
}

.section {
  padding: 96px 0;
  border-top: 1px solid var(--line);
}

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

.section-heading.centered {
  display: grid;
  justify-items: center;
  max-width: 760px;
  margin-right: auto;
  margin-left: auto;
  text-align: center;
}

.section-kicker {
  margin: 0 0 14px;
  color: var(--accent);
  font-size: 0.82rem;
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

h2 {
  margin-bottom: 0;
  font-size: 3.7rem;
  line-height: 1;
}

h3 {
  font-size: 1.2rem;
}

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

.service-card {
  min-height: 300px;
  padding: 24px;
  transition:
    transform 180ms ease,
    border-color 180ms ease,
    background 180ms ease;
}

.service-card:hover,
.project-card:hover,
.skill-card:hover,
.timeline-item:hover {
  transform: translateY(-5px);
  border-color: var(--accent-line);
  background: var(--surface-strong);
}

.service-card span,
.project-index {
  display: block;
  margin-bottom: 34px;
  color: var(--accent);
  font-weight: 950;
}

.service-card p,
.project-card p,
.timeline-item p {
  color: var(--muted);
  line-height: 1.7;
}

.logo-strip {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 1px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--line);
}

.logo-strip span {
  display: grid;
  min-height: 108px;
  place-items: center;
  padding: 20px;
  color: var(--soft);
  background: rgba(255, 255, 255, 0.045);
  font-size: 1.05rem;
  font-weight: 850;
  text-align: center;
}

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

.project-card {
  position: relative;
  display: flex;
  flex-direction: column;
  min-height: 360px;
  padding: 28px;
  overflow: hidden;
  transition:
    transform 200ms ease,
    border-color 200ms ease,
    background 200ms ease;
}

.project-card::before {
  content: "";
  position: absolute;
  inset: auto -26% -40% auto;
  width: 260px;
  height: 260px;
  border-radius: 999px;
  background: var(--project-accent, rgba(52, 211, 153, 0.3));
  filter: blur(18px);
  opacity: 0.2;
}

.project-meta,
.metric-list,
.project-card h3,
.project-card p,
.project-card .outcome-line,
.project-card .chip-row,
.project-actions {
  position: relative;
  z-index: 1;
}

.project-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 20px;
  color: var(--muted);
  font-size: 0.88rem;
}

.project-index {
  margin: 0;
}

.outcome-line {
  margin-bottom: 16px;
  color: var(--text) !important;
  font-size: 1.35rem !important;
  font-weight: 900;
  line-height: 1.25 !important;
}

.metric-list {
  display: grid;
  gap: 10px;
  margin: 18px 0 0;
  padding: 0;
  list-style: none;
}

.metric-list li {
  color: var(--soft);
}

.metric-list li::before,
.offer-list li::before {
  content: "";
  display: inline-block;
  width: 7px;
  height: 7px;
  margin-right: 10px;
  border-radius: 999px;
  background: var(--accent);
}

.chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 18px;
}

.chip {
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 7px 10px;
  color: var(--soft);
  background: rgba(255, 255, 255, 0.045);
  font-size: 0.86rem;
}

.project-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: auto;
  padding-top: 26px;
}

.project-actions a,
.profile-links a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  max-width: 100%;
  overflow-wrap: anywhere;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 9px 12px;
  color: var(--text);
  background: rgba(255, 255, 255, 0.05);
  font-size: 0.88rem;
  font-weight: 850;
}

.project-actions a:hover,
.project-actions a:focus-visible,
.profile-links a:hover,
.profile-links a:focus-visible {
  border-color: var(--accent-line);
  background: var(--accent-soft);
}

.about-section,
.contact-section {
  display: grid;
  grid-template-columns: minmax(0, 0.78fr) minmax(0, 1.22fr);
  gap: 42px;
  align-items: start;
}

.about-photo {
  position: sticky;
  top: 110px;
  aspect-ratio: 4 / 5;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #0b1220;
  box-shadow: var(--shadow);
}

.availability {
  color: var(--accent);
  font-weight: 850;
}

.timeline-list {
  display: grid;
  gap: 12px;
  margin-top: 26px;
}

.timeline-item {
  display: grid;
  grid-template-columns: 150px 1fr;
  gap: 20px;
  padding: 22px;
  transition:
    transform 180ms ease,
    border-color 180ms ease,
    background 180ms ease;
}

.timeline-period {
  color: var(--accent);
  font-weight: 900;
}

.education-block {
  margin-top: 32px;
  padding-top: 28px;
  border-top: 1px solid var(--line);
}

.education-block h3 {
  color: var(--text);
}

.education-block a:hover {
  color: var(--accent);
  text-decoration: underline;
}

.contact-location {
  margin-top: 20px;
}

.skill-card,
.timeline-item > div,
.about-copy,
.contact-copy {
  min-width: 0;
  overflow-wrap: anywhere;
}

.offer-card {
  display: grid;
  grid-template-columns: 1.25fr 0.75fr;
  gap: 40px;
  padding: 34px;
  background:
    radial-gradient(circle at 20% 0%, rgba(52, 211, 153, 0.14), transparent 28rem),
    rgba(255, 255, 255, 0.055);
}

.offer-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin: 26px 0 0;
  padding: 0;
  list-style: none;
}

.offer-list li {
  color: var(--soft);
}

.offer-side {
  display: grid;
  align-content: center;
  gap: 18px;
  border-left: 1px solid var(--line);
  padding-left: 34px;
}

.offer-side span {
  color: var(--accent);
  font-size: 0.82rem;
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

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

.skill-card {
  padding: 22px;
  transition:
    transform 180ms ease,
    border-color 180ms ease,
    background 180ms ease;
}

.contact-copy {
  align-self: start;
}

.profile-links {
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 24px;
}

.hero-social-links {
  justify-content: center;
  max-width: 100%;
  margin: 0 0 32px;
}

.hero-social-links:empty {
  display: none;
}

.contact-form {
  display: grid;
  gap: 16px;
  padding: 24px;
  background: var(--surface);
}

label {
  display: grid;
  gap: 8px;
  color: var(--soft);
  font-weight: 850;
}

input,
textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 13px 14px;
  color: var(--text);
  background: rgba(2, 6, 23, 0.78);
  outline: none;
}

input:focus,
textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 4px rgba(52, 211, 153, 0.12);
}

textarea {
  resize: vertical;
}

.form-button {
  width: 100%;
}

.form-status {
  min-height: 24px;
  margin: 0;
  color: var(--muted);
}

.form-status.success {
  color: var(--accent);
}

.form-status.error {
  color: #fca5a5;
}

.site-footer {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  padding: 28px 0 40px;
  border-top: 1px solid var(--line);
  color: var(--muted);
}

.reveal {
  opacity: 0;
  transform: translateY(18px);
  transition:
    opacity 600ms ease,
    transform 600ms ease;
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

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

  *,
  *::before,
  *::after {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }

  .reveal {
    opacity: 1;
    transform: none;
  }
}

@media (max-width: 64rem) {
  h1 {
    font-size: 4.9rem;
  }

  h2 {
    font-size: 3rem;
  }

  .section-heading,
  .site-footer {
    align-items: flex-start;
    flex-direction: column;
  }

  .site-header {
    flex-wrap: wrap;
    border-radius: 28px;
    padding: 8px 12px;
  }

  .nav-links {
    flex-basis: 100%;
    width: 100%;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 4px;
  }

  .nav-links a {
    border-radius: 12px;
    min-height: 48px;
    color: var(--soft);
  }

  .nav-enhanced .nav-toggle {
    display: inline-flex;
    margin-left: auto;
  }

  .nav-enhanced .nav-links {
    display: none;
    position: absolute;
    top: calc(100% + 10px);
    inset-inline: 0;
    padding: 12px;
    max-height: calc(100vh - 110px);
    max-height: calc(100dvh - 110px);
    overflow-y: auto;
    overscroll-behavior: contain;
    border: 1px solid var(--line);
    border-radius: 22px;
    background: rgba(2, 6, 23, 0.94);
    -webkit-backdrop-filter: blur(20px) saturate(140%);
    backdrop-filter: blur(20px) saturate(140%);
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.28);
  }

  .nav-enhanced .nav-toggle[aria-expanded="true"] + .nav-links {
    display: grid;
  }

  .status-pill {
    display: none;
  }

  .services-grid,
  .skills-grid,
  .logo-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .about-section,
  .contact-section,
  .offer-card {
    grid-template-columns: 1fr;
  }

  .about-photo {
    position: static;
    max-height: 560px;
    width: min(100%, 448px);
    justify-self: center;
  }

  .offer-side {
    border-left: 0;
    border-top: 1px solid var(--line);
    padding-top: 28px;
    padding-left: 0;
  }
}

@media (max-width: 680px) {
  .page-shell {
    width: min(100% - 22px, 1120px);
  }

  .hero-section {
    min-height: auto;
    padding: 58px 0 82px;
  }

  .hero-avatar {
    width: 110px;
    height: 110px;
  }

  h1 {
    font-size: 3.45rem;
  }

  h2 {
    font-size: 2.35rem;
  }

  .hero-role {
    font-size: 1.25rem;
  }

  .stats-grid,
  .services-grid,
  .projects-grid,
  .skills-grid,
  .logo-strip,
  .offer-list,
  .timeline-item {
    grid-template-columns: 1fr;
  }

  .section {
    padding: 68px 0;
  }

  .service-card,
  .project-card {
    min-height: auto;
  }

  .offer-card {
    padding: 24px;
    gap: 24px;
  }

  .section-heading {
    gap: 20px;
  }
}
